Commit eb9dc0c2 authored by zhengke's avatar zhengke

no message

parent 3455c127
...@@ -178,7 +178,6 @@ ...@@ -178,7 +178,6 @@
<template slot-scope="scope"> <template slot-scope="scope">
<div class="agreement-IncomeMoney-box"> <div class="agreement-IncomeMoney-box">
{{scope.row.IncomeMoney}} {{scope.row.IncomeMoney}}
<!-- scope.row.OrderType.split(',').length>1 -->
<i v-if="scope.row.OrderStatus==1" <i v-if="scope.row.OrderStatus==1"
@click="makeAdocument(scope.row,scope.$index,1)" @click="makeAdocument(scope.row,scope.$index,1)"
class="iconfont iconjia- numIcon"></i> class="iconfont iconjia- numIcon"></i>
...@@ -186,12 +185,12 @@ ...@@ -186,12 +185,12 @@
<div class="float-flag-shape"></div> <div class="float-flag-shape"></div>
<el-checkbox-group v-model="scope.row.checkList" <el-checkbox-group v-model="scope.row.checkList"
@change="clickMultipleChoice(scope.row,scope.$index,1)"> @change="clickMultipleChoice(scope.row,scope.$index,1)">
<el-checkbox v-for="(item,index) in MultipleChoiceList" :key="index" <el-checkbox v-for="(item,index) in scope.row.MultipleChoiceList" :key="index"
:label="item.Id">{{item.Name}}</el-checkbox> :label="item.Id">{{item.Name}}</el-checkbox>
</el-checkbox-group> </el-checkbox-group>
<div class="agreement-Cancel"> <div class="agreement-Cancel">
<span @click="scope.row.actuallyReceived=false">取消</span> <span @click="popCancelClick(scope.row,scope.$index,1)">取消</span>
<span @click="popClick(scope.$index,1)">确定</span> <span @click="popClick(scope.row,scope.$index,1)">确定</span>
</div> </div>
</div> </div>
...@@ -213,13 +212,13 @@ ...@@ -213,13 +212,13 @@
@click="makeAdocument(scope.row,scope.$index,3)" class="iconfont iconjia- numIcon"></i> @click="makeAdocument(scope.row,scope.$index,3)" class="iconfont iconjia- numIcon"></i>
<div v-show="scope.row.cost" class="agreement-IncomeMoney-pop"> <div v-show="scope.row.cost" class="agreement-IncomeMoney-pop">
<div class="float-flag-shape"></div> <div class="float-flag-shape"></div>
<el-checkbox-group v-model="scope.row.checkList" @change="clickMultipleChoice"> <el-radio-group v-model="scope.row.selectedType" @change="clickMultipleChoice(scope.row,scope.$index,3)">
<el-checkbox v-for="(item,index) in MultipleChoiceList" :key="index" <el-radio v-for="(item,index) in scope.row.MultipleChoiceList" :key="index"
:label="item.Id">{{item.Name}}</el-checkbox> :label="item.Id">{{item.Name}}</el-radio>
</el-checkbox-group> </el-radio-group>
<div class="agreement-Cancel"> <div class="agreement-Cancel">
<span @click="scope.row.cost=false">取消</span> <span @click="popCancelClick(scope.row,scope.$index,3)">取消</span>
<span @click="popClick(scope.$index,3)">确定</span> <span @click="popClick(scope.row,scope.$index,3)">确定</span>
</div> </div>
</div> </div>
...@@ -398,14 +397,26 @@ ...@@ -398,14 +397,26 @@
}); });
}, },
methods: { methods: {
// 关闭弹窗 // 取消
popClick(index,num){ popCancelClick(row, index, num){
if(num==1){ if(num==1){
this.dataList[index].actuallyReceived =false this.dataList[index].actuallyReceived =false
} }
if(num==3){ if(num==3){
this.dataList[index].cost =false this.dataList[index].cost =false
} }
this.dataList[index].MultipleChoiceList = []
this.dataList[index].selectedType = ''
},
// 关闭弹窗
popClick(row, index, num){
this.makeAdocumentFun(row, index, num)
if(num==1){
this.dataList[index].actuallyReceived =false
}
if(num==3){
this.dataList[index].cost =false
}
}, },
// 查看出票凭据 // 查看出票凭据
...@@ -459,23 +470,25 @@ ...@@ -459,23 +470,25 @@
}, },
// 多选发生变化 // 多选发生变化
clickMultipleChoice(row, index, num) { clickMultipleChoice(row, index, num) {
if(row.checkList.slice(-1)[0] == 4){ if(num == 1){
this.delType(row,1) if(row.checkList.slice(-1)[0] == 4){
this.delType(row,2) this.delType(row,1)
this.delType(row,3) this.delType(row,2)
this.delType(row,5) this.delType(row,3)
}else if(row.checkList.slice(-1)[0] == 5){ this.delType(row,5)
this.delType(row,1) row.selectedType = row.checkList.join(',')
this.delType(row,2) }else if(row.checkList.slice(-1)[0] == 5){
this.delType(row,3) this.delType(row,1)
this.delType(row,4) this.delType(row,2)
}else{ this.delType(row,3)
this.delType(row,4) this.delType(row,4)
this.delType(row,5) row.selectedType = row.checkList.join(',')
}else{
this.delType(row,4)
this.delType(row,5)
row.selectedType = row.checkList.join(',')
}
} }
this.RelevanceFrId = row.checkList.join(',')
console.log(this.RelevanceFrId,'=====')
}, },
// 删除套餐值 // 删除套餐值
delType(row,item) { delType(row,item) {
...@@ -487,20 +500,32 @@ ...@@ -487,20 +500,32 @@
}, },
// 制作单据 // 制作单据
makeAdocument(row, index, num) { makeAdocument(row, index, num) {
if(row.OrderType.split(',').length>1&&num==1){ let list = row.OrderType&&row.OrderType.split(',')
if(list!=null&&list.length!=0&&num==1){
this.dataList.forEach(item=>{ this.dataList.forEach(item=>{
return item.actuallyReceived = false return item.actuallyReceived = false
}) })
if(this.dataList[index]){ this.dataList[index].actuallyReceived = true
this.dataList[index].actuallyReceived = true for(let j=0;j<list.length;j++){
for(let i=0;i<this.MultipleChoiceList.length;i++){
if(list[j]==this.MultipleChoiceList[i].Id){
this.dataList[index].MultipleChoiceList.push(this.MultipleChoiceList[i])
}
}
} }
} }
else if(row.OrderType.split(',').length>1&&num==3){ else if(list!=null&&list.length!=0&&num==3){
this.dataList.forEach(item=>{ this.dataList.forEach(item=>{
return item.cost = false return item.cost = false
}) })
if(this.dataList[index]){ this.dataList[index].cost = true
this.dataList[index].cost = true for(let j=0;j<list.length;j++){
for(let i=0;i<this.MultipleChoiceList.length;i++){
if(list[j]==this.MultipleChoiceList[i].Id){
this.dataList[index].MultipleChoiceList.push(this.MultipleChoiceList[i])
}
}
} }
}else{ }else{
this.makeAdocumentFun(row, index, num) this.makeAdocumentFun(row, index, num)
...@@ -518,7 +543,7 @@ ...@@ -518,7 +543,7 @@
if (this.isOnline()) { if (this.isOnline()) {
url = 'http://yx.oytour.com/#/' url = 'http://yx.oytour.com/#/'
} else { } else {
url = 'http://www.test.com:8084/#/' url = 'http://www.test.com:8081/#/'
} }
let data = [{ let data = [{
path: 'ChoiceAddFinancialDocuments', path: 'ChoiceAddFinancialDocuments',
...@@ -527,8 +552,13 @@ ...@@ -527,8 +552,13 @@
ReFinanceId: row.OrderId, ReFinanceId: row.OrderId,
ReFinanceId2: num, ReFinanceId2: num,
GuestId: row.GuestId, GuestId: row.GuestId,
RelevanceFrId: row.OrderType // 单据类型 RelevanceFrId: row.selectedType?row.selectedType:row.OrderType // 单据类型
}] }]
this.dataList.forEach(item=>{
item.checkList = []
item.MultipleChoiceList = []
item.selectedType = ''
})
href = url + 'automaticLogin?token=' + this.getLocalStorage().token + '&data=' + JSON.stringify(data) href = url + 'automaticLogin?token=' + this.getLocalStorage().token + '&data=' + JSON.stringify(data)
window.open(href); window.open(href);
} }
...@@ -670,17 +700,19 @@ ...@@ -670,17 +700,19 @@
this.msg, this.msg,
(res) => { (res) => {
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
let data = res.data.data.pageData;; let data = res.data.data.pageData;
let addList = function(arr) { let addList = function(arr) {
arr.forEach(item => { arr.forEach(item => {
item.More = '' item.More = ''
item.actuallyReceived = false item.actuallyReceived = false
item.cost = '' item.cost = false
item.selectedType = ''
item.checkList = [] item.checkList = []
item.MultipleChoiceList = []
}); });
}; };
addList(data); addList(data);
this.dataList = res.data.data.pageData; this.dataList = data;
this.total = res.data.data.count; this.total = res.data.data.count;
this.loading = false this.loading = false
} else { } else {
......
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