From fee1948081e9cecc1de29ee5029f737aef2dcb38 Mon Sep 17 00:00:00 2001
From: lzhe <lzhe@example.com>
Date: 星期二, 01 十月 2024 20:43:43 +0800
Subject: [PATCH] Merge branch 'release' of http://122.9.151.159:9090/r/smart-web into release
---
src/views/console/workstation/Dialog.vue | 20 ++++++++++++++++----
1 files changed, 16 insertions(+), 4 deletions(-)
diff --git a/src/views/console/workstation/Dialog.vue b/src/views/console/workstation/Dialog.vue
index ea60a89..4e0ddc4 100644
--- a/src/views/console/workstation/Dialog.vue
+++ b/src/views/console/workstation/Dialog.vue
@@ -92,7 +92,7 @@
</el-select>
</el-form-item>
</el-col>
- <el-col :span="12">
+ <!-- <el-col :span="12">
<el-form-item label="绋嬪簭浼犺緭鏂瑰紡" prop="transmissionMethod">
<el-select v-model="form.transmissionMethod" style="width: 240px">
<el-option label="FTP" :value="1" />
@@ -107,7 +107,7 @@
:value="item.value" />
</el-select>
</el-form-item>
- </el-col>
+ </el-col> -->
<el-col :span="12" v-if="form.ftpDirectoryType == 1">
<el-form-item label="鍏宠仈鐩綍" prop="directoryId">
<el-select v-model="form.directoryId" style="width: 240px">
@@ -309,7 +309,7 @@
})
} else {
this.form.id = ''
- this.form.workbenchVOList = res?.data?.workstationList || []
+ this.form.workbenchVOList = []
Object.keys(this.form).forEach(key => {
this.form[key] = ''
})
@@ -318,10 +318,22 @@
},
//琛ㄥ崟鎻愪氦鏂规硶
submit() {
+ if (!this.form.workbenchVOList) {
+ this.form.workbenchVOList = []
+ }
+ if (this.mode === 'add' && this.form.linkWay === 1) {
+ this.form.machineId
+ this.form.machineCode = this.form.code
+ this.form.machineName = this.form.name
+ }
this.$refs.dialogForm.validate(async (valid) => {
if (valid) {
this.isSaveing = true;
- var res = await this.$API.workstation.add.post(this.form);
+ try {
+ var res = await this.$API.workstation.add.post(this.form);
+ } catch (error) {
+ this.isSaveing = false;
+ }
this.isSaveing = false;
if (res.code == 200) {
this.$emit('success', this.form, this.mode)
--
Gitblit v1.9.3