csx 5 years ago
parent
commit
4a1c8d33b0
4 changed files with 88 additions and 15232 deletions
  1. 0 15214
      package-lock.json
  2. 19 0
      src/api/advice.js
  3. 54 3
      src/xt_pages/data/druguseTemplate.vue
  4. 15 15
      src/xt_pages/user/doctorAdvice.vue

File diff suppressed because it is too large
+ 0 - 15214
package-lock.json


+ 19 - 0
src/api/advice.js View File

274
   })
274
   })
275
 }
275
 }
276
 
276
 
277
+export function getDoctorAdviceConfig() {
278
+  return request({
279
+    url: '/api/adviceconfig/get',
280
+    method: 'get',
281
+  })
282
+}
283
+
284
+
285
+export function postDoctorAdviceConfig(params) {
286
+  return request({
287
+    url: '/api/adviceconfig/isopen',
288
+    method: 'post',
289
+    params:params,
290
+  })
291
+}
292
+
293
+
294
+
295
+
277
 
296
 
278
 
297
 
279
 
298
 

+ 54 - 3
src/xt_pages/data/druguseTemplate.vue View File

3
     <div class="position">
3
     <div class="position">
4
       <bread-crumb :crumbs='crumbs'></bread-crumb>
4
       <bread-crumb :crumbs='crumbs'></bread-crumb>
5
     </div>
5
     </div>
6
+
7
+    <el-dialog title="透析处方长期医嘱医生确认推送提醒" :visible.sync="dialogConfigVisible">
8
+      <el-form>
9
+        <el-form-item label="是否开启推送:">
10
+          <el-radio-group v-model="is_open_remind" @change="changeRemind">
11
+            <el-radio :label="1">开启</el-radio>
12
+            <el-radio :label="2">不开启</el-radio>
13
+          </el-radio-group>
14
+        </el-form-item>
15
+      </el-form>
16
+    </el-dialog>
17
+
18
+
6
     <div class="app-container">
19
     <div class="app-container">
7
       <el-tabs>
20
       <el-tabs>
8
         <el-tab-pane label="医嘱模板 ">
21
         <el-tab-pane label="医嘱模板 ">
9
           <div>
22
           <div>
10
             <div class="filter-container">
23
             <div class="filter-container">
24
+              <el-button size="small"
25
+                         style="float: right;"
26
+                         @click="dialogConfigVisible = true"
27
+                         type="primary">长期医嘱提醒配置
28
+              </el-button>
29
+
11
               <el-button
30
               <el-button
12
                 class="filter-item"
31
                 class="filter-item"
13
-                style="margin-left: 10px;"
32
+                style="margin-left: 10px;margin-right: 10px"
14
                 @click="handleCreateTemplate"
33
                 @click="handleCreateTemplate"
15
                 type="primary"
34
                 type="primary"
16
                 size="small"
35
                 size="small"
1148
     UpdateDrugDic,
1167
     UpdateDrugDic,
1149
     UpdateDrugWay,
1168
     UpdateDrugWay,
1150
     UpdateExecutionFrequency,
1169
     UpdateExecutionFrequency,
1151
-    updateTemplateName
1170
+    updateTemplateName,
1171
+    getDoctorAdviceConfig,
1172
+    postDoctorAdviceConfig
1152
   } from '@/api/advice'
1173
   } from '@/api/advice'
1153
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
1174
   import BreadCrumb from '@/xt_pages/components/bread-crumb'
1154
 
1175
 
1179
         currentIndex: -1,
1200
         currentIndex: -1,
1180
         isEdit: false,
1201
         isEdit: false,
1181
         dialogTitle: '',
1202
         dialogTitle: '',
1203
+        is_open_remind:0,
1182
         isAddChild: false,
1204
         isAddChild: false,
1183
         parent_id: 0,
1205
         parent_id: 0,
1184
         editDialogTitle: '编辑医嘱',
1206
         editDialogTitle: '编辑医嘱',
1246
           execution_frequency: '',
1268
           execution_frequency: '',
1247
           id: 0
1269
           id: 0
1248
         },
1270
         },
1249
-
1271
+        dialogConfigVisible:false,
1250
         templateFormEdit: {
1272
         templateFormEdit: {
1251
           frequency_type: 0,
1273
           frequency_type: 0,
1252
           day_count: '',
1274
           day_count: '',
1309
     created() {
1331
     created() {
1310
       this.getAdviceConfig()
1332
       this.getAdviceConfig()
1311
       this.unitsOption = getDataConfig('hemodialysis', 'units')
1333
       this.unitsOption = getDataConfig('hemodialysis', 'units')
1334
+      this.getDoctorAdviceConfig()
1312
     },
1335
     },
1313
     methods: {
1336
     methods: {
1337
+      getDoctorAdviceConfig(){
1338
+        getDoctorAdviceConfig().then(response => {
1339
+          if (response.data.state == 1) {
1340
+            this.is_open_remind = response.data.data.config.is_open_remind
1341
+          } else {
1342
+            this.$message.error(response.data.msg)
1343
+          }
1344
+        })
1345
+      },
1314
       adviceNameShow({ row, column, rowIndex, columnIndex }) {
1346
       adviceNameShow({ row, column, rowIndex, columnIndex }) {
1315
         if (columnIndex == 1) {
1347
         if (columnIndex == 1) {
1316
           return 'templateadvicenamedisplay'
1348
           return 'templateadvicenamedisplay'
2411
             }
2443
             }
2412
           }
2444
           }
2413
         })
2445
         })
2446
+      }, changeRemind(val) {
2447
+        let params = {
2448
+          'is_open_remind': val,
2449
+        }
2450
+
2451
+        postDoctorAdviceConfig(params).then(response => {
2452
+          if (response.data.state == 1) {
2453
+            this.is_open_remind = response.data.data.is_open_remind
2454
+            if (response.data.data.is_open_remind == 1) {
2455
+              this.$message.success('开启成功')
2456
+            } else {
2457
+              this.$message.success('关闭成功')
2458
+            }
2459
+          } else {
2460
+            this.$message.error(response.data.msg)
2461
+
2462
+          }
2463
+        })
2464
+
2414
       }
2465
       }
2415
     }
2466
     }
2416
   }
2467
   }

+ 15 - 15
src/xt_pages/user/doctorAdvice.vue View File

1
 <template>
1
 <template>
2
   <div class="patient-container">
2
   <div class="patient-container">
3
 
3
 
4
-    <el-dialog title="透析处方长期医嘱医生确认推送提醒" :visible.sync="dialogConfigVisible">
5
-      <el-form>
6
-        <el-form-item label="是否开启推送:">
7
-          <el-radio-group v-model="is_open_remind" @change="changeRemind">
8
-            <el-radio :label="1">开启</el-radio>
9
-            <el-radio :label="2">不开启</el-radio>
10
-          </el-radio-group>
11
-        </el-form-item>
12
-      </el-form>
13
-
14
-    </el-dialog>
4
+    <!--<el-dialog title="透析处方长期医嘱医生确认推送提醒" :visible.sync="dialogConfigVisible">-->
5
+      <!--<el-form>-->
6
+        <!--<el-form-item label="是否开启推送:">-->
7
+          <!--<el-radio-group v-model="is_open_remind" @change="changeRemind">-->
8
+            <!--<el-radio :label="1">开启</el-radio>-->
9
+            <!--<el-radio :label="2">不开启</el-radio>-->
10
+          <!--</el-radio-group>-->
11
+        <!--</el-form-item>-->
12
+      <!--</el-form>-->
13
+
14
+    <!--</el-dialog>-->
15
 
15
 
16
     <patient-sidebar :id="patientID" defaultActive="1-4" v-on:tran-patient="onTranPatient"></patient-sidebar>
16
     <patient-sidebar :id="patientID" defaultActive="1-4" v-on:tran-patient="onTranPatient"></patient-sidebar>
17
     <div class="patient-app-container advice-container app-container">
17
     <div class="patient-app-container advice-container app-container">
18
       <div class="cellButton" style="float:right;">
18
       <div class="cellButton" style="float:right;">
19
-        <el-button :disabled="$store.getters.xt_user.subscibe.state==3?true:false" size="small"
20
-                   @click="dialogConfigVisible = true"
21
-                   type="primary" icon="el-icon-circle-plus-outline">长期医嘱提醒配置
22
-        </el-button>
19
+        <!--<el-button :disabled="$store.getters.xt_user.subscibe.state==3?true:false" size="small"-->
20
+                   <!--@click="dialogConfigVisible = true"-->
21
+                   <!--type="primary" icon="el-icon-circle-plus-outline">长期医嘱提醒配置-->
22
+        <!--</el-button>-->
23
         <el-button :disabled="$store.getters.xt_user.subscibe.state==3?true:false" size="small" @click="openNew"
23
         <el-button :disabled="$store.getters.xt_user.subscibe.state==3?true:false" size="small" @click="openNew"
24
                    type="primary" icon="el-icon-circle-plus-outline">新增
24
                    type="primary" icon="el-icon-circle-plus-outline">新增
25
         </el-button>
25
         </el-button>