|
@@ -57,7 +57,7 @@ class WechatKeywordsService extends BaseService
|
|
$val->wechat_accounts = WechatAccountKeywordLog::query()->where(
|
|
$val->wechat_accounts = WechatAccountKeywordLog::query()->where(
|
|
['weacht_keyworld_id' => $val->id,
|
|
['weacht_keyworld_id' => $val->id,
|
|
'status' => 1
|
|
'status' => 1
|
|
- ])->select('wechat_authorization_info_id as id',"appid",'nick_name')->get();;
|
|
|
|
|
|
+ ])->distinct("appid")->select('wechat_authorization_info_id as id',"appid",'nick_name')->get();;
|
|
}
|
|
}
|
|
return $list;
|
|
return $list;
|
|
}
|
|
}
|
|
@@ -81,7 +81,7 @@ class WechatKeywordsService extends BaseService
|
|
$ids = WechatAccountKeywordLog::query()->where([
|
|
$ids = WechatAccountKeywordLog::query()->where([
|
|
'wechat_authorization_info_id' => $param['wechat_authorization_info_id'],
|
|
'wechat_authorization_info_id' => $param['wechat_authorization_info_id'],
|
|
'status' => 1,
|
|
'status' => 1,
|
|
- ])->pluck('weacht_keyworld_id')->toArray();
|
|
|
|
|
|
+ ])->distinct("weacht_keyworld_id")->pluck('weacht_keyworld_id')->toArray();
|
|
$sql->whereIn('id',$ids);
|
|
$sql->whereIn('id',$ids);
|
|
}
|
|
}
|
|
return $sql;
|
|
return $sql;
|