Просмотр исходного кода

退回、挂起其他选项优化

HD_wangm 4 месяцев назад
Родитель
Сommit
ff924948d3

+ 8 - 0
ygtx-ui/src/components/gxtOrder/suspend.vue

@@ -167,6 +167,14 @@ const handleSubmit = async () => {
     }
   })
 }
+
+// 挂起原因变化处理
+const handleSuspendReasonChange = (val) => {
+  // 选中4工作票编号时修改其他值
+  if (val != '4') {
+    formData.value.suspendExplain = undefined
+  }
+}
 </script>
 
 <style scoped>

+ 12 - 0
ygtx-ui/src/components/repairOrder/return.vue

@@ -57,6 +57,7 @@
               placeholder="请选择退回类型"
               style="width: 100%"
               :disabled="formData.workOrderStatus === 'return'"
+              @change="handleReturnTypeChange"
             >
               <el-option
                 v-for="dict in returnTypeOptions"
@@ -73,6 +74,7 @@
                 v-model="formData.acceptReturnType"
                 placeholder="请选择退回类型"
                 style="width: 100%"
+                @change="handleReturnTypeChange"
             >
               <el-option
                   v-for="dict in returnTypeOptions"
@@ -252,6 +254,16 @@ const handleSubmit = async () => {
     }
   })
 }
+
+// 退回原因变化处理
+const handleReturnTypeChange = (val) => {
+  // 选中2工作票编号时修改其他值
+  if (val != '0') {
+    formData.value.returnReason = undefined
+    formData.value.acceptReturnReason = undefined
+  }
+}
+
 </script>
 
 <style scoped>

+ 9 - 1
ygtx-ui/src/components/repairOrder/suspend.vue

@@ -20,7 +20,7 @@
         </el-col>
         <el-col :span="12">
           <el-form-item label="挂起原因" prop="suspendReason">
-            <el-select v-model="formData.suspendReason" placeholder="请选择挂起原因" style="width: 100%">
+            <el-select v-model="formData.suspendReason" placeholder="请选择挂起原因" style="width: 100%" @change="handleSuspendReasonChange">
               <el-option
                 v-for="dict in suspendReasonOptions"
                 :key="dict.value"
@@ -167,6 +167,14 @@ const handleSubmit = async () => {
     }
   })
 }
+
+// 挂起原因变化处理
+const handleSuspendReasonChange = (val) => {
+  // 选中4工作票编号时修改其他值
+  if (val != '4') {
+    formData.value.suspendExplain = undefined
+  }
+}
 </script>
 
 <style scoped>