mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-23 09:56:45 +08:00
合并鼎诚919
This commit is contained in:
@@ -2,7 +2,15 @@
|
||||
<div class="container">
|
||||
<p class="title pl10 pv5">基本信息</p>
|
||||
<div v-if="source == 'app'">
|
||||
<van-field v-model="userInfo.customerName" required clearable label="姓名" name="姓名" placeholder="请输入" v-validate="'required|name'" />
|
||||
<van-field
|
||||
v-model="userInfo.customerName"
|
||||
required
|
||||
clearable
|
||||
label="姓名"
|
||||
name="姓名"
|
||||
placeholder="请输入"
|
||||
v-validate="'required|name'"
|
||||
/>
|
||||
<van-field
|
||||
v-model="userInfo.customerPhone"
|
||||
required
|
||||
@@ -28,10 +36,8 @@
|
||||
<script>
|
||||
import { Field, CellGroup, Cell } from 'vant'
|
||||
import { getAgentCustomerInfo, updateCustomerInfo } from '@/api/ebiz/customer/customer'
|
||||
import occupationList from '@/components/ebiz/occipation/data/occupation.js'
|
||||
import formBlock from '@/components/ebiz/customer/formBlock'
|
||||
import { constants } from 'crypto'
|
||||
import utilsAge from '@/assets/js/utils/age'
|
||||
|
||||
export default {
|
||||
name: 'editCustomer',
|
||||
@@ -46,7 +52,7 @@ export default {
|
||||
source: this.$route.query.from,
|
||||
appName: this.$route.query.name,
|
||||
appPhone: this.$route.query.tel,
|
||||
customerNumber: this.$route.query.id,
|
||||
customerNumber: localStorage.getItem('customerNumber'),
|
||||
userInfo: {
|
||||
customerName: '', //姓名
|
||||
customerPhone: '', // 手机号
|
||||
@@ -89,18 +95,20 @@ export default {
|
||||
homeArea: '', //家庭区
|
||||
homeAddress: '', //家庭详细地址
|
||||
homeZip: '', //家庭邮编
|
||||
homePhone: '' //单位电话
|
||||
homePhone: '' //家庭电话
|
||||
}
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
//this.filterBtn() //按钮初始化
|
||||
this.getCustomerInfo() //获取客户信息
|
||||
//window.appCallBack = this.appCallBack //app回调
|
||||
//数据回显
|
||||
if (this.source) {
|
||||
if (this.source == 'app') {
|
||||
this.userInfo.customerName = this.appName
|
||||
this.userInfo.customerPhone = this.appPhone
|
||||
this.customerNumber = ''
|
||||
} else {
|
||||
this.getCustomerInfo() //获取客户信息
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -192,6 +200,8 @@ export default {
|
||||
if (result.indexOf(false) > -1) {
|
||||
this.$toast(this.$refs.formBlock.$validator.errors.all()[0])
|
||||
return
|
||||
} else if (this.userInfo.customerIdNumber) {
|
||||
this.$refs.formBlock.validateIdType()
|
||||
} else {
|
||||
this.updateCustomerInfo()
|
||||
}
|
||||
@@ -262,7 +272,7 @@ export default {
|
||||
flag: 'goBack',
|
||||
extra: {
|
||||
refresh: '1',
|
||||
index: this.$route.query.from == 1 ? '-2' : '-1'
|
||||
index: this.$route.query.from == 2 ? '-2' : '-1'
|
||||
},
|
||||
routerInfo: {
|
||||
path: '/customer/customerList'
|
||||
|
||||
Reference in New Issue
Block a user