1
This commit is contained in:
@@ -103,16 +103,17 @@ class Employees extends Wxapp
|
||||
$count = $this->app_user_model->count($where);
|
||||
$lists = $tabs = $bizs = [];
|
||||
if ($count) {
|
||||
$fileds = 'id,uname,mobile,status';
|
||||
$fileds = 'id,uname,mobile,status,group_id';
|
||||
$rows = $this->app_user_model->select($where, 'id desc', $page, $size, $fileds);
|
||||
foreach ($rows as $k => $v){
|
||||
if($v['group_id'] == 3){
|
||||
$row[$k]['uname'] = $v['uname'].'(店长)';
|
||||
}
|
||||
}
|
||||
|
||||
$lists = $rows;
|
||||
}
|
||||
$this->load->model("biz/biz_model");
|
||||
$re_biz = $this->biz_model->get(['id' => $this->biz_id, 'status' => 1]);
|
||||
if ($re_biz['type'] == 1) {//品牌店
|
||||
$tabs = [['id' => 1, 'name' => '本店'], ['id' => 2, 'name' => '其它门店']];
|
||||
$bizs = $this->biz_model->select(['type' => 1, 'status' => 1], 'id desc', 0, 0, 'id, biz_name as name');
|
||||
}
|
||||
|
||||
$data = [
|
||||
'list' => $lists,
|
||||
'total' => $count,
|
||||
|
||||
@@ -46,7 +46,7 @@ class Score extends Wxapp
|
||||
$where['type'] = $type ? Receiver_score_avg_day_model::TYPE_BIZ : Receiver_score_avg_day_model::TYPE_USER;
|
||||
$row = $this->receiver_score_avg_day_model->get($where);
|
||||
$up_time = date('Y-m-d');
|
||||
$title_hd = '较本月';
|
||||
$title_hd = '较上月';
|
||||
} elseif ($day_type == 2) {
|
||||
$up_month = strtotime("-1 month"); //上个月时间
|
||||
$where['year'] = date('Y', $up_month);
|
||||
@@ -61,7 +61,7 @@ class Score extends Wxapp
|
||||
$where['type'] = $type ? Receiver_score_day_model::TYPE_BIZ : Receiver_score_day_model::TYPE_USER;
|
||||
$row = $this->receiver_score_day_model->get($where);
|
||||
$up_time = date('Y-m-d', $up_month);
|
||||
$title_hd = '较昨日';
|
||||
$title_hd = '较上一日';
|
||||
}
|
||||
$score = ceil($row['score']) ?: 0;
|
||||
$abs_score = ceil($row['change_score']) ?: 0;
|
||||
|
||||
Reference in New Issue
Block a user