日志增加门店类型筛选
This commit is contained in:
@@ -14,6 +14,8 @@ class Vlog extends HD_Controller
|
||||
|
||||
public function index()
|
||||
{
|
||||
$typeAry = $this->biz_model->type_ary();
|
||||
$this->data['typeAry'] = $typeAry;
|
||||
return $this->lists();
|
||||
}
|
||||
|
||||
@@ -41,6 +43,10 @@ class Vlog extends HD_Controller
|
||||
}
|
||||
$where["biz_id in ($bizs)"] = null;
|
||||
}
|
||||
if ($params['type']) {
|
||||
$type = intval($params['type']);
|
||||
$where["biz_id in (select id from lc_biz where type={$type})"] = null;
|
||||
}
|
||||
if ($params['c_time']) {
|
||||
$c_time = explode(' ~ ', $params['c_time']);
|
||||
$c_time[0] && $where["createTime >="] = $c_time[0] . ' 00:00:00';
|
||||
|
||||
@@ -12,6 +12,15 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="am-form-group fl">
|
||||
<label class="am-para-label w100">门店类型:</label>
|
||||
<div class="am-form-group am-para-inline w150">
|
||||
<select name="type" v-model="type">
|
||||
<option value="0">所有</option>
|
||||
<option :value="i" v-for="(v,i) in typeAry">{{v}}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="am-form-group">
|
||||
<label class="am-para-label w100">门店:</label>
|
||||
<div class="am-form-group fl">
|
||||
@@ -90,7 +99,9 @@
|
||||
vue_obj = new Vue({
|
||||
el: '#vue-app',
|
||||
data: {
|
||||
lists: []
|
||||
lists: [],
|
||||
type: <?=$params['type'] ? $params['type'] : 0?>,
|
||||
typeAry: <?=$typeAry ? json_encode($typeAry) : '[]'?>,
|
||||
},
|
||||
mounted: function () {
|
||||
this.lists = <?= json_encode($lists, JSON_UNESCAPED_UNICODE) ?>;
|
||||
@@ -133,7 +144,6 @@
|
||||
date = beginDate + ' ~ ' + endDate;
|
||||
$('#id-create-time').val(date);
|
||||
});
|
||||
$('.selectpicker').selectpicker();
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user