Commit ed7751bd authored by 华国豪's avatar 华国豪 🙄

地接提成页面修改,新增一件制单

parent 32dabcd7
......@@ -12,23 +12,19 @@
<th width="120px">实际发放<br>15元/人</th>
<th width="120px">总合计</th>
<th v-for="(item, index) in dataList[0].OPCommissionDetailsList" :key="index">{{item.EmployeeName + item.CommissionPercent + '%'}}</th>
<th>{{$t('system.table_operation')}}</th>
<th width="80px">{{$t('system.table_operation')}}</th>
</tr>
<tr v-for="(item, index) in dataList" :key="index">
<td>{{item.BranchName}}</td>
<td>{{item.GuestNum}}</td>
<td>{{item.BranchId === -1 ? '合计' : item.BranchName}}</td>
<td>{{item.BranchId === -1 ? allGuestNum : item.GuestNum }}</td>
<td>{{15}}</td>
<td>{{item.GuestNum * 15}}</td>
<td>{{item.BranchId === -1 ? allGuestNum * 15 : item.GuestNum * 15}}</td>
<td v-for="(Sitem, Sindex) in item.OPCommissionDetailsList" :key="Sindex">{{Sitem.CommissionMoney}}</td>
<td>查看</td>
</tr>
<tr>
<td>合计</td>
<td>{{allGuestNum}}</td>
<td>{{15}}</td>
<td>{{allGuestNum * 15}}</td>
<td>{{}}</td>
<td></td>
<td>
<div style='width:80px;height:40px;text-align:center;position: relative;padding-top: 6px;padding-top:6px;'>
<el-button type="primary" size='mini' icon="el-icon-view" circle @click="getInfo(item,index)"></el-button>
</div>
</td>
</tr>
</table>
<div class="noDataNotice" v-if="dataList.length<1">
......@@ -51,24 +47,79 @@ export default {
allGuestNum: 0,
loading: false,
dataList: [],
list: [
{
name: 'xxx'
},{
name: 'yyy'
},{
name: 'ttt'
},{
name: 'uuu'
},{
name: 'iii'
},
]
empList: [],
oPComissionPeriods: {},
}
},mounted(){
this.msg.ID = this.$route.query.ID;
this.getList()
},
methods : {
//跳转
getInfo(item) {
this.$router.push({
path: "ClausesOrder",
query: {
StartDate: this.oPComissionPeriods.PeriodsDate,
blank:'y'
}
});
},
ZhiDan(data){
let msg={
TemplateId:27,
RB_Branch_Id:data.RB_Branch_Id,
IsPublic:6,
BType:4,
AccountId:22,
CostTypeID:189,
WBMoney:data.CommissionMoney,
Remark:'',
TCID:0,
IsRelevanceTravel:1,
OrderID:0,
vorcherInos:[],
Description:'',
RemitterName:'',
TradeDate:moment().format('YYYY-MM-DD'),
OrderSource:14,
};
this.$confirm('提成金额是否正确?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.loading = true;
this.apipost(
"Financial_post_SetFinanceInfoCommonForIn",
msg,
res => {
this.loading = false;
if (res.data.resultCode == 1) {
this.apipost(
"OPCommission_UpdatePeriodsFrID",
{ID:this.oPComissionPeriods.ID,FrId:res.data.data},
res => {
if (res.data.resultCode == 1) {
this.Success(res.data.message);
this.getList();
} else {
this.Error(res.data.message);
}
},
null
);
} else {
this.Error(res.data.message);
}
},
null
);
}).catch(() => {
});
},
getList() {
this.loading = true;
this.apipost(
......@@ -77,11 +128,18 @@ export default {
res => {
this.loading = false;
if (res.data.resultCode == 1) {
this.dataList = res.data.data.detailsList;
this.$forceUpdate()
} else {
this.Error(res.data.message);
}
this.dataList = res.data.data.detailsList;
this.empList = res.data.data.empList;
this.oPComissionPeriods=res.data.data.oPComissionPeriods;
let num = 0
this.dataList.forEach(x=>{
num = num + x.GuestNum
})
this.allGuestNum = num
this.$forceUpdate()
} else {
this.Error(res.data.message);
}
},
null
);
......
......@@ -7,15 +7,15 @@
</style>
<template>
<div class="flexOne">
<div class="query-box">
<!-- <div class="query-box">
<ul>
<li>
<input type="button" class="normalBtn" @click="goUrlZD(195)" value="签证制单"/>
<input type="button" class="normalBtn" @click="goUrlZD(196)" value="地接制单"/>
</li>
</ul>
</div>
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0">
</div> -->
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0" v-loading="loading">
<tr>
<th>期数</th>
<th>提成总金额</th>
......@@ -32,6 +32,9 @@
<!-- <el-tooltip class="item" effect="dark" content="取消" placement="top">
<el-button type="danger" icon="el-icon-delete" circle></el-button>
</el-tooltip> -->
<el-tooltip class="item" effect="dark" content="一键制单" placement="top">
<el-button @click="YijianZD(item)" type="danger" class="CM_look" icon="iconfont icon-mui-icon-add" circle></el-button>
</el-tooltip>
<el-tooltip class="item" effect="dark" content="查看" placement="top">
<el-button type="primary" class="CM_look" @click="goUrl('DjCommissionDetail',item.ID)" icon="iconfont icon-chakan" circle></el-button>
</el-tooltip>
......@@ -67,6 +70,31 @@
this.getList();
},
methods: {
YijianZD(item){
this.$confirm('提成金额是否正确?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.loading=true;
this.apipost(
"Financial_post_SetDiJieCommissionBetchImport",
{PeriodsId:item.ID},
res => {
if(res.data.resultCode==1){
this.Success(res.data.message)
this.getList();
}else{
this.loading=false;
this.Error(res.data.message)
}
},
null
);
}).catch(() => {
});
},
goUrlZD(num){
let orderObj = {
OrderID: 0,
......
......@@ -417,7 +417,7 @@ export default {
{
path: '/DjCommissionDetail', //提成详情
name: 'DjCommissionDetail',
component: resolve => require(['@/components/administrative/DjCommissionDetail'], resolve),
component: resolve => require(['@/components/administrative/DjCommissionDetail2'], resolve),
meta: {
title: '提成详情'
},
......
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