|
@@ -2,7 +2,7 @@
|
|
|
|
|
|
use App\Http\Controllers\Api\Api;
|
|
|
use App\Models\Custom as Model;
|
|
|
-use App\Models\WeiBan\Qrcode as WeiBanQrcode;
|
|
|
+use App\Models\Work\State as WorkState;
|
|
|
use Vinkla\Hashids\Facades\Hashids;
|
|
|
use App\Http\Requests\Api\Custom as Request;
|
|
|
use App\Models\City;
|
|
@@ -23,7 +23,7 @@ class Custom extends Api{
|
|
|
* @param string $code 授权码
|
|
|
*
|
|
|
* */
|
|
|
- public function get_info(Model $Model,WeiBanQrcode $WeiBanQrcode,City $City,WorkExternal $WorkExternal){
|
|
|
+ public function get_info(Model $Model,WorkState $WorkState,City $City,WorkExternal $WorkExternal){
|
|
|
// 接口验签
|
|
|
// $this->verify_sign();
|
|
|
// 检查登录
|
|
@@ -41,7 +41,7 @@ class Custom extends Api{
|
|
|
// 手机号
|
|
|
$custom['phone'] = hide_phone($custom['phone']);
|
|
|
// 如果没有关联企微,获取二维码,已关联的不验证
|
|
|
- $followQrcode = $custom['external_userid'] ? ['thumb'=>'','link_url'=>''] : $WeiBanQrcode->getFollowQrcode($custom['city_id']);
|
|
|
+ $followQrcode = $custom['external_userid'] ? '' : $WorkState->getFollowQrcode($custom['city_id']);
|
|
|
// 城市ID换城市名
|
|
|
$cityId = (string) $City->getOne($custom['city_id'],'name');
|
|
|
// 所需数组组合
|
|
@@ -53,8 +53,8 @@ class Custom extends Api{
|
|
|
'company_id'=>1, // 无需验证资质
|
|
|
'show_price'=>$cityId?1:0, // 是否选择了城市处理
|
|
|
'city_id'=>$cityId,
|
|
|
- 'follow_qrcode'=>$followQrcode['thumb'],
|
|
|
- 'follow_linkurl'=>$followQrcode['link_url'],
|
|
|
+ 'follow_qrcode'=>$followQrcode,
|
|
|
+ 'follow_linkurl'=>'',
|
|
|
];
|
|
|
// 返回结果
|
|
|
return json_send(['code'=>'success','msg'=>'获取成功','data'=>$custom]);
|