Browse Source

病例条目批量参数传参问题

luolei 5 năm trước cách đây
mục cha
commit
db53d89420
1 tập tin đã thay đổi với 11 bổ sung3 xóa
  1. 11 3
      src/components/recordInput/ManageItemBatch.vue

+ 11 - 3
src/components/recordInput/ManageItemBatch.vue

@@ -320,15 +320,23 @@
         for(let i = 0; i < values.length; i++){
           for(let j = 0; j < values[i].length;j++){
             const value = values[i][j]
+            if(!value.msg||value.score==""){
+              this.$message({
+                message:'勾选项扣分值和提示语不能为空',
+                type:'warning',
+                showClose: true
+              });
+              return
+            }
             let item = {
               "casesEntryId": value.id,
               "creator": "0",
               "hospitalId": this.hospitalId,
               "modifier": this.modifier,
-              "msg": value.msg,
+              "msg": value.msg||"",
               "remark": value.remark,
-              "score": value.score,
-              "isUsed":value.isUsed
+              "score": Number(value.score),
+              "isUsed":value.isUsed||0
             }
             casesEntryHospitals.push(item)
           }