Commit 6018a522 authored by 华国豪's avatar 华国豪 🙄
parents 21ea7596 f9c3be49
<template>
<div class="Feedback">
<ul style="overflow: initial!important">
<!-- <li>
<span>
<em>公司</em>
</span>
<el-select filterable v-model="obj.BranchId" >
<el-option label="不限" :value='-1'></el-option>
<el-option v-for="item in companyList" :label='item.BName' :value='item.Id' :key='item.Id'>
</el-option>
</el-select>
</li>
<li>
<span>
<em>线路</em>
</span>
<el-select filterable v-model="obj.LineId" >
<el-option label="不限" :value='0'></el-option>
<el-option v-for="item in LineList" :label='item.LineName' :value='item.LineID' :key='item.LineID'></el-option>
</el-select>
</li> -->
<li style="float:right;margin-bottom:10px">
<!-- <input
type="button"
class="hollowFixedBtn"
value="查询"
@click="getList()"
> -->
<input
type="button"
class="hollowFixedBtn"
value="新增"
@click="addRule"
>
</li>
</ul>
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0" v-loading="loading">
<tr>
<th style="width:30%">线路名称</th>
<th>人员</th>
<th>占比</th>
<th>设置</th>
</tr>
<tr>
<td>全部</td>
<td>地接账户基金</td>
<td>{{allzb}}%</td>
<td>
<!-- <el-button @click="SetRules(item)" style="padding:4px" type="primary" icon="el-icon-edit" circle></el-button>
<el-button @click="Delete(item)" style="padding:4px" type="danger" icon="el-icon-delete" circle></el-button> -->
</td>
</tr>
<tbody v-for="(item,i) in dataList" :key="i">
<tr v-for="(com,index) in item.OPCommissionList" :key="index">
<td :rowspan="item.OPCommissionList.length" v-if="index==0">{{item.LineName}}</td>
<td>{{com.EmployeeName}}</td>
<td>{{com.CommissionPercent}}%</td>
<td>
<el-button @click="SetRules(com)" style="padding:4px" type="primary" icon="el-icon-edit" circle></el-button>
<el-button @click="Delete(com)" style="padding:4px" type="danger" icon="el-icon-delete" circle></el-button>
</td>
</tr>
</tbody>
<tr v-if="dataList.length==0">
<td colspan="12" align="center">暂无数据</td>
</tr>
</table>
<el-dialog
title="提成规则"
:visible.sync="ruleVisible"
width="400px">
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
<!-- <el-form-item label="线路" prop="LineIdList">
<el-select class="multiple_input" filterable value-key="item" v-model="form.LineIdList" @change="getLine">
<el-option v-for="item in LineList" :label='item.LineName' :value='item' :key='item.LineID'></el-option>
</el-select>
</el-form-item> -->
<el-form-item label="人员" prop="EmployeeId">
<el-select class="multiple_input" filterable v-model="form.EmployeeId" >
<el-option v-for="item in EmployeeList" :label="item.EmName"
:value="item.EmployeeId" :key="item.EmployeeId"></el-option>
</el-select>
</el-form-item>
<el-form-item label="占比" prop="CommissionPercent">
<el-input class="w220" @keyup.native="checkInteger(form,'CommissionPercent')" v-model="form.CommissionPercent"></el-input>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="ruleVisible = false">取 消</el-button>
<el-button size="small" type="danger" @click="RulesOk('form')">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import moment from "moment"
import { constants } from 'fs';
export default {
name: 'Feedback',
data (){
return{
allzb:100,
obj:{
BranchId:-1,
LineId:0,
},
dataList:[],
loading:false,
dateList:[],
LineList:[],
companyList:[],
ruleVisible:false,
form:{
// LineIdList:[],
LineName:'出境日本线',
LineID:14,
EmployeeId:'',
CommissionPercent:0,
},
departmentMsg: {
RB_Group_Id: '0',
RB_Branch_Id:'-1',
Status:'0',
ParentId:'-1',
Tier:'0',
},
LineTeamList:[],
EmployeeList:[],
rules:{
EmployeeId: [
{ required: true, message: '请选择参与人员', trigger: 'change' }
],
CommissionPercent: [{ required: true, message: "请输入占比", trigger: "blur" }],
},
departmentList:[]
}
},
created(){
},
mounted(){
this.getList();
this.getEmployeeList();
this.getLineList();
},
methods:{
Delete(item) {
this.$confirm("是否删除? 删除后不可恢复", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
})
.then(() => {
this.apipost('OPCommission_RemoveOPCommission', {ID:item.Id}, res => {
if (res.data.resultCode == 1) {
this.Success(res.data.message)
this.getList()
}else{
this.Error(res.data.message)
}
})
})
.catch(() => {});
},
addRule(){
this.ruleVisible=true;
this.form={
LineName:'出境日本线',
LineID:14,
EmployeeId:'',
CommissionPercent:0,
}
},
SetRules(item){
this.ruleVisible=true;
this.form={
LineName:'出境日本线',
LineID:14,
EmployeeId:item.EmployeeId,
CommissionPercent:item.CommissionPercent,
Id:item.Id
}
},
RulesOk(formName){
this.$refs[formName].validate((valid) => {
if (valid) {
let num=0;
let newnum=0;
if(this.form.Id){
this.dataList.forEach(item=>{
item.OPCommissionList.forEach(com=>{
if(com.Id!=this.form.Id){
num+=com.CommissionPercent;
}
})
})
newnum=100-num;
}else{
newnum=this.allzb;
}
if(Number(this.form.CommissionPercent)>newnum || Number(this.form.CommissionPercent)==0){
this.Error("请输入正确的占比!");
return;
}
this.apipost(
'OPCommission_SetOPCommission', this.form,
res => {
if (res.data.resultCode == 1) {
this.getList();
this.ruleVisible=false;
this.Success(res.data.message)
}else{
this.Error(res.data.message)
}
},
err => {
}
)
} else {
}
});
},
getEmployeeList () {
let userInfo = this.getLocalStorage()
let msg = {
GroupId: userInfo.RB_Group_id,
BranchId: '-1',
DepartmentId: '-1',
PostId: '-1',
IsLeave: '0'
}
this.apipost(
'admin_get_EmployeeGetList', {},
res => {
if (res.data.resultCode == 1) {
this.EmployeeList = res.data.data
}
},
err => {
}
)
},
getLineList() {
this.apipost("line_post_GetAllList_V2", {LineDirection: 0}, res => {
if (res.data.resultCode == 1) {
this.LineList = res.data.data;
}
});
},
linkageDepartment(){
this.departmentMsg.RB_Branch_Id=this.form.BranchId;
this.departmentList=[];
this.form.DepartmentId=-1;
this.getDepartment();
},
getDepart(id){
this.form.DepartmentId= id;
this.$forceUpdate();
},
getDepartment() {
this.apipost('admin_get_DepartmentGetList', this.departmentMsg, res => {
if(res.data.resultCode == 1) {
this.departmentList = res.data.data;
}
}, err => {})
},
getList(){
this.loading=true;
this.apipost("OPCommission_GetPageList", {}, res => {
this.loading=false;
if (res.data.resultCode == 1) {
this.dataList = res.data.data;
console.log("this.dataList",this.dataList)
// allzb
let num=0;
this.dataList.forEach(item=>{
item.OPCommissionList.forEach(com=>{
num+=com.CommissionPercent;
})
})
this.allzb=100-num;
}
});
},
}
}
</script>
<style>
.Feedback ul>li{
display: inline-block;
font-size: 12px;
color: #666;
margin: 20px 30px 0px 0;
}
.Feedback .singeRowTable{
margin-top: 20px;
}
</style>
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
placeholder="选择月"> placeholder="选择月">
</el-date-picker> </el-date-picker>
</li> </li>
<li> <li v-show="btnShow">
<el-button size="mini" type="danger" style="border-radius:14px" :loading="btnLoading" @click="generateTable">生成提成</el-button> <el-button size="mini" type="danger" style="border-radius:14px" :loading="btnLoading" @click="generateTable">生成提成</el-button>
<!-- <input v-loading="btnLoading" type="button" class="normalBtn" @click="generateTable" value="生成提成"/> --> <!-- <input v-loading="btnLoading" type="button" class="normalBtn" @click="generateTable" value="生成提成"/> -->
</li> </li>
...@@ -72,9 +72,16 @@ import moment from "moment" ...@@ -72,9 +72,16 @@ import moment from "moment"
total:0, total:0,
currentPage: 1, currentPage: 1,
btnLoading:false, btnLoading:false,
btnShow:false,
} }
}, },
mounted() { mounted() {
let userInfo = this.getLocalStorage();
let ActionMenuCode=userInfo.ActionMenuCode;
if(ActionMenuCode.indexOf('P_OPCommissionSend')!=-1){
this.btnShow=true;
}
this.getList(); this.getList();
}, },
methods: { methods: {
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
</li> </li>
<li> <li>
<button class="hollowFixedBtn" @click="getList">{{$t('pub.searchBtn')}}</button> <button class="hollowFixedBtn" @click="getList">{{$t('pub.searchBtn')}}</button>
<button class="hollowFixedBtn" @click="method5()">导出</button>
</li> </li>
</ul> </ul>
</div> </div>
...@@ -120,6 +120,16 @@ ...@@ -120,6 +120,16 @@
this.getList(); this.getList();
}, },
methods: { methods: {
method5: function() {
let msg = JSON.parse(JSON.stringify(this.msg));
delete msg.pageIndex;
delete msg.pageSize;
this.GetLocalFile(
"sellcommission_post_GetOPCommissionSingleDetailsListToExcel",
msg,
"OP提成明细.xls"
);
},
goUrl(item){ goUrl(item){
this.$router.push({ this.$router.push({
path: "productQuery", path: "productQuery",
......
...@@ -526,6 +526,10 @@ ...@@ -526,6 +526,10 @@
</div> </div>
</div> </div>
<div class="TC_remarkContent"> <div class="TC_remarkContent">
<div class="clearfix TCL-redType">
<div class="TCL_remarkTitle">地接备注团号:</div>
<div class="TCL_Content"> {{item.CombinationNum}}</div>
</div>
<div class="clearfix TCL-redType"> <div class="clearfix TCL-redType">
<div class="TCL_remarkTitle">OP对外备注:</div> <div class="TCL_remarkTitle">OP对外备注:</div>
<div class="TCL_Content">{{item.OPRemark}}</div> <div class="TCL_Content">{{item.OPRemark}}</div>
......
...@@ -621,9 +621,13 @@ ...@@ -621,9 +621,13 @@
</tr> </tr>
<tr> <tr>
<td>签约日期:</td> <td>签约日期:</td>
<td>{{getDate(dataList.payDate)}}</td> <td>
<span v-if="dataList.payDate">{{getDate(dataList.payDate)}}</span>
</td>
<td>签约日期:</td> <td>签约日期:</td>
<td>{{getDate(dataList.payDate)}}</td> <td>
<span v-if="dataList.payDate">{{getDate(dataList.payDate)}}</span>
</td>
</tr> </tr>
<tr> <tr>
<td>签约地点:</td> <td>签约地点:</td>
......
...@@ -987,7 +987,7 @@ ...@@ -987,7 +987,7 @@
<div>备注:1、在主要景点的游览时间不小于此数的时间,以小时填; 2、交通工具不含景区观光车、索道等; 3、“交通工具”栏中的“标准”按各类别的标准填写。</div> <div>备注:1、在主要景点的游览时间不小于此数的时间,以小时填; 2、交通工具不含景区观光车、索道等; 3、“交通工具”栏中的“标准”按各类别的标准填写。</div>
<div>飞机:头等舱/商务舱/经济舱;&nbsp;&nbsp;&nbsp;汽车:空调大巴/空调卧铺/普通客车</div> <div>飞机:头等舱/商务舱/经济舱;&nbsp;&nbsp;&nbsp;汽车:空调大巴/空调卧铺/普通客车</div>
<div>火车:普通车/空调车/动车组(其中:软卧/硬卧/软座/硬座);</div> <div>火车:普通车/空调车/动车组(其中:软卧/硬卧/软座/硬座);</div>
<div>轮船:普通客船/星级游船 &nbsp;&nbsp;&nbsp;人/间(其中:□带卫生间 □不带卫生间)</div> <div>轮船:普通客船/星级游船 &nbsp;&nbsp;&nbsp;人/间</div>
</td> </td>
</tr> </tr>
</tbody> </tbody>
...@@ -1409,16 +1409,6 @@ ...@@ -1409,16 +1409,6 @@
this.CtObj.regulatorName = '四川省成都市旅游质监执法机构'; this.CtObj.regulatorName = '四川省成都市旅游质监执法机构';
this.CtObj.regulatorComplainCall = '17708046437'; this.CtObj.regulatorComplainCall = '17708046437';
this.CtObj.companyComplainCall = '028-96927'; this.CtObj.companyComplainCall = '028-96927';
this.CtObj.clientName=this.guestList[0].surName+''+this.guestList[0].name;
let clientIdcardnum = this.guestList[0].idCard;
if(clientIdcardnum.length<18){
this.CtObj.clientIdcardnum=this.guestList[0].passportNo;
}else{
this.CtObj.clientIdcardnum=this.guestList[0].idCard;
}
this.CtObj.clientCall=this.guestList[0].mobilePhone;
this.CtObj.clientAddress=this.guestList[0].addressDetail;
} else { } else {
this.Error(res.data.message); this.Error(res.data.message);
} }
......
<style>
.CM_look{
padding:4px!important;
position: relative;
top:1px;
}
</style>
<template>
<div class="flexOne">
<!-- <div class="query-box">
<ul>
<li>
<input type="button" class="normalBtn" @click="generateTable" value="生成提成报表"/>
</li>
</ul>
</div> -->
<table v-loading="loading" class="singeRowTable" border="0" cellspacing="0" cellpadding="0">
<tr>
<th>订单号</th>
<th>团号</th>
<th>旅客数</th>
<th>销售名称</th>
</tr>
<tr v-for="(item,index) in dataList" :key="index">
<td>{{item.OrderId}}</td>
<td>{{item.TCNUM}}</td>
<td>{{item.GuestNum}}</td>
<td>{{item.CreateByName}}</td>
<!-- <td>
<el-tooltip class="item" effect="dark" content="查看" placement="top">
<el-button type="primary" class="CM_look" @click="goUrl('CommissionDetail',item.id)" icon="iconfont icon-chakan" circle></el-button>
</el-tooltip>
</td> -->
</tr>
<tr>
<td v-show="dataList.length==0" colspan="4" align="center">暂无数据</td>
</tr>
</table>
<!-- 分页 -->
<el-pagination background @current-change="handleCurrentChange" :current-page.sync="currentPage"
layout="total,prev, pager, next, jumper" :page-size='msg.PageSize' :total='total'>
</el-pagination>
</div>
</template>
<script>
export default {
data() {
return {
msg: {
PageIndex: 1,
PageSize: 20,
StartDate:'',
},
loading:false,
//数据源
dataList:[],
total:0,
currentPage: 1,
}
},
mounted() {
this.msg.StartDate=this.$route.query.StartDate;
this.getList();
},
methods: {
handleCurrentChange(val) {
this.msg.PageIndex = val;
this.getList();
},
goUrl(path,id) {
this.$router.push({
path: path,
query: {
ParentId:id,
blank: 'y',
tab: '报价详情'
}
});
},
//获取数据
getList() {
this.loading = true;
this.apipost(
"OPCommission_GetCommissionOrderPageList",
this.msg,
res => {
this.loading = false;
if(res.data.resultCode==1){
this.dataList = res.data.data.pageData;
this.total = res.data.data.count;
}else{
this.Error(res.data.message);
}
},
null
);
},
//生成提成报表
generateTable(){
let msg = {
UserId: 0
}
this.apipost(
"sellcommission_SetGenerateCommission",msg,
res => {
if(res.data.resultCode==1){
this.getList();
this.Success('报表生成成功')
}else{
this.Error(res.data.message);
}
},
null
);
}
}
}
</script>
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<th>日期</th> <th>日期</th>
<th>{{$t('system.table_operation')}}</th> <th>{{$t('system.table_operation')}}</th>
</tr> </tr>
<tr v-for="item in dataList"> <tr v-for="(item,index) in dataList" :key="index">
<td>{{item.periods}}</td> <td>{{item.periods}}</td>
<td>{{item.sumPrice}}</td> <td>{{item.sumPrice}}</td>
<td>{{item.createByStr}}</td> <td>{{item.createByStr}}</td>
......
<template>
<div class="commissionDetails-box">
<div class="query-box">
<ul>
<li>
<!-- <input type="button" class="normalBtn" value="导出" @click="exportExcel"> -->
</li>
</ul>
</div>
<v-table
v-if="isReady"
is-horizontal-resize
column-width-drag
style="width:100%"
:columns="columns"
:table-data="dataList"
:filter-method="filterMethod"
:total="total"
:pageSize="msg.pageSize"
:pageIndex="msg.pageIndex"
:handleCurrentChange="handleCurrentChange"
:multiple-sort="multipleSort"
:is-loading="loading"
sort-always
@on-custom-comp="customCompFunc"
></v-table>
<div style="height:20px;"> </div>
<!-- @sort-change="sortChange" -->
</div>
</template>
<script>
import moment from "moment"
import Vue from 'vue'
import XLSX from 'xlsx'
var FileSaver = require('file-saver')
export default {
data() {
return {
activeName: "first",
commonName: "姓名",
loading: false,
msg: {
pageIndex: 1,
pageSize: 20,
ParentId: 0,
OrderStr: "RB_Branch_Id asc",
BName:-1
},
total: 0,
currentPage: 1,
columns: [],
remoteLoading: false,
total: 0,
dataList: [],
isReady: false,
multipleSort: false,
loading: true,
CompanyList:[],
dataListTwo: [],
stringPerons:'',
oPComissionPeriods:{},
};
},
methods: {
exportExcel(){
const defaultCellStyle = {'!cols': [{wpx: 60}, {wpx: 200}, {wpx: 60}, {wpx: 150},{wpx:60}]};
const wopts = { bookType:'xlsx', bookSST:false, type:'binary', defaultCellStyle: defaultCellStyle, showGridLines: true};
const wb = { SheetNames: ['提成统计'], Sheets: {}, Props: {} };
let data = []
this.dataList.forEach(x=>{
let obj={
'公司':x.bName,
'部门':x.departmentName,
'员工':x.createByStr,
'提成金额':x.commissionMoney.toFixed(2),
'额外奖励':x.otherMoney.toFixed(2),
'额外扣除':x.backMoney.toFixed(2),
'应发提成':x.sumMoney.toFixed(2),
'收客数':x.peopleCount,
'单签证人数':x.visaPeopleCount,
'所属期数':x.periods
}
data.push(obj)
})
wb.Sheets['提成统计'] = XLSX.utils.json_to_sheet(data)
//创建二进制对象写入转换好的字节流
let tmpDown = new Blob([this.s2ab(XLSX.write(wb, wopts))], { type: "application/octet-stream" })
FileSaver.saveAs(tmpDown, "提成统计.xls");
},
s2ab (s) {
if (typeof ArrayBuffer !== 'undefined') {
var buf = new ArrayBuffer(s.length);
var view = new Uint8Array(buf);
for (var i = 0; i != s.length; ++i) view[i] = s.charCodeAt(i) & 0xFF;
return buf;
} else {
var buf = new Array(s.length);
for (var i = 0; i != s.length; ++i) buf[i] = s.charCodeAt(i) & 0xFF;
return buf;
}
},
filterMethod(filters){
let data = JSON.parse(JSON.stringify(this.dataListTwo))
let dataListTwo = JSON.parse(JSON.stringify(this.dataListTwo))
if (filters.BranchName!='' && filters.BranchName!='__all__'){
data = data.filter(item => item.BranchName.indexOf(filters.BranchName)!=-1);
}
if (filters.DepartmentName!=''){
data = data.filter(item => item.DepartmentName.indexOf(filters.DepartmentName)!=-1);
}
if (filters.EmployeeName!=''){
data = data.filter(item => item.EmployeeName.indexOf(filters.EmployeeName)!=-1);
}
if ((filters.BranchName === '' || filters.BranchName==='__all__') && filters.DepartmentName === '' && filters.EmployeeName === ''){
data = dataListTwo
}
this.dataList = data
},
customCompFunc(params) {
if (params.type === "see") {
this.getInfo(params.data)
}else{
this.voucher(params.data)
}
},
voucher(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(() => {
});
},
getCompanyList() {
//获取公司列表
this.apipost(
"admin_get_BranchGetList",
this.getCompanyMsg,
res => {
if (res.data.resultCode == 1) {
let data = res.data.data;
data.forEach(x => {
x.disabled = false;
});
this.CompanyList = data;
} else {
}
},
err => {}
);
},
initColums() {
let oPComissionPeriods=this.oPComissionPeriods;
this.isReady = false;
let that = this;
let companyList = [];
this.CompanyList.forEach(x => {
let item = {};
item.label = x.BName;
item.value = x.BName;
companyList.push(item);
});
let company = {
field: "BranchName",
title: "公司",
width: 40,
titleAlign: "left",
columnAlign: "left",
isResize: true,
result: "",
filterMultiple: false,
filters: companyList,
type: "select"
// filterMultiple: false,
// filters: companyList,
// result: "",
// type: "select",
// orderBy: "asc"
// isFrozen:true
};
let department = {
field: "DepartmentName",
title: "部门",
width: 80,
titleAlign: "left",
columnAlign: "left",
isResize: true,
result: "",
filterMultiple: false,
filters: companyList,
type: "text"
};
let userName = {
field: "EmployeeName",
title: "姓名",
titleAlign: "left",
columnAlign: "left",
isResize: true,
width: 80,
result: "",
filterMultiple: false,
filters: [{}],
type: "text"
};
let CommissionMoney = {
field: "CommissionMoney",
title: "提成金额",
titleAlign: "left",
columnAlign: "left",
isResize: true,
width: 80,
formatter: function(rowData, rowIndex, pagingIndex, field) {
return `<span>${rowData.CommissionMoney.toFixed(2)}</span>`
}
};
let Zhanbi = {
field: "CommissionPercent",
title: "占比",
titleAlign: "left",
columnAlign: "left",
isResize: true,
width: 80,
formatter: function(rowData, rowIndex, pagingIndex, field) {
return `<span>${rowData.CommissionPercent}%</span>`
}
};
let remark = {
field: "remark",
title: "备注",
titleAlign: "left",
columnAlign: "left",
isResize: true,
width: 80,
componentName: "commission-table-beizhu"
// formatter: function(rowData, rowIndex, pagingIndex, field) {
// return `<span v-if="${rowData.EmployeeId==0 && oPComissionPeriods.FRID>0}">
// <span>${rowData.EmployeeId}</span>
// 单据号:${oPComissionPeriods.FRID}</span>`;
// }
};
let opera = {
title: "操作",
titleAlign: "left",
columnAlign: "left",
width: 80,
isResize: false,
componentName: "commission-table-operation"
};
this.columns = [];
this.columns.push(company);
this.columns.push(department);
this.columns.push(userName);
this.columns.push(CommissionMoney);
// this.columns.push(otherMoney);
// this.columns.push(backMoney);
// this.columns.push(sumMoney);
// this.columns.push(peopleCount);
// this.columns.push(visaPeopleCount);
this.columns.push(Zhanbi);
this.columns.push(remark);
this.columns.push(opera);
this.isReady = true;
},
sortChange(param) {
if(param.sumMoney==''){
if(param.BName!=''){
this.msg.OrderStr='RB_Branch_Id '+param.bName
}
if(param.commissionMoney!=''){
this.msg.OrderStr='CommissionMoney '+param.commissionMoney
}
if(param.peopleCount!=''){
this.msg.OrderStr='PeopleCount '+param.peopleCount
}
if(param.backMoney!=''){
this.msg.OrderStr='BackMoney '+param.backMoney
}
if(param.otherMoney!=''){
this.msg.OrderStr='OtherMoney '+param.otherMoney
}
this.getList();
}else{
let d=JSON.parse(JSON.stringify(this.dataList))
this.dataList = this.orderBy(d, ["sumMoney"], param.sumMoney).results;
}
},
handleCurrentChange(val) {
this.msg.pageIndex = val;
this.getList();
},
getList() {
this.loading = true;
this.apipost(
"OPCommission_GetPeriodsDetailsList",
this.msg,
res => {
this.loading = false;
if (res.data.resultCode == 1) {
let data = res.data.data.data;
this.oPComissionPeriods=res.data.data.oPComissionPeriods;
data.forEach(item=>{
item.FRID=this.oPComissionPeriods.FRID;
item.PeriodsDate=this.oPComissionPeriods.PeriodsDate;
})
this.total = res.data.data.data.length;
this.dataList = data;
// this.dataList.forEach(x=>{
// x.sumMoney=x.commissionMoney+x.otherMoney-x.backMoney
// })
this.dataListTwo = JSON.parse(JSON.stringify(this.dataList))
this.initColums();
} else {
this.Error(res.data.message);
}
},
null
);
},
//切换排序
handleClick(tab, event) {
if (this.activeName == "first") {
// this.commonName='姓名'
this.msg.OrderStr = "UserId";
} else {
// this.commonName='公司名'
this.msg.OrderStr = "RB_Branch_Id";
}
this.getList();
},
//跳转
getInfo(item) {
this.$router.push({
path: "ClausesOrder",
query: {
StartDate: item.PeriodsDate,
blank:'y'
}
});
}
},
mounted() {
this.msg.pageSize = 10000; //不分页
this.msg.ID = this.$route.query.ID;
let dt=new Date()
this.stringPerons=(dt.getMonth()==0?(dt.getFullYear()-1):dt.getFullYear())+''+(dt.getMonth().toString().length<2?'0':'')+(dt.getMonth()==0?12:dt.getMonth());
this.getList();
this.getCompanyList();
},
created(){
Vue.component('commission-table-beizhu',{
template:` <span v-if="rowData.EmployeeId==0 && rowData.FRID>0">
单据号:{{rowData.FRID}}</span>`,
props:{
rowData:{
type:Object
},
field:{
type:String
},
index:{
type:Number
}
},
created(){
},
methods:{
see(){
let params = {type:'see',data:this.rowData};
this.$emit('on-custom-comp',params);
},
ZhiDan(){
let params = {type:'zhidan',data:this.rowData};
this.$emit('on-custom-comp',params);
},
}
})
Vue.component('commission-table-operation',{
template:`<div style='width:80px;height:40px;background:#fff;text-align:center;position: relative;left:-5px;padding-top: 6px;padding-top:6px;'>
<el-button v-if="rowData.EmployeeId==0 && rowData.FRID==0" type="danger" size='mini' icon="el-icon-document" circle @click="ZhiDan(rowData,index)"></el-button>
<el-button type="primary" size='mini' icon="el-icon-view" circle @click="see(rowData,index)"></el-button>
</div>`,
props:{
rowData:{
type:Object
},
field:{
type:String
},
index:{
type:Number
}
},
methods:{
see(){
let params = {type:'see',data:this.rowData};
this.$emit('on-custom-comp',params);
},
ZhiDan(){
let params = {type:'zhidan',data:this.rowData};
this.$emit('on-custom-comp',params);
},
}
})
}
};
</script>
<style>
.commissionDetails-box .el-button.is-circle{padding: 5px !important;}
.commissionDetails-box .v-table-body-cell span {
display: block;
width: 100%;
}
</style>
<style>
.CM_look{
padding:4px!important;
position: relative;
top:1px;
}
</style>
<template>
<div class="flexOne">
<!-- <div class="query-box">
<ul>
<li>
<input type="button" class="normalBtn" @click="generateTable" value="生成提成报表"/>
</li>
</ul>
</div> -->
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0">
<tr>
<th>期数</th>
<th>提成总金额</th>
<th>{{$t('admin.admin_czPerson')}}</th>
<th>日期</th>
<th>{{$t('system.table_operation')}}</th>
</tr>
<tr v-for="(item,index) in dataList" :key="index">
<td>{{item.Periods}}</td>
<td>{{item.SumPrice}}</td>
<td>{{item.CreateByStr}}</td>
<td>{{item.CreateStr}}</td>
<td>
<!-- <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 type="primary" class="CM_look" @click="goUrl('DjCommissionDetail',item.ID)" icon="iconfont icon-chakan" circle></el-button>
</el-tooltip>
</td>
</tr>
<tr v-if="dataList.length==0">
<td colspan="5" align="center">暂无数据</td>
</tr>
</table>
<!-- 分页 -->
<el-pagination background @current-change="handleCurrentChange" :current-page.sync="currentPage"
layout="total,prev, pager, next, jumper" :page-size='msg.PageSize' :total='total'>
</el-pagination>
</div>
</template>
<script>
export default {
data() {
return {
msg: {
PageIndex: 1,
PageSize: 20
},
loading:false,
//数据源
dataList:[],
total:0,
currentPage: 1,
}
},
mounted() {
this.getList();
},
methods: {
handleCurrentChange(val) {
this.msg.PageIndex = val;
this.getList();
},
goUrl(path,id) {
this.$router.push({
path: path,
query: {
ID:id,
blank: 'y',
tab: '详情'
}
});
},
//获取数据
getList() {
this.loading = true;
this.apipost(
"OPCommission_GetPeriodsPageList",
this.msg,
res => {
this.loading = false;
if(res.data.resultCode==1){
this.dataList = res.data.data.pageData;
this.total = res.data.data.count;
}else{
this.Error(res.data.message);
}
},
null
);
},
//生成提成报表
generateTable(){
let msg = {
UserId: 0
}
this.apipost(
"sellcommission_SetGenerateCommission",msg,
res => {
if(res.data.resultCode==1){
this.getList();
this.Success('报表生成成功')
}else{
this.Error(res.data.message);
}
},
null
);
}
}
}
</script>
...@@ -157,7 +157,7 @@ export default { ...@@ -157,7 +157,7 @@ export default {
//跳转至详情 //跳转至详情
goToDetail(item){ goToDetail(item){
this.$router.push({ this.$router.push({
name: 'ElectronicContract', name: 'TravelContractDetail',
query: { query: {
TCID: item.tcid, TCID: item.tcid,
orderID: item.orderId, orderID: item.orderId,
......
...@@ -285,7 +285,7 @@ ...@@ -285,7 +285,7 @@
<el-table-column label="付款方式" min-width="150"> <el-table-column label="付款方式" min-width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<div v-for="subItem in scope.row.BusPlanOrderList" class="comBTM"> <div v-for="subItem in scope.row.BusPlanOrderList" class="comBTM">
<el-select class='sel' v-model='subItem.PayType' :placeholder="$t('pub.pleaseSel')" <el-select class='sel' v-model='subItem.PayType' :disabled="isShowBtn==1?true:false" :placeholder="$t('pub.pleaseSel')"
@change="PayTypeChange(scope.row)"> @change="PayTypeChange(scope.row)">
<el-option label='请选择' :value='0'></el-option> <el-option label='请选择' :value='0'></el-option>
<el-option label='现付' :value='1'></el-option> <el-option label='现付' :value='1'></el-option>
...@@ -382,7 +382,7 @@ ...@@ -382,7 +382,7 @@
<el-table-column label="成本价" min-width="140"> <el-table-column label="成本价" min-width="140">
<template slot-scope="scope"> <template slot-scope="scope">
<div v-for="subItem in scope.row.BusPlanOrderList" class="comBTM"> <div v-for="subItem in scope.row.BusPlanOrderList" class="comBTM">
<el-input v-model="subItem.CostPrice" @keyup.native="checkPrice(subItem,'CostPrice')" <el-input v-model="subItem.CostPrice" :disabled="isShowBtn==1?true:false" @keyup.native="checkPrice(subItem,'CostPrice')"
placeholder="请输入成本价" class="w135"></el-input> placeholder="请输入成本价" class="w135"></el-input>
</div> </div>
</template> </template>
...@@ -414,6 +414,9 @@ ...@@ -414,6 +414,9 @@
:disabled="disButton" value="保存草稿" /> :disabled="disButton" value="保存草稿" />
<input type="button" class="normalBtn" :class="{'disClick':!isSubmit}" @click="SaveList(1)" <input type="button" class="normalBtn" :class="{'disClick':!isSubmit}" @click="SaveList(1)"
:disabled="disButton" value="保存" /> :disabled="disButton" value="保存" />
<span v-if="isShowBtn==1" style="color:red;margin-left:10px;">
已制单,不能再修改价格和付款方式!
</span>
</div> </div>
</el-form> </el-form>
</div> </div>
......
...@@ -406,7 +406,7 @@ ...@@ -406,7 +406,7 @@
{{subItem.ScenicName}} {{subItem.ScenicName}}
</td> </td>
<td> <td>
{{peopleStrToWord(childItem.PeopleType)}}:{{childItem.PeopleNum}} {{peopleStrToWord(childItem.PeopleType)}}:{{childItem.UsePeopleNum}}
</td> </td>
<td> <td>
<p> <p>
......
...@@ -329,6 +329,14 @@ export default { ...@@ -329,6 +329,14 @@ export default {
title: '提成管理' title: '提成管理'
}, },
}, },
{
path: '/DjCommissionsmangment', //提成管理
name: 'DjCommissionsmangment',
component: resolve => require(['@/components/administrative/DjCommissionsmangment'], resolve),
meta: {
title: '地接提成'
},
},
{ {
path: '/AirticketCommission', //票务提成 path: '/AirticketCommission', //票务提成
name: 'AirticketCommission', name: 'AirticketCommission',
...@@ -353,6 +361,22 @@ export default { ...@@ -353,6 +361,22 @@ export default {
title: '提成详情' title: '提成详情'
}, },
}, },
{
path: '/ClausesOrder', //提成详情
name: 'ClausesOrder',
component: resolve => require(['@/components/administrative/ClausesOrder'], resolve),
meta: {
title: '期数订单'
},
},
{
path: '/DjCommissionDetail', //提成详情
name: 'DjCommissionDetail',
component: resolve => require(['@/components/administrative/DjCommissionDetail'], resolve),
meta: {
title: '提成详情'
},
},
{ {
path: '/ExaminationStatistics', //考核管理 path: '/ExaminationStatistics', //考核管理
name: 'ExaminationStatistics', name: 'ExaminationStatistics',
...@@ -3660,6 +3684,14 @@ export default { ...@@ -3660,6 +3684,14 @@ export default {
title: 'op提成' title: 'op提成'
} }
}, },
{
path: '/Djcommissions',
name: 'Djcommissions',
component: resolve => require(['@/components/FinancialModule/Djcommissions'], resolve),
meta: {
title: '地接提成规则'
}
},
{ {
path: '/OPCommissionDetail', path: '/OPCommissionDetail',
name: 'OPCommissionDetail', name: 'OPCommissionDetail',
......
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