maotao 9 mesi fa
parent
commit
1b59b5d042

+ 3 - 4
components/cancelBlood/cancelBlood.vue

@@ -64,7 +64,7 @@
64 64
           bloodIds: this.coopData.children.map(v => v.children).flat().map(v => v.id).toString(),
65 65
           closeOrder: this.isShowTips ? 1 : 0,
66 66
           handoverUser: data.accountId,
67
-          cancelReason: data.cancelReason.id,
67
+          cancelReason: data.cancelReason,
68 68
         };
69 69
       
70 70
         post('/transflow/extra', postData).then(res => {
@@ -186,14 +186,13 @@
186 186
       showSelectAccount2(isShowTips = false) {
187 187
         this.isShowTips = isShowTips;
188 188
         this.hosModels2 = {
189
-          content: `请填写取消原因和交接人信息`,
189
+          content: `请填写取消送血原因和交接人信息`,
190 190
           disjunctor: true,
191
-          tips: isShowTips ? '本患者取消血后,工单将关闭!' : '',
191
+          tips: isShowTips ? '本患者取消血后,工单将关闭!' : '',
192 192
         };
193 193
       },
194 194
       // 取消发血
195 195
       selectAccountHandler(data, index){
196
-        console.log(this.cancelBlood)
197 196
         if(this.cancelBlood != 1 || !this.signType4){
198 197
           return;
199 198
         }

+ 29 - 10
components/selectAccount2/selectAccount2.vue

@@ -5,19 +5,19 @@
5 5
         提示
6 6
       </view>
7 7
       <view class="changeHospital__article">
8
-        <view class="uni-list-cell content" v-show="content">
8
+        <view class="uni-list-cell content red size-30" v-show="content">
9 9
           {{content}}
10 10
         </view>
11
-        <view class="uni-list-cell content red" v-show="tips">
11
+        <view class="uni-list-cell content red size-32" v-show="tips">
12 12
           {{tips}}
13 13
         </view>
14 14
         <view class="uni-list-cell">
15 15
           <view class="uni-list-cell-left">
16 16
             <text class="red">*</text>取消原因:
17 17
           </view>
18
-          <view class="uni-list-cell-db">
18
+          <view class="uni-list-cell-db" v-if="cancelReason.length">
19 19
             <picker @change="changeCancelReason" :value="cancelReasonIndex" :range="cancelReason" range-key="name">
20
-              <view class="uni-input">{{cancelReason[cancelReasonIndex].name}}</view>
20
+              <view class="uni-input">{{cancelReason[cancelReasonIndex] ? cancelReason[cancelReasonIndex].name : '请选择'}}</view>
21 21
             </picker>
22 22
           </view>
23 23
         </view>
@@ -102,8 +102,8 @@
102 102
         account: '', //交接人工号
103 103
         accountName: '', //交接人姓名
104 104
         accountId: '' ,//交接人ID
105
-        cancelReasonIndex: 0,
106
-        cancelReason: [{id: 1, name: '输血科取消'}, {id: 2, name: '临时取消'}],
105
+        cancelReasonIndex: null,
106
+        cancelReason: [],
107 107
       };
108 108
     },
109 109
     watch: {
@@ -153,6 +153,15 @@
153 153
       },
154 154
     },
155 155
     methods: {
156
+			// 获取取消原因字典
157
+			getCancelDic(){
158
+				post('/common/common/getDictionary', {
159
+					"type": "list",
160
+					"key": "blood_trans_cancel_reason"
161
+				}).then(res => {
162
+					this.cancelReason = res;
163
+				})
164
+			},
156 165
       // 修改取消原因
157 166
       changeCancelReason(e){
158 167
         this.cancelReasonIndex = e.detail.value;
@@ -200,7 +209,7 @@
200 209
           e.accountId = this.accountId;
201 210
         }
202 211
         if (this.cancelReason[this.cancelReasonIndex]) {
203
-          e.cancelReason = this.cancelReason[this.cancelReasonIndex];
212
+          e.cancelReason = this.cancelReason[this.cancelReasonIndex].id;
204 213
         }
205 214
         this.$emit("ok", e);
206 215
       },
@@ -210,6 +219,7 @@
210 219
       },
211 220
     },
212 221
     created() {
222
+			this.getCancelDic()
213 223
       this.hosId = uni.getStorageSync('userData').user.currentHospital.id;
214 224
     }
215 225
   };
@@ -236,11 +246,12 @@
236 246
       
237 247
       &.content{
238 248
         justify-content: center;
239
-        color: #000;
249
+        color: red;
240 250
         margin-top: 0;
241 251
         font-weight: bold;
252
+				margin-bottom: 10rpx;
242 253
       }
243
-
254
+			
244 255
       .uni-list-cell-left {
245 256
         flex: 3;
246 257
         font-size: 32rpx;
@@ -291,7 +302,15 @@
291 302
         flex-direction: column;
292 303
         justify-content: center;
293 304
         align-items: center;
294
-
305
+				
306
+				.size-30{
307
+					font-size: 30rpx;
308
+				}
309
+				
310
+				.size-32{
311
+					font-size: 32rpx;
312
+				}
313
+				
295 314
         &.p0 {
296 315
           padding: 0;
297 316
         }