Commit 6baa05ef authored by huangyuanyuan's avatar huangyuanyuan

添加返佣比例管理,修改会员客户跳转

parent 2fbdee90
......@@ -10,7 +10,7 @@
</div>
<div>
<p>{{datainfo.CustomerName}}</p>
<p style="color:#7F8593;font-size:14px">{{datainfo.Contact}}</p>
<p style="color:#7F8593;font-size:14px;padding:6px 0">{{datainfo.Contact}}</p>
</div>
</div>
</div>
......@@ -112,14 +112,14 @@
</div>
<div>
<el-row :gutter="23" justify="space-between">
<el-col :span="18">
<el-col :span="16">
<p style="margin-top:6px">
<!-- 数据是:{{datainfo.totalYearPrice/item.Money>1?100:(datainfo.totalYearPrice/item.Money)*100}} -->
<el-progress :color="colorMethod(item)" :show-text="false" :stroke-width="12" :percentage="datainfo.totalYearPrice/item.Money>1?100:(datainfo.totalYearPrice/item.Money)*100"></el-progress>
</p>
</el-col>
<el-col :span="6">
<el-col :span="8">
<span v-if="item.ActivateState==2"><img style="width:20px;height:20px" src="../../assets/img/saleRank/gou.png" alt=""></span>
<span style="font-size:14px;font-weight:bold;color:#2C3343" v-if="item.ActivateState==0">未开启</span>
<span style="font-size:14px;font-weight:bold;color:#2C3343" v-if="item.ActivateState==1">还差 ¥{{item.PriceSpread}}满足</span>
......
......@@ -112,6 +112,36 @@
</el-select>
</span>
</li>
<li>
<span><em>线路</em>
<el-select filterable v-model='msg.LineId' placeholder="请选择">
<el-option label="不限" value=""></el-option>
<el-option v-for="(item,index) in LineList" :key="index+300" :label="item.LineName" :value="item.LineID"></el-option>
</el-select>
</span>
</li>
<li>
<span><em>公司</em>
<el-select filterable v-model='msg.RB_Branch_Id' placeholder="请选择">
<el-option label="不限" value=""></el-option>
<el-option
v-for="item in companyList"
:label="item.BName"
:value="item.Id"
:key="item.Id"
></el-option>
</el-select>
</span>
</li>
<li>
<span><em>销售</em>
<el-select v-model="msg.EmployeeId" filterable placeholder="请选择">
<el-option label="不限" value=""></el-option>
<el-option v-for="item in employee" :key="item.employeeId" :label="item.name" :value="item.employeeId"></el-option>
</el-select>
</span>
</li>
<li>
<span><em>日期</em>
<el-date-picker
......@@ -135,6 +165,7 @@
<th>门店名称</th>
<th>类型</th>
<th>金额</th>
<th>所属团</th>
<th>描述</th>
<th>时间</th>
<th>历史余额</th>
......@@ -147,6 +178,7 @@
<span>{{item.Type==1?"收入":"折扣"}}</span>
</td>
<td>{{item.Money}}</td>
<td><span style="cursor:pointer" @click="Gourl(item)">{{item.TCNUM}}</span></td>
<td>{{item.Description}}</td>
<td>{{item.UpdateTime}}</td>
<td>{{item.AccountMoney}}</td>
......@@ -180,11 +212,21 @@
OrderSource:"",
StartTime:"",
EndTime:"",
LineId:"",
EmployeeId:"",
RB_Branch_Id:"",
},
currentPage:1,
DataList:[],
dateList:[],
LineList:[],
getCompanyMsg: {
RB_Group_Id: "0",
Status: "0"
},
companyList:[],
employee:[],
}
},
created(){
......@@ -196,8 +238,44 @@
let userInfo = this.getLocalStorage();
this.getList();
this.getLineList();
this.getCompany();
this.getEmployee();
},
methods: {
Gourl(item){
this.$router.push({ name:"groupTourOrderByTuan",query:{"id":item.TCID,"tcmun":item.TCNUM,blank: 'y'} })
},
getEmployee(){
this.apiJavaPost("/api/user/employee/getAllSalesList",{}, res => {
if (res.data.resultCode === 1) {
this.employee=res.data.data;
} else {
this.Error(res.data.message)
}
}, null);
},
getCompany() {
this.apipost(
"admin_get_BranchGetList",
this.getCompanyMsg,
res => {
if (res.data.resultCode == 1) {
this.companyList = res.data.data;
} else {
}
},
err => {}
);
},
//获取线路列表
getLineList() {
this.apipost("line_post_GetLineListExt", {}, res => {
if (res.data.resultCode == 1) {
this.LineList = res.data.data;
}
});
},
getList() { //获取数据
if(this.dateList){
this.msg.StartTime=this.dateList[0];
......
......@@ -7,7 +7,7 @@
z-index: 50; bottom:0;left: 0;border-top:3px solid #38425d;background-color:#f9f9f9; padding: 10px;width: 100%;min-width: 1146px;}
.page_MyCustomer .edHeightOne{display: block!important;height: 450px;}
.page_MyCustomer ._mc_list{overflow-x: auto; background: #fff; padding-top: 20px; padding-left: 15px;}
.page_MyCustomer ._mc_list>ul>li{padding: 20px 20px 0 20px;width: 260px;box-sizing: border-box; height:348px;
.page_MyCustomer ._mc_list>ul>li{padding: 20px 20px 0 20px;width: 260px;box-sizing: border-box; height:370px;
float: left;border: 1px solid #F1F2F5;background: #fff; margin-right:10px;margin-bottom: 20px; border-radius: 10px; position: relative; cursor: pointer;}
.page_MyCustomer ._mc_list>ul>li:hover{box-shadow:0px 0px 10px rgba(191,191,191,1);transition: all linear 0.3s;}
.page_MyCustomer ._mc_list>ul>li .iconDelete{cursor: pointer; display: none; position: absolute; top: -4px; right: 0; color: #E95252; z-index: 5; }
......@@ -72,8 +72,13 @@
}
.xqBtn{
background: #09D49D;
padding:2px 6px;
color:#fff!important;
width: 100%;
display: inline-block;
border-radius: 4px;
font-size: 14px;
height: 23px;
line-height: 23px;
}
</style>
<template>
......@@ -138,10 +143,17 @@
<p class="_other_n" v-else>最近拜访:暂无</p>
</div>
<div class="_bt">
<p>累计交易额度 <span> {{item.tradeTotal}}</span>
<span class="xqBtn" @click.stop="goUrC('CustomerAnalysis',item.customerId)">详情</span>
</p>
<p>询价与需求 <span> {{item.inquireCount}}</span></p>
<el-row :gutter="23">
<el-col :span="16">
<p>累计交易额度 <span> {{item.tradeTotal}}</span></p>
<p>询价与需求 <span> {{item.inquireCount}}</span></p>
<p>幸福存折 <span> {{item.cL_Balance}}</span></p>
</el-col>
<el-col :span="8">
<span class="xqBtn" @click.stop="goUrC('CustomerAnalysis',item.customerId)">详情</span>
</el-col>
</el-row>
</div>
</li>
<div class="clearfix"></div>
......
<style scoped>
.departmentTreeStyleCont {
padding-top: 20px;
display: flex;
height: 100%;
}
.departmentTreeStyleCont .departmentTreeStyle {
background: #fff;
padding: 20px;
flex: 0 1 400px;
min-height: 800px;
}
.departmentTreeStyleCont .departmentTreeStyle > p {
font-size: 14px;
margin-bottom: 15px;
color: #333;
font-weight: bold;
height: 14px;
line-height: 14px;
border-left: 3px solid #E95252;
text-indent: 20px;
}
.departmentTreeStyleCont .departmentTreeStyle .spanIcon {
padding-left: 20px;
display: none
}
.departmentTreeStyleCont .departmentTreeStyle .el-tree-node__content {
height: 32px;
line-height: 32px;
font-size: 12px
}
.TreeSpan img {
width: 24px;
height: 24px;
border-radius: 12px;
vertical-align: sub;
margin-right: 3px;
}
.departmentTreeStyleCont .departmentTreeStyle .el-tree-node__content:hover .spanIcon {
display: inline-block
}
.departmentTreeStyleCont .departmentTreeStyle .el-tree-node__content:hover .spanIcon i {
font-size: 14px !important;
color: #999;
margin-right: 2px;
}
.departmentTreeStyleCont .departmentTreeStyle .el-tree-node__content:hover .spanIcon i:hover {
color: #E95252;
}
.departmentTreeStyleCont .departmentTreeLayer > p {
font-size: 14px;
margin-bottom: 15px;
color: #333;
font-weight: bold;
height: 14px;
line-height: 14px;
border-left: 3px solid #E95252;
text-indent: 20px;
}
.departmentTreeStyleCont .departmentTreeLayer {
background: #fff;
min-height: 300px;
padding: 20px;
margin-left: 20px;
flex: auto
}
.departmentTreeStyleCont .el-date-editor.el-input,
.departmentTreeStyleCont .el-date-editor.el-input__inner {
width: auto !important;
}
</style>
<template>
<div class="flexOne">
<div style="text-align:right;padding:10px">
<input type="button" class="hollowFixedBtn" value="新增" @click="add"/>
</div>
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0" v-loading='loading'>
<tr>
<th>金额</th>
<th>返佣比例</th>
<th>操作人姓名</th>
<th>操作时间</th>
<th>操作</th>
</tr>
<tr v-for="(item,index) in DataList" :key="index+500">
<td>{{item.Money}}</td>
<td>{{item.Ratio}}</td>
<td>{{item.UpdateByName}}</td>
<td>{{item.UpdateTime}}</td>
<td>
<el-tooltip
class="item"
effect="dark"
content="编辑"
placement="top-start"
>
<el-button
type="primary" icon="el-icon-edit"
circle
@click="Edit(item)"
>
</el-button>
</el-tooltip>
<el-tooltip
class="item"
effect="dark"
content="删除"
placement="top-start"
>
<el-button @click="Delete(item)" type="danger" icon="el-icon-delete" circle></el-button>
</el-tooltip>
</td>
</tr>
<tr v-if='DataList.length==0'>
<td colspan="6" 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> -->
<el-dialog
title="提示"
:visible.sync="dialogVisible"
width="400px">
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="120px" class="demo-ruleForm">
<el-form-item label="金额" prop="Money">
<el-input v-model="ruleForm.Money" @keyup.native="checkPrice(ruleForm,'Money')"></el-input>
</el-form-item>
<el-form-item label="返佣比例(‰)" prop="Ratio">
<el-input v-model="ruleForm.Ratio" @keyup.native="checkPrice(ruleForm,'Ratio')"></el-input>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">取 消</el-button>
<el-button type="danger" @click="submitForm('ruleForm')">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
export default {
data() {
return {
dialogVisible:false,
loading: true,
//分页
total: 0,
pageSize: '',
currentPage:1,
DataList:[],
dateList:[],
rules: {
Money: [
{ required: true, message: '请输入金额', trigger: 'blur' },
],
Ratio: [
{ required: true, message: '请输入返佣比例', trigger: 'blur' },
],
},
ruleForm:{
Id:0,
Money:"",
Ratio:"",
},
}
},
created(){
},
mounted() {
let userInfo = this.getLocalStorage();
this.getList();
},
methods: {
Delete(item){
this.$confirm('是否删除?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.apipost('customer_post_DelCustomerCommissionRatio', {Id:item.Id}, res => {
if (res.data.resultCode == 1) {
this.getList();
this.dialogVisible=false;
this.Success(res.data.message)
} else {
this.Success(res.data.message)
}
}, err => {
})
}).catch(() => {
});
},
Edit(item){
this.ruleForm={
Id:item.Id,
Money:item.Money,
Ratio:item.Ratio,
}
this.dialogVisible=true;
},
add(){
this.ruleForm={
Id:0,
Money:"",
Ratio:"",
}
this.dialogVisible=true;
},
submitForm(formName) {
this.$refs[formName].validate((valid) => {
if (valid) {
this.apipost('customer_post_SetCustomerCommissionRatio', this.ruleForm, res => {
if (res.data.resultCode == 1) {
this.getList();
this.dialogVisible=false;
this.$refs["ruleForm"].resetFields();
} else {
}
}, err => {
})
} else {
}
});
},
getList() { //获取数据
this.loading = true;
this.apipost('customer_post_GetCustomerCommissionRatioList', {}, res => {
this.loading = false
if (res.data.resultCode == 1) {
this.DataList = res.data.data;
this.total = res.data.data.count;
} else {
}
}, err => {
})
},
handleCurrentChange(val) {
this.msg.pageIndex = val;
this.getList();
},
resetPageIndex() {
this.msg.pageIndex = 1;
this.currentPage = 1
},
}
}
</script>
......@@ -94,12 +94,13 @@
<!--<label><input type="checkbox" v-model="isCkedAll" @click='checkedAll()' style="vertical-align: middle;"/>门店名称</label>-->
</th>
<th width="10%">联系人</th>
<th width="15%">联系电话</th>
<th width="10%">联系电话</th>
<th width="20%">地址</th>
<th width="8%">所属销售</th>
<th width="8%">客户状态</th>
<th width="5%">幸福存折</th>
<th width="10%">备注</th>
<th width="10%">操作</th>
<th width="12%">操作</th>
</tr>
<tr>
<td colspan="8" align="center" v-show="list.length==0">暂无数据</td>
......@@ -126,7 +127,9 @@
<td>{{item.Address}}</td>
<td>{{item.EmName}}</td>
<td>{{valueToWord(item.CustomerStatus)}}</td>
<td>{{item.CL_Balance}}</td>
<td>{{item.Remark}}</td>
<td>
<el-tooltip effect="dark" content="转交" placement="top-start">
<el-popover width="280" popper-class="pd20" trigger="click">
......@@ -228,6 +231,14 @@
>
</el-button>
</el-tooltip>
<el-tooltip
class="item"
effect="dark"
content="详情"
placement="top-start"
>
<el-button @click="getUrl(item)" type="success" icon="iconfont icon-nav-xiaoshou" circle></el-button>
</el-tooltip>
</td>
</tr>
</table>
......@@ -561,6 +572,9 @@ export default {
};
},
methods: {
getUrl(item){
this.$router.push({ name:"CustomerAnalysis",query:{"customerId":item.CustomerIdS,blank: 'y'} })
},
updateData: function(obj) {
this.apipost(
"app_customer_GetLeaderCustomerInfo",
......
......@@ -1862,14 +1862,22 @@ export default {
title: '拜访记录'
},
},
{ // 销售 幸福存折
{ // 销售 返佣查询
path: '/HappyPassbook',
name: 'HappyPassbook',
component: resolve => require(['@/components/SalesModule/HappyPassbook'], resolve),
meta: {
title: '幸福存折'
title: '返佣查询'
},
}, { // 销售 统计
},
{ // 销售 返佣比例管理
path: '/Returnratio',
name: 'Returnratio',
component: resolve => require(['@/components/SalesModule/Returnratio'], resolve),
meta: {
title: '返佣比例管理'
},
},{ // 销售 统计
path: '/demandStatistics',
name: 'demandStatistics',
component: resolve => require(['@/components/SalesModule/demandStatistics'], resolve),
......
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