Commit bd6751c3 authored by 罗超's avatar 罗超

Merge branch 'master' of http://gitlab.oytour.com/luochao/confucius into master

parents a06f8f77 1dfd73ac
...@@ -73,7 +73,6 @@ ...@@ -73,7 +73,6 @@
/deep/ .q-field__prepend { /deep/ .q-field__prepend {
padding-right: 0px !important; padding-right: 0px !important;
} }
</style> </style>
<template> <template>
<q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale"> <q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale">
...@@ -91,7 +90,35 @@ ...@@ -91,7 +90,35 @@
<div class="row wrap"> <div class="row wrap">
<div class="col-12"> <div class="col-12">
<q-select stack-label color="primary" filled label="类型" option-value="Id" option-label="Name" <q-select stack-label color="primary" filled label="类型" option-value="Id" option-label="Name"
ref="CatetoryType" :options="typeList" class="q-pb-lg" v-model="objOption.CatetoryType" :rules="[val => !!val || '请选择类型']" emit-value map-options /> ref="CatetoryType" :options="typeList" class="q-pb-lg" v-model="objOption.CatetoryType"
:rules="[val => !!val || '请选择类型']" emit-value map-options />
</div>
</div>
<div class="row wrap">
<div class="col-12">
<q-field filled label="签约状态" stack-label>
<template v-slot:control>
<q-radio dense v-model="objOption.IsContract" :val="0" label="未签约" size="xs" />
&nbsp;&nbsp;
<q-radio dense v-model="objOption.IsContract" :val="1" label="已签约" size="xs" />
</template>
</q-field>
</div>
</div>
<div class="row wrap" style="margin-top:20px;">
<div class="col-12">
<template v-if="objOption.IsContract==1">
<el-upload class="upload-demo" action="" :show-file-list="false" :http-request="UploadAttachment"
:multiple="uploadMultple">
<q-btn color="accent" size="sm" icon="add" label="上传同行合同" />
</el-upload>
<a v-if="objOption.ContractUrl" style="margin-left:10px;color:#2961FE;text-decoration:none;"
:href="objOption.ContractUrl" target="_blank">
<template v-if="fileObj.FileName&&fileObj.FileName!=''">
{{fileObj.FileName}}
</template>
查看合同</a>
</template>
</div> </div>
</div> </div>
<template v-if="isShowTel"> <template v-if="isShowTel">
...@@ -120,6 +147,9 @@ ...@@ -120,6 +147,9 @@
</q-dialog> </q-dialog>
</template> </template>
<script> <script>
import {
UploadSelfFile
} from '../../api/common/common'
import { import {
saveCustomerCategory, saveCustomerCategory,
queryCustomerCategory, queryCustomerCategory,
...@@ -141,12 +171,19 @@ ...@@ -141,12 +171,19 @@
CatetoryType: '', CatetoryType: '',
CategoryId: 0, CategoryId: 0,
linkMan: "", linkMan: "",
linkTel: "" linkTel: "",
IsContract: 0, //是否签约
ContractUrl: "", //合同信息
}, },
uploadMultple: true,
typeList: [], //类型 typeList: [], //类型
saveCustomLoading: false, saveCustomLoading: false,
optionTitle: '', optionTitle: '',
isShowTel: true isShowTel: true,
fileObj: {
FileName: '',
FileUrl: ''
}
} }
}, },
created() {}, created() {},
...@@ -168,6 +205,8 @@ ...@@ -168,6 +205,8 @@
this.objOption.CategoryName = tempData.CategoryName; this.objOption.CategoryName = tempData.CategoryName;
this.objOption.CatetoryType = tempData.CatetoryType; this.objOption.CatetoryType = tempData.CatetoryType;
this.objOption.CategoryId = tempData.CategoryId; this.objOption.CategoryId = tempData.CategoryId;
this.objOption.IsContract = tempData.IsContract;
this.objOption.ContractUrl = tempData.ContractUrl;
} }
}) })
this.optionTitle = "修改客户信息" this.optionTitle = "修改客户信息"
...@@ -177,6 +216,8 @@ ...@@ -177,6 +216,8 @@
this.objOption.CategoryId = 0; this.objOption.CategoryId = 0;
this.objOption.linkMan = ''; this.objOption.linkMan = '';
this.objOption.linkTel = ''; this.objOption.linkTel = '';
this.objOption.IsContract = 0;
this.objOption.ContractUrl = '';
this.optionTitle = "新增客户信息" this.optionTitle = "新增客户信息"
this.isShowTel = true; this.isShowTel = true;
} }
...@@ -185,7 +226,7 @@ ...@@ -185,7 +226,7 @@
saveCourse() { saveCourse() {
this.$refs.CategoryName.validate(); this.$refs.CategoryName.validate();
this.$refs.CatetoryType.validate(); this.$refs.CatetoryType.validate();
if (!this.$refs.CategoryName.hasError&&!this.$refs.CatetoryType.hasError) { if (!this.$refs.CategoryName.hasError && !this.$refs.CatetoryType.hasError) {
saveCustomerCategory(this.objOption).then(res => { saveCustomerCategory(this.objOption).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.$q.notify({ this.$q.notify({
...@@ -212,8 +253,17 @@ ...@@ -212,8 +253,17 @@
closeCourseForm() { closeCourseForm() {
this.$emit('close'); this.$emit('close');
this.persistent = false; this.persistent = false;
} },
//上传附件
UploadAttachment(files) {
UploadSelfFile('Attachment', files.file, res => {
if (res.Code == 1) {
this.fileObj.FileName = res.FileName;
this.fileObj.FileUrl = res.FileUrl;
this.objOption.ContractUrl = res.FileUrl;
}
})
},
}, },
} }
</script>
</script> \ No newline at end of file
...@@ -7,7 +7,6 @@ ...@@ -7,7 +7,6 @@
cursor: pointer; cursor: pointer;
color: var(--q-color-primary); color: var(--q-color-primary);
} }
</style> </style>
<template> <template>
<div class="b2bcustomlist"> <div class="b2bcustomlist">
...@@ -25,6 +24,12 @@ ...@@ -25,6 +24,12 @@
<q-td> <q-td>
<div class="CustomerName" @click="showDetail(props.row)"> <div class="CustomerName" @click="showDetail(props.row)">
{{ props.row.CategoryName }} {{ props.row.CategoryName }}
<template v-if="props.row.IsContract==1">
<span style="color:green;">(已签约)</span>
</template>
<template v-if="props.row.IsContract==0">
<span style="color:red;">(未签约)</span>
</template>
</div> </div>
</q-td> </q-td>
</template> </template>
...@@ -248,12 +253,11 @@ ...@@ -248,12 +253,11 @@
//创建者为本人或者有权限 才能修改 //创建者为本人或者有权限 才能修改
if (UserInfo.Id === row.CreateBy || isHavePer) { if (UserInfo.Id === row.CreateBy || isHavePer) {
this.isCanEdit = true; this.isCanEdit = true;
}else{ } else {
this.isCanEdit = false; this.isCanEdit = false;
} }
this.isShowDetailForm = true; this.isShowDetailForm = true;
} }
} }
}; };
</script>
</script> \ No newline at end of file
...@@ -661,7 +661,7 @@ ...@@ -661,7 +661,7 @@
</el-select> </el-select>
</td> </td>
<td> <td>
<el-input class="w80 _border_b_1" @keyup.native="checkPrice(sitem,'YTotalPrice')" v-model="sitem.YTotalPrice"></el-input> <el-input class="w80 _border_b_1" @keyup.native="checkPrice(sitem,'YTotalPrice',true)" v-model="sitem.YTotalPrice"></el-input>
</td> </td>
<td> <td>
<el-input type="textarea" v-model="sitem.Remarks" class="w80 _border_b_1"></el-input> <el-input type="textarea" v-model="sitem.Remarks" class="w80 _border_b_1"></el-input>
...@@ -2139,8 +2139,10 @@ ...@@ -2139,8 +2139,10 @@
return return
} }
this.isSubmit=true; this.isSubmit=true;
this.loading=true;
this.apipost('Financial_post_BatchSet', this.msg, res => { this.apipost('Financial_post_BatchSet', this.msg, res => {
this.isSubmit=false; this.isSubmit=false;
this.loading=false;
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.$q.notify({ this.$q.notify({
icon: 'iconfont icon-chenggong', icon: 'iconfont icon-chenggong',
......
...@@ -49,6 +49,7 @@ ...@@ -49,6 +49,7 @@
<q-tab :name="2" label="内部渠道" /> <q-tab :name="2" label="内部渠道" />
<q-tab :name="3" label="学校渠道" /> <q-tab :name="3" label="学校渠道" />
<q-tab :name="4" label="转介渠道" /> <q-tab :name="4" label="转介渠道" />
<q-tab :name="5" label="签约渠道" />
</q-tabs> </q-tabs>
<el-table :data="dataList" ref="table" style="width: 100%;" :height="tableHeight" v-loading="loading"> <el-table :data="dataList" ref="table" style="width: 100%;" :height="tableHeight" v-loading="loading">
<el-table-column label="序号" type="index"> <el-table-column label="序号" type="index">
...@@ -178,6 +179,7 @@ ...@@ -178,6 +179,7 @@
StuSourceId: 0, StuSourceId: 0,
startTime: this.msg.startTime, startTime: this.msg.startTime,
endTime: this.msg.endTime, endTime: this.msg.endTime,
IsContract: 0
} }
var CreateType = 2; var CreateType = 2;
//同行渠道 //同行渠道
...@@ -186,6 +188,7 @@ ...@@ -186,6 +188,7 @@
param.StuSourceId = 0; param.StuSourceId = 0;
param.CategoryId = row.ChannelId; param.CategoryId = row.ChannelId;
param.CreateType = 0; param.CreateType = 0;
param.IsContract = 0;
} }
//内部渠道 //内部渠道
if (this.msg.top_Check == 2) { if (this.msg.top_Check == 2) {
...@@ -193,6 +196,7 @@ ...@@ -193,6 +196,7 @@
param.StuSourceId = row.ChannelId; param.StuSourceId = row.ChannelId;
param.CategoryId = 0; param.CategoryId = 0;
param.CreateType = CreateType; param.CreateType = CreateType;
param.IsContract = 0;
} }
//学校渠道 //学校渠道
if (this.msg.top_Check == 3) { if (this.msg.top_Check == 3) {
...@@ -200,6 +204,7 @@ ...@@ -200,6 +204,7 @@
param.StuSourceId = 0; param.StuSourceId = 0;
param.CategoryId = row.ChannelId; param.CategoryId = row.ChannelId;
param.CreateType = 0; param.CreateType = 0;
param.IsContract = 0;
} }
//转介绍渠道 //转介绍渠道
if (this.msg.top_Check == 4) { if (this.msg.top_Check == 4) {
...@@ -207,6 +212,15 @@ ...@@ -207,6 +212,15 @@
param.StuSourceId = row.ChannelId; param.StuSourceId = row.ChannelId;
param.CategoryId = 0; param.CategoryId = 0;
param.CreateType = CreateType; param.CreateType = CreateType;
param.IsContract = 0;
}
//签约渠道
if (this.msg.top_Check == 5) {
CreateType = 2;
param.StuSourceId = 0;
param.CategoryId = row.ChannelId;
param.CreateType = 0;
param.IsContract = 1;
} }
this.OpenNewUrl(url, param) this.OpenNewUrl(url, param)
}, },
...@@ -223,6 +237,9 @@ ...@@ -223,6 +237,9 @@
if (this.msg.top_Check == 4) { if (this.msg.top_Check == 4) {
fileName = "转交渠道.xls"; fileName = "转交渠道.xls";
} }
if (this.msg.top_Check == 5) {
fileName = "签约渠道.xls";
}
this.loading = true; this.loading = true;
EduDownLoad( EduDownLoad(
"/UserCenter/DownLoadMarketCreateType", "/UserCenter/DownLoadMarketCreateType",
...@@ -246,6 +263,9 @@ ...@@ -246,6 +263,9 @@
case 4: case 4:
this.dataList = this.allData.transDataList; this.dataList = this.allData.transDataList;
break; break;
case 5:
this.dataList = this.allData.contractDataList;
break;
} }
}, },
//获取数据 //获取数据
...@@ -257,16 +277,46 @@ ...@@ -257,16 +277,46 @@
this.msg.startTime = ""; this.msg.startTime = "";
this.msg.endTime = ""; this.msg.endTime = "";
} }
this.loading = true; this.loading = true;
MarketCreateType(this.msg).then(res => { MarketCreateType(this.msg).then(res => {
this.loading = false; this.loading = false;
if (res.Code == 1) { if (res.Code == 1) {
this.allData = res.Data; var tempData = res.Data;
if (tempData) {
if (tempData.contractDataList) {
tempData.contractDataList.forEach(x => {
x.VisitingRate = this.getStatical(x.VisitCount, x.ClueCount)
x.ContractRate = this.getStatical(x.OrderCount, x.VisitCount)
})
}
if (tempData.customerDataList) {
tempData.customerDataList.forEach(x => {
x.VisitingRate = this.getStatical(x.VisitCount, x.ClueCount)
x.ContractRate = this.getStatical(x.OrderCount, x.VisitCount)
})
}
if (tempData.innerDataList) {
tempData.innerDataList.forEach(x => {
x.VisitingRate = this.getStatical(x.VisitCount, x.ClueCount)
x.ContractRate = this.getStatical(x.OrderCount, x.VisitCount)
})
}
if (tempData.schoolDataList) {
tempData.schoolDataList.forEach(x => {
x.VisitingRate = this.getStatical(x.VisitCount, x.ClueCount)
x.ContractRate = this.getStatical(x.OrderCount, x.VisitCount)
})
}
if (tempData.transDataList) {
tempData.transDataList.forEach(x => {
x.VisitingRate = this.getStatical(x.VisitCount, x.ClueCount)
x.ContractRate = this.getStatical(x.OrderCount, x.VisitCount)
})
}
}
this.allData = tempData;
this.dataList = this.allData.customerDataList; this.dataList = this.allData.customerDataList;
this.dataList.forEach(x => {
x.VisitingRate = this.getStatical(x.VisitCount, x.ClueCount)
x.ContractRate = this.getStatical(x.OrderCount, x.VisitCount)
})
} }
}); });
}, },
......
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