Commit 4886b493 authored by 黄奎's avatar 黄奎

购物店生成财务单据修改

parent 1370bf4d
...@@ -142,12 +142,12 @@ ...@@ -142,12 +142,12 @@
{{subItem.Remarks}} {{subItem.Remarks}}
</td> </td>
<td :rowspan="item.ShopDetailsList.length" v-if='subIndex==0' style=""> <td :rowspan="item.ShopDetailsList.length" v-if='subIndex==0' style="">
<div > <div>
<p style="cursor: pointer;color:blue;margin-top:10px;" @click="CreateHandBill(outItem)">手动生成单据</p> <p style="cursor: pointer;color:blue;margin-top:10px;" @click="CreateHandBill(outItem)">手动生成单据</p>
</div> </div>
</td> </td>
<td :rowspan="outItem.rowspanCount" v-if="index==0&&subIndex==0"> <td :rowspan="outItem.rowspanCount" v-if="index==0&&subIndex==0">
<p style="cursor: pointer;color:blue;" @click="CreateBill(item.ShopDetailsList,outItem)">生成单据</p> <p style="cursor: pointer;color:blue;" @click="isShowFinaceDailog=true,CurrentOutItem=outItem">生成单据</p>
<p style="cursor: pointer;color:blue;margin-top:5px;" <p style="cursor: pointer;color:blue;margin-top:5px;"
@click="goHuiZhi(outItem.TCIDs, item.LeaderName, item.GuideName, item.StartCityNames, item.TCNUMS)"> @click="goHuiZhi(outItem.TCIDs, item.LeaderName, item.GuideName, item.StartCityNames, item.TCNUMS)">
选择购物店</p> 选择购物店</p>
...@@ -206,6 +206,22 @@ ...@@ -206,6 +206,22 @@
</div> </div>
</template> </template>
</el-dialog> </el-dialog>
<el-dialog title="生成财务单据" :visible.sync="isShowFinaceDailog" custom-class='w400' center>
<template>
<el-form label-width="100px">
<el-form-item label="付款方式">
<el-select v-model="PayType">
<el-option label="常规付款" :value="1" :key="1"></el-option>
<el-option label="资金池付款" :value="2" :key="2"></el-option>
</el-select>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<button class="hollowFixedBtn" @click="isShowFinaceDailog=false,CurrentOutItem={}">{{$t('pub.cancelBtn')}}</button>
<button class="normalBtn" type="primary" @click="CreateBill()">{{$t('pub.sureBtn')}}</button>
</div>
</template>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
...@@ -213,6 +229,7 @@ ...@@ -213,6 +229,7 @@
data() { data() {
return { return {
loading: false, loading: false,
PayType:1,//付款方式
msg: { msg: {
pageIndex: 1, pageIndex: 1,
pageSize: 8, pageSize: 8,
...@@ -230,14 +247,16 @@ ...@@ -230,14 +247,16 @@
shopDataList: [], shopDataList: [],
CreateHandBillList: [], CreateHandBillList: [],
zhuanjiaoBox: false, zhuanjiaoBox: false,
isShowFinaceDailog:false,//是否显示生成财务单据对话框
CreateHandBillID: '', CreateHandBillID: '',
CreateHandObj: {}, CreateHandObj: {},
CurrentOutItem:{}//当前选中的团
} }
}, },
methods: { methods: {
goCreateHandBill: function () { goCreateHandBill: function () {
let obj = {} let obj = {}
for(let i = 0; i < this.CreateHandBillList.length; i++) { for (let i = 0; i < this.CreateHandBillList.length; i++) {
if (this.CreateHandBillList[i].id == this.CreateHandBillID) { if (this.CreateHandBillList[i].id == this.CreateHandBillID) {
obj = this.CreateHandBillList[i] obj = this.CreateHandBillList[i]
} }
...@@ -264,7 +283,7 @@ ...@@ -264,7 +283,7 @@
CreateHandBill: function (obj) { CreateHandBill: function (obj) {
this.CreateHandObj = obj this.CreateHandObj = obj
let newList = [] let newList = []
for(let i = 0 ; i < obj.TCList.length; i++) { for (let i = 0; i < obj.TCList.length; i++) {
newList.push({ newList.push({
TCID: obj.TCList[i].TCID, TCID: obj.TCList[i].TCID,
id: obj.TCList[i].TCNUMS, id: obj.TCList[i].TCNUMS,
...@@ -375,7 +394,7 @@ ...@@ -375,7 +394,7 @@
}, err => {}) }, err => {})
}, },
//生成单据 //生成单据
CreateBill(ShopDetailsList, outItem) { CreateBill() {
var that = this; var that = this;
this.Confirm('是否生成财务单据?', function () { this.Confirm('是否生成财务单据?', function () {
that.loading = true; that.loading = true;
...@@ -404,18 +423,19 @@ ...@@ -404,18 +423,19 @@
// } // }
// }, err => {}) // }, err => {})
var nMsg={ var nMsg = {
TCIDs:outItem.TCIDs, TCIDs: that.CurrentOutItem.TCIDs,
PayType:that.PayType,
uid: that.getLocalStorage().EmployeeId uid: that.getLocalStorage().EmployeeId
}; };
let fileName = "生成[" + outItem.NewCombinationNum + "]购物店数据.xls"; let fileName = "生成[" + that.CurrentOutItem.NewCombinationNum + "]购物店数据.xls";
that.GetLocalFile("dmcstatistics_post_ShopCreateBillAndExport", nMsg, fileName, that.GetLocalFile("dmcstatistics_post_ShopCreateBillAndExport", nMsg, fileName,
res => { res => {
that.loading = false; that.loading = false;
this.isShowFinaceDailog=false;
that.Success("导入成功!"); that.Success("导入成功!");
that.getList(); that.getList();
}); });
}); });
}, },
}, },
...@@ -428,6 +448,7 @@ ...@@ -428,6 +448,7 @@
"-" + "-" +
myDate.getDate(); myDate.getDate();
this.msg.StartDate = nowDate; this.msg.StartDate = nowDate;
//this.msg.StartDate = '2019-06-26'
this.getLineList(); this.getLineList();
this.getList(); this.getList();
}, },
......
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