maotao 7 mesi fa
parent
commit
39d9d9aefc

+ 1 - 1
package.json

@@ -5,7 +5,7 @@
5 5
     "start": "ng serve --proxy-config proxy.conf.json --port 4210 --disable-host-check --public-host=dashitech.com --host 0.0.0.0",
6 6
     "build": "ng build --prod",
7 7
     "start:17": "set NODE_OPTIONS=--openssl-legacy-provider && ng serve --proxy-config proxy.conf.json --port 4210 --disable-host-check --public-host=dashitech.com --host 0.0.0.0",
8
-    "build:17": "set NODE_OPTIONS=--openssl-legacy-provider && npm run build",
8
+    "build:17": "set NODE_OPTIONS=--openssl-legacy-provider --max_old_space_size=4096 && npm run build",
9 9
     "development": "node ./upload/development.js",
10 10
     "production": "node ./upload/production.js",
11 11
     "test": "ng test",

+ 8 - 0
src/app/app-routing.module.ts

@@ -13,6 +13,8 @@ import { PharmacyGuard } from './guard/pharmacy.guard';
13 13
 import { SpecimenView2Guard } from './guard/SpecimenView2Guard.guard';
14 14
 // 标本间端权限
15 15
 import { SpecimenRoomViewGuard } from './guard/SpecimenRoomViewGuard.guard';
16
+// 病理科权限
17
+import { PathologyGuard } from './guard/Pathology.guard';
16 18
 // 全局业务查看权限
17 19
 import { DisinfectionSupplyGuard } from './guard/DisinfectionSupplyGuard.guard';
18 20
 // 配置中心查看权限
@@ -77,6 +79,12 @@ const routes: Routes = [
77 79
 	  loadChildren: () => import('./views/specimen-room-view/specimen-room-view.module').then(m => m.SpecimenRoomViewModule),
78 80
 	  canActivate: [SpecimenRoomViewGuard]
79 81
 	},
82
+	// 标本间端
83
+	{
84
+	  path: 'pathology',
85
+	  loadChildren: () => import('./views/pathology/pathology.module').then(m => m.PathologyModule),
86
+	  canActivate: [PathologyGuard]
87
+	},
80 88
   // 全局业务查看
81 89
   {
82 90
     path: 'disinfectionSupply',

+ 22 - 0
src/app/guard/Pathology.guard.ts

@@ -0,0 +1,22 @@
1
+import { Injectable } from '@angular/core';
2
+import { CanActivate, Router } from '@angular/router';
3
+
4
+@Injectable({
5
+  providedIn: 'root'
6
+})
7
+export class PathologyGuard implements CanActivate {
8
+  constructor(public router: Router) { }
9
+
10
+  canActivate(): boolean {
11
+    const menus = JSON.parse(localStorage.getItem('menu'));
12
+    let can = false;
13
+    if (menus) {
14
+      can = menus.some(e => e.link == 'pathology');
15
+    }
16
+    if (!can) {
17
+      this.router.navigate(['login']);
18
+      return false
19
+    }
20
+    return true;
21
+  }
22
+}

+ 7 - 0
src/app/services/main.service.ts

@@ -872,4 +872,11 @@ export class MainService {
872 872
 	    headers: this.headers,
873 873
 	  });
874 874
 	}
875
+	
876
+	// 工号搜索
877
+	jobSearch(data) {
878
+	  return this.http.post(host.host + `/data/isRepeat`, data, {
879
+	    headers: this.headers,
880
+	  });
881
+	}
875 882
 }

+ 19 - 6
src/app/share/pathology-add/pathology-add.component.html

@@ -55,6 +55,19 @@
55 55
 					</nz-form-item>
56 56
 					
57 57
 					<nz-form-item class="form-item">
58
+						<nz-form-label nzRequired nzFor="project" [nzSm]="5" [nzXs]="24">检验项目</nz-form-label>
59
+						<nz-form-control nzErrorTip="请选择检验项目!" [nzSm]="19" [nzXs]="24">
60
+							<nz-input-group>
61
+								<nz-select nzSearch nzShowSearch nzMode="multiple" nzPlaceHolder="请选择检验项目" formControlName="project">
62
+									<ng-container *ngFor="let option of projectData">
63
+										<nz-option [nzLabel]="option.name" [nzValue]="option.id"></nz-option>
64
+									</ng-container>
65
+								</nz-select>
66
+							</nz-input-group>
67
+						</nz-form-control>
68
+					</nz-form-item>
69
+					
70
+					<nz-form-item class="form-item">
58 71
 						<nz-form-label nzRequired nzFor="specimenGenre" [nzSm]="5" [nzXs]="24">标本类型</nz-form-label>
59 72
 						<nz-form-control nzErrorTip="请选择标本类型!" [nzSm]="19" [nzXs]="24">
60 73
 							<nz-input-group>
@@ -73,7 +86,7 @@
73 86
 					<nz-form-item class="form-item">
74 87
 						<nz-form-label nzRequired nzFor="specimenNum" [nzSm]="5" [nzXs]="24">标本件数</nz-form-label>
75 88
 						<nz-form-control nzErrorTip="请输入标本件数!" [nzSm]="19" [nzXs]="24">
76
-							<input nz-input formControlName="specimenNum"  placeholder="请输入标本件数" nzSize="default" />
89
+							<input nz-input formControlName="specimenNum" disabled placeholder="请输入标本件数" nzSize="default" />
77 90
 						</nz-form-control>
78 91
 					</nz-form-item>
79 92
 					
@@ -101,8 +114,8 @@
101 114
 							<div class="specimen-name" (click)="specimenEdit($event,item,index)">
102 115
 							{{item.partSource?item.partSource.name:''}} <span *ngIf="item.system">-</span>
103 116
 							{{item.system?item.system.name:''}} <span *ngIf="item.organ">-</span>
104
-							{{item.organ?item.organ.name:''}} <span *ngIf="item.sample">-</span>
105
-							{{item.sample?item.sample.name:''}}
117
+							{{item.organ?item.organ.name:''}} <span>-</span>
118
+							{{item.sample?item.sample.name:item.specimenName}}
106 119
 							</div>
107 120
 							<span class="icon_transport transport-lajitong specimen-icon" (click)="specimenDel($event,item,index)"></span>
108 121
 						</div>
@@ -175,7 +188,7 @@
175 188
 				</nz-form-item>
176 189
 				
177 190
 				<nz-form-item class="form-item">
178
-					<nz-form-label nzRequired nzFor="remark" [nzSm]="3" [nzXs]="24">备注</nz-form-label>
191
+					<nz-form-label nzFor="remark" [nzSm]="3" [nzXs]="24">备注</nz-form-label>
179 192
 					<nz-form-control nzErrorTip="请输入备注" [nzSm]="21" [nzXs]="24">
180 193
 						<textarea rows="3" nz-input formControlName="remark" placeholder="请输入备注"></textarea>
181 194
 					</nz-form-control>
@@ -266,10 +279,10 @@
266 279
 					<div style="width:70%;padding:1px;">{{printData.specimenNum}}</div>
267 280
 				</div>
268 281
 			</div>
269
-			<div style="height: 10px;"></div>
282
+			<div style="height: 10px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1"></div>
270 283
 			<div style="font-size: 12px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>0">
271 284
 				<div *ngFor="let data of printData.specimenList; let index=index;">
272
-					<div style="height: 30px;"></div>
285
+					<div style="height: 30px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1"></div>
273 286
 					<div style="border: 1px solid #AAAAAA;border-radius: 5px;">
274 287
 						<img style="width: 100%;height: 90px;border-radius: 5px;" [src]="data.barCode" alt="">
275 288
 						<div class="monad-sign" style="border-bottom: 1px solid #AAAAAA;padding-left:1px;">

+ 29 - 5
src/app/share/pathology-add/pathology-add.component.less

@@ -1,3 +1,24 @@
1
+/* 修改垂直滚动条 */
2
+::-webkit-scrollbar {
3
+	width: 4px; /* 修改宽度 */
4
+	border-radius: 2px;
5
+}
6
+ 
7
+/* 修改滚动条轨道背景色 */
8
+::-webkit-scrollbar-track {
9
+	background-color: #f1f1f1;
10
+}
11
+ 
12
+/* 修改滚动条滑块颜色 */
13
+::-webkit-scrollbar-thumb {
14
+	background-color: #888;
15
+}
16
+ 
17
+/* 修改滚动条滑块悬停时的颜色 */
18
+::-webkit-scrollbar-thumb:hover {
19
+	background-color: #555;
20
+}
21
+
1 22
 .pathology-box {
2 23
   position: fixed;
3 24
 	left: 0;
@@ -33,12 +54,12 @@
33 54
 			background: #f9fafb;
34 55
 			border: 1px solid #e5e9ed;
35 56
 			border-radius: 5px;
36
-			overflow: hidden;
57
+			// overflow: hidden;
37 58
 			margin-top: 12px;
38
-			height: auto;
39
-			// padding: 19px 14px 10px 0;
40
-			max-height: 460px;
41
-			overflow-y: auto;
59
+			// height: auto;
60
+			// // padding: 19px 14px 10px 0;
61
+			// max-height: 460px;
62
+			// overflow-y: auto;
42 63
 			.addForm{
43 64
 				display: flex;
44 65
 				.width-100{
@@ -51,8 +72,11 @@
51 72
 				.ant-select{
52 73
 					width: 100%;
53 74
 				}
75
+				
54 76
 				.content-item{
55 77
 					flex: 1;
78
+					height: 460px;
79
+					overflow-y: auto;
56 80
 					padding: 0 15px;
57 81
 					.form-title-box{
58 82
 						display: flex;

+ 104 - 65
src/app/share/pathology-add/pathology-add.component.ts

@@ -38,6 +38,7 @@ export class PathologyAddComponent implements OnInit {
38 38
 	validateSpecimenForm: FormGroup; //选择标本表单
39 39
 	validatePrintForm: FormGroup;
40 40
 	specimenData:any=[]; //标本类型
41
+	projectData:any=[]; //检验项目
41 42
 	isDeptLoading:boolean = false;
42 43
 	specimenModal:boolean = false; //选择标本状态
43 44
 	isSpinning:boolean = false; //页面加载状态
@@ -59,6 +60,8 @@ export class PathologyAddComponent implements OnInit {
59 60
 	type:any = '未打印';
60 61
 	notModal:boolean = false;
61 62
 	hosId:any;
63
+	startDate: string; //离体开始
64
+	
62 65
   ngOnInit() {
63 66
 		this.hosId = this.tool.getCurrentHospital().id;
64 67
 		this.initForm()
@@ -71,6 +74,7 @@ export class PathologyAddComponent implements OnInit {
71 74
 		  intraoperativeRapidity: [1, [Validators.required]],
72 75
 			specimenGenre: [null, [Validators.required]],
73 76
 			intraoperativeFindings: [null, [Validators.required]],
77
+			project: [null, [Validators.required]],
74 78
 			surgicalPlan: [null, [Validators.required]],
75 79
 			specimenNum: [null,[Validators.required]],
76 80
 			takePart: [null, [Validators.required]]
@@ -99,6 +103,7 @@ export class PathologyAddComponent implements OnInit {
99 103
 				if(this.detailsData.intraoperativeFindings){
100 104
 					this.validateForm.controls.intraoperativeFindings.setValue(this.detailsData.intraoperativeFindings);
101 105
 				}
106
+				this.getProDicData()
102 107
 				this.getDicData()
103 108
 				this.getSampleData()
104 109
 				this.getSourceData()
@@ -122,6 +127,20 @@ export class PathologyAddComponent implements OnInit {
122 127
 		});
123 128
 	}
124 129
 	
130
+	// 获取检验项目
131
+	getProDicData(){
132
+		this.mainService.getDictionary("list", "pathology_inspect_type").subscribe((res) => {
133
+			this.projectData = res
134
+			let arr = []
135
+			if(this.detailsData.pathologyInspectDTOS){
136
+				for(let i of this.detailsData.pathologyInspectDTOS){
137
+					arr.push(i.inspectProject.id)
138
+				}
139
+				this.validateForm.controls.project.setValue(arr);
140
+			}
141
+		});
142
+	}
143
+	
125 144
 	// 获取标本-位置来源
126 145
 	getSourceData(){
127 146
 		this.mainService.getDictionary("list", "pathology_position").subscribe((res) => {
@@ -201,7 +220,7 @@ export class PathologyAddComponent implements OnInit {
201 220
 				if(type=='edit'){
202 221
 					if(item.sample){
203 222
 						this.validateSpecimenForm = this.fb.group({
204
-						  remark: [null, [Validators.required]]
223
+						  remark: [null, []]
205 224
 						});
206 225
 						setTimeout(_=>{
207 226
 							let index4 = this.specimenNameList.findIndex(i=>i.id==item.sample.id)
@@ -211,7 +230,7 @@ export class PathologyAddComponent implements OnInit {
211 230
 						},100)
212 231
 					}else{
213 232
 						this.validateSpecimenForm = this.fb.group({
214
-						  remark: [null, [Validators.required]],
233
+						  remark: [null, []],
215 234
 							specimenName: [null, [Validators.required]]
216 235
 						});
217 236
 						this.specimenNameIndex = this.specimenNameList.length-1
@@ -275,7 +294,7 @@ export class PathologyAddComponent implements OnInit {
275 294
 	// 选择标本
276 295
 	openSpecimen(){
277 296
 		this.validateSpecimenForm = this.fb.group({
278
-		  remark: [null, [Validators.required]]
297
+		  remark: [null, []]
279 298
 		});
280 299
 		this.specimenDetailId = null;
281 300
 		this.placeIndex = null;
@@ -290,6 +309,7 @@ export class PathologyAddComponent implements OnInit {
290 309
 		this.systemList=[]; //系统数据
291 310
 		this.apparatusList=[]; //器官数据
292 311
 		this.specimenNameList=[]; //标本名称数据
312
+		this.specimenNameName = null;
293 313
 		this.getSourceData()
294 314
 		this.getSysData()
295 315
 		this.specimenModal = true
@@ -310,6 +330,14 @@ export class PathologyAddComponent implements OnInit {
310 330
 		this.apparatusList = [];
311 331
 		this.apparatusId = null;
312 332
 		this.apparatusIndex = null;
333
+		
334
+		this.specimenNameList = [];
335
+		this.specimenNameId = null;
336
+		this.specimenNameIndex = null;
337
+		this.specimenNameName = null;
338
+		if(this.validateSpecimenForm.value.specimenName){
339
+			this.validateSpecimenForm.controls.specimenName.setValue('')
340
+		}
313 341
 		this.getApparatusData(item.id,{},'select')
314 342
 	}
315 343
 	
@@ -321,6 +349,10 @@ export class PathologyAddComponent implements OnInit {
321 349
 		this.specimenNameList = [];
322 350
 		this.specimenNameId = null;
323 351
 		this.specimenNameIndex = null;
352
+		this.specimenNameName = null;
353
+		if(this.validateSpecimenForm.value.specimenName){
354
+			this.validateSpecimenForm.controls.specimenName.setValue('')
355
+		}
324 356
 		this.getSpNameData(item.id,{},'select')
325 357
 	}
326 358
 	
@@ -332,14 +364,14 @@ export class PathologyAddComponent implements OnInit {
332 364
 		let remark = this.validateSpecimenForm.value.remark
333 365
 		if(item.id == 'qita'){
334 366
 			this.validateSpecimenForm = this.fb.group({
335
-			  remark: [remark?remark:null, [Validators.required]],
367
+			  remark: [remark?remark:null, []],
336 368
 				specimenName: [null, [Validators.required]]
337 369
 			});
338 370
 			this.specimenNameId = 'null'
339 371
 			this.specimenNameName = 'qita'
340 372
 		}else{
341 373
 			this.validateSpecimenForm = this.fb.group({
342
-			  remark: [remark?remark:null, [Validators.required]],
374
+			  remark: [remark?remark:null, []],
343 375
 			});
344 376
 			this.specimenNameId = item.id
345 377
 			this.specimenNameName = item.name
@@ -429,6 +461,7 @@ export class PathologyAddComponent implements OnInit {
429 461
 		  .getFetchDataList("data", "pathologySpecimen", data)
430 462
 		  .subscribe((res) => {
431 463
 		    this.specimenList = res.list
464
+				this.validateForm.controls.specimenNum.setValue(this.specimenList.length);
432 465
 		  });
433 466
 	}
434 467
 	
@@ -441,10 +474,8 @@ export class PathologyAddComponent implements OnInit {
441 474
 	}
442 475
 	
443 476
 	// 日期选择
444
-	startDate: string; //时间开始
445 477
 	formChangeDate(result?): void {
446
-	  this.startDate = format(result[0], 'yyyy-MM-dd HH:mm:ss');
447
-		
478
+	  this.startDate = format(result, 'yyyy-MM-dd HH:mm:ss');
448 479
 	}
449 480
 	
450 481
 	//未打印提交
@@ -456,16 +487,17 @@ export class PathologyAddComponent implements OnInit {
456 487
 		  this.validatePrintForm.controls[i].updateValueAndValidity();
457 488
 		}
458 489
 		if (this.validatePrintForm.invalid) return;
459
-		
490
+		let ids = this.validateForm.value.project.join(',')
460 491
 		let data: any = {
461 492
 			pathologyForm:{
462 493
 				...this.validateForm.value,
463 494
 				...this.detailsData,
464
-				inVitroTime:this.validatePrintForm.value.inVitroTime,
495
+				inVitroTime:this.startDate,
465 496
 				surgeryId: this.surgeryId || "",
466 497
 				patientId: this.patientId || "",
467 498
 				hosId: this.hosId || "" ,
468 499
 				handoverUserId:this.handoverUserId,
500
+				pathologyInspectIds:ids,
469 501
 				specimenType:{
470 502
 					id:this.validateForm.value.specimenGenre
471 503
 				}
@@ -479,28 +511,31 @@ export class PathologyAddComponent implements OnInit {
479 511
 		this.mainService
480 512
 		  .pathologyPrint(data)
481 513
 		  .subscribe((res:any) => {
482
-				
483
-				let arr = res.data;
484
-		    if(arr.applyBarCode){
485
-		    	arr.applyBarCode = this.sanitizer.bypassSecurityTrustResourceUrl(arr.applyBarCode)
486
-		    }
487
-		    for(let i of arr.specimenList){
488
-		    	i.barCode = this.sanitizer.bypassSecurityTrustResourceUrl(i.barCode)
489
-		    }
490
-		    that.printLoading = false;
491
-		    that.printData = arr;
492
-		    setTimeout(() => {
493
-		      const printContent = document.getElementById("report");
494
-		      const WindowPrt = window.open("", "", "width=100,height=1000");
495
-		    	WindowPrt.document.body.innerHTML = printContent.innerHTML;
496
-		    	setTimeout(_=>{
497
-		    		WindowPrt.document.close();
498
-		    		WindowPrt.focus();
499
-		    		WindowPrt.print();
500
-		    		WindowPrt.close();
501
-		    		that.hideModal();
502
-		    	},500)
503
-		    }, 500);
514
+				if(res.status==200){
515
+					let arr = res.data;
516
+					if(arr.applyBarCode){
517
+						arr.applyBarCode = this.sanitizer.bypassSecurityTrustResourceUrl(arr.applyBarCode)
518
+					}
519
+					for(let i of arr.specimenList){
520
+						i.barCode = this.sanitizer.bypassSecurityTrustResourceUrl(i.barCode)
521
+					}
522
+					that.printLoading = false;
523
+					that.printData = arr;
524
+					setTimeout(() => {
525
+					  const printContent = document.getElementById("report");
526
+					  const WindowPrt = window.open("", "", "width=100,height=1000");
527
+						WindowPrt.document.body.innerHTML = printContent.innerHTML;
528
+						setTimeout(_=>{
529
+							WindowPrt.document.close();
530
+							WindowPrt.focus();
531
+							WindowPrt.print();
532
+							WindowPrt.close();
533
+							that.hideModal();
534
+						},500)
535
+					}, 500);
536
+				}else{
537
+					this.message.error(res.msg)
538
+				}
504 539
 		  });
505 540
 	}
506 541
 	
@@ -511,23 +546,19 @@ export class PathologyAddComponent implements OnInit {
511 546
 			this.validatePrintForm.controls.name.setValue('');
512 547
 			return
513 548
 		}
514
-		let data = {
515
-		  idx: 0,
516
-		  sum: 9999,
517
-		  user: {
518
-		    account: e || "",
519
-		    hospital: { id: this.hosId || "" }
520
-		  },
549
+		let query = {
550
+		  account: e
521 551
 		};
522 552
 		this.mainService
523
-		  .getFetchDataList("data", "user", data)
524
-		  .subscribe((data) => {
525
-				if(data.list.length>0){
526
-					this.validatePrintForm.controls.name.setValue(data.list[0].name);
527
-					this.handoverUserId = data.list[0].id
553
+		  .jobSearch(query)
554
+		  .subscribe((data:any) => {
555
+				if(data.status==200){
556
+					this.validatePrintForm.controls.name.setValue(data.userName);
557
+					this.handoverUserId = data.userId
528 558
 				}else{
529 559
 					this.validatePrintForm.controls.name.setValue('');
530
-					this.handoverUserId =null
560
+					this.handoverUserId = null
561
+					// this.message.error(data.data)
531 562
 				}
532 563
 		  });
533 564
 	}
@@ -540,6 +571,10 @@ export class PathologyAddComponent implements OnInit {
540 571
 		  that.validateForm.controls[i].updateValueAndValidity();
541 572
 		}
542 573
 		if (that.validateForm.invalid) return;
574
+		if(this.specimenList.length==0){
575
+			this.message.error('标本不能为空')
576
+			return
577
+		}
543 578
 		if(this.detailsData.status.name=='未打印'){
544 579
 			this.notModal = true
545 580
 			this.validatePrintForm = this.fb.group({
@@ -573,27 +608,31 @@ export class PathologyAddComponent implements OnInit {
573 608
 		that.mainService
574 609
 		  .pathologyPrint(data)
575 610
 		  .subscribe((res:any) => {
576
-				let arr = res.data;
577
-				if(arr.applyBarCode){
578
-					arr.applyBarCode = this.sanitizer.bypassSecurityTrustResourceUrl(arr.applyBarCode)
579
-				}
580
-				for(let i of arr.specimenList){
581
-					i.barCode = this.sanitizer.bypassSecurityTrustResourceUrl(i.barCode)
611
+				if(res.status==200){
612
+					let arr = res.data;
613
+					if(arr.applyBarCode){
614
+						arr.applyBarCode = this.sanitizer.bypassSecurityTrustResourceUrl(arr.applyBarCode)
615
+					}
616
+					for(let i of arr.specimenList){
617
+						i.barCode = this.sanitizer.bypassSecurityTrustResourceUrl(i.barCode)
618
+					}
619
+					that.btnLoading = false;
620
+					that.printData = arr;
621
+					setTimeout(() => {
622
+					  const printContent = document.getElementById("report");
623
+					  const WindowPrt = window.open("", "", "width=100,height=1000");
624
+						WindowPrt.document.body.innerHTML = printContent.innerHTML;
625
+						setTimeout(_=>{
626
+							WindowPrt.document.close();
627
+							WindowPrt.focus();
628
+							WindowPrt.print();
629
+							WindowPrt.close();
630
+							that.hideModal();
631
+						},500)
632
+					}, 500);
633
+				}else{
634
+					this.message.error(res.msg)
582 635
 				}
583
-				that.btnLoading = false;
584
-				that.printData = arr;
585
-		    setTimeout(() => {
586
-		      const printContent = document.getElementById("report");
587
-		      const WindowPrt = window.open("", "", "width=100,height=1000");
588
-					WindowPrt.document.body.innerHTML = printContent.innerHTML;
589
-					setTimeout(_=>{
590
-						WindowPrt.document.close();
591
-						WindowPrt.focus();
592
-						WindowPrt.print();
593
-						WindowPrt.close();
594
-						that.hideModal();
595
-					},500)
596
-		    }, 500);
597 636
 		  });
598 637
 	}
599 638
 	

+ 97 - 96
src/app/share/pathology-detail/pathology-detail.component.html

@@ -1,107 +1,108 @@
1 1
 <div class="pathology-box display_flex align-items_center justify-content_flex-center">
2
-	<div class="pathology-content" *ngIf="!isSpinning">
3
-		<div class="title">查看详情
4
-		<i class="icon_transport transport-guanbi" (click)="closeDetailMoadl()"></i></div>
5
-		<div class="content">
6
-			<div class="content-item boder-right">
7
-				<div class="form-title-box">
8
-					<div class="form-title width-150"><span class="font-weight-500">是否术中快速:</span>{{detailsData.intraoperativeRapidity==1?'是':'否'}}</div>
9
-					<div class="form-title width-200"><span class="font-weight-500">申请单编号:</span>{{detailsData.applyCode}}</div>
10
-					<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status.name}}</div>
11
-					<div class="form-title"><span class="font-weight-500">科室名称:</span>{{detailsData.patientDTO.department.dept}}</div>
12
-				</div>
13
-				<div class="form-title-box">
14
-					<div class="form-title width-150"><span class="font-weight-500">住院号:</span>{{detailsData.patientDTO.patientCode}}</div>
15
-					<div class="form-title width-200"><span class="font-weight-500">患者信息:</span>{{detailsData.patientDTO.patientName}} ({{detailsData.patientDTO.bedNum}}床)</div>
16
-					<div class="form-title"><span class="font-weight-500">年龄:</span>{{detailsData.patientDTO.age||'-'}}岁</div>
17
-				</div>
18
-
19
-				<div class="form-list">
20
-					<div class="form-title font-weight-500">诊断:</div>
21
-					<div class="indent">
22
-						{{detailsData.diagnose||'无'}}
2
+		<div class="pathology-content" *ngIf="!isSpinning">
3
+			<div class="title">查看详情
4
+			<i class="icon_transport transport-guanbi" (click)="closeDetailMoadl()"></i></div>
5
+			<div class="content">
6
+				<div class="content-item boder-right">
7
+					<div class="form-title-box">
8
+						<div class="form-title"><span class="font-weight-500">是否术中快速:</span>{{detailsData.intraoperativeRapidity==1?'是':'否'}}</div>
9
+						<div class="form-title"><span class="font-weight-500">申请单编号:</span>{{detailsData.applyCode}}</div>
10
+						<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status.name}}</div>
11
+						<div class="form-title"><span class="font-weight-500">科室名称:</span>{{detailsData.patientDTO.department.dept}}</div>
12
+					</div>
13
+					<div class="form-title-box">
14
+						<div class="form-title"><span class="font-weight-500">住院号:</span>{{detailsData.patientDTO.patientCode}}</div>
15
+						<div class="form-title"><span class="font-weight-500">患者信息:</span>{{detailsData.patientDTO.patientName}} ({{detailsData.patientDTO.bedNum}}床)</div>
16
+						<div class="form-title"><span class="font-weight-500">年龄:</span>{{detailsData.patientDTO.age||'-'}}岁</div>
17
+					</div>
18
+					
19
+					<div class="form-title-box">
20
+						<div class="form-title"><span class="font-weight-500">检验项目:</span>{{project||'无'}}</div>
21
+					</div>
22
+					
23
+					<div class="form-list">
24
+						<div class="form-title font-weight-500">诊断:</div>
25
+						<div class="indent">
26
+							{{detailsData.diagnose||'无'}}
27
+						</div>
28
+					</div>
29
+					
30
+					<div class="form-list">
31
+						<div class="form-title font-weight-500">病理摘要:</div>
32
+						<div class="indent">{{detailsData.medicalRecords||'无'}}</div>
33
+					</div>
34
+					<div class="form-list">
35
+						<div class="form-title font-weight-500">手术方案:</div>
36
+						<div class="indent">{{detailsData.surgicalPlan||'无'}}</div>
37
+					</div>
38
+					<div class="form-list">
39
+						<div class="form-title font-weight-500">术中所见:</div>
40
+						<div class="indent">{{detailsData.intraoperativeFindings||'无'}}</div>
23 41
 					</div>
24
-				</div>
25
-				
26
-				<div class="form-list">
27
-					<div class="form-title font-weight-500">病理摘要:</div>
28
-					<div class="indent">{{detailsData.medicalRecords||'无'}}</div>
29
-				</div>
30
-				<div class="form-list">
31
-					<div class="form-title font-weight-500">手术方案:</div>
32
-					<div class="indent">{{detailsData.surgicalPlan||'无'}}</div>
33
-				</div>
34
-				<div class="form-list">
35
-					<div class="form-title font-weight-500">术中所见:</div>
36
-					<div class="indent">{{detailsData.intraoperativeFindings||'无'}}</div>
37
-				</div>
38 42
 
39
-				<div class="form-title-box">
40
-					<div class="form-title width-150"><span class="font-weight-500">标本类型:</span>{{detailsData.specimenType.name||'无'}}</div>
41
-					<div class="form-title width-200"><span class="font-weight-500">标本件数:</span>{{detailsData.specimenNum||'无'}}</div>
42
-					<div class="form-title"><span class="font-weight-500">采取部位:</span>{{detailsData.takePart||'无'}}</div>
43
-					<div class="form-title"><span class="font-weight-500">送检医生:</span>{{detailsData.surgeryDoctorDTO?detailsData.surgeryDoctorDTO.name : '-'}}</div>
44
-				</div>
45
-				
46
-				<div class="form-title-box">
47
-					<div class="form-title"><span class="font-weight-500">离体时间:</span>{{detailsData.inVitroTime?(detailsData.inVitroTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
48
-					<div class="form-title"><span class="font-weight-500">固定时间:</span>{{detailsData.fixationTime?(detailsData.fixationTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
49
-				</div>
50
-				
51
-				<div class="form-list">
52
-					<div class="form-title font-weight-500">标本:</div>
53 43
 					<div class="form-title-box">
54
-						<div class="form-title" *ngFor="let item of specimenList">
55
-							{{item.partSource?item.partSource.name:''}} <span *ngIf="item.system">-</span>
56
-							{{item.system?item.system.name:''}} <span *ngIf="item.organ">-</span>
57
-							{{item.organ?item.organ.name:''}} <span *ngIf="item.sample">-</span>
58
-							{{item.sample?item.sample.name:''}}
44
+						<div class="form-title"><span class="font-weight-500">标本类型:</span>{{detailsData.specimenType.name||'无'}}</div>
45
+						<div class="form-title"><span class="font-weight-500">标本件数:</span>{{detailsData.specimenNum||'无'}}</div>
46
+						<div class="form-title"><span class="font-weight-500">采取部位:</span>{{detailsData.takePart||'无'}}</div>
47
+					</div>
48
+					
49
+					<div class="form-title-box">
50
+						<div class="form-title"><span class="font-weight-500">送检医生:</span>{{detailsData.surgeryDoctorDTO?detailsData.surgeryDoctorDTO.name : '-'}}</div>
51
+						<div class="form-title"><span class="font-weight-500">离体时间:</span>{{detailsData.inVitroTime?(detailsData.inVitroTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
52
+						<div class="form-title"><span class="font-weight-500">固定时间:</span>{{detailsData.fixationTime?(detailsData.fixationTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
53
+					</div>
54
+					
55
+					<div class="form-list">
56
+						<div class="form-title font-weight-500">标本:</div>
57
+						<div class="form-title-box">
58
+							<div class="form-title" *ngFor="let item of specimenList">
59
+								{{item.partSource?item.partSource.name:''}} <span *ngIf="item.system">-</span>
60
+								{{item.system?item.system.name:''}} <span *ngIf="item.organ">-</span>
61
+								{{item.organ?item.organ.name:''}} <span>-</span>
62
+								{{item.sample?item.sample.name:item.specimenName}}
63
+							</div>
59 64
 						</div>
60 65
 					</div>
61 66
 				</div>
62
-
67
+				<div class="content-item-right">
68
+					<div class="step-title">病理闭环</div>
69
+					<nz-steps [nzCurrent]="stepLength" nzDirection="vertical" nzSize="small">
70
+						<ng-container *ngFor="let item of pathologyLogs; let index = index">
71
+								<nz-step
72
+									[nzDescription]="tpl"
73
+								>
74
+								</nz-step>
75
+								<ng-template #tpl>
76
+									<div *ngIf="index==pathologyLogs.length-1" class="step-size">
77
+										<div style="color: #49B856;">{{item.operationType.name}}</div>
78
+										<div style="color:#333;">{{item.createTime|date:'yyyy-MM-dd HH:mm:ss'}} {{item.operationUserDto.name}}</div>
79
+									</div>
80
+									<div *ngIf="index!=pathologyLogs.length-1" class="step-size">
81
+										<div>{{item.operationType.name}}</div>
82
+										<div>{{item.createTime|date:'yyyy-MM-dd HH:mm:ss'}} {{item.operationUserDto.name}}</div>
83
+									</div>
84
+								</ng-template>
85
+							</ng-container>
86
+					</nz-steps>
87
+				</div>
63 88
 			</div>
64
-			
65
-			<div class="content-item-right">
66
-				<div class="step-title">病理闭环</div>
67
-				<nz-steps [nzCurrent]="stepLength" nzDirection="vertical" nzSize="small">
68
-					<ng-container *ngFor="let item of pathologyLogs; let index = index">
69
-							<nz-step
70
-								[nzDescription]="tpl"
71
-							>
72
-							</nz-step>
73
-							<ng-template #tpl>
74
-								<div *ngIf="index==pathologyLogs.length-1" class="step-size">
75
-									<div style="color: #49B856;">{{item.operationType.name}}</div>
76
-									<div style="color:#333;">{{item.createTime|date:'yyyy-MM-dd HH:mm:ss'}} {{item.operationUserDto.name}}</div>
77
-								</div>
78
-								<div *ngIf="index!=pathologyLogs.length-1" class="step-size">
79
-									<div>{{item.operationType.name}}</div>
80
-									<div>{{item.createTime|date:'yyyy-MM-dd HH:mm:ss'}} {{item.operationUserDto.name}}</div>
81
-								</div>
82
-							</ng-template>
83
-						</ng-container>
84
-				</nz-steps>
89
+			<div class="display_flex justify-content_flex-center bottom-btn">
90
+				<button class="btn btn-right" *ngIf="detailsData.status.value==6 || 
91
+				detailsData.status.value==7 || detailsData.status.value==8 || 
92
+				detailsData.status.value==9 || detailsData.status.value==10"nz-button nzType="primary" (click)="closeDetailMoadl()">确定</button>
93
+				
94
+				<button class="btn btn-right" *ngIf="detailsData.status.value==2 || 
95
+				detailsData.status.value==3 || detailsData.status.value==4 || 
96
+				detailsData.status.value==5" nz-button nzType="primary" (click)="submitPrint()" [nzLoading]="btnLoading">补打</button>
97
+				
98
+				<!-- <button class="btn btn-right" *ngIf="detailsData.status.value==2 || 
99
+				detailsData.status.value==3 || detailsData.status.value==4 || 
100
+				detailsData.status.value==5" nz-button nzType="primary" 
101
+				(click)="immobilization()">标本固定</button> -->
102
+				
103
+				<button class="btn cancel" nz-button nzType="default" (click)="closeDetailMoadl()">取消</button>
85 104
 			</div>
86 105
 		</div>
87
-		<div class="display_flex justify-content_flex-center bottom-btn">
88
-			<button class="btn btn-right" *ngIf="detailsData.status.value==6 || 
89
-			detailsData.status.value==7 || detailsData.status.value==8 || 
90
-			detailsData.status.value==9 || detailsData.status.value==10"nz-button nzType="primary" (click)="closeDetailMoadl()">确定</button>
91
-			
92
-			<button class="btn btn-right" *ngIf="detailsData.status.value==2 || 
93
-			detailsData.status.value==3 || detailsData.status.value==4 || 
94
-			detailsData.status.value==5" nz-button nzType="primary" (click)="submitPrint()" [nzLoading]="btnLoading">补打</button>
95
-			
96
-			<!-- <button class="btn btn-right" *ngIf="detailsData.status.value==2 || 
97
-			detailsData.status.value==3 || detailsData.status.value==4 || 
98
-			detailsData.status.value==5" nz-button nzType="primary" 
99
-			(click)="immobilization()">标本固定</button> -->
100
-			
101
-			<button class="btn cancel" nz-button nzType="default" (click)="closeDetailMoadl()">取消</button>
102
-		</div>
103
-	</div>
104
-	
105 106
 	<div class="mask-style" *ngIf="isSpinning">
106 107
 		<nz-spin nzSimple class="spin-style"></nz-spin>
107 108
 	</div>
@@ -134,10 +135,10 @@
134 135
 					<div style="width:70%;padding:1px;">{{printData.specimenNum}}</div>
135 136
 				</div>
136 137
 			</div>
137
-			 <div style="height: 10px;"></div>
138
+			<div style="height: 10px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1"></div>
138 139
 			<div style="font-size: 12px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>0">
139 140
 				<div *ngFor="let data of printData.specimenList; let index=index;">
140
-				 <div style="height: 30px;"></div>
141
+				 <div style="height: 30px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1"></div>
141 142
 				 <div style="border: 1px solid #AAAAAA;border-radius: 5px;">
142 143
 					 <img style="width: 100%;height: 90px;border-radius: 5px;" [src]="data.barCode" alt="">
143 144
 					 <div class="monad-sign" style="border-bottom: 1px solid #AAAAAA; padding-left:1px;">

+ 33 - 11
src/app/share/pathology-detail/pathology-detail.component.less

@@ -1,3 +1,24 @@
1
+/* 修改垂直滚动条 */
2
+::-webkit-scrollbar {
3
+	width: 4px; /* 修改宽度 */
4
+	border-radius: 2px;
5
+}
6
+ 
7
+/* 修改滚动条轨道背景色 */
8
+::-webkit-scrollbar-track {
9
+	background-color: #f1f1f1;
10
+}
11
+ 
12
+/* 修改滚动条滑块颜色 */
13
+::-webkit-scrollbar-thumb {
14
+	background-color: #888;
15
+}
16
+ 
17
+/* 修改滚动条滑块悬停时的颜色 */
18
+::-webkit-scrollbar-thumb:hover {
19
+	background-color: #555;
20
+}
21
+
1 22
 .pathology-box {
2 23
   position: fixed;
3 24
 	left: 0;
@@ -33,7 +54,6 @@
33 54
 			background: #f9fafb;
34 55
 			border: 1px solid #e5e9ed;
35 56
 			border-radius: 5px;
36
-			overflow: hidden;
37 57
 			margin-top: 12px;
38 58
 			display: flex;
39 59
 			// .addForm{
@@ -46,13 +66,13 @@
46 66
 					width: 100%;
47 67
 				}
48 68
 				.content-item{
49
-					height: auto;
50
-					max-height: 460px;
69
+					width: 78%;
70
+					height: 460px;
51 71
 					overflow-y: auto;
52
-					width: 75%;
53 72
 					padding: 15px;
54 73
 					.form-title-box{
55 74
 						display: flex;
75
+						flex-wrap: wrap;
56 76
 						margin-bottom: 10px;
57 77
 						.form-title{
58 78
 							color: #333;
@@ -87,13 +107,13 @@
87 107
 						}
88 108
 					}
89 109
 					.ant-form-item {
90
-					  margin-bottom: 14px;
110
+						margin-bottom: 14px;
91 111
 						display: flex;
92 112
 						flex-wrap: wrap;
93
-					  .ant-form-item-label {
94
-					    text-align: left;
113
+						.ant-form-item-label {
114
+							text-align: left;
95 115
 							font-weight: 500;
96
-					  }
116
+						}
97 117
 						.ant-form-item-control-wrapper{
98 118
 							.ant-form-item-control{
99 119
 								width: 400px;
@@ -115,10 +135,10 @@
115 135
 						}
116 136
 					}
117 137
 				}
138
+			
139
+
118 140
 				.content-item-right{
119
-					width: 25%;
120
-					height: auto;
121
-					max-height: 460px;
141
+					height: 460px;
122 142
 					overflow-y: auto;
123 143
 					padding: 15px;
124 144
 					.step-title{
@@ -127,6 +147,8 @@
127 147
 						margin-bottom: 10px;
128 148
 					}
129 149
 				}
150
+				
151
+				
130 152
 				.boder-right{
131 153
 					border-right: 1px solid #e5e9ed;
132 154
 				}

+ 475 - 462
src/app/share/pathology-detail/pathology-detail.component.ts

@@ -75,6 +75,10 @@ export class PathologyDetailComponent implements OnInit {
75 75
 	notModal:boolean = false;
76 76
 	hosId:any;
77 77
 	pathologyLogs:any //日志
78
+	printLoading:boolean = false;
79
+	printData:any = [];
80
+	project:any = [];
81
+	
78 82
   ngOnInit() {
79 83
 		this.hosId = this.tool.getCurrentHospital().id;
80 84
 		// this.initForm()
@@ -100,27 +104,31 @@ export class PathologyDetailComponent implements OnInit {
100 104
 		this.mainService
101 105
 		  .pathologyPrint(data)
102 106
 		  .subscribe((res:any) => {
103
-		    let arr = res.data;
104
-		    if(arr.applyBarCode){
105
-		    	arr.applyBarCode = this.sanitizer.bypassSecurityTrustResourceUrl(arr.applyBarCode)
106
-		    }
107
-		    for(let i of arr.specimenList){
108
-		    	i.barCode = this.sanitizer.bypassSecurityTrustResourceUrl(i.barCode)
109
-		    }
110
-		    that.printLoading = false;
111
-		    that.printData = arr;
112
-		    setTimeout(() => {
113
-		      const printContent = document.getElementById("report");
114
-		      const WindowPrt = window.open("", "", "width=100,height=1000");
115
-		    	WindowPrt.document.body.innerHTML = printContent.innerHTML;
116
-		    	setTimeout(_=>{
117
-		    		WindowPrt.document.close();
118
-		    		WindowPrt.focus();
119
-		    		WindowPrt.print();
120
-		    		WindowPrt.close();
121
-		    		that.hideModal();
122
-		    	},500)
123
-		    }, 500);
107
+				if(res.status==200){
108
+					let arr = res.data;
109
+					if(arr.applyBarCode){
110
+						arr.applyBarCode = this.sanitizer.bypassSecurityTrustResourceUrl(arr.applyBarCode)
111
+					}
112
+					for(let i of arr.specimenList){
113
+						i.barCode = this.sanitizer.bypassSecurityTrustResourceUrl(i.barCode)
114
+					}
115
+					that.printLoading = false;
116
+					that.printData = arr;
117
+					setTimeout(() => {
118
+					  const printContent = document.getElementById("report");
119
+					  const WindowPrt = window.open("", "", "width=100,height=1000");
120
+						WindowPrt.document.body.innerHTML = printContent.innerHTML;
121
+						setTimeout(_=>{
122
+							WindowPrt.document.close();
123
+							WindowPrt.focus();
124
+							WindowPrt.print();
125
+							WindowPrt.close();
126
+							that.hideModal();
127
+						},500)
128
+					}, 500);
129
+				}else{
130
+					this.message.error(res.msg)
131
+				}
124 132
 		  });
125 133
 	}
126 134
 	
@@ -130,16 +138,16 @@ export class PathologyDetailComponent implements OnInit {
130 138
 	}
131 139
 	
132 140
 	// 初始化新增form表单
133
-	initForm() {
134
-		this.validateForm = this.fb.group({
135
-		  intraoperativeRapidity: [1, [Validators.required]],
136
-			specimenGenre: [null, [Validators.required]],
137
-			intraoperativeFindings: [null, [Validators.required]],
138
-			surgicalPlan: [null, [Validators.required]],
139
-			specimenNum: [null,[Validators.required]],
140
-			takePart: [null, [Validators.required]]
141
-		});
142
-	}
141
+	// initForm() {
142
+	// 	this.validateForm = this.fb.group({
143
+	// 	  intraoperativeRapidity: [1, [Validators.required]],
144
+	// 		specimenGenre: [null, [Validators.required]],
145
+	// 		intraoperativeFindings: [null, [Validators.required]],
146
+	// 		surgicalPlan: [null, [Validators.required]],
147
+	// 		specimenNum: [null,[Validators.required]],
148
+	// 		takePart: [null, [Validators.required]]
149
+	// 	});
150
+	// }
143 151
 	
144 152
 	// 获取详情
145 153
 	fetchDataList(){
@@ -160,6 +168,12 @@ export class PathologyDetailComponent implements OnInit {
160 168
 		    this.detailsData = data.list[0];
161 169
 				this.pathologyLogs = data.list[0].formLogDTOS
162 170
 				this.stepLength = this.pathologyLogs.length
171
+				if(this.detailsData.pathologyInspectDTOS){
172
+					for(let i of this.detailsData.pathologyInspectDTOS){
173
+						this.project.push(i.inspectProject.name)
174
+					}
175
+					this.project = this.project.join('、')
176
+				}
163 177
 				// if(this.detailsData.surgicalPlan){
164 178
 				// 	this.validateForm.controls.surgicalPlan.setValue(this.detailsData.surgicalPlan);
165 179
 				// }
@@ -170,306 +184,306 @@ export class PathologyDetailComponent implements OnInit {
170 184
 		  });
171 185
 	}
172 186
 	
173
-	// 获取标本类型
174
-	getDicData(){
175
-		this.mainService.getDictionary("list", "pathology_specimen_type").subscribe((res) => {
176
-			this.specimenData = res
177
-		});
178
-	}
179
-	
180
-	// 获取标本-位置来源
181
-	getSourceData(){
182
-		this.mainService.getDictionary("list", "pathology_position").subscribe((res) => {
183
-			this.placeList = res
184
-		});
185
-	}
186
-	
187
-	// 获取标本-系统
188
-	getSysData(){
189
-		let postData: any = {
190
-		  idx: 0,
191
-		  sum: 9999,
192
-		  dictionaryTree: {
193
-		    level: 1,
194
-		    key: 'pathology_specimen',
195
-		    deleted: 0,
196
-		  },
197
-		};
198
-		this.mainService
199
-		  .getFetchDataList("simple/data", "dictionaryTree", postData)
200
-		  .subscribe((data) => {
201
-		    this.systemList = data.list;
202
-		  });
187
+	// // 获取标本类型
188
+	// getDicData(){
189
+	// 	this.mainService.getDictionary("list", "pathology_specimen_type").subscribe((res) => {
190
+	// 		this.specimenData = res
191
+	// 	});
192
+	// }
193
+	
194
+	// // 获取标本-位置来源
195
+	// getSourceData(){
196
+	// 	this.mainService.getDictionary("list", "pathology_position").subscribe((res) => {
197
+	// 		this.placeList = res
198
+	// 	});
199
+	// }
200
+	
201
+	// // 获取标本-系统
202
+	// getSysData(){
203
+	// 	let postData: any = {
204
+	// 	  idx: 0,
205
+	// 	  sum: 9999,
206
+	// 	  dictionaryTree: {
207
+	// 	    level: 1,
208
+	// 	    key: 'pathology_specimen',
209
+	// 	    deleted: 0,
210
+	// 	  },
211
+	// 	};
212
+	// 	this.mainService
213
+	// 	  .getFetchDataList("simple/data", "dictionaryTree", postData)
214
+	// 	  .subscribe((data) => {
215
+	// 	    this.systemList = data.list;
216
+	// 	  });
203 217
 
204
-	}
205
-	
206
-	// 获取标本-器官
207
-	getApparatusData(id,item,type){
208
-		let postData: any = {
209
-		  idx: 0,
210
-		  sum: 9999,
211
-		  dictionaryTree: {
212
-		    level: 2,
213
-				parent:id,
214
-		    key: 'pathology_specimen',
215
-		    deleted: 0,
216
-		  },
217
-		};
218
-		this.mainService
219
-		  .getFetchDataList("simple/data", "dictionaryTree", postData)
220
-		  .subscribe((data) => {
221
-				if(data.list.length>0){
222
-					this.apparatusList = data.list;
223
-					if(type=='edit'){
224
-						setTimeout(_=>{
225
-							let index3 = this.apparatusList.findIndex(i=>i.id==item.organ.id)
226
-							this.apparatusIndex = index3
227
-							this.apparatusId = Number(item.organ.id);
228
-						},100)
229
-					}
230
-				}else{
231
-					this.message.info('暂无数据')
232
-				}
233
-		  });
234
-	}
235
-	
236
-	// 获取标本-标本名称
237
-	getSpNameData(id,item,type){
238
-		let postData: any = {
239
-		  idx: 0,
240
-		  sum: 9999,
241
-		  dictionaryTree: {
242
-		    level: 3,
243
-				parent:id,
244
-		    key: 'pathology_specimen',
245
-		    deleted: 0,
246
-		  },
247
-		};
248
-		this.mainService
249
-		  .getFetchDataList("simple/data", "dictionaryTree", postData)
250
-		  .subscribe((data) => {
251
-		    this.specimenNameList = data.list;
252
-				this.specimenNameList.push({
253
-					name:'其他',
254
-					id:'qita'
255
-				})
256
-				if(type=='edit'){
257
-					if(item.sample){
258
-						this.validateSpecimenForm = this.fb.group({
259
-						  remark: [null, [Validators.required]]
260
-						});
261
-						setTimeout(_=>{
262
-							let index4 = this.specimenNameList.findIndex(i=>i.id==item.sample.id)
263
-							this.specimenNameIndex = index4
264
-							this.specimenNameName = item.sample.name
265
-							this.specimenNameId = Number(item.sample.id);
266
-						},100)
267
-					}else{
268
-						this.validateSpecimenForm = this.fb.group({
269
-						  remark: [null, [Validators.required]],
270
-							specimenName: [null, [Validators.required]]
271
-						});
272
-						this.specimenNameIndex = this.specimenNameList.length-1
273
-						this.specimenNameName = 'qita'
274
-						this.validateSpecimenForm.controls.specimenName.setValue(item.specimenName);
275
-					}
276
-					setTimeout(_=>{
277
-						this.validateSpecimenForm.controls.remark.setValue(item.remark);
278
-						this.specimenModal = true
279
-					},50)
280
-				}
281
-		  });
282
-	}
283
-	
284
-	// 删除标本
285
-	delModal:boolean = false
286
-	coopId:any;
287
-	specimenDel(e,item,index){
288
-		this.delModal = true
289
-		this.coopId = item.id
290
-	}
291
-	
292
-	// 确定删除
293
-	confirmDel(){
294
-		this.mainService
295
-		  .coopTypeConfig(
296
-		    "rmvData",
297
-		    "pathologySpecimen",
298
-		     [this.coopId]
299
-		  )
300
-		  .subscribe((data) => {
301
-		    this.btnLoading = false;
302
-		    this.delModal = false;
303
-				this.getSampleData()
304
-		    if (data.status==200) {
305
-		      this.showSpecimenModal("删除", true, "");
306
-		    } else {
307
-		      this.showSpecimenModal("删除", false, data.data[0].msg);
308
-		    }
309
-		  });
310
-	}
311
-	// 确定删除
312
-	hideDelModal() {
313
-	  this.delModal = false;
314
-	}
315
-	
316
-	// 编辑标本
317
-	specimenDetailId:any = null;
318
-	specimenEdit(e,item,index){
319
-		this.specimenDetailId = item.id
320
-		let index1 = this.placeList.findIndex(i=>i.id==item.partSource.id)
321
-		this.placeIndex = index1
322
-		this.placeId = Number(item.partSource.id)
323
-		let index2 = this.systemList.findIndex(i=>i.id==item.system.id)
324
-		this.systemIndex = index2
325
-		this.systemId = Number(item.system.id)
326
-		this.getApparatusData(item.system.id,item,'edit')
327
-		this.getSpNameData(item.organ.id,item,'edit')
328
-	}
329
-	
330
-	// 选择标本
331
-	openSpecimen(){
332
-		this.validateSpecimenForm = this.fb.group({
333
-		  remark: [null, [Validators.required]]
334
-		});
335
-		this.specimenDetailId = null;
336
-		this.placeIndex = null;
337
-		this.systemIndex = null;
338
-		this.apparatusIndex = null;
339
-		this.specimenNameIndex = null;
340
-		this.placeId = null;
341
-		this.systemId = null;
342
-		this.apparatusId = null;
343
-		this.specimenNameId = null;
344
-		this.placeList=[]; //位置来源数据
345
-		this.systemList=[]; //系统数据
346
-		this.apparatusList=[]; //器官数据
347
-		this.specimenNameList=[]; //标本名称数据
348
-		this.getSourceData()
349
-		this.getSysData()
350
-		this.specimenModal = true
351
-	}
352
-	
353
-	// 选择位置来源
354
-	placeId:any = null;
355
-	placeClick(e,item,index){
356
-		this.placeId = item.id
357
-		this.placeIndex = index
358
-	}
359
-	
360
-	// 选择系统
361
-	systemId:any = null;
362
-	systemClick(e,item,index){
363
-		this.systemId = Number(item.id)
364
-		this.systemIndex = index
365
-		this.apparatusList = [];
366
-		this.apparatusId = null;
367
-		this.apparatusIndex = null;
368
-		this.getApparatusData(item.id,{},'select')
369
-	}
370
-	
371
-	// 选择器官
372
-	apparatusId:any = null;
373
-	apparatusClick(e,item,index){
374
-		this.apparatusId = Number(item.id)
375
-		this.apparatusIndex = index
376
-		this.specimenNameList = [];
377
-		this.specimenNameId = null;
378
-		this.specimenNameIndex = null;
379
-		this.getSpNameData(item.id,{},'select')
380
-	}
381
-	
382
-	// 选择标本名称
383
-	specimenNameId:any = null;
384
-	specimenNameName:any = null;
385
-	specimenNameClick(e,item,index){
386
-		this.specimenNameIndex = index
387
-		let remark = this.validateSpecimenForm.value.remark
388
-		if(item.id == 'qita'){
389
-			this.validateSpecimenForm = this.fb.group({
390
-			  remark: [remark?remark:null, [Validators.required]],
391
-				specimenName: [null, [Validators.required]]
392
-			});
393
-			this.specimenNameId = 'null'
394
-			this.specimenNameName = 'qita'
395
-		}else{
396
-			this.validateSpecimenForm = this.fb.group({
397
-			  remark: [remark?remark:null, [Validators.required]],
398
-			});
399
-			this.specimenNameId = item.id
400
-			this.specimenNameName = item.name
401
-		}
402
-	}
403
-	
404
-	// 保存标本
405
-	btnSpLoading:boolean = false;
406
-	submitSpecimen(){
407
-		if(this.placeIndex==null){
408
-			this.message.error('请选择位置来源')
409
-			return
410
-		}
411
-		if(this.systemIndex==null){
412
-			this.message.error('请选择系统')
413
-			return
414
-		}
415
-		if(this.apparatusIndex==null){
416
-			this.message.error('请选择器官')
417
-			return
418
-		}
419
-		if(this.specimenNameIndex==null){
420
-			this.message.error('请选择标本名称')
421
-			return
422
-		}
423
-		for (const i in this.validateSpecimenForm.controls) {
424
-		  this.validateSpecimenForm.controls[i].markAsDirty();
425
-		  this.validateSpecimenForm.controls[i].updateValueAndValidity();
426
-		}
427
-		if (this.validateSpecimenForm.invalid) return;
428
-		let data = {
429
-			pathologyFormId:this.detailsData.id,
430
-			partSource:{
431
-				id:this.placeId
432
-			},
433
-			system:{
434
-				id:this.systemId
435
-			},
436
-			organ:{
437
-				id:this.apparatusId
438
-			},
439
-			sample:{
440
-				id:this.specimenNameId
441
-			},
442
-			hosId:this.hosId,
443
-			specimenName:null,
444
-			id:'',
445
-			remark:this.validateSpecimenForm.value.remark
446
-		};
447
-		if(this.specimenNameName == 'qita'){
448
-			delete data.sample
449
-			data.specimenName = this.validateSpecimenForm.value.specimenName
450
-		}else{
451
-			data.specimenName = this.specimenNameName
452
-		}
453
-		let queryType = null
454
-		if(this.specimenDetailId){
455
-			queryType = 'updData'
456
-			data.id = this.specimenDetailId
457
-		}else{
458
-			queryType = 'addData'
459
-			delete data.id
460
-		}
461
-		this.btnSpLoading = true;
462
-		this.mainService
463
-		  .simplePost(queryType, "pathologySpecimen", data)
464
-		  .subscribe((res) => {
465
-		    this.btnSpLoading = false;
466
-		    if (res.status == 200) {
467
-		      this.showSpecimenModal("操作", true, "");
468
-		    } else {
469
-		      this.showSpecimenModal("操作", false, res.msg);
470
-		    }
471
-		  });
472
-	}
218
+	// }
219
+	
220
+	// // 获取标本-器官
221
+	// getApparatusData(id,item,type){
222
+	// 	let postData: any = {
223
+	// 	  idx: 0,
224
+	// 	  sum: 9999,
225
+	// 	  dictionaryTree: {
226
+	// 	    level: 2,
227
+	// 			parent:id,
228
+	// 	    key: 'pathology_specimen',
229
+	// 	    deleted: 0,
230
+	// 	  },
231
+	// 	};
232
+	// 	this.mainService
233
+	// 	  .getFetchDataList("simple/data", "dictionaryTree", postData)
234
+	// 	  .subscribe((data) => {
235
+	// 			if(data.list.length>0){
236
+	// 				this.apparatusList = data.list;
237
+	// 				if(type=='edit'){
238
+	// 					setTimeout(_=>{
239
+	// 						let index3 = this.apparatusList.findIndex(i=>i.id==item.organ.id)
240
+	// 						this.apparatusIndex = index3
241
+	// 						this.apparatusId = Number(item.organ.id);
242
+	// 					},100)
243
+	// 				}
244
+	// 			}else{
245
+	// 				this.message.info('暂无数据')
246
+	// 			}
247
+	// 	  });
248
+	// }
249
+	
250
+	// // 获取标本-标本名称
251
+	// getSpNameData(id,item,type){
252
+	// 	let postData: any = {
253
+	// 	  idx: 0,
254
+	// 	  sum: 9999,
255
+	// 	  dictionaryTree: {
256
+	// 	    level: 3,
257
+	// 			parent:id,
258
+	// 	    key: 'pathology_specimen',
259
+	// 	    deleted: 0,
260
+	// 	  },
261
+	// 	};
262
+	// 	this.mainService
263
+	// 	  .getFetchDataList("simple/data", "dictionaryTree", postData)
264
+	// 	  .subscribe((data) => {
265
+	// 	    this.specimenNameList = data.list;
266
+	// 			this.specimenNameList.push({
267
+	// 				name:'其他',
268
+	// 				id:'qita'
269
+	// 			})
270
+	// 			if(type=='edit'){
271
+	// 				if(item.sample){
272
+	// 					this.validateSpecimenForm = this.fb.group({
273
+	// 					  remark: [null, [Validators.required]]
274
+	// 					});
275
+	// 					setTimeout(_=>{
276
+	// 						let index4 = this.specimenNameList.findIndex(i=>i.id==item.sample.id)
277
+	// 						this.specimenNameIndex = index4
278
+	// 						this.specimenNameName = item.sample.name
279
+	// 						this.specimenNameId = Number(item.sample.id);
280
+	// 					},100)
281
+	// 				}else{
282
+	// 					this.validateSpecimenForm = this.fb.group({
283
+	// 					  remark: [null, [Validators.required]],
284
+	// 						specimenName: [null, [Validators.required]]
285
+	// 					});
286
+	// 					this.specimenNameIndex = this.specimenNameList.length-1
287
+	// 					this.specimenNameName = 'qita'
288
+	// 					this.validateSpecimenForm.controls.specimenName.setValue(item.specimenName);
289
+	// 				}
290
+	// 				setTimeout(_=>{
291
+	// 					this.validateSpecimenForm.controls.remark.setValue(item.remark);
292
+	// 					this.specimenModal = true
293
+	// 				},50)
294
+	// 			}
295
+	// 	  });
296
+	// }
297
+	
298
+	// // 删除标本
299
+	// delModal:boolean = false
300
+	// coopId:any;
301
+	// specimenDel(e,item,index){
302
+	// 	this.delModal = true
303
+	// 	this.coopId = item.id
304
+	// }
305
+	
306
+	// // 确定删除
307
+	// confirmDel(){
308
+	// 	this.mainService
309
+	// 	  .coopTypeConfig(
310
+	// 	    "rmvData",
311
+	// 	    "pathologySpecimen",
312
+	// 	     [this.coopId]
313
+	// 	  )
314
+	// 	  .subscribe((data) => {
315
+	// 	    this.btnLoading = false;
316
+	// 	    this.delModal = false;
317
+	// 			this.getSampleData()
318
+	// 	    if (data.status==200) {
319
+	// 	      this.showSpecimenModal("删除", true, "");
320
+	// 	    } else {
321
+	// 	      this.showSpecimenModal("删除", false, data.data[0].msg);
322
+	// 	    }
323
+	// 	  });
324
+	// }
325
+	// // 确定删除
326
+	// hideDelModal() {
327
+	//   this.delModal = false;
328
+	// }
329
+	
330
+	// // 编辑标本
331
+	// specimenDetailId:any = null;
332
+	// specimenEdit(e,item,index){
333
+	// 	this.specimenDetailId = item.id
334
+	// 	let index1 = this.placeList.findIndex(i=>i.id==item.partSource.id)
335
+	// 	this.placeIndex = index1
336
+	// 	this.placeId = Number(item.partSource.id)
337
+	// 	let index2 = this.systemList.findIndex(i=>i.id==item.system.id)
338
+	// 	this.systemIndex = index2
339
+	// 	this.systemId = Number(item.system.id)
340
+	// 	this.getApparatusData(item.system.id,item,'edit')
341
+	// 	this.getSpNameData(item.organ.id,item,'edit')
342
+	// }
343
+	
344
+	// // 选择标本
345
+	// openSpecimen(){
346
+	// 	this.validateSpecimenForm = this.fb.group({
347
+	// 	  remark: [null, [Validators.required]]
348
+	// 	});
349
+	// 	this.specimenDetailId = null;
350
+	// 	this.placeIndex = null;
351
+	// 	this.systemIndex = null;
352
+	// 	this.apparatusIndex = null;
353
+	// 	this.specimenNameIndex = null;
354
+	// 	this.placeId = null;
355
+	// 	this.systemId = null;
356
+	// 	this.apparatusId = null;
357
+	// 	this.specimenNameId = null;
358
+	// 	this.placeList=[]; //位置来源数据
359
+	// 	this.systemList=[]; //系统数据
360
+	// 	this.apparatusList=[]; //器官数据
361
+	// 	this.specimenNameList=[]; //标本名称数据
362
+	// 	this.getSourceData()
363
+	// 	this.getSysData()
364
+	// 	this.specimenModal = true
365
+	// }
366
+	
367
+	// // 选择位置来源
368
+	// placeId:any = null;
369
+	// placeClick(e,item,index){
370
+	// 	this.placeId = item.id
371
+	// 	this.placeIndex = index
372
+	// }
373
+	
374
+	// // 选择系统
375
+	// systemId:any = null;
376
+	// systemClick(e,item,index){
377
+	// 	this.systemId = Number(item.id)
378
+	// 	this.systemIndex = index
379
+	// 	this.apparatusList = [];
380
+	// 	this.apparatusId = null;
381
+	// 	this.apparatusIndex = null;
382
+	// 	this.getApparatusData(item.id,{},'select')
383
+	// }
384
+	
385
+	// // 选择器官
386
+	// apparatusId:any = null;
387
+	// apparatusClick(e,item,index){
388
+	// 	this.apparatusId = Number(item.id)
389
+	// 	this.apparatusIndex = index
390
+	// 	this.specimenNameList = [];
391
+	// 	this.specimenNameId = null;
392
+	// 	this.specimenNameIndex = null;
393
+	// 	this.getSpNameData(item.id,{},'select')
394
+	// }
395
+	
396
+	// // 选择标本名称
397
+	// specimenNameId:any = null;
398
+	// specimenNameName:any = null;
399
+	// specimenNameClick(e,item,index){
400
+	// 	this.specimenNameIndex = index
401
+	// 	let remark = this.validateSpecimenForm.value.remark
402
+	// 	if(item.id == 'qita'){
403
+	// 		this.validateSpecimenForm = this.fb.group({
404
+	// 		  remark: [remark?remark:null, [Validators.required]],
405
+	// 			specimenName: [null, [Validators.required]]
406
+	// 		});
407
+	// 		this.specimenNameId = 'null'
408
+	// 		this.specimenNameName = 'qita'
409
+	// 	}else{
410
+	// 		this.validateSpecimenForm = this.fb.group({
411
+	// 		  remark: [remark?remark:null, [Validators.required]],
412
+	// 		});
413
+	// 		this.specimenNameId = item.id
414
+	// 		this.specimenNameName = item.name
415
+	// 	}
416
+	// }
417
+	
418
+	// // 保存标本
419
+	// btnSpLoading:boolean = false;
420
+	// submitSpecimen(){
421
+	// 	if(this.placeIndex==null){
422
+	// 		this.message.error('请选择位置来源')
423
+	// 		return
424
+	// 	}
425
+	// 	if(this.systemIndex==null){
426
+	// 		this.message.error('请选择系统')
427
+	// 		return
428
+	// 	}
429
+	// 	if(this.apparatusIndex==null){
430
+	// 		this.message.error('请选择器官')
431
+	// 		return
432
+	// 	}
433
+	// 	if(this.specimenNameIndex==null){
434
+	// 		this.message.error('请选择标本名称')
435
+	// 		return
436
+	// 	}
437
+	// 	for (const i in this.validateSpecimenForm.controls) {
438
+	// 	  this.validateSpecimenForm.controls[i].markAsDirty();
439
+	// 	  this.validateSpecimenForm.controls[i].updateValueAndValidity();
440
+	// 	}
441
+	// 	if (this.validateSpecimenForm.invalid) return;
442
+	// 	let data = {
443
+	// 		pathologyFormId:this.detailsData.id,
444
+	// 		partSource:{
445
+	// 			id:this.placeId
446
+	// 		},
447
+	// 		system:{
448
+	// 			id:this.systemId
449
+	// 		},
450
+	// 		organ:{
451
+	// 			id:this.apparatusId
452
+	// 		},
453
+	// 		sample:{
454
+	// 			id:this.specimenNameId
455
+	// 		},
456
+	// 		hosId:this.hosId,
457
+	// 		specimenName:null,
458
+	// 		id:'',
459
+	// 		remark:this.validateSpecimenForm.value.remark
460
+	// 	};
461
+	// 	if(this.specimenNameName == 'qita'){
462
+	// 		delete data.sample
463
+	// 		data.specimenName = this.validateSpecimenForm.value.specimenName
464
+	// 	}else{
465
+	// 		data.specimenName = this.specimenNameName
466
+	// 	}
467
+	// 	let queryType = null
468
+	// 	if(this.specimenDetailId){
469
+	// 		queryType = 'updData'
470
+	// 		data.id = this.specimenDetailId
471
+	// 	}else{
472
+	// 		queryType = 'addData'
473
+	// 		delete data.id
474
+	// 	}
475
+	// 	this.btnSpLoading = true;
476
+	// 	this.mainService
477
+	// 	  .simplePost(queryType, "pathologySpecimen", data)
478
+	// 	  .subscribe((res) => {
479
+	// 	    this.btnSpLoading = false;
480
+	// 	    if (res.status == 200) {
481
+	// 	      this.showSpecimenModal("操作", true, "");
482
+	// 	    } else {
483
+	// 	      this.showSpecimenModal("操作", false, res.msg);
484
+	// 	    }
485
+	// 	  });
486
+	// }
473 487
 	
474 488
 	// 获取标本列表
475 489
 	getSampleData(){
@@ -496,144 +510,143 @@ export class PathologyDetailComponent implements OnInit {
496 510
 	}
497 511
 	
498 512
 	// 日期选择
499
-	startDate: string; //时间开始
500
-	formChangeDate(result?): void {
501
-	  this.startDate = format(result[0], 'yyyy-MM-dd HH:mm:ss');
513
+	// startDate: string; //时间开始
514
+	// formChangeDate(result?): void {
515
+	//   this.startDate = format(result[0], 'yyyy-MM-dd HH:mm:ss');
502 516
 		
503
-	}
517
+	// }
504 518
 	
505 519
 	//未打印提交
506
-	printLoading:boolean = false;
507
-	submitPrintForm(): void{
508
-		for (const i in this.validatePrintForm.controls) {
509
-		  this.validatePrintForm.controls[i].markAsDirty();
510
-		  this.validatePrintForm.controls[i].updateValueAndValidity();
511
-		}
512
-		if (this.validatePrintForm.invalid) return;
520
+	// submitPrintForm(): void{
521
+	// 	for (const i in this.validatePrintForm.controls) {
522
+	// 	  this.validatePrintForm.controls[i].markAsDirty();
523
+	// 	  this.validatePrintForm.controls[i].updateValueAndValidity();
524
+	// 	}
525
+	// 	if (this.validatePrintForm.invalid) return;
513 526
 		
514
-		let data: any = {
515
-			pathologyForm:{
516
-				...this.validateForm.value,
517
-				...this.detailsData,
518
-				inVitroTime:this.validatePrintForm.value.inVitroTime,
519
-				surgeryId: this.surgeryId || "",
520
-				patientId: this.patientId || "",
521
-				hosId: this.hosId || "" ,
522
-				handoverUserId:this.handoverUserId,
523
-				specimenType:{
524
-					id:this.validateForm.value.specimenGenre
525
-				}
526
-			}
527
-		};
528
-		delete data.pathologyForm.patientDTO
529
-		delete data.pathologyForm.surgeryDeptDTO
530
-		delete data.pathologyForm.surgeryDoctorDTO
531
-		delete data.pathologyForm.specimenGenre
532
-		this.printLoading = true;
533
-		this.mainService
534
-		  .pathologyPrint(data)
535
-		  .subscribe((res:any) => {
536
-				console.log(5555,res)
537
-				this.hideModal()
538
-		    this.printData = res.data;
539
-				this.printLoading = false;
540
-		    setTimeout(() => {
541
-		      const printContent = document.getElementById("report");
542
-		      const WindowPrt = window.open("", "", "width=100,height=1000");
543
-		      WindowPrt.document.write(printContent.innerHTML);
544
-		      WindowPrt.document.close();
545
-		      WindowPrt.focus();
546
-		      WindowPrt.print();
547
-		      WindowPrt.close();
548
-		    }, 500);
549
-		  });
550
-	}
551
-	
552
-	// 监听工号数据
553
-	handoverUserId:any = null;
554
-	numberChange(e){
555
-		if(e.length < 3) {
556
-			this.validatePrintForm.controls.name.setValue('');
557
-			return
558
-		}
559
-		let data = {
560
-		  idx: 0,
561
-		  sum: 9999,
562
-		  user: {
563
-		    account: e || "",
564
-		    hospital: { id: this.hosId || "" }
565
-		  },
566
-		};
567
-		this.mainService
568
-		  .getFetchDataList("data", "user", data)
569
-		  .subscribe((data) => {
570
-				if(data.list.length>0){
571
-					this.validatePrintForm.controls.name.setValue(data.list[0].name);
572
-					this.handoverUserId = data.list[0].id
573
-				}else{
574
-					this.validatePrintForm.controls.name.setValue('');
575
-					this.handoverUserId =null
576
-				}
577
-		  });
578
-	}
579
-	
580
-	printData:any;
581
-	submitForm(): void{
582
-		var that = this;
583
-		for (const i in that.validateForm.controls) {
584
-		  that.validateForm.controls[i].markAsDirty();
585
-		  that.validateForm.controls[i].updateValueAndValidity();
586
-		}
587
-		if (that.validateForm.invalid) return;
588
-		if(this.detailsData.status.name=='未打印'){
589
-			this.notModal = true
590
-			this.validatePrintForm = this.fb.group({
591
-			  inVitroTime: [null, [Validators.required]],
592
-				jobNumber: [null, [Validators.required]],
593
-				name:[null, [Validators.required]],
594
-			});
595
-			let date = new Date();
596
-			this.startDate = format(date, "yyyy-MM-dd HH:mm:ss")
597
-			this.validatePrintForm.controls.inVitroTime.setValue(this.startDate);
598
-			return
599
-		}
527
+	// 	let data: any = {
528
+	// 		pathologyForm:{
529
+	// 			...this.validateForm.value,
530
+	// 			...this.detailsData,
531
+	// 			inVitroTime:this.validatePrintForm.value.inVitroTime,
532
+	// 			surgeryId: this.surgeryId || "",
533
+	// 			patientId: this.patientId || "",
534
+	// 			hosId: this.hosId || "" ,
535
+	// 			handoverUserId:this.handoverUserId,
536
+	// 			specimenType:{
537
+	// 				id:this.validateForm.value.specimenGenre
538
+	// 			}
539
+	// 		}
540
+	// 	};
541
+	// 	delete data.pathologyForm.patientDTO
542
+	// 	delete data.pathologyForm.surgeryDeptDTO
543
+	// 	delete data.pathologyForm.surgeryDoctorDTO
544
+	// 	delete data.pathologyForm.specimenGenre
545
+	// 	this.printLoading = true;
546
+	// 	this.mainService
547
+	// 	  .pathologyPrint(data)
548
+	// 	  .subscribe((res:any) => {
549
+	// 			console.log(5555,res)
550
+	// 			this.hideModal()
551
+	// 	    this.printData = res.data;
552
+	// 			this.printLoading = false;
553
+	// 	    setTimeout(() => {
554
+	// 	      const printContent = document.getElementById("report");
555
+	// 	      const WindowPrt = window.open("", "", "width=100,height=1000");
556
+	// 	      WindowPrt.document.write(printContent.innerHTML);
557
+	// 	      WindowPrt.document.close();
558
+	// 	      WindowPrt.focus();
559
+	// 	      WindowPrt.print();
560
+	// 	      WindowPrt.close();
561
+	// 	    }, 500);
562
+	// 	  });
563
+	// }
564
+	
565
+	// // 监听工号数据
566
+	// handoverUserId:any = null;
567
+	// numberChange(e){
568
+	// 	if(e.length < 3) {
569
+	// 		this.validatePrintForm.controls.name.setValue('');
570
+	// 		return
571
+	// 	}
572
+	// 	let data = {
573
+	// 	  idx: 0,
574
+	// 	  sum: 9999,
575
+	// 	  user: {
576
+	// 	    account: e || "",
577
+	// 	    hospital: { id: this.hosId || "" }
578
+	// 	  },
579
+	// 	};
580
+	// 	this.mainService
581
+	// 	  .getFetchDataList("data", "user", data)
582
+	// 	  .subscribe((data) => {
583
+	// 			if(data.list.length>0){
584
+	// 				this.validatePrintForm.controls.name.setValue(data.list[0].name);
585
+	// 				this.handoverUserId = data.list[0].id
586
+	// 			}else{
587
+	// 				this.validatePrintForm.controls.name.setValue('');
588
+	// 				this.handoverUserId =null
589
+	// 			}
590
+	// 	  });
591
+	// }
592
+	
593
+	// printData:any;
594
+	// submitForm(): void{
595
+	// 	var that = this;
596
+	// 	for (const i in that.validateForm.controls) {
597
+	// 	  that.validateForm.controls[i].markAsDirty();
598
+	// 	  that.validateForm.controls[i].updateValueAndValidity();
599
+	// 	}
600
+	// 	if (that.validateForm.invalid) return;
601
+	// 	if(this.detailsData.status.name=='未打印'){
602
+	// 		this.notModal = true
603
+	// 		this.validatePrintForm = this.fb.group({
604
+	// 		  inVitroTime: [null, [Validators.required]],
605
+	// 			jobNumber: [null, [Validators.required]],
606
+	// 			name:[null, [Validators.required]],
607
+	// 		});
608
+	// 		let date = new Date();
609
+	// 		this.startDate = format(date, "yyyy-MM-dd HH:mm:ss")
610
+	// 		this.validatePrintForm.controls.inVitroTime.setValue(this.startDate);
611
+	// 		return
612
+	// 	}
600 613
 
601
-		let data: any = {
602
-			pathologyForm:{
603
-				...this.validateForm.value,
604
-				...this.detailsData,
605
-				surgeryId: this.surgeryId || "",
606
-				patientId: this.patientId || "",
607
-				hosId: this.hosId || "" ,
608
-				specimenType:{
609
-					id:this.validateForm.value.specimenGenre
610
-				}
611
-			}
612
-		};
613
-		delete data.pathologyForm.patientDTO
614
-		delete data.pathologyForm.surgeryDeptDTO
615
-		delete data.pathologyForm.surgeryDoctorDTO 
616
-		delete data.pathologyForm.specimenGenre 
617
-		that.btnLoading = true;
618
-		that.mainService
619
-		  .pathologyPrint(data)
620
-		  .subscribe((res:any) => {
621
-				this.hideModal()
622
-				let arr = res.data;
623
-		    that.printData = arr;
624
-				that.btnLoading = false;
625
-		    setTimeout(() => {
626
-		      const printContent = document.getElementById("report");
627
-		      const WindowPrt = window.open("", "", "width=100,height=1000");
628
-		      WindowPrt.document.write(printContent.innerHTML);
629
-		      WindowPrt.document.close();
630
-		      WindowPrt.focus();
631
-		      WindowPrt.print();
632
-		      WindowPrt.close();
614
+	// 	let data: any = {
615
+	// 		pathologyForm:{
616
+	// 			...this.validateForm.value,
617
+	// 			...this.detailsData,
618
+	// 			surgeryId: this.surgeryId || "",
619
+	// 			patientId: this.patientId || "",
620
+	// 			hosId: this.hosId || "" ,
621
+	// 			specimenType:{
622
+	// 				id:this.validateForm.value.specimenGenre
623
+	// 			}
624
+	// 		}
625
+	// 	};
626
+	// 	delete data.pathologyForm.patientDTO
627
+	// 	delete data.pathologyForm.surgeryDeptDTO
628
+	// 	delete data.pathologyForm.surgeryDoctorDTO 
629
+	// 	delete data.pathologyForm.specimenGenre 
630
+	// 	that.btnLoading = true;
631
+	// 	that.mainService
632
+	// 	  .pathologyPrint(data)
633
+	// 	  .subscribe((res:any) => {
634
+	// 			this.hideModal()
635
+	// 			let arr = res.data;
636
+	// 	    that.printData = arr;
637
+	// 			that.btnLoading = false;
638
+	// 	    setTimeout(() => {
639
+	// 	      const printContent = document.getElementById("report");
640
+	// 	      const WindowPrt = window.open("", "", "width=100,height=1000");
641
+	// 	      WindowPrt.document.write(printContent.innerHTML);
642
+	// 	      WindowPrt.document.close();
643
+	// 	      WindowPrt.focus();
644
+	// 	      WindowPrt.print();
645
+	// 	      WindowPrt.close();
633 646
 					
634
-		    }, 500);
635
-		  });
636
-	}
647
+	// 	    }, 500);
648
+	// 	  });
649
+	// }
637 650
 	
638 651
 	// 关闭标本
639 652
 	closeSpecimenModel(){

+ 3 - 3
src/app/views/hushijiandan/hushijiandan.component.html

@@ -1663,6 +1663,7 @@
1663 1663
                             <!-- 【是否开启手术即将开始通知】开启 -->
1664 1664
                             <button class="btn1 mr8 mb8 mt8" (click)="pickUpPatient($event, item)" *ngIf="item.state && item.state.value == 3">一键接患者</button>
1665 1665
                             <!-- 手术状态是【手术中】,并且【是否开通送回病房】开启 -->
1666
+														<button *ngIf="surgeryWKOMsg.patientDTO && surgeryConfigs && surgeryConfigs.isPathologyForm == 1" class="btn1 mr8 mb8 mt8" (click)="pathologyAddItem($event,item)">病理申请单</button>
1666 1667
                             <button class="btn1 mr8 mb8 mt8" (click)="sendWard($event, item)" *ngIf="item.patientDTO && surgeryConfigs && surgeryConfigs.remandClinical == 1 && item.state && item.state.value == 8">送回病房</button>
1667 1668
                             <!-- 手术状态是【手术中】,并且【是否开通送回苏醒室】开启 -->
1668 1669
                             <button class="btn1 mr8 mb8 mt8" (click)="sendAwakeningRoom($event, item)" *ngIf="item.patientDTO && surgeryConfigs && surgeryConfigs.remandRecovery == 1 && item.state && item.state.value == 8">送回苏醒间</button>
@@ -3955,8 +3956,7 @@
3955 3956
 <button ngxPrint printSectionId="print-section" #printBtn hidden [printStyle]="{ '@page': { margin: '0 !important' }, 'body': { margin: '0 !important' } }">打印</button>
3956 3957
 
3957 3958
 <!-- 病理申请单 -->
3958
-
3959
-<app-pathology-add *ngIf="pathologyModal" [surgeryId]="surgeryWKOMsg.id" [patientId]="surgeryWKOMsg.patientDTO.id" (pathologyCancel)="pathologyCancel($event)"></app-pathology-add>
3959
+<app-pathology-add *ngIf="pathologyModal" [surgeryId]="surgeryDataId" [patientId]="patientDataId" (pathologyCancel)="pathologyCancel($event)"></app-pathology-add>
3960 3960
 
3961 3961
 <!-- 病理详情 -->
3962
-<app-pathology-detail *ngIf="pathologyDetailModal" [surgeryId]="surgeryWKOMsg.id" [patientId]="surgeryWKOMsg.patientDTO.id" (pathologyCancel)="pathologyDetailCancel($event)"></app-pathology-detail>
3962
+<app-pathology-detail *ngIf="pathologyDetailModal" [surgeryId]="surgeryDataId" [patientId]="patientDataId" (pathologyCancel)="pathologyDetailCancel($event)"></app-pathology-detail>

+ 39 - 11
src/app/views/hushijiandan/hushijiandan.component.ts

@@ -168,7 +168,9 @@ export class HushijiandanComponent implements OnInit {
168 168
 	pathologyDetailModal:boolean = false; //病理详情
169 169
   // 初始化权限按钮
170 170
   coopBtns: any = {};
171
-
171
+	surgeryDataId: any; //手术id
172
+	patientDataId: any; //病人id
173
+	
172 174
   ngOnInit() {
173 175
     this.getCoopBtns();
174 176
     this.currentHospital = this.tool.getCurrentHospital();
@@ -307,18 +309,44 @@ export class HushijiandanComponent implements OnInit {
307 309
     console.log(this.coopBtns);
308 310
   }
309 311
 	
312
+	// 手术排程-病理申请单
313
+	pathologyAddItem(e,item){
314
+		this.surgeryDataId = item.id
315
+		this.patientDataId = item.patientDTO.id
316
+		let data = {
317
+			idx: 0,
318
+			sum: 9999,
319
+			pathologyForm: {
320
+				surgeryId: item.id || "",
321
+				patientId: item.patientDTO.id || "",
322
+				hosId: this.currentHospital.id || "" ,
323
+			},
324
+		};
325
+		this.mainService
326
+			.getFetchDataList("data", "pathologyForm", data)
327
+			.subscribe((data) => {
328
+				if(data.list[0].status.value==1){
329
+					this.pathologyModal = true
330
+				}else{
331
+					this.pathologyDetailModal = true
332
+				}
333
+			});
334
+	}
335
+	
310 336
 	// 病理申请单
311 337
 	pathologyAdd(e){
312
-	let data = {
313
-		idx: 0,
314
-		sum: 9999,
315
-		pathologyForm: {
316
-			surgeryId: this.surgeryWKOMsg.id || "",
317
-			patientId: this.surgeryWKOMsg.patientDTO.id || "",
318
-			hosId: this.currentHospital.id || "" ,
319
-		},
320
-	};
321
-	this.mainService
338
+		this.surgeryDataId = this.surgeryWKOMsg.id
339
+		this.patientDataId = this.surgeryWKOMsg.patientDTO.id
340
+		let data = {
341
+			idx: 0,
342
+			sum: 9999,
343
+			pathologyForm: {
344
+				surgeryId: this.surgeryWKOMsg.id || "",
345
+				patientId: this.surgeryWKOMsg.patientDTO.id || "",
346
+				hosId: this.currentHospital.id || "" ,
347
+			},
348
+		};
349
+		this.mainService
322 350
 		.getFetchDataList("data", "pathologyForm", data)
323 351
 		.subscribe((data) => {
324 352
 			if(data.list[0].status.value==1){

+ 2 - 1
src/app/views/main/main.component.html

@@ -42,7 +42,8 @@
42 42
           <button nz-button nzType="primary" *ngIf="specimenViewRole" (click)="toBigScreen('specimenView')" [nzLoading]="deptTypeLoading">业务视图</button>
43 43
           <button nz-button nzType="primary" *ngIf="specimenViewRole2" (click)="toSpecimenView2()">标本视图</button>
44 44
 					<button nz-button nzType="primary" *ngIf="specimenRoomView" (click)="toSpecimenRoomView()">标本间端</button>
45
-          <button nz-button nzType="primary" *ngIf="disinfectionSupplyRole" (click)="toDisinfectionSupply()">全局业务查看</button>
45
+					<button nz-button nzType="primary" *ngIf="pathology" (click)="toPathology()">病理科端</button>
46
+					<button nz-button nzType="primary" *ngIf="disinfectionSupplyRole" (click)="toDisinfectionSupply()">全局业务查看</button>
46 47
           <button nz-button nzType="primary" *ngIf="configurationCenterRole" (click)="toConfigurationCenter()">配置中心</button>
47 48
         </div>
48 49
         <div class="right">

+ 9 - 0
src/app/views/main/main.component.ts

@@ -30,6 +30,7 @@ export class MainComponent implements OnInit {
30 30
   specimenViewRole: boolean = false; //业务视图权限
31 31
   specimenViewRole2: boolean = false; //标本视图权限
32 32
 	specimenRoomView: boolean = false; //标本间权限
33
+	pathology: boolean = false; //病理科权限
33 34
   disinfectionSupplyRole: boolean = false; //全局业务查看权限
34 35
   configurationCenterRole: boolean = false; //配置中心权限
35 36
   PCCommutesToWork: boolean = false; //PC上下班权限
@@ -294,6 +295,10 @@ export class MainComponent implements OnInit {
294 295
 			  this.specimenRoomView = true;
295 296
 			  console.log("标本间权限");
296 297
 			}
298
+			if (e.link == "pathology") {
299
+			  this.pathology = true;
300
+			  console.log("病理科权限");
301
+			}
297 302
       if (e.link == "disinfectionSupply") {
298 303
         this.disinfectionSupplyRole = true;
299 304
         console.log("全局业务查看权限");
@@ -417,6 +422,10 @@ export class MainComponent implements OnInit {
417 422
 	toSpecimenRoomView(): void {
418 423
 	  this.router.navigateByUrl("specimenRoomView");
419 424
 	}
425
+	// 病理科
426
+	toPathology(): void {
427
+	  this.router.navigateByUrl("pathology");
428
+	}
420 429
   // 全局业务查看
421 430
   toDisinfectionSupply(): void {
422 431
     this.router.navigateByUrl("disinfectionSupply");

+ 17 - 0
src/app/views/pathology/pathology-routing.module.ts

@@ -0,0 +1,17 @@
1
+import { NgModule } from "@angular/core";
2
+import { Routes, RouterModule } from "@angular/router";
3
+import { PathologyComponent } from "./pathology.component";
4
+import { DetailSampleComponent } from 'src/app/share/detail-sample/detail-sample.component';
5
+
6
+const routes: Routes = [
7
+  {
8
+    path: "",
9
+    component: PathologyComponent
10
+  },
11
+];
12
+
13
+@NgModule({
14
+  imports: [RouterModule.forChild(routes)],
15
+  exports: [RouterModule],
16
+})
17
+export class PathologyRoutingModule {}

+ 622 - 0
src/app/views/pathology/pathology.component.html

@@ -0,0 +1,622 @@
1
+<div class="pharmacy">
2
+  <!-- 头部 start -->
3
+  <div class="pharmacy-header">
4
+   <div class="pharmacy-logo">
5
+		<h2 class="pharmacy-name__title">
6
+			<span>病理科</span>
7
+		</h2>
8
+    </div>
9
+    <div class="pharmacy-name">
10
+			<div class="mar-ri-30">
11
+				今日接收:
12
+				申请单 <span class="weight">50</span> &nbsp;
13
+				标本 <span class="weight">50</span>&nbsp;
14
+				送出 <span class="weight">50</span>&nbsp;
15
+				速冻 <span class="weight">50</span>&nbsp;
16
+			</div>
17
+      <div class="pharmacy-name__total">
18
+				<nz-input-group nzSize="large">
19
+					<input type="text" id="Binput" (ngModelChange)="specimenCodeChange($event)" [(ngModel)]="barCode" nz-input placeholder="可扫描物理标本条码及包码" />
20
+				</nz-input-group>
21
+      </div>
22
+			<div class="error-class">{{errorcODEMsg}}</div>
23
+    </div>
24
+    <div class="userInfo">
25
+      <div class="wel">欢迎您:</div>
26
+      <div class="user">
27
+        <img src="../../assets/images/icon_keshi.png" alt="" />
28
+        <span *ngIf="deptDisplay">{{
29
+          deptDisplay == 2 ? loginUser.dept.deptalias : loginUser.dept.dept
30
+        }}</span>
31
+      </div>
32
+      <div class="userInfo-wrap">
33
+        <div class="logOut" (click)="changeKsNow()">切换科室</div>
34
+        <div class="logOut" (click)="logOut()">退出</div>
35
+      </div>
36
+    </div>
37
+  </div>
38
+	<div class="tabs">
39
+		<div class="tabs-item">
40
+			<div class="tabs-item-item" [ngClass]="{'activeClass': activeIndex == 0}" (click)="tabClick(0)">交接本</div>
41
+			<div class="tabs-item-item" [ngClass]="{'activeClass': activeIndex == 1}" (click)="tabClick(1)">实时术中快速<span class="red">(13)</span></div>
42
+			<div class="tabs-item-item" [ngClass]="{'activeClass': activeIndex == 2}" (click)="tabClick(2)">打包配送</div>
43
+		</div>
44
+		<div class="tabs-btn">
45
+			<button class="btn default" nzSize="small" (click)='connect()'>交接</button>
46
+			<button class="btn default" nzSize="small" (click)='packaging()'>打包</button>
47
+		</div>
48
+	</div>
49
+  <!-- 头部 end -->
50
+  <div class="pharmacy-main">
51
+    <div *ngIf="activeIndex==0" class="list-template pharmacy-main__list pharmacy-main__print">
52
+			<div class="list-template__content">
53
+			  <div class="list-template__top" nz-row>
54
+			    <div nz-col nzLg='18' class="list-template__searchBox">
55
+			      <div class="list-template__searchItem">
56
+			        <span class="label">接收时间:</span>
57
+			        <nz-range-picker [(ngModel)]="acceptTime" nzFormat="yyyy-MM-dd HH:mm:ss"
58
+							(ngModelChange)="changeDate($event)"></nz-range-picker>
59
+			      </div>
60
+						<div class="list-template__searchItem">
61
+						  <span class="label">配送人:</span>
62
+							<nz-select class="formItem" (nzOnSearch)="changeUserInp($event)"
63
+							  [nzDropdownMatchSelectWidth]="false" nzServerSearch nzShowSearch nzAllowClear nzPlaceHolder="请选择配送人"
64
+							  [(ngModel)]="deliveryUser">
65
+							  <ng-container *ngFor="let option of userData">
66
+							    <nz-option *ngIf="!isLoading" [nzLabel]="option.name" [nzValue]="option.id"></nz-option>
67
+							  </ng-container>
68
+							  <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
69
+							    <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
70
+							  </nz-option>
71
+							</nz-select>
72
+						</div>
73
+						<div class="list-template__searchItem">
74
+						  <span class="label">术中快速:</span>
75
+							<nz-radio-group [(ngModel)]="intraoperativeRapidity">
76
+								<label nz-radio nzValue="1"></label>
77
+								<label nz-radio nzValue="0"></label>
78
+							</nz-radio-group>
79
+						</div>
80
+			    </div>
81
+			    <div nz-col nzLg="6" class="list-template__btns">
82
+			      <button class="btn default" (click)='search()'>搜索</button>
83
+			      <button class="btn default ml8" (click)='reset()'>重置</button>
84
+			    </div>
85
+			  </div>
86
+			  <div class="list-template__bottom">
87
+			    <nz-table class="list-template__nzTable" [nzData]="listOneData" nzSize="middle" [nzShowPagination]="false"
88
+			      [nzLoading]="loading1">
89
+			      <thead>
90
+			        <tr class="thead">
91
+			          <th>申请单号</th>
92
+			          <th>患者姓名</th>
93
+			          <th>住院号</th>
94
+			          <th>部位</th>
95
+			          <th>标本数</th>
96
+			          <th>申请科室</th>
97
+			          <th>配送人</th>
98
+			          <th>接收人</th>
99
+								<th>接收时间</th>
100
+			          <th>操作</th>
101
+			        </tr>
102
+			      </thead>
103
+			      <tbody>
104
+			        <tr *ngFor="let data of listOneData">
105
+			          <td><span style="color: red;"></span>{{ data.applyCode || '-' }}</td>
106
+								<td>{{ data.patientDTO.patientName || '-' }}</td>
107
+			          <td>{{ data.residenceNo}}</td>
108
+			          <td>{{ data.takePart}}</td>
109
+			          <td>{{ data.specimenNum}}</td>
110
+			          <td>{{ data.drugNum || '0'}}</td>
111
+								<td>{{ data.cartonNum || '0' }}</td>
112
+								<td>{{ data.totalPrice || '0' }}</td>
113
+								<td>{{ data.time|date:'yyyy-MM-dd HH:mm'  }}</td>
114
+			          <td>
115
+			            <div class="coop">
116
+										<span (click)="oneLook($event,data)">查看</span>
117
+			            </div>
118
+			          </td>
119
+			        </tr>
120
+			      </tbody>
121
+			    </nz-table>
122
+			    <div class="list-template__pagination">
123
+			      <nz-pagination [(nzPageIndex)]="pageOneIndex" [(nzTotal)]="listOneLength" nzShowSizeChanger [(nzPageSize)]="pageSize"
124
+			        (nzPageIndexChange)="getConnectList()" (nzPageSizeChange)="getConnectList()">
125
+			      </nz-pagination>
126
+			    </div>
127
+			  </div>
128
+			</div>
129
+    </div>
130
+
131
+    <div class="pharmacy-main__list pharmacy-main__waitDelivery">
132
+      <div *ngIf="activeIndex==1" class="list-template pharmacy-main__list pharmacy-main__print">
133
+      	<div class="list-template__content">
134
+      	  <div class="list-template__bottom">
135
+      	    <nz-table class="list-template__nzTable" [nzData]="listTwoData" nzSize="middle" [nzShowPagination]="false"
136
+      	      [nzLoading]="loading2">
137
+      	      <thead>
138
+      	        <tr class="thead">
139
+      	          <th>申请单号</th>
140
+      	          <th>患者姓名</th>
141
+      	          <th>住院号</th>
142
+      	          <th>部位</th>
143
+      	          <th>标本数</th>
144
+      	          <th>申请科室</th>
145
+      	          <th>配送人</th>
146
+      	          <th>状态</th>
147
+      	          <th>操作</th>
148
+      	        </tr>
149
+      	      </thead>
150
+      	      <tbody>
151
+      	        <tr *ngFor="let data of listTwoData">
152
+      	          <td><span style="color: red;"></span>{{ data.applyCode || '-' }}</td>
153
+      	          <td>{{ data.patientDTO.patientName || '-' }}</td>
154
+      	          <td>{{ data.residenceNo}}</td>
155
+      	          <td>{{ data.takePart}}</td>
156
+      	          <td>{{ data.specimenNum}}</td>
157
+      	          <td>{{ data.drugNum || '0'}}</td>
158
+      	          <td>{{ data.cartonNum || '0' }}</td>
159
+      	          <td>{{ data.totalPrice || '0' }}</td>
160
+      	          <td>
161
+      	            <div class="coop">
162
+      								<span (click)="oneLook($event,data)">查看</span>
163
+      	            </div>
164
+      	          </td>
165
+      	        </tr>
166
+      	      </tbody>
167
+      	    </nz-table>
168
+      	    <div class="list-template__pagination">
169
+      	      <nz-pagination [(nzPageIndex)]="pageTwoIndex" [(nzTotal)]="listTwoLength" nzShowSizeChanger [(nzPageSize)]="pageSize"
170
+      	        (nzPageIndexChange)="getSpeedinessList()" (nzPageSizeChange)="getSpeedinessList()">
171
+      	      </nz-pagination>
172
+      	    </div>
173
+      	  </div>
174
+      	</div>
175
+      </div>
176
+    </div>
177
+
178
+    <div class="pharmacy-main__list pharmacy-main__delivery">
179
+			<div *ngIf="activeIndex==2" class="list-template pharmacy-main__list pharmacy-main__print">
180
+				<div class="list-template__content">
181
+				  <div class="list-template__bottom">
182
+				    <nz-table class="list-template__nzTable" [nzData]="listThreeData" nzSize="middle" [nzShowPagination]="false"
183
+				      [nzLoading]="loading3">
184
+				      <thead>
185
+				        <tr class="thead">
186
+				          <th>包号</th>
187
+				          <th>打包人 | 打包时间</th>
188
+				          <th>申请单数</th>
189
+				          <th>标本数</th>
190
+									<th>配送人 | 配送时间</th>
191
+									<th>接收人 | 接收时间</th>
192
+				          <th>状态</th>
193
+				          <th>操作</th>
194
+				        </tr>
195
+				      </thead>
196
+				      <tbody>
197
+				        <tr *ngFor="let data of listThreeData">
198
+				          <td>{{ data.batchNo || '-' }}</td>
199
+									<td>
200
+										<div>{{data.batchNo }}</div>
201
+										<div>{{data.batchNo }}</div>
202
+									</td>
203
+				          <td>{{ data.createTime|date:'yyyy-MM-dd HH:mm' }}</td>
204
+				          <td>{{ data.pharmacyDTO?data.pharmacyDTO.dept:'-' }}</td>
205
+				          <td>
206
+				          	<div>{{data.batchNo }}</div>
207
+				          	<div>{{data.batchNo }}</div>
208
+				          </td>
209
+				          <td>
210
+				          	<div>{{data.batchNo }}</div>
211
+				          	<div>{{data.batchNo }}</div>
212
+				          </td>
213
+									<td>{{ data.batchState?data.batchState.name : '-' }}</td>
214
+				          <td>
215
+				            <div class="coop">
216
+											<span (click)="oneLook($event,data)">查看</span>
217
+				            </div>
218
+				          </td>
219
+				        </tr>
220
+				      </tbody>
221
+				    </nz-table>
222
+				    <div class="list-template__pagination">
223
+				      <nz-pagination [(nzPageIndex)]="pageThreeIndex" [(nzTotal)]="listThreeLength" nzShowSizeChanger [(nzPageSize)]="pageSize"
224
+				        (nzPageIndexChange)="getPackList()" (nzPageSizeChange)="getPackList()">
225
+				      </nz-pagination>
226
+				    </div>
227
+				  </div>
228
+				</div>
229
+			</div>
230
+    </div>
231
+  </div>
232
+  <!-- 主体部分 end -->
233
+  <router-outlet></router-outlet>
234
+</div>
235
+
236
+<!-- 科室切换提示框 -->
237
+<app-hs-prompt-modal
238
+  [changeShow]="changeShow"
239
+  [closeTime]="closeTime"
240
+  [closeTimeFlag]="closeTimeFlag"
241
+  [show]="hsPromptModalShow"
242
+  (closeModelHs)="closeModelHs($event)"
243
+  (clearModelHs)="clearModelHs($event)"
244
+  deptType="nurse"
245
+> 
246
+  <!-- 返回系统按钮 -->
247
+  <!-- 右侧悬浮框 -->
248
+   <div id="fixedMenu" class="fixed" *ngIf="mainRole">
249
+    <div class="right">
250
+      <div class="fixedMenu hujiaozhongxin">
251
+        <div class="menuItems">
252
+          <div class="item">快捷菜单</div>
253
+        </div>
254
+      </div>
255
+      <div class="fixedMenu">
256
+        <div class="menuItems">
257
+          <div
258
+            class="others"
259
+            [ngStyle]="{
260
+              height: showLastItems
261
+                ? mainRole
262
+                  ? 35 * 2 + 'px'
263
+                  : 35 * 1 + 'px'
264
+                : 0
265
+            }"
266
+          >
267
+            <div
268
+              [ngClass]="{ item: true, checked: fixedTab == 'back' }"
269
+              *ngIf="mainRole"
270
+              (click)="checkFixedTab('toSystem')"
271
+            >
272
+              返回系统
273
+            </div>
274
+          </div>
275
+        </div>
276
+        <div class="arrow" *ngIf="!showLastItems" (click)="fixedMenuXiala()">
277
+          <i class="icon_transport transport-xiala2-01"></i>
278
+        </div>
279
+        <div class="arrow" *ngIf="showLastItems" (click)="fixedMenuShangla()">
280
+          <i class="icon_transport transport-shangla-"></i>
281
+        </div>
282
+      </div>
283
+    </div>
284
+    <div
285
+      *ngIf="showLastItems && fixedTab != ''"
286
+      (click)="fixedMenuShangla()"
287
+      class="fixedMark"
288
+    ></div>
289
+  </div>
290
+</app-hs-prompt-modal>
291
+
292
+
293
+<!-- 关联标本/手术室 -->
294
+<div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="relevanceModal">
295
+	<div class="modalBody">
296
+		<div class="title">关联科室</div>
297
+		<overlay-scrollbars #osComponentRef1 class="content">
298
+		 <form nz-form [formGroup]="validateForm" class="addForm" (ngSubmit)="submitForm()">
299
+			<nz-form-item>
300
+				<nz-form-label nzRequired nzFor="specimen" [nzSm]="5" [nzXs]="24">关联标本间</nz-form-label>
301
+				<nz-form-control nzErrorTip="请选择标本间!" [nzSm]="19" [nzXs]="24">
302
+					<nz-input-group>
303
+						<nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择标本间" formControlName="specimen">
304
+							<ng-container *ngFor="let option of specimenData">
305
+								<nz-option [nzLabel]="option.dept" [nzValue]="option.id"></nz-option>
306
+							</ng-container>
307
+						</nz-select>
308
+					</nz-input-group>
309
+				</nz-form-control>
310
+			</nz-form-item>
311
+			
312
+			<nz-form-item>
313
+				<nz-form-label nzRequired nzFor="operation" [nzSm]="5" [nzXs]="24">关联手术间</nz-form-label>
314
+				<nz-form-control nzErrorTip="请选择手术间!" [nzSm]="19" [nzXs]="24">
315
+					<nz-input-group>
316
+						<nz-select class="formItem" nzMode="multiple" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择请选择手术间" formControlName="operation">
317
+							<ng-container *ngFor="let option of operationData">
318
+								<nz-option [nzLabel]="option.dept" [nzValue]="option.id"></nz-option>
319
+							</ng-container>
320
+						</nz-select>
321
+					</nz-input-group>
322
+				</nz-form-control>
323
+			</nz-form-item>
324
+			
325
+			<nz-form-item>
326
+				<nz-form-label nzRequired nzFor="generate">标本是否直接生成配送单</nz-form-label>
327
+				<nz-form-control nzErrorTip="请选择!">
328
+					<nz-radio-group formControlName="generate">
329
+						<label nz-radio [nzValue]="1"></label>
330
+						<label nz-radio [nzValue]="0"></label>
331
+					</nz-radio-group>
332
+				</nz-form-control>
333
+			</nz-form-item>
334
+		 </form>
335
+		</overlay-scrollbars>
336
+		<div class="display_flex justify-content_flex-center">
337
+			<button class="btn" nz-button nzType="primary" (click)="submitForm()" [nzLoading]="btnLoading">确定</button>
338
+		</div>
339
+	</div>
340
+</div>
341
+
342
+
343
+<!-- 标本接收 -->
344
+<div class="pathology-box display_flex align-items_center justify-content_flex-center" *ngIf="fixationModal">
345
+	<div class="pathology-content">
346
+		<div class="title">标本接收
347
+		<i class="icon_transport transport-guanbi" (click)="hideSpecimenModal()"></i></div>
348
+		<div class="content">
349
+			<div class="content-item">
350
+				<!-- <div class="center">提示:申请单含<span class="red">{{codeData.specimenNum}}</span>只标本,已扫<span class="red">{{codeData.pathologySpecimenDTOList.length}}</span>只<span *ngIf="codeData.pathologySpecimenDTOList.length < codeData.specimenNum">,请继续扫描标本。</span></div> -->
351
+				<div class="disp-fl">
352
+					<div class="disp-title">
353
+						接收申请单数: <span class="weight">50</span>  &nbsp;
354
+						接收标本数: <span class="weight">50</span>  
355
+					</div>
356
+					<div>
357
+						<!-- <div class="width-120">标本条码:</div> -->
358
+						<input nz-input id="specimen" placeholder="可扫描物理标本条码及包码" [(ngModel)]="specimenCode" (ngModelChange)="codeChange($event)"/>
359
+					</div>
360
+					<div class="error-class">{{errorMsg}}</div>
361
+				</div>
362
+				<div class="list-template">
363
+				  <div class="list-template__content">
364
+						<div class="list-template__bottom" style="padding: 0 !important;">
365
+							<nz-table class="list-template__nzTable" [nzData]="codeData" nzSize="middle" [nzShowPagination]="false"
366
+								[nzLoading]="tableLoading">
367
+								<thead>
368
+									<tr class="thead">
369
+										<th>申请单号 | 申请科室</th>
370
+										<th>患者姓名 | 住院号</th>
371
+										<th>标本数</th>
372
+										<th>部位</th>
373
+										<th>标本名称</th>
374
+									</tr>
375
+								</thead>
376
+								<tbody>
377
+									<tr *ngFor="let data of codeData let index = index">
378
+										<td>
379
+											<div>{{ data.applyCode}}</div>
380
+											<div>{{ data.surgeryDeptDTO.dept}}</div>
381
+										</td>
382
+										<td>
383
+											<div>{{ data.patientDTO.patientName}}</div>
384
+											<div>{{ data.patientDTO.residenceNo}}</div>
385
+										</td>
386
+										<td>{{ data.specimenNum}}</td>
387
+										<td>{{ data.takePart}}</td>
388
+										<td>
389
+											<div *ngFor="let item of data.pathologySpecimenDTOList">
390
+												{{item.partSource?item.partSource.name:''}} <span *ngIf="item.system">-</span>
391
+												{{item.system?item.system.name:''}} <span *ngIf="item.organ">-</span>
392
+												{{item.organ?item.organ.name:''}} <span *ngIf="item.sample">-</span>
393
+												{{item.sample?item.sample.name:''}}
394
+											</div>
395
+										</td>
396
+									</tr>
397
+								</tbody>
398
+							</nz-table>
399
+						</div>
400
+					</div>
401
+				</div>
402
+			</div>
403
+		</div>
404
+		<div class="display_flex justify-content_flex-center bottom-btn">
405
+			<button class="btn btn-right" nz-button nzType="primary" (click)="submitFixationForm()" [nzLoading]="btnLoading">交接完成</button>
406
+			<!-- <button class="btn cancel" nz-button nzType="default" (click)="hideSpecimenModal()">取消</button> -->
407
+		</div>
408
+	</div>
409
+</div>
410
+
411
+
412
+<!-- 查看详情 -->
413
+<div class="pathology-box display_flex align-items_center justify-content_flex-center" *ngIf="listDetailMoadl">
414
+	<div class="pathology-content">
415
+		<div class="title">查看详情
416
+		<i class="icon_transport transport-guanbi" (click)="closeDetail()"></i></div>
417
+		<div class="content">
418
+			<div class="content-item">
419
+				<div class="list-template">
420
+				  <div class="list-template__content">
421
+						<div class="list-template__bottom" style="padding: 0 !important;">
422
+							<nz-table class="list-template__nzTable" [nzData]="codeData" nzSize="middle" [nzShowPagination]="false"
423
+								[nzLoading]="tableLoading">
424
+								<thead>
425
+									<tr class="thead">
426
+										<th>申请单号 | 申请科室</th>
427
+										<th>患者姓名 | 住院号</th>
428
+										<th>标本数</th>
429
+										<th>部位</th>
430
+										<th>标本名称</th>
431
+									</tr>
432
+								</thead>
433
+								<tbody>
434
+									<tr *ngFor="let data of codeData let index = index">
435
+										<td>
436
+											<div>{{ data.applyCode}}</div>
437
+											<div>{{ data.surgeryDeptDTO.dept}}</div>
438
+										</td>
439
+										<td>
440
+											<div>{{ data.patientDTO.patientName}}</div>
441
+											<div>{{ data.patientDTO.residenceNo}}</div>
442
+										</td>
443
+										<td>{{ data.specimenNum}}</td>
444
+										<td>{{ data.takePart}}</td>
445
+										<td>
446
+											<div *ngFor="let item of data.pathologySpecimenDTOList">
447
+												{{item.partSource?item.partSource.name:''}} <span *ngIf="item.system">-</span>
448
+												{{item.system?item.system.name:''}} <span *ngIf="item.organ">-</span>
449
+												{{item.organ?item.organ.name:''}} <span *ngIf="item.sample">-</span>
450
+												{{item.sample?item.sample.name:''}}
451
+											</div>
452
+										</td>
453
+									</tr>
454
+								</tbody>
455
+							</nz-table>
456
+						</div>
457
+					</div>
458
+				</div>
459
+			</div>
460
+		</div>
461
+		<div class="display_flex justify-content_flex-center bottom-btn">
462
+			<button class="btn btn-right" nz-button nzType="primary" (click)="closeDetail()">知道了</button>
463
+		</div>
464
+	</div>
465
+</div>
466
+
467
+
468
+<!-- 操作成功/失败提示框 -->
469
+<app-prompt-modal *ngIf="promptModalShow" [content]="promptContent" [success]="ifSuccess" [show]="promptModalShow"
470
+  [info]="promptInfo" (closeModel)="closeModel()"></app-prompt-modal>
471
+	
472
+<!-- 标本固定信息 -->
473
+<div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="verificationMoadl">
474
+	<div class="modalBody no-width">
475
+		<div class="title">标本固定信息<i class="icon_transport transport-guanbi" (click)="hideVerificationModal()"></i>
476
+		</div>
477
+		<div class="content">
478
+			<form nz-form [formGroup]="validateVerificationForm" class="addForm" (ngSubmit)="submitVerificationForm()">
479
+				<nz-form-item>
480
+				  <nz-form-label nzRequired [nzSpan]="6" nzFor="fixationTime">固定时间</nz-form-label>
481
+				  <nz-form-control [nzSpan]="18" nzErrorTip="请选择固定时间!">
482
+				    <nz-input-group>
483
+							<nz-date-picker formControlName="fixationTime" 
484
+							[nzShowTime]="{ nzFormat: 'yyyy-MM-dd HH:mm:ss' }" nzFormat="yyyy-MM-dd HH:mm:ss"
485
+							(ngModelChange)="formChangeDate($event)"></nz-date-picker>
486
+						</nz-input-group>
487
+				  </nz-form-control>
488
+				</nz-form-item>
489
+				<nz-form-item>
490
+				  <nz-form-label nzRequired [nzSpan]="6" nzFor="jobNumber">工号</nz-form-label>
491
+					<nz-form-control [nzSpan]="18" nzErrorTip="请输入工号!">
492
+						<input nz-input (ngModelChange)="numberChange($event)" formControlName="jobNumber" placeholder="请输入工号" nzSize="default" />
493
+					</nz-form-control>
494
+				</nz-form-item>
495
+				<nz-form-item>
496
+				  <nz-form-label nzRequired [nzSpan]="6" nzFor="name">姓名</nz-form-label>
497
+					<nz-form-control [nzSpan]="18" nzErrorTip="请输入姓名!">
498
+						<input nz-input disabled formControlName="name" placeholder="请输入姓名" nzSize="default" />
499
+					</nz-form-control>
500
+				</nz-form-item>
501
+				<nz-form-item>
502
+				  <nz-form-label nzRequired [nzSpan]="8" nzFor="fixative">固体液类型</nz-form-label>
503
+				  <nz-form-control [nzSpan]="16" nzErrorTip="请选择固体液类型!">
504
+				    <nz-input-group>
505
+							<nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择固体液类型" formControlName="fixative">
506
+							  <ng-container *ngFor="let option of fixativeData">
507
+							    <nz-option [nzLabel]="option.name" [nzValue]="option.id"></nz-option>
508
+							  </ng-container>
509
+							</nz-select>
510
+						</nz-input-group>
511
+				  </nz-form-control>
512
+				</nz-form-item>
513
+			</form>
514
+		</div>
515
+		<div class="display_flex justify-content_flex-center bottom-btn">
516
+			<button class="btn btn-right" nz-button nzType="primary" (click)="submitVerificationForm()" [nzLoading]="btnInfoLoading">确定</button>
517
+			<button class="btn cancel" nz-button nzType="default" (click)="hideVerificationModal()">取消</button>
518
+		</div>
519
+	</div>
520
+</div>
521
+
522
+<!-- 标本查看详情-->
523
+<div class="pathology-box display_flex align-items_center justify-content_flex-center" *ngIf="detailMoadl">
524
+	<div class="pathology-content">
525
+		<div class="title">查看详情
526
+		<i class="icon_transport transport-guanbi" (click)="closeDetailMoadl()"></i></div>
527
+		<div class="content">
528
+			<div class="content-item boder-right">
529
+				<div class="form-title-box">
530
+					<div class="form-title"><span class="font-weight-500">是否术中快速:</span>{{detailsData.intraoperativeRapidity==1?'是':'否'}}</div>
531
+					<div class="form-title"><span class="font-weight-500">申请单编号:</span>{{detailsData.applyCode}}</div>
532
+					<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status.name}}</div>
533
+					<div class="form-title"><span class="font-weight-500">科室名称:</span>{{detailsData.patientDTO.department.dept}}</div>
534
+				</div>
535
+				<div class="form-title-box">
536
+					<div class="form-title"><span class="font-weight-500">住院号:</span>{{detailsData.patientDTO.patientCode}}</div>
537
+					<div class="form-title"><span class="font-weight-500">患者信息:</span>{{detailsData.patientDTO.patientName}} ({{detailsData.patientDTO.bedNum}}床)</div>
538
+					<div class="form-title"><span class="font-weight-500">年龄:</span>{{detailsData.patientDTO.age||'-'}}岁</div>
539
+				</div>
540
+				
541
+				<div class="form-title-box">
542
+					<div class="form-title"><span class="font-weight-500">检验项目:</span>{{project||'无'}}</div>
543
+				</div>
544
+				
545
+				<div class="form-list">
546
+					<div class="form-title font-weight-500">诊断:</div>
547
+					<div class="indent">
548
+						{{detailsData.diagnose||'无'}}
549
+					</div>
550
+				</div>
551
+				
552
+				<div class="form-list">
553
+					<div class="form-title font-weight-500">病理摘要:</div>
554
+					<div class="indent">{{detailsData.medicalRecords||'无'}}</div>
555
+				</div>
556
+				<div class="form-list">
557
+					<div class="form-title font-weight-500">手术方案:</div>
558
+					<div class="indent">{{detailsData.surgicalPlan||'无'}}</div>
559
+				</div>
560
+				<div class="form-list">
561
+					<div class="form-title font-weight-500">术中所见:</div>
562
+					<div class="indent">{{detailsData.intraoperativeFindings||'无'}}</div>
563
+				</div>
564
+
565
+				<div class="form-title-box">
566
+					<div class="form-title"><span class="font-weight-500">标本类型:</span>{{detailsData.specimenType.name||'无'}}</div>
567
+					<div class="form-title"><span class="font-weight-500">标本件数:</span>{{detailsData.specimenNum||'无'}}</div>
568
+					<div class="form-title"><span class="font-weight-500">采取部位:</span>{{detailsData.takePart||'无'}}</div>
569
+				</div>
570
+				
571
+				<div class="form-title-box">
572
+					<div class="form-title"><span class="font-weight-500">送检医生:</span>{{detailsData.surgeryDoctorDTO?detailsData.surgeryDoctorDTO.name : '-'}}</div>
573
+					<div class="form-title"><span class="font-weight-500">离体时间:</span>{{detailsData.inVitroTime?(detailsData.inVitroTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
574
+					<div class="form-title"><span class="font-weight-500">固定时间:</span>{{detailsData.fixationTime?(detailsData.fixationTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
575
+				</div>
576
+				
577
+				<div class="form-list">
578
+					<div class="form-title font-weight-500">标本:</div>
579
+					<div class="form-title specimen-list">
580
+						<div *ngFor="let item of specimenList" class="specimen-item-class">
581
+							{{item.partSource?item.partSource.name:''}} <span *ngIf="item.system">-</span>
582
+							{{item.system?item.system.name:''}} <span *ngIf="item.organ">-</span>
583
+							{{item.organ?item.organ.name:''}} <span *ngIf="item.sample">-</span>
584
+							{{item.sample?item.sample.name:''}}
585
+						</div>
586
+					</div>
587
+				</div>
588
+
589
+			</div>
590
+			
591
+			<div class="content-item-right">
592
+				<div class="step-title">病理闭环</div>
593
+				<nz-steps [nzCurrent]="stepLength" nzDirection="vertical" nzSize="small">
594
+					<ng-container *ngFor="let item of pathologyLogs; let index = index">
595
+							<nz-step
596
+								[nzDescription]="tpl"
597
+							>
598
+							</nz-step>
599
+							<ng-template #tpl>
600
+								<div *ngIf="index==pathologyLogs.length-1" class="step-size">
601
+									<div style="color: #49B856;">{{item.operationType.name}}</div>
602
+									<div style="color:#333;">{{item.createTime|date:'yyyy-MM-dd HH:mm:ss'}} {{item.operationUserDto.name}}</div>
603
+								</div>
604
+								<div *ngIf="index!=pathologyLogs.length-1" class="step-size">
605
+									<div>{{item.operationType.name}}</div>
606
+									<div>{{item.createTime|date:'yyyy-MM-dd HH:mm:ss'}} {{item.operationUserDto.name}}</div>
607
+								</div>
608
+							</ng-template>
609
+						</ng-container>
610
+				</nz-steps>
611
+			</div>
612
+		</div>
613
+		<div class="display_flex justify-content_flex-center bottom-btn">
614
+			<button class="btn btn-right" nz-button nzType="primary" (click)="closeDetailMoadl()">确定</button>
615
+			<button class="btn cancel" nz-button nzType="default" (click)="closeDetailMoadl()">取消</button>
616
+		</div>
617
+	</div>
618
+</div>
619
+
620
+<div class="mask-style" *ngIf="isSpinning">
621
+	<nz-spin nzSimple class="spin-style"></nz-spin>
622
+</div>

+ 850 - 0
src/app/views/pathology/pathology.component.less

@@ -0,0 +1,850 @@
1
+@import "../../../../src/theme.less";
2
+:host {
3
+  width: 100%;
4
+  background-color: #f9fafb;
5
+  .ant-btn[disabled] {
6
+    color: rgba(0, 0, 0, 0.25) !important;
7
+    background-color: #f5f5f5 !important;
8
+  }
9
+  .red {
10
+    color: red !important;
11
+    font-weight: bold !important;
12
+  }
13
+  .green {
14
+    color: @primary-color!important;
15
+    font-weight: bold !important;
16
+  }
17
+
18
+  h1,
19
+  h2,
20
+  h3,
21
+  p {
22
+    margin: 0;
23
+  }
24
+  em {
25
+    font-style: normal;
26
+  }
27
+	
28
+	
29
+	/* 修改垂直滚动条 */
30
+	::-webkit-scrollbar {
31
+		width: 4px; /* 修改宽度 */
32
+		border-radius: 2px;
33
+	}
34
+	 
35
+	/* 修改滚动条轨道背景色 */
36
+	::-webkit-scrollbar-track {
37
+		background-color: #f1f1f1;
38
+	}
39
+	 
40
+	/* 修改滚动条滑块颜色 */
41
+	::-webkit-scrollbar-thumb {
42
+		background-color: #888;
43
+	}
44
+	 
45
+	/* 修改滚动条滑块悬停时的颜色 */
46
+	::-webkit-scrollbar-thumb:hover {
47
+		background-color: #555;
48
+	}
49
+	
50
+  .pharmacy {
51
+    display: flex;
52
+    flex-direction: column;
53
+    height: 100%;
54
+  }
55
+
56
+  // 头部 start
57
+  .pharmacy-header {
58
+    // height: 88px;
59
+    background-color: #fff;
60
+    border-bottom: 1px solid #e5e9ed;
61
+    box-sizing: border-box;
62
+    display: flex;
63
+		color: #000;
64
+    .pharmacy-logo {
65
+      width: 100px;
66
+      background-color: #fff;
67
+      display: flex;
68
+      flex-direction: column;
69
+      justify-content: center;
70
+      align-items: center;
71
+			font-weight: bold;
72
+      .pharmacy-logo__img {
73
+        max-width: 100%;
74
+        max-height: 50%;
75
+      }
76
+
77
+      .pharmacy-logo__name {
78
+        font-size: 14px;
79
+        color: @primary-color;
80
+        margin-top: 8px;
81
+      }
82
+    }
83
+
84
+    .pharmacy-name {
85
+      // flex: 1;
86
+      // border-right: 1px solid #e5e9ed;
87
+      display: flex;
88
+      // justify-content: space-between;
89
+      align-items: center;
90
+			width: 70%;
91
+			justify-content: center;
92
+			.mar-ri-30{
93
+				margin-right: 30px;
94
+			}
95
+			.weight{
96
+				font-weight: bold;
97
+			}
98
+      .pharmacy-name__title {
99
+        font-size: 22px;
100
+        color: #333;
101
+        margin-left: 43px;
102
+        line-height: 87px;
103
+        .currentDate {
104
+          margin-left: 24px;
105
+          font-size: 16px;
106
+        }
107
+      }
108
+      .pharmacy-name__total {
109
+        width: 250px;
110
+        font-size: 16px;
111
+				display: flex;
112
+				.pharmacy-title{
113
+					width: 160px;
114
+					font-weight: 600;
115
+					font-size: 22px;
116
+				}
117
+      }
118
+			.error-class{
119
+				color: red;
120
+				margin-left: 10px;
121
+			}
122
+    }
123
+
124
+    .pharmacy-operate {
125
+      width: 211px;
126
+      display: flex;
127
+      justify-content: center;
128
+      align-items: center;
129
+      position: relative;
130
+      .pharmacy-operatePop {
131
+        cursor: pointer;
132
+        border: 1px solid #e5e9ed;
133
+        background-color: #fff;
134
+        position: absolute;
135
+        left: 0;
136
+        top: 100%;
137
+        width: 100%;
138
+        height: 34px;
139
+        line-height: 34px;
140
+        text-align: center;
141
+        font-size: 14px;
142
+        color: @primary-color;
143
+      }
144
+
145
+      &:after {
146
+        content: "";
147
+        display: block;
148
+        width: 0;
149
+        height: 0;
150
+        border-left: 7px solid transparent;
151
+        border-right: 7px solid transparent;
152
+        border-top: 10px solid #666;
153
+      }
154
+
155
+      .pharmacy-operate__img {
156
+        max-height: 40px;
157
+        margin-right: 8px;
158
+      }
159
+
160
+      .pharmacy-operate__title {
161
+        font-size: 20px;
162
+        color: #666;
163
+        padding-right: 24px;
164
+        cursor: pointer;
165
+      }
166
+    }
167
+  }
168
+	.tabs{
169
+		display: flex;
170
+		justify-content: space-between;
171
+		font-size: 14px;
172
+		background: #fff;
173
+		border-bottom: 1px solid #e5e9ed;
174
+		margin-right: 13px;
175
+		.tabs-item{
176
+			display: flex;
177
+			align-items: center;
178
+			.tabs-item-item{
179
+				padding: 15px 20px;
180
+				border-bottom: 2px solid #f9fafb;
181
+				cursor: pointer;
182
+			}
183
+			.red{
184
+				color: red;
185
+			}
186
+			.activeClass{
187
+				color: #64BD7B;
188
+				border-bottom: 2px solid #64BD7B;
189
+			}
190
+		}
191
+		.tabs-btn{
192
+			display: flex;
193
+			align-items: center;
194
+			.btn{
195
+				margin-left: 10px;
196
+			}
197
+		}
198
+	}
199
+	
200
+  .userInfo {
201
+    // display: none;
202
+    width: 336px;
203
+    // height: 100%;
204
+    // float: right;
205
+    padding: 8px;
206
+    box-sizing: border-box;
207
+    font-size: 14px;
208
+    // border-left: 1px solid #e5e9ed;
209
+
210
+    .wel {
211
+      line-height: 15px;
212
+    }
213
+
214
+    .user {
215
+      font-size: 20px;
216
+      height: 36px;
217
+      display: flex;
218
+      justify-content: center;
219
+      align-items: center;
220
+      line-height: normal;
221
+
222
+      img {
223
+        height: 100%;
224
+        margin-right: 8px;
225
+      }
226
+    }
227
+    .userInfo-wrap {
228
+      display: flex;
229
+      justify-content: flex-end;
230
+      .logOut {
231
+        display: inline-block;
232
+        text-align: right;
233
+        color: @primary-color;
234
+        line-height: 20px;
235
+        cursor: pointer;
236
+        margin-right: 8px;
237
+      }
238
+    }
239
+  }
240
+  // 头部 end
241
+  // 主体部分 start
242
+  .pharmacy-main {
243
+    .pharmacy-main__list {
244
+      display: flex;
245
+      flex-direction: column;
246
+      background-color: #fff;
247
+      margin: 0 4px;
248
+      box-sizing: border-box;
249
+      // 标题 start
250
+      .pharmacy-main__title {
251
+        height: 40px;
252
+        background-color: #fff;
253
+        font-size: 16px;
254
+        color: #333;
255
+        font-weight: 700;
256
+        padding-left: 8px;
257
+        display: flex;
258
+        justify-content: space-between;
259
+        align-items: center;
260
+        border-bottom: 1px solid #e5e9ed;
261
+        .autoUpdate {
262
+          font-size: 14px;
263
+          color: #49b856;
264
+          margin-right: 8px;
265
+        }
266
+        .pharmacy-main__printAll {
267
+          // width: 80px;
268
+          height: 28px;
269
+          line-height: 28px;
270
+          margin-right: 16px;
271
+          background-color: @primary-color;
272
+          font-size: 14px;
273
+          color: #fff;
274
+          border-radius: 4px;
275
+          text-align: center;
276
+          display: flex;
277
+          justify-content: center;
278
+        }
279
+      }
280
+      // 标题 end
281
+      // 搜索框 start
282
+      .pharmacy-main__search {
283
+        padding: 8px;
284
+        position: relative;
285
+				border-bottom: 1px solid #e5e9ed;
286
+        .pharmacy-main__searchInput {
287
+          border-radius: 100px;
288
+          padding-right: 82px;
289
+          border: 1px solid #e5e9ed;
290
+          background-color: #fff;
291
+          overflow: hidden;
292
+          input {
293
+            border: none;
294
+          }
295
+          .ant-input:focus {
296
+            border-color: #fff;
297
+            outline: 0;
298
+            box-shadow: 0 0 0 2px #fff;
299
+          }
300
+          .pharmacy-main__searchText {
301
+            cursor: pointer;
302
+            position: absolute;
303
+            top: 13px;
304
+            right: 8px;
305
+            width: 74px;
306
+            height: 22px;
307
+            border-left: 1px solid #e5e9ed;
308
+            color: #999;
309
+            padding-left: 8px;
310
+            box-sizing: border-box;
311
+            span {
312
+              color: @primary-color;
313
+              margin-left: 8px;
314
+            }
315
+          }
316
+        }
317
+      }
318
+      // 搜索框 end
319
+      // 列表 start
320
+      .pharmacy-main__selectionWrap {
321
+        flex: 1;
322
+        // height: 630px;
323
+        overflow: auto;
324
+        &:first-child {
325
+          border-top: 1px solid #e5e9ed;
326
+        }
327
+        .pharmacy-main__selection {
328
+          box-sizing: border-box;
329
+          border-bottom: 1px solid #e5e9ed;
330
+          display: flex;
331
+          cursor: pointer;
332
+          &.noPointer{
333
+            cursor: pointer;
334
+          }
335
+          &.pharmacy-main__selection--more {
336
+            color: @primary-color;
337
+            height: 34px;
338
+            cursor: pointer;
339
+            .pharmacy-main__selectionInfo {
340
+              justify-content: center;
341
+              align-items: center;
342
+              flex-direction: row;
343
+              .pharmacy-main__selection--icon {
344
+                margin-right: 8px;
345
+              }
346
+            }
347
+          }
348
+          &.pharmacy-main__selection--noData {
349
+            height: calc(100vh - 212px);
350
+            min-height: 556px;
351
+            display: flex;
352
+            justify-content: center;
353
+            align-items: center;
354
+            img {
355
+              width: 100px;
356
+            }
357
+          }
358
+          .pharmacy-main__selectionInfo {
359
+            padding: 8px;
360
+            flex: 1;
361
+            display: flex;
362
+            flex-direction: column;
363
+            justify-content: space-between;
364
+            .pharmacy-main__selectionItem {
365
+              display: flex;
366
+              justify-content: space-between;
367
+              padding: 0 8px;
368
+							margin-bottom: 5px;
369
+							.weight{
370
+								font-weight: 500;
371
+								.sign-red{
372
+									color: red;
373
+									margin-right: 10px;
374
+								}
375
+							}
376
+              .moreContent{
377
+                width: 150px;
378
+                display: flex;
379
+                justify-content: flex-end;
380
+                text-align: justify;
381
+                &.left{
382
+                  justify-content: flex-start;
383
+                }
384
+              }
385
+              span {
386
+                color: #666;
387
+                font-size: 12px;
388
+              }
389
+              strong {
390
+                color: #333;
391
+                font-weight: 700;
392
+                font-size: 14px;
393
+              }
394
+            }
395
+          }
396
+          .pharmacy-main__selectionPrint {
397
+            width: 90px;
398
+            display: flex;
399
+            justify-content: center;
400
+            align-items: center;
401
+            border-left: 1px solid #e5e9ed;
402
+            .pharmacy-main__selectionPrintBtn {
403
+              width: 60px;
404
+              height: 28px;
405
+              line-height: 28px;
406
+              border-radius: 4px;
407
+              border: 1px solid @primary-color;
408
+              color: @primary-color;
409
+              text-align: center;
410
+              cursor: pointer;
411
+            }
412
+          }
413
+        }
414
+      }
415
+      // 列表 end
416
+    }
417
+  }
418
+  // 主体部分 end
419
+
420
+  // 右侧悬浮菜单
421
+  .fixed {
422
+    position: fixed;
423
+    top: 40%;
424
+    right: 0;
425
+    z-index: 99;
426
+    border-radius: 5px 0 0 5px;
427
+
428
+    .fixedMark {
429
+      position: fixed;
430
+      left: 0;
431
+      top: 0;
432
+      width: 100%;
433
+      height: 100%;
434
+      background: rgba(0, 0, 0, 0.2);
435
+      z-index: 88;
436
+    }
437
+
438
+    // overflow: hidden;
439
+    & > .left {
440
+      width: 480px;
441
+      // height: 280px;
442
+      float: left;
443
+      background: #fff;
444
+      padding: 16px;
445
+      border-radius: 5px;
446
+      border: 1px solid #e5e9ed;
447
+      // box-shadow: -8px 5px 15px #eae9e9;
448
+      position: relative;
449
+      z-index: 98;
450
+
451
+      .con {
452
+        background: #f9fafb;
453
+        width: 100%;
454
+        height: 100%;
455
+        border-radius: 5px;
456
+        border: 1px solid #e5e9ed;
457
+        padding: 16px 20px;
458
+
459
+        &.tableCon {
460
+          padding: 0;
461
+
462
+          .table {
463
+            font-size: 14px;
464
+
465
+            tr {
466
+              td {
467
+                padding: 15px 6px;
468
+                text-align: center;
469
+
470
+                & > .tdiv {
471
+                  overflow: hidden;
472
+
473
+                  .name {
474
+                    float: left;
475
+                  }
476
+
477
+                  .num {
478
+                    float: right;
479
+                    font-size: 12px;
480
+
481
+                    span {
482
+                      color: @primary-color;
483
+                      font-size: 14px;
484
+                    }
485
+                  }
486
+                }
487
+
488
+                .notOpen {
489
+                  color: #666;
490
+                  font-size: 12px;
491
+
492
+                  img {
493
+                    margin-bottom: 8px;
494
+                  }
495
+                }
496
+              }
497
+            }
498
+          }
499
+        }
500
+
501
+        .title {
502
+          color: #333;
503
+          text-align: center;
504
+        }
505
+
506
+        .conditions {
507
+          & > .ant-row {
508
+            margin: 8px 0;
509
+
510
+            .ant-row {
511
+              .ant-col-6 {
512
+                margin: 2px 0;
513
+              }
514
+            }
515
+
516
+            .checkAll {
517
+              width: 100%;
518
+              border-bottom: 1px solid rgb(233, 233, 233);
519
+              color: @primary-color;
520
+            }
521
+          }
522
+        }
523
+
524
+        .btns {
525
+          padding: 5px 20px 0 20px;
526
+        }
527
+      }
528
+    }
529
+
530
+    .right {
531
+      // opacity: .5;
532
+      width: 80px;
533
+      float: left;
534
+      background: rgba(255, 255, 255, 0.5);
535
+      border-radius: 5px 0 0 5px;
536
+      position: relative;
537
+      z-index: 98;
538
+
539
+      .fixedMenu {
540
+        border: 1px solid #e5e9ed;
541
+        color: rgba(0, 128, 0, 0.5);
542
+        background: rgba(255, 255, 255, 0.5);
543
+        text-align: center;
544
+        border-radius: 5px 0 0 5px;
545
+        // box-shadow: -3px 4px 15px rgba(234, 233, 233, .5);
546
+
547
+        &.hujiaozhongxin {
548
+          margin-bottom: 5px;
549
+        }
550
+
551
+        .menuItems {
552
+          .item {
553
+            height: 35px;
554
+            line-height: 35px;
555
+            padding: 0 6px;
556
+            cursor: default;
557
+            border-bottom: 1px solid #e5e9ed;
558
+            user-select: none;
559
+
560
+            &.checked {
561
+              background: #fff;
562
+              color: #52ab77;
563
+              opacity: 1;
564
+              box-shadow: -3px 4px 7px #eae9e9;
565
+            }
566
+          }
567
+
568
+          .others {
569
+            transition: height 0.4s linear;
570
+            overflow: hidden;
571
+          }
572
+        }
573
+
574
+        .arrow {
575
+          cursor: pointer;
576
+        }
577
+      }
578
+    }
579
+  }
580
+}
581
+
582
+	// 新增
583
+	&.add {
584
+		position: fixed;
585
+		left: 0;
586
+		top: 0;
587
+		width: 100%;
588
+		height: 100%;
589
+		background: rgba(0, 0, 0, 0.4);
590
+		z-index: 999;
591
+	  .modalBody {
592
+	    width: 40%;
593
+	    height: auto;
594
+			padding: 10px 20px;
595
+			border-radius: 5px;
596
+			background: #fff;
597
+			.title {
598
+			  width: 100%;
599
+			  text-align: center;
600
+			  font-size: 18px;
601
+			  position: relative;
602
+			
603
+			  i {
604
+			    position: absolute;
605
+			    right: 0;
606
+			    top: 0;
607
+			    font-size: 20px;
608
+			    color: #666;
609
+			    cursor: pointer;
610
+			    padding: 0 5px;
611
+			  }
612
+			}
613
+	    .content {
614
+	      width: 100%;
615
+	      // height: auto;
616
+	      padding: 19px 14px 0 14px;
617
+	      // max-height: 500px;
618
+	      // overflow-y: auto;
619
+				.ant-select{
620
+					width: 100%;
621
+				}
622
+				.ant-form-item {
623
+				  margin-bottom: 14px;
624
+					display: flex;
625
+					flex-wrap: wrap;
626
+				  .ant-form-item-label {
627
+				    text-align: left;
628
+						font-weight: 500;
629
+				  }
630
+					.ant-form-item-control-wrapper{
631
+						.ant-form-item-control{
632
+							width: 400px;
633
+						}
634
+					}
635
+				}
636
+				.select-item{
637
+					margin-top: 5px;
638
+					display: flex;
639
+					flex-wrap: wrap;
640
+					padding: 3px 8px;
641
+					border: 1px solid #e5e9ed;
642
+					border-radius: 5px;
643
+					margin-right: 10px;
644
+					cursor: pointer;
645
+					display: inline-block;
646
+				}
647
+				
648
+	      
649
+	    }
650
+			.bottom-btn{
651
+				margin-top: 10px;
652
+				.btn-right{
653
+					margin-right: 10px;
654
+				}
655
+			}
656
+	  }
657
+		.no-width{
658
+			width: 30% !important;
659
+		}
660
+	}
661
+
662
+.pathology-box {
663
+  position: fixed;
664
+	left: 0;
665
+	top: 0;
666
+	width: 100%;
667
+	height: 100%;
668
+	background: rgba(0, 0, 0, 0.4);
669
+	z-index: 99;
670
+	.pathology-content{
671
+		width: 80%;
672
+		background: #fff;
673
+		border-radius: 5px;
674
+		padding: 10px 20px;
675
+		color: #000;
676
+		.title {
677
+		  width: 100%;
678
+		  text-align: center;
679
+		  font-size: 18px;
680
+		  position: relative;
681
+		
682
+		  i {
683
+		    position: absolute;
684
+		    right: 0;
685
+		    top: 0;
686
+		    font-size: 20px;
687
+		    color: #666;
688
+		    cursor: pointer;
689
+		    padding: 0 5px;
690
+		  }
691
+		}
692
+		.content{
693
+			width: 100%;
694
+			background: #f9fafb;
695
+			// border: 1px solid #e5e9ed;
696
+			border-radius: 5px;
697
+			margin-top: 12px;
698
+			height: 460px;
699
+			// display: flex;
700
+			// .addForm{
701
+				// display: flex;
702
+				.font-weight-500{
703
+					color: #000;
704
+					font-weight: 500;
705
+				}
706
+				.ant-select{
707
+					width: 100%;
708
+				}
709
+				.content-item{
710
+					// height: auto;
711
+					// max-height: 460px;
712
+					// overflow-y: auto;
713
+					// width: 78%;
714
+					padding: 15px;
715
+					.form-title-box{
716
+						display: flex;
717
+						margin-bottom: 10px;
718
+						.form-title{
719
+							color: #333;
720
+							margin-right: 40px;
721
+						}
722
+						.width-150{
723
+							width: 150px;
724
+						}
725
+						.width-200{
726
+							width: 200px;
727
+						}
728
+					}
729
+					.center{
730
+						text-align: center;
731
+						padding: 10px 0;
732
+					}
733
+					.disp-fl{
734
+						display: flex;
735
+						align-items: center;
736
+						.disp-title{
737
+							margin-right: 160px;
738
+							.weight{
739
+								font-weight: bold;
740
+							}
741
+						}
742
+						.width-120{
743
+							width: 85px;
744
+						}
745
+						.ant-input{
746
+							width: 300px;
747
+						}
748
+						.error-class{
749
+							color: red;
750
+							margin-left: 10px;
751
+						}
752
+					}
753
+					.form-list{
754
+						margin-bottom: 10px;
755
+						.specimen-list{
756
+							display: flex;
757
+							flex-wrap: wrap;
758
+							.specimen-item-class{
759
+								margin-right: 40px;
760
+								color:#333;
761
+							}
762
+						}
763
+						.indent{
764
+							text-indent: 2ch;
765
+							color: #333;
766
+						}
767
+					}
768
+					.ant-form-item {
769
+					  margin-bottom: 14px;
770
+						display: flex;
771
+						flex-wrap: wrap;
772
+					  .ant-form-item-label {
773
+					    text-align: left;
774
+							font-weight: 500;
775
+					  }
776
+						.ant-form-item-control-wrapper{
777
+							.ant-form-item-control{
778
+								width: 400px;
779
+							}
780
+						}
781
+					}
782
+					.add-icon-class{
783
+						border: 1px solid #e5e9ed;
784
+						border-radius: 3px;
785
+						width: 26px;
786
+						height: 26px;
787
+						line-height: 26px;
788
+						text-align: center;
789
+						position: relative;
790
+						top: 7px;
791
+						cursor: pointer;
792
+						.form-icon{
793
+							
794
+						}
795
+					}
796
+				}
797
+				.content-item-right{
798
+					width: 25%;
799
+					height: auto;
800
+					max-height: 460px;
801
+					overflow-y: auto;
802
+					padding: 10px;
803
+					.step-title{
804
+						font-size: 16px;
805
+						font-weight: 500;
806
+						margin-bottom: 10px;
807
+					}
808
+				}
809
+				.boder-right{
810
+					border-right: 1px solid #e5e9ed;
811
+				}
812
+				.specimen-item{
813
+					display: flex;
814
+					margin-bottom: 10px;
815
+					.specimen-icon{
816
+						color: #64BD7B;
817
+						cursor: pointer;
818
+						font-size: 20px;
819
+						position: relative;
820
+						top: -4px;
821
+						left: 2px;
822
+					}
823
+				}
824
+			// }
825
+		}
826
+		.bottom-btn{
827
+			margin-top: 10px;
828
+			.btn-right{
829
+				margin-right: 10px;
830
+			}
831
+		}
832
+	}
833
+	
834
+}
835
+
836
+.mask-style{
837
+	width: 100%;
838
+	height: 100%;
839
+	position: fixed;
840
+	top: 0;
841
+	left: 0;
842
+	z-index: 999;
843
+	display: flex;
844
+	background: rgba(0,0,0,0.2);
845
+	align-items: center;
846
+	justify-content: center;
847
+}
848
+.spin-style{
849
+	z-index:9999;
850
+}

+ 818 - 0
src/app/views/pathology/pathology.component.ts

@@ -0,0 +1,818 @@
1
+import { Component, OnInit, ViewChild, OnDestroy } from "@angular/core";
2
+import { MainService } from "../../services/main.service";
3
+import { Router } from "@angular/router";
4
+import { OverlayScrollbarsComponent } from "overlayscrollbars-ngx";
5
+import { startOfDay, format, endOfDay } from "date-fns";
6
+import { ToolService } from 'src/app/services/tool.service';
7
+import { NzMessageService } from "ng-zorro-antd";
8
+import { debounceTime } from 'rxjs/operators';
9
+import { Subject } from 'rxjs';
10
+
11
+import {
12
+  FormBuilder,
13
+  Validators,
14
+  FormGroup,
15
+  FormControl,
16
+} from "@angular/forms";
17
+
18
+@Component({
19
+  selector: "app-pathology",
20
+  templateUrl: "./pathology.component.html",
21
+  styleUrls: ["./pathology.component.less"],
22
+})
23
+export class PathologyComponent implements OnInit, OnDestroy {
24
+  @ViewChild("osComponentRef1", {
25
+    read: OverlayScrollbarsComponent,
26
+    static: false,
27
+  })
28
+  osComponentRef1: OverlayScrollbarsComponent;
29
+  @ViewChild("osComponentRef2", {
30
+    read: OverlayScrollbarsComponent,
31
+    static: false,
32
+  })
33
+  osComponentRef2: OverlayScrollbarsComponent;
34
+  @ViewChild("osComponentRef3", {
35
+    read: OverlayScrollbarsComponent,
36
+    static: false,
37
+  })
38
+  osComponentRef3: OverlayScrollbarsComponent;
39
+  @ViewChild("osComponentRef4", {
40
+    read: OverlayScrollbarsComponent,
41
+    static: false,
42
+  })
43
+  osComponentRef4: OverlayScrollbarsComponent;
44
+  @ViewChild("osComponentRef5", {
45
+    read: OverlayScrollbarsComponent,
46
+    static: false,
47
+  })
48
+  osComponentRef5: OverlayScrollbarsComponent;
49
+  constructor(
50
+	private mainService: MainService, 
51
+	public router: Router, 
52
+	public tool: ToolService,
53
+	private fb: FormBuilder,
54
+	private message: NzMessageService,
55
+	) {}
56
+  // 今日药单量
57
+  todayTotal: undefined;
58
+  // 今日已完成
59
+  todayComplete: undefined;
60
+  //手术间数据
61
+  printPharmacyList = []; //数据列表
62
+  printPharmacyIdx = 0; //页码
63
+  printPharmacyTotal = 0; //总数
64
+  printPharmacyFlag = false; //是否查看更多
65
+  printPharmacySearchKey = ""; //搜索的内容
66
+  printPharmacyLoad = false; //按钮的loading
67
+  // 标本间列表
68
+  waitPharmacyList = [];
69
+  waitPharmacyIdx = 0;
70
+  waitPharmacyTotal = 0;
71
+  waitPharmacyFlag = false;
72
+  waitPharmacySearchKey = "";
73
+  waitPharmacyLoad = false;
74
+  // 今日离科列表
75
+  pharmacyList = [];
76
+  pharmacyIdx = 0;
77
+  pharmacyTotal = 0;
78
+  pharmacyFlag = false;
79
+  pharmacySearchKey = "";
80
+  pharmacyLoad = false;
81
+  // 配送中列表
82
+  distributionList = [];
83
+  distributionIdx = 0;
84
+  distributionTotal = 0;
85
+  distributionFlag = false;
86
+  distributionSearchKey = "";
87
+  distributionLoad = false;
88
+  // 已完成列表
89
+  completedList = [];
90
+  completedIdx = 0;
91
+  completedTotal = 0;
92
+  completedFlag = false;
93
+  completedSearchKey = "";
94
+  completedLoad = false;
95
+	
96
+	barCode:any; //条码搜索
97
+  // other
98
+  loginUser: any = localStorage.getItem("user")
99
+    ? JSON.parse(localStorage.getItem("user")).user
100
+    : null; //登录人信息
101
+
102
+  logTimer = null; //定时器
103
+  logTime = 0; //自动刷新秒数
104
+  logTimeConst = 60; //自动刷新秒数
105
+
106
+  time = new Date().getTime(); // 时间戳
107
+  timer = null; // 时间定时器
108
+	relevanceModal:boolean = false //关联标本和手术室
109
+	validateForm: FormGroup; //关联标本和手术室表单
110
+	validateVerificationForm: FormGroup; //核验标本
111
+	specimenData:any = []; //标本间数据
112
+	operationData:any = []; //手术间数据
113
+	fixationModal:boolean = false //标本接收固定
114
+	verificationMoadl:boolean = false //标本核验
115
+	specimenCode:any; //标本条码
116
+	listOneData:any=[
117
+		{applyCode:1008611,patientDTO:{patientName:''}}
118
+	]; 
119
+	listOneLength:any;
120
+	pageOneIndex:any = 0;
121
+	pageSize:any = 10;
122
+	listTwoData:any=[];
123
+	listTwoLength:any;
124
+	pageTwoIndex:any = 0;
125
+	listThreeData:any=[];
126
+	listThreeLength:any;
127
+	pageThreeIndex:any = 0;
128
+	loading1:boolean = false;
129
+	loading2:boolean = false;
130
+	loading3:boolean = false;
131
+	loading4:boolean = false;
132
+	loading5:boolean = false;
133
+	fixativeData:any = []; //固体液类型
134
+	hosId:any;
135
+	userId:any;
136
+	detailsData:any;
137
+	isSpinning:boolean = false; //全屏加载状态
138
+	codeData:any = []; //标本条码数据
139
+	btnInfoLoading :boolean = false; //标本加固加载
140
+	activeIndex:any = 0; //tabs选择状态
141
+	changeInpSubject = new Subject(); //防抖
142
+	changeInpSubjectUser = new Subject(); //防抖
143
+	changeInpSubjectSpecimen = new Subject(); //防抖
144
+	intraoperativeRapidity:any = 1; //术中快速
145
+	deliveryUser:any //配送人
146
+	acceptTime:any; //接收时间
147
+	userData:any = []; //配送人数据
148
+	isLoading:boolean = false;
149
+	listDetailMoadl:boolean = false; //详情弹框
150
+  ngOnDestroy() {
151
+    clearTimeout(this.timer);
152
+    clearTimeout(this.logTimer);
153
+  }
154
+
155
+  ngOnInit() {
156
+		this.changeInpSubject.pipe(debounceTime(500)).subscribe((v) => {
157
+		  this.searchSpecimenData(v[0])
158
+		});
159
+		this.changeInpSubjectSpecimen.pipe(debounceTime(500)).subscribe((v) => {
160
+		  this.searchSpecimen(v[0])
161
+		});
162
+		this.changeInpSubjectUser.pipe(debounceTime(500)).subscribe((v) => {
163
+			this.isLoading = true
164
+		  this.getUserData(v[0])
165
+		});
166
+		
167
+		this.hosId = this.tool.getCurrentHospital().id;
168
+		this.userId = this.tool.getCurrentUserId()
169
+		this.getUserData('')
170
+    this.changeKs();
171
+  }
172
+  // 当前时间日期
173
+  runTime() {
174
+    clearTimeout(this.timer);
175
+    this.timer = setTimeout(() => {
176
+      this.time = Date.now();
177
+      this.runTime();
178
+    }, 500);
179
+  }
180
+	
181
+	//tab切换
182
+	tabClick(type){
183
+		this.activeIndex = type
184
+	}
185
+	
186
+	//配送人搜索
187
+	changeUserInp(e){
188
+		this.changeInpSubjectUser.next([e]);
189
+	}
190
+	
191
+	// 获取配送人
192
+	getUserData(e){
193
+		let query={
194
+			idx: 0,
195
+			sum: 10,
196
+			user: {
197
+			  hospital: {id: this.hosId},
198
+			  account: e,
199
+			},
200
+		}
201
+		this.mainService
202
+		.getFetchDataList("data", "user", query)
203
+		.subscribe((res) => {
204
+			this.isLoading = false
205
+			this.userData = res.list
206
+		});
207
+	}
208
+	
209
+	// 搜索
210
+	search() {
211
+	  this.pageOneIndex = 1;
212
+	  this.getConnectList();
213
+	}
214
+	// 重置
215
+	reset() {
216
+	  this.pageOneIndex = 1;
217
+	  this.startDate = null;
218
+		this.endDate = null;
219
+	  this.getConnectList();
220
+	}
221
+	// 交接本数据
222
+	getConnectList() {
223
+	  var that = this;
224
+	  let data = {
225
+	    idx: that.pageOneIndex - 1,
226
+	    sum: that.pageSize,
227
+	    drugsBatch: {
228
+	      startTime: this.startDate,
229
+	  		endTime: this.endDate,
230
+	  		hosId: this.hosId
231
+	    },
232
+	  };
233
+	  this.loading1 = true;
234
+	  that.mainService
235
+	    .getFetchDataList("data", "drugsBatch", data)
236
+	    .subscribe((data) => {
237
+	      this.loading1 = false;
238
+	      that.listOneData = data.list;
239
+	      that.listOneLength = data.totalNum;
240
+	    });
241
+	}
242
+	
243
+	// 实时术中快速数据
244
+	getSpeedinessList() {
245
+	  var that = this;
246
+	  let data = {
247
+	    idx: that.pageTwoIndex - 1,
248
+	    sum: that.pageSize,
249
+	    drugsBatch: {
250
+	  		hosId: this.hosId
251
+	    },
252
+	  };
253
+	  this.loading2 = true;
254
+	  that.mainService
255
+	    .getFetchDataList("data", "drugsBatch", data)
256
+	    .subscribe((data) => {
257
+	      this.loading2 = false;
258
+	      that.listTwoData = data.list;
259
+	      that.listTwoLength = data.totalNum;
260
+	    });
261
+	}
262
+	
263
+	// 打包配送
264
+	getPackList() {
265
+	  var that = this;
266
+	  let data = {
267
+	    idx: that.pageThreeIndex - 1,
268
+	    sum: that.pageSize,
269
+	    drugsBatch: {
270
+	  		hosId: this.hosId
271
+	    },
272
+	  };
273
+	  this.loading3 = true;
274
+	  that.mainService
275
+	    .getFetchDataList("data", "drugsBatch", data)
276
+	    .subscribe((data) => {
277
+	      this.loading3 = false;
278
+	      that.listThreeData = data.list;
279
+	      that.listThreeLength = data.totalNum;
280
+	    });
281
+	}
282
+	
283
+	// 查看
284
+	oneLook(e){
285
+		this.listDetailMoadl = true
286
+	}
287
+	
288
+	closeDetail(){
289
+		this.listDetailMoadl = false
290
+	}
291
+	
292
+	// 交接
293
+	connect(){
294
+		this.fixationModal = true
295
+		setTimeout(_=>{
296
+			document.getElementById('specimen').focus();
297
+		},200)
298
+	}
299
+	
300
+	
301
+	// 打包
302
+	packaging(){
303
+		
304
+	}
305
+	
306
+	// 接收时间
307
+	startDate:any;
308
+	endDate:any;
309
+	changeDate(result){
310
+		this.startDate = format(result[0], 'yyyy-MM-dd HH:mm:ss');
311
+		this.endDate = format(result[1], 'yyyy-MM-dd HH:mm:ss');
312
+	}
313
+	
314
+	// 标本条码搜索
315
+	errorcODEMsg:any = null
316
+	searchSpecimen(e){
317
+		if(!e){
318
+			return
319
+		}
320
+		if(e.length < 10) {
321
+			return
322
+		}
323
+		let data={
324
+			barcode:e
325
+		}
326
+		this.isSpinning = true
327
+		this.mainService.pathologyScanCode(data)
328
+		.subscribe((res:any) => {
329
+			this.isSpinning = false
330
+			if(res.status==200){
331
+				this.codeData = res.data
332
+				if(this.codeData.pathologyInspectDTOS){
333
+					this.project = this.codeData.pathologyInspectDTOS.map(i=>{
334
+						return i.inspectProject.name
335
+					})
336
+					this.project = this.project.join('、')
337
+				}
338
+				this.errorcODEMsg = null
339
+				this.fixationModal = true
340
+				setTimeout(_=>{
341
+					document.getElementById('specimen').focus();
342
+				},200)
343
+			}else{
344
+				this.barCode = null
345
+				this.errorcODEMsg = res.msg
346
+				// this.message.error(res.msg)
347
+			}
348
+		})
349
+	}
350
+	
351
+	// 选择固定时间
352
+	formChangeDate(result){
353
+	  this.startDate = format(result, 'yyyy-MM-dd HH:mm:ss');
354
+	}
355
+	
356
+	// 确定接受固定标本
357
+	submitFixationForm(){
358
+		this.validateVerificationForm = this.fb.group({
359
+		  fixationTime: [null, [Validators.required]],
360
+			jobNumber: [null, [Validators.required]],
361
+			name:[null, [Validators.required]],
362
+			fixative:[null, [Validators.required]],
363
+		});
364
+		let date = new Date();
365
+		this.startDate = format(date, "yyyy-MM-dd HH:mm:ss")
366
+		this.validateVerificationForm.controls.fixationTime.setValue(this.startDate);
367
+		this.btnLoading = true
368
+		this.mainService.getDictionary("list", "fixing_liquid_type").subscribe((res) => {
369
+			this.fixativeData = res
370
+			this.btnLoading = false
371
+			this.verificationMoadl = true
372
+		});
373
+	}
374
+	
375
+	// 关闭接受固定标本
376
+	hideSpecimenModal(){
377
+		// this.autoUpdate()
378
+		this.barCode = null;
379
+		this.specimenCode = null;
380
+		this.fixationModal = false;
381
+	}
382
+	
383
+	// 获取标本详情
384
+	project:any = [];
385
+	getSampleData(item){
386
+		this.mainService.getFetchData("data", "pathologyForm", item.id)
387
+		.subscribe((data) => {
388
+			this.isSpinning = false
389
+			this.detailsData = data.data
390
+		  this.specimenList = data.data.pathologySpecimenDTOList||[]
391
+			this.pathologyLogs = data.data.formLogDTOS
392
+			this.stepLength = this.pathologyLogs.length
393
+			if(this.detailsData.pathologyInspectDTOS){
394
+				this.project = this.detailsData.pathologyInspectDTOS.map(i=>{
395
+					return i.inspectProject.name
396
+				})
397
+				this.project = this.project.join('、')
398
+			}
399
+		  this.detailMoadl = true
400
+		});
401
+	}
402
+	
403
+	// 获取科室
404
+	getDept(){
405
+		this.setSpecimen()
406
+		var that = this;
407
+		that.mainService.getDictionary("list", "dept_type").subscribe((res2) => {
408
+			let item1 = res2.find(i=>i.name=='手术室科室')
409
+			let item2 = res2.find(i=>i.name=='标本间科室')
410
+			let data1 = {
411
+			  idx: 0,
412
+			  sum: 9999,
413
+			  department: {
414
+			    hospital: { id: that.hosId || "" },
415
+			    type: { id: item1.id || "" },
416
+			  },
417
+			};
418
+			let data2 = {
419
+			  idx: 0,
420
+			  sum: 9999,
421
+			  department: {
422
+			    hospital: { id: that.hosId || "" },
423
+			    type: { id: item2.id || "" },
424
+			  },
425
+			};
426
+			that.mainService
427
+			  .getFetchDataList("data", "department", data1)
428
+			  .subscribe((res) => {
429
+			    that.operationData = res.list;
430
+			  });
431
+				
432
+			that.mainService
433
+			  .getFetchDataList("data", "department", data2)
434
+			  .subscribe((res) => {
435
+					that.specimenData = res.list
436
+					this.getDeptDetail()
437
+			  });
438
+		});
439
+	}
440
+	
441
+	// 获取关联科室详情
442
+	getDeptDetail(){
443
+		this.mainService
444
+		  .transfusionPrint("user", this.userId)
445
+		  .subscribe((res) => {
446
+				let data = res.data;
447
+				if(data.surgeryDepts){
448
+					let deptArr = []
449
+					for(let i of data.surgeryDepts){
450
+						deptArr.push(i.id)
451
+					}
452
+					this.validateForm.controls.operation.setValue(deptArr);
453
+				}
454
+				this.validateForm.controls.specimen.setValue(data.dept.id);
455
+				if(data.autoCreateOrder){
456
+					this.validateForm.controls.generate.setValue(data.autoCreateOrder);
457
+				}
458
+		  });
459
+	}
460
+	
461
+	// 获取是否关联标本间
462
+	setSpecimen(){
463
+		this.validateForm = this.fb.group({
464
+		  specimen: [null, [Validators.required]],
465
+			operation: [null, [Validators.required]],
466
+			generate:[1, [Validators.required]],
467
+		});
468
+		this.relevanceModal = true
469
+	}
470
+	
471
+	// 确定关联科室
472
+	btnLoading:boolean = false;
473
+	submitForm(){
474
+		for (const i in this.validateForm.controls) {
475
+		  this.validateForm.controls[i].markAsDirty();
476
+		  this.validateForm.controls[i].updateValueAndValidity();
477
+		}
478
+		if (this.validateForm.invalid) return;
479
+		let deptArr = this.validateForm.value.operation.join(',')
480
+		let data = {
481
+		  user: {
482
+		    autoCreateOrder: this.validateForm.value.generate,
483
+				dept:{
484
+					id:this.validateForm.value.specimen
485
+				},
486
+				surgeryDeptIds:deptArr,
487
+				id:this.userId
488
+		  },
489
+		};
490
+		this.btnLoading = true
491
+		this.mainService
492
+		  .coopData("updData", "user", data)
493
+		  .subscribe((data) => {
494
+				this.getNewDept()
495
+				this.btnLoading = false
496
+				this.relevanceModal = false
497
+		    if (data.status == 200) {
498
+		      this.showPromptModal("操作", true, "");
499
+		    } else {
500
+		      this.showPromptModal("操作", false, data.msg);
501
+		    }
502
+		  });
503
+	}
504
+	
505
+	getNewDept(){
506
+		let postData = {
507
+		  currentHosId: this.hosId,
508
+		  loginType: "PC",
509
+		};
510
+		this.mainService.changeHospital(postData).subscribe((result) => {
511
+		  if (result.status == 200) {
512
+		    let dataObj = {
513
+		      user: {
514
+		        dept: {
515
+		          id: this.validateForm.value.specimen,
516
+		        },
517
+		        id: JSON.parse(localStorage.getItem("user")).user.id,
518
+		      },
519
+		    };
520
+		    this.mainService
521
+		      .coopData("updData", "user", dataObj)
522
+		      .subscribe((data) => {
523
+		        if (data.status == 200) {
524
+		          this.getCurrentUserNow();
525
+		        }
526
+		      });
527
+		  }
528
+		});
529
+	}
530
+	
531
+	// 获取当前用户信息
532
+	getCurrentUserNow() {
533
+	  this.mainService.getCurrentUser1().subscribe((data:any) => {
534
+	    if (data["status"] == 200) {
535
+				this.loginUser = data.data 
536
+	      let user = JSON.parse(localStorage.getItem("user"));
537
+	      user.user.dept = data["data"].dept;
538
+	      user.user.currentHospital = data["data"].currentHospital;
539
+	      localStorage.setItem("user", JSON.stringify(user));
540
+	    }
541
+	  });
542
+	}
543
+	
544
+	// 输入工号查询姓名
545
+	handoverUserId:any = null;
546
+	numberChange(e){
547
+		if(e.length < 3) {
548
+			this.validateVerificationForm.controls.name.setValue('');
549
+			return
550
+		}
551
+		let query = {
552
+		  account: e
553
+		};
554
+		this.mainService
555
+		  .jobSearch(query)
556
+		  .subscribe((data:any) => {
557
+				if(data.status==200){
558
+					this.validateVerificationForm.controls.name.setValue(data.userName);
559
+					this.handoverUserId = data.userId
560
+				}else{
561
+					this.validateVerificationForm.controls.name.setValue('');
562
+					this.handoverUserId =null
563
+					this.message.error(data.data)
564
+				}
565
+		  });
566
+	}
567
+	
568
+	// 提交固定标本接收
569
+	submitVerificationForm(){
570
+		for (const i in this.validateVerificationForm.controls) {
571
+		  this.validateVerificationForm.controls[i].markAsDirty();
572
+		  this.validateVerificationForm.controls[i].updateValueAndValidity();
573
+		}
574
+		if (this.validateVerificationForm.invalid) return;
575
+		
576
+		let data: any = {
577
+			id:this.codeData.id,
578
+			specimenDeptId:this.validateForm.value.specimen,
579
+			specimenFixingLiquid:{
580
+				id:this.validateVerificationForm.value.fixative
581
+			},
582
+			fixationTime:this.startDate,
583
+			hosId: this.hosId || "" ,
584
+			handoverUserId:this.handoverUserId
585
+		};
586
+		this.btnInfoLoading = true;
587
+		this.mainService
588
+		.simplePost("addData", "pathologyForm", data)
589
+		.subscribe((res) => {
590
+			this.btnInfoLoading = false;
591
+			this.barCode = null;
592
+			if (res.status == 200) {
593
+				this.showPromptModal("操作", true, "");
594
+			} else {
595
+				this.showPromptModal("操作", false, res.msg);
596
+			}
597
+		});
598
+	}
599
+	
600
+	closeModel(){
601
+		this.verificationMoadl = false
602
+		this.fixationModal = false
603
+	}
604
+	
605
+	// 关闭固定接受标本
606
+	hideVerificationModal(){
607
+		this.verificationMoadl = false
608
+	}
609
+	
610
+
611
+	// 监听标本条码
612
+	specimenCodeChange(e){
613
+		this.changeInpSubjectSpecimen.next([e]);
614
+	}
615
+	
616
+	// 监听接受固定标本条码
617
+	tableLoading:boolean = false;
618
+	codeChange(e){
619
+		this.changeInpSubject.next([e]);
620
+	}
621
+	
622
+	errorMsg:any = null;
623
+	searchSpecimenData(e){
624
+		if(!e){
625
+			return
626
+		}
627
+		if(e.length < 10) {
628
+			return
629
+		}
630
+		this.tableLoading = true
631
+		this.mainService.pathologyScanCode({
632
+			barcode:e,
633
+			pathologyFormId:this.codeData.id
634
+		})
635
+		.subscribe((res:any) => {
636
+			this.tableLoading = false
637
+			this.specimenCode = null
638
+			if(res.status==200){
639
+				this.codeData = res.data
640
+				this.errorMsg = null
641
+			}else{
642
+				this.errorMsg = res.msg
643
+				// this.message.error(res.msg)
644
+			}
645
+		})
646
+	}
647
+	
648
+	// 查看详情
649
+	detailMoadl:boolean = false;
650
+	pathologyLogs:any=[];
651
+	specimenList:any=[]
652
+	stepLength:any = 0;
653
+	viewDetail(item,type){
654
+		this.isSpinning = true
655
+		this.getSampleData(item)
656
+		clearInterval(this.logTimer);
657
+		if(type==1){
658
+			
659
+		}else if(type==2){
660
+			
661
+		}else{
662
+			
663
+		}
664
+	}
665
+	
666
+	closeDetailMoadl(){
667
+		this.detailMoadl = false
668
+		// this.autoUpdate(false);
669
+	}
670
+	
671
+ 
672
+  // 自动刷新倒计时
673
+  autoUpdate(flag = true) {
674
+    if (flag) {
675
+      this.logTime = this.logTimeConst;
676
+    }
677
+    clearInterval(this.logTimer);
678
+    this.logTimer = setInterval(() => {
679
+      this.logTime--;
680
+      if (this.logTime === 0) {
681
+        this.logTime = this.logTimeConst;
682
+
683
+      }
684
+    }, 1000);
685
+  }
686
+  // 退出
687
+  logOut(): void {
688
+    // 假退出
689
+    let hospital = this.tool.getCurrentHospital();
690
+    if(hospital){
691
+      this.router.navigate(["login", hospital.id]);
692
+    }else{
693
+      this.router.navigateByUrl("login");
694
+    }
695
+    localStorage.removeItem("user");
696
+    localStorage.removeItem("menu");
697
+    localStorage.removeItem("phones");
698
+    localStorage.removeItem("index");
699
+    // 假退出
700
+    this.mainService.logOut().subscribe((data) => {
701
+      if (data.status == 200) {
702
+        if(hospital){
703
+          this.router.navigate(["login", hospital.id]);
704
+        }else{
705
+          this.router.navigateByUrl("login");
706
+        }
707
+        localStorage.removeItem("user");
708
+        localStorage.removeItem("menu");
709
+        localStorage.removeItem("phones");
710
+        localStorage.removeItem("index");
711
+      }
712
+    });
713
+
714
+  }
715
+
716
+  // 右侧菜单
717
+  showLastItems: boolean = false;
718
+  // 下拉
719
+  fixedMenuXiala() {
720
+    this.showLastItems = true;
721
+  }
722
+
723
+  // 上拉
724
+  fixedMenuShangla() {
725
+    this.showLastItems = false;
726
+  }
727
+
728
+  mainRole: boolean = false; //回到系统管理权限
729
+  initRole() {
730
+    let menus = JSON.parse(localStorage.getItem("menu"));
731
+    console.log("菜单数量" + menus.length);
732
+    if (menus.length >= 2) {
733
+      this.mainRole = true;
734
+      return;
735
+    }
736
+  }
737
+
738
+  // 切换右侧菜单Tab
739
+  fixedTab: string = "";
740
+  checkFixedTab(type: string) {
741
+    if (type == "toSystem") {
742
+      this.router.navigateByUrl("main");
743
+    }
744
+    if (this.fixedTab == type) {
745
+      this.fixedTab = "";
746
+    } else {
747
+      this.fixedTab = type;
748
+    }
749
+  }
750
+  //药房端科室切换
751
+  changeShow = true;
752
+  closeTime = 3;
753
+  closeTimeFlag = 0;
754
+  hsPromptModalShow: boolean = false; //科室切换提示框是否展示
755
+  timerCloseTime = null;
756
+  deptDisplay = 1; //护士端是否显示可以别名,1是显示科室名称,2是显示科室别名
757
+  //子传父接收
758
+  closeModelHs(e) {
759
+    this.hsPromptModalShow = JSON.parse(e).show;
760
+    this.changeShow = JSON.parse(e).changeShow;
761
+		setTimeout(_=>{
762
+			document.getElementById('Binput').focus();
763
+		},200)
764
+  }
765
+  //子传父接收
766
+  clearModelHs(e) {
767
+    if (JSON.parse(e).clear === true) {
768
+      clearInterval(this.timerCloseTime);
769
+    }
770
+    this.changeShow = JSON.parse(e).changeShow;
771
+		setTimeout(_=>{
772
+			document.getElementById('Binput').focus();
773
+		},200)
774
+  }
775
+  // 头部切换科室
776
+  changeKsNow() {
777
+    this.hsPromptModalShow = true;
778
+    clearInterval(this.timerCloseTime);
779
+    this.changeShow = false;
780
+  }
781
+  // 切换科室
782
+  changeKs() {
783
+    this.hsPromptModalShow = true;
784
+    // (1)	当用户设置为正数时,用户必须查看此窗体指定秒数。
785
+    // (2)	当用户设置为负数时,用户可点击知道了也可倒计时自动关闭。
786
+    // (3)	如果用户填写0则为无自动关闭和强制查看时间。
787
+    if (this.closeTimeFlag === 0) {
788
+      return;
789
+    }
790
+    this.closeTime = Math.abs(this.closeTimeFlag);
791
+    clearInterval(this.timerCloseTime);
792
+    this.timerCloseTime = setInterval(() => {
793
+      this.closeTime = Math.max(--this.closeTime, 0);
794
+      if (this.closeTime === 0) {
795
+        if (this.closeTimeFlag <= 0) {
796
+          this.hsPromptModalShow = false;
797
+        }
798
+        clearInterval(this.timerCloseTime);
799
+      }
800
+    }, 1000);
801
+  }
802
+	
803
+	promptModalShow:boolean = false;
804
+	promptContent:any = null;
805
+	ifSuccess:any = null;
806
+	promptInfo:any = null;
807
+	// 展示信息提示框(con:提示信息,success:操作是否成功,promptInfo:操作结果提示信息)
808
+	showPromptModal(con, success, promptInfo?) {
809
+	  this.promptModalShow = false;
810
+	  this.promptContent = con;
811
+	  this.ifSuccess = success;
812
+	  this.promptInfo = promptInfo;
813
+	  setTimeout(() => {
814
+	    this.promptModalShow = true;
815
+	  }, 100);
816
+	}
817
+}
818
+

+ 17 - 0
src/app/views/pathology/pathology.module.ts

@@ -0,0 +1,17 @@
1
+import { NgModule } from '@angular/core';
2
+import { CommonModule } from '@angular/common';
3
+
4
+import { PathologyRoutingModule } from './pathology-routing.module';
5
+import { ShareModule } from 'src/app/share/share.module';
6
+import { PathologyComponent } from './pathology.component';
7
+
8
+
9
+@NgModule({
10
+  declarations: [PathologyComponent],
11
+  imports: [
12
+    CommonModule,
13
+    PathologyRoutingModule,
14
+    ShareModule
15
+  ]
16
+})
17
+export class PathologyModule { }

+ 4 - 5
src/app/views/round-robin/round-robin.component.html

@@ -191,9 +191,9 @@
191 191
             </nz-form-control>
192 192
           </nz-form-item>
193 193
           <ng-container *ngIf="selectedTasktype">
194
-            <nz-form-item *ngIf="selectedTasktype.associationType.value=='specimenPlan'">
194
+            <nz-form-item *ngIf="selectedTasktype.associationType.value=='specimenPlan' || selectedTasktype.associationType.value=='specimen'">
195 195
               <nz-form-label [nzSm]="6" [nzXs]="24"
196
-                [nzRequired]="selectedTasktype.associationType.value=='specimenPlan'" nzFor="endDepartment">终点科室
196
+                [nzRequired]="selectedTasktype.associationType.value=='specimenPlan' || selectedTasktype.associationType.value=='specimen'" nzFor="endDepartment">终点科室
197 197
               </nz-form-label>
198 198
               <nz-form-control nzErrorTip="请选择终点科室!">
199 199
                 <nz-select [nzMode]="'multiple'" [nzDropdownMatchSelectWidth]="false" formControlName="endDepartment"
@@ -220,9 +220,8 @@
220 220
           </ng-container>
221 221
         </form>
222 222
         <ng-container *ngIf="selectedTasktype">
223
-          <p *ngIf="selectedTasktype.associationType.value=='specimenPlan'" class="roundRobinTips">
224
-            提示:起点科室即为标本开通科室;执行人即为科室绑定人员设定;前往设置<a [routerLink]="['/main','officeManagement']">开通科室</a><a
225
-              [routerLink]="['/main','workAssignment']">工作分配</a>>>
223
+          <p *ngIf="selectedTasktype.associationType.value=='specimenPlan' || selectedTasktype.associationType.value=='specimen'" class="roundRobinTips">
224
+            提示:起点科室即为标本开通科室;执行人即为科室绑定人员设定;前往设置开通科室、工作分配
226 225
           </p>
227 226
           <p *ngIf="selectedTasktype.associationType.value=='other'&&(selectedTasktype.carryingCourses[0].departmentStrategy.value==1||selectedTasktype.carryingCourses[1].departmentStrategy.value==1)"
228 227
             class="roundRobinTips">

+ 22 - 8
src/app/views/round-robin/round-robin.component.ts

@@ -114,7 +114,6 @@ export class RoundRobinComponent implements OnInit {
114 114
         this.validateForm.controls.endDepartment.setValue(null);
115 115
       }
116 116
     }
117
-
118 117
     let data = {
119 118
       department: {
120 119
         hospital: { id },
@@ -190,10 +189,16 @@ export class RoundRobinComponent implements OnInit {
190 189
   depting = "";
191 190
   searchDepartment(dept, type) {
192 191
     this.depting = dept;
192
+		let typeId = null
193
+		if(this.selectedTasktype.associationType.value == "specimen"){
194
+			typeId = 282 
195
+		}else{
196
+			typeId = 383
197
+		}
193 198
     let postData = {
194 199
       department: {
195 200
         dept,
196
-        type: { id: 383 },
201
+        type: { id: typeId },
197 202
         hospital: {
198 203
           id: this.hosId,
199 204
         },
@@ -288,7 +293,7 @@ export class RoundRobinComponent implements OnInit {
288 293
       sum: 5,
289 294
       taskType: {
290 295
         hosIds: this.hosId + "",
291
-        associationTypeIds: "380,259",
296
+        associationTypeIds: "380,259,256",
292 297
         taskName,
293 298
       },
294 299
     };
@@ -441,7 +446,8 @@ export class RoundRobinComponent implements OnInit {
441 446
           executeTime: new Date(this.validateForm.value.executeTime).getTime(),
442 447
         },
443 448
       };
444
-      if (this.selectedTasktype.associationType.value == "specimenPlan") {
449
+      if (this.selectedTasktype.associationType.value == "specimenPlan"||
450
+					this.selectedTasktype.associationType.value == "specimen") {
445 451
         //标本轮巡
446 452
         postData.orderPlan.targetDept =
447 453
           this.validateForm.value.endDepartment.join();
@@ -475,7 +481,8 @@ export class RoundRobinComponent implements OnInit {
475 481
         dayType: this.validateForm.value.datesType,
476 482
         executeTime: new Date(this.validateForm.value.executeTime).getTime(),
477 483
       };
478
-      if (this.selectedTasktype.associationType.value == "specimenPlan") {
484
+      if (this.selectedTasktype.associationType.value == "specimenPlan"||
485
+				this.selectedTasktype.associationType.value == "specimen") {
479 486
         //标本轮巡
480 487
         postData.targetDept = this.validateForm.value.endDepartment.join();
481 488
       } else if (this.selectedTasktype.associationType.value == "other") {
@@ -541,7 +548,7 @@ export class RoundRobinComponent implements OnInit {
541 548
         sum: 5,
542 549
         taskType: {
543 550
           hosIds: this.hosId + "",
544
-          associationTypeIds: "380,259",
551
+          associationTypeIds: "380,259,256",
545 552
           taskName: "",
546 553
         },
547 554
       };
@@ -585,7 +592,8 @@ export class RoundRobinComponent implements OnInit {
585 592
     }
586 593
     //轮巡策略(时间)end
587 594
     // --------终点科室---
588
-    if (data.taskType.associationType.value == "specimenPlan") {
595
+    if (data.taskType.associationType.value == "specimenPlan" ||
596
+			this.selectedTasktype.associationType.value == "specimen") {
589 597
       //标本轮巡,则回显
590 598
       let targetDeptArr = [];
591 599
       let targetDept = data.targetDept.split(",");
@@ -593,11 +601,17 @@ export class RoundRobinComponent implements OnInit {
593 601
       targetDept.forEach((item, index) => {
594 602
         targetDeptArr.push({ id: item, dept: targetDeptShow[index] });
595 603
       });
604
+			let typeId = null
605
+			if(this.selectedTasktype.associationType.value == "specimen"){
606
+				typeId = 282
607
+			}else{
608
+				typeId = 383
609
+			}
596 610
       this.mainService
597 611
         .getFetchDataList("data", "department", {
598 612
           department: {
599 613
             hospital: { id: data.hospital },
600
-            type: { id: 383 },
614
+            type: { id: typeId },
601 615
           },
602 616
           idx: 0,
603 617
           sum: 20,

+ 44 - 30
src/app/views/specimen-room-view/specimen-room-view.component.html

@@ -16,13 +16,16 @@
16 16
     <div class="pharmacy-name">
17 17
       <div class="pharmacy-name__total">
18 18
 				<div class="pharmacy-title">标本条码:</div>
19
-				<nz-input-group nzSearch nzSize="large" [nzAddOnAfter]="suffixButton">
20
-					<input type="text" [(ngModel)]="barCode" nz-input placeholder="请输入条码" />
19
+				<nz-input-group nzSize="large">
20
+					<input type="text" id="Binput" (ngModelChange)="specimenCodeChange($event)" [(ngModel)]="barCode" nz-input placeholder="请输入条码" />
21 21
 				</nz-input-group>
22
-				<ng-template #suffixButton>
22
+				<!-- <ng-template #suffixButton>
23 23
 					<button nz-button nzType="primary" nzSize="large" nzSearch (click)="searchSpecimen()">搜索</button>
24
-				</ng-template>
24
+				</ng-template> -->
25 25
       </div>
26
+			<div>
27
+				<div class="error-class">{{searchMsg}}</div>
28
+			</div>
26 29
     </div>
27 30
     <div class="userInfo">
28 31
       <div class="wel">欢迎您:</div>
@@ -46,6 +49,7 @@
46 49
       <!-- 标题 start -->
47 50
       <div class="pharmacy-main__title">
48 51
         <strong>手术间标本</strong>
52
+				<span *ngIf="printPharmacyList.length>0">共 {{printPharmacyList.length}} 条</span>
49 53
         <span class="autoUpdate">{{ logTime }}秒</span>
50 54
       </div>
51 55
       <!-- 标题 end -->
@@ -135,6 +139,7 @@
135 139
       <!-- 标题 start -->
136 140
       <div class="pharmacy-main__title">
137 141
         <strong>标本间标本</strong>
142
+				<span *ngIf="waitPharmacyList.length>0">共 {{waitPharmacyList.length}} 条</span>
138 143
         <span class="autoUpdate">{{ logTime }}秒</span>
139 144
       </div>
140 145
       <!-- 标题 end -->
@@ -224,6 +229,7 @@
224 229
       <!-- 标题 start -->
225 230
       <div class="pharmacy-main__title">
226 231
         <strong>今日离科标本</strong>
232
+				<span *ngIf="pharmacyList.length>0">共 {{pharmacyList.length}} 条</span>
227 233
         <span class="autoUpdate">{{ logTime }}秒</span>
228 234
       </div>
229 235
       <!-- 标题 end -->
@@ -316,7 +322,7 @@
316 322
   <router-outlet></router-outlet>
317 323
 </div>
318 324
 
319
-<!-- 药房端科室切换提示框 -->
325
+<!-- 科室切换提示框 -->
320 326
 <app-hs-prompt-modal
321 327
   [changeShow]="changeShow"
322 328
   [closeTime]="closeTime"
@@ -324,7 +330,7 @@
324 330
   [show]="hsPromptModalShow"
325 331
   (closeModelHs)="closeModelHs($event)"
326 332
   (clearModelHs)="clearModelHs($event)"
327
-  deptType="pharmacy"
333
+  deptType="nurse"
328 334
 > 
329 335
   <!-- 返回系统按钮 -->
330 336
   <!-- 右侧悬浮框 -->
@@ -373,30 +379,30 @@
373 379
 </app-hs-prompt-modal>
374 380
 
375 381
 <!-- 标本历史记录查看 -->
376
-<app-history-prompt-modal
382
+<!-- <app-history-prompt-modal
377 383
   *ngIf="logPromptModalShow"
378 384
   [show]="logPromptModalShow"
379 385
   [scode]="scode"
380 386
   (closeModelHs)="closeModelLog($event)"
381
-></app-history-prompt-modal>
387
+></app-history-prompt-modal> -->
382 388
 
383 389
 <!-- 标本列表查看 -->
384
-<app-spe-prompt-modal
390
+<!-- <app-spe-prompt-modal
385 391
   *ngIf="spePromptModalShow"
386 392
   [show]="spePromptModalShow"
387 393
   [checkDeptId]="checkDeptId"
388 394
   [pharmacySearchKey]="pharmacySearchKey"
389 395
   [printDate]="printDate"
390 396
   (closeModelHs)="closeModelSpe($event)"
391
-></app-spe-prompt-modal>
397
+></app-spe-prompt-modal> -->
392 398
 
393 399
 <!-- 工单列表查看 -->
394
-<app-order-prompt-modal
400
+<!-- <app-order-prompt-modal
395 401
   *ngIf="orderPromptModalShow"
396 402
   [show]="orderPromptModalShow"
397 403
   [workId]="workId"
398 404
   (closeModelHs)="closeModelOrder($event)"
399
-></app-order-prompt-modal>
405
+></app-order-prompt-modal> -->
400 406
 
401 407
 <!-- 关联标本/手术室 -->
402 408
 <div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="relevanceModal">
@@ -470,6 +476,9 @@
470 476
 					<div class="form-title"><span class="font-weight-500">患者信息:</span>{{codeData.patientDTO.patientName}} ({{codeData.patientDTO.bedNum}}床)</div>
471 477
 					<div class="form-title"><span class="font-weight-500">年龄:</span>{{codeData.patientDTO.age||'-'}}岁</div>
472 478
 				</div>
479
+				<div class="form-title-box">
480
+					<div class="form-title"><span class="font-weight-500">检验项目:</span>{{project||'无'}}</div>
481
+				</div>
473 482
 				<div class="form-list">
474 483
 					<div class="form-title font-weight-500">诊断:</div>
475 484
 					<div class="indent">
@@ -490,13 +499,13 @@
490 499
 					<div class="indent">{{codeData.intraoperativeFindings||'无'}}</div>
491 500
 				</div>
492 501
 				<div class="form-title-box">
493
-					<div class="form-title"><span class="font-weight-500">标本类型:</span>{{codeData.specimenType.name||'无'}}</div>
494
-					<div class="form-title"><span class="font-weight-500">标本件数:</span>{{codeData.specimenNum||'无'}}</div>
495
-					<div class="form-title"><span class="font-weight-500">采取部位:</span>{{codeData.takePart||'无'}}</div>
502
+					<div class="form-title"><span class="font-weight-500">标本类型:</span>{{codeData.specimenType?codeData.specimenType.name:'无'}}</div>
503
+					<div class="form-title"><span class="font-weight-500">标本件数:</span>{{codeData.specimenNum?codeData.specimenNum:'无'}}</div>
496 504
 				</div>
497 505
 				<div class="form-title-box">
506
+					<div class="form-title"><span class="font-weight-500">采取部位:</span>{{codeData.takePart||'无'}}</div>
498 507
 					<div class="form-title"><span class="font-weight-500">取标本位置:</span>{{codeData.surgeryDeptDTO?codeData.surgeryDeptDTO.dept:''}}</div>
499
-					<div class="form-title"><span class="font-weight-500">取材医生:</span>{{codeData.surgeryDoctorDTO?detailsData.surgeryDoctorDTO.name : '-'}}</div>
508
+					<div class="form-title"><span class="font-weight-500">取材医生:</span>{{codeData.surgeryDoctorDTO?codeData.surgeryDoctorDTO.name : '-'}}</div>
500 509
 				</div>
501 510
 	<!-- 			<div class="form-list">
502 511
 					<div class="form-title font-weight-500">标本:</div>
@@ -511,6 +520,7 @@
511 520
 					<div class="width-120">标本条码:</div>
512 521
 					<input nz-input id="specimen" [(ngModel)]="specimenCode" (ngModelChange)="codeChange($event)"/>
513 522
 				</div>
523
+				<div class="error-fix">{{fixationError}}</div>
514 524
 				<div class="list-template">
515 525
 				  <div class="list-template__content">
516 526
 						<div class="list-template__bottom" style="padding: 0 !important;">
@@ -530,8 +540,8 @@
530 540
 										<td>
531 541
 											{{data.partSource?data.partSource.name:''}} <span *ngIf="data.system">-</span>
532 542
 											{{data.system?data.system.name:''}} <span *ngIf="data.organ">-</span>
533
-											{{data.organ?data.organ.name:''}} <span *ngIf="data.sample">-</span>
534
-											{{data.sample?data.sample.name:''}}
543
+											{{data.organ?data.organ.name:''}} <span>-</span>
544
+											{{data.sample?data.sample.name:data.specimenName}}
535 545
 										</td>
536 546
 									</tr>
537 547
 								</tbody>
@@ -610,17 +620,21 @@
610 620
 		<div class="content">
611 621
 			<div class="content-item boder-right">
612 622
 				<div class="form-title-box">
613
-					<div class="form-title width-150"><span class="font-weight-500">是否术中快速:</span>{{detailsData.intraoperativeRapidity==1?'是':'否'}}</div>
614
-					<div class="form-title width-200"><span class="font-weight-500">申请单编号:</span>{{detailsData.applyCode}}</div>
623
+					<div class="form-title"><span class="font-weight-500">是否术中快速:</span>{{detailsData.intraoperativeRapidity==1?'是':'否'}}</div>
624
+					<div class="form-title"><span class="font-weight-500">申请单编号:</span>{{detailsData.applyCode}}</div>
615 625
 					<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status.name}}</div>
616 626
 					<div class="form-title"><span class="font-weight-500">科室名称:</span>{{detailsData.patientDTO.department.dept}}</div>
617 627
 				</div>
618 628
 				<div class="form-title-box">
619
-					<div class="form-title width-150"><span class="font-weight-500">住院号:</span>{{detailsData.patientDTO.patientCode}}</div>
620
-					<div class="form-title width-200"><span class="font-weight-500">患者信息:</span>{{detailsData.patientDTO.patientName}} ({{detailsData.patientDTO.bedNum}}床)</div>
629
+					<div class="form-title"><span class="font-weight-500">住院号:</span>{{detailsData.patientDTO.patientCode}}</div>
630
+					<div class="form-title"><span class="font-weight-500">患者信息:</span>{{detailsData.patientDTO.patientName}} ({{detailsData.patientDTO.bedNum}}床)</div>
621 631
 					<div class="form-title"><span class="font-weight-500">年龄:</span>{{detailsData.patientDTO.age||'-'}}岁</div>
622 632
 				</div>
623
-
633
+				
634
+				<div class="form-title-box">
635
+					<div class="form-title"><span class="font-weight-500">检验项目:</span>{{project||'无'}}</div>
636
+				</div>
637
+				
624 638
 				<div class="form-list">
625 639
 					<div class="form-title font-weight-500">诊断:</div>
626 640
 					<div class="indent">
@@ -642,13 +656,13 @@
642 656
 				</div>
643 657
 
644 658
 				<div class="form-title-box">
645
-					<div class="form-title width-150"><span class="font-weight-500">标本类型:</span>{{detailsData.specimenType.name||'无'}}</div>
646
-					<div class="form-title width-200"><span class="font-weight-500">标本件数:</span>{{detailsData.specimenNum||'无'}}</div>
659
+					<div class="form-title"><span class="font-weight-500">标本类型:</span>{{detailsData.specimenType.name||'无'}}</div>
660
+					<div class="form-title"><span class="font-weight-500">标本件数:</span>{{detailsData.specimenNum||'无'}}</div>
647 661
 					<div class="form-title"><span class="font-weight-500">采取部位:</span>{{detailsData.takePart||'无'}}</div>
648
-					<div class="form-title"><span class="font-weight-500">送检医生:</span>{{detailsData.surgeryDoctorDTO?detailsData.surgeryDoctorDTO.name : '-'}}</div>
649 662
 				</div>
650 663
 				
651 664
 				<div class="form-title-box">
665
+					<div class="form-title"><span class="font-weight-500">送检医生:</span>{{detailsData.surgeryDoctorDTO?detailsData.surgeryDoctorDTO.name : '-'}}</div>
652 666
 					<div class="form-title"><span class="font-weight-500">离体时间:</span>{{detailsData.inVitroTime?(detailsData.inVitroTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
653 667
 					<div class="form-title"><span class="font-weight-500">固定时间:</span>{{detailsData.fixationTime?(detailsData.fixationTime|date:'yyyy-MM-dd HH:mm:ss'):'无'}}</div>
654 668
 				</div>
@@ -659,8 +673,8 @@
659 673
 						<div *ngFor="let item of specimenList" class="specimen-item-class">
660 674
 							{{item.partSource?item.partSource.name:''}} <span *ngIf="item.system">-</span>
661 675
 							{{item.system?item.system.name:''}} <span *ngIf="item.organ">-</span>
662
-							{{item.organ?item.organ.name:''}} <span *ngIf="item.sample">-</span>
663
-							{{item.sample?item.sample.name:''}}
676
+							{{item.organ?item.organ.name:''}} <span>-</span>
677
+							{{item.sample?item.sample.name:item.specimenName}}
664 678
 						</div>
665 679
 					</div>
666 680
 				</div>
@@ -690,8 +704,8 @@
690 704
 			</div>
691 705
 		</div>
692 706
 		<div class="display_flex justify-content_flex-center bottom-btn">
693
-			<button class="btn btn-right" nz-button nzType="primary" (click)="closeDetailMoadl()">确定</button>
694
-			<button class="btn cancel" nz-button nzType="default" (click)="closeDetailMoadl()">取消</button>
707
+			<button class="btn btn-right" nz-button nzType="primary" (click)="closeDetailMoadl()">知道了</button>
708
+			<!-- <button class="btn cancel" nz-button nzType="default" (click)="closeDetailMoadl()">取消</button> -->
695 709
 		</div>
696 710
 	</div>
697 711
 </div>

+ 35 - 5
src/app/views/specimen-room-view/specimen-room-view.component.less

@@ -24,6 +24,29 @@
24 24
   em {
25 25
     font-style: normal;
26 26
   }
27
+	
28
+	
29
+	/* 修改垂直滚动条 */
30
+	::-webkit-scrollbar {
31
+		width: 4px; /* 修改宽度 */
32
+		border-radius: 2px;
33
+	}
34
+	 
35
+	/* 修改滚动条轨道背景色 */
36
+	::-webkit-scrollbar-track {
37
+		background-color: #f1f1f1;
38
+	}
39
+	 
40
+	/* 修改滚动条滑块颜色 */
41
+	::-webkit-scrollbar-thumb {
42
+		background-color: #888;
43
+	}
44
+	 
45
+	/* 修改滚动条滑块悬停时的颜色 */
46
+	::-webkit-scrollbar-thumb:hover {
47
+		background-color: #555;
48
+	}
49
+	
27 50
   .pharmacy {
28 51
     display: flex;
29 52
     flex-direction: column;
@@ -86,6 +109,9 @@
86 109
 					font-size: 22px;
87 110
 				}
88 111
       }
112
+			.error-class{
113
+				color: red;
114
+			}
89 115
     }
90 116
 
91 117
     .pharmacy-operate {
@@ -555,10 +581,10 @@
555 581
 			}
556 582
 	    .content {
557 583
 	      width: 100%;
558
-	      height: auto;
584
+	      // height: auto;
559 585
 	      padding: 19px 14px 0 14px;
560
-	      max-height: 500px;
561
-	      overflow-y: auto;
586
+	      // max-height: 500px;
587
+	      // overflow-y: auto;
562 588
 				.ant-select{
563 589
 					width: 100%;
564 590
 				}
@@ -641,7 +667,6 @@
641 667
 			background: #f9fafb;
642 668
 			border: 1px solid #e5e9ed;
643 669
 			border-radius: 5px;
644
-			overflow: hidden;
645 670
 			margin-top: 12px;
646 671
 			display: flex;
647 672
 			// .addForm{
@@ -657,7 +682,7 @@
657 682
 					height: auto;
658 683
 					max-height: 460px;
659 684
 					overflow-y: auto;
660
-					width: 75%;
685
+					width: 78%;
661 686
 					padding: 15px;
662 687
 					.form-title-box{
663 688
 						display: flex;
@@ -687,6 +712,11 @@
687 712
 							width: 300px;
688 713
 						}
689 714
 					}
715
+					.error-fix{
716
+						margin-top: 10px;
717
+						color: red;
718
+						text-align: center;
719
+					}
690 720
 					.form-list{
691 721
 						margin-bottom: 10px;
692 722
 						.specimen-list{

+ 204 - 109
src/app/views/specimen-room-view/specimen-room-view.component.ts

@@ -121,7 +121,9 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
121 121
 	isSpinning:boolean = false; //全屏加载状态
122 122
 	codeData:any; //标本条码数据
123 123
 	btnInfoLoading :boolean = false; //标本加固加载
124
+	searchMsg:any = null;
124 125
 	changeInpSubject = new Subject(); //防抖
126
+	changeInpSubjectSpecimen = new Subject(); //防抖
125 127
   ngOnDestroy() {
126 128
     clearTimeout(this.timer);
127 129
     clearTimeout(this.logTimer);
@@ -129,14 +131,16 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
129 131
 
130 132
   ngOnInit() {
131 133
 		this.changeInpSubject.pipe(debounceTime(500)).subscribe((v) => {
132
-		  this.tableLoading = true
133 134
 		  this.searchSpecimenData(v[0])
134 135
 		});
136
+		this.changeInpSubjectSpecimen.pipe(debounceTime(500)).subscribe((v) => {
137
+		  this.searchSpecimen(v[0])
138
+		});
135 139
 		this.hosId = this.tool.getCurrentHospital().id;
136 140
 		this.userId = this.tool.getCurrentUserId()
137 141
     this.runTime();
138 142
     // 统计
139
-    this.total();
143
+    // this.total();
140 144
 		this.getDept()
141 145
     // 切换科室
142 146
     // this.changeKs();
@@ -145,6 +149,9 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
145 149
     // 自动刷新倒计时 start
146 150
     this.autoUpdate();
147 151
     // 自动刷新倒计时 end
152
+		setTimeout(_=>{
153
+			document.getElementById('Binput').focus();
154
+		},200)
148 155
   }
149 156
   // 当前时间日期
150 157
   runTime() {
@@ -156,13 +163,15 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
156 163
   }
157 164
 	
158 165
 	// 标本条码搜索
159
-	searchSpecimen(){
166
+	searchSpecimen(e){
160 167
 		if(!this.barCode){
161
-			this.message.error('请输入标本条码')
168
+			return
169
+		}
170
+		if(this.barCode.length < 10) {
162 171
 			return
163 172
 		}
164 173
 		let data={
165
-			barcode:this.barCode
174
+			barcode:e
166 175
 		}
167 176
 		this.isSpinning = true
168 177
 		clearInterval(this.logTimer);
@@ -171,16 +180,31 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
171 180
 			this.isSpinning = false
172 181
 			if(res.status==200){
173 182
 				this.codeData = res.data[0]
183
+				if(this.codeData.pathologyInspectDTOS){
184
+					this.project = this.codeData.pathologyInspectDTOS.map(i=>{
185
+						return i.inspectProject.name
186
+					})
187
+					this.project = this.project.join('、')
188
+				}
189
+				this.fixationError = null
174 190
 				this.fixationModal = true
175 191
 				setTimeout(_=>{
176 192
 					document.getElementById('specimen').focus();
177 193
 				},200)
194
+				this.searchMsg = null
178 195
 			}else{
179
-				this.message.error(res.msg)
196
+				this.barCode = null
197
+				this.searchMsg = res.msg
198
+				// this.message.error(res.msg)
180 199
 			}
181 200
 		})
182 201
 	}
183 202
 	
203
+	// 选择固定时间
204
+	formChangeDate(result){
205
+	  this.startDate = format(result, 'yyyy-MM-dd HH:mm:ss');
206
+	}
207
+	
184 208
 	// 确定接受固定标本
185 209
 	startDate:any;
186 210
 	submitFixationForm(){
@@ -206,10 +230,15 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
206 230
 		this.autoUpdate()
207 231
 		this.barCode = null;
208 232
 		this.specimenCode = null;
233
+		this.fixationError = null
209 234
 		this.fixationModal = false;
235
+		setTimeout(_=>{
236
+			document.getElementById('Binput').focus();
237
+		},200)
210 238
 	}
211 239
 	
212 240
 	// 获取标本详情
241
+	project:any = [];
213 242
 	getSampleData(item){
214 243
 		this.mainService.getFetchData("data", "pathologyForm", item.id)
215 244
 		.subscribe((data) => {
@@ -218,6 +247,12 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
218 247
 		  this.specimenList = data.data.pathologySpecimenDTOList||[]
219 248
 			this.pathologyLogs = data.data.formLogDTOS
220 249
 			this.stepLength = this.pathologyLogs.length
250
+			if(this.detailsData.pathologyInspectDTOS){
251
+				this.project = this.detailsData.pathologyInspectDTOS.map(i=>{
252
+					return i.inspectProject.name
253
+				})
254
+				this.project = this.project.join('、')
255
+			}
221 256
 		  this.detailMoadl = true
222 257
 		});
223 258
 	}
@@ -313,6 +348,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
313 348
 		this.mainService
314 349
 		  .coopData("updData", "user", data)
315 350
 		  .subscribe((data) => {
351
+				this.getNewDept()
316 352
 				// 手术间列表
317 353
 				this.getPharmacyList(this.printPharmacyIdx, 'surgeryDept', this.printPharmacySearchKey);
318 354
 				// 标本间列表
@@ -329,6 +365,45 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
329 365
 		  });
330 366
 	}
331 367
 	
368
+	getNewDept(){
369
+		let postData = {
370
+		  currentHosId: this.hosId,
371
+		  loginType: "PC",
372
+		};
373
+		this.mainService.changeHospital(postData).subscribe((result) => {
374
+		  if (result.status == 200) {
375
+		    let dataObj = {
376
+		      user: {
377
+		        dept: {
378
+		          id: this.validateForm.value.specimen,
379
+		        },
380
+		        id: JSON.parse(localStorage.getItem("user")).user.id,
381
+		      },
382
+		    };
383
+		    this.mainService
384
+		      .coopData("updData", "user", dataObj)
385
+		      .subscribe((data) => {
386
+		        if (data.status == 200) {
387
+		          this.getCurrentUserNow();
388
+		        }
389
+		      });
390
+		  }
391
+		});
392
+	}
393
+	
394
+	// 获取当前用户信息
395
+	getCurrentUserNow() {
396
+	  this.mainService.getCurrentUser1().subscribe((data:any) => {
397
+	    if (data["status"] == 200) {
398
+				this.loginUser = data.data 
399
+	      let user = JSON.parse(localStorage.getItem("user"));
400
+	      user.user.dept = data["data"].dept;
401
+	      user.user.currentHospital = data["data"].currentHospital;
402
+	      localStorage.setItem("user", JSON.stringify(user));
403
+	    }
404
+	  });
405
+	}
406
+	
332 407
 	// 输入工号查询姓名
333 408
 	handoverUserId:any = null;
334 409
 	numberChange(e){
@@ -336,25 +411,21 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
336 411
 			this.validateVerificationForm.controls.name.setValue('');
337 412
 			return
338 413
 		}
339
-		let data = {
340
-			idx: 0,
341
-			sum: 9999,
342
-			user: {
343
-				account: e || "",
344
-				hospital: { id: this.hosId || "" }
345
-			},
414
+		let query = {
415
+		  account: e
346 416
 		};
347 417
 		this.mainService
348
-			.getFetchDataList("data", "user", data)
349
-			.subscribe((data) => {
350
-				if(data.list.length>0){
351
-					this.validateVerificationForm.controls.name.setValue(data.list[0].name);
352
-					this.handoverUserId = data.list[0].id
418
+		  .jobSearch(query)
419
+		  .subscribe((data:any) => {
420
+				if(data.status==200){
421
+					this.validateVerificationForm.controls.name.setValue(data.userName);
422
+					this.handoverUserId = data.userId
353 423
 				}else{
354 424
 					this.validateVerificationForm.controls.name.setValue('');
355 425
 					this.handoverUserId =null
426
+					// this.message.error(data.data)
356 427
 				}
357
-			});
428
+		  });
358 429
 	}
359 430
 	
360 431
 	// 提交固定标本接收
@@ -371,7 +442,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
371 442
 			specimenFixingLiquid:{
372 443
 				id:this.validateVerificationForm.value.fixative
373 444
 			},
374
-			fixationTime:this.validateVerificationForm.value.fixationTime,
445
+			fixationTime:this.startDate,
375 446
 			hosId: this.hosId || "" ,
376 447
 			handoverUserId:this.handoverUserId
377 448
 		};
@@ -399,11 +470,23 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
399 470
 	closeModel(){
400 471
 		this.verificationMoadl = false
401 472
 		this.fixationModal = false
473
+		setTimeout(_=>{
474
+			document.getElementById('Binput').focus();
475
+		},200)
402 476
 	}
403 477
 	
404 478
 	// 关闭固定接受标本
405 479
 	hideVerificationModal(){
406 480
 		this.verificationMoadl = false
481
+		setTimeout(_=>{
482
+			document.getElementById('Binput').focus();
483
+		},200)
484
+	}
485
+	
486
+
487
+	// 监听标本条码
488
+	specimenCodeChange(e){
489
+		this.changeInpSubjectSpecimen.next([e]);
407 490
 	}
408 491
 	
409 492
 	// 监听接受固定标本条码
@@ -412,7 +495,15 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
412 495
 		this.changeInpSubject.next([e]);
413 496
 	}
414 497
 	
498
+	fixationError:any;
415 499
 	searchSpecimenData(e){
500
+		if(!e){
501
+			return
502
+		}
503
+		if(e.length < 10) {
504
+			return
505
+		}
506
+		this.tableLoading = true
416 507
 		this.mainService.pathologyScanCode({
417 508
 			barcode:e,
418 509
 			pathologyFormId:this.codeData.id
@@ -423,8 +514,9 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
423 514
 			this.specimenCode = null
424 515
 			if(res.status==200){
425 516
 				this.codeData = res.data[0]
517
+				this.fixationError = null 
426 518
 			}else{
427
-				this.message.error(res.msg)
519
+				this.fixationError = res.msg 
428 520
 			}
429 521
 		})
430 522
 	}
@@ -448,75 +540,78 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
448 540
 	}
449 541
 	
450 542
 	closeDetailMoadl(){
543
+		setTimeout(_=>{
544
+			document.getElementById('Binput').focus();
545
+		},200)
451 546
 		this.detailMoadl = false
452 547
 		this.autoUpdate(false);
453 548
 	}
454 549
 	
455 550
   // 统计
456
-  total() {
457
-    let launch = JSON.parse(localStorage.getItem("user")).user.dept.id;
458
-    let startTime = format(startOfDay(new Date()), "yyyy-MM-dd HH:mm:ss");
459
-    let endTime = format(endOfDay(new Date()), "yyyy-MM-dd HH:mm:ss");
460
-    let postData = {
461
-      startTime,
462
-      endTime,
463
-      launch,
464
-    };
551
+  // total() {
552
+  //   let launch = JSON.parse(localStorage.getItem("user")).user.dept.id;
553
+  //   let startTime = format(startOfDay(new Date()), "yyyy-MM-dd HH:mm:ss");
554
+  //   let endTime = format(endOfDay(new Date()), "yyyy-MM-dd HH:mm:ss");
555
+  //   let postData = {
556
+  //     startTime,
557
+  //     endTime,
558
+  //     launch,
559
+  //   };
465 560
 
466
-    this.mainService.getDrugsBagStateCount(postData).subscribe((res: any) => {
467
-      if (res.status == 200) {
468
-        this.todayTotal = res.countMap.todayTotal;
469
-        this.todayComplete = res.countMap.todayComplete;
470
-      }
471
-    });
472
-  }
473
-  // 查看工单详情
474
-  goToOrderDetail(item){
475
-    console.log(item);
476
-    this.router.navigateByUrl(`specimenView2/detailSample/${item.id}`);
477
-  }
561
+  //   this.mainService.getDrugsBagStateCount(postData).subscribe((res: any) => {
562
+  //     if (res.status == 200) {
563
+  //       this.todayTotal = res.countMap.todayTotal;
564
+  //       this.todayComplete = res.countMap.todayComplete;
565
+  //     }
566
+  //   });
567
+  // }
568
+  // // 查看工单详情
569
+  // goToOrderDetail(item){
570
+  //   console.log(item);
571
+  //   this.router.navigateByUrl(`specimenView2/detailSample/${item.id}`);
572
+  // }
478 573
 	
479
-  // 查看流程信息弹窗
480
-  logPromptModalShow = false; //弹窗开关
481
-  scode = ""; //查看记录携带
482
-  showLogs(data) {
483
-    clearInterval(this.logTimer);
484
-    this.scode = data.scode;
485
-    this.logPromptModalShow = true;
486
-  }
487
-  // 关闭流程信息弹窗
488
-  closeModelLog(e) {
489
-    this.logPromptModalShow = JSON.parse(e).show;
490
-    this.autoUpdate(false);
491
-  }
492
-  // 查看标本列表弹窗
493
-  spePromptModalShow = false; //弹窗开关
494
-  checkDeptId = ""; //检查科室id
495
-  printDate = ""; //采集日期
496
-  showSpeList(data) {
497
-    clearInterval(this.logTimer);
498
-    this.checkDeptId = data.check_dept_id;
499
-    this.printDate = data.startTime;
500
-    this.spePromptModalShow = true;
501
-  }
574
+  // // 查看流程信息弹窗
575
+  // logPromptModalShow = false; //弹窗开关
576
+  // scode = ""; //查看记录携带
577
+  // showLogs(data) {
578
+  //   clearInterval(this.logTimer);
579
+  //   this.scode = data.scode;
580
+  //   this.logPromptModalShow = true;
581
+  // }
582
+  // // 关闭流程信息弹窗
583
+  // closeModelLog(e) {
584
+  //   this.logPromptModalShow = JSON.parse(e).show;
585
+  //   this.autoUpdate(false);
586
+  // }
587
+  // // 查看标本列表弹窗
588
+  // spePromptModalShow = false; //弹窗开关
589
+  // checkDeptId = ""; //检查科室id
590
+  // printDate = ""; //采集日期
591
+  // showSpeList(data) {
592
+  //   clearInterval(this.logTimer);
593
+  //   this.checkDeptId = data.check_dept_id;
594
+  //   this.printDate = data.startTime;
595
+  //   this.spePromptModalShow = true;
596
+  // }
502 597
   // 关闭标本列表弹窗
503
-  closeModelSpe(e) {
504
-    this.spePromptModalShow = JSON.parse(e).show;
505
-    this.autoUpdate(false);
506
-  }
507
-   // 查看工单列表弹窗
508
-   orderPromptModalShow = false; //弹窗开关
509
-   workId = ""; //配送人员ID
510
-   showOrderList(data) {
511
-     clearInterval(this.logTimer);
512
-     this.workId = data.workerid;
513
-     this.orderPromptModalShow = true;
514
-   }
515
-   // 关闭工单列表弹窗
516
-   closeModelOrder(e) {
517
-     this.orderPromptModalShow = JSON.parse(e).show;
518
-     this.autoUpdate(false);
519
-   }
598
+  // closeModelSpe(e) {
599
+  //   this.spePromptModalShow = JSON.parse(e).show;
600
+  //   this.autoUpdate(false);
601
+  // }
602
+  //  // 查看工单列表弹窗
603
+  //  orderPromptModalShow = false; //弹窗开关
604
+  //  workId = ""; //配送人员ID
605
+  //  showOrderList(data) {
606
+  //    clearInterval(this.logTimer);
607
+  //    this.workId = data.workerid;
608
+  //    this.orderPromptModalShow = true;
609
+  //  }
610
+  //  // 关闭工单列表弹窗
611
+  //  closeModelOrder(e) {
612
+  //    this.orderPromptModalShow = JSON.parse(e).show;
613
+  //    this.autoUpdate(false);
614
+  //  }
520 615
   // 自动刷新倒计时
521 616
   autoUpdate(flag = true) {
522 617
     if (flag) {
@@ -646,33 +741,33 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
646 741
       });
647 742
   }
648 743
   // 加载更多
649
-  loadMore(type) {
650
-    switch (type) {
651
-      case 'surgeryDept':
652
-        this.printPharmacyIdx++;
653
-        this.printPharmacyLoad = true;
654
-        this.getPharmacyList(
655
-          this.printPharmacyIdx,
656
-          type,
657
-          this.printPharmacySearchKey
658
-        );
659
-        break;
660
-      case 'specimenDept':
661
-        this.waitPharmacyIdx++;
662
-        this.waitPharmacyLoad = true;
663
-        this.getPharmacyList(
664
-          this.waitPharmacyIdx,
665
-          type,
666
-          this.waitPharmacySearchKey
667
-        );
668
-        break;
669
-      case 'leavedDept':
670
-        this.pharmacyIdx++;
671
-        this.pharmacyLoad = true;
672
-        this.getPharmacyList(this.pharmacyIdx, type, this.pharmacySearchKey);
673
-        break;
674
-    }
675
-  }
744
+  // loadMore(type) {
745
+  //   switch (type) {
746
+  //     case 'surgeryDept':
747
+  //       this.printPharmacyIdx++;
748
+  //       this.printPharmacyLoad = true;
749
+  //       this.getPharmacyList(
750
+  //         this.printPharmacyIdx,
751
+  //         type,
752
+  //         this.printPharmacySearchKey
753
+  //       );
754
+  //       break;
755
+  //     case 'specimenDept':
756
+  //       this.waitPharmacyIdx++;
757
+  //       this.waitPharmacyLoad = true;
758
+  //       this.getPharmacyList(
759
+  //         this.waitPharmacyIdx,
760
+  //         type,
761
+  //         this.waitPharmacySearchKey
762
+  //       );
763
+  //       break;
764
+  //     case 'leavedDept':
765
+  //       this.pharmacyIdx++;
766
+  //       this.pharmacyLoad = true;
767
+  //       this.getPharmacyList(this.pharmacyIdx, type, this.pharmacySearchKey);
768
+  //       break;
769
+  //   }
770
+  // }
676 771
   // 搜索关键词
677 772
   searchKeyHandle(type) {
678 773
     switch (type) {