seimin 1 vuosi sitten
vanhempi
commit
c1a0b39f91

+ 37 - 8
pages/medicalWaste/medicalWasteBindCheck/medicalWasteBindCheck.vue

@@ -29,7 +29,7 @@
29
       <view class="btn" @click="scanDeptOrUser()"> 扫一扫 </view>
29
       <view class="btn" @click="scanDeptOrUser()"> 扫一扫 </view>
30
     </view>
30
     </view>
31
     <!-- 弹窗 -->
31
     <!-- 弹窗 -->
32
-    <showModel :title="models1.title" :icon="models1.icon" :disjunctor="models1.disjunctor" :content="models1.content"  @know="know1" :operate="models1.operate"></showModel>
32
+    <showModel :title="models1.title" :icon="models1.icon" :disjunctor="models1.disjunctor" :content="models1.content" @ok="ok1" @cancel="cancel1"  @know="know1" :operate="models1.operate"></showModel>
33
   </view>
33
   </view>
34
 </template>
34
 </template>
35
 <script>
35
 <script>
@@ -59,6 +59,35 @@
59
       this.SMFlag = true;
59
       this.SMFlag = true;
60
     },
60
     },
61
     methods: {
61
     methods: {
62
+      ok1(){
63
+        this.models1.disjunctor = false;
64
+        uni.showLoading({
65
+          title: '加载中',
66
+          mask: true,
67
+        })
68
+        post("/medicalWaste/checkComplete", {
69
+          handoverId: this.handoverId || undefined,
70
+          deptId: +this.queryObj.deptId,
71
+          hosId: this.hosId,
72
+          clinicalWasteTypeIds: this.infoList.map(v => v.id).toString(),
73
+        })
74
+          .then((res) => {
75
+            uni.hideLoading();
76
+            if (res.status == 200) {
77
+              uni.navigateTo({
78
+                url: `/pages/receiptpage/receiptpage`,
79
+              });
80
+            } else {
81
+              uni.showToast({
82
+                icon: "none",
83
+                title: res.msg || "接口获取数据失败!",
84
+              });
85
+            }
86
+          });
87
+      },
88
+      cancel1(){
89
+        this.models1.disjunctor = false;
90
+      },
62
       // 扫科室或人
91
       // 扫科室或人
63
       scanDeptOrUser() {
92
       scanDeptOrUser() {
64
         if (!this.SMFlag) {
93
         if (!this.SMFlag) {
@@ -78,15 +107,15 @@
78
               this.SMFlag = true;
107
               this.SMFlag = true;
79
               // 200检测通过,201没有有效期也通过。
108
               // 200检测通过,201没有有效期也通过。
80
               if (result.state == 200 || result.state == 201) {
109
               if (result.state == 200 || result.state == 201) {
110
+                
81
                 let data = {
111
                 let data = {
82
                   code: result.code, //二维码
112
                   code: result.code, //二维码
83
                 };
113
                 };
84
                 
114
                 
85
-                post("/medicalWaste/checkComplete", {
86
-                  code: result.code,
115
+                post("/medicalWaste/scanByCode", {
87
                   deptId: +this.queryObj.deptId,
116
                   deptId: +this.queryObj.deptId,
117
+                  code: result.code,
88
                   hosId: this.hosId,
118
                   hosId: this.hosId,
89
-                  clinicalWasteTypeIds: this.infoList.map(v => v.id).toString(),
90
                 })
119
                 })
91
                   .then((res) => {
120
                   .then((res) => {
92
                     uni.hideLoading();
121
                     uni.hideLoading();
@@ -136,16 +165,15 @@
136
       //知道了
165
       //知道了
137
       know1() {
166
       know1() {
138
         this.models1.disjunctor = false;
167
         this.models1.disjunctor = false;
139
-        uni.navigateTo({
140
-          url: `/pages/receiptpage/receiptpage`,
141
-        });
142
       },
168
       },
143
       // 被服送回弹窗
169
       // 被服送回弹窗
144
       showModel1(data, type) {
170
       showModel1(data, type) {
145
         let content = '';
171
         let content = '';
146
         if(type === 'dept'){
172
         if(type === 'dept'){
173
+          this.handoverId = undefined;
147
           content = `您与<strong class="red">${data.dept}</strong>成功交接,总重量为<strong class="red">${this.weightTotal}kg</strong>,<strong class="red">${this.countTotal}袋</strong>医废`;
174
           content = `您与<strong class="red">${data.dept}</strong>成功交接,总重量为<strong class="red">${this.weightTotal}kg</strong>,<strong class="red">${this.countTotal}袋</strong>医废`;
148
         }else if(type === 'user'){
175
         }else if(type === 'user'){
176
+          this.handoverId = data.id;
149
           content = `您与<strong class="red">${data.name}</strong>,<strong class="red">${data.dept?data.dept.dept:''}</strong>成功交接,总重量为<strong class="red">${this.weightTotal}kg</strong>,<strong class="red">${this.countTotal}袋</strong>医废`;
177
           content = `您与<strong class="red">${data.name}</strong>,<strong class="red">${data.dept?data.dept.dept:''}</strong>成功交接,总重量为<strong class="red">${this.weightTotal}kg</strong>,<strong class="red">${this.countTotal}袋</strong>医废`;
150
         }
178
         }
151
         
179
         
@@ -155,7 +183,8 @@
155
           content,
183
           content,
156
           icon: "warn",
184
           icon: "warn",
157
           operate: {
185
           operate: {
158
-            know: "知道了",
186
+            ok: "确定",
187
+            cancel: "取消",
159
           },
188
           },
160
         };
189
         };
161
       },
190
       },

+ 2 - 2
pages/medicalWaste/medicalWasteSignIn/medicalWasteSignIn.vue

@@ -20,7 +20,7 @@
20
       <view class="Scanning_cont_list">
20
       <view class="Scanning_cont_list">
21
         <view class="Scanning_cont_list_item Scanning_cont_list_head">
21
         <view class="Scanning_cont_list_item Scanning_cont_list_head">
22
           <view class="name">
22
           <view class="name">
23
-            科室名称<text class="red">({{nameTotal}})</text>
23
+            {{parentIndex === 0 ? '科室名称' : '类型名称'}}<text class="red">({{nameTotal}})</text>
24
           </view>
24
           </view>
25
           <view class="value">
25
           <view class="value">
26
             <view>
26
             <view>
@@ -55,7 +55,7 @@
55
 
55
 
56
     <view class="foot_btn">
56
     <view class="foot_btn">
57
       <view class="btn" @click="goBack()"> 取消 </view>
57
       <view class="btn" @click="goBack()"> 取消 </view>
58
-      <view class="btn" @click="onClick()"> 确认交接 </view>
58
+      <view class="btn" @click="onClick()" *ngIf="gdIds"> 确认交接 </view>
59
     </view>
59
     </view>
60
     <!-- 弹窗 -->
60
     <!-- 弹窗 -->
61
     <showModel :title="models1.title" :icon="models1.icon" :disjunctor="models1.disjunctor" :content="models1.content"
61
     <showModel :title="models1.title" :icon="models1.icon" :disjunctor="models1.disjunctor" :content="models1.content"

+ 16 - 0
pages/medicalWaste/medicalWasteSignOut/medicalWasteSignOut.vue

@@ -270,6 +270,21 @@
270
           });
270
           });
271
           return;
271
           return;
272
         }
272
         }
273
+        if(!this.wasteCountTotal){
274
+          uni.showModal({
275
+            title: "提示",
276
+            content: "选择的类型,无医废数据请确认后发起出库!",
277
+            showCancel: false,
278
+            success: function(res) {
279
+              if (res.confirm) {
280
+                console.log("用户点击确定");
281
+              } else if (res.cancel) {
282
+                console.log("用户点击取消");
283
+              }
284
+            },
285
+          });
286
+          return;
287
+        }
273
         this.showModel1()
288
         this.showModel1()
274
       },
289
       },
275
       goBack(){
290
       goBack(){
@@ -283,6 +298,7 @@
283
           mask: true,
298
           mask: true,
284
         });
299
         });
285
         post("/medicalWaste/complete", {
300
         post("/medicalWaste/complete", {
301
+          clinicalWasteTypeIds: this.queryObj.clinicalWasteTypeIds,
286
           wasteOutInfo:{
302
           wasteOutInfo:{
287
             credentialsNumber: this.credentialsNumber,
303
             credentialsNumber: this.credentialsNumber,
288
             totalBox: +this.totalBox,
304
             totalBox: +this.totalBox,