From 35cf8d289a09a6a4a34cf3d73fb41d84969ae4ee Mon Sep 17 00:00:00 2001
From: zhangwei <1504152376@qq.com>
Date: 星期一, 18 八月 2025 17:30:26 +0800
Subject: [PATCH] '注册修改'

---
 src/views/system/dept/form.vue |   15 +++++++++++++--
 1 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/src/views/system/dept/form.vue b/src/views/system/dept/form.vue
index de51a19..4c55292 100644
--- a/src/views/system/dept/form.vue
+++ b/src/views/system/dept/form.vue
@@ -8,13 +8,15 @@
 import { Operation } from "@element-plus/icons-vue";
 import { getCaigoufangshiList } from "@/api/item/index";
 
-const { state } = useDept();
+const { state } = useDept(ref({}));
 const props = withDefaults(defineProps<FormProps>(), {
   formInline: () => ({
+    id: "",
     projectCode: "", // 椤圭洰缂栧彿锛堝繀濉級
     projectName: "", // 椤圭洰鍚嶇О锛堝繀濉級
     hangyepinmu: null, // 琛屼笟鍝佺洰锛堝彲閫夛級
     caigoufangshi: null, // 閲囪喘鏂瑰紡锛堝彲閫夛級
+    caigoufangshiName: null,
     caigouyusuan: null, // 閲囪喘棰勭畻锛堝彲閫夛級
     dingbiaoguize: null, // 瀹氭爣瑙勫垯锛堝彲閫夛級
     baomingfei: null, // 鎶ュ悕璐癸紙鍙�夛級
@@ -55,6 +57,13 @@
 const handleChange = value => {
   console.log(value);
 };
+const selectChange = value => {
+  let obj = state.caigoufangshiList.find(item => {
+    return item.value == value;
+  });
+  newFormInline.value.caigoufangshiName = obj.label;
+};
+
 defineExpose({ getRef });
 onMounted(async () => {});
 </script>
@@ -87,9 +96,10 @@
         </el-form-item>
       </re-col>
       <re-col :value="6" :xs="24" :sm="24">
-        <el-form-item label="椤圭洰缂栧彿" prop="projectCode">
+        <el-form-item label="椤圭洰缂栧彿">
           <el-input
             v-model="newFormInline.projectCode"
+            
             clearable
             placeholder="璇疯緭鍏ラ」鐩紪鍙�"
           />
@@ -118,6 +128,7 @@
             v-model="newFormInline.caigoufangshi"
             placeholder="璇烽�夋嫨閲囪喘鏂瑰紡"
             style="width: 240px"
+            @change="selectChange"
           >
             <el-option
               v-for="item in state.caigoufangshiList"

--
Gitblit v1.9.1