From c88e4e1bd87b909fdcc927223762a3f7d752fd6c Mon Sep 17 00:00:00 2001
From: su1124 <1583764726@qq.com>
Date: 星期三, 27 十二月 2023 16:57:45 +0800
Subject: [PATCH] su

---
 src/views/hosp/project/index.vue |   53 +++++++++++++++++++++--------------------------------
 1 files changed, 21 insertions(+), 32 deletions(-)

diff --git a/src/views/hosp/project/index.vue b/src/views/hosp/project/index.vue
index 41f5838..12d640c 100644
--- a/src/views/hosp/project/index.vue
+++ b/src/views/hosp/project/index.vue
@@ -64,7 +64,7 @@
             width="110px" /> -->
           <el-table-column label="鍙備笌灏忕粨" align="center" prop="needReport" :show-overflow-tooltip="true" width="110px">
             <template slot-scope="scope">
-              <dict-tag :options="dict.type.sys_yes_no" :value="scope.row.proCheckMethod" />
+              <dict-tag :options="dict.type.sys_yes_no" :value="scope.row.needReport" />
             </template>
           </el-table-column>
           <el-table-column label="鏄惁绌鸿吂" align="center" prop="proCheckMethod" :show-overflow-tooltip="true" width="110px">
@@ -326,8 +326,8 @@
             </div>
             <div class="pag" v-if="List == false">
               <div class="pag1">
-                <pagination v-show="total > 0" :total="total" :page.sync="querycharge.page"
-                  :limit.sync="querycharge.pageSize" @pagination="getListByXmId" />
+                <pagination v-show="total > 0" :total="total" :page.sync="queryParam.page"
+                  :limit.sync="queryParam.pageSize" @pagination="getListByXmId" />
               </div>
             </div>
           </el-col>
@@ -471,7 +471,12 @@
         id: null,
       },
       // 琛ㄥ崟鍙傛暟
-      form: {},
+      form: {
+       needReport :"Y",
+       proName:"",
+       proPrice:"",
+       sfxmId:"",
+      },
       // 琛ㄥ崟鏍¢獙
       rules: {
         createTime: [
@@ -568,8 +573,11 @@
 
     /** 鏂板鎸夐挳鎿嶄綔 */
     handleAdd(row) {
-      this.reset();
+      // this.reset();
       this.loading = true;
+      this.form.proPrice = 0.00
+      this.form.proName = ""
+      this.form.proId = null
       ProjectTree().then((response) => {
         if (response.code == 200) {
           this.loading = false;
@@ -591,7 +599,7 @@
 
       this.form.deptId = this.queryParams.deptId;
       this.form.proCheckMethod = "N";
-      this.form.needReport ="Y"
+     
       if ((this.key = "Y")) {
         gettreeList().then((response) => {
           this.deptOptionstree = response.data;
@@ -818,7 +826,7 @@
         deptName: null,
         consumablesList: [],
         tjStandardList: [],
-        proStatus: "鍚敤",
+        proStatus: "0",
       };
       this.resetForm("form");
     },
@@ -965,11 +973,6 @@
           this.showRentPrise = true;
         }
         this.form.deptId = Number(this.form.deptId);
-        if (this.form.proStatus === 0) {
-          this.form.proStatus = "鍚敤";
-        } else {
-          this.form.proStatus = "鍋滅敤";
-        }
         if (this.form.proStandard === 0) {
           this.showPrise = true;
           this.showRentPrise = false;
@@ -977,6 +980,7 @@
           this.showPrise = false;
           this.showRentPrise = true;
         }
+        this.form.proStatus =  this.form.proStatus.toString()
         this.form.consumablesList = response.data.consumablesList;
         this.form.tjStandardList = response.data.tjStandardList;
         if (this.form.tjStandardList != null) {
@@ -1084,11 +1088,8 @@
                   }
                 });
               }
-              if (this.form.proStatus === "鍚敤") {
-                this.form.proStatus = 0;
-              } else {
-                this.form.proStatus = 1;
-              }
+              
+              
               updateProject(this.form).then((response) => {
                 this.$modal.msgSuccess("淇敼鎴愬姛");
                 this.cancel();
@@ -1104,11 +1105,7 @@
                 this.$message.error("璇峰~鍐欑埗椤瑰悕绉版垨绉戝鍚嶇О");
                 this.open = true;
               } else {
-                if (this.form.proStatus === "鍚敤") {
-                  this.form.proStatus = 0;
-                } else {
-                  this.form.proStatus = 1;
-                }
+               
                 addProject(this.form).then((response) => {
                   this.$modal.msgSuccess("鏂板鎴愬姛");
                   this.cancel();
@@ -1154,11 +1151,7 @@
                   }
                 });
               }
-              if (this.form.proStatus === "鍚敤") {
-                this.form.proStatus = 0;
-              } else {
-                this.form.proStatus = 1;
-              }
+        
               updateProject(this.form).then((response) => {
                 this.$modal.msgSuccess("淇敼鎴愬姛");
                 this.cancel();
@@ -1174,11 +1167,7 @@
                 this.$message.error("璇峰~鍐欑埗椤瑰悕绉版垨绉戝鍚嶇О");
                 this.open = true;
               } else {
-                if (this.form.proStatus === "鍚敤") {
-                  this.form.proStatus = 0;
-                } else {
-                  this.form.proStatus = 1;
-                }
+              
                 addProject(this.form).then((response) => {
                   this.$modal.msgSuccess("鏂板鎴愬姛");
                   this.cancel();

--
Gitblit v1.8.0