Commit 787a5de8 authored by lvshibao's avatar lvshibao

seat页面修改

parent 0a4891b4
...@@ -107,7 +107,7 @@ ...@@ -107,7 +107,7 @@
end-placeholder="结束日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"> :default-time="['00:00:00', '23:59:59']">
</el-date-picker> </el-date-picker>
<el-select v-model="cityvalue" filterable placeholder="请选择" @change="changeCity"> <el-select v-model="cityvalue" filterable placeholder="请选择" @change="changeCity">
<el-option <el-option
v-for="item in cityList" v-for="item in cityList"
:key="item.id" :key="item.id"
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
:value="item.id"> :value="item.id">
</el-option> </el-option>
</el-select> </el-select>
<el-select v-model="countryvalue" v-if="country_show == true" filterable placeholder="请选择" @change="changeCountry"> <el-select v-model="countryvalue" v-if="country_show == true" filterable placeholder="请选择" @change="changeCountry">
<el-option <el-option
label="全部县" label="全部县"
value=""> value="">
...@@ -127,7 +127,7 @@ ...@@ -127,7 +127,7 @@
:value="item.id"> :value="item.id">
</el-option> </el-option>
</el-select> </el-select>
<el-select v-model="seatvalue" v-if="seat_show == true" filterable placeholder="请选择" @change='changeSeat'> <el-select v-model="seatvalue" v-if="seat_show == true" filterable placeholder="请选择工号" @change='changeSeat'>
<el-option <el-option
label="全部工号" label="全部工号"
value=""> value="">
......
...@@ -24,24 +24,36 @@ ...@@ -24,24 +24,36 @@
end-placeholder="结束日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"> :default-time="['00:00:00', '23:59:59']">
</el-date-picker> </el-date-picker>
<el-select v-if="sel_is_show == true" v-model="taskvalue" filterable placeholder="请选择" @change="changeTask"> <el-select v-model="cityvalue" filterable placeholder="请选择市" @change="changeCity">
<el-option <el-option
v-for="item in taskList" v-for="item in cityList"
:key="item.id" :key="item.id"
:label="item.name" :label="item.name"
:value="item.id"> :value="item.id">
</el-option> </el-option>
</el-select> </el-select>
<el-select v-model="takevalue" filterable placeholder="请选择" @change='changeTake'> <el-select v-if="country_show == true" v-model="countryvalue" filterable placeholder="请选择县" @change="changeCountry">
<el-option
label="全部县"
value="">
</el-option>
<el-option
v-for="item in countryList"
:key="item.id"
:label="item.name"
:value="item.id">
</el-option>
</el-select>
<el-select v-if="seat_show == true" v-model="seatvalue" filterable placeholder="请选择坐席" @change='changeSeat'>
<el-option <el-option
label="全部坐席" label="全部坐席"
value=""> value="">
</el-option> </el-option>
<el-option <el-option
v-for="item in takeList" v-for="item in seatList"
:key="item.agentName" :key="item.code"
:label="item.agentName" :label="item.name"
:value="item.agentName"> :value="item.code">
</el-option> </el-option>
</el-select> </el-select>
<el-button type='primary' size='mini' style='height:30px;' @click='loadData()'> <el-button type='primary' size='mini' style='height:30px;' @click='loadData()'>
......
...@@ -8,9 +8,11 @@ new Vue({ ...@@ -8,9 +8,11 @@ new Vue({
countryList: [], countryList: [],
cityvalue: '', cityvalue: '',
countryvalue: '', countryvalue: '',
country_show: false,
start_date: '', start_date: '',
end_date: '', end_date: '',
seatList: [], seatList: [],
seat_show: true,
seatvalue: '', seatvalue: '',
loading: true, loading: true,
tableData: [], tableData: [],
...@@ -18,7 +20,6 @@ new Vue({ ...@@ -18,7 +20,6 @@ new Vue({
name: '', name: '',
sort: 'des', sort: 'des',
}, },
sel_is_show: true,
BASEURL: window_url, BASEURL: window_url,
currentPage: 1, currentPage: 1,
pagesize: 15, pagesize: 15,
...@@ -68,6 +69,11 @@ new Vue({ ...@@ -68,6 +69,11 @@ new Vue({
} else { } else {
that.cityList = data.data.city_list; that.cityList = data.data.city_list;
that.countryList = data.data.country_list; that.countryList = data.data.country_list;
if (that.countryList.length > 0) {
that.country_show = true;
} else {
that.country_show = false;
};
that.cityvalue = data.data.city_id; that.cityvalue = data.data.city_id;
console.log(that.cityvalue); console.log(that.cityvalue);
that.init_simple = true; that.init_simple = true;
...@@ -78,14 +84,20 @@ new Vue({ ...@@ -78,14 +84,20 @@ new Vue({
}, },
getTake() { getTake() {
let that = this; let that = this;
RquestsGet('api/v1/tasks/seat/?city=' + that.cityvalue + 'country=' + this.countryvalue + '&start_date=' + this.start_date + '&end_date=' + this.end_date).then(data => { RquestsGet('api/v1/tasks/seat/?city=' + that.cityvalue + '&country=' + that.countryvalue + '&start_date=' + this.start_date + '&end_date=' + this.end_date).then(data => {
//console.log(data); //console.log(data);
if (data.code != 0) { if (data.code != 0) {
//that.takeList = [{agentName:'全部坐席'}] //that.takeList = [{agentName:'全部坐席'}]
} else { } else {
that.seatList = data.data; that.seatList = data.data;
if (that.seatList.length > 0) {
that.seat_show = true;
} else {
that.seat_show = false;
};
} }
}) })
}, },
sortChange(item) { sortChange(item) {
......
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