|
@@ -119,7 +119,7 @@ export class HushijiandanComponent implements OnInit {
|
119
|
119
|
});
|
120
|
120
|
this.mainService
|
121
|
121
|
.coopConfig("setOrders", postData)
|
122
|
|
- .subscribe((result) => { });
|
|
122
|
+ .subscribe((result) => {});
|
123
|
123
|
}, 500);
|
124
|
124
|
},
|
125
|
125
|
};
|
|
@@ -231,34 +231,42 @@ export class HushijiandanComponent implements OnInit {
|
231
|
231
|
jpDrugsWKOMsg: any = {}; //药品静配提示信息
|
232
|
232
|
|
233
|
233
|
// 获取报修区域(所属院区)
|
234
|
|
- areas: any = [];//区域(所属院区)列表
|
|
234
|
+ areas: any = []; //区域(所属院区)列表
|
235
|
235
|
getArea() {
|
236
|
236
|
this.areas = [];
|
237
|
|
- this.mainService.fetchListBx('area', { idx: 0, sum: 1000 }).subscribe((result: any) => {
|
238
|
|
- if (result.status == 200) {
|
239
|
|
- this.areas = result.list;
|
240
|
|
- if (this.areas.length) {
|
241
|
|
- this.bxForm.controls.hospital.setValue(this.areas[0].id);
|
242
|
|
- } else {
|
243
|
|
- this.bxForm.controls.hospital.setValue(null);
|
|
237
|
+ this.mainService
|
|
238
|
+ .fetchListBx("area", { idx: 0, sum: 1000 })
|
|
239
|
+ .subscribe((result: any) => {
|
|
240
|
+ if (result.status == 200) {
|
|
241
|
+ this.areas = result.list;
|
|
242
|
+ if (this.areas.length) {
|
|
243
|
+ this.bxForm.controls.hospital.setValue(this.areas[0].id);
|
|
244
|
+ } else {
|
|
245
|
+ this.bxForm.controls.hospital.setValue(null);
|
|
246
|
+ }
|
244
|
247
|
}
|
245
|
|
- }
|
246
|
|
- });
|
|
248
|
+ });
|
247
|
249
|
}
|
248
|
250
|
//根据区域(所属院区)获取地点(楼栋)
|
249
|
|
- places: any = [];//地点(楼栋)列表
|
|
251
|
+ places: any = []; //地点(楼栋)列表
|
250
|
252
|
getPlace(buildingId) {
|
251
|
253
|
this.places = [];
|
252
|
|
- this.mainService.fetchListBx('place', { idx: 0, sum: 1000, place: { area: { id: buildingId } } }).subscribe((result: any) => {
|
253
|
|
- if (result.status == 200) {
|
254
|
|
- this.places = result.list;
|
255
|
|
- if (this.places.length) {
|
256
|
|
- this.bxForm.controls.building.setValue(this.places[0].id);
|
257
|
|
- } else {
|
258
|
|
- this.bxForm.controls.building.setValue(null);
|
|
254
|
+ this.mainService
|
|
255
|
+ .fetchListBx("place", {
|
|
256
|
+ idx: 0,
|
|
257
|
+ sum: 1000,
|
|
258
|
+ place: { area: { id: buildingId } },
|
|
259
|
+ })
|
|
260
|
+ .subscribe((result: any) => {
|
|
261
|
+ if (result.status == 200) {
|
|
262
|
+ this.places = result.list;
|
|
263
|
+ if (this.places.length) {
|
|
264
|
+ this.bxForm.controls.building.setValue(this.places[0].id);
|
|
265
|
+ } else {
|
|
266
|
+ this.bxForm.controls.building.setValue(null);
|
|
267
|
+ }
|
259
|
268
|
}
|
260
|
|
- }
|
261
|
|
- });
|
|
269
|
+ });
|
262
|
270
|
}
|
263
|
271
|
|
264
|
272
|
btnLoading: boolean = false; //确认按钮loading状态
|
|
@@ -410,6 +418,17 @@ export class HushijiandanComponent implements OnInit {
|
410
|
418
|
closeModelHistory(e) {
|
411
|
419
|
this.historyPromptModalShow = JSON.parse(e).show;
|
412
|
420
|
}
|
|
421
|
+ // 查看药单历史记录
|
|
422
|
+ historyDPromptModalShow = false; //药单历史记录弹窗开关
|
|
423
|
+ packidD = ""; //查看历史记录携带
|
|
424
|
+ viewDrugsbagHistory(data) {
|
|
425
|
+ this.packidD = data.scode;
|
|
426
|
+ this.historyDPromptModalShow = true;
|
|
427
|
+ }
|
|
428
|
+ // 关闭药单历史记录弹窗
|
|
429
|
+ closeModelHistoryDrugsbag(e) {
|
|
430
|
+ this.historyDPromptModalShow = JSON.parse(e).show;
|
|
431
|
+ }
|
413
|
432
|
// 查看报修信息弹窗
|
414
|
433
|
bxPromptModalShow = false; //弹窗开关
|
415
|
434
|
bData = ""; //查看详情携带所有数据
|
|
@@ -689,11 +708,11 @@ export class HushijiandanComponent implements OnInit {
|
689
|
708
|
data,
|
690
|
709
|
data.focusPatient === 0
|
691
|
710
|
? "您将设置患者【" +
|
692
|
|
- data.patientName +
|
693
|
|
- "】为重点关注,后期此患者的相关检查将会自动建单通知支助中心"
|
|
711
|
+ data.patientName +
|
|
712
|
+ "】为重点关注,后期此患者的相关检查将会自动建单通知支助中心"
|
694
|
713
|
: "您将取消设置患者【" +
|
695
|
|
- data.patientName +
|
696
|
|
- "】为重点关注,后期此患者的相关检查将不会自动建单通知支助中心"
|
|
714
|
+ data.patientName +
|
|
715
|
+ "】为重点关注,后期此患者的相关检查将不会自动建单通知支助中心"
|
697
|
716
|
);
|
698
|
717
|
}
|
699
|
718
|
// 通用提示模态框
|
|
@@ -761,9 +780,9 @@ export class HushijiandanComponent implements OnInit {
|
761
|
780
|
// 确认
|
762
|
781
|
confirmBx() {
|
763
|
782
|
this.loading6 = true;
|
764
|
|
- this.mainService.wxbx({}).subscribe(result => {
|
|
783
|
+ this.mainService.wxbx({}).subscribe((result) => {
|
765
|
784
|
if ((result as any).status == 200) {
|
766
|
|
- let bxcode = (result as any).data;//生成微信报修号
|
|
785
|
+ let bxcode = (result as any).data; //生成微信报修号
|
767
|
786
|
let postData: any = {
|
768
|
787
|
verification: "true",
|
769
|
788
|
incident: {
|
|
@@ -773,31 +792,31 @@ export class HushijiandanComponent implements OnInit {
|
773
|
792
|
requester: { account: this.loginUser.account },
|
774
|
793
|
sourceType: "wechatUserIncident",
|
775
|
794
|
fileUrl: "url",
|
776
|
|
- bxcode
|
|
795
|
+ bxcode,
|
777
|
796
|
},
|
778
|
797
|
loginUser: {
|
779
|
798
|
account: this.loginUser.account,
|
780
|
|
- id: this.loginUser.id
|
781
|
|
- }
|
|
799
|
+ id: this.loginUser.id,
|
|
800
|
+ },
|
782
|
801
|
};
|
783
|
802
|
if (this.coopBx.category) {
|
784
|
|
- postData.incident.categoryId = this.coopBx.category.id
|
|
803
|
+ postData.incident.categoryId = this.coopBx.category.id;
|
785
|
804
|
}
|
786
|
|
- this.mainService.addWxIncident(postData).subscribe(res => {
|
|
805
|
+ this.mainService.addWxIncident(postData).subscribe((res) => {
|
787
|
806
|
this.loading6 = false;
|
788
|
807
|
this.bxModal = false;
|
789
|
808
|
if ((res as any).state == 200) {
|
790
|
809
|
this.showPromptModal("提交", true, "");
|
791
|
|
- this.checkTable('bxlb');
|
|
810
|
+ this.checkTable("bxlb");
|
792
|
811
|
} else {
|
793
|
812
|
this.showPromptModal("提交", false, (res as any).msg);
|
794
|
813
|
}
|
795
|
|
- })
|
|
814
|
+ });
|
796
|
815
|
} else {
|
797
|
816
|
this.loading6 = false;
|
798
|
817
|
this.showPromptModal("提交", false, "");
|
799
|
818
|
}
|
800
|
|
- })
|
|
819
|
+ });
|
801
|
820
|
}
|
802
|
821
|
|
803
|
822
|
// 获取当前登录人科室任务类型信息
|
|
@@ -994,7 +1013,7 @@ export class HushijiandanComponent implements OnInit {
|
994
|
1013
|
keyWord: e ? e : this.tabSearchCont,
|
995
|
1014
|
};
|
996
|
1015
|
// 查询父级科室患者
|
997
|
|
- postData['patient']['parentIdOnly'] = true;
|
|
1016
|
+ postData["patient"]["parentIdOnly"] = true;
|
998
|
1017
|
if (
|
999
|
1018
|
this.currentUser.typeValue == "checkRoom2" ||
|
1000
|
1019
|
this.currentUser.typeValue == "outpatientDept" ||
|
|
@@ -2341,17 +2360,20 @@ export class HushijiandanComponent implements OnInit {
|
2341
|
2360
|
this.checkedTableType = type;
|
2342
|
2361
|
if (type === "historySpecimen") {
|
2343
|
2362
|
this.getHistorySpecimen();
|
2344
|
|
- } else if (type === "bxlb") {
|
2345
|
|
- this.getBxlb();
|
2346
|
|
- } else if (type === "kjbx") {
|
2347
|
|
- this.getQuickBxlb();
|
2348
|
|
- // 获取报修的区域(所属院区)
|
2349
|
|
- this.getArea();
|
2350
|
|
- this.bxForm.controls.name.setValue(this.loginUser.name);
|
2351
|
|
- this.bxForm.controls.phone.setValue(this.loginUser.phone);
|
2352
|
|
- this.bxForm.controls.address.setValue(null);
|
2353
|
|
- this.bxForm.controls.content.setValue(null);
|
2354
|
|
- }
|
|
2363
|
+ } else if (type === "historyDrugsbag") {
|
|
2364
|
+ this.getHistoryDrugsbag();
|
|
2365
|
+ }
|
|
2366
|
+ // else if (type === "bxlb") {
|
|
2367
|
+ // this.getBxlb();
|
|
2368
|
+ // } else if (type === "kjbx") {
|
|
2369
|
+ // this.getQuickBxlb();
|
|
2370
|
+ // // 获取报修的区域(所属院区)
|
|
2371
|
+ // this.getArea();
|
|
2372
|
+ // this.bxForm.controls.name.setValue(this.loginUser.name);
|
|
2373
|
+ // this.bxForm.controls.phone.setValue(this.loginUser.phone);
|
|
2374
|
+ // this.bxForm.controls.address.setValue(null);
|
|
2375
|
+ // this.bxForm.controls.content.setValue(null);
|
|
2376
|
+ // }
|
2355
|
2377
|
}
|
2356
|
2378
|
//提交报修
|
2357
|
2379
|
bxLoading = false;
|
|
@@ -2362,9 +2384,9 @@ export class HushijiandanComponent implements OnInit {
|
2362
|
2384
|
}
|
2363
|
2385
|
if (this.bxForm.invalid) return;
|
2364
|
2386
|
this.bxLoading = true;
|
2365
|
|
- this.mainService.wxbx({}).subscribe(result => {
|
|
2387
|
+ this.mainService.wxbx({}).subscribe((result) => {
|
2366
|
2388
|
if ((result as any).status == 200) {
|
2367
|
|
- let bxcode = (result as any).data;//生成微信报修号
|
|
2389
|
+ let bxcode = (result as any).data; //生成微信报修号
|
2368
|
2390
|
let postData = {
|
2369
|
2391
|
verification: "true",
|
2370
|
2392
|
incident: {
|
|
@@ -2377,27 +2399,27 @@ export class HushijiandanComponent implements OnInit {
|
2377
|
2399
|
requester: { account: this.loginUser.account },
|
2378
|
2400
|
sourceType: "wechatUserIncident",
|
2379
|
2401
|
fileUrl: "url",
|
2380
|
|
- bxcode
|
|
2402
|
+ bxcode,
|
2381
|
2403
|
},
|
2382
|
2404
|
loginUser: {
|
2383
|
2405
|
account: this.loginUser.account,
|
2384
|
|
- id: this.loginUser.id
|
2385
|
|
- }
|
|
2406
|
+ id: this.loginUser.id,
|
|
2407
|
+ },
|
2386
|
2408
|
};
|
2387
|
|
- this.mainService.addWxIncident(postData).subscribe(res => {
|
|
2409
|
+ this.mainService.addWxIncident(postData).subscribe((res) => {
|
2388
|
2410
|
this.bxLoading = false;
|
2389
|
2411
|
if ((res as any).state == 200) {
|
2390
|
2412
|
this.showPromptModal("提交", true, "");
|
2391
|
|
- this.checkTable('bxlb');
|
|
2413
|
+ this.checkTable("bxlb");
|
2392
|
2414
|
} else {
|
2393
|
2415
|
this.showPromptModal("提交", false, (res as any).msg);
|
2394
|
2416
|
}
|
2395
|
|
- })
|
|
2417
|
+ });
|
2396
|
2418
|
} else {
|
2397
|
2419
|
this.bxLoading = false;
|
2398
|
2420
|
this.showPromptModal("提交", false, "");
|
2399
|
2421
|
}
|
2400
|
|
- })
|
|
2422
|
+ });
|
2401
|
2423
|
}
|
2402
|
2424
|
|
2403
|
2425
|
// 意见箱表格数据
|
|
@@ -2471,48 +2493,84 @@ export class HushijiandanComponent implements OnInit {
|
2471
|
2493
|
this.historySpecimenListLength = data.totalNum || 0;
|
2472
|
2494
|
});
|
2473
|
2495
|
}
|
2474
|
|
- // 报修列表查询表格数据
|
2475
|
|
- bxlbList: any = [];
|
2476
|
|
- bxlbPageIndex: number = 1; //表格当前页码
|
2477
|
|
- bxlbPageSize: number = 10; //表格每页展示条数
|
2478
|
|
- bxlbListLength: number = 10; //表格总数据量
|
2479
|
|
- bxlbCodeSearchInp: string = ""; //标本编码搜索
|
2480
|
|
- bxlbParentSearchInp: string = ""; //患者信息搜索
|
2481
|
|
- bxlbLoading = false;
|
2482
|
|
- getBxlb(idx?) {
|
|
2496
|
+ // 历史药单查询表格数据
|
|
2497
|
+ historyDrugsbagList: any = [];
|
|
2498
|
+ historyDrugsbagPageIndex: number = 1; //表格当前页码
|
|
2499
|
+ historyDrugsbagPageSize: number = 10; //表格每页展示条数
|
|
2500
|
+ historyDrugsbagListLength: number = 10; //表格总数据量
|
|
2501
|
+ historyDrugsbagCodeSearchInp: string = ""; //发药单号搜索
|
|
2502
|
+ // historyDrugsbagParentSearchInp: string = ""; //患者信息搜索
|
|
2503
|
+ hsDLoading = false;
|
|
2504
|
+ getHistoryDrugsbag(idx?) {
|
2483
|
2505
|
if (idx) {
|
2484
|
|
- this.bxlbPageIndex = 1;
|
|
2506
|
+ this.historyDrugsbagPageIndex = 1;
|
2485
|
2507
|
}
|
2486
|
2508
|
let current = JSON.parse(localStorage.getItem("user"));
|
2487
|
|
- this.bxlbLoading = true;
|
|
2509
|
+ let postData = {
|
|
2510
|
+ drugsBag: {
|
|
2511
|
+ target: {
|
|
2512
|
+ id: current.user.dept.id,
|
|
2513
|
+ },
|
|
2514
|
+ packid:
|
|
2515
|
+ this.historyDrugsbagCodeSearchInp === ""
|
|
2516
|
+ ? ''
|
|
2517
|
+ : this.historyDrugsbagCodeSearchInp,
|
|
2518
|
+ platform: 2,
|
|
2519
|
+ },
|
|
2520
|
+ idx: this.historyDrugsbagPageIndex - 1,
|
|
2521
|
+ sum: this.historyDrugsbagPageSize,
|
|
2522
|
+ };
|
|
2523
|
+ this.hsDLoading = true;
|
2488
|
2524
|
this.mainService
|
2489
|
|
- .listWxIncident({
|
2490
|
|
- "assignee": current.user.account,
|
2491
|
|
- "state": 0,
|
2492
|
|
- "idx": this.bxlbPageIndex - 1,
|
2493
|
|
- "sum": this.bxlbPageSize
|
2494
|
|
- })
|
2495
|
|
- .subscribe((data: any) => {
|
2496
|
|
- this.bxlbLoading = false;
|
2497
|
|
- this.bxlbList = data.data || [];
|
2498
|
|
- this.bxlbListLength = data.resultCount || 0;
|
|
2525
|
+ .getFetchDataList("api", "drugsBag", postData)
|
|
2526
|
+ .subscribe((data) => {
|
|
2527
|
+ this.hsDLoading = false;
|
|
2528
|
+ this.historyDrugsbagList = data.list || [];
|
|
2529
|
+ this.historyDrugsbagListLength = data.totalNum || 0;
|
2499
|
2530
|
});
|
2500
|
2531
|
}
|
|
2532
|
+ // 报修列表查询表格数据
|
|
2533
|
+ // bxlbList: any = [];
|
|
2534
|
+ // bxlbPageIndex: number = 1; //表格当前页码
|
|
2535
|
+ // bxlbPageSize: number = 10; //表格每页展示条数
|
|
2536
|
+ // bxlbListLength: number = 10; //表格总数据量
|
|
2537
|
+ // bxlbCodeSearchInp: string = ""; //标本编码搜索
|
|
2538
|
+ // bxlbParentSearchInp: string = ""; //患者信息搜索
|
|
2539
|
+ // bxlbLoading = false;
|
|
2540
|
+ // getBxlb(idx?) {
|
|
2541
|
+ // if (idx) {
|
|
2542
|
+ // this.bxlbPageIndex = 1;
|
|
2543
|
+ // }
|
|
2544
|
+ // let current = JSON.parse(localStorage.getItem("user"));
|
|
2545
|
+ // this.bxlbLoading = true;
|
|
2546
|
+ // this.mainService
|
|
2547
|
+ // .listWxIncident({
|
|
2548
|
+ // "assignee": current.user.account,
|
|
2549
|
+ // "state": 0,
|
|
2550
|
+ // "idx": this.bxlbPageIndex - 1,
|
|
2551
|
+ // "sum": this.bxlbPageSize
|
|
2552
|
+ // })
|
|
2553
|
+ // .subscribe((data: any) => {
|
|
2554
|
+ // this.bxlbLoading = false;
|
|
2555
|
+ // this.bxlbList = data.data || [];
|
|
2556
|
+ // this.bxlbListLength = data.resultCount || 0;
|
|
2557
|
+ // });
|
|
2558
|
+ // }
|
2501
|
2559
|
|
2502
|
2560
|
//快速报修列表
|
2503
|
|
- quickBxlbLoading = false;
|
2504
|
|
- quickBxlbList = [];
|
2505
|
|
- getQuickBxlb() {
|
2506
|
|
- this.quickBxlbLoading = true;
|
2507
|
|
- this.mainService
|
2508
|
|
- .fetchListBx("incidentCategoryContent", { idx: 0, sum: 10 })
|
2509
|
|
- .subscribe((data: any) => {
|
2510
|
|
- this.quickBxlbLoading = false;
|
2511
|
|
- if (data.status == 200) {
|
2512
|
|
- this.quickBxlbList = data.list || [];
|
2513
|
|
- }
|
2514
|
|
- });
|
2515
|
|
- }
|
|
2561
|
+ // quickBxlbLoading = false;
|
|
2562
|
+ // quickBxlbList = [];
|
|
2563
|
+ // getQuickBxlb() {
|
|
2564
|
+ // this.quickBxlbLoading = true;
|
|
2565
|
+ // this.mainService
|
|
2566
|
+ // .fetchListBx("incidentCategoryContent", { idx: 0, sum: 10 })
|
|
2567
|
+ // .subscribe((data: any) => {
|
|
2568
|
+ // this.quickBxlbLoading = false;
|
|
2569
|
+ // if (data.status == 200) {
|
|
2570
|
+ // this.quickBxlbList = data.list || [];
|
|
2571
|
+ // }
|
|
2572
|
+ // });
|
|
2573
|
+ // }
|
2516
|
2574
|
|
2517
|
2575
|
// 意见箱-查看模态框
|
2518
|
2576
|
adviceModal: boolean = false;
|
|
@@ -2640,7 +2698,7 @@ export class HushijiandanComponent implements OnInit {
|
2640
|
2698
|
if (
|
2641
|
2699
|
that.adviceList.length == 1 &&
|
2642
|
2700
|
that.advicePageIndex ==
|
2643
|
|
- Math.ceil(that.adviceListLength / that.advicePageSize)
|
|
2701
|
+ Math.ceil(that.adviceListLength / that.advicePageSize)
|
2644
|
2702
|
) {
|
2645
|
2703
|
that.adviceListLength--;
|
2646
|
2704
|
that.advicePageIndex = Math.ceil(
|