Jelajahi Sumber

修复数量类型问题

shaogen1995 4 tahun lalu
induk
melakukan
621c04f8b0

+ 4 - 2
src/views/collect/collect0.vue

@@ -219,10 +219,12 @@ export default {
       this.tableData = res.data.list
       this.tableData.forEach(v => {
         if (v.textureType === 0) v.textureType = '单一质地'
-        else v.textureType = '复合质地'
+        else if (v.textureType === 1) v.textureType = '复合质地'
         if (v.status === 0) v.status = '保管中'
         else if (v.status === 1) v.status = '已提用'
         else v.status = '已注销'
+        if (v.amountType === 0) v.amountType = '单件'
+        else if (v.amountType === 1) v.amountType = '一套多件'
         v.numTypeId = this.mycategory(v.numTypeId)
         v.integrity = this.spoil(v.integrity)
         v.repair = this.mySave(v.repair)
@@ -254,7 +256,7 @@ export default {
     this.json_data.forEach(v => {
       v.numTypeId = this.mycategory(v.numTypeId)
       if (v.amountType === 0) v.amountType = '单件'
-      else v.amountType = '一套多件'
+      else if (v.amountType === 1) v.amountType = '一套多件'
       v.integrity = this.spoil(v.integrity)
       v.repair = this.mySave(v.repair)
     })

+ 1 - 1
src/views/collect/collect0_look.vue

@@ -40,7 +40,7 @@
               <div><span>文物质地:</span>{{ myObj.texture }}</div>
             </div>
             <div class="row">
-              <div><span>数量类型:</span>{{ myObj.amountType === '0' ? "单件" : "一套多件" }}</div>
+              <div><span>数量类型:</span>{{ myObj.amountType}}</div>
               <div><span>具体数量:</span>{{ myObj.amount }}</div>
             </div>
             <div class="row">

+ 2 - 0
src/views/holding/holding0_audit.vue

@@ -193,6 +193,8 @@ export default {
         this.switch1.push(false)
         // 首先把所有的入库变成0(不入库状态)
         this.mySrt[v.id] = 0
+        if (v.amountType === 0) v.amountType = '单件'
+        else if (v.amountType === 1) v.amountType = '一套多件'
       })
     },
     skip (index) {

+ 1 - 1
src/views/holding/holding0_audit_Dia.vue

@@ -25,7 +25,7 @@
       <div class="row">
         <div>
           <span>数量类型:</span
-          >{{ myObj.amountType === 0 ? "单件" : "一套多件" }}
+          >{{ myObj.amountType}}
         </div>
         <div><span>具体数量:</span>{{ myObj.amount }}</div>
       </div>

+ 4 - 2
src/views/holding/holding3.vue

@@ -220,10 +220,12 @@ export default {
       this.tableData = res.data.list
       this.tableData.forEach(v => {
         if (v.textureType === 0) v.textureType = '单一质地'
-        else v.textureType = '复合质地'
+        else if (v.textureType === 1) v.textureType = '复合质地'
         if (v.status === 0) v.status = '待入库'
         else if (v.status === 1) v.status = '已入库'
         else v.status = '已出库'
+        if (v.amountType === 0) v.amountType = '单件'
+        else if (v.amountType === 1) v.amountType = '一套多件'
         v.numTypeId = this.mycategory(v.numTypeId)
         v.integrity = this.spoil(v.integrity)
         v.repair = this.mySave(v.repair)
@@ -255,7 +257,7 @@ export default {
     this.json_data.forEach(v => {
       v.numTypeId = this.mycategory(v.numTypeId)
       if (v.amountType === 0) v.amountType = '单件'
-      else v.amountType = '一套多件'
+      else if (v.amountType === 1) v.amountType = '一套多件'
       v.integrity = this.spoil(v.integrity)
       v.repair = this.mySave(v.repair)
     })

+ 1 - 1
src/views/holding/holding3_look.vue

@@ -40,7 +40,7 @@
               <div><span>文物质地:</span>{{ myObj.texture }}</div>
             </div>
             <div class="row">
-              <div><span>数量类型:</span>{{ myObj.amountType === '0' ? "单件" : "一套多件" }}</div>
+              <div><span>数量类型:</span>{{ myObj.amountType}}</div>
               <div><span>具体数量:</span>{{ myObj.amount }}</div>
             </div>
             <div class="row">