瀏覽代碼

Merge branch '20201109_pc_vue_new_branch' of http://git.shengws.com/csx/Vue_New into 20201109_pc_vue_new_branch

王子凡 4 年之前
父節點
當前提交
9c159c0aea

+ 12 - 0
src/router/modules/dialysis.js 查看文件

@@ -316,6 +316,18 @@ export default {
316 316
         noCache: true
317 317
       }
318 318
     },
319
+    {
320
+      path: '/dialysis/print/batch/thirty',
321
+      component: () =>
322
+        import('@/xt_pages/dialysis/batch_print/batch_print_order_thirty'),
323
+      hidden: true,
324
+      is_menu: false,
325
+      name: 'dialysis_batch_thirty',
326
+      meta: {
327
+        title: '批量打印',
328
+        noCache: true
329
+      }
330
+    },
319 331
     {
320 332
       path: '/dialysis/print/batch/twentyTwo_one',
321 333
       component: () =>

+ 1 - 1
src/xt_pages/dialysis/batch_print/batch_print_order_seven.vue 查看文件

@@ -1301,7 +1301,7 @@
1301 1301
 
1302 1302
             this.records = this.records.concat(resp.data.schedules)
1303 1303
 
1304
-              console.log('记录', this.records)
1304
+              // console.log('记录', this.records)
1305 1305
 
1306 1306
             for (const recordIndex in this.records) {
1307 1307
               var dlegh = 0

文件差異過大導致無法顯示
+ 1527 - 0
src/xt_pages/dialysis/batch_print/batch_print_order_thirty.vue


+ 12 - 0
src/xt_pages/dialysis/bloodPresssWatch.vue 查看文件

@@ -199,6 +199,16 @@
199 199
           >
200 200
         </div>
201 201
       </template>
202
+      <template v-if="this.template_id == 30">
203
+        <el-button
204
+          size="small"
205
+          icon="el-icon-printer"
206
+          :disabled="selecting_schs.length == 0"
207
+          @click="batchPrintAction"
208
+          type="primary"
209
+          >批量打印</el-button
210
+        >
211
+      </template>
202 212
     </div>
203 213
     <div class="app-container">
204 214
       <!-- <div class="filter-container">
@@ -717,6 +727,8 @@ export default {
717 727
         this.$router.push({ path: "/dialysis/print/batch/twenty" });
718 728
       } else if (this.template_id == 22) {
719 729
         this.$router.push({ path: "/dialysis/print/batch/twentyTwo" });
730
+      }else if (this.template_id == 30) {
731
+        this.$router.push({ path: "/dialysis/print/batch/thirty" });
720 732
       }
721 733
     },
722 734
     batchPrintActionOne: function() {

+ 3 - 3
src/xt_pages/dialysis/details/dialog/computer_dialog.vue 查看文件

@@ -314,10 +314,10 @@
314 314
               this.$set(this_order, key, resp_dialysis_order[key])
315 315
             }
316 316
             let orgId = parseInt(sessionStorage.getItem("org_id"));
317
-            axios.get('/api/index/uppatient?org_id='+ orgId + '&admin_user_id='+ this.form.nurse_id + '&patient_id=' + this.patient_id + '&up_time=' + (new Date(this.form.start_time).getTime() / 1000)).then((res) => {
318
-              console.log('res',res.data)
317
+            // axios.get('/api/index/uppatient?org_id='+ orgId + '&admin_user_id='+ this.form.nurse_id + '&patient_id=' + this.patient_id + '&up_time=' + (new Date(this.form.start_time).getTime() / 1000)).then((res) => {
318
+            //   console.log('res',res.data)
319 319
 
320
-            }) 
320
+            // }) 
321 321
             this.hide()
322 322
             this.$emit('monitor', resp.data.monitor)
323 323
             this.$message.success('上机成功')

+ 3 - 3
src/xt_pages/dialysis/details/dialog/finish_dialog.vue 查看文件

@@ -213,10 +213,10 @@
213 213
               this.$set(this_order, key, dialysis_order[key])
214 214
             }
215 215
             let orgId = parseInt(sessionStorage.getItem("org_id"));
216
-            axios.get('/api/index/downpatient?org_id='+ orgId + '&admin_user_id='+ this.form.nurse_id + '&patient_id=' + this.patient_id).then((res) => {
217
-              console.log('res',res.data)
216
+            // axios.get('/api/index/downpatient?org_id='+ orgId + '&admin_user_id='+ this.form.nurse_id + '&patient_id=' + this.patient_id).then((res) => {
217
+            //   console.log('res',res.data)
218 218
 
219
-            }) 
219
+            // }) 
220 220
             this.hide()
221 221
             this.$emit('assessmentAfterDislysis', resp.data.assessmentAfterDislysis)
222 222
 

+ 7 - 1
src/xt_pages/dialysis/details/index.vue 查看文件

@@ -1801,10 +1801,16 @@ export default {
1801 1801
       })
1802 1802
     },
1803 1803
     next(){
1804
+      let schedule_type = null
1805
+      if(new Date().getHours() < 11){
1806
+        schedule_type = 1
1807
+      }else {
1808
+        schedule_type = 2
1809
+      }
1804 1810
       console.log('patient_id',this.$route.query.date)
1805 1811
       let org_id =  parseInt(sessionStorage.getItem("org_id"));
1806 1812
       let admin_user_id = parseInt(sessionStorage.getItem("admin_user_id"));
1807
-      axios.get('/api/index/nextcall?org_id=' + org_id + '&patient_id=' + this.patient_id + '&admin_user_id=' + admin_user_id).then(res => {
1813
+      axios.get('/api/index/nextcall?org_id=' + org_id + '&patient_id=' + this.patient_id + '&admin_user_id=' + admin_user_id + '&schedule_type=' + schedule_type).then(res => {
1808 1814
         console.log(res)
1809 1815
         if(res.data.data.patientInfo == null){
1810 1816
           this.$message.error('已经是最后一位了');

+ 35 - 5
src/xt_pages/dialysis/schedualPatient.vue 查看文件

@@ -378,13 +378,30 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
378 378
           // let res = re.data;
379 379
           console.log('res3333333333',res)
380 380
           if(res.channel == 'queue/join'){
381
+            let timeType = null
382
+            if(new Date().getHours() < 11){
383
+              timeType = 1
384
+            }else if(new Date().getHours() >= 11){
385
+              timeType = 2
386
+            }
387
+            let fisrtQueueInfo = []
388
+            this.newFisrtQueueInfo = res.data.fisrtQueueInfo
381 389
             if(res.data.fisrtQueueInfo != null){
382
-              if(res.data.fisrtQueueInfo.create_time){
383
-                res.data.fisrtQueueInfo.create_time = moment(parseInt(res.data.fisrtQueueInfo.create_time) * 1000).format('HH:mm')
384
-              }
390
+                if(timeType == 1){
391
+                    fisrtQueueInfo = res.data.fisrtQueueInfo.morning
392
+                    if(fisrtQueueInfo.create_time){
393
+                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
394
+                    }
395
+                }else if(timeType == 2){
396
+                    fisrtQueueInfo = res.data.fisrtQueueInfo.afternoon
397
+                    if(fisrtQueueInfo.create_time){
398
+                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
399
+                    }
400
+                }
385 401
             }
402
+            this.fisrtQueueInfo = fisrtQueueInfo
386 403
             this.queueConfig = res.data.queueConfig
387
-            this.fisrtQueueInfo = res.data.fisrtQueueInfo
404
+            // this.fisrtQueueInfo = res.data.fisrtQueueInfo
388 405
             let arr = res.data.patientQueueList.data
389 406
             let waitingCalledArr = []
390 407
             let calledArr = []
@@ -448,10 +465,23 @@ import { getDialysisRecordInitData, getDialysisSchedules } from '@/api/dialysis_
448 465
             this.$message.error('已经是最后一位了');
449 466
             return
450 467
           }
468
+          let schedule_type = null
469
+          if(this.schedule_type_selected == 0){
470
+            if(new Date().getHours() < 11){
471
+              schedule_type = 1
472
+            }else {
473
+              schedule_type = 2
474
+            }
475
+          }else if(this.schedule_type_selected == 1){
476
+            schedule_type = 1
477
+          }else if(this.schedule_type_selected == 2){
478
+            schedule_type = 2
479
+          }
480
+          
451 481
           console.log('patient_id',patient_id)
452 482
           let org_id =  parseInt(sessionStorage.getItem("org_id"));
453 483
           let admin_user_id = parseInt(sessionStorage.getItem("admin_user_id"));
454
-          axios.get('/api/index/nextcall?org_id=' + org_id + '&patient_id=' + patient_id + '&admin_user_id=' + admin_user_id).then(res => {
484
+          axios.get('/api/index/nextcall?org_id=' + org_id + '&patient_id=' + patient_id + '&admin_user_id=' + admin_user_id + '&schedule_type=' + schedule_type).then(res => {
455 485
               console.log(res)
456 486
               // let patientArr = res.data.queue_list.data
457 487
               // this.patientArr = patientArr

+ 1 - 1
src/xt_pages/dialysis/template/DialysisPrintOrderThirty.vue 查看文件

@@ -429,7 +429,7 @@
429 429
                     <td width="10">ml</td>
430 430
                     <td width="30"></td>
431 431
                     <td width='70'>透后体重:</td>
432
-                    <td width="50">
432
+                    <td width="70">
433 433
                       <div class="under-line">&nbsp;{{ afterdialysis.weight_after ? afterdialysis.weight_after : "未称重" }}</div>
434 434
                     </td>
435 435
                     <td width="10">Kg</td>

+ 1 - 0
src/xt_pages/outpatientDoctorStation/components/deskPrescription.vue 查看文件

@@ -1028,6 +1028,7 @@
1028 1028
           isLoading = true
1029 1029
           console.log("prescriptions9999",this.prescriptions)
1030 1030
           console.log("params---",params)
1031
+          console.log("data",data)
1031 1032
           createHisPrescription(data, params).then(response => {
1032 1033
             if (response.data.state == 1) {
1033 1034
               this.$emit("change")

+ 123 - 48
src/xt_pages/sign/components/beforeDialysisCalling.vue 查看文件

@@ -11,16 +11,17 @@
11 11
         </div>
12 12
         <div style="display:flex;justify-content: space-between;">
13 13
             <div class="callingArea">
14
-                <waiting-called v-if="patientStateVal == 0" :waitingCalled='waitingCalled' ></waiting-called>
15
-                <called v-if="patientStateVal == 1" :called="called"></called>
14
+                <waiting-called v-if="patientStateVal == 0" :waitingCalled='waitingCalledAm' ></waiting-called>
15
+                <waiting-called v-if="patientStateVal == 1" :waitingCalled='waitingCalledPm' ></waiting-called>
16
+                <called v-if="patientStateVal == 2" :called="called"></called>
16 17
             </div>
17
-            <div class="nowCalling" v-if="patientStateVal == 0">
18
+            <div class="nowCalling" v-if="patientStateVal == 0 || patientStateVal == 1">
18 19
                 <p class="nowCallingTitle">当前叫号</p>
19 20
                 <p class="nowCallingName">{{ fisrtQueueInfo ? fisrtQueueInfo.patient_name : '' }}</p>
20 21
                 <p class="nowCallingTime">签到时间:{{ fisrtQueueInfo ? fisrtQueueInfo.create_time : '' }}</p>
21 22
                 <el-button type="primary" @click="call(fisrtQueueInfo && fisrtQueueInfo.patient_id ? fisrtQueueInfo.patient_id : '')" style="margin-left:0;margin: 30px 0 20px 0;">&ensp;叫号&ensp;</el-button>
22 23
                 <!-- <el-button style="margin: 0px 0 20px 0;" @click="pass(fisrtQueueInfo.patient_id)">&ensp;过号&ensp;</el-button> -->
23
-                <el-button style="margin:0 auto;" @click="next(fisrtQueueInfo && fisrtQueueInfo.patient_id ? fisrtQueueInfo.patient_id : '')">下一位</el-button>
24
+                <el-button style="margin:0 auto;" @click="next(fisrtQueueInfo && fisrtQueueInfo.patient_id ? fisrtQueueInfo.patient_id : '',fisrtQueueInfo && fisrtQueueInfo.schedule_type ? fisrtQueueInfo.schedule_type : '')">下一位</el-button>
24 25
             </div>
25 26
         </div>
26 27
     </div>
@@ -40,8 +41,9 @@ export default {
40 41
     data(){
41 42
         return{
42 43
             patient_state:[
43
-                {value: 0,label: '待叫号'},
44
-                {value: 1,label: '已叫号'},
44
+                {value: 0,label: '上午待叫号'},
45
+                {value: 1,label: '下午待叫号'},
46
+                {value: 2,label: '已叫号'},
45 47
             ],
46 48
             patientStateVal: 0,
47 49
             waitingCalled:[],
@@ -49,6 +51,10 @@ export default {
49 51
             fisrtQueueInfo:{},
50 52
             timer:null,
51 53
 
54
+            waitingCalledAm:[],
55
+            waitingCalledPm:[],
56
+            newFisrtQueueInfo:{}
57
+
52 58
         }
53 59
     },
54 60
     computed: {
@@ -116,53 +122,116 @@ export default {
116 122
                 let res = JSON.parse(e.data);
117 123
                 // let res = re.data;
118 124
                 console.log('res3333333333',res)
119
-                if(res.channel == 'queue/join'){
120
-                    if(res.data.fisrtQueueInfo != null){
121
-                        if(res.data.fisrtQueueInfo.create_time){
122
-                            res.data.fisrtQueueInfo.create_time = moment(parseInt(res.data.fisrtQueueInfo.create_time) * 1000).format('HH:mm')
125
+                
126
+                    if(res.channel == 'queue/join'){
127
+                        if(res.data.type == 3){
128
+                            let fisrtQueueInfo = []
129
+                            this.newFisrtQueueInfo = res.data.fisrtQueueInfo
130
+                            if(res.data.fisrtQueueInfo != null){
131
+                                if(this.patientStateVal == 0){
132
+                                    fisrtQueueInfo = res.data.fisrtQueueInfo.morning
133
+                                    if(fisrtQueueInfo.create_time){
134
+                                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
135
+                                    }
136
+                                }else if(this.patientStateVal == 1){
137
+                                    fisrtQueueInfo = res.data.fisrtQueueInfo.afternoon
138
+                                    if(fisrtQueueInfo.create_time){
139
+                                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
140
+                                    }
141
+                                }
142
+                            }
143
+                            this.fisrtQueueInfo = fisrtQueueInfo
144
+                            let arr = res.data.patientQueueList.data
145
+                            // let waitingCalledArr = []
146
+                            let waitingCalledAm = []
147
+                            let waitingCalledPm = []
148
+                            let calledArr = []
149
+                            arr.map(item => {
150
+                                if(item.status == 1){
151
+                                    item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
152
+                                    // waitingCalledArr.push(item)
153
+                                    if(item.schedule_type == 1){
154
+                                        waitingCalledAm.push(item)
155
+                                    }else if(item.schedule_type == 2){
156
+                                        waitingCalledPm.push(item)
157
+                                    }
158
+                                }else if(item.status == 2){
159
+                                    item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
160
+                                    calledArr.push(item)
161
+                                }
162
+                            })
163
+                            // this.waitingCalled = waitingCalledArr
164
+                            this.waitingCalledAm = waitingCalledAm
165
+                            this.waitingCalledPm = waitingCalledPm
166
+                            this.called = calledArr
123 167
                         }
124
-                        
168
+                    }else if(res.channel == 'allQueueList'){
169
+                        let arr = res.data.queue_list.data
170
+                        // let waitingCalledArr = []
171
+                        let waitingCalledAm = []
172
+                        let waitingCalledPm = []
173
+                        let calledArr = []
174
+                        arr.map(item => {
175
+                            if(item.status == 1){
176
+                                item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
177
+                                // waitingCalledArr.push(item)
178
+                                if(item.schedule_type == 1){
179
+                                    waitingCalledAm.push(item)
180
+                                }else if(item.schedule_type == 2){
181
+                                    waitingCalledPm.push(item)
182
+                                }
183
+                            }else if(item.status == 2){
184
+                                item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
185
+                                calledArr.push(item)
186
+                            }
187
+                        })
188
+                        // this.waitingCalled = waitingCalledArr
189
+                        this.waitingCalledAm = waitingCalledAm
190
+                        this.waitingCalledPm = waitingCalledPm
191
+                        this.called = calledArr
192
+                    }else if(res.channel == 'patientCallInfo'){
193
+                        res.data.patientInfo.create_time = moment(parseInt(res.data.patientInfo.create_time) * 1000).format('HH:mm')
194
+                        this.fisrtQueueInfo = res.data.patientInfo
125 195
                     }
126
-                    this.fisrtQueueInfo = res.data.fisrtQueueInfo
127
-                    let arr = res.data.patientQueueList.data
128
-                    let waitingCalledArr = []
129
-                    let calledArr = []
130
-                    arr.map(item => {
131
-                        if(item.status == 1){
132
-                            item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
133
-                            waitingCalledArr.push(item)
134
-                        }else if(item.status == 2){
135
-                            item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
136
-                            calledArr.push(item)
137
-                        }
138
-                    })
139
-                    console.log('waitingCalledArr待叫号',waitingCalledArr)
140
-                    console.log('waitingCalledArr以较好',calledArr)
141
-                    this.waitingCalled = waitingCalledArr
142
-                    this.called = calledArr
143
-                }else if(res.channel == 'allQueueList'){
144
-                    let arr = res.data.queue_list.data
145
-                    let waitingCalledArr = []
146
-                    let calledArr = []
147
-                    arr.map(item => {
148
-                        if(item.status == 1){
149
-                            item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
150
-                            waitingCalledArr.push(item)
151
-                        }else if(item.status == 2){
152
-                            item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
153
-                            calledArr.push(item)
154
-                        }
155
-                    })
156
-                    this.waitingCalled = waitingCalledArr
157
-                    this.called = calledArr
158
-                }else if(res.channel == 'patientCallInfo'){
159
-                    res.data.patientInfo.create_time = moment(parseInt(res.data.patientInfo.create_time) * 1000).format('HH:mm')
160
-                    this.fisrtQueueInfo = res.data.patientInfo
161
-                }
196
+                
162 197
             }
163 198
         },
164 199
         handleStateChange: function(index) {
165 200
             this.patientStateVal = index
201
+            // if(index == 0){
202
+            //     let arr = this.waitingCalledAm
203
+            //     let newArr = []
204
+            //     arr.map(item => {
205
+            //         if(item.schedule_type == 1){
206
+            //             newArr.push(item)
207
+            //         }
208
+            //     }) 
209
+            //     this.waitingCalledAm = newArr
210
+            // }else if(index == 1){
211
+            //     let arr = this.waitingCalledPm
212
+            //     let newArr = []
213
+            //     arr.map(item => {
214
+            //         if(item.schedule_type == 2){
215
+            //             newArr.push(item)
216
+            //         }
217
+            //     }) 
218
+            //     this.waitingCalledPm = newArr
219
+            // }
220
+            let fisrtQueueInfo = []
221
+            if(this.newFisrtQueueInfo != null){
222
+                if(this.patientStateVal == 0){
223
+                    fisrtQueueInfo = this.newFisrtQueueInfo.morning
224
+                    if(fisrtQueueInfo.create_time){
225
+                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
226
+                    }
227
+                }else if(this.patientStateVal == 1){
228
+                    fisrtQueueInfo = this.newFisrtQueueInfo.afternoon
229
+                    if(fisrtQueueInfo.create_time){
230
+                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
231
+                    }
232
+                }
233
+            }
234
+            this.fisrtQueueInfo = fisrtQueueInfo
166 235
         },
167 236
         call(patient_id){
168 237
             if(patient_id == undefined || patient_id == ""){
@@ -190,10 +259,16 @@ export default {
190 259
                 this.$message.error('已经是最后一位了');
191 260
                 return
192 261
             }
262
+            let schedule_type = null
263
+            if(this.patientStateVal == 0){
264
+                schedule_type = 1
265
+            }else if(this.patientStateVal == 1){
266
+                schedule_type = 2
267
+            }
193 268
             console.log('patient_id',patient_id)
194 269
             let org_id =  parseInt(sessionStorage.getItem("org_id"));
195 270
             let admin_user_id = parseInt(sessionStorage.getItem("admin_user_id"));
196
-            axios.get('/api/index/nextcall?org_id=' + org_id + '&patient_id=' + patient_id + '&admin_user_id=' + admin_user_id).then(res => {
271
+            axios.get('/api/index/nextcall?org_id=' + org_id + '&patient_id=' + patient_id + '&admin_user_id=' + admin_user_id + '&schedule_type=' + schedule_type).then(res => {
197 272
                 console.log(res)
198 273
                 // let patientArr = res.data.queue_list.data
199 274
                 // this.patientArr = patientArr

+ 102 - 28
src/xt_pages/sign/components/computerCalling.vue 查看文件

@@ -11,8 +11,9 @@
11 11
         </div>
12 12
         <div style="display:flex;justify-content: space-between;">
13 13
             <div class="callingArea">
14
-                <called v-if="patientStateVal == 0" :index='1' :called='waitingCalled'></called>
15
-                <called v-if="patientStateVal == 1" :called="called"></called>
14
+                <called v-if="patientStateVal == 0" :index='1' :called='waitingCalledAm'></called>
15
+                <called v-if="patientStateVal == 1" :index='1' :called='waitingCalledPm'></called>
16
+                <called v-if="patientStateVal == 2" :called="called"></called>
16 17
             </div>
17 18
             <div class="nowCalling" v-if="patientStateVal == 0">
18 19
                 <p class="nowCallingTitle">当前叫号</p>
@@ -36,8 +37,9 @@ export default {
36 37
     data(){
37 38
         return{
38 39
             patient_state:[
39
-                {value: 0,label: '待叫号'},
40
-                {value: 1,label: '已叫号'},
40
+                {value: 0,label: '上午待叫号'},
41
+                {value: 1,label: '下午待叫号'},
42
+                {value: 2,label: '已叫号'},
41 43
             ],
42 44
             patientStateVal: 0,
43 45
             waitingCalled:[],
@@ -45,6 +47,10 @@ export default {
45 47
             fisrtQueueInfo:{},
46 48
             timer:null,
47 49
 
50
+            waitingCalledAm:[],
51
+            waitingCalledPm:[],
52
+            newFisrtQueueInfo:{}
53
+
48 54
         }
49 55
     },
50 56
     computed: {
@@ -93,42 +99,70 @@ export default {
93 99
                 // let res = re.data;
94 100
                 console.log('res',res)
95 101
                 if(res.channel == 'queue/join'){
96
-                    if(res.data.fisrtQueueInfo != null){
97
-                        if(res.data.fisrtQueueInfo.create_time){
98
-                            res.data.fisrtQueueInfo.create_time = moment(parseInt(res.data.fisrtQueueInfo.create_time) * 1000).format('HH:mm')
102
+                    if(res.data.type == 4){
103
+                        let fisrtQueueInfo = []
104
+                        this.newFisrtQueueInfo = res.data.fisrtQueueInfo
105
+                        if(res.data.fisrtQueueInfo != null){
106
+                            if(this.patientStateVal == 0){
107
+                                fisrtQueueInfo = res.data.fisrtQueueInfo.morning
108
+                                if(fisrtQueueInfo.create_time){
109
+                                    fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
110
+                                }
111
+                            }else if(this.patientStateVal == 1){
112
+                                fisrtQueueInfo = res.data.fisrtQueueInfo.afternoon
113
+                                if(fisrtQueueInfo.create_time){
114
+                                    fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
115
+                                }
116
+                            }
99 117
                         }
118
+                        this.fisrtQueueInfo = fisrtQueueInfo
119
+                        let arr = res.data.patientQueueList.data
120
+                        // let waitingCalledArr = []
121
+                        let waitingCalledAm = []
122
+                        let waitingCalledPm = []
123
+                        let calledArr = []
124
+                        arr.map(item => {
125
+                            if(item.status == 2){
126
+                                item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
127
+                                // waitingCalledArr.push(item)
128
+                                if(item.schedule_type == 1){
129
+                                    waitingCalledAm.push(item)
130
+                                }else if(item.schedule_type == 2){
131
+                                    waitingCalledPm.push(item)
132
+                                }
133
+                            }else if(item.status == 3){
134
+                                item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
135
+                                calledArr.push(item)
136
+                            }
137
+                        })
138
+                        // this.waitingCalled = waitingCalledArr
139
+                        this.waitingCalledAm = waitingCalledAm
140
+                        this.waitingCalledPm = waitingCalledPm
141
+                        this.called = calledArr
100 142
                     }
101
-                    this.fisrtQueueInfo = res.data.fisrtQueueInfo
102
-                    let arr = res.data.patientQueueList.data
103
-                    let waitingCalledArr = []
104
-                    let calledArr = []
105
-                    arr.map(item => {
106
-                        if(item.status == 2){
107
-                            item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
108
-                            waitingCalledArr.push(item)
109
-                        }else if(item.status == 3){
110
-                            item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
111
-                            calledArr.push(item)
112
-                        }
113
-                    })
114
-                    console.log('waitingCalledArr',waitingCalledArr)
115
-                    console.log('waitingCalledArr',calledArr)
116
-                    this.waitingCalled = waitingCalledArr
117
-                    this.called = calledArr
118 143
                 }else if(res.channel == 'allQueueList'){
119 144
                     let arr = res.data.queue_list.data
120
-                    let waitingCalledArr = []
145
+                    // let waitingCalledArr = []
146
+                    let waitingCalledAm = []
147
+                    let waitingCalledPm = []
121 148
                     let calledArr = []
122 149
                     arr.map(item => {
123 150
                         if(item.status == 2){
124 151
                             item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
125
-                            waitingCalledArr.push(item)
152
+                            // waitingCalledArr.push(item)
153
+                            if(item.schedule_type == 1){
154
+                                waitingCalledAm.push(item)
155
+                            }else if(item.schedule_type == 2){
156
+                                waitingCalledPm.push(item)
157
+                            }
126 158
                         }else if(item.status == 3){
127 159
                             item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
128 160
                             calledArr.push(item)
129 161
                         }
130 162
                     })
131
-                    this.waitingCalled = waitingCalledArr
163
+                    // this.waitingCalled = waitingCalledArr
164
+                    this.waitingCalledAm = waitingCalledAm
165
+                    this.waitingCalledPm = waitingCalledPm
132 166
                     this.called = calledArr
133 167
                 }else if(res.channel == 'patientCallInfo'){
134 168
                     res.data.patientInfo.create_time = moment(res.data.patientInfo.create_time * 1000).format('HH:mm')
@@ -138,6 +172,40 @@ export default {
138 172
         },
139 173
         handleStateChange: function(index) {
140 174
             this.patientStateVal = index
175
+            // if(index == 0){
176
+            //     let arr = this.waitingCalledAm
177
+            //     let newArr = []
178
+            //     arr.map(item => {
179
+            //         if(item.schedule_type == 1){
180
+            //             newArr.push(item)
181
+            //         }
182
+            //     }) 
183
+            //     this.waitingCalledAm = newArr
184
+            // }else if(index == 1){
185
+            //     let arr = this.waitingCalledPm
186
+            //     let newArr = []
187
+            //     arr.map(item => {
188
+            //         if(item.schedule_type == 2){
189
+            //             newArr.push(item)
190
+            //         }
191
+            //     }) 
192
+            //     this.waitingCalledPm = newArr
193
+            // }
194
+            let fisrtQueueInfo = []
195
+            if(this.newFisrtQueueInfo != null){
196
+                if(this.patientStateVal == 0){
197
+                    fisrtQueueInfo = this.newFisrtQueueInfo.morning
198
+                    if(fisrtQueueInfo.create_time){
199
+                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
200
+                    }
201
+                }else if(this.patientStateVal == 1){
202
+                    fisrtQueueInfo = this.newFisrtQueueInfo.afternoon
203
+                    if(fisrtQueueInfo.create_time){
204
+                        fisrtQueueInfo.create_time = moment(parseInt(fisrtQueueInfo.create_time) * 1000).format('HH:mm')
205
+                    }
206
+                }
207
+            }
208
+            this.fisrtQueueInfo = fisrtQueueInfo
141 209
         },
142 210
         call(patient_id){
143 211
             if(patient_id == undefined || patient_id == ""){
@@ -166,9 +234,15 @@ export default {
166 234
                 return
167 235
             }
168 236
             console.log('patient_id',patient_id)
237
+            let schedule_type = null
238
+            if(this.patientStateVal == 0){
239
+                schedule_type = 1
240
+            }else if(this.patientStateVal == 1){
241
+                schedule_type = 2
242
+            }
169 243
             let org_id =  parseInt(sessionStorage.getItem("org_id"));
170 244
             let admin_user_id = parseInt(sessionStorage.getItem("admin_user_id"));
171
-            axios.get('/api/index/nextupcall?org_id=' + org_id + '&patient_id=' + patient_id + '&admin_user_id=' + admin_user_id).then(res => {
245
+            axios.get('/api/index/nextupcall?org_id=' + org_id + '&patient_id=' + patient_id + '&admin_user_id=' + admin_user_id + '&schedule_type=' + schedule_type).then(res => {
172 246
                 console.log(res)
173 247
                 // let patientArr = res.data.queue_list.data
174 248
                 // this.patientArr = patientArr

+ 75 - 71
src/xt_pages/sign/lineUp.vue 查看文件

@@ -70,7 +70,7 @@
70 70
                                     <span v-if="item.status == 5">已下机</span>
71 71
                                 </p>
72 72
                                 <p style="width:14%">{{ item.start_time ? getDates(item.start_time) : '--' }}</p>
73
-                                <p style="width:16%">{{ item.end_time ? getDates(item.end_time) : '--' }}</p>
73
+                                <p style="width:16%">{{ item.end_time && item.start_time ? getDates(item.end_time) : '--' }}</p>
74 74
                             </div>
75 75
                         </div>
76 76
                     </div> 
@@ -154,7 +154,7 @@
154 154
                                     <span v-if="item.status == 5">已下机</span>
155 155
                                 </p>
156 156
                                 <p style="width:14%">{{ item.start_time ? getDates(item.start_time) : '--' }}</p>
157
-                                <p style="width:16%">{{ item.end_time ? getDates(item.end_time) : '--' }}</p>
157
+                                <p style="width:16%">{{ item.end_time && item.start_time ? getDates(item.end_time) : '--' }}</p>
158 158
                             </div>
159 159
                         </div>
160 160
                     </div> 
@@ -353,76 +353,80 @@ export default {
353 353
                 let res = JSON.parse(e.data);
354 354
                 // let res = re.data;
355 355
                 console.log('res',res)
356
-                if(res.channel == 'queue/join'){
357
-                    this.queueConfig = res.data.queueConfig
358
-                    this.lineUpList = res.data.patientQueueList.data
359
-                    this.receivingPatient = res.data.receivingPatient
360
-                    this.waitDoctorList = res.data.waitDoctorList
361
-                    this.upPatientList = res.data.upPatientList
362
-                    this.count = res.data.patientQueueList.count
363
-                    // this.lineUpList.map(item => {
364
-                    //     item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
365
-                    //     // item.start_time = moment(item.start_time * 1000).format('HH:mm')
366
-                    // })
367
-                }else if(res.channel == 'queue/queuelist'){
368
-                    this.lineUpList = res.data.patientQueueList.data
369
-                    this.count = res.data.patientQueueList.count
370
-                    // this.lineUpList.map(item => {
371
-                    //     item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
372
-                    //     // item.start_time = moment(item.start_time * 1000).format('HH:mm')
373
-                    //     if(item.start_time != null){
374
-                    //         item.start_time = moment(item.start_time * 1000).format('HH:mm:ss')
375
-                    //     }
376
-                    //     if(item.status == 5 || item.end_time){
377
-                    //         item.end_time = moment(item.end_time * 1000).format('HH:mm:ss')
378
-                    //     }
379
-                    // })
380
-                }else if(res.channel == 'patientCallInfo'){
381
-                    console.log(999999999999,res.data)
382
-                    
383
-                    
384
-                    console.log('执行几次',this.voiceNum)
385
-                    if(this.voice == true){
386
-                        this.patient_id = res.data.patientInfo.patient_id
387
-                        this.voice = false
388
-                        // let time1 = null
389
-                        this.voicePrompt(res.data.callVolUrl)
390
-                        this.voiceTime = setInterval(() => {
391
-                            let num = null
392
-                            if(res.data.patientInfo.status == 2){
393
-                                num = parseInt(this.queueConfig.jzdcbbcs)
394
-                            }else if(res.data.patientInfo.status == 3){
395
-                                num = parseInt(this.queueConfig.sjdcbbcs)
396
-                            }
397
-                            if(this.voiceNum < num){
398
-                                this.voiceNum++
399
-                                this.voicePrompt(res.data.callVolUrl)
400
-                            }else{
401
-                                this.voiceNum = 1;
402
-                                this.voice = true 
403
-                                let obj = {
404
-                                    cmd: "queue/callreturn",
405
-                                    data: {patient_id:this.patient_id},
406
-                                };
407
-                                this.websocketSend(obj)
408
-                                clearInterval(this.voiceTime);
409
-                                this.voiceTime = null
410
-                            }
411
-                        },6000)
412
-                    }else {
413
-                        // this.$message({
414
-                        //     message: '警告哦,这是一条警告消息',
415
-                        //     type: 'warning'
416
-                        // });
356
+                
357
+                    if(res.channel == 'queue/join'){
358
+                        if(res.data.type == 2){
359
+                            this.queueConfig = res.data.queueConfig
360
+                            this.lineUpList = res.data.patientQueueList.data
361
+                            this.receivingPatient = res.data.receivingPatient
362
+                            this.waitDoctorList = res.data.waitDoctorList
363
+                            this.upPatientList = res.data.upPatientList
364
+                            this.count = res.data.patientQueueList.count
365
+                            // this.lineUpList.map(item => {
366
+                            //     item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
367
+                            //     // item.start_time = moment(item.start_time * 1000).format('HH:mm')
368
+                            // })
369
+                        }
370
+                    }else if(res.channel == 'queue/queuelist'){
371
+                        this.lineUpList = res.data.patientQueueList.data
372
+                        this.count = res.data.patientQueueList.count
373
+                        // this.lineUpList.map(item => {
374
+                        //     item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
375
+                        //     // item.start_time = moment(item.start_time * 1000).format('HH:mm')
376
+                        //     if(item.start_time != null){
377
+                        //         item.start_time = moment(item.start_time * 1000).format('HH:mm:ss')
378
+                        //     }
379
+                        //     if(item.status == 5 || item.end_time){
380
+                        //         item.end_time = moment(item.end_time * 1000).format('HH:mm:ss')
381
+                        //     }
382
+                        // })
383
+                    }else if(res.channel == 'patientCallInfo'){
384
+                        console.log(999999999999,res.data)
385
+                        
386
+                        
387
+                        console.log('执行几次',this.voiceNum)
388
+                        if(this.voice == true){
389
+                            this.patient_id = res.data.patientInfo.patient_id
390
+                            this.voice = false
391
+                            // let time1 = null
392
+                            this.voicePrompt(res.data.callVolUrl)
393
+                            this.voiceTime = setInterval(() => {
394
+                                let num = null
395
+                                if(res.data.patientInfo.status == 2){
396
+                                    num = parseInt(this.queueConfig.jzdcbbcs)
397
+                                }else if(res.data.patientInfo.status == 3){
398
+                                    num = parseInt(this.queueConfig.sjdcbbcs)
399
+                                }
400
+                                if(this.voiceNum < num){
401
+                                    this.voiceNum++
402
+                                    this.voicePrompt(res.data.callVolUrl)
403
+                                }else{
404
+                                    this.voiceNum = 1;
405
+                                    this.voice = true 
406
+                                    let obj = {
407
+                                        cmd: "queue/callreturn",
408
+                                        data: {patient_id:this.patient_id},
409
+                                    };
410
+                                    this.websocketSend(obj)
411
+                                    clearInterval(this.voiceTime);
412
+                                    this.voiceTime = null
413
+                                }
414
+                            },6000)
415
+                        }else {
416
+                            // this.$message({
417
+                            //     message: '警告哦,这是一条警告消息',
418
+                            //     type: 'warning'
419
+                            // });
420
+                        }
421
+                    }else if(res.channel == 'updateCallList'){
422
+                        this.receivingPatient = res.data.queue_list
423
+                        
424
+                    }else if(res.channel == 'updateWaitCallList'){
425
+                        this.waitDoctorList = res.data.queue_list
426
+                    }else if(res.channel == 'updateUpCallList'){
427
+                        this.upPatientList = res.data.queue_list
417 428
                     }
418
-                }else if(res.channel == 'updateCallList'){
419
-                    this.receivingPatient = res.data.queue_list
420
-                    
421
-                }else if(res.channel == 'updateWaitCallList'){
422
-                    this.waitDoctorList = res.data.queue_list
423
-                }else if(res.channel == 'updateUpCallList'){
424
-                    this.upPatientList = res.data.queue_list
425
-                }
429
+                
426 430
                 // else if(res.channel == "patientQueueInfo"){
427 431
                 //     this.queueInfo = res.data.queueInfo
428 432
                 //     let obj = {

+ 33 - 29
src/xt_pages/sign/signIn.vue 查看文件

@@ -216,35 +216,39 @@ export default {
216 216
                 let res = JSON.parse(e.data);
217 217
                 // let res = re.data;
218 218
                 console.log('res',res)
219
-                if(res.channel == 'queue/join'){
220
-                    this.signInList = res.data.patientQueueList.data
221
-                    this.count = res.data.patientQueueList.count
222
-                    this.signInList.map(item => {
223
-                        item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
224
-                    })
225
-                }else if(res.channel == "patientQueueInfo"){
226
-                    clearTimeout(this.ds)
227
-                    this.ds = null
228
-                    this.queueInfo = res.data.queueInfo
229
-                    this.page = 1
230
-                    let obj = {
231
-                        cmd: "queue/queuelist",
232
-                        data: {page:1,size:10,sort:1}
233
-                    };
234
-                    this.websocketSend(obj)
235
-                    
236
-                    this.ds = setTimeout(() => { 
237
-                       this.queueInfo = {} 
238
-                    }, 60000);
239
-                    
240
-                }else if(res.channel == 'queue/queuelist'){
241
-                    console.log(11111111111,res.data)
242
-                    this.signInList = res.data.patientQueueList.data
243
-                    this.count = res.data.patientQueueList.count
244
-                    this.signInList.map(item => {
245
-                        item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
246
-                    })
247
-                }
219
+                
220
+                    if(res.channel == 'queue/join'){
221
+                        if(res.data.type == 1){
222
+                            this.signInList = res.data.patientQueueList.data
223
+                            this.count = res.data.patientQueueList.count
224
+                            this.signInList.map(item => {
225
+                                item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
226
+                            })
227
+                        }
228
+                    }else if(res.channel == "patientQueueInfo"){
229
+                        clearTimeout(this.ds)
230
+                        this.ds = null
231
+                        this.queueInfo = res.data.queueInfo
232
+                        this.page = 1
233
+                        let obj = {
234
+                            cmd: "queue/queuelist",
235
+                            data: {page:1,size:10,sort:1}
236
+                        };
237
+                        this.websocketSend(obj)
238
+                        
239
+                        this.ds = setTimeout(() => { 
240
+                        this.queueInfo = {} 
241
+                        }, 60000);
242
+                        
243
+                    }else if(res.channel == 'queue/queuelist'){
244
+                        console.log(11111111111,res.data)
245
+                        this.signInList = res.data.patientQueueList.data
246
+                        this.count = res.data.patientQueueList.count
247
+                        this.signInList.map(item => {
248
+                            item.create_time = moment(item.create_time * 1000).format('HH:mm:ss')
249
+                        })
250
+                    }
251
+                
248 252
                 // console.log("action", re.action);
249 253
                 // console.log("data", JSON.stringify(res));
250 254
             }

+ 12 - 5
src/xt_pages/workforce/components/nextTableWeeks.vue 查看文件

@@ -229,9 +229,19 @@ export default {
229 229
       }
230 230
      },
231 231
     getNextScheduleWeekDay() {
232
+        const start = moment().weekday(1).format('YYYY-MM-DD'); //本周一
233
+        const end = moment().weekday(7).format('YYYY-MM-DD')
234
+        // console.log("start",moment(start).unix())
235
+      
236
+        // const params = {
237
+        //   start_time:moment().week(moment().week() + 1).startOf('week').unix(),
238
+        //   end_time:moment().week(moment().week() + 1).endOf('week').unix(),
239
+        //   week_type:this.week_type,
240
+        //   week_time:this.week_time,
241
+        // }
232 242
         const params = {
233
-          start_time:moment().week(moment().week() + 1).startOf('week').unix(),
234
-          end_time:moment().week(moment().week() + 1).endOf('week').unix(),
243
+          start_time:1609603200,
244
+          end_time:1610208000,
235 245
           week_type:this.week_type,
236 246
           week_time:this.week_time,
237 247
         }
@@ -293,9 +303,6 @@ export default {
293 303
     },
294 304
     selectWeekType(type) {
295 305
       this.week_type = type;
296
-      // let params = {
297
-      //   week_type: this.week_type
298
-      // };
299 306
       this.getNextScheduleWeekDay();
300 307
     },
301 308
     selectWeekTime(type){

+ 2 - 2
src/xt_pages/workforce/components/tableWeeks.vue 查看文件

@@ -240,8 +240,8 @@ export default {
240 240
            for(let i=0;i<scheduleData.length;i++){
241 241
              scheduleData[i].sort = scheduleData[i].number.sort
242 242
            }
243
-          var arr =   scheduleData.sort(this.compare('sort'))
244
-          // console.log("元旦快乐",arr)
243
+          var arr = scheduleData.sort(this.compare('sort'))
244
+          console.log("元旦快乐",arr)
245 245
           this.scheduleData = arr
246 246
         } else {
247 247
           this.$message.error("网络错误");

+ 10 - 3
src/xt_pages/workforce/next_remind_print.vue 查看文件

@@ -127,11 +127,18 @@
127 127
       this.week_type = this.$route.query.week_type
128 128
       this.week_time  = this.$route.query.week_time
129 129
       
130
-      const params = {
130
+      // const params = {
131
+      //     week_type:this.week_type,
132
+      //     week_time:this.week_time,
133
+      //     start_time:this.start_time,
134
+      //     end_time:this.end_time,
135
+      //   }
136
+
137
+         const params = {
131 138
           week_type:this.week_type,
132 139
           week_time:this.week_time,
133
-          start_time:this.start_time,
134
-          end_time:this.end_time,
140
+          start_time:1609603200,
141
+          end_time:1610208000,
135 142
         }
136 143
       console.log("打印下周",params)
137 144
       getNextScheduleWeekDay(params).then(rs => {