申请人电话校验 11位
parent
d11e80011a
commit
9f6d4a30b6
|
@ -126,7 +126,7 @@
|
|||
|
||||
<el-form-item v-if="isSalesContractMode" label="申请人电话" prop="applyPersonPhone"
|
||||
:rules="[{ required: true, message: '申请人电话不能为空'}]">
|
||||
<el-input placeholder="请输入内容" v-model="processForm.applyPersonPhone"></el-input>
|
||||
<el-input placeholder="请输入内容" v-model="processForm.applyPersonPhone" maxlength="11"></el-input>
|
||||
</el-form-item>
|
||||
|
||||
</div>
|
||||
|
@ -308,9 +308,9 @@
|
|||
<el-button size="small" type="text" slot="reference">上传附件</el-button>
|
||||
<#--展示已经上传的文件-->
|
||||
<div v-if="scope.row.attachment">
|
||||
<el-tag size="small" v-for="attachment in scope.row.attachment"
|
||||
<el-tag size="small" v-for="attachment in scope.row.attachment" closable
|
||||
@close="removeSupplierMaterialAttachment(scope, attachment)">
|
||||
<a :href="attachment.uri">
|
||||
<a :href="attachment.uri" target="_blank">
|
||||
<i class="el-icon-document"></i> {{attachment.name}}
|
||||
</a>
|
||||
</el-tag>
|
||||
|
@ -822,14 +822,14 @@
|
|||
const processType = this.processType
|
||||
const supplierMaterialsForm = this.supplierMaterialsForm
|
||||
|
||||
if (fileList && fileList.length === 0) {
|
||||
this.$message.error("未上传附件");
|
||||
return false
|
||||
}
|
||||
|
||||
let validStatus = !needValid
|
||||
if (needValid) {
|
||||
// 校验表单
|
||||
if (fileList && fileList.length === 0) {
|
||||
this.$message.error("未上传附件");
|
||||
return false
|
||||
}
|
||||
|
||||
this.$refs["contractProcessForm"].validate((valid) => {
|
||||
if (valid) {
|
||||
if (processType === saleContract) {
|
||||
|
@ -1074,6 +1074,8 @@
|
|||
name: file.name
|
||||
})
|
||||
|
||||
console.log(attachments)
|
||||
console.log(scope.row['attachment'])
|
||||
this.$message.success("上传成功");
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -233,7 +233,7 @@
|
|||
<el-form-item v-if="isSalesContractMode" label="申请人电话" prop="applyPersonPhone"
|
||||
:rules="[{ required: true, message: '申请人电话不能为空'},
|
||||
{ pattern:/^((0\d{2,3}-\d{7,8})|(1[3584]\d{9}))$/, message: '请输入合法手机号', trigger: 'blur' }]">
|
||||
<el-input placeholder="请输入内容" v-model="processForm.applyPersonPhone"></el-input>
|
||||
<el-input placeholder="请输入内容" v-model="processForm.applyPersonPhone" maxlength="11"></el-input>
|
||||
</el-form-item>
|
||||
|
||||
</div>
|
||||
|
@ -420,9 +420,9 @@
|
|||
<el-button size="small" type="text" slot="reference">上传附件</el-button>
|
||||
<#--展示已经上传的文件-->
|
||||
<div v-if="scope.row.attachment">
|
||||
<el-tag size="small" v-for="attachment in scope.row.attachment"
|
||||
<el-tag size="small" v-for="attachment in scope.row.attachment" closable :key="attachment.name"
|
||||
@close="removeSupplierMaterialAttachment(scope, attachment)">
|
||||
<a :href="attachment.uri">
|
||||
<a :href="attachment.uri" target="_blank">
|
||||
<i class="el-icon-document"></i> {{attachment.name}}
|
||||
</a>
|
||||
</el-tag>
|
||||
|
@ -990,12 +990,12 @@
|
|||
this.$message.error("未选择项目");
|
||||
return false
|
||||
}
|
||||
if (fileList && fileList.length === 0) {
|
||||
this.$message.error("未上传附件");
|
||||
return false
|
||||
}
|
||||
let validStatus = !needValid
|
||||
if (needValid) {
|
||||
if (fileList && fileList.length === 0) {
|
||||
this.$message.error("未上传附件");
|
||||
return false
|
||||
}
|
||||
// 校验表单
|
||||
this.$refs["contractProcessForm"].validate((valid) => {
|
||||
if (valid) {
|
||||
|
@ -1242,7 +1242,6 @@
|
|||
|
||||
handleSupplierMaterialFileUploaded(scope, response, file, fileList) {
|
||||
if (response.success) {
|
||||
console.log(fileList)
|
||||
let attachments = scope.row['attachment']
|
||||
if (isEmpty(attachments)) {
|
||||
attachments = []
|
||||
|
@ -1253,6 +1252,9 @@
|
|||
name: file.name
|
||||
})
|
||||
|
||||
console.log(attachments)
|
||||
console.log(scope.row['attachment'])
|
||||
|
||||
this.$message.success("上传成功");
|
||||
}
|
||||
else {
|
||||
|
|
Loading…
Reference in New Issue