3 コミット 6d7fb79c6e ... 04b0176dcd

作者 SHA1 メッセージ 日付
  陈少旭 04b0176dcd Merge branch '20230223_pc_vue_new_branch' of http://git.shengws.com/csx/Vue_New into 20230223_pc_vue_new_branch 4 週間 前
  陈少旭 ea1af51047 1111 4 週間 前
  陈少旭 7a477910ef 1111 4 週間 前

+ 10 - 0
src/router/modules/drugSourceCode.js ファイルの表示

18
       component: () => import('@/xt_pages/drugSourceCode/drugStock'),
18
       component: () => import('@/xt_pages/drugSourceCode/drugStock'),
19
       name: 'drugStock',
19
       name: 'drugStock',
20
       meta: { title: 'drugStock', noCache: true }
20
       meta: { title: 'drugStock', noCache: true }
21
+    },{
22
+      path: '/drugSourceCode/goodStock',
23
+      component: () => import('@/xt_pages/drugSourceCode/goodStock'),
24
+      name: 'goodStock',
25
+      meta: { title: 'goodStock', noCache: true }
21
     },
26
     },
22
     {
27
     {
23
       path: '/drugSourceCode/drugChange',
28
       path: '/drugSourceCode/drugChange',
30
       component: () => import('@/xt_pages/drugSourceCode/drugQuery'),
35
       component: () => import('@/xt_pages/drugSourceCode/drugQuery'),
31
       name: 'drugQuery',
36
       name: 'drugQuery',
32
       meta: { title: 'drugQuery', noCache: true },
37
       meta: { title: 'drugQuery', noCache: true },
38
+    }, {
39
+      path: '/drugSourceCode/goodQuery',
40
+      component: () => import('@/xt_pages/drugSourceCode/goodQuery'),
41
+      name: 'goodQuery',
42
+      meta: { title: 'goodQuery', noCache: true },
33
     },
43
     },
34
     {
44
     {
35
       path: '/drugSourceCode/drugCodeQuery',
45
       path: '/drugSourceCode/drugCodeQuery',

+ 18 - 0
src/router/modules/goodGrant.js ファイルの表示

1
+
2
+import Layout from '@/views/layout/Layout'
3
+
4
+export default {
5
+  path: '/goodGrant',
6
+  component: Layout,
7
+  name:'goodGrant',
8
+  redirct: 'noredirect',
9
+  children: [{
10
+    path: '/Pharmacy/goodGrant',
11
+    component: () => import('@/xt_pages/Pharmacy/goodGrant.vue'),
12
+    name: '药房管理',
13
+    meta: {
14
+      title: "耗材发放",
15
+      noCache: true
16
+    }
17
+  },]
18
+}

File diff suppressed because it is too large
+ 1690 - 0
src/xt_pages/Pharmacy/goodGrant.vue


+ 791 - 0
src/xt_pages/drugSourceCode/goodQuery.vue ファイルの表示

1
+<template>
2
+  <div>
3
+    <div class="position">
4
+      <BreadCrumb :crumbs="crumbs"></BreadCrumb>
5
+    </div>
6
+    <div class="app-container">
7
+      <div style="display: flex;justify-content: space-between;margin-bottom:10px;">
8
+        <div class="cell clearfix">
9
+          <span>入库时间:</span>
10
+          <el-date-picker
11
+            size="small"
12
+            v-model="start_time"
13
+            prefix-icon="el-icon-date"
14
+            :editable="false"
15
+            style="width: 196px;"
16
+            type="date"
17
+            placeholder="选择日期时间"
18
+            align="right"
19
+            format="yyyy-MM-dd"
20
+            value-format="yyyy-MM-dd"
21
+            @change="startTimeChange"
22
+          ></el-date-picker>-
23
+          <el-date-picker
24
+            size="small"
25
+            v-model="end_time"
26
+            prefix-icon="el-icon-date"
27
+            :editable="false"
28
+            style="width: 196px;margin-right:10px;"
29
+            type="date"
30
+            placeholder="选择日期时间"
31
+            align="right"
32
+            format="yyyy-MM-dd"
33
+            value-format="yyyy-MM-dd"
34
+            @change="endTimeChange"
35
+          ></el-date-picker>
36
+        </div>
37
+
38
+        <div class="cell clearfix">
39
+          <div>查询类型:</div>
40
+          <el-select size="small" v-model="stock_type" placeholder="请选择"
41
+                     style="width:100px;margin-left:10px;" @change="changeStockType">
42
+            <el-option
43
+              v-for="item,index in items"
44
+              :key="index"
45
+              :label="item.name"
46
+              :value="item.id">
47
+            </el-option>
48
+          </el-select>
49
+        </div>
50
+
51
+        <div class="cell clearfix">
52
+          <div>耗材:</div>
53
+          <el-select size="small" v-model="drug_id" placeholder="请选择"
54
+                     style="width:100px;margin-left:10px;" @change="change">
55
+            <el-option
56
+              label="全部"
57
+              value="0">
58
+            </el-option>
59
+            <el-option
60
+              v-for="item,index in drugs"
61
+              :key="index"
62
+              :label="item.good_name"
63
+              :value="item.id">
64
+            </el-option>
65
+          </el-select>
66
+        </div>
67
+        <div>
68
+          <el-button type="primary" @click="query()">查询</el-button>
69
+          <el-button type="primary" @click="export_detail()">导出</el-button>
70
+
71
+        </div>
72
+      </div>
73
+      <el-table v-if="stock_type == 3" :data="tableData" border :row-style="{ color: '#303133' }" ref="table"
74
+                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
75
+                max-height="600"
76
+                highlight-current-row>
77
+        <el-table-column align="center" prop="name" label="耗材名称">
78
+          <template slot-scope="scope">{{scope.row.MedinsListName}}</template>
79
+        </el-table-column>
80
+        <el-table-column align="center" prop="name" label="国家编码">
81
+          <template slot-scope="scope">{{scope.row.MedListCodg}}</template>
82
+        </el-table-column>
83
+        <el-table-column align="center" prop="name" label="销售/退货数量">
84
+          <template slot-scope="scope">
85
+            <div>{{scope.row.SelRetnCnt}}</div>
86
+          </template>
87
+        </el-table-column>
88
+
89
+        <el-table-column align="center" prop="name" label="销售/退货时间">
90
+          <template slot-scope="scope">
91
+            <div>{{scope.row.SelRetnTime}}</div>
92
+          </template>
93
+        </el-table-column>
94
+
95
+
96
+        <el-table-column align="center" prop="total" label="药师姓名">
97
+          <template slot-scope="scope">
98
+            <div>{{scope.row.PharName}}</div>
99
+          </template>
100
+        </el-table-column>
101
+
102
+        <el-table-column align="center" prop="total" label="生产日期">
103
+          <template slot-scope="scope">
104
+            <div>{{scope.row.ManuDate}}</div>
105
+          </template>
106
+        </el-table-column>
107
+
108
+
109
+        <el-table-column align="center" prop="total" label="记录号">
110
+          <template slot-scope="scope">
111
+            <div>{{scope.row.Rid}}</div>
112
+          </template>
113
+        </el-table-column>
114
+
115
+
116
+        <el-table-column align="center" prop="total" label="有效标志">
117
+          <template slot-scope="scope">
118
+            <div>{{scope.row.ValiFlag}}</div>
119
+          </template>
120
+        </el-table-column>
121
+        <el-table-column align="center" prop="total" label="批次流水号">
122
+          <template slot-scope="scope">
123
+            <div>{{scope.row.FixmedinsBchno}}</div>
124
+          </template>
125
+        </el-table-column>
126
+
127
+        <el-table-column align="center" prop="total" label="经办时间">
128
+          <template slot-scope="scope">
129
+            <div></div>
130
+          </template>
131
+        </el-table-column>
132
+      </el-table>
133
+      <el-table v-if="stock_type == 4" :data="tableData" border :row-style="{ color: '#303133' }" ref="table"
134
+                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
135
+                max-height="600"
136
+                highlight-current-row>
137
+        <el-table-column align="center" prop="name" label="耗材名称">
138
+          <template slot-scope="scope">{{scope.row.MedinsListName}}</template>
139
+        </el-table-column>
140
+        <el-table-column align="center" prop="name" label="国家编码">
141
+          <template slot-scope="scope">{{scope.row.MedListCodg}}</template>
142
+        </el-table-column>
143
+        <el-table-column align="center" prop="name" label="耗材追溯码">
144
+          <template slot-scope="scope">
145
+            <div>{{scope.row.DrugTracCodg}}</div>
146
+          </template>
147
+        </el-table-column>
148
+        <el-table-column align="center" prop="total" label="批次流水号">
149
+          <template slot-scope="scope">
150
+            <div>{{scope.row.FixmedinsBchno}}</div>
151
+          </template>
152
+        </el-table-column>
153
+      </el-table>
154
+      <el-table  v-if="stock_type == 5"  :data="tableData"  border :row-style="{ color: '#303133' }" ref="table"
155
+                 :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
156
+                 max-height="600"
157
+                 highlight-current-row>
158
+
159
+        <el-table-column align="center" prop="name" label="就诊ID">
160
+          <template slot-scope="scope">{{scope.row.MdtrtId}}</template>
161
+        </el-table-column>
162
+        <el-table-column align="center" prop="name" label="耗材名称">
163
+          <template slot-scope="scope">{{scope.row.MedinsListName}}</template>
164
+        </el-table-column>
165
+
166
+        <el-table-column align="center" prop="name" label="患者名称">
167
+          <template slot-scope="scope">{{scope.row.PsnName}}</template>
168
+        </el-table-column>
169
+
170
+        <el-table-column align="center" prop="name" label="耗材追溯码">
171
+          <template slot-scope="scope">
172
+            <div>{{scope.row.DrugTracCodg}}</div>
173
+          </template>
174
+        </el-table-column>
175
+        <el-table-column align="center" prop="name" label="上传日期">
176
+          <template slot-scope="scope">
177
+            <div>{{scope.row.UpdtTime}}</div>
178
+          </template>
179
+        </el-table-column>
180
+
181
+        <el-table-column align="center" prop="total" label="批次流水号">
182
+          <template slot-scope="scope">
183
+            <div>{{scope.row.FixmedinsBchno}}</div>
184
+          </template>
185
+        </el-table-column>
186
+
187
+
188
+      </el-table>
189
+    </div>
190
+    <!--    <el-table v-if="stock_type == 1" :data="tableData" border :row-style="{ color: '#303133' }" ref="table"-->
191
+    <!--              :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"-->
192
+    <!--              max-height="600"-->
193
+    <!--              highlight-current-row>-->
194
+    <!--      <el-table-column align="center" prop="name" label="药品名称">-->
195
+    <!--        <template slot-scope="scope">{{scope.row.MedinsListName}}</template>-->
196
+    <!--      </el-table-column>-->
197
+    <!--      <el-table-column align="center" prop="name" label="国家编码">-->
198
+    <!--        <template slot-scope="scope">{{scope.row.MedListCodg}}</template>-->
199
+    <!--      </el-table-column>-->
200
+    <!--      <el-table-column align="center" prop="name" label="库存数量">-->
201
+    <!--        <template slot-scope="scope">-->
202
+    <!--          <div>{{scope.row.InvCnt}}</div>-->
203
+    <!--        </template>-->
204
+    <!--      </el-table-column>-->
205
+
206
+    <!--      <el-table-column align="center" prop="name" label="更新时间">-->
207
+    <!--        <template slot-scope="scope">-->
208
+    <!--          <div>{{scope.row.UpdtTime}}</div>-->
209
+    <!--        </template>-->
210
+    <!--      </el-table-column>-->
211
+
212
+
213
+    <!--      <el-table-column align="center" prop="total" label="生产日期">-->
214
+    <!--        <template slot-scope="scope">-->
215
+    <!--          <div>{{scope.row.ManuDate}}</div>-->
216
+    <!--        </template>-->
217
+    <!--      </el-table-column>-->
218
+
219
+
220
+    <!--      <el-table-column align="center" prop="total" label="记录号">-->
221
+    <!--        <template slot-scope="scope">-->
222
+    <!--          <div>{{scope.row.Rid}}</div>-->
223
+    <!--        </template>-->
224
+    <!--      </el-table-column>-->
225
+
226
+
227
+    <!--      <el-table-column align="center" prop="total" label="库存日期">-->
228
+    <!--        <template slot-scope="scope">-->
229
+    <!--          <div>{{scope.row.Invdate}}</div>-->
230
+    <!--        </template>-->
231
+    <!--      </el-table-column>-->
232
+
233
+    <!--      <el-table-column align="center" prop="total" label="有效标志">-->
234
+    <!--        <template slot-scope="scope">-->
235
+    <!--          <div>{{scope.row.ValiFlag}}</div>-->
236
+    <!--        </template>-->
237
+    <!--      </el-table-column>-->
238
+    <!--      <el-table-column align="center" prop="total" label="批次流水号">-->
239
+    <!--        <template slot-scope="scope">-->
240
+    <!--          <div>{{scope.row.FixmedinsBchno}}</div>-->
241
+    <!--        </template>-->
242
+    <!--      </el-table-column>-->
243
+
244
+    <!--      <el-table-column align="center" prop="total" label="经办时间">-->
245
+    <!--        <template slot-scope="scope">-->
246
+    <!--          <div></div>-->
247
+    <!--        </template>-->
248
+    <!--      </el-table-column>-->
249
+
250
+    <!--      <el-table-column align="center" prop="total" label="经办人">-->
251
+    <!--        <template slot-scope="scope">-->
252
+    <!--          <div>{{scope.row.OptTime}}</div>-->
253
+    <!--        </template>-->
254
+    <!--      </el-table-column>-->
255
+
256
+
257
+    <!--    </el-table>-->
258
+
259
+
260
+    <!--    <el-table v-if="stock_type == 2" :data="tableData" border :row-style="{ color: '#303133' }" ref="table"-->
261
+    <!--              :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"-->
262
+    <!--              max-height="600"-->
263
+    <!--              highlight-current-row>-->
264
+    <!--      <el-table-column align="center" prop="name" label="药品名称">-->
265
+    <!--        <template slot-scope="scope">{{scope.row.MedinsListName}}</template>-->
266
+    <!--      </el-table-column>-->
267
+    <!--      <el-table-column align="center" prop="name" label="国家编码">-->
268
+    <!--        <template slot-scope="scope">{{scope.row.MedListCodg}}</template>-->
269
+    <!--      </el-table-column>-->
270
+    <!--      <el-table-column align="center" prop="name" label="变更类型">-->
271
+    <!--        <template slot-scope="scope"></template>-->
272
+    <!--      </el-table-column>-->
273
+    <!--      <el-table-column align="center" prop="name" label="变更数量">-->
274
+    <!--        <template slot-scope="scope">-->
275
+    <!--          <div>{{scope.row.Cnt}}</div>-->
276
+    <!--        </template>-->
277
+    <!--      </el-table-column>-->
278
+
279
+    <!--      <el-table-column align="center" prop="name" label="单价">-->
280
+    <!--        <template slot-scope="scope">-->
281
+    <!--          <div>{{scope.row.Pric}}</div>-->
282
+    <!--        </template>-->
283
+    <!--      </el-table-column>-->
284
+
285
+    <!--      <el-table-column align="center" prop="name" label="库存变更时间">-->
286
+    <!--        <template slot-scope="scope">-->
287
+    <!--          <div>{{scope.row.InvChgTime}}</div>-->
288
+    <!--        </template>-->
289
+    <!--      </el-table-column>-->
290
+
291
+
292
+    <!--      <el-table-column align="center" prop="name" label="变更经办人">-->
293
+    <!--        <template slot-scope="scope">-->
294
+    <!--          <div>{{scope.row.InvChgOpterName}}</div>-->
295
+    <!--        </template>-->
296
+    <!--      </el-table-column>-->
297
+
298
+    <!--      <el-table-column align="center" prop="total" label="有效标志">-->
299
+    <!--        <template slot-scope="scope">-->
300
+    <!--          <div>{{scope.row.ValiFlag}}</div>-->
301
+    <!--        </template>-->
302
+    <!--      </el-table-column>-->
303
+
304
+    <!--      <el-table-column align="center" prop="total" label="批次流水号">-->
305
+    <!--        <template slot-scope="scope">-->
306
+    <!--          <div>{{scope.row.FixmedinsBchno}}</div>-->
307
+    <!--        </template>-->
308
+    <!--      </el-table-column>-->
309
+
310
+
311
+    <!--      <el-table-column align="center" prop="total" label="经办时间">-->
312
+    <!--        <template slot-scope="scope">-->
313
+    <!--          <div></div>-->
314
+    <!--        </template>-->
315
+    <!--      </el-table-column>-->
316
+
317
+    <!--      <el-table-column align="center" prop="total" label="经办人">-->
318
+    <!--        <template slot-scope="scope">-->
319
+    <!--          <div>{{scope.row.OptTime}}</div>-->
320
+    <!--        </template>-->
321
+    <!--      </el-table-column>-->
322
+
323
+    <!--      <el-table-column align="center" prop="total" label="记录号">-->
324
+    <!--        <template slot-scope="scope">-->
325
+    <!--          <div>{{scope.row.Rid}}</div>-->
326
+    <!--        </template>-->
327
+    <!--      </el-table-column>-->
328
+
329
+
330
+    <!--    </el-table>-->
331
+
332
+
333
+
334
+
335
+
336
+
337
+    <!--&lt;!&ndash;    实时库存&ndash;&gt;-->
338
+    <!--    <div v-if="stock_type == 6">-->
339
+    <!--    <el-table  :data="tableData" border :row-style="{ color: '#303133' }" ref="table"-->
340
+    <!--              :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"-->
341
+    <!--              max-height="600"-->
342
+    <!--              highlight-current-row>-->
343
+    <!--      <el-table-column align="center" prop="name" label="药品名称">-->
344
+    <!--        <template slot-scope="scope">{{scope.row.MedinsListName}}</template>-->
345
+    <!--      </el-table-column>-->
346
+    <!--      <el-table-column align="center" prop="name" label="国家编码">-->
347
+    <!--        <template slot-scope="scope">{{scope.row.MedListCodg}}</template>-->
348
+    <!--      </el-table-column>-->
349
+    <!--      <el-table-column align="center" prop="name" label="库存数量">-->
350
+    <!--        <template slot-scope="scope">{{scope.row.InvCnt}}</template>-->
351
+    <!--      </el-table-column>-->
352
+    <!--      <el-table-column align="center" prop="name" label="销售价格">-->
353
+    <!--        <template slot-scope="scope">{{scope.row.Pric}}</template>-->
354
+    <!--      </el-table-column>-->
355
+
356
+    <!--      <el-table-column align="center" prop="name" label="库存日期">-->
357
+    <!--        <template slot-scope="scope">{{scope.row.Invdate}}</template>-->
358
+    <!--      </el-table-column>-->
359
+
360
+    <!--      <el-table-column align="center" prop="total" label="批次流水号">-->
361
+    <!--        <template slot-scope="scope">-->
362
+    <!--          <div>{{scope.row.FixmedinsBchno}}</div>-->
363
+    <!--        </template>-->
364
+    <!--      </el-table-column>-->
365
+    <!--      <el-table-column align="center" prop="name" label="更新时间">-->
366
+    <!--        <template slot-scope="scope">-->
367
+    <!--          <div>{{scope.row.UpdtTime}}</div>-->
368
+    <!--        </template>-->
369
+    <!--      </el-table-column>-->
370
+
371
+
372
+
373
+
374
+    <!--    </el-table>-->
375
+
376
+    <!--    </div>-->
377
+
378
+
379
+    <!--    <div v-if="stock_type == 7">-->
380
+    <!--      <el-table :data="tableData" border :row-style="{ color: '#303133' }" ref="table"-->
381
+    <!--                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"-->
382
+    <!--                max-height="600"-->
383
+    <!--                highlight-current-row>-->
384
+    <!--        <el-table-column align="center" prop="name" label="药品名称">-->
385
+    <!--          <template slot-scope="scope">{{scope.row.MedinsListName}}</template>-->
386
+    <!--        </el-table-column>-->
387
+    <!--        <el-table-column align="center" prop="name" label="国家编码">-->
388
+    <!--          <template slot-scope="scope">{{scope.row.MedListCodg}}</template>-->
389
+    <!--        </el-table-column>-->
390
+    <!--        <el-table-column align="center" prop="name" label="库存数量">-->
391
+    <!--          <template slot-scope="scope">{{scope.row.InvCnt}}</template>-->
392
+    <!--        </el-table-column>-->
393
+    <!--        <el-table-column align="center" prop="name" label="销售价格">-->
394
+    <!--          <template slot-scope="scope">{{scope.row.Pric}}</template>-->
395
+    <!--        </el-table-column>-->
396
+
397
+    <!--        <el-table-column align="center" prop="name" label="库存变更类型">-->
398
+    <!--          <template slot-scope="scope">{{scope.row.InvChgType}}</template>-->
399
+    <!--        </el-table-column>-->
400
+
401
+    <!--        <el-table-column align="center" prop="total" label="批次流水号">-->
402
+    <!--          <template slot-scope="scope">-->
403
+    <!--            <div>{{scope.row.FixmedinsBchno}}</div>-->
404
+    <!--          </template>-->
405
+    <!--        </el-table-column>-->
406
+
407
+    <!--      </el-table>-->
408
+    <!--    </div>-->
409
+
410
+
411
+    <!--    <el-table :data="tableData_two" border :row-style="{ color: '#303133' }" ref="table"-->
412
+    <!--              :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"-->
413
+    <!--              max-height="600"-->
414
+    <!--              highlight-current-row>-->
415
+    <!--      <el-table-column align="center" prop="name" label="药品名称">-->
416
+    <!--        <template slot-scope="scope">{{scope.row.medinsListName}}</template>-->
417
+    <!--      </el-table-column>-->
418
+    <!--      <el-table-column align="center" prop="name" label="国家编码">-->
419
+    <!--        <template slot-scope="scope">{{scope.row.medListCodg}}</template>-->
420
+    <!--      </el-table-column>-->
421
+    <!--      <el-table-column align="center" prop="name" label="变更类型">-->
422
+    <!--        <template slot-scope="scope">{{}}</template>-->
423
+    <!--      </el-table-column>-->
424
+    <!--      <el-table-column align="center" prop="name" label="变更数量">-->
425
+    <!--        <template slot-scope="scope">-->
426
+    <!--          <div>{{scope.row.cnt}}</div>-->
427
+    <!--        </template>-->
428
+    <!--      </el-table-column>-->
429
+
430
+    <!--      <el-table-column align="center" prop="name" label="单价">-->
431
+    <!--        <template slot-scope="scope">-->
432
+    <!--          <div>{{scope.row.pric}}</div>-->
433
+    <!--        </template>-->
434
+    <!--      </el-table-column>-->
435
+
436
+    <!--      <el-table-column align="center" prop="name" label="库存变更时间">-->
437
+    <!--        <template slot-scope="scope">-->
438
+    <!--          <div>{{scope.row.invChgTime}}</div>-->
439
+    <!--        </template>-->
440
+    <!--      </el-table-column>-->
441
+
442
+
443
+    <!--      <el-table-column align="center" prop="name" label="变更经办人">-->
444
+    <!--        <template slot-scope="scope">-->
445
+    <!--          <div>{{scope.row.invChgOpterName}}</div>-->
446
+    <!--        </template>-->
447
+    <!--      </el-table-column>-->
448
+
449
+    <!--      <el-table-column align="center" prop="total" label="有效标志">-->
450
+    <!--        <template slot-scope="scope">-->
451
+    <!--          <div>{{scope.row.valiFlag}}</div>-->
452
+    <!--        </template>-->
453
+    <!--      </el-table-column>-->
454
+
455
+    <!--      <el-table-column align="center" prop="total" label="批次流水号">-->
456
+    <!--        <template slot-scope="scope">-->
457
+    <!--          <div>{{scope.row.fixmedinsBchno}}</div>-->
458
+    <!--        </template>-->
459
+    <!--      </el-table-column>-->
460
+
461
+
462
+    <!--      <el-table-column align="center" prop="total" label="经办时间">-->
463
+    <!--        <template slot-scope="scope">-->
464
+    <!--          <div></div>-->
465
+    <!--        </template>-->
466
+    <!--      </el-table-column>-->
467
+
468
+    <!--      <el-table-column align="center" prop="total" label="经办人">-->
469
+    <!--        <template slot-scope="scope">-->
470
+    <!--          <div>{{scope.row.optTime}}</div>-->
471
+    <!--        </template>-->
472
+    <!--      </el-table-column>-->
473
+
474
+    <!--      <el-table-column align="center" prop="total" label="记录号">-->
475
+    <!--        <template slot-scope="scope">-->
476
+    <!--          <div>{{scope.row.rid}}</div>-->
477
+    <!--        </template>-->
478
+    <!--      </el-table-column>-->
479
+
480
+    <!--      <el-table-column label="操作" width="200">-->
481
+    <!--        <template slot-scope="scope">-->
482
+    <!--          <el-button type="text" @click="delete(scope.row)">删除</el-button>-->
483
+    <!--        </template>-->
484
+    <!--      </el-table-column>-->
485
+    <!--    </el-table>-->
486
+
487
+
488
+  </div>
489
+
490
+  <!-- </div> -->
491
+</template>
492
+
493
+
494
+<script>
495
+import {
496
+  getGood
497
+} from '@/api/his/his'
498
+import BreadCrumb from '@/xt_pages/components/bread-crumb'
499
+import axios from 'axios'
500
+const moment = require('moment')
501
+export default {
502
+  components: {
503
+    BreadCrumb
504
+  },
505
+  data() {
506
+    return {
507
+      start_time: new Date(new Date().getFullYear(), new Date().getMonth(), 1).toLocaleDateString('en-CA'),
508
+      end_time: new Date(new Date().getFullYear(), new Date().getMonth() + 3, 0).toLocaleDateString('en-CA'),
509
+      tableData: [],
510
+      tableData_two:[],
511
+      stock_type:4,
512
+      drug_id:"",
513
+      items: [
514
+        { id: 4, name: '入库耗材追溯信息查询' },
515
+        { id: 5, name: '耗材销售追溯信息查询' },
516
+      ],
517
+      drugs: [
518
+
519
+      ]
520
+    }
521
+  },
522
+  methods: {
523
+    // 药品数据源
524
+    getInitData() {
525
+      getGood().then(response => {
526
+        if (response.data.state == 0) {
527
+          this.$message.error(response.data.msg)
528
+          return false
529
+        } else {
530
+          this.drugs = response.data.data.drugs
531
+          this.drug_id = "0"
532
+        }
533
+      })
534
+    },
535
+    delete(){
536
+    },
537
+    export_detail() {
538
+      let list = []
539
+      for (let i = 0; i < this.tableData.length; i++) {
540
+        let order = this.tableData[i]
541
+        let name = order.FixmedinsBchno
542
+        let obj = {
543
+          '患者姓名': name,
544
+        }
545
+        list.push(obj)
546
+      }
547
+      import('@/vendor/Export2Excel').then(excel => {
548
+        const tHeader = ['患者姓名']
549
+        const filterVal = ['患者姓名']
550
+        const data = this.formatJson(filterVal, list)
551
+        excel.export_json_to_excel1({
552
+          header: tHeader,
553
+          data,
554
+          filename: '明细',
555
+          ref: this.$refs['table'].$el
556
+        })
557
+      })
558
+
559
+    }, formatJson(filterVal, jsonData) {
560
+      return jsonData.map(v => filterVal.map(j => v[j]))
561
+    },
562
+    stock(){
563
+
564
+
565
+
566
+    },exports(){
567
+
568
+
569
+    },
570
+    query(){
571
+      var that = this;
572
+      let params = {
573
+        id:this.drug_id,
574
+        start_time:this.start_time,
575
+        end_time:this.end_time,
576
+        admin_user_id:this.$store.getters.xt_user.user.id
577
+      };
578
+
579
+
580
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
581
+        if (response.data.state == 0) {
582
+          that.isloading = false
583
+
584
+          // that.$message.error(response.data.data.msg);
585
+          that.$confirm("请检查医保程序是否有打开", "提示", {
586
+            confirmButtonText: "确 定",
587
+            cancelButtonText: "取 消",
588
+            type: "warning",
589
+          }).then(() => {
590
+
591
+
592
+          })
593
+            .catch(() => {});
594
+          return false
595
+        } else {
596
+          console.log("-------ssajsnaskjnajska")
597
+          that.tableData = []
598
+          console.log(that.stock_type)
599
+
600
+          if(that.stock_type == 1){
601
+            axios.get('http://127.0.0.1:9532/api/3508',{params:params}).then(function(response) {
602
+              if (response.data.state == 0) {
603
+                that.$message.error(response.data.data.msg);
604
+                return false
605
+              } else {
606
+                if(response.data.data.failed_code == -10){
607
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
608
+                    confirmButtonText: '确 定',
609
+                    type: 'warning'
610
+                  }).then(() => {
611
+
612
+                  }).catch(() => {
613
+
614
+                  })
615
+                }else{
616
+                  that.tableData = that.tableData.concat(response.data.data.info)
617
+
618
+                }
619
+              }
620
+            }).catch(function(error) {
621
+            })
622
+
623
+          }else if(that.stock_type == 2){
624
+            axios.get('http://127.0.0.1:9532/api/3509',{params:params}).then(function(response) {
625
+              if (response.data.state == 0) {
626
+                that.$message.error(response.data.data.msg);
627
+                return false
628
+              } else {
629
+                if(response.data.data.failed_code == -10){
630
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
631
+                    confirmButtonText: '确 定',
632
+                    type: 'warning'
633
+                  }).then(() => {
634
+
635
+                  }).catch(() => {
636
+                  })
637
+                }else{
638
+                  that.tableData = that.tableData.concat(response.data.data.info)
639
+
640
+                }
641
+              }
642
+            }).catch(function(error) {
643
+            })
644
+
645
+          }else if(that.stock_type == 3){
646
+            axios.get('http://127.0.0.1:9532/api/3511',{params:params}).then(function(response) {
647
+              if (response.data.state == 0) {
648
+                that.$message.error(response.data.data.msg);
649
+                return false
650
+              } else {
651
+                if(response.data.data.failed_code == -10){
652
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
653
+                    confirmButtonText: '确 定',
654
+                    type: 'warning'
655
+                  }).then(() => {
656
+
657
+                  }).catch(() => {
658
+                  })
659
+                }else{
660
+                  that.tableData = that.tableData.concat(response.data.data.info)
661
+
662
+                }
663
+              }
664
+            }).catch(function(error) {
665
+            })
666
+
667
+          }else if(that.stock_type == 4){
668
+            axios.get('http://127.0.0.1:9532/api/3512',{params:params}).then(function(response) {
669
+              if (response.data.state == 0) {
670
+                that.$message.error(response.data.data.msg);
671
+                return false
672
+              } else {
673
+                if(response.data.data.failed_code == -10){
674
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
675
+                    confirmButtonText: '确 定',
676
+                    type: 'warning'
677
+                  }).then(() => {
678
+
679
+                  }).catch(() => {
680
+                  })
681
+                }else{
682
+                  that.tableData = that.tableData.concat(response.data.data.info)
683
+
684
+                }
685
+              }
686
+            }).catch(function(error) {
687
+            })
688
+
689
+          }else if(that.stock_type == 5){
690
+            axios.get('http://127.0.0.1:9532/api/3513',{params:params}).then(function(response) {
691
+              if (response.data.state == 0) {
692
+                that.$message.error(response.data.data.msg);
693
+                return false
694
+              } else {
695
+                if(response.data.data.failed_code == -10){
696
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
697
+                    confirmButtonText: '确 定',
698
+                    type: 'warning'
699
+                  }).then(() => {
700
+
701
+                  }).catch(() => {
702
+                  })
703
+                }else{
704
+                  that.tableData = that.tableData.concat(response.data.data.info)
705
+
706
+                }
707
+              }
708
+            }).catch(function(error) {
709
+            })
710
+
711
+          }else if(that.stock_type == 6){
712
+
713
+            axios.get('http://127.0.0.1:9532/api/35081',{params:params}).then(function(response) {
714
+              if (response.data.state == 0) {
715
+                that.$message.error(response.data.data.msg);
716
+                return false
717
+              } else {
718
+                if(response.data.data.failed_code == -10){
719
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
720
+                    confirmButtonText: '确 定',
721
+                    type: 'warning'
722
+                  }).then(() => {
723
+
724
+                  }).catch(() => {
725
+                  })
726
+                }else{
727
+                  that.tableData = that.tableData.concat(response.data.data.info)
728
+
729
+                }
730
+              }
731
+            }).catch(function(error) {
732
+            })
733
+
734
+          }else if(that.stock_type == 7){
735
+            axios.get('http://127.0.0.1:9532/api/35082',{params:params}).then(function(response) {
736
+              if (response.data.state == 0) {
737
+                that.$message.error(response.data.data.msg);
738
+                return false
739
+              } else {
740
+                if(response.data.data.failed_code == -10){
741
+                  that.$confirm(response.data.data.msg, '医保错误信息', {
742
+                    confirmButtonText: '确 定',
743
+                    type: 'warning'
744
+                  }).then(() => {
745
+
746
+                  }).catch(() => {
747
+                  })
748
+                }else{
749
+                  that.tableData = that.tableData.concat(response.data.data.info)
750
+
751
+                }
752
+              }
753
+            }).catch(function(error) {
754
+            })
755
+          }
756
+        }
757
+      }).catch(function(error) {
758
+        that.$confirm("请检查医保程序是否有打开", "提示", {
759
+          confirmButtonText: "确 定",
760
+          cancelButtonText: "取 消",
761
+          type: "warning",
762
+        }).then(() => {
763
+        })
764
+          .catch(() => {});
765
+      })
766
+
767
+    },
768
+    change(){
769
+
770
+
771
+    },
772
+    changeStockType(){
773
+
774
+
775
+    },
776
+    endTimeChange(){
777
+
778
+
779
+    },
780
+    startTimeChange(){
781
+
782
+
783
+    },
784
+  },
785
+  created() {
786
+    this.getInitData()
787
+
788
+  }
789
+}
790
+</script>
791
+

+ 566 - 0
src/xt_pages/drugSourceCode/goodStock.vue ファイルの表示

1
+<template>
2
+  <div>
3
+    <div class="position">
4
+      <BreadCrumb :crumbs="crumbs"></BreadCrumb>
5
+    </div>
6
+    <div class="app-container">
7
+      <div style="display: flex;justify-content: space-between;margin-bottom:10px;">
8
+        <div class="cell clearfix" >
9
+          <span>入库时间:</span>
10
+          <el-date-picker
11
+            size="small"
12
+            v-model="start_time"
13
+            prefix-icon="el-icon-date"
14
+            :editable="false"
15
+            style="width: 196px;"
16
+            type="date"
17
+            placeholder="选择日期时间"
18
+            align="right"
19
+            format="yyyy-MM-dd"
20
+            value-format="yyyy-MM-dd"
21
+            @change="startTimeChange"
22
+          ></el-date-picker>-
23
+          <el-date-picker
24
+            size="small"
25
+            v-model="end_time"
26
+            prefix-icon="el-icon-date"
27
+            :editable="false"
28
+            style="width: 196px;margin-right:10px;"
29
+            type="date"
30
+            placeholder="选择日期时间"
31
+            align="right"
32
+            format="yyyy-MM-dd"
33
+            value-format="yyyy-MM-dd"
34
+            @change="endTimeChange"
35
+          ></el-date-picker>
36
+
37
+          <span>销售状态:</span>
38
+          <el-select size="small" v-model="stock_type" placeholder="请选择"
39
+                     style="width:100px;" @change="changeStock">
40
+            <el-option
41
+              label="不限"
42
+              value="0">
43
+            </el-option>
44
+            <el-option
45
+              v-for="item,index in items"
46
+              :key="index"
47
+              :label="item.name"
48
+              :value="item.id">
49
+            </el-option>
50
+          </el-select>
51
+        </div>
52
+
53
+        <!--        <el-input size="small" style="width:150px;" v-model="keywords" @input="searchAction"-->
54
+        <!--                  @keyup.enter.native='searchAction'-->
55
+        <!--                  placeholder="请输入药品名称"-->
56
+        <!--                  class="filter-item"/>-->
57
+
58
+        <div>
59
+          <el-button type="primary" @click="query()" >查询</el-button>
60
+          <el-button type="primary" v-loading="isloading" @click="stock()">盘存</el-button>
61
+          <el-button type="primary" @click="exportdata()">导出</el-button>
62
+        </div>
63
+      </div>
64
+      <el-table :data="tableData" border :row-style="{ color: '#303133', height: '40px' }" ref="table2"
65
+                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266' }"
66
+                max-height="600"
67
+                @select="selectCostInfo"
68
+                @selection-change="changeCostInfoTableData"
69
+                @select-all="changeAllCostInfoTableData"
70
+                highlight-current-row>
71
+        <el-table-column
72
+          align="center"
73
+          type="selection"
74
+          width="55"
75
+        ></el-table-column>
76
+        <el-table-column align="center" prop="name" label="耗材名称">
77
+          <template slot-scope="scope">{{scope.row.drug_name}}</template>
78
+        </el-table-column>
79
+
80
+        <el-table-column align="center" prop="name" label="规格">
81
+          <template slot-scope="scope">{{scope.row.spec}}</template>
82
+        </el-table-column>
83
+
84
+        <el-table-column  width="100px"   align="center" prop="name" label="追溯码">
85
+          <template slot-scope="scope">{{scope.row.drug_code}}</template>
86
+        </el-table-column>
87
+
88
+        <el-table-column  width="100px"   align="center" prop="name" label="追溯码数量">
89
+          <template slot-scope="scope">{{getCount(scope.row.drug_code)}}</template>
90
+        </el-table-column>
91
+
92
+        <el-table-column align="center" prop="name" label="批号">
93
+          <template slot-scope="scope">{{scope.row.batch_number}}</template>
94
+        </el-table-column>
95
+
96
+
97
+        <el-table-column align="center" prop="name" label="入库数量">
98
+          <template slot-scope="scope">
99
+            <div>{{scope.row.count}}{{scope.row.unit}}</div>
100
+          </template>
101
+        </el-table-column>
102
+
103
+        <el-table-column align="center" prop="total" label="生产日期">
104
+          <template slot-scope="scope">
105
+            <div>{{scope.row.p_date}}</div>
106
+          </template>
107
+        </el-table-column>
108
+
109
+
110
+
111
+
112
+
113
+        <el-table-column align="center" prop="total" label="盘存状态">
114
+          <template slot-scope="scope">
115
+            <div>{{scope.row.is_pc?'已盘存':'未盘存'}}</div>
116
+          </template>
117
+        </el-table-column>
118
+
119
+
120
+
121
+        <el-table-column align="center" prop="total" label="盘存日期">
122
+          <template slot-scope="scope">
123
+            <div>{{scope.row.pc_date}}</div>
124
+          </template>
125
+        </el-table-column>
126
+
127
+        <el-table-column label="操作" width="200">
128
+          <template slot-scope="scope">
129
+            <el-button v-if="!scope.row.is_pc || scope.row.is_pc == 0" type="primary" @click="sigle_stock(scope.row)">盘存</el-button>
130
+            <el-button v-if="scope.row.is_pc == 1 || scope.row.is_pc == 1"  type="primary" @click="deleteStock(scope.row)">撤销</el-button>
131
+          </template>
132
+        </el-table-column>
133
+      </el-table>
134
+
135
+
136
+      <el-table v-show="false" :data="tableData" border :row-style="{ color: '#303133' }" ref="table"
137
+                :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
138
+                max-height="600"
139
+                @select="selectCostInfo"
140
+                @selection-change="changeCostInfoTableData"
141
+                @select-all="changeAllCostInfoTableData"
142
+                highlight-current-row>
143
+        <el-table-column
144
+          align="center"
145
+          type="selection"
146
+          width="55"
147
+        ></el-table-column>
148
+        <el-table-column align="center" prop="name" label="药品名称">
149
+          <template slot-scope="scope">{{scope.row.drug_name}}</template>
150
+        </el-table-column>
151
+        <el-table-column align="center" prop="name" label="药品类型">
152
+          <template slot-scope="scope">{{scope.row.drug_type}}</template>
153
+        </el-table-column>
154
+        <el-table-column align="center" prop="name" label="规格单位">
155
+          <template slot-scope="scope">{{scope.row.spec}}</template>
156
+        </el-table-column>
157
+        <el-table-column align="center" prop="name" label="国家编码">
158
+          <template slot-scope="scope">{{scope.row.code}}</template>
159
+        </el-table-column>
160
+        <el-table-column align="center" prop="name" label="批号">
161
+          <template slot-scope="scope">{{scope.row.batch_number}}</template>
162
+        </el-table-column>
163
+        <el-table-column align="center" prop="name" label="入库数量">
164
+          <template slot-scope="scope">
165
+            <div>{{scope.row.count}}{{scope.row.unit}}</div>
166
+          </template>
167
+        </el-table-column>
168
+
169
+        <el-table-column align="center" prop="total" label="生产日期">
170
+          <template slot-scope="scope">
171
+            <div>{{scope.row.p_date}}</div>
172
+          </template>
173
+        </el-table-column>
174
+
175
+
176
+        <el-table-column align="center" prop="total" label="有效日期">
177
+          <template slot-scope="scope">
178
+            <div>{{scope.row.e_date}}</div>
179
+          </template>
180
+        </el-table-column>
181
+
182
+
183
+        <el-table-column align="center" prop="total" label="盘存状态">
184
+          <template slot-scope="scope">
185
+            <div>{{scope.row.is_pc?'已盘存':'未盘存'}}</div>
186
+          </template>
187
+        </el-table-column>
188
+
189
+
190
+        <el-table-column align="center" prop="total" label="盘存日期">
191
+          <template slot-scope="scope">
192
+            <div>{{scope.row.pc_date}}</div>
193
+          </template>
194
+        </el-table-column>
195
+
196
+      </el-table>
197
+    </div>
198
+
199
+
200
+  </div>
201
+
202
+  <!-- </div> -->
203
+</template>
204
+
205
+
206
+<script>
207
+import BreadCrumb from '@/xt_pages/components/bread-crumb'
208
+import {GetDrugStock, GetGoodStock} from '../../api/new_stock/stock'
209
+const moment = require('moment')
210
+import { getDictionaryDataConfig } from "@/utils/data";
211
+import { uParseTime } from '@/utils/tools'
212
+import axios from 'axios'
213
+
214
+export default {
215
+  components: {
216
+    BreadCrumb
217
+  },
218
+  data() {
219
+    return {
220
+      keywords:"",
221
+      drugTypeList: [{ id: 0, name: "全部" }],
222
+      start_time: new Date(new Date().getFullYear(), new Date().getMonth(), 1).toLocaleDateString('en-CA'),
223
+      end_time: new Date(new Date().getFullYear(), new Date().getMonth() + 3, 0).toLocaleDateString('en-CA'),
224
+      tableData: [],
225
+      stock_type:"0",
226
+      change_type:"0",
227
+      selection:[],
228
+      isloading:false,
229
+      items: [
230
+
231
+        { id: 1, name: '已盘存' },
232
+        { id: 2, name: '未盘存' },
233
+      ],
234
+      changes: [
235
+        { id: 1, name: '已变更' },
236
+        { id: 2, name: '未变更' },
237
+      ],
238
+      crumbs: [
239
+        { path: false, name: '药品追溯' },
240
+        { path: false, name: '药品盘点' }
241
+      ],
242
+    }
243
+  },
244
+  methods: {
245
+    getCount(code){
246
+
247
+      let noNewLineStr = code.replace(/\n/g, "");
248
+      // 按逗号分割成数组
249
+      let resultArray = noNewLineStr.split(",");
250
+      var arr = []
251
+      for(let i = 0;i < resultArray.length;i++){
252
+        if(resultArray[i] != ""){
253
+
254
+          arr.push(resultArray[i])
255
+        }
256
+      }
257
+      return arr.length
258
+    },
259
+    searchAction(){
260
+
261
+
262
+    },
263
+    sigle_stock(row){
264
+      if(row.drug_code.length == 0){
265
+        this.$message.error("追溯码不能为空");
266
+        return
267
+      }
268
+      let ids  = row.id
269
+      var that = this;
270
+
271
+      let params = {
272
+        ids:ids,
273
+        admin_user_id:this.$store.getters.xt_user.user.id
274
+      };
275
+
276
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
277
+        if (response.data.state == 0) {
278
+          // that.$message.error(response.data.data.msg);
279
+          that.$confirm("请检查医保程序是否有打开", "提示", {
280
+            confirmButtonText: "确 定",
281
+            cancelButtonText: "取 消",
282
+            type: "warning",
283
+          }).then(() => {
284
+
285
+
286
+          })
287
+            .catch(() => {});
288
+          return false
289
+        } else {
290
+
291
+          //有打开则调用接口
292
+          axios.get('http://127.0.0.1:9532/api/good_pc_bg',{params:params}).then(function(response) {
293
+            if (response.data.state == 0) {
294
+              that.$message.error(response.data.data.msg);
295
+              return false
296
+            } else {
297
+              if(response.data.data.failed_code == -10){
298
+                that.$confirm(response.data.data.msg, '医保错误信息', {
299
+                  confirmButtonText: '确 定',
300
+                  type: 'warning'
301
+                }).then(() => {
302
+
303
+                }).catch(() => {
304
+                })
305
+              }else{
306
+                that.GetDrugStock()
307
+              }
308
+            }
309
+          }).catch(function(error) {
310
+          })
311
+        }
312
+      }).catch(function(error) {
313
+        that.$confirm("请检查医保程序是否有打开", "提示", {
314
+          confirmButtonText: "确 定",
315
+          cancelButtonText: "取 消",
316
+          type: "warning",
317
+        }).then(() => {
318
+        })
319
+          .catch(() => {});
320
+      })
321
+
322
+
323
+    },
324
+    selectCostInfo(selection, row) {
325
+      this.selection = selection
326
+    }, changeCostInfoTableData(val) {
327
+      this.selection = val
328
+    }, changeAllCostInfoTableData(selection) {
329
+      this.selection = selection
330
+    },
331
+    deleteStock(row){
332
+      let ids  = row.id
333
+      var that = this;
334
+      let params = {
335
+        ids:ids,
336
+        admin_user_id:this.$store.getters.xt_user.user.id
337
+      };
338
+
339
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
340
+        if (response.data.state == 0) {
341
+          // that.$message.error(response.data.data.msg);
342
+          that.$confirm("请检查医保程序是否有打开", "提示", {
343
+            confirmButtonText: "确 定",
344
+            cancelButtonText: "取 消",
345
+            type: "warning",
346
+          }).then(() => {
347
+
348
+
349
+          })
350
+            .catch(() => {});
351
+          return false
352
+        } else {
353
+          axios.get('http://127.0.0.1:9532/api/delete_good_pc_bg',{params:params}).then(function(response) {
354
+            if (response.data.state == 0) {
355
+
356
+              that.$message.error(response.data.data.msg);
357
+              return false
358
+            } else {
359
+              if(response.data.data.failed_code == -10){
360
+                that.$confirm(response.data.data.msg, '医保错误信息', {
361
+                  confirmButtonText: '确 定',
362
+                  type: 'warning'
363
+                }).then(() => {
364
+
365
+                }).catch(() => {
366
+                })
367
+              }else{
368
+                that.GetDrugStock()
369
+
370
+
371
+              }
372
+            }
373
+          }).catch(function(error) {
374
+          })
375
+        }
376
+      }).catch(function(error) {
377
+        that.$confirm("请检查医保程序是否有打开", "提示", {
378
+          confirmButtonText: "确 定",
379
+          cancelButtonText: "取 消",
380
+          type: "warning",
381
+        }).then(() => {
382
+        })
383
+          .catch(() => {});
384
+      })
385
+    },
386
+    exportdata(){
387
+      let list = []
388
+      // for (let i = 0; i < this.tableData.length; i++) {
389
+      //   let order = this.tableData[i]
390
+      //   let name = order.name
391
+      //   let item_name = order.item_name
392
+      //   let count = order.count
393
+      //   let price = order.price.toFixed(2)
394
+      //   let pay_sumamt = (order.price.toFixed(2) * order.count).toFixed(2)
395
+      //   let total = order.total.toFixed(2)
396
+      //
397
+      //   let obj = {
398
+      //     '患者姓名': name,
399
+      //     '项目名称': item_name,
400
+      //     '数量': count,
401
+      //     '单价': price,
402
+      //     '费用': pay_sumamt,
403
+      //     '费用总额': total
404
+      //   }
405
+      //   list.push(obj)
406
+      // }
407
+      import('@/vendor/Export2Excel').then(excel => {
408
+        const tHeader = ['患者姓名', '项目名称', '数量', '单价', '费用', '费用总额']
409
+        const filterVal = ['患者姓名', '项目名称', '数量', '单价', '费用', '费用总额']
410
+        const data = this.formatJson(filterVal, list)
411
+        excel.export_json_to_excel1({
412
+          header: tHeader,
413
+          data,
414
+          filename: '明细',
415
+          ref: this.$refs['table'].$el
416
+        })
417
+      })
418
+
419
+    },formatJson(filterVal, jsonData) {
420
+      return jsonData.map(v => filterVal.map(j => v[j]))
421
+    },
422
+    stock(){
423
+      let ids  = ""
424
+      for (var i = 0; i < this.selection.length; i++){
425
+        if (ids.length == 0){
426
+          ids = this.selection[i].id
427
+        }else{
428
+          ids = ids + "," + this.selection[i].id
429
+        }
430
+      }
431
+      var that = this;
432
+      let params = {
433
+        ids:ids,
434
+        admin_user_id:that.$store.getters.xt_user.user.id
435
+      };
436
+      var  that= this
437
+      axios.get('http://127.0.0.1:9532/test/net',{}).then(function(response) {
438
+        if (response.data.state == 0) {
439
+          // that.$message.error(response.data.data.msg);
440
+          that.$confirm("请检查医保程序是否有打开", "提示", {
441
+            confirmButtonText: "确 定",
442
+            cancelButtonText: "取 消",
443
+            type: "warning",
444
+          }).then(() => {
445
+
446
+
447
+          })
448
+            .catch(() => {});
449
+          return false
450
+        } else {
451
+          that.isloading = true
452
+          //有打开则调用接口
453
+          axios.get('http://127.0.0.1:9532/api/good_pc_bg',{params:params}).then(function(response) {
454
+            if (response.data.state == 0) {
455
+              that.isloading = false
456
+              that.$message.error(response.data.data.msg);
457
+              return false
458
+            } else {
459
+              that.isloading = false
460
+              if(response.data.data.failed_code == -10){
461
+                that.$confirm(response.data.data.msg, '医保错误信息', {
462
+                  confirmButtonText: '确 定',
463
+                  type: 'warning'
464
+                }).then(() => {
465
+
466
+                }).catch(() => {
467
+                })
468
+              }else{
469
+                that.GetDrugStock()
470
+              }
471
+            }
472
+          }).catch(function(error) {
473
+          })
474
+
475
+        }
476
+      }).catch(function(error) {
477
+        that.$confirm("请检查医保程序是否有打开", "提示", {
478
+          confirmButtonText: "确 定",
479
+          cancelButtonText: "取 消",
480
+          type: "warning",
481
+        }).then(() => {
482
+        })
483
+          .catch(() => {});
484
+      })
485
+
486
+    },
487
+    query(){
488
+      this.GetGoodStock()
489
+
490
+    },
491
+    change(){
492
+
493
+
494
+    },
495
+    changeStock(){
496
+
497
+
498
+    },
499
+    endTimeChange(){
500
+
501
+
502
+    }, getDrugType(id) {
503
+      var name = "";
504
+      for (let i = 0; i < this.drugTypeList.length; i++) {
505
+        if (this.drugTypeList[i].id == id) {
506
+          name = this.drugTypeList[i].name;
507
+        }
508
+      }
509
+
510
+      return name;
511
+    },  getTime(val) {
512
+      if(val == "" || val == undefined){
513
+        return ""
514
+      }else {
515
+        return uParseTime(val, '{y}-{m}-{d}')
516
+      }
517
+    },
518
+    startTimeChange(){
519
+
520
+
521
+    },GetGoodStock(){
522
+      this.tableData = []
523
+      let params = {
524
+        start_time: this.start_time,
525
+        end_time: this.end_time,
526
+        is_pc:this.stock_type,
527
+      }
528
+      GetGoodStock(params).then(response => {
529
+        if (response.data.state == 0) {
530
+          this.$message.error(response.data.msg)
531
+          return false
532
+        } else {
533
+          for(let i =0; i < response.data.data.info.length; i++){
534
+            let obj = {
535
+              id:response.data.data.info[i].id,
536
+              drug_name:response.data.data.info[i].GoodInfo.good_name,
537
+              drug_code:response.data.data.info[i].good_code,
538
+              spec: response.data.data.info[i].GoodInfo.specification_name,
539
+              code:response.data.data.info[i].GoodInfo.medical_insurance_number,
540
+              batch_number:response.data.data.info[i].number,
541
+              count: response.data.data.info[i].warehousing_count,
542
+              p_date:this.getTime(response.data.data.info[i].product_date),
543
+              e_date:this.getTime(response.data.data.info[i].expiry_date),
544
+              is_pc:response.data.data.info[i].is_pc,
545
+              pc_date:this.getTime(response.data.data.info[i].pc_date),
546
+              is_bg:response.data.data.info[i].is_bg,
547
+              unit: response.data.data.info[i].max_unit,
548
+            }
549
+            this.tableData.push(obj)
550
+          }
551
+        }
552
+      })
553
+    }
554
+  },
555
+  created() {
556
+    // var drugTypeList = getDictionaryDataConfig("system", "drug_type");
557
+    // this.drugTypeList.push(...drugTypeList);
558
+    this.GetGoodStock()
559
+  }
560
+}
561
+</script>
562
+
563
+<style lang="scss" scoped>
564
+
565
+</style>
566
+

+ 1 - 0
src/xt_pages/outpatientCharges/listPrint.vue ファイルの表示

181
                   med_chrgitm_type: this.getType(infos.med_chrgitm_type),
181
                   med_chrgitm_type: this.getType(infos.med_chrgitm_type),
182
                   price: infos.pric.toFixed(4),
182
                   price: infos.pric.toFixed(4),
183
                   count: infos.cnt,
183
                   count: infos.cnt,
184
+                  det: infos.det_item_fee_sumamt,
184
                   selfpay_prop:infos.selfpay_prop,
185
                   selfpay_prop:infos.selfpay_prop,
185
                 }
186
                 }
186
                 if (infos.advice && infos.advice.id == 0 && infos.project && infos.project.id > 0) {
187
                 if (infos.advice && infos.advice.id == 0 && infos.project && infos.project.id > 0) {

+ 6 - 5
src/xt_pages/outpatientCharges/listTemplate/batch_listPrint.vue ファイルの表示

1
 <template>
1
 <template>
2
   <div >
2
   <div >
3
-    
3
+
4
     <div class="position" >
4
     <div class="position" >
5
       <div style="text-align: right;flex: 1;">
5
       <div style="text-align: right;flex: 1;">
6
         <el-button type='primary' @click="printThisPage">打印</el-button>
6
         <el-button type='primary' @click="printThisPage">打印</el-button>
55
                 </td>
55
                 </td>
56
                 <td style="width:5%" >{{ite.unit}}</td>
56
                 <td style="width:5%" >{{ite.unit}}</td>
57
                 <td style="width:7%">
57
                 <td style="width:7%">
58
-                  <span v-if="ite.code!=undefined">{{(ite.price*1).toFixed(2)}}</span>
58
+                  <span v-if="ite.code!=undefined">{{(ite.price*1).toFixed(4)}}</span>
59
                 </td>
59
                 </td>
60
-                <td style="width:7%">{{(ite.price * ite.count).toFixed(2)}}</td>
60
+                <td style="width:7%">{{ite.det}}</td>
61
                 <td style="width:8%" v-if="org_id !=10653 ">
61
                 <td style="width:8%" v-if="org_id !=10653 ">
62
                   <div v-if="ite.code!=undefined">
62
                   <div v-if="ite.code!=undefined">
63
                     {{(ite.selfpay_prop)*100}}
63
                     {{(ite.selfpay_prop)*100}}
64
                     <span v-if="ite.selfpay_prop !=''">%</span>
64
                     <span v-if="ite.selfpay_prop !=''">%</span>
65
                   </div>
65
                   </div>
66
-                  
66
+
67
                 </td>
67
                 </td>
68
             </tr>
68
             </tr>
69
           </table>
69
           </table>
181
             med_chrgitm_type: this.getType(infos.med_chrgitm_type),
181
             med_chrgitm_type: this.getType(infos.med_chrgitm_type),
182
             price: infos.pric.toFixed(4),
182
             price: infos.pric.toFixed(4),
183
             count: infos.cnt,
183
             count: infos.cnt,
184
+            det: infos.det_item_fee_sumamt,
184
             selfpay_prop:infos.selfpay_prop,
185
             selfpay_prop:infos.selfpay_prop,
185
           }
186
           }
186
           if (infos.advice && infos.advice.id == 0 && infos.project && infos.project.id > 0) {
187
           if (infos.advice && infos.advice.id == 0 && infos.project && infos.project.id > 0) {
234
           newObj['is_total']= 1
235
           newObj['is_total']= 1
235
           this.list_arr[x].lists.push(newObj)
236
           this.list_arr[x].lists.push(newObj)
236
         }
237
         }
237
-        
238
+
238
       })
239
       })
239
     },
240
     },
240
     getType(med_chrgitm_type) {
241
     getType(med_chrgitm_type) {

+ 5 - 5
src/xt_pages/outpatientCharges/listTemplate/listPrintforu.vue ファイルの表示

23
             <div v-if="org_id !=10653">基金支付金额:{{ order.fund_pay_sumamt }}</div>
23
             <div v-if="org_id !=10653">基金支付金额:{{ order.fund_pay_sumamt }}</div>
24
             <div v-if="org_id !=10653">收费日期:{{getTimes(order.ctime)}}</div>
24
             <div v-if="org_id !=10653">收费日期:{{getTimes(order.ctime)}}</div>
25
         </div>
25
         </div>
26
-        
26
+
27
         <table class="listTable" style="text-align: center;">
27
         <table class="listTable" style="text-align: center;">
28
             <tr style="border-bottom: 1px solid black;">
28
             <tr style="border-bottom: 1px solid black;">
29
               <td style="width:12%" v-if="org_id==10489">开方日期</td>
29
               <td style="width:12%" v-if="org_id==10489">开方日期</td>
48
                 </td>
48
                 </td>
49
                 <td style="width:5%" >{{item.unit}}</td>
49
                 <td style="width:5%" >{{item.unit}}</td>
50
                 <td style="width:7%">
50
                 <td style="width:7%">
51
-                  <span v-if="item.code!=undefined">{{(item.price*1).toFixed(2)}}</span>
51
+                  <span v-if="item.code!=undefined">{{(item.price*1).toFixed(4)}}</span>
52
                 </td>
52
                 </td>
53
-                <td style="width:7%">{{(item.price * item.count).toFixed(2)}}</td>
53
+                <td style="width:7%">{{item.det}}</td>
54
                 <td style="width:8%" v-if="org_id !=10653 ">
54
                 <td style="width:8%" v-if="org_id !=10653 ">
55
                   <div v-if="item.code!=undefined">
55
                   <div v-if="item.code!=undefined">
56
                     {{(item.selfpay_prop)*100}}
56
                     {{(item.selfpay_prop)*100}}
57
                     <span v-if="item.selfpay_prop !=''">%</span>
57
                     <span v-if="item.selfpay_prop !=''">%</span>
58
                   </div>
58
                   </div>
59
-                  
59
+
60
                 </td>
60
                 </td>
61
             </tr>
61
             </tr>
62
         </table>
62
         </table>
174
     }
174
     }
175
   },
175
   },
176
   created(){
176
   created(){
177
-   
177
+
178
     this.org_id = this.$store.getters.xt_user.org_id
178
     this.org_id = this.$store.getters.xt_user.org_id
179
   },
179
   },
180
   watch:{
180
   watch:{