Commit 8574926e authored by hujun's avatar hujun

所属城市商铺

parent db62d9be
...@@ -80,6 +80,7 @@ class WatchShop extends Basic ...@@ -80,6 +80,7 @@ class WatchShop extends Basic
if ($params['check_status'] == 2) { if ($params['check_status'] == 2) {
$where['a.appoint_agent_id'] = $this->userId; $where['a.appoint_agent_id'] = $this->userId;
$where['d.site_id'] = $this->siteId; $where['d.site_id'] = $this->siteId;
$where['c.city'] = $this->city;
$data['list'] = $applies->getAppointWatchOurList($pageNo, $pageSize, 'id DESC', 'a.*', $where); $data['list'] = $applies->getAppointWatchOurList($pageNo, $pageSize, 'id DESC', 'a.*', $where);
$data['total'] = $applies->getAppointWatchOurTotal($where); $data['total'] = $applies->getAppointWatchOurTotal($where);
} }
......
...@@ -81,9 +81,8 @@ class AppointWatchShop extends BaseModel ...@@ -81,9 +81,8 @@ class AppointWatchShop extends BaseModel
return $this return $this
->field($field) ->field($field)
->alias('a') ->alias('a')
->join('u_users b', 'a.user_id=b.id', 'left') ->join('u_user_agent d', 'a.user_id=d.user_id', 'left')
->join('u_user_agent d', 'b.id=d.user_id', 'left') ->join('g_houses c', 'a.house_id=c.id', 'left')
->join('a_agents c', 'd.agent_id=c.id', 'left')
->where($params) ->where($params)
->order($order_) ->order($order_)
->limit($pageSize) ->limit($pageSize)
...@@ -102,9 +101,8 @@ class AppointWatchShop extends BaseModel ...@@ -102,9 +101,8 @@ class AppointWatchShop extends BaseModel
$params['d.is_del'] = 0; $params['d.is_del'] = 0;
return $this return $this
->alias('a') ->alias('a')
->join('u_users b', 'a.user_id=b.id', 'left') ->join('u_user_agent d', 'a.user_id=d.user_id', 'left')
->join('u_user_agent d', 'b.id=d.user_id', 'left') ->join('g_houses c', 'a.house_id=c.id', 'left')
->join('a_agents c', 'd.agent_id=c.id', 'left')
->where($params) ->where($params)
->count(); ->count();
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment