Commit 1dffdad4 authored by yujinyao's avatar yujinyao

跟进默认选择当前的客户经理,下次跟进时间不能小于当前时间

parent 02c24a4c
......@@ -92,10 +92,11 @@ export function editCustomerFollow(data) {
})
}
export function exportCustomerFollow() {
export function exportCustomerFollow(params) {
return request({
url: '/customer/followup/export-excel',
method: 'get'
method: 'get',
params
})
}
......@@ -89,7 +89,7 @@
</el-col>
<el-col :span="13">
<el-form-item :label="$t('下次跟进时间')">
<el-date-picker v-model="form.nextTime" type="datetime" :placeholder="$t('请选择')" :disabled="isView">
<el-date-picker v-model="form.nextTime" type="datetime" :placeholder="$t('请选择')" :disabled="isView" @change="changeNextTime">
</el-date-picker>
</el-form-item>
</el-col>
......@@ -217,8 +217,8 @@ export default {
allSimplList: [],
pickerOptions: {
disabledDate(time) {
return time.getTime() < Date.now()
}
return time.getTime() <= Date.now()
},
},
isEdit: false,
queryParams: {},
......@@ -303,6 +303,16 @@ export default {
updateTime: new Date().getTime()
};
},
changeNextTime(val) {
if (val) {
const curTime = new Date().getTime()
const valTime = new Date(val).getTime()
if (curTime > valTime) {
this.form.nextTime = null
this.$modal.msgError(this.$t("不能小于当前时间"))
}
}
},
customerFollowSubmit(status) {
console.log(this.form)
this.$refs["customerFollowForm"].validate(valid => {
......
......@@ -1340,11 +1340,11 @@ export default {
],
areaCode: [
{ required: true, message: this.$t("请选择区号"), trigger: "change" },
{
/*{
required: true,
trigger: "change",
validator: this.codeValidator,
},
},*/
],
phoneNew: [
{
......
This diff is collapsed.
This diff is collapsed.
......@@ -1374,6 +1374,7 @@
<customer-follow-list
:customer-id="customerId"
:id="customerId"
:customer-service="customerService"
ref="CustomerFollowList"
v-if="customerFollowVisible"
></customer-follow-list>
......@@ -1578,6 +1579,7 @@ export default {
customData: {},
currentisNew: false,
userId: undefined, //lanbm 2024-05-23 add
customerService: undefined,
customerFollowVisible: false,
enterOpenSeaTime: [],
customerServiceConfirmedTime: [],
......@@ -1809,6 +1811,7 @@ export default {
},
followUp(row) {
this.customerId = row.id;
this.customerService = row.customerService;
this.customerFollowVisible = true
this.$nextTick(_ => {
// this.$refs.CustomerFollowList.customerFollow.dialogVisible = true;
......
......@@ -1333,25 +1333,28 @@ export default {
this.getInfoListOfferPage()
},
getCustomerFollowList() {
let queryParams = {}
if (this.followTime && this.followTime.length == 2) {
queryParams.beginFollowTime = this.followTime[0]
queryParams.endFollowTime = this.followTime[0]
}
if (this.nextTime && this.nextTime.length == 2) {
queryParams.beginNextTime = this.nextTime[0]
queryParams.endNextTime = this.nextTime[1]
}
queryParams = Object.assign({}, queryParams, this.followForm)
getCustomerFollowList({
...queryParams,
...this.followForm,
customerId: this.customerId
}).then(r => {
this.customerFollowList = r.data.list;
this.customerFollowTotal = r.data.total;
})
},
/** 跟进记录导出按钮操作 */
handleExport() {
// 执行导出
this.$modal.confirm(this.$t('是否确认导出客户跟进记录数据项?')).then(() => {
exportCustomerFollow({
...this.followForm,
customerId: this.customerId
}).then((r) => {
this.$message.success(
this.$t("已加入导出队列,请稍后在下载日志中下载")
);
});
})
},
// 数据
getOrderStatistics(){
orderStatistics({customerId:this.id}).then(r => {
......@@ -1477,17 +1480,6 @@ export default {
this.handleQuery()
})
},
/** 导出按钮操作 */
handleExport() {
// 执行导出
this.$modal.confirm(this.$t('是否确认导出客户跟进记录数据项?')).then(() => {
exportCustomerFollow().then((r) => {
this.$message.success(
this.$t("已加入导出队列,请稍后在下载日志中下载")
);
});
})
},
}
}
</script>
......@@ -729,6 +729,7 @@
ref="customerFollowList"
:customer-id="customerId"
:id="customerId"
:customer-service="customerService"
v-if="customerFollowVisible"
></customer-follow-list>
<customer-complaints
......@@ -946,6 +947,7 @@ export default {
selectCustomerList: [],
//lanbm 2024-05-26 添加参数
userId:undefined,
customerService: undefined,
customerFollowVisible: false,
enterOpenSeaTime: [],
customerServiceConfirmedTime: [],
......@@ -1236,6 +1238,7 @@ export default {
followUp(row) {
this.customerId = row.id;
// this.$refs["customerFollowList"].customerFollow.dialogVisible = true;
this.customerService = row.customerService;
this.customerFollowVisible = true
this.$nextTick(_ => {
this.$refs['customerFollowList'].init()
......
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