|
@@ -15,7 +15,7 @@
|
|
<el-form-item label="客户名称" prop="workClientInfo.name" :rules="[
|
|
<el-form-item label="客户名称" prop="workClientInfo.name" :rules="[
|
|
{required: true, message:'请输入客户名称', trigger:'blur'}
|
|
{required: true, message:'请输入客户名称', trigger:'blur'}
|
|
]">
|
|
]">
|
|
- <el-input @blur="isExistByName" v-model="inputForm.workClientInfo.name" placeholder="请输入客户名称"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" @blur="isExistByName" v-model="inputForm.workClientInfo.name" placeholder="请输入客户名称"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
<el-col :span="2">
|
|
<el-col :span="2">
|
|
@@ -88,7 +88,7 @@
|
|
:rules="[
|
|
:rules="[
|
|
{required: true, message:'请输入统一社会信用代码', trigger:'blur'}
|
|
{required: true, message:'请输入统一社会信用代码', trigger:'blur'}
|
|
]">
|
|
]">
|
|
- <el-input @blur="isExistByUscCode" v-model="inputForm.workClientInfo.uscCode" placeholder="请输入统一社会信用代码"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" @blur="isExistByUscCode" v-model="inputForm.workClientInfo.uscCode" placeholder="请输入统一社会信用代码"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
@@ -158,26 +158,27 @@
|
|
|
|
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
<el-form-item label="法人代表" prop="workClientInfo.lawerPresint">
|
|
<el-form-item label="法人代表" prop="workClientInfo.lawerPresint">
|
|
- <el-input v-model="inputForm.workClientInfo.lawerPresint" placeholder="请填写法人代表"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" v-model="inputForm.workClientInfo.lawerPresint" placeholder="请填写法人代表"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
<el-form-item label="邮政编码" prop="workClientInfo.zipCode">
|
|
<el-form-item label="邮政编码" prop="workClientInfo.zipCode">
|
|
- <el-input v-model="inputForm.workClientInfo.zipCode" placeholder="请填写邮政编码"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" v-model="inputForm.workClientInfo.zipCode" placeholder="请填写邮政编码"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
<el-form-item label="传真" prop="workClientInfo.fax">
|
|
<el-form-item label="传真" prop="workClientInfo.fax">
|
|
- <el-input v-model="inputForm.workClientInfo.fax" placeholder="请填写传真"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" v-model="inputForm.workClientInfo.fax" placeholder="请填写传真"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
<el-form-item label="公司电话" prop="workClientInfo.telephone"
|
|
<el-form-item label="公司电话" prop="workClientInfo.telephone"
|
|
:rules="[
|
|
:rules="[
|
|
- {validator: this.validatorXG.isMobile, trigger: 'blur'}
|
|
|
|
|
|
+ {validator: validatorXG.isPhoneOrMobile, trigger: 'change'},
|
|
|
|
+ {validator: validatorXG.isPhoneOrMobile, trigger: 'blur'}
|
|
]">
|
|
]">
|
|
<el-input v-model="inputForm.workClientInfo.telephone" placeholder="请填写公司电话"></el-input>
|
|
<el-input v-model="inputForm.workClientInfo.telephone" placeholder="请填写公司电话"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
@@ -185,7 +186,7 @@
|
|
|
|
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
<el-form-item label="公司网址" prop="workClientInfo.companyUrl">
|
|
<el-form-item label="公司网址" prop="workClientInfo.companyUrl">
|
|
- <el-input v-model="inputForm.workClientInfo.companyUrl" placeholder="请填写公司网址"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" v-model="inputForm.workClientInfo.companyUrl" placeholder="请填写公司网址"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
@@ -193,13 +194,13 @@
|
|
|
|
|
|
<el-col :span="24">
|
|
<el-col :span="24">
|
|
<el-form-item label="注册地址" prop="workClientInfo.registerAddress">
|
|
<el-form-item label="注册地址" prop="workClientInfo.registerAddress">
|
|
- <el-input v-model="inputForm.workClientInfo.registerAddress" placeholder="请填写注册地址"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="128" v-model="inputForm.workClientInfo.registerAddress" placeholder="请填写注册地址"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="24">
|
|
<el-col :span="24">
|
|
<el-form-item label="详细地址" prop="workClientInfo.address">
|
|
<el-form-item label="详细地址" prop="workClientInfo.address">
|
|
- <el-input v-model="inputForm.workClientInfo.address" placeholder="请填写详细地址"></el-input>
|
|
|
|
|
|
+ <el-input maxlength="128" v-model="inputForm.workClientInfo.address" placeholder="请填写详细地址"></el-input>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
@@ -237,7 +238,7 @@
|
|
|
|
|
|
<vxe-table-column field="ourBank" title="开户银行" :edit-render="{}">
|
|
<vxe-table-column field="ourBank" title="开户银行" :edit-render="{}">
|
|
<template v-slot:edit="scope" >
|
|
<template v-slot:edit="scope" >
|
|
- <el-input v-model="scope.row.ourBank" ></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" v-model="scope.row.ourBank" ></el-input>
|
|
</template>
|
|
</template>
|
|
</vxe-table-column>
|
|
</vxe-table-column>
|
|
<vxe-table-column field="bankNumber" title="开户账号" :edit-render="{}">
|
|
<vxe-table-column field="bankNumber" title="开户账号" :edit-render="{}">
|
|
@@ -247,7 +248,7 @@
|
|
</vxe-table-column>
|
|
</vxe-table-column>
|
|
<vxe-table-column field="remarks" title="备注信息" :edit-render="{}">
|
|
<vxe-table-column field="remarks" title="备注信息" :edit-render="{}">
|
|
<template v-slot:edit="scope" >
|
|
<template v-slot:edit="scope" >
|
|
- <el-input v-model="scope.row.remarks" ></el-input>
|
|
|
|
|
|
+ <el-input maxlength="64" v-model="scope.row.remarks" ></el-input>
|
|
</template>
|
|
</template>
|
|
</vxe-table-column>
|
|
</vxe-table-column>
|
|
<vxe-table-column title="操作" width="100">
|
|
<vxe-table-column title="操作" width="100">
|
|
@@ -280,17 +281,17 @@
|
|
|
|
|
|
<vxe-table-column field="name" title="联系人姓名" :edit-render="{}">
|
|
<vxe-table-column field="name" title="联系人姓名" :edit-render="{}">
|
|
<template v-slot:edit="scope">
|
|
<template v-slot:edit="scope">
|
|
- <el-input v-model="scope.row.name" ></el-input>
|
|
|
|
|
|
+ <el-input maxlength="10" v-model="scope.row.name" ></el-input>
|
|
</template>
|
|
</template>
|
|
</vxe-table-column>
|
|
</vxe-table-column>
|
|
<vxe-table-column field="office" title="部门" :edit-render="{}">
|
|
<vxe-table-column field="office" title="部门" :edit-render="{}">
|
|
<template v-slot:edit="scope">
|
|
<template v-slot:edit="scope">
|
|
- <el-input v-model="scope.row.office" ></el-input>
|
|
|
|
|
|
+ <el-input maxlength="10" v-model="scope.row.office" ></el-input>
|
|
</template>
|
|
</template>
|
|
</vxe-table-column>
|
|
</vxe-table-column>
|
|
<vxe-table-column field="position" title="职务" :edit-render="{}">
|
|
<vxe-table-column field="position" title="职务" :edit-render="{}">
|
|
<template v-slot:edit="scope">
|
|
<template v-slot:edit="scope">
|
|
- <el-input v-model="scope.row.position" ></el-input>
|
|
|
|
|
|
+ <el-input maxlength="10" v-model="scope.row.position" ></el-input>
|
|
</template>
|
|
</template>
|
|
</vxe-table-column>
|
|
</vxe-table-column>
|
|
<vxe-table-column field="qq" title="QQ" :edit-render="{}">
|
|
<vxe-table-column field="qq" title="QQ" :edit-render="{}">
|
|
@@ -330,7 +331,7 @@
|
|
zIndex="9999"/>
|
|
zIndex="9999"/>
|
|
<span slot="footer" class="dialog-footer">
|
|
<span slot="footer" class="dialog-footer">
|
|
<el-button size="small" @click="close(),closeXTable()" icon="el-icon-circle-close">关闭</el-button>
|
|
<el-button size="small" @click="close(),closeXTable()" icon="el-icon-circle-close">关闭</el-button>
|
|
- <el-button size="small" type="primary" v-if="method != 'view'" @click="doSubmit()" icon="el-icon-circle-check" v-noMoreClick :disabled="isSubmit">确定</el-button>
|
|
|
|
|
|
+ <el-button size="small" type="primary" v-if="method != 'view'" @click="doSubmit()" icon="el-icon-circle-check" v-noMoreClick >确定</el-button>
|
|
</span>
|
|
</span>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
</div>
|
|
</div>
|
|
@@ -353,7 +354,6 @@
|
|
dataListNew: [],
|
|
dataListNew: [],
|
|
title: '',
|
|
title: '',
|
|
method: '',
|
|
method: '',
|
|
- isSubmit: false,
|
|
|
|
visible: false,
|
|
visible: false,
|
|
loading: false,
|
|
loading: false,
|
|
returnForm: {
|
|
returnForm: {
|
|
@@ -482,12 +482,8 @@
|
|
let value = this.inputForm.workClientInfo.name
|
|
let value = this.inputForm.workClientInfo.name
|
|
if (value !== null && value !== undefined && value !== '') {
|
|
if (value !== null && value !== undefined && value !== '') {
|
|
this.workClientService.isExist(value).then((data) => {
|
|
this.workClientService.isExist(value).then((data) => {
|
|
- console.log('data', data.data)
|
|
|
|
if (data.data !== 0) {
|
|
if (data.data !== 0) {
|
|
this.$message.error('该客户名称已存在')
|
|
this.$message.error('该客户名称已存在')
|
|
- this.isSubmit = true
|
|
|
|
- } else {
|
|
|
|
- this.isSubmit = false
|
|
|
|
}
|
|
}
|
|
})
|
|
})
|
|
}
|
|
}
|
|
@@ -496,12 +492,8 @@
|
|
let value = this.inputForm.workClientInfo.uscCode
|
|
let value = this.inputForm.workClientInfo.uscCode
|
|
if (value !== null && value !== undefined && value !== '') {
|
|
if (value !== null && value !== undefined && value !== '') {
|
|
this.workClientService.isExist(value).then((data) => {
|
|
this.workClientService.isExist(value).then((data) => {
|
|
- console.log('data', data.data)
|
|
|
|
if (data.data !== 0) {
|
|
if (data.data !== 0) {
|
|
this.$message.error('该统一社会信用代码已存在')
|
|
this.$message.error('该统一社会信用代码已存在')
|
|
- this.isSubmit = true
|
|
|
|
- } else {
|
|
|
|
- this.isSubmit = false
|
|
|
|
}
|
|
}
|
|
})
|
|
})
|
|
}
|
|
}
|
|
@@ -644,6 +636,9 @@
|
|
},
|
|
},
|
|
// 表单提交
|
|
// 表单提交
|
|
doSubmit () {
|
|
doSubmit () {
|
|
|
|
+ if (this.isExistByName() === undefined) {
|
|
|
|
+ return
|
|
|
|
+ }
|
|
if (this.$refs.uploadComponent.checkProgress()) {
|
|
if (this.$refs.uploadComponent.checkProgress()) {
|
|
this.loading = false
|
|
this.loading = false
|
|
return
|
|
return
|
|
@@ -712,13 +707,13 @@
|
|
flag = false
|
|
flag = false
|
|
return
|
|
return
|
|
}
|
|
}
|
|
- if (!this.validateXG.isMobile(item.linkPhone)) {
|
|
|
|
|
|
+ if (!this.validateXG.isPhoneOrMobile(item.linkPhone)) {
|
|
this.$message.error('联系人联系方式1填写不正确')
|
|
this.$message.error('联系人联系方式1填写不正确')
|
|
this.loading = false
|
|
this.loading = false
|
|
flag = false
|
|
flag = false
|
|
return
|
|
return
|
|
}
|
|
}
|
|
- if (!this.validateXG.isMobile(item.linkMobile)) {
|
|
|
|
|
|
+ if (!this.validateXG.isPhoneOrMobile(item.linkMobile)) {
|
|
this.$message.error('联系人联系方式2填写不正确')
|
|
this.$message.error('联系人联系方式2填写不正确')
|
|
this.loading = false
|
|
this.loading = false
|
|
flag = false
|
|
flag = false
|
|
@@ -728,6 +723,31 @@
|
|
return
|
|
return
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ if (this.inputForm.workClientLinkman.length !== 0) {
|
|
|
|
+ let flag = true
|
|
|
|
+ this.inputForm.workClientLinkman.forEach(item => {
|
|
|
|
+ if (!this.commonJS.isEmpty(item.email)) {
|
|
|
|
+ if (!this.validateXG.isEmail(item.email)) {
|
|
|
|
+ this.$message.error('联系人信息-Email填写不正确')
|
|
|
|
+ this.loading = false
|
|
|
|
+ flag = false
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ if (!this.commonJS.isEmpty(item.qq)) {
|
|
|
|
+ if (!this.validate.isQq(item.qq)) {
|
|
|
|
+ this.$message.error('联系人信息-qq填写不正确')
|
|
|
|
+ this.loading = false
|
|
|
|
+ flag = false
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ flag = true
|
|
|
|
+ })
|
|
|
|
+ if (flag === false) {
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
|
|
this.inputForm.workClientInfo.deputy = this.inputForm.workClientInfo.deputyList.join(',')
|
|
this.inputForm.workClientInfo.deputy = this.inputForm.workClientInfo.deputyList.join(',')
|
|
|
|
|