Commit db747bf2 authored by youjie's avatar youjie

no message

parent e79a5d59
...@@ -429,7 +429,7 @@ ...@@ -429,7 +429,7 @@
}, },
//下载餐厅统计 //下载餐厅统计
DownLoadDinnerSalesBoard() { DownLoadDinnerSalesBoard() {
if (this.msg.DiningIDList&&this.msg.DiningIDList.length==0) { if (this.msg.DiningID<=0&&!this.msg.DiningIDs) {
this.Info(this.$t('sm.qxzcanting')); this.Info(this.$t('sm.qxzcanting'));
return; return;
} }
......
...@@ -204,7 +204,8 @@ ...@@ -204,7 +204,8 @@
<li> <li>
<span> <span>
<em>{{$t('commonPickUp.Pick_attractions')}}</em> <em>{{$t('commonPickUp.Pick_attractions')}}</em>
<el-select v-model="msg.CouponsId" :placeholder="$t('pub.pleaseSel')" filterable> <el-select v-model="msg.CouponsIdList" :placeholder="$t('pub.pleaseSel')"
multiple collapse-tags filterable @change="getMultipleChoice">
<el-option :label="$t('pub.unlimitedSel')" :value="defaultSelectValue"></el-option> <el-option :label="$t('pub.unlimitedSel')" :value="defaultSelectValue"></el-option>
<el-option v-for="item in ScenicList" :key="item.ID" :label="item.Name" :value="item.ID"></el-option> <el-option v-for="item in ScenicList" :key="item.ID" :label="item.Name" :value="item.ID"></el-option>
</el-select> </el-select>
...@@ -278,6 +279,8 @@ ...@@ -278,6 +279,8 @@
Year: 0, Year: 0,
Month: 0, Month: 0,
CouponsId: 0, CouponsId: 0,
CouponsIdList:[],
CouponsIds: [],
QStatus: 0, QStatus: 0,
loading: false, loading: false,
uid:0, uid:0,
...@@ -295,6 +298,26 @@ ...@@ -295,6 +298,26 @@
}; };
}, },
methods: { methods: {
// 多选
getMultipleChoice(){
if(this.msg.CouponsIdList.length>1){
if(this.msg.CouponsIdList.at(-1)==0){
this.msg.CouponsIdList = [0]
}else if(this.msg.CouponsIdList.at(-1)!=0){
this.msg.CouponsIdList.forEach((x,index)=>{
if(x==0){
this.msg.CouponsIdList.splice(index,1)
}
})
}
this.msg.CouponsId = 0
this.msg.CouponsIds = this.msg.CouponsIdList.join(',')
}
if(this.msg.CouponsIdList.length==1){
this.msg.CouponsId = this.msg.CouponsIdList[0]
this.msg.CouponsIds = ''
}
},
stockColor: function (type) { stockColor: function (type) {
if (type === 1) { if (type === 1) {
return 'hasStock_1' return 'hasStock_1'
...@@ -398,14 +421,20 @@ ...@@ -398,14 +421,20 @@
}, },
//下载餐厅统计 //下载餐厅统计
DownLoadDinnerSalesBoard() { DownLoadDinnerSalesBoard() {
if (this.msg.CouponsId <= 0) { if (this.msg.CouponsId<=0&&!this.msg.CouponsIds) {
this.Info("请选择景点!"); this.Info("请选择景点!");
return; return;
} }
let url
if(this.msg.CouponsId>0){
url = 'ticketcouponsorder_post_DownLoadScenicMonthStatistics'
}else{
url ='ticketcouponsorder_post_DownLoadScenicMonthStatisticsNew'
}
this.msg.loading = true; this.msg.loading = true;
this.msg.uid=this.userInfo.EmployeeId; this.msg.uid=this.userInfo.EmployeeId;
let fileName = "门票下载" + this.$commonUtils.getCurrentDate() + ".xls"; let fileName = "门票下载" + this.$commonUtils.getCurrentDate() + ".xls";
this.GetLocalFile("ticketcouponsorder_post_DownLoadScenicMonthStatistics", this.msg, fileName, this.GetLocalFile(url, this.msg, fileName,
res => { res => {
this.msg.loading = false; this.msg.loading = false;
}); });
......
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