Bladeren bron

拉取代码

maotao 3 maanden geleden
bovenliggende
commit
75dc7970f9
21 gewijzigde bestanden met toevoegingen van 1350 en 405 verwijderingen
  1. 24 20
      src/app/share/pathology-add/pathology-add.component.html
  2. 5 2
      src/app/share/pathology-add/pathology-add.component.less
  3. 34 18
      src/app/share/pathology-add/pathology-add.component.ts
  4. 14 11
      src/app/share/pathology-detail/pathology-detail.component.html
  5. 24 0
      src/app/views/batch-distribution/batch-distribution-routing.module.ts
  6. 117 0
      src/app/views/batch-distribution/batch-distribution.component.html
  7. 249 0
      src/app/views/batch-distribution/batch-distribution.component.less
  8. 193 0
      src/app/views/batch-distribution/batch-distribution.component.ts
  9. 19 0
      src/app/views/batch-distribution/batch-distribution.module.ts
  10. 10 13
      src/app/views/hushijiandan/hushijiandan.component.html
  11. 61 5
      src/app/views/hushijiandan/hushijiandan.component.less
  12. 9 61
      src/app/views/hushijiandan/hushijiandan.component.ts
  13. 5 0
      src/app/views/main/main-routing.module.ts
  14. 137 106
      src/app/views/pathology-communication-book/pathology-communication-book.component.html
  15. 122 1
      src/app/views/pathology-communication-book/pathology-communication-book.component.ts
  16. 56 52
      src/app/views/pathology-sample/pathology-sample.component.html
  17. 7 2
      src/app/views/pathology-sample/pathology-sample.component.less
  18. 59 32
      src/app/views/pathology-sample/pathology-sample.component.ts
  19. 31 10
      src/app/views/specimen-room-view/specimen-room-view.component.html
  20. 119 36
      src/app/views/specimen-room-view/specimen-room-view.component.less
  21. 55 36
      src/app/views/specimen-room-view/specimen-room-view.component.ts

+ 24 - 20
src/app/share/pathology-add/pathology-add.component.html

@@ -9,6 +9,7 @@
9 9
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
10 10
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
11 11
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
12
+						<div class="form-title" *ngIf="detailsData.pathologyFormType==2">申请单类型:病理细胞学申请单</div>
12 13
 						<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
13 14
 					</nz-form-item>
14 15
 					<nz-form-item class="form-title-box">
@@ -195,7 +196,7 @@
195 196
 					</div>
196 197
 				</nz-form-item>
197 198
 				
198
-				<nz-form-item class="form-item">
199
+	<!-- 			<nz-form-item class="form-item">
199 200
 					<nz-form-label [nzSm]="4" [nzXs]="24">快捷键入</nz-form-label>
200 201
 					<div class="specimen-list">
201 202
 						<div *ngFor="let item of fastList;let index=index;" class="select-item"
@@ -203,16 +204,16 @@
203 204
 							{{item.name}}
204 205
 						</div>
205 206
 					</div>
206
-				</nz-form-item>
207
+				</nz-form-item> -->
207 208
 				
208 209
 				<nz-form-item class="form-item">
209 210
 					<nz-form-label nzRequired nzFor="specimenName" [nzSm]="3" [nzXs]="24">标本名称</nz-form-label>
210 211
 					<div class="specimen-tip" [ngClass]="{'isSpecumen':placeName}">{{placeName?placeName:''}}</div>
211 212
 					<nz-form-control nzErrorTip="请输入标本名称" [(nzSm)]="nzSmNum" [nzXs]="24">
212
-						<input nz-input maxlength="15" (ngModelChange)="specimenInput($event)" formControlName="specimenName" placeholder="请输入标本名称"/>
213
+						<input nz-input maxlength="20" (ngModelChange)="specimenInput($event)" formControlName="specimenName" placeholder="请输入标本名称"/>
213 214
 					</nz-form-control>
214
-					<div class="empty-box" [ngClass]="{'beSpecumenEmpty':placeName, 'noSpecumenEmpty':placeName==''}">
215
-						<span class="name">{{specimenNameLength}}/15</span>
215
+					<div class="empty-box" [ngClass]="{'beSpecumenEmpty':placeName, 'noSpecumenEmpty':!placeName}">
216
+						<span class="name">{{specimenNameLength}}/20</span>
216 217
 						<span class="empty" (click)="emptData($event)">清空</span>
217 218
 					</div>
218 219
 				</nz-form-item>
@@ -273,7 +274,7 @@
273 274
 						</nz-input-group>
274 275
 					</nz-form-control>
275 276
 				</nz-form-item>
276
-				<nz-form-item *ngIf="ifImmobilization">
277
+				<nz-form-item *ngIf="ifImmobilization && detailsData.pathologyFormType==0">
277 278
 				  <nz-form-label nzRequired [nzSpan]="6" nzFor="fixationTime">固定时间</nz-form-label>
278 279
 				  <nz-form-control style="display: flex;align-items: center;" [nzSpan]="18" nzErrorTip="请选择固定时间!">
279 280
 				    <nz-input-group style="display: flex;gap: 10px">
@@ -286,7 +287,7 @@
286 287
 						</nz-input-group>
287 288
 				  </nz-form-control>
288 289
 				</nz-form-item>
289
-				<nz-form-item *ngIf="ifImmobilization">
290
+				<nz-form-item *ngIf="ifImmobilization && detailsData.pathologyFormType==0">
290 291
 				  <nz-form-label nzRequired [nzSpan]="8" nzFor="fixative">固定液类型</nz-form-label>
291 292
 				  <nz-form-control [nzSpan]="16" nzErrorTip="请选择固定液类型!">
292 293
 				    <nz-input-group>
@@ -304,10 +305,10 @@
304 305
 						<input nz-input (ngModelChange)="numberChange($event)" formControlName="jobNumber" placeholder="请输入工号" nzSize="default" />
305 306
 					</nz-form-control>
306 307
 				</nz-form-item>
307
-				<nz-form-item class="df">
308
+				<nz-form-item>
308 309
 				  <nz-form-label nzRequired [nzSpan]="5">姓名</nz-form-label>
309
-					<nz-form-control [nzSpan]="19" nzErrorTip="请输入工号!">
310
-						<input nz-input disabled formControlName="name" placeholder="请输入工号" nzSize="default" />
310
+					<nz-form-control [nzSpan]="19" nzErrorTip="请输入姓名!">
311
+						<input nz-input disabled formControlName="name" placeholder="请输入姓名" nzSize="default" />
311 312
 					</nz-form-control>
312 313
 				</nz-form-item>
313 314
 			</form>
@@ -455,7 +456,7 @@
455 456
 								<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
456 457
 							</div>
457 458
 							<div style="margin-top:10px;">
458
-								<div style="width: 100%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
459
+								<div style="width: 98%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
459 460
 							</div>
460 461
 						 </div>
461 462
 						 <div style="width: 30%;">
@@ -481,26 +482,29 @@
481 482
 			<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
482 483
 				<div *ngFor="let data of printData.specimenList; let index=index;">
483 484
 					<div style="width: 100%;display: flex;margin-top: 5px;padding: 0 7px;">
484
-					 <div style="width: 46%;">
485
-						 <div style="display: flex;justify-content: center;">
485
+					 <div style="width: 35%;">
486
+						 <div style="display: flex;">
486 487
 							 <div style="width: 50px;height: 50px;">
487 488
 							 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
488 489
 							 </div>
489
-							 <div style="width: 12px;">申请单</div>
490
+							 <!-- <div style="width: 12px;">申请单</div> -->
490 491
 						 </div>
491 492
 						 <div>{{printData.applyCode}}</div>
492 493
 					 </div>
493
-					 <div style="width: 4%;"></div>
494
-					 <div style="width: 49%;">
494
+					 <div style="width: 5%;"></div>
495
+					 <div style="width: 60%;position: relative;left: -5px;">
495 496
 						<div style="display: flex;flex-wrap: nowrap;">住院号: {{data.residenceNo}}</div>
496 497
 						<div style="margin-top:9px;">患者: {{data.patientName}}</div>
497
-						<div style="margin-top:9px;margin-left: 25px;">性别: {{data.patientGender}}</div>
498
+						<div style="margin-top:9px;margin-left: 30px;">性别: {{data.patientGender}}</div>
498 499
 					 </div>
499 500
 					</div>
500
-					<div style="margin-top:10px;padding-left: 7px;">
501
-						<div style="width: 100%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
501
+					<div style="margin-top:3px;padding-left: 7px;">
502
+						<div style="width: 98%;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
503
+					</div>
504
+					<div style="margin-top:3px;padding-left: 7px;">
505
+						<div style="width: 98%;">日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
502 506
 					</div>
503
-				 <div style="height: 11px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1 && index+1 < printData.specimenList.length"></div>
507
+				 <div style="height: 18px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1 && index+1 < printData.specimenList.length"></div>
504 508
 				</div>
505 509
 			</div>
506 510
 		</div>

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

@@ -269,11 +269,11 @@
269 269
 						}
270 270
 					}
271 271
 					.beSpecumenEmpty{
272
-						right: 6px;
272
+						right: 10px;
273 273
 						top: 8px;
274 274
 					}
275 275
 					.noSpecumenEmpty{
276
-						right: 6px;
276
+						right: 10px;
277 277
 						top: 8px;
278 278
 					}
279 279
 				}
@@ -307,6 +307,9 @@
307 307
 	  }
308 308
 		.no-width{
309 309
 			width: 33% !important;
310
+			.ant-select{
311
+				width: 100% !important;
312
+			}
310 313
 			.ant-input-disabled{
311 314
 				color: rgba(0, 0, 0, 0.65) !important;
312 315
 				background: #fff !important;

+ 34 - 18
src/app/share/pathology-add/pathology-add.component.ts

@@ -517,8 +517,8 @@ export class PathologyAddComponent implements OnInit {
517 517
 			this.specimenNameId = item.id
518 518
 			this.specimenNameName = item.name
519 519
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
520
-				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>14){
521
-					this.message.error('字符长度不能超过15个')
520
+				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>19){
521
+					this.message.error('字符长度不能超过20个')
522 522
 					return
523 523
 				}
524 524
 			}
@@ -542,8 +542,8 @@ export class PathologyAddComponent implements OnInit {
542 542
 	fastClick(e,item,index){
543 543
 		this.fastIndex = index
544 544
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
545
-				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>14){
546
-					this.message.error('字符长度不能超过15个')
545
+				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>19){
546
+					this.message.error('字符长度不能超过20个')
547 547
 					return
548 548
 				}
549 549
 			}
@@ -586,8 +586,8 @@ export class PathologyAddComponent implements OnInit {
586 586
 		  this.validateSpecimenForm.controls[i].updateValueAndValidity();
587 587
 		}
588 588
 		if (this.validateSpecimenForm.invalid) return;
589
-		if(this.validateSpecimenForm.value.specimenName.length>15){
590
-			this.message.error('字符长度不能超过15个')
589
+		if(this.validateSpecimenForm.value.specimenName.length>19){
590
+			this.message.error('字符长度不能超过20个')
591 591
 			return
592 592
 		}
593 593
 		if(type==2){
@@ -705,7 +705,7 @@ export class PathologyAddComponent implements OnInit {
705 705
 	// 监听输入字数
706 706
 	specimenNameLength:any=0;
707 707
 	specimenInput(e){
708
-		if(e.length>15){
708
+		if(e.length>20){
709 709
 			return
710 710
 		}
711 711
 		this.specimenNameLength = e.length
@@ -766,9 +766,13 @@ export class PathologyAddComponent implements OnInit {
766 766
 		this.fixationData = format(result, 'yyyy-MM-dd');
767 767
 		console.log(this.fixationData)
768 768
 	}
769
-	fixationTimeSelect:any;
769
+	fixationTimeSelect:any = null;
770 770
 	fixationTimeChange(result){
771
-		this.fixationTimeSelect = format(result, 'HH:mm');
771
+		if(result){
772
+			this.fixationTimeSelect = format(result, 'HH:mm');
773
+		}else{
774
+			this.fixationTimeSelect = null
775
+		}
772 776
 		console.log(this.fixationData + ' ' + this.fixationTimeSelect)
773 777
 	}
774 778
 	
@@ -779,9 +783,13 @@ export class PathologyAddComponent implements OnInit {
779 783
 		this.inVitroData = format(result, 'yyyy-MM-dd');
780 784
 		console.log(this.inVitroData)
781 785
 	}
782
-	inVitroTimeSelect:any;
786
+	inVitroTimeSelect:any = null;
783 787
 	inVitroTimeChange(result){
784
-		this.inVitroTimeSelect = format(result, 'HH:mm');
788
+		if(result){
789
+			this.inVitroTimeSelect = format(result, 'HH:mm');
790
+		}else{
791
+			this.inVitroTimeSelect = null;
792
+		}
785 793
 		console.log(this.inVitroData + ' ' + this.inVitroTimeSelect)
786 794
 	}
787 795
 	
@@ -789,6 +797,14 @@ export class PathologyAddComponent implements OnInit {
789 797
 	printLoading:boolean = false;
790 798
 	submitPrintForm(): void{
791 799
 		let that = this
800
+		if(this.ifImmobilization && this.detailsData.pathologyFormType==0 && (!this.fixationTimeSelect || this.fixationTimeSelect == null)){
801
+			this.message.error('请选择固定时间')
802
+			return
803
+		}
804
+		if(!this.inVitroTimeSelect || this.inVitroTimeSelect == null){
805
+			this.message.error('请选择离体时间')
806
+			return
807
+		}
792 808
 		for (const i in this.validatePrintForm.controls) {
793 809
 		  this.validatePrintForm.controls[i].markAsDirty();
794 810
 		  this.validatePrintForm.controls[i].updateValueAndValidity();
@@ -828,7 +844,7 @@ export class PathologyAddComponent implements OnInit {
828 844
 			delete data.operation
829 845
 			delete data.pathologySpecimenIds
830 846
 		}
831
-		if(this.ifImmobilization){
847
+		if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
832 848
 			data.pathologyForm.fixationTime = this.fixationData + ' ' + this.fixationTimeSelect +':00'
833 849
 			data.pathologyForm.specimenFixingLiquid.id = this.validatePrintForm.value.fixative
834 850
 		}else{
@@ -969,7 +985,7 @@ export class PathologyAddComponent implements OnInit {
969 985
 				let date = new Date();
970 986
 				
971 987
 				let inVitroDate = format(date, "yyyy-MM-dd")
972
-				if(this.ifImmobilization){
988
+				if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
973 989
 					this.validatePrintForm = this.fb.group({
974 990
 						inVitroTimes: [null, [Validators.required]],
975 991
 						inVitroDate: [null, [Validators.required]],
@@ -985,7 +1001,7 @@ export class PathologyAddComponent implements OnInit {
985 1001
 					this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
986 1002
 					// this.validatePrintForm.controls.fixationTimes.setValue(date);
987 1003
 					this.fixationData = inVitroDate;
988
-					this.fixationTimeSelect = format(date, 'HH:mm');
1004
+					this.fixationTimeSelect = null;
989 1005
 				}else{
990 1006
 					this.validatePrintForm = this.fb.group({
991 1007
 						inVitroTimes: [null, [Validators.required]],
@@ -1030,7 +1046,7 @@ export class PathologyAddComponent implements OnInit {
1030 1046
 					let date = new Date();
1031 1047
 					
1032 1048
 					let inVitroDate = format(date, "yyyy-MM-dd")
1033
-					if(this.ifImmobilization){
1049
+					if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
1034 1050
 						this.validatePrintForm = this.fb.group({
1035 1051
 							inVitroTimes: [null, [Validators.required]],
1036 1052
 							inVitroDate: [null, [Validators.required]],
@@ -1045,7 +1061,7 @@ export class PathologyAddComponent implements OnInit {
1045 1061
 						this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
1046 1062
 						// this.validatePrintForm.controls.fixationTimes.setValue(date);
1047 1063
 						this.fixationData = inVitroDate;
1048
-						this.fixationTimeSelect = format(date, 'HH:mm');
1064
+						this.fixationTimeSelect = null;
1049 1065
 					}else{
1050 1066
 						this.validatePrintForm = this.fb.group({
1051 1067
 							inVitroTimes: [null, [Validators.required]],
@@ -1101,7 +1117,7 @@ export class PathologyAddComponent implements OnInit {
1101 1117
 					let date = new Date();
1102 1118
 					
1103 1119
 					let inVitroDate = format(date, "yyyy-MM-dd")
1104
-					if(this.ifImmobilization){
1120
+					if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
1105 1121
 						this.validatePrintForm = this.fb.group({
1106 1122
 							inVitroTimes: [null, [Validators.required]],
1107 1123
 							inVitroDate: [null, [Validators.required]],
@@ -1116,7 +1132,7 @@ export class PathologyAddComponent implements OnInit {
1116 1132
 						this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
1117 1133
 						// this.validatePrintForm.controls.fixationTimes.setValue(date);
1118 1134
 						this.fixationData = inVitroDate;
1119
-						this.fixationTimeSelect = format(date, 'HH:mm');
1135
+						this.fixationTimeSelect = null;
1120 1136
 					}else{
1121 1137
 						this.validatePrintForm = this.fb.group({
1122 1138
 							inVitroTimes: [null, [Validators.required]],

+ 14 - 11
src/app/share/pathology-detail/pathology-detail.component.html

@@ -5,7 +5,7 @@
5 5
 			<div class="content">
6 6
 				<div class="content-item boder-right">
7 7
 					<nz-form-item class="form-title-box">
8
-						<div class="form-title">申请单类型:{{detailsData.pathologyFormType==1?'术中快速病理检查申请单':'病理检查申请单'}}</div>
8
+						<div class="form-title">申请单类型:{{detailsData.pathologyFormType==1?'术中快速病理检查申请单' : detailsData.pathologyFormType==2 ? '病理细胞学申请单' : '病理检查申请单'}}</div>
9 9
 						<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
10 10
 					</nz-form-item>
11 11
 					<nz-form-item class="form-title-box">
@@ -243,7 +243,7 @@
243 243
 								<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
244 244
 							</div>
245 245
 							<div style="margin-top:10px;">
246
-								<div style="width: 100%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
246
+								<div style="width: 98%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
247 247
 							</div>
248 248
 						 </div>
249 249
 						 <div style="width: 30%;">
@@ -269,26 +269,29 @@
269 269
 			<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
270 270
 				<div *ngFor="let data of printData.specimenList; let index=index;">
271 271
 					<div style="width: 100%;display: flex;margin-top: 5px;padding: 0 7px;">
272
-					 <div style="width: 46%;">
273
-						 <div style="display: flex;justify-content: center;">
272
+					 <div style="width: 35%;">
273
+						 <div style="display: flex;">
274 274
 							 <div style="width: 50px;height: 50px;">
275 275
 							 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
276 276
 							 </div>
277
-							 <div style="width: 12px;">申请单</div>
277
+							 <!-- <div style="width: 12px;">申请单</div> -->
278 278
 						 </div>
279 279
 						 <div>{{printData.applyCode}}</div>
280 280
 					 </div>
281
-					 <div style="width: 4%;"></div>
282
-					 <div style="width: 49%;">
281
+					 <div style="width: 5%;"></div>
282
+					 <div style="width: 60%;position: relative;left: -5px;">
283 283
 						<div style="display: flex;flex-wrap: nowrap;">住院号: {{data.residenceNo}}</div>
284 284
 						<div style="margin-top:9px;">患者: {{data.patientName}}</div>
285
-						<div style="margin-top:9px;margin-left: 25px;">性别: {{data.patientGender}}</div>
285
+						<div style="margin-top:9px;margin-left: 30px;">性别: {{data.patientGender}}</div>
286 286
 					 </div>
287 287
 					</div>
288
-					<div style="margin-top:10px;padding-left: 7px;">
289
-						<div style="width: 100%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
288
+					<div style="margin-top:3px;padding-left: 7px;">
289
+						<div style="width: 98%;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
290 290
 					</div>
291
-				 <div style="height: 11px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1 && index+1 < printData.specimenList.length"></div>
291
+					<div style="margin-top:3px;padding-left: 7px;">
292
+						<div style="width: 98%;">日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
293
+					</div>
294
+				 <div style="height: 18px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1 && index+1 < printData.specimenList.length"></div>
292 295
 				</div>
293 296
 			</div>
294 297
 		</div>

+ 24 - 0
src/app/views/batch-distribution/batch-distribution-routing.module.ts

@@ -0,0 +1,24 @@
1
+import { NgModule } from '@angular/core';
2
+import { Routes, RouterModule } from '@angular/router';
3
+import { BatchDistributionComponent } from './batch-distribution.component';
4
+
5
+
6
+const routes: Routes = [
7
+  {
8
+    path: '',
9
+    component: BatchDistributionComponent,
10
+    // children: [
11
+    //   {
12
+    //     // 查看详情
13
+    //     path: 'officeDetail/:id',
14
+    //     loadChildren: () => import('../office-detail/office-detail.module').then(m => m.OfficeDetailModule),
15
+    //   }
16
+    // ]
17
+  }
18
+];
19
+
20
+@NgModule({
21
+  imports: [RouterModule.forChild(routes)],
22
+  exports: [RouterModule]
23
+})
24
+export class BatchDistributionRoutingModule { }

+ 117 - 0
src/app/views/batch-distribution/batch-distribution.component.html

@@ -0,0 +1,117 @@
1
+<div class="list-template">
2
+  <div class="list-template__content">
3
+    <div class="list-template__top" nz-row>
4
+      <div nz-col nzLg='20' class="list-template__searchBox">
5
+        <div class="list-template__searchItem">
6
+          <span class="label">批次号:</span>
7
+          <input nz-input class="formItem" [(ngModel)]="batchNumber" placeholder="请输入批次号" nzSize="default" />
8
+        </div>
9
+        <div class="list-template__searchItem">
10
+          <span class="label">创建时间:</span>
11
+          <nz-range-picker [(ngModel)]="dateRange" nzFormat="yyyy-MM-dd HH:mm:ss"
12
+					(ngModelChange)="changeDate($event)"></nz-range-picker>
13
+        </div>
14
+      </div>
15
+      <div nz-col nzLg="4" class="list-template__btns">
16
+        <button class="btn default" (click)='search()'>搜索</button>
17
+        <button class="btn default ml8" (click)='reset()'>重置</button>
18
+      </div>
19
+    </div>
20
+    <div class="list-template__bottom">
21
+      <nz-table class="list-template__nzTable" [nzData]="listOfData" nzSize="middle" [nzShowPagination]="false"
22
+        [nzLoading]="loading1">
23
+        <thead>
24
+          <tr class="thead">
25
+						<th>批次号</th>
26
+            <th>创建时间</th>
27
+						<th>核对人</th>
28
+						<th>配送人</th>
29
+						<th>申请单数</th>
30
+            <th>标本数</th>
31
+            <th nzWidth="120px">操作</th>
32
+          </tr>
33
+        </thead>
34
+        <tbody v-if="listOfData && listOfData.length>0">
35
+          <tr *ngFor="let data of listOfData">
36
+            <td>{{ data.batchNo || '-' }}</td>
37
+            <td>{{ data.createTime|date:'yyyy-MM-dd HH:mm'}}</td>
38
+            <td>{{ data.checkUserDTO?data.checkUserDTO.name:'' }}</td>
39
+						<td>{{ data.deliverUserDTO?data.deliverUserDTO.name:'' }}</td>
40
+						<td>{{ data.pathologyFormNum||'0' }}</td>
41
+						<td>{{ data.specimenNum||'0' }}</td>
42
+            <td>
43
+              <div class="coop">
44
+                <span *ngIf="coopBtns.look" (click)="viewSingle(data)">查看申请单</span>
45
+              </div>
46
+            </td>
47
+          </tr>
48
+        </tbody>
49
+      </nz-table>
50
+      <div class="list-template__pagination">
51
+        <nz-pagination [(nzPageIndex)]="pageIndex" [(nzTotal)]="listLength" nzShowSizeChanger [(nzPageSize)]="pageSize"
52
+          (nzPageIndexChange)="getList()" (nzPageSizeChange)="getList()">
53
+        </nz-pagination>
54
+      </div>
55
+    </div>
56
+  </div>
57
+
58
+  <!-- 查看申请单 -->
59
+  <div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="modal">
60
+    <div class="modalBody">
61
+      <div class="title">申请单列表<i class="icon_transport transport-guanbi" (click)="hideModal()"></i>
62
+      </div>
63
+      <overlay-scrollbars #osComponentRef1 class="content">
64
+        <div class="list-template__bottom">
65
+        	<nz-table class="list-template__nzTable" [nzData]="viewData" nzSize="middle" [nzShowPagination]="false"
66
+        		[nzLoading]="grossLoading">
67
+        		<thead>
68
+        			<tr class="thead">
69
+        				<th>申请单类型</th>
70
+        				<th>申请单号</th>
71
+								<th>申请科室</th>
72
+								<th>操作科室</th>
73
+								<th>患者信息</th>
74
+        				<th nzWidth="20%">检验项目</th>
75
+								<th>部位</th>
76
+        				<th>标本数</th>
77
+        				<th nzWidth="100px">操作</th>
78
+        			</tr>
79
+        		</thead>
80
+        		<tbody>
81
+        			<tr *ngFor="let data of viewData">
82
+        				<td *ngIf="data.pathologyFormType==1" class="red">术中快速</td>
83
+        				<td *ngIf="data.pathologyFormType==0">普通病理</td>
84
+        				<td *ngIf="data.pathologyFormType==2">病理细胞学</td>
85
+        				<td style="text-decoration: underline;cursor: pointer;" (click)="itemClick(data)">{{ data.applyCode}}</td>
86
+        				<td>{{ data.patientDTO? data.patientDTO.department.dept:'-'}}</td>
87
+								<td>{{ data.surgeryDeptDTO? data.surgeryDeptDTO.dept:'-'}}</td>
88
+        				<td>{{ data.patientDTO.patientName}} ({{data.patientDTO.bedNum}}床)</td>
89
+								<td>{{ data.arr ? data.arr.join('、') : '无' }}</td>
90
+								<td>{{ data.takePart}}</td>
91
+								<td>{{ data.specimenNum}}</td>
92
+        				<td>
93
+        				  <div class="coop">
94
+        				    <span (click)="itemClick(data)">查看</span>
95
+        				  </div>
96
+        				</td>
97
+        			</tr>
98
+        		</tbody>
99
+        	</nz-table>
100
+        </div>
101
+      </overlay-scrollbars>
102
+      <div class="display_flex justify-content_flex-center">
103
+        <button class="btn" nz-button nzType="primary" (click)="hideModal()">知道了</button>
104
+      </div>
105
+    </div>
106
+  </div>
107
+</div>
108
+
109
+<!-- 病理详情 -->
110
+<app-pathology-detail *ngIf="pathologyDetailModal" [surgeryId]="detailItem.surgeryId" [patientId]="detailItem.patientId" [detailId]="detailItem.id" (pathologyCancel)="pathologyDetailCancel($event)"></app-pathology-detail>
111
+
112
+<!-- 操作成功/失败提示框 -->
113
+<app-prompt-modal *ngIf="promptModalShow" [content]="promptContent" [success]="ifSuccess" [show]="promptModalShow"
114
+  [info]="promptInfo"></app-prompt-modal>
115
+
116
+<!-- 遮罩 -->
117
+<app-mask *ngIf="maskFlag"></app-mask>

+ 249 - 0
src/app/views/batch-distribution/batch-distribution.component.less

@@ -0,0 +1,249 @@
1
+@import "../../../../src/theme.less";
2
+:host {
3
+  .add-button {
4
+    margin: 0 auto 16px !important;
5
+  }
6
+  .targetDept {
7
+    overflow: hidden;
8
+    // width: 90px;
9
+    text-overflow: ellipsis;
10
+    white-space: nowrap;
11
+  }
12
+  .dynamic {
13
+    margin-bottom: 16px;
14
+    display: flex;
15
+    align-items: center;
16
+    input {
17
+      width: 90%;
18
+    }
19
+    i {
20
+      margin-left: 8px;
21
+      cursor: pointer;
22
+      font-size: 18px;
23
+    }
24
+  }
25
+}
26
+
27
+.save {
28
+  position: fixed;
29
+  left: 0;
30
+  top: 0;
31
+  width: 100%;
32
+  height: 100%;
33
+  background: rgba(0, 0, 0, 0.4);
34
+  z-index: 99;
35
+
36
+  .modalBody {
37
+    width: 350px;
38
+    background: #fff;
39
+    border-radius: 5px;
40
+    padding: 10px 20px;
41
+    color: #333;
42
+
43
+    .title {
44
+      width: 100%;
45
+      text-align: center;
46
+      font-size: 18px;
47
+      position: relative;
48
+
49
+      i {
50
+        position: absolute;
51
+        right: 0;
52
+        top: 0;
53
+        font-size: 20px;
54
+        color: #666;
55
+        cursor: pointer;
56
+        padding: 0 5px;
57
+      }
58
+    }
59
+
60
+    .content {
61
+      width: 100%;
62
+      height: 117px;
63
+      background: #f9fafb;
64
+      border: 1px solid #e5e9ed;
65
+      border-radius: 5px;
66
+      overflow: hidden;
67
+      margin-top: 12px;
68
+
69
+      div {
70
+        text-align: center;
71
+        margin: 0;
72
+
73
+        &.icon {
74
+          margin-top: 17px;
75
+
76
+          i {
77
+            color: #34b349;
78
+            font-size: 30px !important;
79
+
80
+            &.transport-wenhao {
81
+              color: #f5a523;
82
+            }
83
+
84
+            &.transport-shibai {
85
+              color: #ff3a52;
86
+            }
87
+          }
88
+        }
89
+
90
+        &.defeat {
91
+          color: #333;
92
+          font-size: 18px;
93
+        }
94
+
95
+        &:nth-child(3) {
96
+          font-size: 14px;
97
+          color: #666;
98
+        }
99
+      }
100
+    }
101
+
102
+    button {
103
+      margin-top: 10px;
104
+
105
+      &.btn {
106
+        margin-left: 8px;
107
+      }
108
+    }
109
+  }
110
+
111
+  // 新增
112
+  &.add {
113
+    .modalBody {
114
+      width: 80%;
115
+      height: auto;
116
+
117
+      .content {
118
+        width: 100%;
119
+        height: auto;
120
+        padding: 19px 14px 0 14px;
121
+        max-height: 500px;
122
+        overflow-y: auto;
123
+				
124
+				.list-template__bottom {
125
+				  background: #f9fafb;
126
+				  border: 1px solid #e5e9ed;
127
+				  border-radius: 8px;
128
+				  padding-bottom: 56px;
129
+				  position: relative;
130
+				  .list-template__nzTable {
131
+				    padding: 16px 16px 0;
132
+				
133
+				    .thead {
134
+				      background-image: linear-gradient(to right, @bg-start, @bg-end);
135
+				
136
+				      th {
137
+				        background: transparent;
138
+				        color: #fff;
139
+				        text-align: center;
140
+				      }
141
+				    }
142
+				
143
+				    .ant-table-body {
144
+				      border-bottom: 1px solid #e5e9ed;
145
+				    }
146
+				
147
+				    .ant-table-tbody {
148
+				      tr {
149
+				        text-align: center;
150
+				        color: #333;
151
+				
152
+				        td {
153
+				          border: none;
154
+				
155
+				          &.tab_hover:hover{
156
+				            text-decoration: underline;
157
+				            cursor: pointer;
158
+				          }
159
+				
160
+				          .coop {
161
+				            button{
162
+				              color: #333;
163
+				            }
164
+				            span,button {
165
+				              display: inline-block;
166
+				              padding: 0 8px;
167
+				              cursor: pointer;
168
+				              position: relative;
169
+				
170
+				              &::after {
171
+				                content: "|";
172
+				                position: absolute;
173
+				                top: 0;
174
+				                right: 0;
175
+				              }
176
+				
177
+				              &:hover,
178
+				              &:active {
179
+				                color: @primary-color;
180
+				              }
181
+				
182
+				              &:nth-last-child(1) {
183
+				                &::after {
184
+				                  content: "";
185
+				                }
186
+				              }
187
+				            }
188
+				          }
189
+				        }
190
+				      }
191
+				    }
192
+				  }
193
+				  .list-template__pagination {
194
+				    height: 56px;
195
+				    display: flex;
196
+				    align-items: center;
197
+				    position: absolute;
198
+				    right: 8px;
199
+				  }
200
+				}
201
+				
202
+        .addForm {
203
+          .ant-form-item {
204
+            margin-bottom: 14px;
205
+
206
+            .ant-form-item-label {
207
+              line-height: 14px;
208
+              text-align: left;
209
+            }
210
+          }
211
+        }
212
+
213
+        .editForm {
214
+          .ant-form-item {
215
+            margin-bottom: 14px;
216
+
217
+            .ant-form-item-label {
218
+              line-height: 0;
219
+              text-align: left;
220
+            }
221
+          }
222
+        }
223
+      }
224
+
225
+      button {
226
+        &:nth-child(1) {
227
+          margin-right: 20px;
228
+        }
229
+      }
230
+    }
231
+  }
232
+	
233
+	.mask-style{
234
+		width: 100%;
235
+		height: 100%;
236
+		position: fixed;
237
+		top: 0;
238
+		left: 0;
239
+		z-index: 999;
240
+		display: flex;
241
+		background: rgba(0,0,0,0.2);
242
+		align-items: center;
243
+		justify-content: center;
244
+	}
245
+	.spin-style{
246
+		z-index:9999;
247
+	}
248
+}
249
+

+ 193 - 0
src/app/views/batch-distribution/batch-distribution.component.ts

@@ -0,0 +1,193 @@
1
+import { Component, OnInit, ViewChild} from "@angular/core";
2
+import { ActivatedRoute, Router } from "@angular/router";
3
+import {
4
+  FormBuilder,
5
+  Validators,
6
+  FormGroup,
7
+  FormControl,
8
+} from "@angular/forms";
9
+
10
+import { MainService } from "../../services/main.service";
11
+import { OverlayScrollbarsComponent } from "overlayscrollbars-ngx";
12
+import { ToolService } from "../../services/tool.service";
13
+import { format, startOfDay, endOfDay } from "date-fns";
14
+import { NzMessageService } from "ng-zorro-antd";
15
+import { Subject } from "rxjs";
16
+import { debounceTime, filter } from "rxjs/operators";
17
+import host from "../../../assets/js/http";
18
+import { HttpRequest, HttpResponse, HttpClient } from '@angular/common/http';
19
+
20
+@Component({
21
+  selector: "app-batch-distribution",
22
+  templateUrl: "./batch-distribution.component.html",
23
+  styleUrls: ["./batch-distribution.component.less"],
24
+})
25
+export class BatchDistributionComponent implements OnInit{
26
+  @ViewChild("osComponentRef1", {
27
+    read: OverlayScrollbarsComponent,
28
+    static: false,
29
+  })
30
+  osComponentRef1: OverlayScrollbarsComponent;
31
+  constructor(
32
+    private message: NzMessageService,
33
+    private fb: FormBuilder,
34
+    private route: ActivatedRoute,
35
+    private router: Router,
36
+    private mainService: MainService,
37
+    private tool: ToolService,
38
+    private http: HttpClient,
39
+  ) {}
40
+
41
+  ngOnInit() {
42
+		this.hosId = this.tool.getCurrentHospital().id;
43
+    this.coopBtns = this.tool.initCoopBtns(this.route);
44
+		this.getList()
45
+  }
46
+	isSpinning:any = false;
47
+  listOfData: any[] = []; //表格数据
48
+  promptContent: string; //操作提示框提示信息
49
+  ifSuccess: boolean; //操作成功/失败
50
+  promptInfo: string; //操作结果提示信息
51
+  promptModalShow: boolean; //操作提示框是否展示
52
+  modal: boolean = false; //新增/编辑模态框
53
+  add: boolean; //true:新增;false:编辑
54
+  validateForm: FormGroup; //新增/编辑表单
55
+  coopId: number; //表格中执行操作的id
56
+  department: ""; //所属科室
57
+	hosId: number;
58
+	dateRange;//时间
59
+  batchNumber; //批次号
60
+  num; //编码
61
+  deptalias; //别名
62
+  type; //类型
63
+  deptHandoverType; //类型
64
+  pageIndex: number = 1; //页码
65
+  listLength: number = 10; //总条数
66
+  pageSize: number = 10; //每页条数
67
+  btnLoading: boolean = false; //确认按钮loading状态
68
+  printLoading: boolean = false; //批量打印按钮loading状态
69
+  deptPhones: any = []; //新添加的科室电话列表
70
+  isAddDeptsPhone = true; //添加新的科室电话是否禁用
71
+  deptsPhoneId = 1; //科室电话自增id
72
+  allParentdepart: any = []; //所有的父级科室列表
73
+  hospitals1: any = []; //科室列表(搜索)
74
+	rowData: object = {}; //打印选择列表
75
+  searchParentDeptSubject = new Subject();
76
+  // 初始化增删改按钮
77
+  coopBtns: any = {};
78
+	viewData: any = []; //科室单查看数据
79
+  // 打开父级科室下拉框baba
80
+  isLoading = false;
81
+
82
+  // 搜索
83
+  search() {
84
+    this.pageIndex = 1;
85
+    this.getList();
86
+  }
87
+  // 重置
88
+  reset() {
89
+    this.pageIndex = 1;
90
+    this.batchNumber = "";
91
+		this.dateRange = [];
92
+		this.startDate = "";
93
+		this.endDate = "";
94
+    this.getList();
95
+  }
96
+  // 表格数据
97
+  loading1 = false;
98
+  getList() {
99
+    let data = {
100
+      idx: this.pageIndex - 1,
101
+      sum: this.pageSize,
102
+      pathologyDeliveryBatch: {
103
+				batchNo:this.batchNumber,
104
+        startTime: this.startDate,
105
+				endTime: this.endDate,
106
+				hosId: this.hosId
107
+      },
108
+    };
109
+		if(this.batchNumber){
110
+			data.pathologyDeliveryBatch.batchNo = this.batchNumber
111
+		}else{
112
+			delete data.pathologyDeliveryBatch.batchNo
113
+		}
114
+    this.loading1 = true;
115
+    this.mainService
116
+      .getFetchDataList("data", "pathologyDeliveryBatch", data)
117
+      .subscribe((data) => {
118
+        this.loading1 = false;
119
+        this.listOfData = data.list;
120
+        this.listLength = data.totalNum;
121
+      });
122
+  }
123
+
124
+	// 日期选择
125
+	startDate: any = null; //发起时间开始
126
+	endDate: any = null; //发起时间结束
127
+	changeDate(result?): void {
128
+	  if (result.length==0) {
129
+	    this.startDate = this.endDate = "";
130
+	  }else{
131
+			this.startDate = format(startOfDay(result[0]), 'yyyy-MM-dd HH:mm:ss');
132
+			this.endDate = format(endOfDay(result[1]), 'yyyy-MM-dd HH:mm:ss');
133
+		}
134
+	}
135
+
136
+  // 展示信息提示框(con:提示信息,success:操作是否成功,promptInfo:操作结果提示信息)
137
+  showPromptModal(con, success, promptInfo?) {
138
+    this.promptModalShow = false;
139
+    this.promptContent = con;
140
+    this.ifSuccess = success;
141
+    this.promptInfo = promptInfo;
142
+    setTimeout(() => {
143
+      this.promptModalShow = true;
144
+    }, 100);
145
+    this.getList();
146
+  }
147
+
148
+  // 查看
149
+  viewSingle(item) {
150
+    let query = {
151
+    	idx: 0,
152
+    	sum: 9999,
153
+    	pathologyForm: {
154
+    		batchId: item.id,
155
+    		order:'createTime desc'
156
+    	},
157
+    };
158
+    this.loading1 = true
159
+    this.mainService
160
+    .getFetchDataList("data", "pathologyForm", query)
161
+    .subscribe((data) => {
162
+    	this.loading1 = false
163
+    	this.viewData = data.list
164
+    	for(let i of this.viewData){
165
+    		if(i.pathologyInspectDTOS){
166
+    			i.arr = []
167
+    			for(let x of i.pathologyInspectDTOS){
168
+    				i.arr.push(x.inspectProject.name)
169
+    			}
170
+    		}
171
+    	}
172
+    	this.modal = true
173
+    });
174
+  }
175
+	
176
+	// 申请单号点击
177
+	detailItem:any = null;
178
+	pathologyDetailModal:any = false;
179
+	itemClick(item){
180
+		this.detailItem = item
181
+		setTimeout(_=>{
182
+			this.pathologyDetailModal = true
183
+		},200)
184
+	}
185
+	
186
+	hideModal(){
187
+		this.modal = false
188
+	}
189
+	
190
+	pathologyDetailCancel(){
191
+		this.pathologyDetailModal = false
192
+	}
193
+}

+ 19 - 0
src/app/views/batch-distribution/batch-distribution.module.ts

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

+ 10 - 13
src/app/views/hushijiandan/hushijiandan.component.html

@@ -2585,12 +2585,9 @@
2585 2585
 <!-- 多个申请单 -->
2586 2586
 <div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="multiDialog">
2587 2587
 	<div class="modalBody modalBody-ga">
2588
-		<div class="title">多条申请单提示<i class="icon_transport transport-guanbi" (click)="hideModal()"></i>
2588
+		<div class="new-title"><span class="title-weight">{{viewData[0].patientDTO.patientName}}({{viewData[0].patientDTO.patientCode}})</span>患者申请单列表<i class="icon_transport transport-guanbi" (click)="hideModal()"></i>
2589 2589
 		</div>
2590 2590
 		<div class="content">
2591
-			<div class="weight" *ngIf="viewData.length>0">
2592
-				提示:查询到{{viewData[0].patientDTO.patientName}}({{viewData[0].patientDTO.patientCode}})患者有多条申请单,请选择对应申请单
2593
-			</div>
2594 2591
 			<div class="list-template__bottom">
2595 2592
 				<nz-table class="list-template__nzTable" [nzData]="viewData" nzSize="middle" [nzShowPagination]="false"
2596 2593
 					[nzLoading]="grossLoading">
@@ -2598,19 +2595,19 @@
2598 2595
 						<tr class="thead">
2599 2596
 							<th>申请单类型</th>
2600 2597
 							<th>申请单号</th>
2601
-							<th nzWidth="15%">检验项目</th>
2598
+							<th nzWidth="20%">检验项目</th>
2602 2599
 							<th>标本类型</th>
2603 2600
 							<th>申请时间</th>
2604 2601
 							<th>申请科室</th>
2605 2602
 							<th>状态</th>
2606
-							<th>作</th>
2603
+							<th>作</th>
2607 2604
 						</tr>
2608 2605
 					</thead>
2609 2606
 					<tbody>
2610 2607
 						<tr *ngFor="let data of viewData">
2611
-							<td *ngIf="data.pathologyFormType==1">术中快速病理检查申请单</td>
2612
-							<td *ngIf="data.pathologyFormType==0">病理检查申请单</td>
2613
-							<td *ngIf="data.pathologyFormType==null">无</td>
2608
+							<td *ngIf="data.pathologyFormType==1" class="red">术中快速</td>
2609
+							<td *ngIf="data.pathologyFormType==0">普通病理</td>
2610
+							<td *ngIf="data.pathologyFormType==2">病理细胞学</td>
2614 2611
 							<td style="text-decoration: underline;cursor: pointer;" (click)="itemClick(data)">{{ data.applyCode}}</td>
2615 2612
 							<td>{{ data.arr ? data.arr.join('、') : '无' }}</td>
2616 2613
 							<td>{{ data.specimenType?data.specimenType.name:'无'}}</td>
@@ -2618,10 +2615,10 @@
2618 2615
 							<td>{{ data.patientDTO.department? data.patientDTO.department.dept:'-'}}</td>
2619 2616
 							<td>{{ data.status?data.status.name:'-'}}</td>
2620 2617
 							<td>
2621
-							  <div class="coop">
2622
-							    <span *ngIf="data.status.value==1 || data.status.value==2
2618
+							  <div class="coop-btn">
2619
+									<button class="btn" *ngIf="data.status.value==1 || data.status.value==2
2623 2620
 									|| data.status.value==3 || data.status.value==4 ||
2624
-									data.status.value==5" (click)="cancellation(data)">作废</span>
2621
+									data.status.value==5" (click)="cancellation(data)" nz-button nzType="primary">作废</button>
2625 2622
 							  </div>
2626 2623
 							</td>
2627 2624
 						</tr>
@@ -2631,7 +2628,7 @@
2631 2628
 		</div>
2632 2629
 		<div class="display_flex justify-content_flex-center mar-20 btns">
2633 2630
 			<button class="btn" style="margin-right: 0;" *ngIf="autoCreate==1" nz-button nzType="primary" (click)="addPathologyType(0)">新增普通病理</button>
2634
-			<button class="btn" *ngIf="autoCreate==1" nz-button nzType="primary" (click)="addPathologyType(1)">新增术中快速病理</button>
2631
+			<button class="btn" *ngIf="autoCreate==1" nz-button nzType="primary" (click)="addPathologyType(1)">新增术中快速</button>
2635 2632
 			<button class="btn cancel" nz-button nzType="default" (click)="hideModal()">知道了</button>
2636 2633
 		</div>
2637 2634
 	</div>

+ 61 - 5
src/app/views/hushijiandan/hushijiandan.component.less

@@ -230,6 +230,15 @@
230 230
 		.list-template__searchBox{
231 231
 			margin-top: 10px;
232 232
 		}
233
+		.list-template__bottom{
234
+			padding-bottom:20px !important;
235
+		}
236
+		.list-template__bottom{
237
+			.list-template__nzTable{
238
+				height: 420px !important;
239
+				overflow-y: auto !important;
240
+			}
241
+		}
233 242
 		.ant-select{
234 243
 			width: 20%;
235 244
 		}
@@ -244,7 +253,6 @@
244 253
     .title {
245 254
       width: 100%;
246 255
       text-align: center;
247
-      font-size: 18px;
248 256
       position: relative;
249 257
 
250 258
       i {
@@ -257,7 +265,27 @@
257 265
         padding: 0 5px;
258 266
       }
259 267
     }
260
-
268
+		
269
+		.new-title {
270
+		  width: 100%;
271
+		  text-align: center;
272
+		  position: relative;
273
+			font-size: 14px;
274
+		  i {
275
+		    position: absolute;
276
+		    right: 0;
277
+		    top: 0;
278
+		    font-size: 20px;
279
+		    color: #666;
280
+		    cursor: pointer;
281
+		    padding: 0 5px;
282
+		  }
283
+		}
284
+		
285
+		.title-weight{
286
+			font-weight: bold;
287
+			font-size: 15px;
288
+		}
261 289
     .content {
262 290
       width: 100%;
263 291
       // height: 117px;
@@ -325,8 +353,8 @@
325 353
         width: 100%;
326 354
         height: auto;
327 355
         padding: 19px 14px 0 14px;
328
-        max-height: 500px;
329
-        overflow-y: auto;
356
+        // max-height: 500px;
357
+        // overflow-y: auto;
330 358
 
331 359
 				.ant-select{
332 360
 					width: 100%;
@@ -369,7 +397,35 @@
369 397
 				            text-decoration: underline;
370 398
 				            cursor: pointer;
371 399
 				          }
372
-
400
+									
401
+									.coop-btn{
402
+										button{
403
+											margin-top: 0 !important;
404
+										  color: #fff;
405
+											&:nth-child(1) {
406
+											  margin-right: 0 !important;
407
+											}
408
+										}
409
+										span,button {
410
+										  display: inline-block;
411
+										  cursor: pointer;
412
+										  position: relative;
413
+										
414
+										  &::after {
415
+										    content: "|";
416
+										    position: absolute;
417
+										    top: 0;
418
+										    right: 0;
419
+										  }
420
+										
421
+										  &:nth-last-child(1) {
422
+										    &::after {
423
+										      content: "";
424
+										    }
425
+										  }
426
+										}
427
+									}
428
+									
373 429
 				          .coop {
374 430
 				            button{
375 431
 				              color: #333;

+ 9 - 61
src/app/views/hushijiandan/hushijiandan.component.ts

@@ -400,9 +400,9 @@ export class HushijiandanComponent implements OnInit {
400 400
 			idx: 0,
401 401
 			sum: 9999,
402 402
 			pathologyForm: {
403
-				// surgeryId: item.id || "",
403
+				surgeryId: item.id || "",
404 404
 				patientId: item.patientDTO.id || "",
405
-				hosId: this.currentHospital.id || "" ,
405
+				// hosId: this.currentHospital.id || "" ,
406 406
 				operationType: 'pathologyForm',
407 407
 				order:'createTime desc',
408 408
 			},
@@ -413,39 +413,15 @@ export class HushijiandanComponent implements OnInit {
413 413
 			.subscribe((data) => {
414 414
 				this.isSpinning = false
415 415
 				this.viewData = data.list
416
-				if(this.viewData.pathologyInspectDTOS){
417
-					for(let i of this.viewData.pathologyInspectDTOS){
416
+				for(let i of this.viewData){
417
+					if(i.pathologyInspectDTOS){
418 418
 						i.arr = []
419
-						i.arr.push(i.inspectProject.name)
420
-					}
421
-				}
422
-				this.multiDialog = true
423
-				return
424
-				if(data.list.length==1){
425
-					this.detailId = data.list[0].id
426
-					if(!data.list[0].status){
427
-						this.pathologyModal = true
428
-						return
429
-					}
430
-					if(data.list[0].status &&
431
-					(data.list[0].status.value==1 || data.list[0].status.value==2 ||
432
-					data.list[0].status.value==3 || data.list[0].status.value==4)){
433
-						this.pathologyModal = true
434
-					}else{
435
-						this.pathologyDetailModal = true
436
-					}
437
-				}else if(data.list.length>1){
438
-					this.viewData = data.list
439
-					if(this.viewData.pathologyInspectDTOS){
440
-						for(let i of this.viewData.pathologyInspectDTOS){
441
-							i.arr = []
442
-							i.arr.push(i.inspectProject.name)
419
+						for(let x of i.pathologyInspectDTOS){
420
+							i.arr.push(x.inspectProject.name)
443 421
 						}
444 422
 					}
445
-					this.multiDialog = true
446
-				}else if(data.list.length==0){
447
-					this.message.error('无申请单')
448 423
 				}
424
+				this.multiDialog = true
449 425
 			});
450 426
 	}
451 427
 
@@ -461,9 +437,9 @@ export class HushijiandanComponent implements OnInit {
461 437
 			idx: 0,
462 438
 			sum: 9999,
463 439
 			pathologyForm: {
464
-				// surgeryId: this.surgeryWKOMsg.id || "",
440
+				surgeryId: this.surgeryWKOMsg.id || "",
465 441
 				patientId: this.surgeryWKOMsg.patientDTO.id || "",
466
-				hosId: this.currentHospital.id || "" ,
442
+				// hosId: this.currentHospital.id || "" ,
467 443
 				operationType: 'pathologyForm',
468 444
 				order:'createTime desc'
469 445
 			},
@@ -483,34 +459,6 @@ export class HushijiandanComponent implements OnInit {
483 459
 				}
484 460
 			}
485 461
 			this.multiDialog = true
486
-			return
487
-			if(data.list.length==1){
488
-				this.detailId = data.list[0].id
489
-				if(!data.list[0].status){
490
-					this.pathologyModal = true
491
-					return
492
-				}
493
-				if(data.list[0].status &&
494
-				(data.list[0].status.value==1 || data.list[0].status.value==2 ||
495
-					data.list[0].status.value==3 || data.list[0].status.value==4)){
496
-					this.pathologyModal = true
497
-				}else{
498
-					this.pathologyDetailModal = true
499
-				}
500
-			}else if(data.list.length>1){
501
-				this.viewData = data.list
502
-				for(let i of this.viewData){
503
-					if(i.pathologyInspectDTOS){
504
-						i.arr = []
505
-						for(let x of i.pathologyInspectDTOS){
506
-							i.arr.push(x.inspectProject.name)
507
-						}
508
-					}
509
-				}
510
-				this.multiDialog = true
511
-			}else if(data.list.length==0){
512
-				this.message.error('无申请单')
513
-			}
514 462
 		});
515 463
 	}
516 464
 	

+ 5 - 0
src/app/views/main/main-routing.module.ts

@@ -613,6 +613,11 @@ const routes: Routes = [
613 613
 			  path: "deptAllStatistics",
614 614
 			  loadChildren: () => import("../dept-all-statistics/dept-all-statistics.module").then((m) => m.DeptAllStatisticsModule),
615 615
 			},
616
+			// 病理管理-批次配送
617
+			{
618
+			  path: "batchDistribution",
619
+			  loadChildren: () => import("../batch-distribution/batch-distribution.module").then((m) => m.BatchDistributionModule),
620
+			}
616 621
     ],
617 622
   },
618 623
 ];

+ 137 - 106
src/app/views/pathology-communication-book/pathology-communication-book.component.html

@@ -50,6 +50,7 @@
50 50
 	<div class="tabs">
51 51
 		<div class="tabs-item">
52 52
 			<div class="tabs-item-item" [ngClass]="{'activeClass': activeIndex == 0}" (click)="tabClick(0)">交接本</div>
53
+			<div class="tabs-item-item"  *ngIf="coopBtns.print" [ngClass]="{'activeClass': activeIndex == 1}" (click)="tabClick(1)">未打印</div>
53 54
 		</div>
54 55
 		<div class="tabs-btn">
55 56
 			<button class="btn default" nz-button nzType="primary" nzSize="small" (click)='distributionTab()'>配送清点</button>
@@ -57,7 +58,7 @@
57 58
 	</div>
58 59
   <!-- 头部 end -->
59 60
   <div class="pharmacy-main">
60
-    <div *ngIf="activeIndex==0" class="list-template pharmacy-main__list pharmacy-main__print">
61
+    <div class="list-template pharmacy-main__list pharmacy-main__print">
61 62
 			<div class="list-template__content">
62 63
 			  <div class="list-template__top" nz-row>
63 64
 			    <div nz-col nzLg='18' class="list-template__searchBox">
@@ -100,9 +101,10 @@
100 101
 			    <div nz-col nzLg="6" class="list-template__btns">
101 102
 			      <button class="btn default" (click)='search()'>搜索</button>
102 103
 			      <button class="btn default ml8" (click)='reset()'>重置</button>
104
+						<button class="btn default ml8" nz-button *ngIf="coopBtns.batchPrint && activeIndex==1" (click)="print('batchPrint')" [nzLoading]="btnLoading">批量打印</button>
103 105
 			    </div>
104 106
 			  </div>
105
-			  <div class="list-template__bottom">
107
+			  <div class="list-template__bottom" *ngIf="activeIndex==0">
106 108
 			    <nz-table class="list-template__nzTable" [nzData]="listOneData" nzSize="middle" [nzShowPagination]="false"
107 109
 			      [nzLoading]="loading1">
108 110
 			      <thead>
@@ -118,7 +120,7 @@
118 120
 								<th>固定时间</th>
119 121
 			          <th>配送人</th>
120 122
 								<th>配送时间</th>
121
-			          <th nzWidth="80px">操作</th>
123
+			          <th nzWidth="120px">操作</th>
122 124
 			        </tr>
123 125
 			      </thead>
124 126
 			      <tbody>
@@ -137,6 +139,7 @@
137 139
 			          <td>
138 140
 			            <div class="coop">
139 141
 										<span (click)="oneLook($event,data)">查看</span>
142
+										<span *ngIf="coopBtns.print && data.printFlag==1" (click)="print('print',data)">补打</span>
140 143
 			            </div>
141 144
 			          </td>
142 145
 			        </tr>
@@ -148,114 +151,69 @@
148 151
 			      </nz-pagination>
149 152
 			    </div>
150 153
 			  </div>
151
-			</div>
152
-    </div>
153
-
154
-    <div class="pharmacy-main__list pharmacy-main__waitDelivery">
155
-      <div *ngIf="activeIndex==1" class="list-template pharmacy-main__list pharmacy-main__print">
156
-      	<div class="list-template__content">
157
-      	  <div class="list-template__bottom">
158
-      	    <nz-table class="list-template__nzTable" [nzData]="listTwoData" nzSize="middle" [nzShowPagination]="false"
159
-      	      [nzLoading]="loading2">
160
-      	      <thead>
161
-      	        <tr class="thead">
162
-      	          <th>申请单号</th>
163
-      	          <th>患者姓名</th>
164
-      	          <th>住院号</th>
165
-      	          <th>部位</th>
166
-      	          <th>标本数</th>
167
-      	          <th>申请科室</th>
168
-      	          <th>配送人</th>
169
-      	          <th>状态</th>
170
-      	          <th>操作</th>
171
-      	        </tr>
172
-      	      </thead>
173
-      	      <tbody>
174
-      	        <tr *ngFor="let data of listTwoData">
175
-      	         <td><span *ngIf="data.pathologyFormType==1" style="color: red;">速</span>{{ data.applyCode || '-' }}</td>
176
-      	         <td>{{ data.patientDTO?data.patientDTO.patientName : '-' }}</td>
177
-      	         <td>{{ data.patientDTO.patientCode}}</td>
178
-      	         <td>{{ data.takePart}}</td>
179
-      	         <td>{{ data.specimenNum}}</td>
180
-      	         <td>{{ data.patientDTO?data.patientDTO.department.dept : '-'}}</td>
181
-      	         <td>{{ data.deliveryUserDTO?data.deliveryUserDTO.name : '-' }}</td>
182
-      	         <td>{{ data.status?data.status.name:'-' }}</td>
183
-      	         <td>
184
-      	           <div class="coop">
185
-      	         		<span (click)="oneLook($event,data)">查看</span>
186
-      	           </div>
187
-      	         </td>
188
-      	        </tr>
189
-      	      </tbody>
190
-      	    </nz-table>
191
-      	    <div class="list-template__pagination">
192
-      	      <nz-pagination [(nzPageIndex)]="pageTwoIndex" [(nzTotal)]="listTwoLength" nzShowSizeChanger [(nzPageSize)]="pageSize"
193
-      	        (nzPageIndexChange)="getSpeedinessList()" (nzPageSizeChange)="getSpeedinessList()">
194
-      	      </nz-pagination>
195
-      	    </div>
196
-      	  </div>
197
-      	</div>
198
-      </div>
199
-    </div>
200
-
201
-    <div class="pharmacy-main__list pharmacy-main__delivery">
202
-			<div *ngIf="activeIndex==2" class="list-template pharmacy-main__list pharmacy-main__print">
203
-				<div class="list-template__content">
204
-				  <div class="list-template__bottom">
205
-				    <nz-table class="list-template__nzTable" [nzData]="listThreeData" nzSize="middle" [nzShowPagination]="false"
206
-				      [nzLoading]="loading3">
207
-				      <thead>
208
-				        <tr class="thead">
209
-				          <th>包号</th>
210
-				          <th>打包人 | 打包时间</th>
211
-				          <th>申请单数</th>
212
-				          <th>标本数</th>
213
-									<th>配送人 | 配送时间</th>
214
-									<th>接收人 | 接收时间</th>
215
-				          <th>状态</th>
216
-				          <th>操作</th>
217
-				        </tr>
218
-				      </thead>
219
-				      <tbody>
220
-				        <tr *ngFor="let data of listThreeData">
221
-				          <td>{{ data.packCode || '-' }}</td>
222
-									<td>
223
-										<div>{{data.packUserDTO.name }}</div>
224
-										<div>{{data.packTime|date:'yyyy-MM-dd HH:mm' }}</div>
225
-									</td>
226
-				          <td>{{ data.pathologyFormNum }}</td>
227
-				          <td>{{ data.specimenNum }}</td>
228
-				          <td>
229
-				          	<div>{{data.deliveryUserDTO?data.deliveryUserDTO.name:'-' }}</div>
230
-				          	<div>{{data.deliveryTime|date:'yyyy-MM-dd HH:mm' || '-' }}</div>
231
-				          </td>
232
-				          <td>
233
-				          	<div>{{data.receiveUserDTO?data.receiveUserDTO.name:'-' }}</div>
234
-				          	<div>{{data.receiveTime|date:'yyyy-MM-dd HH:mm' || '-' }}</div>
235
-				          </td>
236
-									<td>{{ data.status.name }}</td>
237
-				          <td>
238
-				            <div class="coop">
239
-											<span (click)="threeLook($event,data)">查看标本</span>
240
-											<span (click)="reprint($event,data)">补打</span>
241
-											<span *ngIf="data.status.value==1" (click)="distribution($event,data)">配送</span>
242
-				            </div>
243
-				          </td>
244
-				        </tr>
245
-				      </tbody>
246
-				    </nz-table>
247
-				    <div class="list-template__pagination">
248
-				      <nz-pagination [(nzPageIndex)]="pageThreeIndex" [(nzTotal)]="listThreeLength" nzShowSizeChanger [(nzPageSize)]="pageSize"
249
-				        (nzPageIndexChange)="getPackList()" (nzPageSizeChange)="getPackList()">
250
-				      </nz-pagination>
251
-				    </div>
154
+				
155
+				<div class="list-template__bottom" *ngIf="activeIndex==1">
156
+				  <nz-table class="list-template__nzTable" [nzData]="listOneData" nzSize="middle" [nzShowPagination]="false"
157
+				    [nzLoading]="loading1">
158
+				    <thead>
159
+				      <tr class="thead">
160
+								<th 
161
+								*ngIf="coopBtns.batchPrint"
162
+								nzShowCheckbox
163
+								[(nzChecked)]="isAllDisplayDataChecked"
164
+								[nzIndeterminate]="isIndeterminate"
165
+								(nzCheckedChange)="checkAll($event)"></th>
166
+				        <th>申请单号</th>
167
+								<th>状态</th>
168
+				        <th>患者姓名</th>
169
+				        <th>住院号</th>
170
+				        <th nzWidth="100px">部位</th>
171
+				        <th>标本数</th>
172
+				        <th>申请科室</th>
173
+								<th>离体时间</th>
174
+								<th>固定时间</th>
175
+				        <th>配送人</th>
176
+								<th>配送时间</th>
177
+				        <th nzWidth="120px">操作</th>
178
+				      </tr>
179
+				    </thead>
180
+				    <tbody>
181
+				      <tr *ngFor="let data of listOneData">
182
+								<td
183
+								  *ngIf="coopBtns.batchPrint"
184
+									nzShowCheckbox
185
+									[(nzChecked)]="mapOfCheckedId[data.id]"
186
+									(nzCheckedChange)="refreshStatus()"
187
+								></td>
188
+				        <td><span *ngIf="data.pathologyFormType==1" style="color: red;">速</span>{{ data.applyCode || '-' }}</td>
189
+								<td>{{ data.status?data.status.name : '-' }}</td>
190
+								<td>{{ data.patientDTO.patientName}}</td>
191
+				        <td>{{ data.patientDTO.residenceNo}}</td>
192
+				        <td>{{ data.takePart}}</td>
193
+				        <td>{{ data.specimenNum}}</td>
194
+				        <td>{{ data.patientDTO?data.patientDTO.department.dept : '-'}}</td>
195
+								<td>{{ data.inVitroTime|date:'yyyy-MM-dd HH:mm:ss'  }}</td>
196
+								<td>{{ data.fixationTime|date:'yyyy-MM-dd HH:mm:ss'  }}</td>
197
+								<td>{{ data.deliveryUserDTO?data.deliveryUserDTO.name : '-' }}</td>
198
+								<td>{{ data.leaveDeptTime|date:'yyyy-MM-dd HH:mm:ss'  }}</td>
199
+				        <td>
200
+				          <div class="coop">
201
+										<span (click)="oneLook($event,data)">查看</span>
202
+										<span *ngIf="coopBtns.print" (click)="print('print',data)">打印</span>
203
+				          </div>
204
+				        </td>
205
+				      </tr>
206
+				    </tbody>
207
+				  </nz-table>
208
+				  <div class="list-template__pagination">
209
+				    <nz-pagination [(nzPageIndex)]="pageOneIndex" [(nzTotal)]="listOneLength" nzShowSizeChanger [(nzPageSize)]="pageSize"
210
+				      (nzPageIndexChange)="getConnectList()" (nzPageSizeChange)="getConnectList()">
211
+				    </nz-pagination>
252 212
 				  </div>
253 213
 				</div>
254 214
 			</div>
255 215
     </div>
256 216
   </div>
257
-  <!-- 主体部分 end -->
258
-  <!-- <router-outlet></router-outlet> -->
259 217
 </div>
260 218
 
261 219
 <!-- 科室切换提示框 -->
@@ -453,4 +411,77 @@
453 411
 			</div>
454 412
 		</div>
455 413
 	</div>
414
+</div>
415
+
416
+<!-- 打印 -->
417
+<div id="report" style="display: none;">
418
+	<div class="monad">
419
+		<div style="font-size: 12px;">
420
+			<div style="position: relative;height: 100%;" *ngFor="let data of printData; let index=index;">
421
+				<div style="position: relative;width:96%;margin-left: 2%;padding-bottom: 12px;">
422
+					<div style="height: 80px;line-height: 80px;text-align: center;font-size: 30px;">病理申请单</div>
423
+					<div *ngIf="pathologyBarCode==1" style="position: absolute;right: 0;height: 95%;top: 10px;text-align: right;">
424
+					 <img style="max-width: 75%;height: 50%;" [src]="data.barCode" alt="">
425
+					 <div>申请单号:{{data.applyCode}}</div>
426
+					</div>
427
+					<div *ngIf="pathologyBarCode==2" style="position: absolute;right: 10px;height: 95%;top: 0px;text-align: center;">
428
+					 <img style="max-width: 100%;height: 80%;" [src]="data.barCode" alt="">
429
+					 <div>申请单号:{{data.applyCode}}</div>
430
+					</div>
431
+				</div>
432
+				<div style="border-top: 1px solid #333; width:96%;margin-left: 2%;padding-bottom: 12px;">
433
+					<div style="display: flex; justify-content: space-between; margin-top:12px;">
434
+						<div>姓名: {{data.patientDTO ? data.patientDTO.patientName : ''}}</div>
435
+						<div>性别: {{data.patientDTO && data.patientDTO.gender ? data.patientDTO.gender.name:''}}</div>
436
+						<div>年龄: {{data.patientDTO ? data.patientDTO.age : ''}}</div>
437
+						<div>电话: {{data.patientDTO?data.patientDTO.patientPhone:''}}</div>
438
+					</div>
439
+					<div style="display: flex; justify-content: space-between; margin-top:12px;">
440
+						<div>门诊号: {{data.patientDTO.patientCode}}</div>
441
+						<div>住院号: {{data.patientDTO.residenceNo}}</div>
442
+						<div>床号: {{data.patientDTO.bedNum}}</div>
443
+						<div>科室: {{data.patientDTO.department ? data.patientDTO.department.dept:''}}</div>
444
+					</div>
445
+					<div style="display: flex; justify-content: space-between; margin-top:12px;">
446
+						<div style="width: 100%;overflow: hidden;">活检部位: {{data.takePart}}</div>
447
+					</div>
448
+					<div style="display: flex; justify-content: space-between; margin-top:12px;">
449
+						<div>检查时间: {{data.createTime|date:'yyyy-MM-dd HH:mm:ss'}}</div>
450
+						<div>离体时间: {{data.inVitroTime|date:'yyyy-MM-dd HH:mm:ss'}}</div>
451
+						<div>固定时间: {{data.fixationTime|date:'yyyy-MM-dd HH:mm:ss'}}</div>
452
+					</div>
453
+				</div>
454
+				<div style="border-top: 1px solid #333; width:96%;margin-left: 2%;padding-bottom: 12px;">
455
+					<div style="margin-top:12px;">临床诊断:</div>
456
+					<div style="margin-top:12px;">{{data.diagnose}}</div>
457
+					<div style="margin-top:12px;">检查所见:</div>
458
+					<div style="margin-top:12px;">
459
+						{{data.intraoperativeFindings}}
460
+					</div>
461
+					<div style="margin-top:12px;">手术诊断:</div>
462
+					<div style="margin-top:12px;">{{data.surgicalPlan}}</div>
463
+					<div style="margin-top:12px;">备注:</div>
464
+				</div>
465
+				<div style="width:96%;margin-left: 2%;padding-bottom: 12px; border-top: 1px solid #333;position: absolute;bottom: 0;">
466
+					<div style="display: flex; margin-top:12px;">
467
+						<div style="flex: 1;">取材医生: {{data.surgeryDoctorDTO?data.surgeryDoctorDTO.name:''}}</div>
468
+						<div style="flex: 1;">取材护士: {{data.nurseDTO?data.nurseDTO.name:''}}</div>
469
+					</div>
470
+					<div style="margin-top:12px;">注意事项:</div>
471
+					<div style="margin-top:12px;">
472
+						1、患者姓名、住院号必须在标本瓶上著名。
473
+					</div>
474
+					<div style="margin-top:12px;">
475
+						2、标本必须立即固定10 %福尔马林液体内,瓶口宜大以便取出。
476
+					</div>
477
+					<div style="margin-top:12px;">
478
+						3、手术取下之标本,务请全部送检,如贵科科研需要,请注明,我科检查后商议处理。
479
+					</div>
480
+					<div style="margin-top:12px;">
481
+						4、如发现检查与临床有意见不符之处,请与我科联系
482
+					</div>
483
+				</div>
484
+			 <div style="height: 26px;" *ngIf="printData && printData.length>1 && index+1 < printData.length"></div>
485
+			</div>
486
+		</div>
456 487
 </div>

+ 122 - 1
src/app/views/pathology-communication-book/pathology-communication-book.component.ts

@@ -169,6 +169,7 @@ export class PathologyCommunicationBookComponent implements OnInit, OnDestroy {
169 169
 	toDayTime:any = null;
170 170
 	backType:any = 'list';
171 171
 	mainRole:any = false;
172
+	coopBtns:any = {};
172 173
 	loginUserDeptId: number = JSON.parse(localStorage.getItem("user")).user.dept
173 174
 	  .id; //登录人所属科室
174 175
   ngOnDestroy() {
@@ -189,9 +190,11 @@ export class PathologyCommunicationBookComponent implements OnInit, OnDestroy {
189 190
 		// 	this.isLoading = true
190 191
 		//   this.getUserData(v[0])
191 192
 		// });
193
+		this.coopBtns = this.tool.initCoopBtns(this.route);
192 194
 		this.hosId = this.tool.getCurrentHospital().id;
193 195
 		this.userId = this.tool.getCurrentUserId()
194 196
 		this.deptId = this.tool.getCurrentUserDept().id
197
+		this.getTaskTypesId()
195 198
 		this.getConnectList()
196 199
 		if(this.route.snapshot.queryParams && this.route.snapshot.queryParams.type){
197 200
 			this.backType = this.route.snapshot.queryParams.type
@@ -207,13 +210,122 @@ export class PathologyCommunicationBookComponent implements OnInit, OnDestroy {
207 210
 			this.getToday()
208 211
 		},60000)
209 212
   }
213
+	
214
+	isAllDisplayDataChecked:any = false;
215
+	isOperating:any  = false;
216
+	isIndeterminate:any = false;
217
+	listOfAllData: any = [];
218
+	mapOfCheckedId: { [key: string]: boolean } = {};
219
+	numberOfChecked = 0;
220
+	selectedData:any = null;
221
+	
222
+	refreshStatus(): void {
223
+		let arr = [];
224
+		if (this.listOneData.length) {
225
+		  this.isAllDisplayDataChecked = this.listOneData.every(
226
+		    (item) => this.mapOfCheckedId[item.id]
227
+		  );
228
+		} else {
229
+		  this.isAllDisplayDataChecked = false;
230
+		}
231
+		
232
+		for (var m in this.mapOfCheckedId) {
233
+		  if (this.mapOfCheckedId[m]) {
234
+		    arr.push(m);
235
+		  }
236
+		}
237
+		this.selectedData = arr;
238
+	}
210 239
 
240
+	checkAll(value: boolean): void {
241
+		this.listOneData.forEach(item => (this.mapOfCheckedId[item.id] = value));
242
+		this.refreshStatus();
243
+	}
244
+	
245
+	taskTypeData:any;
246
+	getTaskTypesId() {
247
+		this.mainService.getDictionary("list", "ordinary_field").subscribe((data) => {
248
+			this.taskTypeData = data.find(i=>i.value=='pathology')
249
+			this.getConfig();
250
+		});
251
+	}
252
+	
253
+	// 获取配置
254
+	pathologyBarCode:any = 1;
255
+	getConfig() {
256
+		let postData = {
257
+			idx: 0,
258
+			sum: 10,
259
+			taskTypeConfig: {
260
+				hosId:this.hosId,
261
+				taskType:this.taskTypeData.id
262
+			}
263
+		}
264
+	  this.mainService
265
+	    .getFetchDataList("simple/data", "taskTypeConfig", postData)
266
+	    .subscribe((result) => {
267
+	      if (result.status == 200) {
268
+					this.pathologyBarCode = result.list[0].pathologyBarCode?result.list[0].pathologyBarCode:1;
269
+	      }
270
+	    });
271
+	}
272
+	
273
+	// 打印
274
+	btnLoading:any = false;
275
+	printData:any = [];
276
+	print(type, data){
277
+		let ids = null
278
+		if(type=='batchPrint'){
279
+			if(!this.selectedData || this.selectedData.length==0){
280
+				this.message.error('请先选择申请单')
281
+				return
282
+			}
283
+			ids = this.selectedData.join(',')
284
+		}
285
+		this.isSpinning = true
286
+		let query = {
287
+			operation: 'pathologyHandoverBook',
288
+			pathologyFormIds: type=='batchPrint' ? ids : data.id
289
+		}
290
+		this.mainService
291
+			.pathologyPrint(query)
292
+			.subscribe((res:any) => {
293
+				if(res.status==200){
294
+					let arr = res.data;
295
+					for(let i of arr){
296
+						if(i.barCode){
297
+							i.barCode = this.sanitizer.bypassSecurityTrustResourceUrl(i.barCode)
298
+						}
299
+					}
300
+					this.isSpinning = false;
301
+					this.printData = arr;
302
+					this.getConnectList();
303
+					setTimeout(() => {
304
+						const printContent = document.getElementById("report");
305
+						const WindowPrt = window.open("", "", "width=100,height=1000");
306
+						WindowPrt.document.body.innerHTML = printContent.innerHTML;
307
+						setTimeout(_=>{
308
+							WindowPrt.document.close();
309
+							WindowPrt.focus();
310
+							WindowPrt.print();
311
+							WindowPrt.close();
312
+						},500)
313
+					}, 500);
314
+				}else{
315
+					this.message.error(res.msg)
316
+				}
317
+			});
318
+	}
319
+	
211 320
 	//tab切换
212 321
 	tabClick(type){
213 322
 		this.activeIndex = type
214 323
 		localStorage.setItem("pathologyActiveIndex",type)
324
+		this.pageOneIndex = 1;
215 325
 		if(type==0){
216 326
 			this.getConnectList()
327
+		}else{
328
+			this.getConnectList()
217 329
 		}
218 330
 	}
219 331
 	
@@ -286,9 +398,18 @@ export class PathologyCommunicationBookComponent implements OnInit, OnDestroy {
286 398
 				status:{
287 399
 					id:this.status
288 400
 				},
289
-				pathologyFormType:this.pathologyFormType
401
+				pathologyFormType:this.pathologyFormType,
402
+				printFlag:null
290 403
 	    },
291 404
 	  };
405
+		if(this.activeIndex==1){
406
+			data.pathologyForm.printFlag = 0
407
+			this.isAllDisplayDataChecked = false;
408
+			this.mapOfCheckedId = {};
409
+			this.selectedData = null;
410
+		}else{
411
+			delete data.pathologyForm.printFlag
412
+		}
292 413
 	  this.loading1 = true;
293 414
 	  that.mainService
294 415
 	    .getFetchDataList("data", "pathologyForm", data)

+ 56 - 52
src/app/views/pathology-sample/pathology-sample.component.html

@@ -35,31 +35,30 @@
35 35
   </div>
36 36
   <div class="pharmacy-main">
37 37
 		<div class="left" *ngIf="adviceList">
38
-			<div class="top" *ngIf="adviceList.patientNo">
39
-				<div>{{adviceList.patientName}} {{adviceList.patientGender?adviceList.patientGender.name:'-'}} ({{adviceList.patientAge||'-'}}岁)</div>
40
-				<div class="border">{{adviceList.patientNo}}</div>
38
+			<div class="top" *ngIf="adviceList.patientDTO">
39
+				<div>{{adviceList.patientDTO.patientName}} {{adviceList.patientDTO.gender?adviceList.patientDTO.gender.name:'-'}} ({{adviceList.patientDTO.age||'-'}}岁)</div>
40
+				<div class="border">{{adviceList.patientDTO.residenceNo?adviceList.patientDTO.residenceNo:adviceList.patientDTO.patientCode}}</div>
41 41
 			</div>
42 42
 			<div class="left-content" [ngClass]="{'noAddAppClass': !ifAddapplication, 'beAddAppClass': ifAddapplication}">
43
-				<div class="content" *ngFor="let item of adviceList.pathologyAdviceDTOS;let index=index;" (click)="listClick(item,index)" [ngClass]="{'activeLeftClass': index == leftIndex}">
43
+				<div class="content" *ngFor="let item of adviceList.pathologyFormDTOS;let index=index;" (click)="listClick(item,index)" [ngClass]="{'activeLeftClass': index == leftIndex}">
44 44
 					<div class="list list-df">
45
-						<div class="code">{{item.adviceId ? item.adviceId : '无'}}</div>
46
-						<div class="form-title">{{item.adviceType ? item.adviceType.name : ''}}</div>
45
+						<div class="code">{{item.applyCode ? item.applyCode : '无'}}</div>
46
+						<div class="form-title">{{item.status?item.status.name:'无'}}</div>
47 47
 						<div class="del-class">
48 48
 							<i (click)="delItem($event,item)" class="icon_transport transport-lajitong specimen-icon"></i>
49 49
 						</div>
50 50
 					</div>
51
-					<div class="list">项目:{{item.inspectType?item.inspectType.name:'无'}}</div>
52
-					<div class="list">部位:{{item.inspectPart ? item.inspectPart : '无'}}</div>
53
-					<div class="list">诊断:{{item.diagnosis ? item.diagnosis : '无'}}</div>
54
-					<div class="list">开单时间:{{item.orderTime | date:'yyyy-MM-dd HH:mm:ss'}}</div>
55
-					<!-- <div class="list">状态:{{item.orderStatusName}}</div> -->
51
+					<div class="list">项目:{{item.project.length>0 ? item.project.join('、') :'无'}}</div>
52
+					<div class="list">部位:{{item.takePart ? item.takePart : '无'}}</div>
53
+					<div class="list">诊断:{{item.diagnose ? item.diagnose : '无'}}</div>
54
+					<div class="list">开单时间:{{item.createTime | date:'yyyy-MM-dd HH:mm:ss'}}</div>
56 55
 				</div>
57 56
 			</div>
58 57
 			<div *ngIf="ifAddapplication && adviceList" class="center-box">
59
-				<button nz-button nzType="primary" class="btn txtC mr8" (click)="addPathology(0)">新增病理申请单</button>
58
+				<button nz-button nzType="primary" class="btn txtC mr8" (click)="addPathology(0)" [nzLoading]="addLoading">新增病理申请单</button>
60 59
 			</div>
61 60
 		</div>
62
-		<div class="center" *ngIf="adviceList && adviceList.pathologyAdviceDTOS.length>0 && detailsData && viewType!='add'">
61
+		<div class="center" *ngIf="adviceList && adviceList.pathologyFormDTOS.length>0 && detailsData && viewType!='add'">
63 62
 			<div class="pathology-content" *ngIf="viewType=='edit'">
64 63
 				<div class="title">病理检查申请单</div>
65 64
 				<div class="content">
@@ -70,17 +69,11 @@
70 69
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
71 70
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
72 71
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
72
+								<div class="form-title" *ngIf="detailsData.pathologyFormType==2">申请单类型:病理细胞学申请单</div>
73 73
 								<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
74 74
 							</nz-form-item>
75 75
 							
76 76
 							<nz-form-item>
77
-								<div class="form-title width-100 font-weight-500">诊断:</div>
78
-								<div>
79
-									{{detailsData.diagnose||'无'}}
80
-								</div>
81
-							</nz-form-item>
82
-							
83
-							<nz-form-item>
84 77
 								<div class="form-title width-100 font-weight-500">病历摘要:</div>
85 78
 								<div class="indent" [ngClass]="{'height-200': isShowMove, 'height-100': !isShowMove && detailsData.medicalRecords}">{{detailsData.medicalRecords||'无'}}</div>
86 79
 								<div (click)="showLook()" class="cursor" *ngIf="medicalRecordsLength>10">
@@ -89,10 +82,17 @@
89 82
 								</div>
90 83
 							</nz-form-item>
91 84
 							
85
+							<nz-form-item>
86
+								<div class="form-title width-100 font-weight-500">临床诊断:</div>
87
+								<div>
88
+									{{detailsData.diagnose||'无'}}
89
+								</div>
90
+							</nz-form-item>
91
+							
92 92
 							<nz-form-item class="form-item">
93
-								<nz-form-label nzFor="surgicalPlan" [nzSm]="24" [nzXs]="24">手术方案</nz-form-label>
94
-								<nz-form-control nzErrorTip="请输入手术方案" [nzSm]="24" [nzXs]="24">
95
-									<input nz-input formControlName="surgicalPlan" placeholder="请输入手术方案"/>
93
+								<nz-form-label nzFor="surgicalPlan" [nzSm]="24" [nzXs]="24">手术诊断</nz-form-label>
94
+								<nz-form-control nzErrorTip="请输入手术诊断" [nzSm]="24" [nzXs]="24">
95
+									<input nz-input formControlName="surgicalPlan" placeholder="请输入手术诊断"/>
96 96
 								</nz-form-control>
97 97
 							</nz-form-item>
98 98
 							
@@ -188,16 +188,10 @@
188 188
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
189 189
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
190 190
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
191
+								<div class="form-title" *ngIf="detailsData.pathologyFormType==2">申请单类型:病理细胞学申请单</div>
191 192
 								<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
192 193
 							</div>
193
-							
194
-							<div class="form-list">
195
-								<div class="form-title font-weight-500">诊断:</div>
196
-								<div class="indent">
197
-									{{detailsData.diagnose||'无'}}
198
-								</div>
199
-							</div>
200
-							
194
+					
201 195
 							<div class="form-list">
202 196
 								<div class="form-title width-100 font-weight-500">病历摘要:</div>
203 197
 								<div class="indent" [ngClass]="{'height-200': isShowMove, 'height-100': !isShowMove && detailsData.medicalRecords}">{{detailsData.medicalRecords||'无'}}</div>
@@ -207,8 +201,15 @@
207 201
 								</div>
208 202
 							</div>
209 203
 							
204
+							<div class="form-list">
205
+								<div class="form-title font-weight-500">临床诊断:</div>
206
+								<div class="indent">
207
+									{{detailsData.diagnose||'无'}}
208
+								</div>
209
+							</div>
210
+							
210 211
 								<div class="form-list">
211
-									<div class="form-title font-weight-500">手术方案:</div>
212
+									<div class="form-title font-weight-500">手术诊断:</div>
212 213
 									<div class="indent">{{detailsData.surgicalPlan||'无'}}</div>
213 214
 								</div>
214 215
 								<div class="form-list">
@@ -243,7 +244,7 @@
243 244
 				</div>
244 245
 			</div>
245 246
 		
246
-		<div class="content-item-right" *ngIf="adviceList && adviceList.pathologyAdviceDTOS.length>0 && pathologyLogs.length && (viewType=='view' || viewType=='edit')">
247
+		<div class="content-item-right" *ngIf="adviceList && adviceList.pathologyFormDTOS.length>0 && pathologyLogs.length && (viewType=='view' || viewType=='edit')">
247 248
 			<div class="step-title">病理闭环</div>
248 249
 			<nz-steps [nzCurrent]="stepLength" nzDirection="vertical" nzSize="small">
249 250
 				<ng-container *ngFor="let item of pathologyLogs; let index = index">
@@ -380,7 +381,7 @@
380 381
 					</div>
381 382
 				</nz-form-item>
382 383
 				
383
-				<nz-form-item class="form-item">
384
+<!-- 				<nz-form-item class="form-item">
384 385
 					<nz-form-label [nzSm]="4" [nzXs]="24">快捷键入</nz-form-label>
385 386
 					<div class="specimen-list">
386 387
 						<div *ngFor="let item of fastList;let index=index;" class="select-item"
@@ -388,16 +389,16 @@
388 389
 							{{item.name}}
389 390
 						</div>
390 391
 					</div>
391
-				</nz-form-item>
392
+				</nz-form-item> -->
392 393
 				
393 394
 				<nz-form-item class="form-item">
394 395
 					<nz-form-label nzRequired nzFor="specimenName" [nzSm]="3" [nzXs]="24">标本名称</nz-form-label>
395 396
 					<div class="specimen-tip" [ngClass]="{'isSpecumen':placeName}">{{placeName?placeName:''}}</div>
396 397
 					<nz-form-control nzErrorTip="请输入标本名称" [(nzSm)]="nzSmNum" [nzXs]="24">
397
-						<input nz-input maxlength="15" (ngModelChange)="specimenInput($event)" formControlName="specimenName" placeholder="请输入标本名称"/>
398
+						<input nz-input maxlength="20" (ngModelChange)="specimenInput($event)" formControlName="specimenName" placeholder="请输入标本名称"/>
398 399
 					</nz-form-control>
399
-					<div class="empty-box" [ngClass]="{'beSpecumenEmpty':placeName, 'noSpecumenEmpty':placeName==''}">
400
-						<span class="name">{{specimenNameLength}}/15</span>
400
+					<div class="empty-box" [ngClass]="{'beSpecumenEmpty':placeName, 'noSpecumenEmpty':!placeName}">
401
+						<span class="name">{{specimenNameLength}}/20</span>
401 402
 						<span class="empty" (click)="emptData($event)">清空</span>
402 403
 					</div>
403 404
 				</nz-form-item>
@@ -429,9 +430,9 @@
429 430
 <app-dialog-delete [delModal]="delModal" (hideDelModalEvent)="hideDelModal()" [btnLoading]="btnLoading"
430 431
 	(confirmDelEvent)="confirmDel()" content="您确认要删除标本吗?"></app-dialog-delete>
431 432
 
432
-<!-- 删除医嘱 -->
433
-<app-dialog-delete [delModal]="delAdviceModal" (hideDelModalEvent)="hideAdviceModal()" [btnLoading]="btnLoading"
434
-	(confirmDelEvent)="confirmAdvice()" content="您确认要删除医嘱吗?"></app-dialog-delete>
433
+<!-- 删除申请单 -->
434
+<app-dialog-delete [delModal]="delAdviceModal" (hideDelModalEvent)="hideAdviceModal()" [btnLoading]="btnDelLoading"
435
+	(confirmDelEvent)="confirmAdvice()" content="您确认要删除申请单吗?"></app-dialog-delete>
435 436
 		
436 437
 <!-- 查看标本 -->
437 438
 <div class="look">
@@ -575,7 +576,7 @@
575 576
 							<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
576 577
 						</div>
577 578
 						<div style="margin-top:10px;">
578
-							<div style="width: 100%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
579
+							<div style="width: 98%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
579 580
 						</div>
580 581
 					 </div>
581 582
 					 <div style="width: 30%;">
@@ -601,26 +602,29 @@
601 602
 		<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
602 603
 			<div *ngFor="let data of printData.specimenList; let index=index;">
603 604
 				<div style="width: 100%;display: flex;margin-top: 5px;padding: 0 7px;">
604
-				 <div style="width: 46%;">
605
-					 <div style="display: flex;justify-content: center;">
605
+				 <div style="width: 35%;">
606
+					 <div style="display: flex;">
606 607
 						 <div style="width: 50px;height: 50px;">
607 608
 						 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
608 609
 						 </div>
609
-						 <div style="width: 12px;">申请单</div>
610
+						 <!-- <div style="width: 12px;">申请单</div> -->
610 611
 					 </div>
611 612
 					 <div>{{printData.applyCode}}</div>
612 613
 				 </div>
613
-				 <div style="width: 4%;"></div>
614
-				 <div style="width: 49%;">
615
-					<div style="display: flex;flex-wrap: nowrap;">门诊号: {{data.patientNo}}</div>
614
+				 <div style="width: 5%;"></div>
615
+				 <div style="width: 60%;position: relative;left: -5px;">
616
+					<div style="display: flex;flex-wrap: nowrap;">住院号: {{data.residenceNo}}</div>
616 617
 					<div style="margin-top:9px;">患者: {{data.patientName}}</div>
617
-					<div style="margin-top:9px;margin-left: 25px;">性别: {{data.patientGender}}</div>
618
+					<div style="margin-top:9px;margin-left: 30px;">性别: {{data.patientGender}}</div>
618 619
 				 </div>
619 620
 				</div>
620
-				<div style="margin-top:10px;padding-left: 7px;">
621
-					<div style="width: 100%;height: 32px;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
621
+				<div style="margin-top:3px;padding-left: 7px;">
622
+					<div style="width: 98%;overflow: hidden;">部位: {{data.partSource}}{{data.specimenName}}</div>
623
+				</div>
624
+				<div style="margin-top:3px;padding-left: 7px;">
625
+					<div style="width: 98%;">日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
622 626
 				</div>
623
-			 <div style="height: 11px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1 && index+1 < printData.specimenList.length"></div>
627
+			 <div style="height: 18px;" *ngIf="printData && printData.specimenList && printData.specimenList.length>1 && index+1 < printData.specimenList.length"></div>
624 628
 			</div>
625 629
 		</div>
626 630
 	</div>

+ 7 - 2
src/app/views/pathology-sample/pathology-sample.component.less

@@ -915,11 +915,11 @@
915 915
 						}
916 916
 					}
917 917
 					.beSpecumenEmpty{
918
-						right: 6px;
918
+						right: 10px;
919 919
 						top: 8px;
920 920
 					}
921 921
 					.noSpecumenEmpty{
922
-						right: 6px;
922
+						right: 10px;
923 923
 						top: 8px;
924 924
 					}
925 925
 				}
@@ -953,6 +953,11 @@
953 953
 	  }
954 954
 		.no-width{
955 955
 			width: 33% !important;
956
+			.ant-input-disabled{
957
+				color: rgba(0, 0, 0, 0.65) !important;
958
+				background: #fff !important;
959
+				border: none !important;
960
+			}
956 961
 		}
957 962
 	}
958 963
 

+ 59 - 32
src/app/views/pathology-sample/pathology-sample.component.ts

@@ -83,15 +83,18 @@ export class PathologySampleComponent implements OnInit {
83 83
 	project:any;
84 84
 	viewType:any = 'no';
85 85
 	mainRole:any;
86
+	deptId:any = null;
87
+	btnDelLoading:any = false;
86 88
   ngOnInit() {
87 89
 		this.changeInpSubject.pipe(debounceTime(500)).subscribe((v) => {
88 90
 		  this.searchSpecimenData(v[0])
89 91
 		});
90 92
 		this.changeInpSubjectSpecimen.pipe(debounceTime(500)).subscribe((v) => {
91
-		  this.searchSpecimen(v[0],'search')
93
+		  this.searchSpecimen(v[0],'search','new')
92 94
 		});
93 95
 		this.hosId = this.tool.getCurrentHospital().id;
94
-		this.userId = this.tool.getCurrentUserId()
96
+		this.userId = this.tool.getCurrentUserId();
97
+		this.deptId = this.tool.getCurrentUserDept().id;
95 98
 		this.getProDicData()
96 99
 		this.getDicData()
97 100
 		this.getSourceData()
@@ -108,7 +111,7 @@ export class PathologySampleComponent implements OnInit {
108 111
 		});
109 112
 		if(this.route.snapshot.params && this.route.snapshot.params.param){
110 113
 			this.barCode = this.route.snapshot.params.param
111
-			this.searchSpecimen(this.barCode,'search')
114
+			this.searchSpecimen(this.barCode,'search','new')
112 115
 		}
113 116
 		setTimeout(_=>{
114 117
 			document.getElementById('Binput').focus();
@@ -228,8 +231,7 @@ export class PathologySampleComponent implements OnInit {
228 231
 			if(this.leftIndex == null){
229 232
 				this.leftIndex = 0
230 233
 			}
231
-			this.fetchDataList(data.data.id);
232
-			this.searchSpecimen(this.adviceList.patientNo,'add');
234
+			this.searchSpecimen(this.residenceNo,'add','bottom');
233 235
 		});
234 236
 	}
235 237
 	
@@ -278,7 +280,7 @@ export class PathologySampleComponent implements OnInit {
278 280
 	    });
279 281
 	}
280 282
 	
281
-	// 病理医嘱删除
283
+	// 病理申请单删除
282 284
 	itemData:any;
283 285
 	delAdviceModal:any = false;
284 286
 	itemDataType:any = 2;
@@ -291,18 +293,17 @@ export class PathologySampleComponent implements OnInit {
291 293
 	
292 294
 	// 确定删除
293 295
 	confirmAdvice(){
294
-		this.btnLoading = true;
296
+		this.btnDelLoading = true;
295 297
 		this.mainService
296 298
 		  .coopTypeConfig(
297 299
 		    "rmvData",
298
-		    "pathologyAdvice",
300
+		    "pathologyForm",
299 301
 		     [this.itemData.id]
300 302
 		  )
301 303
 		  .subscribe((data) => {
302
-		    this.btnLoading = false;
304
+		    this.btnDelLoading = false;
303 305
 		    this.delAdviceModal = false;
304
-				this.searchSpecimen(this.adviceList.patientNo,'load');
305
-				// this.fetchDataList(this.itemData.pathologyFormId);
306
+				this.searchSpecimen(this.residenceNo,'load', 'new');
306 307
 		    if (data.status==200) {
307 308
 		      this.showSpecimenModal("删除", true, "");
308 309
 		    } else {
@@ -321,8 +322,8 @@ export class PathologySampleComponent implements OnInit {
321 322
 	listClick(item,index){
322 323
 		this.leftIndex = index
323 324
 		this.adviceItem = item
324
-		if(item.pathologyFormId){
325
-			this.fetchDataList(item.pathologyFormId);
325
+		if(item.id){
326
+			this.fetchDataList(item.id);
326 327
 		}else{
327 328
 			this.viewType = 'add'
328 329
 		}
@@ -335,7 +336,8 @@ export class PathologySampleComponent implements OnInit {
335 336
 	
336 337
 	// 标本条码搜索
337 338
 	adviceList:any = null;
338
-	searchSpecimen(e,type){
339
+	residenceNo:any = null;
340
+	searchSpecimen(e,type,optType){
339 341
 		if(type!='add' && type!='load'){
340 342
 			if(!this.barCode){
341 343
 				return
@@ -346,13 +348,16 @@ export class PathologySampleComponent implements OnInit {
346 348
 		}
347 349
 		let data:any = {
348 350
 			idx: 0,
349
-			sum: 9999,
350
-			pathologyAdvice:{
351
-				patientNo:this.barCode?this.barCode:e
351
+			sum: 10,
352
+			pathologyForm:{
353
+				order: "createTime desc",
354
+				patientNo:this.barCode?this.barCode:e,
355
+				surgeryDeptId:this.deptId,
356
+				operationType:'outpatientPathologyForm'
352 357
 			}
353 358
 		}
354 359
 		this.isSpinning = true
355
-		this.mainService.getFetchDataList("data", "pathologyAdvice", data)
360
+		this.mainService.getFetchDataList("data", "pathologyForm", data)
356 361
 		.subscribe((res:any) => {
357 362
 			this.isSpinning = false
358 363
 			if(res.status==200){
@@ -369,8 +374,22 @@ export class PathologySampleComponent implements OnInit {
369 374
 					this.viewType = 'no';
370 375
 				}
371 376
 				if(res.list.length>0){
377
+					for(let i of res.list[0].pathologyFormDTOS){
378
+						i.project = []
379
+						if(i.pathologyInspectDTOS){
380
+							for(let x of i.pathologyInspectDTOS){
381
+								i.project.push(x.inspectProject.name)
382
+							}
383
+						}
384
+					}
372 385
 					this.adviceList = res.list[0]
373
-					this.patientId = this.adviceList.patientId
386
+					this.residenceNo = this.adviceList.patientDTO.residenceNo?this.adviceList.patientDTO.residenceNo:this.adviceList.patientDTO.patientCode
387
+					this.patientId = this.adviceList.patientDTO.id
388
+					if(optType=='bottom'){
389
+						this.leftIndex = 0;
390
+						this.adviceItem = this.adviceList.pathologyFormDTOS[0];
391
+						this.fetchDataList(this.adviceList.pathologyFormDTOS[0].id);
392
+					}
374 393
 				}else{
375 394
 					this.adviceList = null
376 395
 					this.viewType = 'no';
@@ -431,22 +450,29 @@ export class PathologySampleComponent implements OnInit {
431 450
 		this.inVitroData = format(result, 'yyyy-MM-dd');
432 451
 		console.log(this.inVitroData)
433 452
 	}
434
-	inVitroTimeSelect:any;
453
+	inVitroTimeSelect:any = null;
435 454
 	inVitroTimeChange(result){
436
-		this.inVitroTimeSelect = format(result, 'HH:mm');
455
+		if(result){
456
+			this.inVitroTimeSelect = format(result, 'HH:mm');
457
+		}else{
458
+			this.inVitroTimeSelect = null;
459
+		}
437 460
 		console.log(this.inVitroData + ' ' + this.inVitroTimeSelect)
438 461
 	}
439
-
440 462
 	
441 463
 	// 提交固定标本接收
442 464
 	startDate:any;
443 465
 	printLoading:any = false;
444 466
 	submitVerificationForm(){
445 467
 		let that = this
446
-		if(!this.fixationTimeSelect && this.fixationTimeSelect == null){
468
+		if(!this.fixationTimeSelect || this.fixationTimeSelect == null){
447 469
 			this.message.error('请选择固定时间')
448 470
 			return
449 471
 		}
472
+		if(!this.inVitroTimeSelect || this.inVitroTimeSelect == null){
473
+			this.message.error('请选择离体时间')
474
+			return
475
+		}
450 476
 		for (const i in this.validatePrintForm.controls) {
451 477
 		  this.validatePrintForm.controls[i].markAsDirty();
452 478
 		  this.validatePrintForm.controls[i].updateValueAndValidity();
@@ -508,7 +534,7 @@ export class PathologySampleComponent implements OnInit {
508 534
 					}
509 535
 					that.printLoading = false;
510 536
 					that.printData = arr;
511
-					this.searchSpecimen(this.adviceList.patientNo,'load');
537
+					this.searchSpecimen(this.residenceNo,'load', 'new');
512 538
 					setTimeout(() => {
513 539
 					  const printContent = document.getElementById("report");
514 540
 					  const WindowPrt = window.open("", "", "width=100,height=1000");
@@ -850,8 +876,8 @@ export class PathologySampleComponent implements OnInit {
850 876
 			this.specimenNameId = item.id
851 877
 			this.specimenNameName = item.name
852 878
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
853
-				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>14){
854
-					this.message.error('字符长度不能超过15个')
879
+				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>19){
880
+					this.message.error('字符长度不能超过20个')
855 881
 					return
856 882
 				}
857 883
 			}
@@ -875,8 +901,8 @@ export class PathologySampleComponent implements OnInit {
875 901
 	fastClick(e,item,index){
876 902
 		this.fastIndex = index
877 903
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
878
-				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>14){
879
-					this.message.error('字符长度不能超过15个')
904
+				if(item.name.length+this.validateSpecimenForm.value.specimenName.length>19){
905
+					this.message.error('字符长度不能超过20个')
880 906
 					return
881 907
 				}
882 908
 			}
@@ -919,8 +945,8 @@ export class PathologySampleComponent implements OnInit {
919 945
 		  this.validateSpecimenForm.controls[i].updateValueAndValidity();
920 946
 		}
921 947
 		if (this.validateSpecimenForm.invalid) return;
922
-		if(this.validateSpecimenForm.value.specimenName.length>15){
923
-			this.message.error('字符长度不能超过15个')
948
+		if(this.validateSpecimenForm.value.specimenName.length>19){
949
+			this.message.error('字符长度不能超过20个')
924 950
 			return
925 951
 		}
926 952
 		if(type==2){
@@ -1038,7 +1064,7 @@ export class PathologySampleComponent implements OnInit {
1038 1064
 	// 监听输入字数
1039 1065
 	specimenNameLength:any=0;
1040 1066
 	specimenInput(e){
1041
-		if(e.length>15){
1067
+		if(e.length>20){
1042 1068
 			return
1043 1069
 		}
1044 1070
 		this.specimenNameLength = e.length
@@ -1078,6 +1104,7 @@ export class PathologySampleComponent implements OnInit {
1078 1104
 	
1079 1105
 	// 关闭标本
1080 1106
 	closeSpecimenModel(){
1107
+		this.itemDataType = 2
1081 1108
 		this.hideSpecimenModal()
1082 1109
 	}
1083 1110
 	
@@ -1342,7 +1369,7 @@ export class PathologySampleComponent implements OnInit {
1342 1369
 					}
1343 1370
 					this.btnLoading = false;
1344 1371
 					this.printData = arr;
1345
-					this.searchSpecimen(this.adviceList.patientNo,'load');
1372
+					this.searchSpecimen(this.residenceNo,'load', 'new');
1346 1373
 					setTimeout(() => {
1347 1374
 						const printContent = document.getElementById("report");
1348 1375
 						const WindowPrt = window.open("", "", "width=100,height=1000");

+ 31 - 10
src/app/views/specimen-room-view/specimen-room-view.component.html

@@ -28,7 +28,22 @@
28 28
 			</div>
29 29
 			<button class="right-btn" nz-button nzType="primary" (click)="specimenCheck()">标本核对</button>
30 30
     </div>
31
-    <div class="userInfo">
31
+		<div class="right">
32
+		  <div class="userInfo dropdown">
33
+		    <div class="user" (mouseenter)="showDropdown = true" (mouseleave)="showDropdown = false">
34
+		      <img src="../../assets/images/icon_keshi.png" alt="">
35
+		      <span><ng-container *ngIf="loginUser.dept">{{deptDisplay == 2 ? loginUser.dept.deptalias : loginUser.dept.dept}}-</ng-container>{{loginUser.name}}</span>
36
+		      <i class="icon_transport transport-xiala1 ml8"></i>
37
+		    </div>
38
+		    <div class="dropdown-content r8" [hidden]="!showDropdown" (mouseenter)="showDropdown = true" (mouseleave)="showDropdown = false">
39
+		      <div class="dropdownItem" (click)="setSpecimen()">切换科室</div>
40
+					<div class="dropdownItem" (click)="distributionRecord()">配送记录</div>
41
+					<div class="dropdownItem" (click)="toMain()">回到系统管理</div>
42
+		      <div class="dropdownItem" (click)="logOut()">退出</div>
43
+		    </div>
44
+		  </div>
45
+		</div>
46
+<!--    <div class="userInfo">
32 47
       <div class="wel">欢迎您:</div>
33 48
       <div class="user">
34 49
         <img src="../../assets/images/icon_keshi.png" alt="" />
@@ -40,7 +55,7 @@
40 55
         <div class="logOut" (click)="setSpecimen()">切换科室</div>
41 56
         <div class="logOut" (click)="logOut()">退出</div>
42 57
       </div>
43
-    </div>
58
+    </div> -->
44 59
   </div>
45 60
   <!-- 头部 end -->
46 61
   <!-- 主体部分 start -->
@@ -50,7 +65,7 @@
50 65
       <!-- 标题 start -->
51 66
       <div class="pharmacy-main__title">
52 67
         <strong>手术间标本</strong>
53
-				<span *ngIf="printPharmacyList.length>0">共 {{printPharmacyList.length}} 条</span>
68
+				<span *ngIf="otherData1">{{otherData1.pathologyFormNum}}申请单 {{otherData1.specimenNum}}标本</span>
54 69
         <span class="autoUpdate">{{ logTime }}秒</span>
55 70
       </div>
56 71
       <!-- 标题 end -->
@@ -82,6 +97,7 @@
82 97
                 <span title="住院号" class="weight">
83 98
 									<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
84 99
 									<span *ngIf="item.pathologyFormType==0">普</span>
100
+									<span *ngIf="item.pathologyFormType==2">细</span>
85 101
 									{{item.applyCode || '无'}}
86 102
 								</span>
87 103
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
@@ -141,7 +157,7 @@
141 157
       <!-- 标题 start -->
142 158
       <div class="pharmacy-main__title">
143 159
         <strong>标本间标本</strong>
144
-				<span *ngIf="waitPharmacyList.length>0">共 {{waitPharmacyList.length}} 条</span>
160
+				<span *ngIf="otherData2">{{otherData2.pathologyFormNum}}申请单 {{otherData2.specimenNum}}标本</span>
145 161
         <span class="autoUpdate">{{ logTime }}秒</span>
146 162
       </div>
147 163
       <!-- 标题 end -->
@@ -173,6 +189,7 @@
173 189
                 <span title="住院号" class="weight">
174 190
 									<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
175 191
 									<span *ngIf="item.pathologyFormType==0">普</span>
192
+									<span *ngIf="item.pathologyFormType==2">细</span>
176 193
 									{{item.applyCode || '无'}}
177 194
             		</span>
178 195
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
@@ -232,7 +249,7 @@
232 249
       <!-- 标题 start -->
233 250
       <div class="pharmacy-main__title">
234 251
         <strong>今日离科标本</strong>
235
-				<span *ngIf="pharmacyList.length>0">共 {{pharmacyList.length}} 条</span>
252
+				<span *ngIf="otherData3">{{otherData3.pathologyFormNum}}申请单 {{otherData3.specimenNum}}标本</span>
236 253
         <span class="autoUpdate">{{ logTime }}秒</span>
237 254
       </div>
238 255
       <!-- 标题 end -->
@@ -264,6 +281,7 @@
264 281
                 <span title="住院号" class="weight">
265 282
             			<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
266 283
             			<span *ngIf="item.pathologyFormType==0">普</span>
284
+									<span *ngIf="item.pathologyFormType==2">细</span>
267 285
 									{{item.applyCode || '无'}}
268 286
             		</span>
269 287
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
@@ -463,6 +481,9 @@
463 481
 		</overlay-scrollbars>
464 482
 		<div class="display_flex justify-content_flex-center">
465 483
 			<button class="btn" nz-button nzType="primary" (click)="submitForm()" [nzLoading]="btnLoading">确定</button>
484
+			<button class="btn mar-left" nz-button nzType="primary" nzGhost (click)="hideModal()">
485
+			  取消
486
+			</button>
466 487
 		</div>
467 488
 	</div>
468 489
 </div>
@@ -607,7 +628,7 @@
607 628
 						<input nz-input disabled formControlName="name" placeholder="请输入医生姓名" nzSize="default" />
608 629
 					</nz-form-control>
609 630
 				</nz-form-item>
610
-				<nz-form-item>
631
+<!-- 				<nz-form-item>
611 632
 				  <nz-form-label nzRequired [nzSpan]="6" nzFor="nurseJobNumber">护士工号</nz-form-label>
612 633
 					<nz-form-control [nzSpan]="18" nzErrorTip="请输入护士工号!">
613 634
 						<input nz-input (ngModelChange)="numberChange($event,2)" formControlName="nurseJobNumber" placeholder="请输入护士工号" nzSize="default" />
@@ -618,10 +639,10 @@
618 639
 					<nz-form-control [nzSpan]="18" nzErrorTip="请输入护士姓名!">
619 640
 						<input nz-input disabled formControlName="nurseName" placeholder="请输入护士姓名" nzSize="default" />
620 641
 					</nz-form-control>
621
-				</nz-form-item>
642
+				</nz-form-item> -->
622 643
 				<nz-form-item *ngIf="!ifFixType">
623
-				  <nz-form-label nzRequired [nzSpan]="8" nzFor="fixative">固定液类型</nz-form-label>
624
-				  <nz-form-control [nzSpan]="16" nzErrorTip="请选择固定液类型!">
644
+				  <nz-form-label nzRequired [nzSpan]="6" nzFor="fixative">固定液类型</nz-form-label>
645
+				  <nz-form-control [nzSpan]="18" nzErrorTip="请选择固定液类型!">
625 646
 				    <nz-input-group>
626 647
 							<nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择固定液类型" formControlName="fixative">
627 648
 							  <ng-container *ngFor="let option of fixativeData">
@@ -648,7 +669,7 @@
648 669
 		<div class="content">
649 670
 			<div class="content-item boder-right">
650 671
 				<nz-form-item class="form-title-box">
651
-					<div class="form-title">申请单类型:{{detailsData.pathologyFormType==1?'术中快速病理检查申请单':'病理检查申请单'}}</div>
672
+					<div class="form-title">申请单类型:{{detailsData.pathologyFormType==1?'术中快速病理检查申请单' : detailsData.pathologyFormType==2 ? '病理细胞学申请单' : '病理检查申请单'}}</div>
652 673
 					<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
653 674
 				</nz-form-item>
654 675
 				<nz-form-item class="form-title-box">

+ 119 - 36
src/app/views/specimen-room-view/specimen-room-view.component.less

@@ -14,7 +14,11 @@
14 14
     color: @primary-color!important;
15 15
     font-weight: bold !important;
16 16
   }
17
-
17
+	
18
+	.mar-left{
19
+		margin-left: 10px;
20
+	}
21
+	
18 22
   h1,
19 23
   h2,
20 24
   h3,
@@ -163,44 +167,118 @@
163 167
       }
164 168
     }
165 169
   }
166
-  .userInfo {
167
-		width: 260px;
170
+		
171
+	.right {
172
+		width: 20%;
168 173
 		height: 100%;
169
-		padding: 8px 36px 8px 8px;
170
-		box-sizing: border-box;
171
-		font-size: 14px;
172
-		border-left: 1px solid #e5e9ed;
174
+		flex-shrink: 0;
175
+		display: flex;
176
+		align-items: center;
177
+		justify-content: right;
178
+		// box-shadow: 0px 3px 6px 1px rgba(167, 167, 167, 0.16);
179
+		height: 48px;
180
+		.msg {
181
+			float: left;
182
+			width: 50px;
183
+			height: 100%;
184
+			border-left: 1px solid #e5e9ed;
173 185
 
174
-    .wel {
175
-      line-height: 15px;
176
-    }
186
+			.msgBtn {
187
+				width: 100%;
188
+				height: 100%;
177 189
 
178
-    .user {
179
-      font-size: 20px;
180
-      height: 36px;
181
-      display: flex;
182
-      justify-content: center;
183
-      align-items: center;
184
-      line-height: normal;
190
+				i {
191
+					font-size: 30px;
192
+				}
193
+			}
194
+		}
185 195
 
186
-      img {
187
-        height: 100%;
188
-        margin-right: 8px;
189
-      }
190
-    }
191
-    .userInfo-wrap {
192
-      display: flex;
193
-      justify-content: flex-end;
194
-      .logOut {
195
-        display: inline-block;
196
-        text-align: right;
197
-        color: @primary-color;
198
-        line-height: 20px;
199
-        cursor: pointer;
200
-        margin-right: 8px;
201
-      }
202
-    }
203
-  }
196
+		.userInfo {
197
+			height: 100%;
198
+			float: right;
199
+			padding: 0 24px;
200
+			box-sizing: border-box;
201
+			font-size: 14px;
202
+			// border-left: 1px solid #e5e9ed;
203
+
204
+			.wel {
205
+				line-height: 15px;
206
+				white-space: nowrap;
207
+				overflow: hidden;//文本超出隐藏
208
+				text-overflow: ellipsis;//文本超出省略号替代
209
+			}
210
+
211
+			.user {
212
+				overflow: hidden;
213
+				height: 48px;
214
+				display: flex;
215
+				justify-content: center;
216
+				align-items: center;
217
+				font-size: 16px;
218
+				cursor: pointer;
219
+
220
+				img {
221
+					width: 32px;
222
+					height: 32px;
223
+					margin-right: 8px;
224
+				}
225
+
226
+				span, .transport-xiala1 {
227
+					height: 48px;
228
+					line-height: 48px;
229
+				}
230
+			}
231
+
232
+			.logOut {
233
+				text-align: right;
234
+				color: @primary-color;
235
+				line-height: 20px;
236
+
237
+				span {
238
+					cursor: pointer;
239
+					padding: 10px;
240
+				}
241
+			}
242
+		}
243
+	}
244
+	
245
+	// 下拉列表
246
+	.dropdown{
247
+	  position: relative;
248
+	  height: 48px;
249
+	  line-height: 48px;
250
+	  .dropdown-content {
251
+	    position: absolute;
252
+	    top: 48px;
253
+	    background-color: #fff;
254
+	    width: 156px;
255
+	    box-shadow: 0px 2px 4px 1px #D9D9D9;
256
+	    z-index: 999999;
257
+	    border-radius: 4px;
258
+	    border: 1px solid rgba(0,0,0,0.15);
259
+	    color: rgba(0,0,0,0.65);
260
+	    &.ct{
261
+	      left: 50%;
262
+	      transform: translateX(-50%);
263
+	    }
264
+	    &.r8{
265
+	      right: 8px;
266
+	    }
267
+	  }
268
+	
269
+	  .dropdown-content .dropdownItem {
270
+	    height: 40px;
271
+	    cursor: pointer;
272
+	    display: flex;
273
+	    align-items: center;
274
+	    padding: 0 24px;
275
+	  }
276
+	
277
+	  .dropdown-content .dropdownItem:hover {
278
+	    background-color: #e9f7e9;
279
+	  }
280
+	}
281
+	
204 282
   // 头部 end
205 283
   // 主体部分 start
206 284
   .pharmacy-main {
@@ -649,7 +727,12 @@
649 727
 			}
650 728
 	  }
651 729
 		.no-width{
652
-			width: 30% !important;
730
+			width: 33% !important;
731
+			.ant-input-disabled{
732
+				color: rgba(0, 0, 0, 0.65) !important;
733
+				background: #fff !important;
734
+				border: none !important;
735
+			}
653 736
 		}
654 737
 	}
655 738
 

+ 55 - 36
src/app/views/specimen-room-view/specimen-room-view.component.ts

@@ -138,13 +138,14 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
138 138
 		});
139 139
 		this.hosId = this.tool.getCurrentHospital().id;
140 140
 		this.userId = this.tool.getCurrentUserId()
141
+		// 手术间列表
142
+		this.getPharmacyList(this.printPharmacyIdx, 'surgeryDept', this.printPharmacySearchKey);
143
+		// 标本间列表
144
+		this.getPharmacyList(this.waitPharmacyIdx, 'specimenDept', this.waitPharmacySearchKey);
145
+		// 今日离科标本列表
146
+		this.getPharmacyList(this.pharmacyIdx, 'leavedDept', this.pharmacySearchKey);
141 147
     this.runTime();
142
-    // 统计
143
-    // this.total();
144 148
 		this.getDept()
145
-    // 切换科室
146
-    // this.changeKs();
147
-
148 149
     this.initRole();
149 150
     // 自动刷新倒计时 start
150 151
     this.autoUpdate();
@@ -289,7 +290,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
289 290
 		this.fixationData = format(result, 'yyyy-MM-dd');
290 291
 		console.log(this.fixationData)
291 292
 	}
292
-	fixationTimeSelect:any;
293
+	fixationTimeSelect:any = null;
293 294
 	fixationTimeChange(result){
294 295
 		if(result){
295 296
 			this.fixationTimeSelect = format(result, 'HH:mm');
@@ -310,8 +311,8 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
310 311
 		  fixationDate: [null, [Validators.required]],
311 312
 			jobNumber: [null, [Validators.required]],
312 313
 			name:[null, [Validators.required]],
313
-			nurseJobNumber: [null, [Validators.required]],
314
-			nurseName:[null, [Validators.required]],
314
+			// nurseJobNumber: [null, [Validators.required]],
315
+			// nurseName:[null, [Validators.required]],
315 316
 			fixative:[null, [Validators.required]],
316 317
 		});
317 318
 		let date = new Date();
@@ -336,9 +337,9 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
336 337
 				new FormControl(null, Validators.required)
337 338
 			);
338 339
 			this.validateVerificationForm.controls.fixationDate.setValue(inVitroDate);
339
-			// this.validateVerificationForm.controls.fixationTimes.setValue(date);
340
+			this.validateVerificationForm.controls.fixationTimes.setValue(date);
340 341
 			this.fixationData = inVitroDate;
341
-			// this.fixationTimeSelect = format(date, 'HH:mm');
342
+			this.fixationTimeSelect = format(date, 'HH:mm');
342 343
 		}
343 344
 
344 345
 		this.btnLoading = true
@@ -417,7 +418,12 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
417 418
 	
418 419
 	// 获取科室
419 420
 	getDept(){
420
-		this.setSpecimen()
421
+		this.validateForm = this.fb.group({
422
+		  specimen: [null, [Validators.required]],
423
+			operation: [null, [Validators.required]],
424
+			generate:[null, [Validators.required]],
425
+			showFrozen:[null, [Validators.required]],
426
+		});
421 427
 		var that = this;
422 428
 		that.mainService.getDictionary("list", "dept_type").subscribe((res2) => {
423 429
 			let item1 = res2.find(i=>i.name=='手术室科室')
@@ -467,33 +473,28 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
467 473
 					this.validateForm.controls.operation.setValue(deptArr);
468 474
 				}
469 475
 				this.validateForm.controls.specimen.setValue(data.dept.id);
470
-				this.validateForm.controls.showFrozen.setValue(data.showFrozen);
471
-				if(data.autoCreateOrder){
476
+				if(data.showFrozen!=null){
477
+					this.validateForm.controls.showFrozen.setValue(data.showFrozen);
478
+				}else{
479
+					this.validateForm.controls.showFrozen.setValue(0);
480
+				}
481
+				if(data.autoCreateOrder!=null){
472 482
 					this.validateForm.controls.generate.setValue(data.autoCreateOrder);
483
+				}else{
484
+					this.validateForm.controls.generate.setValue(1);
473 485
 				}
474 486
 		  });
475 487
 	}
476 488
 
477 489
 	// 获取是否关联标本间
478 490
 	setSpecimen(){
479
-		if(this.validateForm){
480
-			this.validateForm = this.fb.group({
481
-			  specimen: [this.validateForm.value.specimen, [Validators.required]],
482
-				operation: [this.validateForm.value.operation, [Validators.required]],
483
-				generate:[this.validateForm.value.generate, [Validators.required]],
484
-				showFrozen:[this.validateForm.value.showFrozen, [Validators.required]],
485
-			});
486
-		}else{
487
-			this.validateForm = this.fb.group({
488
-			  specimen: [null, [Validators.required]],
489
-				operation: [null, [Validators.required]],
490
-				generate:[1, [Validators.required]],
491
-				showFrozen:[0, [Validators.required]],
492
-			});
493
-		}
494 491
 		this.relevanceModal = true
495 492
 	}
496
-
493
+	
494
+	hideModal(){
495
+		this.relevanceModal = false
496
+	}
497
+	
497 498
 	// 确定关联科室
498 499
 	btnLoading:boolean = false;
499 500
 	submitForm(){
@@ -568,6 +569,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
568 569
 				this.loginUser = data.data
569 570
 	      let user = JSON.parse(localStorage.getItem("user"));
570 571
 	      user.user.dept = data["data"].dept;
572
+				user.user.autoCreateOrder = data["data"].autoCreateOrder;
571 573
 	      user.user.currentHospital = data["data"].currentHospital;
572 574
 	      localStorage.setItem("user", JSON.stringify(user));
573 575
 	    }
@@ -578,10 +580,10 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
578 580
 	handoverUserId:any = null; //医生工号
579 581
 	nurseId:any = null; //护士工号
580 582
 	numberChange(e,type){
581
-		// if(e.length < 3) {
582
-		// 	this.validateVerificationForm.controls.name.setValue('');
583
-		// 	return
584
-		// }
583
+		if(e.length < 3) {
584
+			this.validateVerificationForm.controls.name.setValue('');
585
+			return
586
+		}
585 587
 		let query = {
586 588
 		  account: e
587 589
 		};
@@ -593,8 +595,8 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
593 595
 						this.validateVerificationForm.controls.name.setValue(data.userName);
594 596
 						this.handoverUserId = data.userId
595 597
 					}else{
596
-						this.validateVerificationForm.controls.nurseName.setValue(data.userName);
597
-						this.nurseId = data.userId
598
+						// this.validateVerificationForm.controls.nurseName.setValue(data.userName);
599
+						// this.nurseId = data.userId
598 600
 					}
599 601
 				}
600 602
 		  });
@@ -777,6 +779,9 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
777 779
   loading3 = false;
778 780
   loading4 = false;
779 781
   loading5 = false;
782
+	otherData1 = null;
783
+	otherData2 = null;
784
+	otherData3 = null;
780 785
   getPharmacyList(idx, type, searchKey) {
781 786
     let hosId = JSON.parse(localStorage.getItem("user")).user.currentHospital.id;
782 787
     switch (type) {
@@ -828,6 +833,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
828 833
               } else {
829 834
                 this.printPharmacyFlag = true;
830 835
               }
836
+							this.otherData1 = result.otherData;
831 837
               // 列表数据合并
832 838
               if (idx === 0) {
833 839
                 this.printPharmacyList = result["list"];
@@ -848,6 +854,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
848 854
               } else {
849 855
                 this.waitPharmacyFlag = true;
850 856
               }
857
+							this.otherData2 = result.otherData;
851 858
               if (idx === 0) {
852 859
                 this.waitPharmacyList = result["list"];
853 860
               } else {
@@ -867,6 +874,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
867 874
               } else {
868 875
                 this.pharmacyFlag = true;
869 876
               }
877
+							this.otherData3 = result.otherData;
870 878
               if (idx === 0) {
871 879
                 this.pharmacyList = result["list"];
872 880
               } else {
@@ -963,6 +971,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
963 971
 
964 972
   // 右侧菜单
965 973
   showLastItems: boolean = false;
974
+	showDropdown:boolean = false;
966 975
   // 下拉
967 976
   fixedMenuXiala() {
968 977
     this.showLastItems = true;
@@ -972,7 +981,17 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
972 981
   fixedMenuShangla() {
973 982
     this.showLastItems = false;
974 983
   }
975
-
984
+	
985
+	// 回到系统管理
986
+	toMain() {
987
+	  this.router.navigateByUrl("main");
988
+	}
989
+	
990
+	// 配送记录
991
+	distributionRecord(){
992
+		this.router.navigateByUrl("batchDistribution");
993
+	}
994
+	
976 995
   mainRole: boolean = false; //回到系统管理权限
977 996
   initRole() {
978 997
     let menus = JSON.parse(localStorage.getItem("menu"));