Browse Source

新分支

28169 6 months ago
parent
commit
0d7fbf08d4

+ 9 - 0
src/api/config.js View File

251
     method:"get",
251
     method:"get",
252
     params:params,
252
     params:params,
253
   })
253
   })
254
+}
255
+
256
+export function changeDrugCodeOpen(params){
257
+ 
258
+  return request({
259
+    url:"/api/changedrugcodeopen",
260
+    method:"get",
261
+    params:params
262
+  })
254
 }
263
 }

+ 9 - 0
src/api/pharmacy.js View File

173
     method:"get",
173
     method:"get",
174
     params:params
174
     params:params
175
   })
175
   })
176
+}
177
+
178
+export function changeDrugCode(params){
179
+
180
+  return request({
181
+    url:"/api/pharmacy/changedrugcode",
182
+    method:"get",
183
+    params:params,
184
+  })
176
 }
185
 }

+ 37 - 8
src/xt_pages/Pharmacy/DrugDispensing.vue View File

195
             <el-table-column
195
             <el-table-column
196
               type="index"
196
               type="index"
197
               label="序号"
197
               label="序号"
198
-              width="120"
198
+              width="50"
199
               align="center"
199
               align="center"
200
             >
200
             >
201
             </el-table-column>
201
             </el-table-column>
202
             <el-table-column
202
             <el-table-column
203
               prop="name"
203
               prop="name"
204
               label="患者名称"
204
               label="患者名称"
205
-              width="180"
205
+              width="100"
206
               align="center"
206
               align="center"
207
             >
207
             >
208
               <template slot-scope="scope">
208
               <template slot-scope="scope">
212
             <el-table-column
212
             <el-table-column
213
               prop="name"
213
               prop="name"
214
               label="单次用量"
214
               label="单次用量"
215
-              width="170"
215
+              width="100"
216
               align="center"
216
               align="center"
217
             >
217
             >
218
               <template slot-scope="scope">
218
               <template slot-scope="scope">
222
             <el-table-column
222
             <el-table-column
223
               prop="name"
223
               prop="name"
224
               label="用法"
224
               label="用法"
225
-              width="160"
225
+              width="100"
226
               align="center"
226
               align="center"
227
             >
227
             >
228
               <template slot-scope="scope">
228
               <template slot-scope="scope">
232
             <el-table-column
232
             <el-table-column
233
               prop="name"
233
               prop="name"
234
               label="频率"
234
               label="频率"
235
-              width="160"
235
+              width="100"
236
               align="center"
236
               align="center"
237
             >
237
             >
238
               <template slot-scope="scope">
238
               <template slot-scope="scope">
242
             <el-table-column
242
             <el-table-column
243
               prop="name"
243
               prop="name"
244
               label="天数"
244
               label="天数"
245
-              width="160"
245
+              width="100"
246
               align="center"
246
               align="center"
247
             >
247
             >
248
               <template slot-scope="scope">
248
               <template slot-scope="scope">
252
             <el-table-column
252
             <el-table-column
253
               prop="name"
253
               prop="name"
254
               label="总量"
254
               label="总量"
255
-              width="160"
255
+              width="100"
256
               align="center"
256
               align="center"
257
             >
257
             >
258
               <template slot-scope="scope">
258
               <template slot-scope="scope">
259
                 {{ scope.row.total }}
259
                 {{ scope.row.total }}
260
               </template>
260
               </template>
261
             </el-table-column>
261
             </el-table-column>
262
+            <el-table-column label="药品追溯码" width="162" align="center">
263
+              <template slot-scope="scope">
264
+                 <el-input style="width: 100;" v-model="scope.row.DrugCode" @input="changeDrugCode(scope.row.ID,scope.row.DataSources,scope.row.DrugCode)"></el-input>
265
+              </template>
266
+            </el-table-column>
262
             <el-table-column
267
             <el-table-column
263
               prop="name"
268
               prop="name"
264
               label="数据来源"
269
               label="数据来源"
265
-              width="162"
270
+              width="102"
266
               align="center"
271
               align="center"
267
             >
272
             >
268
               <template slot-scope="scope">
273
               <template slot-scope="scope">
454
   getcurrentname,
459
   getcurrentname,
455
   getpartitionlist,
460
   getpartitionlist,
456
   routeofadministration,
461
   routeofadministration,
462
+  changeDrugCode
457
 } from "@/api/pharmacy";
463
 } from "@/api/pharmacy";
458
 const moment = require("moment");
464
 const moment = require("moment");
459
 export default {
465
 export default {
506
   },
512
   },
507
 
513
 
508
   methods: {
514
   methods: {
515
+    changeDrugCode(id,DataSources,drug_code){
516
+       var is_source =0
517
+       if (DataSources == "his处方"){
518
+        is_source = 1
519
+       }
520
+       if (DataSources == "临时医嘱"){
521
+         is_source = 2
522
+       }
523
+       var params = {
524
+        id:id,
525
+        data_source:is_source,
526
+        drug_code:drug_code,
527
+       }
528
+       console.log("paramss",params)
529
+      
530
+      changeDrugCode(params).then(response=>{
531
+         if(response.data.state == 1){
532
+            this.$message.success("保存成功!")
533
+         }
534
+      })
535
+    
536
+
537
+    },
509
     tt() {},
538
     tt() {},
510
     async fun3() {
539
     async fun3() {
511
       this.fun1().then((val) => {
540
       this.fun1().then((val) => {

+ 33 - 2
src/xt_pages/Pharmacy/PatientDispensing.vue View File

178
             <el-table-column
178
             <el-table-column
179
               type="index"
179
               type="index"
180
               label="序号"
180
               label="序号"
181
-              width="120"
181
+              width="50"
182
               align="center"
182
               align="center"
183
             >
183
             >
184
             </el-table-column>
184
             </el-table-column>
185
-            <el-table-column label="名称" width="200" align="center">
185
+            <el-table-column label="名称" width="100" align="center">
186
               <template slot-scope="scope">
186
               <template slot-scope="scope">
187
                 <span>{{ scope.row.Name ? scope.row.Name : "" }}</span>
187
                 <span>{{ scope.row.Name ? scope.row.Name : "" }}</span>
188
               </template>
188
               </template>
226
                 <span>{{ getManutuer(scope.row.DrugId) }}</span>
226
                 <span>{{ getManutuer(scope.row.DrugId) }}</span>
227
               </template>
227
               </template>
228
             </el-table-column>
228
             </el-table-column>
229
+            <el-table-column label="药品追溯码" width="162" align="center">
230
+              <template slot-scope="scope">
231
+                 <el-input style="width: 100;" v-model="scope.row.DrugCode" @input="changeDrugCode(scope.row.ID,scope.row.DataSources,scope.row.DrugCode)"></el-input>
232
+              </template>
233
+            </el-table-column>
229
             <el-table-column label="开立医生" width="150" align="center">
234
             <el-table-column label="开立医生" width="150" align="center">
230
               <template slot-scope="scope">
235
               <template slot-scope="scope">
231
                 <span>{{ scope.row.Doctor ? scope.row.Doctor : "" }}</span>
236
                 <span>{{ scope.row.Doctor ? scope.row.Doctor : "" }}</span>
243
                 <span>{{getDrugName(scope.row.DrugId)}}</span>
248
                 <span>{{getDrugName(scope.row.DrugId)}}</span>
244
               </template>
249
               </template>
245
             </el-table-column>
250
             </el-table-column>
251
+
252
+        
246
             <el-table-column label="备注" width="170" align="center">
253
             <el-table-column label="备注" width="170" align="center">
247
               <template slot-scope="scope">
254
               <template slot-scope="scope">
248
                 <span>{{ scope.row.Remarks ? scope.row.Remarks : "" }}</span>
255
                 <span>{{ scope.row.Remarks ? scope.row.Remarks : "" }}</span>
304
   dispensingmedicine,
311
   dispensingmedicine,
305
   drugwithdrawal,
312
   drugwithdrawal,
306
   getpartitionlist,
313
   getpartitionlist,
314
+  changeDrugCode
307
 } from "@/api/pharmacy";
315
 } from "@/api/pharmacy";
316
+import dataDruguse from "../../router/modules/dataDruguse";
308
 const moment = require("moment");
317
 const moment = require("moment");
309
 export default {
318
 export default {
310
   components: {
319
   components: {
792
          }
801
          }
793
        }
802
        }
794
        return spc
803
        return spc
804
+    },
805
+    changeDrugCode(id,DataSources,drug_code){
806
+       var is_source =0
807
+       if (DataSources == "his处方"){
808
+        is_source = 1
809
+       }
810
+       if (DataSources == "临时医嘱"){
811
+         is_source = 2
812
+       }
813
+       var params = {
814
+        id:id,
815
+        data_source:is_source,
816
+        drug_code:drug_code,
817
+       }
818
+       console.log("paramss",params)
819
+      changeDrugCode(params).then(response=>{
820
+         if(response.data.state == 1){
821
+            this.$message.success("保存成功!")
822
+         }
823
+      })
824
+    
825
+
795
     }
826
     }
796
   },
827
   },
797
 };
828
 };

+ 0 - 1
src/xt_pages/user/components/PatientDetail.vue View File

120
               <el-form-item
120
               <el-form-item
121
                 label="身份证号 : "
121
                 label="身份证号 : "
122
                 class="is-required"
122
                 class="is-required"
123
-                prop="idCardNo"
124
               >
123
               >
125
                 <el-input v-model="form.idCardNo" disabled></el-input>
124
                 <el-input v-model="form.idCardNo" disabled></el-input>
126
               </el-form-item>
125
               </el-form-item>

+ 0 - 2
src/xt_pages/user/components/PatientForm.vue View File

129
               <el-col :span="8" :style="isEdit ? 'width:360px' : ''">
129
               <el-col :span="8" :style="isEdit ? 'width:360px' : ''">
130
                 <el-form-item
130
                 <el-form-item
131
                   label="身份证号 : "
131
                   label="身份证号 : "
132
-                  prop="idCardNo"
133
                 >
132
                 >
134
                   <el-input
133
                   <el-input
135
-                    @input="checkIdCardNo"
136
                     v-model="form.idCardNo"
134
                     v-model="form.idCardNo"
137
                   ></el-input><!---->
135
                   ></el-input><!---->
138
                 </el-form-item>
136
                 </el-form-item>

+ 13 - 13
src/xt_permission.js View File

12
 
12
 
13
 router.beforeEach((to, from, next) => {
13
 router.beforeEach((to, from, next) => {
14
   // 线上注释
14
   // 线上注释
15
-  // if (!store.getters.configlist || store.getters.configlist === undefined || store.getters.configlist.length <= 0) {
16
-  //   store.dispatch('VerifyConfigList', []).then(() => {
17
-  //     next()
18
-  //   })
19
-  // }
20
-  // if (store.getters.permission_routers === undefined) {
21
-  //   store.dispatch('xt_GenerateRoutes', []).then(() => {
22
-  //     next()
23
-  //   })
24
-  // } else {
25
-  //   next()
26
-  // }
27
-  // return
15
+  if (!store.getters.configlist || store.getters.configlist === undefined || store.getters.configlist.length <= 0) {
16
+    store.dispatch('VerifyConfigList', []).then(() => {
17
+      next()
18
+    })
19
+  }
20
+  if (store.getters.permission_routers === undefined) {
21
+    store.dispatch('xt_GenerateRoutes', []).then(() => {
22
+      next()
23
+    })
24
+  } else {
25
+    next()
26
+  }
27
+  return
28
   // 线上注释
28
   // 线上注释
29
   NProgress.start()
29
   NProgress.start()
30
   // console.log(store.getters.current_role_urls.indexOf(to.path))
30
   // console.log(store.getters.current_role_urls.indexOf(to.path))