@ -12,7 +12,7 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="业务员" prop="userId">
|
||||
<el-select v-model="queryParams.userId" placeholder="请选择业务员" clearable size="small">
|
||||
<el-select v-model="queryParams.userId" filterable placeholder="请选择业务员" clearable size="small">
|
||||
<el-option
|
||||
v-for="dict in searchUserIdOptions"
|
||||
:key="dict.dictValue"
|
||||
|
@ -12,7 +12,7 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="业务员" prop="userId">
|
||||
<el-select v-model="queryParams.userId" placeholder="请选择业务员" clearable size="small">
|
||||
<el-select v-model="queryParams.userId" filterable placeholder="请选择业务员" clearable size="small">
|
||||
<el-option
|
||||
v-for="dict in searchUserIdOptions"
|
||||
:key="dict.dictValue"
|
||||
@ -21,14 +21,14 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!--<el-form-item label="月份" prop="month">
|
||||
<el-form-item label="月份" prop="month">
|
||||
<el-date-picker
|
||||
v-model="month"
|
||||
@change="monthRangeChange"
|
||||
type="month"
|
||||
placeholder="选择月">
|
||||
placeholder="选择月份">
|
||||
</el-date-picker>
|
||||
</el-form-item>-->
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||
@ -239,7 +239,7 @@
|
||||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.resetForm("queryForm");
|
||||
this.handleQuery();
|
||||
//this.handleQuery();
|
||||
this.searchUserIdOptions = this.totalUserIdOptions.slice();
|
||||
},
|
||||
// 多选框选中数据
|
||||
|
@ -54,14 +54,14 @@
|
||||
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
<!--<el-button
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="handleAdd"
|
||||
v-hasPermi="['custom:contract:add']"
|
||||
>新增
|
||||
</el-button>
|
||||
</el-button>-->
|
||||
</el-col>
|
||||
<!-- <el-col :span="1.5">-->
|
||||
<!-- <el-button-->
|
||||
|
@ -25,7 +25,7 @@
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="主营养师" prop="mainDietitian">
|
||||
<!--<el-form-item label="主营养师" prop="mainDietitian">
|
||||
<el-input
|
||||
v-model="queryParams.mainDietitian"
|
||||
placeholder="请输入主营养师"
|
||||
@ -60,7 +60,7 @@
|
||||
size="small"
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-form-item>-->
|
||||
<el-form-item>
|
||||
<el-button
|
||||
type="cyan"
|
||||
@ -149,7 +149,7 @@
|
||||
prop="salesman"
|
||||
:formatter="preSaleIdFormat"
|
||||
/>
|
||||
<el-table-column label="订单" align="center">
|
||||
<el-table-column label="订单" align="center" v-hasPermi="['custom:order:list']">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
@ -159,7 +159,7 @@
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="合同" align="center">
|
||||
<el-table-column label="合同" align="center" v-hasPermi="['custom:contract:list']">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
@ -169,7 +169,7 @@
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="健康评估" align="center">
|
||||
<el-table-column label="健康评估" align="center" v-hasPermi="['custom:healthy:list']">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
@ -179,7 +179,7 @@
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="食谱计划" align="center">
|
||||
<el-table-column label="食谱计划" align="center" v-hasPermi="['recipes:recipesPlan:list']">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
|
@ -76,6 +76,7 @@
|
||||
v-model="queryParams.preSaleId"
|
||||
placeholder="请选择售前"
|
||||
clearable
|
||||
filterable
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
@ -93,6 +94,7 @@
|
||||
v-model="queryParams.afterSaleId"
|
||||
placeholder="请选择售后"
|
||||
clearable
|
||||
filterable
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
@ -110,6 +112,7 @@
|
||||
v-model="queryParams.nutritionistId"
|
||||
placeholder="请选择主营养师"
|
||||
clearable
|
||||
filterable
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
@ -131,6 +134,7 @@
|
||||
v-model="queryParams.nutriAssisId"
|
||||
placeholder="请选择营养师助理"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 170px"
|
||||
size="small"
|
||||
>
|
||||
@ -149,6 +153,7 @@
|
||||
v-model="queryParams.plannerId"
|
||||
placeholder="请选择策划"
|
||||
clearable
|
||||
filterable
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
@ -166,6 +171,7 @@
|
||||
v-model="queryParams.plannerAssisId"
|
||||
placeholder="请选择策划助理"
|
||||
clearable
|
||||
filterable
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
@ -183,6 +189,7 @@
|
||||
v-model="queryParams.operatorId"
|
||||
placeholder="请选择运营"
|
||||
clearable
|
||||
filterable
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
@ -200,6 +207,7 @@
|
||||
v-model="queryParams.operatorAssisId"
|
||||
placeholder="请选择运营助理"
|
||||
clearable
|
||||
filterable
|
||||
size="small"
|
||||
>
|
||||
<el-option
|
||||
@ -250,7 +258,6 @@
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
value-format="yyyy-MM-dd"
|
||||
:picker-options="pickerOptions"
|
||||
>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
@ -379,14 +386,14 @@
|
||||
v-hasPermi="['custom:order:edit']"
|
||||
>修改
|
||||
</el-button>
|
||||
<!-- <el-button
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-s-data"
|
||||
@click="orderPauseManage(scope.row)"
|
||||
v-hasPermi="['orderPause:pause:query']"
|
||||
>暂停记录管理
|
||||
</el-button> -->
|
||||
</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
|
@ -10,10 +10,14 @@
|
||||
</div>
|
||||
<el-form ref="form" label-position="top" :model="form" :rules="rules" label-width="100px" style="padding: 16px">
|
||||
<div v-show="stepArray[0]">
|
||||
<p class="p_title_1" style="margin-top: 5px;">{{healthyData['titleArray'][0]}}</p>
|
||||
<el-form-item label="真实姓名" prop="name" style="padding-top: 10px;">
|
||||
<el-input v-model="form.name" placeholder="请输入真实姓名" maxlength="20"/>
|
||||
<p class="p_title_1" style="margin-top: 10px;">{{healthyData['titleArray'][0]}}</p>
|
||||
<p style="font-size: 15px; margin-bottom: 12px;margin-top: 10px;">请您确认下方姓名、手机号是否正确</p>
|
||||
<el-form-item label="真实姓名" prop="name">
|
||||
<el-input v-model="form.name" :readonly="true" placeholder="请输入真实姓名" maxlength="20"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="手机号" prop="phone" >
|
||||
<el-input type="number" :readonly="true" v-model="form.phone" placeholder="请输入手机号" />
|
||||
</el-form-item>
|
||||
<el-form-item label="性别" prop="sex">
|
||||
<el-radio-group v-model="form.sex" size="small" >
|
||||
<el-radio :label="parseInt('0')" border>男</el-radio>
|
||||
@ -29,10 +33,6 @@
|
||||
<el-form-item label="体重(斤)" prop="weight" >
|
||||
<el-input type="number" v-model="form.weight" placeholder="请输入体重" autocomplete="off" ></el-input>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="手机号" prop="phone" >
|
||||
<el-input type="number" v-model="form.phone" placeholder="请输入手机号" />
|
||||
</el-form-item>
|
||||
<el-form-item label="调理项目" prop="conditioningProjectId">
|
||||
<el-select v-model="form.conditioningProjectId" filterable clearable placeholder="请选择">
|
||||
<el-option
|
||||
@ -652,7 +652,7 @@
|
||||
</section>
|
||||
</template>
|
||||
<script>
|
||||
import { getDictData,addCustomerHealthy,physicalSignsList } from "@/api/custom/customerInvestigation";
|
||||
import { getDictData,addCustomerHealthy,physicalSignsList,getCustomerBaseMessage } from "@/api/custom/customerInvestigation";
|
||||
import * as healthyData from "@/utils/healthyData";
|
||||
const logo = require("@/assets/logo/st_logo.png");
|
||||
export default {
|
||||
@ -665,6 +665,8 @@ export default {
|
||||
callback();
|
||||
};
|
||||
return {
|
||||
//客户是否存在标识
|
||||
customerExistFlag:false,
|
||||
healthyData:healthyData,
|
||||
logo,
|
||||
submitFlag: false,
|
||||
@ -675,6 +677,7 @@ export default {
|
||||
stepArray: [true,false,false,false,false,false,false,false,false],
|
||||
stepActive: 0,
|
||||
form: {
|
||||
customerEncId: null,
|
||||
name: null,
|
||||
phone: null,
|
||||
conditioningProjectId: 0,
|
||||
@ -801,10 +804,10 @@ export default {
|
||||
},
|
||||
timer: null,
|
||||
rules: {
|
||||
name: [
|
||||
/*name: [
|
||||
{ required: true, trigger: "blur", message: "请填写姓名" },
|
||||
{ min: 1, max: 20, trigger: "blur", message: "姓名过长" },
|
||||
],
|
||||
],*/
|
||||
sex: [{ required: true, trigger: "blur", message: "请选择性别" }],
|
||||
age: [
|
||||
{ required: true, trigger: "blur", message: "请填写年龄" },
|
||||
@ -833,7 +836,7 @@ export default {
|
||||
message: "体重格式不正确",
|
||||
},
|
||||
],
|
||||
phone: [
|
||||
/*phone: [
|
||||
{ required: true, trigger: "blur", message: "请填写手机号" },
|
||||
{ required: true, trigger: "blur", message: "请填写正确的手机号" },
|
||||
{
|
||||
@ -842,7 +845,7 @@ export default {
|
||||
pattern: /^[0-9]{5,11}$/,
|
||||
message: "手机号格式不正确",
|
||||
},
|
||||
],
|
||||
],*/
|
||||
conditioningProjectId:[
|
||||
{ required: true, trigger: "blur", message: "请选择调理项目" }
|
||||
],
|
||||
@ -853,6 +856,24 @@ export default {
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
//根据用户ID获取用户基本信息(手机号、姓名)
|
||||
getCustomerBase(id){
|
||||
if(id == null || id == undefined){
|
||||
return;
|
||||
}
|
||||
getCustomerBaseMessage(id).then((response) => {
|
||||
if (response.code === 200) {
|
||||
if(response.data){
|
||||
console.log(response.data);
|
||||
this.customerExistFlag = true;
|
||||
this.form.name = response.data.name;
|
||||
this.form.phone = response.data.phone;
|
||||
}
|
||||
}
|
||||
}).catch(function() {
|
||||
console.log("error");
|
||||
});
|
||||
},
|
||||
submit(){
|
||||
if (this.submitFlag) {
|
||||
this.$message({
|
||||
@ -885,7 +906,7 @@ export default {
|
||||
this.healthyData['arrayName'].forEach(function (item, index) {
|
||||
cusMessage[item] = cusMessage[item] != null ? cusMessage[item].join(",") : null;
|
||||
});
|
||||
this.timer = setTimeout(this.fail,1000*60);
|
||||
//this.timer = setTimeout(this.fail,1000*60);
|
||||
addCustomerHealthy(cusMessage).then((response) => {
|
||||
if (response.code === 200) {
|
||||
this.$notify({
|
||||
@ -899,11 +920,14 @@ export default {
|
||||
});
|
||||
},
|
||||
fail(){
|
||||
console.log("fail");
|
||||
this.submitFlag = false;
|
||||
this.upload.isUploading = false;
|
||||
},
|
||||
nextStep(step){
|
||||
if(!this.customerExistFlag){
|
||||
this.$message.error('客户不存在');
|
||||
return;
|
||||
}
|
||||
this.$refs.form.validate((valid) => {
|
||||
if(valid || step < 0){
|
||||
this.stepArray[this.stepActive] = false;
|
||||
@ -928,15 +952,6 @@ export default {
|
||||
},
|
||||
//监控上传文件列表
|
||||
handleFileChange(file, fileList) {
|
||||
/*console.log("------------")
|
||||
let existFile = fileList.slice(0, fileList.length - 1).find(f => f.name === file.name);
|
||||
if (existFile) {
|
||||
this.$message({
|
||||
message: "当前文件已经存在",
|
||||
type: "warning",
|
||||
});
|
||||
fileList.pop();
|
||||
}*/
|
||||
let sizeFlag = file.size > this.upload.fileSize;
|
||||
if (sizeFlag) {
|
||||
this.$message({
|
||||
@ -1000,6 +1015,8 @@ export default {
|
||||
},
|
||||
},
|
||||
created() {
|
||||
this.form.customerEncId = this.$route.params.id;
|
||||
this.getCustomerBase(this.form.customerEncId);
|
||||
this.getDict("conditioning_project");
|
||||
this.getPhysicalSignsList();
|
||||
this.getMoistureDictData();
|
||||
|
Reference in New Issue
Block a user