Commit d6b1cbdc authored by youjie's avatar youjie

no message

parent 60a7da1a
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
<li> <li>
<em>出团公司</em> <em>出团公司</em>
<el-select filterable v-model='msg.OutBranchId' <el-select filterable v-model='msg.OutBranchId'
@change='handleCurrentChange(1)'> @change='handleCurrentChange(1)' :disabled="disabled">
<el-option label="不限" :value="-1" :key="-1"></el-option> <el-option label="不限" :value="-1" :key="-1"></el-option>
<el-option <el-option
v-for="item in companyList" v-for="item in companyList"
...@@ -112,65 +112,6 @@ ...@@ -112,65 +112,6 @@
<el-pagination background @current-change="handleCurrentChange" :current-page.sync="msg.pageIndex" <el-pagination background @current-change="handleCurrentChange" :current-page.sync="msg.pageIndex"
layout="total,prev, pager, next, jumper" :page-size='msg.pageSize' :total='total'> layout="total,prev, pager, next, jumper" :page-size='msg.pageSize' :total='total'>
</el-pagination> </el-pagination>
<!-- 制单人员选择 -->
<el-dialog custom-class='w1006' title="选择制单人员" :visible.sync="outerVisible" center :before-close="closeChangeMachie">
<template>
<div
class="cm_content"
style="width: 100%;margin-bottom: 35px;margin-top: 30px;"
>
<el-table
v-loading="BillMakingLoading"
ref="orderMakerList"
:data="orderMakerList"
tooltip-effect="dark"
style="width: 100%"
@selection-change="handleSelectionChange">
<el-table-column
:selectable="checkSelectable"
type="selection"
width="55">
</el-table-column>
<el-table-column
label="公司"
width="120">
<template slot-scope="scope">{{ scope.row.BranchName }}</template>
</el-table-column>
<el-table-column
prop="DeptName"
label="部门">
</el-table-column>
<el-table-column
prop="EmName"
label="姓名"
show-overflow-tooltip>
</el-table-column>
<el-table-column
v-if="BillMakingMsg.Type==1"
prop="Commission"
label="提成金额"
show-overflow-tooltip>
</el-table-column>
<el-table-column
v-else
label="追加工资"
show-overflow-tooltip>
<template slot-scope="scope"> + {{ scope.row.WageMoney }}</template>
</el-table-column>
<el-table-column
label="是否已发放"
show-overflow-tooltip>
<template slot-scope="scope">{{ scope.row.IsGiveOut==2? '否':'是' }}</template>
</el-table-column>
</el-table>
</div>
<div style="margin-top: 10px">金额总额:{{ totalAmount }}</div>
</template>
<div slot="footer" class="dialog-footer">
<button class="hollowFixedBtn" @click="outerVisible = false">取消</button> &nbsp;
<button class="normalBtn" type="primary" @click="BillMaking">确定</button>
</div>
</el-dialog>
</div> </div>
</template> </template>
...@@ -184,8 +125,6 @@ ...@@ -184,8 +125,6 @@
Status:'0', Status:'0',
}, },
companyList: [], companyList: [],
orderMakerList:[],//制单人列表
outerVisible: false,
Month: moment().subtract(1, 'months').format("YYYY-MM"), Month: moment().subtract(1, 'months').format("YYYY-MM"),
msg: { msg: {
pageIndex: 1, pageIndex: 1,
...@@ -198,15 +137,8 @@ ...@@ -198,15 +137,8 @@
total: 0, total: 0,
btnShow: false, btnShow: false,
btnLoading: false, btnLoading: false,
cMaker: true,//是否可以制单 cMaker: false,//是否可以制单
BillMakingLoading: false, disabled: true
totalAmount:0,
multipleSelection:[],
BillMakingMsg:{
PeroidsId: null,
Type: null,
EmpIds:''
}
} }
}, },
mounted() { mounted() {
...@@ -217,6 +149,14 @@ ...@@ -217,6 +149,14 @@
if (ActionMenuCode.indexOf('F_DCommissionSend') != -1) { if (ActionMenuCode.indexOf('F_DCommissionSend') != -1) {
this.btnShow = true; this.btnShow = true;
} }
if (ActionMenuCode.indexOf('home_DCommissionZD') != -1) {
this.cMaker = true;
}
if (ActionMenuCode.indexOf('home_CommissionSeeAll') != -1) {//是否有看所有人的权限
this.disabled = false;
}else{
this.disabled = true;
}
this.getCompany() this.getCompany()
this.getList() this.getList()
}, },
...@@ -228,28 +168,6 @@ ...@@ -228,28 +168,6 @@
}else{} }else{}
},err=>{}) },err=>{})
}, },
// 是否已发放
checkSelectable (row){
return row.IsGiveOut != 1
},
// 已选可制单人员
handleSelectionChange(val){
this.multipleSelection = val;
let zong = 0;
this.multipleSelection.forEach((x) => {
if(this.BillMakingMsg.Type==1){
zong += x.Commission;
}else{
zong += x.WageMoney;
}
});
this.totalAmount = zong;
},
closeChangeMachie(done){//弹出框关闭初始化弹框内表单
done();
},
handleCurrentChange(val) { handleCurrentChange(val) {
this.msg.pageIndex = val; this.msg.pageIndex = val;
this.getList(); this.getList();
...@@ -310,65 +228,6 @@ ...@@ -310,65 +228,6 @@
} }
); );
}, },
// 保存制单人员
BillMaking(){
if(this.multipleSelection.length==0){
this.Error("请选择需要制单的人员!")
return
}
if(this.totalAmount<=0){
this.Error("金额总额必须大于0!")
return
}
let data = []
this.multipleSelection.map(item=>{
data.push(item.EmpId)
})
this.BillMakingMsg.EmpIds = data.join(',')
this.$confirm("是否制单? 制单后无法更改制单状态,如需修改请联系管理员", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning"
})
.then(() => {
this.BillMakingFun()
})
.catch(() => {});
},
BillMakingFun(){
this.crmapipost(
'/api/Commission/SetCommissionSendEmployee', this.BillMakingMsg,
res => {
if (res.data.resultCode == 1) {
this.BillMakingMsg.totalAmount = this.totalAmount
this.BillMakingMsg.OtherType = this.BillMakingMsg.Type==1?'56':'57'
let query = {
blank: "y",
tab: "新增付款单据",
Type: 2,
commissionObj: JSON.stringify(this.BillMakingMsg)
}
this.$router.push({
path: "/ChoiceAddFinancialDocuments",
query
});
this.Success('制单人员保存成功')
this.outerVisible = false
this.BillMakingMsg = {
PeroidsId: null,
Type: null,
EmpIds:''
}
} else {
this.Error(res.data.message)
}
},
err => {}
)
},
// 点击制单 // 点击制单
YijianZD(item,type) { YijianZD(item,type) {
let Money let Money
......
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
<li> <li>
<em>所属公司</em> <em>所属公司</em>
<el-select filterable v-model='msg.RB_Branch_Id' <el-select filterable v-model='msg.RB_Branch_Id'
@change='getDepartment();handleCurrentChange(1)'> @change='getDepartment();handleCurrentChange(1)' :disabled="disabled">
<el-option label="不限" :value="-1" :key="-1"></el-option> <el-option label="不限" :value="-1" :key="-1"></el-option>
<el-option <el-option
v-for="item in companyList" v-for="item in companyList"
...@@ -72,7 +72,7 @@ ...@@ -72,7 +72,7 @@
<li> <li>
<em>部门</em> <em>部门</em>
<el-select filterable v-model='msg.RB_Department_Id' <el-select filterable v-model='msg.RB_Department_Id'
@change='getEmployee();handleCurrentChange(1)'> @change='getEmployee();handleCurrentChange(1)' :disabled="disabled">
<el-option label="不限" :value="-1"></el-option> <el-option label="不限" :value="-1"></el-option>
<el-option v-for='item in departmentList' <el-option v-for='item in departmentList'
:label='item.DepartmentName' :label='item.DepartmentName'
...@@ -83,7 +83,8 @@ ...@@ -83,7 +83,8 @@
</li> </li>
<li> <li>
<em>人员</em> <em>人员</em>
<el-select v-model="msg.UserId" size="mini" @change="handleCurrentChange(1)" filterable> <el-select v-model="msg.UserId" size="mini"
@change="handleCurrentChange(1)" :disabled="disabled" filterable>
<el-option label="不限" :value="-1"></el-option> <el-option label="不限" :value="-1"></el-option>
<el-option label="微途" :value="-2"></el-option> <el-option label="微途" :value="-2"></el-option>
<el-option v-for="(item,index) in searchList" :key="item.index" :label="item.name" <el-option v-for="(item,index) in searchList" :key="item.index" :label="item.name"
...@@ -95,6 +96,11 @@ ...@@ -95,6 +96,11 @@
<el-input maxlength="50" v-model="msg.OrderId" class="permiss-input w200" <el-input maxlength="50" v-model="msg.OrderId" class="permiss-input w200"
@keyup.native.enter="handleCurrentChange(1)" :placeholder="$t('pub.pleaseImport')"></el-input> @keyup.native.enter="handleCurrentChange(1)" :placeholder="$t('pub.pleaseImport')"></el-input>
</li> </li>
<li>
<em>团号</em>
<el-input maxlength="50" v-model="msg.TCNUM" class="permiss-input w200"
@keyup.native.enter="handleCurrentChange(1)" :placeholder="$t('pub.pleaseImport')"></el-input>
</li>
<li> <li>
<em>订单类型</em> <em>订单类型</em>
<el-select v-model="msg.OrderType" class="w200 HworkInput" <el-select v-model="msg.OrderType" class="w200 HworkInput"
...@@ -133,11 +139,12 @@ ...@@ -133,11 +139,12 @@
<table v-loading="loading" class="singeRowTable" border="0" cellspacing="0" cellpadding="0" <table v-loading="loading" class="singeRowTable" border="0" cellspacing="0" cellpadding="0"
style="margin-top: 10px;"> style="margin-top: 10px;">
<tr> <tr>
<th style="width: 100px;">出团公司</th>
<th style="width: 80px;">类型</th> <th style="width: 80px;">类型</th>
<th style="width: 80px;">订单号</th> <th style="width: 80px;">订单号</th>
<th style="width: 150px;">团号</th> <th style="width: 150px;">团号</th>
<th style="width: 100px;">所属公司</th> <th style="width: 100px;">所属公司</th>
<th style="width: 100px;">出团公司</th>
<th style="width: 100px;">部门</th> <th style="width: 100px;">部门</th>
<th style="width: 100px;">姓名</th> <th style="width: 100px;">姓名</th>
<th style="width: 100px;">线路</th> <th style="width: 100px;">线路</th>
...@@ -147,18 +154,19 @@ ...@@ -147,18 +154,19 @@
<th style="width: 100px;">团队总人数</th> <th style="width: 100px;">团队总人数</th>
<th style="width: 100px;">提成方式</th> <th style="width: 100px;">提成方式</th>
<th style="width: 100px;">提成比例</th> <th style="width: 100px;">提成比例</th>
<th style="width: 100px;">订单业绩/利润</th> <th style="width: 100px;">当月利润</th>
<th style="width: 100px;">团队利润</th> <th style="width: 100px;">团队利润</th>
<th style="width: 100px;">提成金额</th>
<th style="width: 100px;">期数</th> <th style="width: 100px;">期数</th>
<th width='200'>备注</th> <th width='200'>备注</th>
</tr> </tr>
<tr v-for="item in dataList"> <tr v-for="item in dataList">
<td>{{item.OutBranchName?item.OutBranchName:'-'}}</td>
<td>{{item.OrderTypeName}}</td> <td>{{item.OrderTypeName}}</td>
<td><span class="cursor-p" style="color: #409EFF;" @click="clickUrl(item,1)">{{item.OrderId}}</span></td> <td><span class="cursor-p" style="color: #409EFF;" @click="clickUrl(item,1)">{{item.OrderId}}</span></td>
<td><span class="cursor-p" style="color: #409EFF;" v-if="item.TCNUM" @click="goTuanDetails(item)">{{item.TCNUM}}({{item.TCID}})</span></td> <td><span class="cursor-p" style="color: #409EFF;" v-if="item.TCNUM" @click="goTuanDetails(item)">{{item.TCNUM}}({{item.TCID}})</span></td>
<td>{{item.BranchName?item.BranchName:'-'}}</td> <td>{{item.BranchName?item.BranchName:'-'}}</td>
<td>{{item.OutBranchName?item.OutBranchName:'-'}}</td>
<td>{{item.DeptName?item.DeptName:'-'}}</td> <td>{{item.DeptName?item.DeptName:'-'}}</td>
<td>{{item.UserName}}</td> <td>{{item.UserName}}</td>
<td>{{item.LineName}}</td> <td>{{item.LineName}}</td>
...@@ -169,11 +177,12 @@ ...@@ -169,11 +177,12 @@
<td>{{item.Rate?item.Rate+'%':'-'}}</td> <td>{{item.Rate?item.Rate+'%':'-'}}</td>
<td>{{item.OrderProfit}}</td> <td>{{item.OrderProfit}}</td>
<td>{{item.TCProfit}}</td> <td>{{item.TCProfit}}</td>
<td>{{item.CommissionMoney?item.CommissionMoney:'-'}}</td>
<td>{{item.Periods}}</td> <td>{{item.Periods}}</td>
<td>{{item.Description?item.Description:'-'}}</td> <td>{{item.Description?item.Description:'-'}}</td>
</tr> </tr>
<tr v-if="dataList.length==0"> <tr v-if="dataList.length==0">
<td style="text-align:center" colspan="17">暂无数据</td> <td style="text-align:center" colspan="18">暂无数据</td>
</tr> </tr>
</table> </table>
<!-- 分页 --> <!-- 分页 -->
...@@ -246,7 +255,8 @@ ...@@ -246,7 +255,8 @@
Tier:'0', Tier:'0',
}, },
S_CheckBranchOrder:false, S_CheckBranchOrder:false,
S_CheckAllOrder:false S_CheckAllOrder:false,
disabled:true
} }
}, },
mounted() { mounted() {
...@@ -271,11 +281,16 @@ ...@@ -271,11 +281,16 @@
} }
if (this.$route.query) { //不大于0的话用默认值 if (this.$route.query) { //不大于0的话用默认值
if (this.$route.query.PeriodId && this.$route.query.PeriodId > 0) { if (this.$route.query.PeriodId && this.$route.query.PeriodId > 0) {
this.msg.PeriodId = Number(this.$route.query.PeriodId)
} }
if (this.$route.query.UserId) {
this.msg.UserId = this.$route.query.UserId
} }
this.msg.PeriodId = this.$route.query&&this.$route.query.PeriodId>0?Number(this.$route.query.PeriodId):-1
this.msg.OutBranchId = this.$route.query&&this.$route.query.RB_Branch_Id>-1?Number(this.$route.query.RB_Branch_Id):Number(userInfo.RB_Branch_id)
this.msg.UserId = this.$route.query&&this.$route.query.UserId?Number(this.$route.query.UserId):Number(userInfo.EmployeeId)
if (ActionMenuCode.indexOf('home_CommissionSeeAll') != -1) {//是否有看所有人的权限
this.disabled = false;
}else{
this.disabled = true;
} }
this.getList() this.getList()
}, },
...@@ -493,7 +508,6 @@ ...@@ -493,7 +508,6 @@
res => { res => {
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.searchList = res.data.data; this.searchList = res.data.data;
} }
}, },
err => {} err => {}
......
...@@ -129,7 +129,7 @@ ...@@ -129,7 +129,7 @@
<li> <li>
<em>出团公司</em> <em>出团公司</em>
<el-select filterable v-model='msg.OutBranchId' <el-select filterable v-model='msg.OutBranchId'
@change='handleCurrentChange(1)'> @change='handleCurrentChange(1)' :disabled="disabled">
<el-option label="不限" :value="-1" :key="-1"></el-option> <el-option label="不限" :value="-1" :key="-1"></el-option>
<el-option <el-option
v-for="item in companyList" v-for="item in companyList"
...@@ -150,7 +150,7 @@ ...@@ -150,7 +150,7 @@
<li> <li>
<em>所属公司</em> <em>所属公司</em>
<el-select filterable v-model='msg.RB_Branch_Id' <el-select filterable v-model='msg.RB_Branch_Id'
@change='getDepartment();handleCurrentChange(1)'> @change='getDepartment();handleCurrentChange(1)' :disabled="disabled">
<el-option label="不限" :value="-1" :key="-1"></el-option> <el-option label="不限" :value="-1" :key="-1"></el-option>
<el-option <el-option
v-for="item in companyList" v-for="item in companyList"
...@@ -164,7 +164,7 @@ ...@@ -164,7 +164,7 @@
<li> <li>
<em>部门</em> <em>部门</em>
<el-select filterable v-model='msg.RB_Department_Id' <el-select filterable v-model='msg.RB_Department_Id'
@change='getEmployee();handleCurrentChange(1)'> @change='getEmployee();handleCurrentChange(1)' :disabled="disabled">
<el-option label="不限" :value="-1"></el-option> <el-option label="不限" :value="-1"></el-option>
<el-option v-for='item in departmentList' <el-option v-for='item in departmentList'
:label='item.DepartmentName' :label='item.DepartmentName'
...@@ -175,7 +175,8 @@ ...@@ -175,7 +175,8 @@
</li> </li>
<li> <li>
<em>人员</em> <em>人员</em>
<el-select v-model="msg.UserId" size="mini" @change="handleCurrentChange(1)" filterable> <el-select v-model="msg.UserId" size="mini"
@change="handleCurrentChange(1)" :disabled="disabled" filterable>
<el-option label="不限" :value="-1"></el-option> <el-option label="不限" :value="-1"></el-option>
<el-option label="微途" :value="-2"></el-option> <el-option label="微途" :value="-2"></el-option>
<el-option v-for="(item,index) in searchList" :key="item.index" :label="item.name" <el-option v-for="(item,index) in searchList" :key="item.index" :label="item.name"
...@@ -225,7 +226,7 @@ ...@@ -225,7 +226,7 @@
</td> </td>
</tr> </tr>
<tr v-if="dataList.length==0"> <tr v-if="dataList.length==0">
<td style="text-align:center" colspan="10">暂无数据</td> <td style="text-align:center" colspan="11">暂无数据</td>
</tr> </tr>
</table> </table>
<!-- 分页 --> <!-- 分页 -->
...@@ -258,7 +259,6 @@ ...@@ -258,7 +259,6 @@
msg: { msg: {
pageIndex: 1, pageIndex: 1,
pageSize: 20, pageSize: 20,
EmpId: -1,
PeriodId: -1, PeriodId: -1,
UserId: -1, UserId: -1,
RB_Department_Id: -1,//部门ID RB_Department_Id: -1,//部门ID
...@@ -292,6 +292,7 @@ ...@@ -292,6 +292,7 @@
ParentId:'-1', ParentId:'-1',
Tier:'0', Tier:'0',
}, },
disabled:true
} }
}, },
mounted() { mounted() {
...@@ -300,12 +301,16 @@ ...@@ -300,12 +301,16 @@
this.departmentMsg.RB_Group_Id = userInfo.RB_Group_id; //集团 this.departmentMsg.RB_Group_Id = userInfo.RB_Group_id; //集团
this.departmentMsg.RB_Branch_Id = userInfo.RB_Branch_Id; this.departmentMsg.RB_Branch_Id = userInfo.RB_Branch_Id;
let ActionMenuCode = userInfo.ActionMenuCode; let ActionMenuCode = userInfo.ActionMenuCode;
if (this.$route.query && this.$route.query.PeriodId) { this.msg.PeriodId = this.$route.query&&this.$route.query.PeriodId>0?Number(this.$route.query.PeriodId):-1
this.msg.PeriodId = Number(this.$route.query.PeriodId) this.msg.OutBranchId = this.$route.query&&this.$route.query.RB_Branch_Id>-1?Number(this.$route.query.RB_Branch_Id):Number(userInfo.RB_Branch_id)
} this.msg.UserId = this.$route.query&&this.$route.query.UserId?Number(this.$route.query.UserId):Number(userInfo.EmployeeId)
if (this.$route.query && this.$route.query.EmpIds) {
this.msg.EmpIds = this.$route.query.EmpIds if (ActionMenuCode.indexOf('home_CommissionSeeAll') != -1) {//是否有看所有人的权限
this.disabled = false;
}else{
this.disabled = true;
} }
this.getList() this.getList()
this.getEmployee()//人员 this.getEmployee()//人员
this.getDepartment() this.getDepartment()
...@@ -419,6 +424,7 @@ ...@@ -419,6 +424,7 @@
path: path, path: path,
query: { query: {
PeriodId: this.$route.query.PeriodId, PeriodId: this.$route.query.PeriodId,
RB_Branch_Id: item.RB_Branch_Id,
UserId: item.UserId, UserId: item.UserId,
blank: 'y', blank: 'y',
tab: '同业提现详情' tab: '同业提现详情'
......
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