|
@@ -313,6 +313,41 @@ export default {
|
|
|
spinner: 'el-icon-loading',
|
|
|
background: 'rgba(255,255,255,0.7)'
|
|
|
});
|
|
|
+ // 获取联系人信息和地址信息的数据列表
|
|
|
+ const contacts = this.form.corpsAttnList;
|
|
|
+ const addresses = this.form.corpsAddrList;
|
|
|
+ console.log(contacts);
|
|
|
+ console.log(addresses);
|
|
|
+ if (!contacts.length) {
|
|
|
+ // 联系人地址为空,阻止保存并显示错误提示
|
|
|
+ this.$message.error('联系人不能为空');
|
|
|
+ loading.close();
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ if (!addresses.length) {
|
|
|
+ // 地址为空,阻止保存并显示错误提示
|
|
|
+ this.$message.error('地址不能为空');
|
|
|
+ loading.close();
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ // 验证联系人信息
|
|
|
+ // for (const contact of contacts) {
|
|
|
+ // if (!contact.address) {
|
|
|
+ // // 联系人地址为空,阻止保存并显示错误提示
|
|
|
+ // this.$message.error('联系人地址不能为空');
|
|
|
+ // return;
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+
|
|
|
+ // // 验证地址信息
|
|
|
+ // for (const address of addresses) {
|
|
|
+ // if (!address.address) {
|
|
|
+ // // 地址为空,阻止保存并显示错误提示
|
|
|
+ // this.$message.error('地址不能为空');
|
|
|
+ // return;
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+
|
|
|
submit({
|
|
|
...this.form,
|
|
|
corpType: "GYS"
|