Browse Source

拉取代码

maotao 5 months ago
parent
commit
75dc7970f9
21 changed files with 1350 additions and 405 deletions
  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
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
9
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
10
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
10
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
11
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
11
 						<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
12
+						<div class="form-title" *ngIf="detailsData.pathologyFormType==2">申请单类型:病理细胞学申请单</div>
12
 						<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
13
 						<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
13
 					</nz-form-item>
14
 					</nz-form-item>
14
 					<nz-form-item class="form-title-box">
15
 					<nz-form-item class="form-title-box">
@@ -195,7 +196,7 @@
195
 					</div>
196
 					</div>
196
 				</nz-form-item>
197
 				</nz-form-item>
197
 				
198
 				
198
-				<nz-form-item class="form-item">
199
+	<!-- 			<nz-form-item class="form-item">
199
 					<nz-form-label [nzSm]="4" [nzXs]="24">快捷键入</nz-form-label>
200
 					<nz-form-label [nzSm]="4" [nzXs]="24">快捷键入</nz-form-label>
200
 					<div class="specimen-list">
201
 					<div class="specimen-list">
201
 						<div *ngFor="let item of fastList;let index=index;" class="select-item"
202
 						<div *ngFor="let item of fastList;let index=index;" class="select-item"
@@ -203,16 +204,16 @@
203
 							{{item.name}}
204
 							{{item.name}}
204
 						</div>
205
 						</div>
205
 					</div>
206
 					</div>
206
-				</nz-form-item>
207
+				</nz-form-item> -->
207
 				
208
 				
208
 				<nz-form-item class="form-item">
209
 				<nz-form-item class="form-item">
209
 					<nz-form-label nzRequired nzFor="specimenName" [nzSm]="3" [nzXs]="24">标本名称</nz-form-label>
210
 					<nz-form-label nzRequired nzFor="specimenName" [nzSm]="3" [nzXs]="24">标本名称</nz-form-label>
210
 					<div class="specimen-tip" [ngClass]="{'isSpecumen':placeName}">{{placeName?placeName:''}}</div>
211
 					<div class="specimen-tip" [ngClass]="{'isSpecumen':placeName}">{{placeName?placeName:''}}</div>
211
 					<nz-form-control nzErrorTip="请输入标本名称" [(nzSm)]="nzSmNum" [nzXs]="24">
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
 					</nz-form-control>
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
 						<span class="empty" (click)="emptData($event)">清空</span>
217
 						<span class="empty" (click)="emptData($event)">清空</span>
217
 					</div>
218
 					</div>
218
 				</nz-form-item>
219
 				</nz-form-item>
@@ -273,7 +274,7 @@
273
 						</nz-input-group>
274
 						</nz-input-group>
274
 					</nz-form-control>
275
 					</nz-form-control>
275
 				</nz-form-item>
276
 				</nz-form-item>
276
-				<nz-form-item *ngIf="ifImmobilization">
277
+				<nz-form-item *ngIf="ifImmobilization && detailsData.pathologyFormType==0">
277
 				  <nz-form-label nzRequired [nzSpan]="6" nzFor="fixationTime">固定时间</nz-form-label>
278
 				  <nz-form-label nzRequired [nzSpan]="6" nzFor="fixationTime">固定时间</nz-form-label>
278
 				  <nz-form-control style="display: flex;align-items: center;" [nzSpan]="18" nzErrorTip="请选择固定时间!">
279
 				  <nz-form-control style="display: flex;align-items: center;" [nzSpan]="18" nzErrorTip="请选择固定时间!">
279
 				    <nz-input-group style="display: flex;gap: 10px">
280
 				    <nz-input-group style="display: flex;gap: 10px">
@@ -286,7 +287,7 @@
286
 						</nz-input-group>
287
 						</nz-input-group>
287
 				  </nz-form-control>
288
 				  </nz-form-control>
288
 				</nz-form-item>
289
 				</nz-form-item>
289
-				<nz-form-item *ngIf="ifImmobilization">
290
+				<nz-form-item *ngIf="ifImmobilization && detailsData.pathologyFormType==0">
290
 				  <nz-form-label nzRequired [nzSpan]="8" nzFor="fixative">固定液类型</nz-form-label>
291
 				  <nz-form-label nzRequired [nzSpan]="8" nzFor="fixative">固定液类型</nz-form-label>
291
 				  <nz-form-control [nzSpan]="16" nzErrorTip="请选择固定液类型!">
292
 				  <nz-form-control [nzSpan]="16" nzErrorTip="请选择固定液类型!">
292
 				    <nz-input-group>
293
 				    <nz-input-group>
@@ -304,10 +305,10 @@
304
 						<input nz-input (ngModelChange)="numberChange($event)" formControlName="jobNumber" placeholder="请输入工号" nzSize="default" />
305
 						<input nz-input (ngModelChange)="numberChange($event)" formControlName="jobNumber" placeholder="请输入工号" nzSize="default" />
305
 					</nz-form-control>
306
 					</nz-form-control>
306
 				</nz-form-item>
307
 				</nz-form-item>
307
-				<nz-form-item class="df">
308
+				<nz-form-item>
308
 				  <nz-form-label nzRequired [nzSpan]="5">姓名</nz-form-label>
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
 					</nz-form-control>
312
 					</nz-form-control>
312
 				</nz-form-item>
313
 				</nz-form-item>
313
 			</form>
314
 			</form>
@@ -455,7 +456,7 @@
455
 								<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
456
 								<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
456
 							</div>
457
 							</div>
457
 							<div style="margin-top:10px;">
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
 							</div>
460
 							</div>
460
 						 </div>
461
 						 </div>
461
 						 <div style="width: 30%;">
462
 						 <div style="width: 30%;">
@@ -481,26 +482,29 @@
481
 			<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
482
 			<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
482
 				<div *ngFor="let data of printData.specimenList; let index=index;">
483
 				<div *ngFor="let data of printData.specimenList; let index=index;">
483
 					<div style="width: 100%;display: flex;margin-top: 5px;padding: 0 7px;">
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
 							 <div style="width: 50px;height: 50px;">
487
 							 <div style="width: 50px;height: 50px;">
487
 							 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
488
 							 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
488
 							 </div>
489
 							 </div>
489
-							 <div style="width: 12px;">申请单</div>
490
+							 <!-- <div style="width: 12px;">申请单</div> -->
490
 						 </div>
491
 						 </div>
491
 						 <div>{{printData.applyCode}}</div>
492
 						 <div>{{printData.applyCode}}</div>
492
 					 </div>
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
 						<div style="display: flex;flex-wrap: nowrap;">住院号: {{data.residenceNo}}</div>
496
 						<div style="display: flex;flex-wrap: nowrap;">住院号: {{data.residenceNo}}</div>
496
 						<div style="margin-top:9px;">患者: {{data.patientName}}</div>
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
 					 </div>
499
 					 </div>
499
 					</div>
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
 					</div>
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
 				</div>
508
 				</div>
505
 			</div>
509
 			</div>
506
 		</div>
510
 		</div>

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

@@ -269,11 +269,11 @@
269
 						}
269
 						}
270
 					}
270
 					}
271
 					.beSpecumenEmpty{
271
 					.beSpecumenEmpty{
272
-						right: 6px;
272
+						right: 10px;
273
 						top: 8px;
273
 						top: 8px;
274
 					}
274
 					}
275
 					.noSpecumenEmpty{
275
 					.noSpecumenEmpty{
276
-						right: 6px;
276
+						right: 10px;
277
 						top: 8px;
277
 						top: 8px;
278
 					}
278
 					}
279
 				}
279
 				}
@@ -307,6 +307,9 @@
307
 	  }
307
 	  }
308
 		.no-width{
308
 		.no-width{
309
 			width: 33% !important;
309
 			width: 33% !important;
310
+			.ant-select{
311
+				width: 100% !important;
312
+			}
310
 			.ant-input-disabled{
313
 			.ant-input-disabled{
311
 				color: rgba(0, 0, 0, 0.65) !important;
314
 				color: rgba(0, 0, 0, 0.65) !important;
312
 				background: #fff !important;
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
 			this.specimenNameId = item.id
517
 			this.specimenNameId = item.id
518
 			this.specimenNameName = item.name
518
 			this.specimenNameName = item.name
519
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
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
 					return
522
 					return
523
 				}
523
 				}
524
 			}
524
 			}
@@ -542,8 +542,8 @@ export class PathologyAddComponent implements OnInit {
542
 	fastClick(e,item,index){
542
 	fastClick(e,item,index){
543
 		this.fastIndex = index
543
 		this.fastIndex = index
544
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
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
 					return
547
 					return
548
 				}
548
 				}
549
 			}
549
 			}
@@ -586,8 +586,8 @@ export class PathologyAddComponent implements OnInit {
586
 		  this.validateSpecimenForm.controls[i].updateValueAndValidity();
586
 		  this.validateSpecimenForm.controls[i].updateValueAndValidity();
587
 		}
587
 		}
588
 		if (this.validateSpecimenForm.invalid) return;
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
 			return
591
 			return
592
 		}
592
 		}
593
 		if(type==2){
593
 		if(type==2){
@@ -705,7 +705,7 @@ export class PathologyAddComponent implements OnInit {
705
 	// 监听输入字数
705
 	// 监听输入字数
706
 	specimenNameLength:any=0;
706
 	specimenNameLength:any=0;
707
 	specimenInput(e){
707
 	specimenInput(e){
708
-		if(e.length>15){
708
+		if(e.length>20){
709
 			return
709
 			return
710
 		}
710
 		}
711
 		this.specimenNameLength = e.length
711
 		this.specimenNameLength = e.length
@@ -766,9 +766,13 @@ export class PathologyAddComponent implements OnInit {
766
 		this.fixationData = format(result, 'yyyy-MM-dd');
766
 		this.fixationData = format(result, 'yyyy-MM-dd');
767
 		console.log(this.fixationData)
767
 		console.log(this.fixationData)
768
 	}
768
 	}
769
-	fixationTimeSelect:any;
769
+	fixationTimeSelect:any = null;
770
 	fixationTimeChange(result){
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
 		console.log(this.fixationData + ' ' + this.fixationTimeSelect)
776
 		console.log(this.fixationData + ' ' + this.fixationTimeSelect)
773
 	}
777
 	}
774
 	
778
 	
@@ -779,9 +783,13 @@ export class PathologyAddComponent implements OnInit {
779
 		this.inVitroData = format(result, 'yyyy-MM-dd');
783
 		this.inVitroData = format(result, 'yyyy-MM-dd');
780
 		console.log(this.inVitroData)
784
 		console.log(this.inVitroData)
781
 	}
785
 	}
782
-	inVitroTimeSelect:any;
786
+	inVitroTimeSelect:any = null;
783
 	inVitroTimeChange(result){
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
 		console.log(this.inVitroData + ' ' + this.inVitroTimeSelect)
793
 		console.log(this.inVitroData + ' ' + this.inVitroTimeSelect)
786
 	}
794
 	}
787
 	
795
 	
@@ -789,6 +797,14 @@ export class PathologyAddComponent implements OnInit {
789
 	printLoading:boolean = false;
797
 	printLoading:boolean = false;
790
 	submitPrintForm(): void{
798
 	submitPrintForm(): void{
791
 		let that = this
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
 		for (const i in this.validatePrintForm.controls) {
808
 		for (const i in this.validatePrintForm.controls) {
793
 		  this.validatePrintForm.controls[i].markAsDirty();
809
 		  this.validatePrintForm.controls[i].markAsDirty();
794
 		  this.validatePrintForm.controls[i].updateValueAndValidity();
810
 		  this.validatePrintForm.controls[i].updateValueAndValidity();
@@ -828,7 +844,7 @@ export class PathologyAddComponent implements OnInit {
828
 			delete data.operation
844
 			delete data.operation
829
 			delete data.pathologySpecimenIds
845
 			delete data.pathologySpecimenIds
830
 		}
846
 		}
831
-		if(this.ifImmobilization){
847
+		if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
832
 			data.pathologyForm.fixationTime = this.fixationData + ' ' + this.fixationTimeSelect +':00'
848
 			data.pathologyForm.fixationTime = this.fixationData + ' ' + this.fixationTimeSelect +':00'
833
 			data.pathologyForm.specimenFixingLiquid.id = this.validatePrintForm.value.fixative
849
 			data.pathologyForm.specimenFixingLiquid.id = this.validatePrintForm.value.fixative
834
 		}else{
850
 		}else{
@@ -969,7 +985,7 @@ export class PathologyAddComponent implements OnInit {
969
 				let date = new Date();
985
 				let date = new Date();
970
 				
986
 				
971
 				let inVitroDate = format(date, "yyyy-MM-dd")
987
 				let inVitroDate = format(date, "yyyy-MM-dd")
972
-				if(this.ifImmobilization){
988
+				if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
973
 					this.validatePrintForm = this.fb.group({
989
 					this.validatePrintForm = this.fb.group({
974
 						inVitroTimes: [null, [Validators.required]],
990
 						inVitroTimes: [null, [Validators.required]],
975
 						inVitroDate: [null, [Validators.required]],
991
 						inVitroDate: [null, [Validators.required]],
@@ -985,7 +1001,7 @@ export class PathologyAddComponent implements OnInit {
985
 					this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
1001
 					this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
986
 					// this.validatePrintForm.controls.fixationTimes.setValue(date);
1002
 					// this.validatePrintForm.controls.fixationTimes.setValue(date);
987
 					this.fixationData = inVitroDate;
1003
 					this.fixationData = inVitroDate;
988
-					this.fixationTimeSelect = format(date, 'HH:mm');
1004
+					this.fixationTimeSelect = null;
989
 				}else{
1005
 				}else{
990
 					this.validatePrintForm = this.fb.group({
1006
 					this.validatePrintForm = this.fb.group({
991
 						inVitroTimes: [null, [Validators.required]],
1007
 						inVitroTimes: [null, [Validators.required]],
@@ -1030,7 +1046,7 @@ export class PathologyAddComponent implements OnInit {
1030
 					let date = new Date();
1046
 					let date = new Date();
1031
 					
1047
 					
1032
 					let inVitroDate = format(date, "yyyy-MM-dd")
1048
 					let inVitroDate = format(date, "yyyy-MM-dd")
1033
-					if(this.ifImmobilization){
1049
+					if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
1034
 						this.validatePrintForm = this.fb.group({
1050
 						this.validatePrintForm = this.fb.group({
1035
 							inVitroTimes: [null, [Validators.required]],
1051
 							inVitroTimes: [null, [Validators.required]],
1036
 							inVitroDate: [null, [Validators.required]],
1052
 							inVitroDate: [null, [Validators.required]],
@@ -1045,7 +1061,7 @@ export class PathologyAddComponent implements OnInit {
1045
 						this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
1061
 						this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
1046
 						// this.validatePrintForm.controls.fixationTimes.setValue(date);
1062
 						// this.validatePrintForm.controls.fixationTimes.setValue(date);
1047
 						this.fixationData = inVitroDate;
1063
 						this.fixationData = inVitroDate;
1048
-						this.fixationTimeSelect = format(date, 'HH:mm');
1064
+						this.fixationTimeSelect = null;
1049
 					}else{
1065
 					}else{
1050
 						this.validatePrintForm = this.fb.group({
1066
 						this.validatePrintForm = this.fb.group({
1051
 							inVitroTimes: [null, [Validators.required]],
1067
 							inVitroTimes: [null, [Validators.required]],
@@ -1101,7 +1117,7 @@ export class PathologyAddComponent implements OnInit {
1101
 					let date = new Date();
1117
 					let date = new Date();
1102
 					
1118
 					
1103
 					let inVitroDate = format(date, "yyyy-MM-dd")
1119
 					let inVitroDate = format(date, "yyyy-MM-dd")
1104
-					if(this.ifImmobilization){
1120
+					if(this.ifImmobilization && this.detailsData.pathologyFormType==0){
1105
 						this.validatePrintForm = this.fb.group({
1121
 						this.validatePrintForm = this.fb.group({
1106
 							inVitroTimes: [null, [Validators.required]],
1122
 							inVitroTimes: [null, [Validators.required]],
1107
 							inVitroDate: [null, [Validators.required]],
1123
 							inVitroDate: [null, [Validators.required]],
@@ -1116,7 +1132,7 @@ export class PathologyAddComponent implements OnInit {
1116
 						this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
1132
 						this.validatePrintForm.controls.fixationDate.setValue(inVitroDate);
1117
 						// this.validatePrintForm.controls.fixationTimes.setValue(date);
1133
 						// this.validatePrintForm.controls.fixationTimes.setValue(date);
1118
 						this.fixationData = inVitroDate;
1134
 						this.fixationData = inVitroDate;
1119
-						this.fixationTimeSelect = format(date, 'HH:mm');
1135
+						this.fixationTimeSelect = null;
1120
 					}else{
1136
 					}else{
1121
 						this.validatePrintForm = this.fb.group({
1137
 						this.validatePrintForm = this.fb.group({
1122
 							inVitroTimes: [null, [Validators.required]],
1138
 							inVitroTimes: [null, [Validators.required]],

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

@@ -5,7 +5,7 @@
5
 			<div class="content">
5
 			<div class="content">
6
 				<div class="content-item boder-right">
6
 				<div class="content-item boder-right">
7
 					<nz-form-item class="form-title-box">
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
 						<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
9
 						<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
10
 					</nz-form-item>
10
 					</nz-form-item>
11
 					<nz-form-item class="form-title-box">
11
 					<nz-form-item class="form-title-box">
@@ -243,7 +243,7 @@
243
 								<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
243
 								<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
244
 							</div>
244
 							</div>
245
 							<div style="margin-top:10px;">
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
 							</div>
247
 							</div>
248
 						 </div>
248
 						 </div>
249
 						 <div style="width: 30%;">
249
 						 <div style="width: 30%;">
@@ -269,26 +269,29 @@
269
 			<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
269
 			<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
270
 				<div *ngFor="let data of printData.specimenList; let index=index;">
270
 				<div *ngFor="let data of printData.specimenList; let index=index;">
271
 					<div style="width: 100%;display: flex;margin-top: 5px;padding: 0 7px;">
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
 							 <div style="width: 50px;height: 50px;">
274
 							 <div style="width: 50px;height: 50px;">
275
 							 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
275
 							 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
276
 							 </div>
276
 							 </div>
277
-							 <div style="width: 12px;">申请单</div>
277
+							 <!-- <div style="width: 12px;">申请单</div> -->
278
 						 </div>
278
 						 </div>
279
 						 <div>{{printData.applyCode}}</div>
279
 						 <div>{{printData.applyCode}}</div>
280
 					 </div>
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
 						<div style="display: flex;flex-wrap: nowrap;">住院号: {{data.residenceNo}}</div>
283
 						<div style="display: flex;flex-wrap: nowrap;">住院号: {{data.residenceNo}}</div>
284
 						<div style="margin-top:9px;">患者: {{data.patientName}}</div>
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
 					 </div>
286
 					 </div>
287
 					</div>
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
 					</div>
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
 				</div>
295
 				</div>
293
 			</div>
296
 			</div>
294
 		</div>
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
 <div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="multiDialog">
2586
 <div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="multiDialog">
2587
 	<div class="modalBody modalBody-ga">
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
 		</div>
2589
 		</div>
2590
 		<div class="content">
2590
 		<div class="content">
2591
-			<div class="weight" *ngIf="viewData.length>0">
2592
-				提示:查询到{{viewData[0].patientDTO.patientName}}({{viewData[0].patientDTO.patientCode}})患者有多条申请单,请选择对应申请单
2593
-			</div>
2594
 			<div class="list-template__bottom">
2591
 			<div class="list-template__bottom">
2595
 				<nz-table class="list-template__nzTable" [nzData]="viewData" nzSize="middle" [nzShowPagination]="false"
2592
 				<nz-table class="list-template__nzTable" [nzData]="viewData" nzSize="middle" [nzShowPagination]="false"
2596
 					[nzLoading]="grossLoading">
2593
 					[nzLoading]="grossLoading">
@@ -2598,19 +2595,19 @@
2598
 						<tr class="thead">
2595
 						<tr class="thead">
2599
 							<th>申请单类型</th>
2596
 							<th>申请单类型</th>
2600
 							<th>申请单号</th>
2597
 							<th>申请单号</th>
2601
-							<th nzWidth="15%">检验项目</th>
2598
+							<th nzWidth="20%">检验项目</th>
2602
 							<th>标本类型</th>
2599
 							<th>标本类型</th>
2603
 							<th>申请时间</th>
2600
 							<th>申请时间</th>
2604
 							<th>申请科室</th>
2601
 							<th>申请科室</th>
2605
 							<th>状态</th>
2602
 							<th>状态</th>
2606
-							<th>作</th>
2603
+							<th>作</th>
2607
 						</tr>
2604
 						</tr>
2608
 					</thead>
2605
 					</thead>
2609
 					<tbody>
2606
 					<tbody>
2610
 						<tr *ngFor="let data of viewData">
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
 							<td style="text-decoration: underline;cursor: pointer;" (click)="itemClick(data)">{{ data.applyCode}}</td>
2611
 							<td style="text-decoration: underline;cursor: pointer;" (click)="itemClick(data)">{{ data.applyCode}}</td>
2615
 							<td>{{ data.arr ? data.arr.join('、') : '无' }}</td>
2612
 							<td>{{ data.arr ? data.arr.join('、') : '无' }}</td>
2616
 							<td>{{ data.specimenType?data.specimenType.name:'无'}}</td>
2613
 							<td>{{ data.specimenType?data.specimenType.name:'无'}}</td>
@@ -2618,10 +2615,10 @@
2618
 							<td>{{ data.patientDTO.department? data.patientDTO.department.dept:'-'}}</td>
2615
 							<td>{{ data.patientDTO.department? data.patientDTO.department.dept:'-'}}</td>
2619
 							<td>{{ data.status?data.status.name:'-'}}</td>
2616
 							<td>{{ data.status?data.status.name:'-'}}</td>
2620
 							<td>
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
 									|| data.status.value==3 || data.status.value==4 ||
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
 							  </div>
2622
 							  </div>
2626
 							</td>
2623
 							</td>
2627
 						</tr>
2624
 						</tr>
@@ -2631,7 +2628,7 @@
2631
 		</div>
2628
 		</div>
2632
 		<div class="display_flex justify-content_flex-center mar-20 btns">
2629
 		<div class="display_flex justify-content_flex-center mar-20 btns">
2633
 			<button class="btn" style="margin-right: 0;" *ngIf="autoCreate==1" nz-button nzType="primary" (click)="addPathologyType(0)">新增普通病理</button>
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
 			<button class="btn cancel" nz-button nzType="default" (click)="hideModal()">知道了</button>
2632
 			<button class="btn cancel" nz-button nzType="default" (click)="hideModal()">知道了</button>
2636
 		</div>
2633
 		</div>
2637
 	</div>
2634
 	</div>

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

@@ -230,6 +230,15 @@
230
 		.list-template__searchBox{
230
 		.list-template__searchBox{
231
 			margin-top: 10px;
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
 		.ant-select{
242
 		.ant-select{
234
 			width: 20%;
243
 			width: 20%;
235
 		}
244
 		}
@@ -244,7 +253,6 @@
244
     .title {
253
     .title {
245
       width: 100%;
254
       width: 100%;
246
       text-align: center;
255
       text-align: center;
247
-      font-size: 18px;
248
       position: relative;
256
       position: relative;
249
 
257
 
250
       i {
258
       i {
@@ -257,7 +265,27 @@
257
         padding: 0 5px;
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
     .content {
289
     .content {
262
       width: 100%;
290
       width: 100%;
263
       // height: 117px;
291
       // height: 117px;
@@ -325,8 +353,8 @@
325
         width: 100%;
353
         width: 100%;
326
         height: auto;
354
         height: auto;
327
         padding: 19px 14px 0 14px;
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
 				.ant-select{
359
 				.ant-select{
332
 					width: 100%;
360
 					width: 100%;
@@ -369,7 +397,35 @@
369
 				            text-decoration: underline;
397
 				            text-decoration: underline;
370
 				            cursor: pointer;
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
 				          .coop {
429
 				          .coop {
374
 				            button{
430
 				            button{
375
 				              color: #333;
431
 				              color: #333;

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

@@ -400,9 +400,9 @@ export class HushijiandanComponent implements OnInit {
400
 			idx: 0,
400
 			idx: 0,
401
 			sum: 9999,
401
 			sum: 9999,
402
 			pathologyForm: {
402
 			pathologyForm: {
403
-				// surgeryId: item.id || "",
403
+				surgeryId: item.id || "",
404
 				patientId: item.patientDTO.id || "",
404
 				patientId: item.patientDTO.id || "",
405
-				hosId: this.currentHospital.id || "" ,
405
+				// hosId: this.currentHospital.id || "" ,
406
 				operationType: 'pathologyForm',
406
 				operationType: 'pathologyForm',
407
 				order:'createTime desc',
407
 				order:'createTime desc',
408
 			},
408
 			},
@@ -413,39 +413,15 @@ export class HushijiandanComponent implements OnInit {
413
 			.subscribe((data) => {
413
 			.subscribe((data) => {
414
 				this.isSpinning = false
414
 				this.isSpinning = false
415
 				this.viewData = data.list
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
 						i.arr = []
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
 			idx: 0,
437
 			idx: 0,
462
 			sum: 9999,
438
 			sum: 9999,
463
 			pathologyForm: {
439
 			pathologyForm: {
464
-				// surgeryId: this.surgeryWKOMsg.id || "",
440
+				surgeryId: this.surgeryWKOMsg.id || "",
465
 				patientId: this.surgeryWKOMsg.patientDTO.id || "",
441
 				patientId: this.surgeryWKOMsg.patientDTO.id || "",
466
-				hosId: this.currentHospital.id || "" ,
442
+				// hosId: this.currentHospital.id || "" ,
467
 				operationType: 'pathologyForm',
443
 				operationType: 'pathologyForm',
468
 				order:'createTime desc'
444
 				order:'createTime desc'
469
 			},
445
 			},
@@ -483,34 +459,6 @@ export class HushijiandanComponent implements OnInit {
483
 				}
459
 				}
484
 			}
460
 			}
485
 			this.multiDialog = true
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
 			  path: "deptAllStatistics",
613
 			  path: "deptAllStatistics",
614
 			  loadChildren: () => import("../dept-all-statistics/dept-all-statistics.module").then((m) => m.DeptAllStatisticsModule),
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
 	<div class="tabs">
50
 	<div class="tabs">
51
 		<div class="tabs-item">
51
 		<div class="tabs-item">
52
 			<div class="tabs-item-item" [ngClass]="{'activeClass': activeIndex == 0}" (click)="tabClick(0)">交接本</div>
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
 		</div>
54
 		</div>
54
 		<div class="tabs-btn">
55
 		<div class="tabs-btn">
55
 			<button class="btn default" nz-button nzType="primary" nzSize="small" (click)='distributionTab()'>配送清点</button>
56
 			<button class="btn default" nz-button nzType="primary" nzSize="small" (click)='distributionTab()'>配送清点</button>
@@ -57,7 +58,7 @@
57
 	</div>
58
 	</div>
58
   <!-- 头部 end -->
59
   <!-- 头部 end -->
59
   <div class="pharmacy-main">
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
 			<div class="list-template__content">
62
 			<div class="list-template__content">
62
 			  <div class="list-template__top" nz-row>
63
 			  <div class="list-template__top" nz-row>
63
 			    <div nz-col nzLg='18' class="list-template__searchBox">
64
 			    <div nz-col nzLg='18' class="list-template__searchBox">
@@ -100,9 +101,10 @@
100
 			    <div nz-col nzLg="6" class="list-template__btns">
101
 			    <div nz-col nzLg="6" class="list-template__btns">
101
 			      <button class="btn default" (click)='search()'>搜索</button>
102
 			      <button class="btn default" (click)='search()'>搜索</button>
102
 			      <button class="btn default ml8" (click)='reset()'>重置</button>
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
 			    </div>
105
 			    </div>
104
 			  </div>
106
 			  </div>
105
-			  <div class="list-template__bottom">
107
+			  <div class="list-template__bottom" *ngIf="activeIndex==0">
106
 			    <nz-table class="list-template__nzTable" [nzData]="listOneData" nzSize="middle" [nzShowPagination]="false"
108
 			    <nz-table class="list-template__nzTable" [nzData]="listOneData" nzSize="middle" [nzShowPagination]="false"
107
 			      [nzLoading]="loading1">
109
 			      [nzLoading]="loading1">
108
 			      <thead>
110
 			      <thead>
@@ -118,7 +120,7 @@
118
 								<th>固定时间</th>
120
 								<th>固定时间</th>
119
 			          <th>配送人</th>
121
 			          <th>配送人</th>
120
 								<th>配送时间</th>
122
 								<th>配送时间</th>
121
-			          <th nzWidth="80px">操作</th>
123
+			          <th nzWidth="120px">操作</th>
122
 			        </tr>
124
 			        </tr>
123
 			      </thead>
125
 			      </thead>
124
 			      <tbody>
126
 			      <tbody>
@@ -137,6 +139,7 @@
137
 			          <td>
139
 			          <td>
138
 			            <div class="coop">
140
 			            <div class="coop">
139
 										<span (click)="oneLook($event,data)">查看</span>
141
 										<span (click)="oneLook($event,data)">查看</span>
142
+										<span *ngIf="coopBtns.print && data.printFlag==1" (click)="print('print',data)">补打</span>
140
 			            </div>
143
 			            </div>
141
 			          </td>
144
 			          </td>
142
 			        </tr>
145
 			        </tr>
@@ -148,114 +151,69 @@
148
 			      </nz-pagination>
151
 			      </nz-pagination>
149
 			    </div>
152
 			    </div>
150
 			  </div>
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
 				  </div>
212
 				  </div>
253
 				</div>
213
 				</div>
254
 			</div>
214
 			</div>
255
     </div>
215
     </div>
256
   </div>
216
   </div>
257
-  <!-- 主体部分 end -->
258
-  <!-- <router-outlet></router-outlet> -->
259
 </div>
217
 </div>
260
 
218
 
261
 <!-- 科室切换提示框 -->
219
 <!-- 科室切换提示框 -->
@@ -453,4 +411,77 @@
453
 			</div>
411
 			</div>
454
 		</div>
412
 		</div>
455
 	</div>
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
 </div>
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
 	toDayTime:any = null;
169
 	toDayTime:any = null;
170
 	backType:any = 'list';
170
 	backType:any = 'list';
171
 	mainRole:any = false;
171
 	mainRole:any = false;
172
+	coopBtns:any = {};
172
 	loginUserDeptId: number = JSON.parse(localStorage.getItem("user")).user.dept
173
 	loginUserDeptId: number = JSON.parse(localStorage.getItem("user")).user.dept
173
 	  .id; //登录人所属科室
174
 	  .id; //登录人所属科室
174
   ngOnDestroy() {
175
   ngOnDestroy() {
@@ -189,9 +190,11 @@ export class PathologyCommunicationBookComponent implements OnInit, OnDestroy {
189
 		// 	this.isLoading = true
190
 		// 	this.isLoading = true
190
 		//   this.getUserData(v[0])
191
 		//   this.getUserData(v[0])
191
 		// });
192
 		// });
193
+		this.coopBtns = this.tool.initCoopBtns(this.route);
192
 		this.hosId = this.tool.getCurrentHospital().id;
194
 		this.hosId = this.tool.getCurrentHospital().id;
193
 		this.userId = this.tool.getCurrentUserId()
195
 		this.userId = this.tool.getCurrentUserId()
194
 		this.deptId = this.tool.getCurrentUserDept().id
196
 		this.deptId = this.tool.getCurrentUserDept().id
197
+		this.getTaskTypesId()
195
 		this.getConnectList()
198
 		this.getConnectList()
196
 		if(this.route.snapshot.queryParams && this.route.snapshot.queryParams.type){
199
 		if(this.route.snapshot.queryParams && this.route.snapshot.queryParams.type){
197
 			this.backType = this.route.snapshot.queryParams.type
200
 			this.backType = this.route.snapshot.queryParams.type
@@ -207,13 +210,122 @@ export class PathologyCommunicationBookComponent implements OnInit, OnDestroy {
207
 			this.getToday()
210
 			this.getToday()
208
 		},60000)
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
 	//tab切换
320
 	//tab切换
212
 	tabClick(type){
321
 	tabClick(type){
213
 		this.activeIndex = type
322
 		this.activeIndex = type
214
 		localStorage.setItem("pathologyActiveIndex",type)
323
 		localStorage.setItem("pathologyActiveIndex",type)
324
+		this.pageOneIndex = 1;
215
 		if(type==0){
325
 		if(type==0){
216
 			this.getConnectList()
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
 				status:{
398
 				status:{
287
 					id:this.status
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
 	  this.loading1 = true;
413
 	  this.loading1 = true;
293
 	  that.mainService
414
 	  that.mainService
294
 	    .getFetchDataList("data", "pathologyForm", data)
415
 	    .getFetchDataList("data", "pathologyForm", data)

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

@@ -35,31 +35,30 @@
35
   </div>
35
   </div>
36
   <div class="pharmacy-main">
36
   <div class="pharmacy-main">
37
 		<div class="left" *ngIf="adviceList">
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
 			</div>
41
 			</div>
42
 			<div class="left-content" [ngClass]="{'noAddAppClass': !ifAddapplication, 'beAddAppClass': ifAddapplication}">
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
 					<div class="list list-df">
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
 						<div class="del-class">
47
 						<div class="del-class">
48
 							<i (click)="delItem($event,item)" class="icon_transport transport-lajitong specimen-icon"></i>
48
 							<i (click)="delItem($event,item)" class="icon_transport transport-lajitong specimen-icon"></i>
49
 						</div>
49
 						</div>
50
 					</div>
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
 				</div>
55
 				</div>
57
 			</div>
56
 			</div>
58
 			<div *ngIf="ifAddapplication && adviceList" class="center-box">
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
 			</div>
59
 			</div>
61
 		</div>
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
 			<div class="pathology-content" *ngIf="viewType=='edit'">
62
 			<div class="pathology-content" *ngIf="viewType=='edit'">
64
 				<div class="title">病理检查申请单</div>
63
 				<div class="title">病理检查申请单</div>
65
 				<div class="content">
64
 				<div class="content">
@@ -70,17 +69,11 @@
70
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
69
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
71
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
70
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
72
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
71
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
72
+								<div class="form-title" *ngIf="detailsData.pathologyFormType==2">申请单类型:病理细胞学申请单</div>
73
 								<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
73
 								<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
74
 							</nz-form-item>
74
 							</nz-form-item>
75
 							
75
 							
76
 							<nz-form-item>
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
 								<div class="form-title width-100 font-weight-500">病历摘要:</div>
77
 								<div class="form-title width-100 font-weight-500">病历摘要:</div>
85
 								<div class="indent" [ngClass]="{'height-200': isShowMove, 'height-100': !isShowMove && detailsData.medicalRecords}">{{detailsData.medicalRecords||'无'}}</div>
78
 								<div class="indent" [ngClass]="{'height-200': isShowMove, 'height-100': !isShowMove && detailsData.medicalRecords}">{{detailsData.medicalRecords||'无'}}</div>
86
 								<div (click)="showLook()" class="cursor" *ngIf="medicalRecordsLength>10">
79
 								<div (click)="showLook()" class="cursor" *ngIf="medicalRecordsLength>10">
@@ -89,10 +82,17 @@
89
 								</div>
82
 								</div>
90
 							</nz-form-item>
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
 							<nz-form-item class="form-item">
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
 								</nz-form-control>
96
 								</nz-form-control>
97
 							</nz-form-item>
97
 							</nz-form-item>
98
 							
98
 							
@@ -188,16 +188,10 @@
188
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
188
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==null">申请单类型:无</div>
189
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
189
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==1">申请单类型:术中快速病理检查申请单</div>
190
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
190
 								<div class="form-title" *ngIf="detailsData.pathologyFormType==0">申请单类型:病理检查申请单</div>
191
+								<div class="form-title" *ngIf="detailsData.pathologyFormType==2">申请单类型:病理细胞学申请单</div>
191
 								<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
192
 								<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
192
 							</div>
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
 							<div class="form-list">
195
 							<div class="form-list">
202
 								<div class="form-title width-100 font-weight-500">病历摘要:</div>
196
 								<div class="form-title width-100 font-weight-500">病历摘要:</div>
203
 								<div class="indent" [ngClass]="{'height-200': isShowMove, 'height-100': !isShowMove && detailsData.medicalRecords}">{{detailsData.medicalRecords||'无'}}</div>
197
 								<div class="indent" [ngClass]="{'height-200': isShowMove, 'height-100': !isShowMove && detailsData.medicalRecords}">{{detailsData.medicalRecords||'无'}}</div>
@@ -207,8 +201,15 @@
207
 								</div>
201
 								</div>
208
 							</div>
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
 								<div class="form-list">
211
 								<div class="form-list">
211
-									<div class="form-title font-weight-500">手术方案:</div>
212
+									<div class="form-title font-weight-500">手术诊断:</div>
212
 									<div class="indent">{{detailsData.surgicalPlan||'无'}}</div>
213
 									<div class="indent">{{detailsData.surgicalPlan||'无'}}</div>
213
 								</div>
214
 								</div>
214
 								<div class="form-list">
215
 								<div class="form-list">
@@ -243,7 +244,7 @@
243
 				</div>
244
 				</div>
244
 			</div>
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
 			<div class="step-title">病理闭环</div>
248
 			<div class="step-title">病理闭环</div>
248
 			<nz-steps [nzCurrent]="stepLength" nzDirection="vertical" nzSize="small">
249
 			<nz-steps [nzCurrent]="stepLength" nzDirection="vertical" nzSize="small">
249
 				<ng-container *ngFor="let item of pathologyLogs; let index = index">
250
 				<ng-container *ngFor="let item of pathologyLogs; let index = index">
@@ -380,7 +381,7 @@
380
 					</div>
381
 					</div>
381
 				</nz-form-item>
382
 				</nz-form-item>
382
 				
383
 				
383
-				<nz-form-item class="form-item">
384
+<!-- 				<nz-form-item class="form-item">
384
 					<nz-form-label [nzSm]="4" [nzXs]="24">快捷键入</nz-form-label>
385
 					<nz-form-label [nzSm]="4" [nzXs]="24">快捷键入</nz-form-label>
385
 					<div class="specimen-list">
386
 					<div class="specimen-list">
386
 						<div *ngFor="let item of fastList;let index=index;" class="select-item"
387
 						<div *ngFor="let item of fastList;let index=index;" class="select-item"
@@ -388,16 +389,16 @@
388
 							{{item.name}}
389
 							{{item.name}}
389
 						</div>
390
 						</div>
390
 					</div>
391
 					</div>
391
-				</nz-form-item>
392
+				</nz-form-item> -->
392
 				
393
 				
393
 				<nz-form-item class="form-item">
394
 				<nz-form-item class="form-item">
394
 					<nz-form-label nzRequired nzFor="specimenName" [nzSm]="3" [nzXs]="24">标本名称</nz-form-label>
395
 					<nz-form-label nzRequired nzFor="specimenName" [nzSm]="3" [nzXs]="24">标本名称</nz-form-label>
395
 					<div class="specimen-tip" [ngClass]="{'isSpecumen':placeName}">{{placeName?placeName:''}}</div>
396
 					<div class="specimen-tip" [ngClass]="{'isSpecumen':placeName}">{{placeName?placeName:''}}</div>
396
 					<nz-form-control nzErrorTip="请输入标本名称" [(nzSm)]="nzSmNum" [nzXs]="24">
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
 					</nz-form-control>
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
 						<span class="empty" (click)="emptData($event)">清空</span>
402
 						<span class="empty" (click)="emptData($event)">清空</span>
402
 					</div>
403
 					</div>
403
 				</nz-form-item>
404
 				</nz-form-item>
@@ -429,9 +430,9 @@
429
 <app-dialog-delete [delModal]="delModal" (hideDelModalEvent)="hideDelModal()" [btnLoading]="btnLoading"
430
 <app-dialog-delete [delModal]="delModal" (hideDelModalEvent)="hideDelModal()" [btnLoading]="btnLoading"
430
 	(confirmDelEvent)="confirmDel()" content="您确认要删除标本吗?"></app-dialog-delete>
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
 <div class="look">
438
 <div class="look">
@@ -575,7 +576,7 @@
575
 							<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
576
 							<div>日期: {{data.inVitroTime|date:'yyyy-MM-dd'}}</div>
576
 						</div>
577
 						</div>
577
 						<div style="margin-top:10px;">
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
 						</div>
580
 						</div>
580
 					 </div>
581
 					 </div>
581
 					 <div style="width: 30%;">
582
 					 <div style="width: 30%;">
@@ -601,26 +602,29 @@
601
 		<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
602
 		<div style="font-size: 12px;" *ngIf="outpatientPathologyLabelSizeType==2 && printData && printData.specimenList && printData.specimenList.length>0">
602
 			<div *ngFor="let data of printData.specimenList; let index=index;">
603
 			<div *ngFor="let data of printData.specimenList; let index=index;">
603
 				<div style="width: 100%;display: flex;margin-top: 5px;padding: 0 7px;">
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
 						 <div style="width: 50px;height: 50px;">
607
 						 <div style="width: 50px;height: 50px;">
607
 						 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
608
 						 		<img style="max-width: 100%;max-height: 100%;position: relative;left: -2px;" [src]="data.barCode" alt="">
608
 						 </div>
609
 						 </div>
609
-						 <div style="width: 12px;">申请单</div>
610
+						 <!-- <div style="width: 12px;">申请单</div> -->
610
 					 </div>
611
 					 </div>
611
 					 <div>{{printData.applyCode}}</div>
612
 					 <div>{{printData.applyCode}}</div>
612
 				 </div>
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
 					<div style="margin-top:9px;">患者: {{data.patientName}}</div>
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
 				 </div>
619
 				 </div>
619
 				</div>
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
 				</div>
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
 			</div>
628
 			</div>
625
 		</div>
629
 		</div>
626
 	</div>
630
 	</div>

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

@@ -915,11 +915,11 @@
915
 						}
915
 						}
916
 					}
916
 					}
917
 					.beSpecumenEmpty{
917
 					.beSpecumenEmpty{
918
-						right: 6px;
918
+						right: 10px;
919
 						top: 8px;
919
 						top: 8px;
920
 					}
920
 					}
921
 					.noSpecumenEmpty{
921
 					.noSpecumenEmpty{
922
-						right: 6px;
922
+						right: 10px;
923
 						top: 8px;
923
 						top: 8px;
924
 					}
924
 					}
925
 				}
925
 				}
@@ -953,6 +953,11 @@
953
 	  }
953
 	  }
954
 		.no-width{
954
 		.no-width{
955
 			width: 33% !important;
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
 	project:any;
83
 	project:any;
84
 	viewType:any = 'no';
84
 	viewType:any = 'no';
85
 	mainRole:any;
85
 	mainRole:any;
86
+	deptId:any = null;
87
+	btnDelLoading:any = false;
86
   ngOnInit() {
88
   ngOnInit() {
87
 		this.changeInpSubject.pipe(debounceTime(500)).subscribe((v) => {
89
 		this.changeInpSubject.pipe(debounceTime(500)).subscribe((v) => {
88
 		  this.searchSpecimenData(v[0])
90
 		  this.searchSpecimenData(v[0])
89
 		});
91
 		});
90
 		this.changeInpSubjectSpecimen.pipe(debounceTime(500)).subscribe((v) => {
92
 		this.changeInpSubjectSpecimen.pipe(debounceTime(500)).subscribe((v) => {
91
-		  this.searchSpecimen(v[0],'search')
93
+		  this.searchSpecimen(v[0],'search','new')
92
 		});
94
 		});
93
 		this.hosId = this.tool.getCurrentHospital().id;
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
 		this.getProDicData()
98
 		this.getProDicData()
96
 		this.getDicData()
99
 		this.getDicData()
97
 		this.getSourceData()
100
 		this.getSourceData()
@@ -108,7 +111,7 @@ export class PathologySampleComponent implements OnInit {
108
 		});
111
 		});
109
 		if(this.route.snapshot.params && this.route.snapshot.params.param){
112
 		if(this.route.snapshot.params && this.route.snapshot.params.param){
110
 			this.barCode = this.route.snapshot.params.param
113
 			this.barCode = this.route.snapshot.params.param
111
-			this.searchSpecimen(this.barCode,'search')
114
+			this.searchSpecimen(this.barCode,'search','new')
112
 		}
115
 		}
113
 		setTimeout(_=>{
116
 		setTimeout(_=>{
114
 			document.getElementById('Binput').focus();
117
 			document.getElementById('Binput').focus();
@@ -228,8 +231,7 @@ export class PathologySampleComponent implements OnInit {
228
 			if(this.leftIndex == null){
231
 			if(this.leftIndex == null){
229
 				this.leftIndex = 0
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
 	itemData:any;
284
 	itemData:any;
283
 	delAdviceModal:any = false;
285
 	delAdviceModal:any = false;
284
 	itemDataType:any = 2;
286
 	itemDataType:any = 2;
@@ -291,18 +293,17 @@ export class PathologySampleComponent implements OnInit {
291
 	
293
 	
292
 	// 确定删除
294
 	// 确定删除
293
 	confirmAdvice(){
295
 	confirmAdvice(){
294
-		this.btnLoading = true;
296
+		this.btnDelLoading = true;
295
 		this.mainService
297
 		this.mainService
296
 		  .coopTypeConfig(
298
 		  .coopTypeConfig(
297
 		    "rmvData",
299
 		    "rmvData",
298
-		    "pathologyAdvice",
300
+		    "pathologyForm",
299
 		     [this.itemData.id]
301
 		     [this.itemData.id]
300
 		  )
302
 		  )
301
 		  .subscribe((data) => {
303
 		  .subscribe((data) => {
302
-		    this.btnLoading = false;
304
+		    this.btnDelLoading = false;
303
 		    this.delAdviceModal = false;
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
 		    if (data.status==200) {
307
 		    if (data.status==200) {
307
 		      this.showSpecimenModal("删除", true, "");
308
 		      this.showSpecimenModal("删除", true, "");
308
 		    } else {
309
 		    } else {
@@ -321,8 +322,8 @@ export class PathologySampleComponent implements OnInit {
321
 	listClick(item,index){
322
 	listClick(item,index){
322
 		this.leftIndex = index
323
 		this.leftIndex = index
323
 		this.adviceItem = item
324
 		this.adviceItem = item
324
-		if(item.pathologyFormId){
325
-			this.fetchDataList(item.pathologyFormId);
325
+		if(item.id){
326
+			this.fetchDataList(item.id);
326
 		}else{
327
 		}else{
327
 			this.viewType = 'add'
328
 			this.viewType = 'add'
328
 		}
329
 		}
@@ -335,7 +336,8 @@ export class PathologySampleComponent implements OnInit {
335
 	
336
 	
336
 	// 标本条码搜索
337
 	// 标本条码搜索
337
 	adviceList:any = null;
338
 	adviceList:any = null;
338
-	searchSpecimen(e,type){
339
+	residenceNo:any = null;
340
+	searchSpecimen(e,type,optType){
339
 		if(type!='add' && type!='load'){
341
 		if(type!='add' && type!='load'){
340
 			if(!this.barCode){
342
 			if(!this.barCode){
341
 				return
343
 				return
@@ -346,13 +348,16 @@ export class PathologySampleComponent implements OnInit {
346
 		}
348
 		}
347
 		let data:any = {
349
 		let data:any = {
348
 			idx: 0,
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
 		this.isSpinning = true
359
 		this.isSpinning = true
355
-		this.mainService.getFetchDataList("data", "pathologyAdvice", data)
360
+		this.mainService.getFetchDataList("data", "pathologyForm", data)
356
 		.subscribe((res:any) => {
361
 		.subscribe((res:any) => {
357
 			this.isSpinning = false
362
 			this.isSpinning = false
358
 			if(res.status==200){
363
 			if(res.status==200){
@@ -369,8 +374,22 @@ export class PathologySampleComponent implements OnInit {
369
 					this.viewType = 'no';
374
 					this.viewType = 'no';
370
 				}
375
 				}
371
 				if(res.list.length>0){
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
 					this.adviceList = res.list[0]
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
 				}else{
393
 				}else{
375
 					this.adviceList = null
394
 					this.adviceList = null
376
 					this.viewType = 'no';
395
 					this.viewType = 'no';
@@ -431,22 +450,29 @@ export class PathologySampleComponent implements OnInit {
431
 		this.inVitroData = format(result, 'yyyy-MM-dd');
450
 		this.inVitroData = format(result, 'yyyy-MM-dd');
432
 		console.log(this.inVitroData)
451
 		console.log(this.inVitroData)
433
 	}
452
 	}
434
-	inVitroTimeSelect:any;
453
+	inVitroTimeSelect:any = null;
435
 	inVitroTimeChange(result){
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
 		console.log(this.inVitroData + ' ' + this.inVitroTimeSelect)
460
 		console.log(this.inVitroData + ' ' + this.inVitroTimeSelect)
438
 	}
461
 	}
439
-
440
 	
462
 	
441
 	// 提交固定标本接收
463
 	// 提交固定标本接收
442
 	startDate:any;
464
 	startDate:any;
443
 	printLoading:any = false;
465
 	printLoading:any = false;
444
 	submitVerificationForm(){
466
 	submitVerificationForm(){
445
 		let that = this
467
 		let that = this
446
-		if(!this.fixationTimeSelect && this.fixationTimeSelect == null){
468
+		if(!this.fixationTimeSelect || this.fixationTimeSelect == null){
447
 			this.message.error('请选择固定时间')
469
 			this.message.error('请选择固定时间')
448
 			return
470
 			return
449
 		}
471
 		}
472
+		if(!this.inVitroTimeSelect || this.inVitroTimeSelect == null){
473
+			this.message.error('请选择离体时间')
474
+			return
475
+		}
450
 		for (const i in this.validatePrintForm.controls) {
476
 		for (const i in this.validatePrintForm.controls) {
451
 		  this.validatePrintForm.controls[i].markAsDirty();
477
 		  this.validatePrintForm.controls[i].markAsDirty();
452
 		  this.validatePrintForm.controls[i].updateValueAndValidity();
478
 		  this.validatePrintForm.controls[i].updateValueAndValidity();
@@ -508,7 +534,7 @@ export class PathologySampleComponent implements OnInit {
508
 					}
534
 					}
509
 					that.printLoading = false;
535
 					that.printLoading = false;
510
 					that.printData = arr;
536
 					that.printData = arr;
511
-					this.searchSpecimen(this.adviceList.patientNo,'load');
537
+					this.searchSpecimen(this.residenceNo,'load', 'new');
512
 					setTimeout(() => {
538
 					setTimeout(() => {
513
 					  const printContent = document.getElementById("report");
539
 					  const printContent = document.getElementById("report");
514
 					  const WindowPrt = window.open("", "", "width=100,height=1000");
540
 					  const WindowPrt = window.open("", "", "width=100,height=1000");
@@ -850,8 +876,8 @@ export class PathologySampleComponent implements OnInit {
850
 			this.specimenNameId = item.id
876
 			this.specimenNameId = item.id
851
 			this.specimenNameName = item.name
877
 			this.specimenNameName = item.name
852
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
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
 					return
881
 					return
856
 				}
882
 				}
857
 			}
883
 			}
@@ -875,8 +901,8 @@ export class PathologySampleComponent implements OnInit {
875
 	fastClick(e,item,index){
901
 	fastClick(e,item,index){
876
 		this.fastIndex = index
902
 		this.fastIndex = index
877
 			if(this.validateSpecimenForm.value.specimenName && this.validateSpecimenForm.value.specimenName.length){
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
 					return
906
 					return
881
 				}
907
 				}
882
 			}
908
 			}
@@ -919,8 +945,8 @@ export class PathologySampleComponent implements OnInit {
919
 		  this.validateSpecimenForm.controls[i].updateValueAndValidity();
945
 		  this.validateSpecimenForm.controls[i].updateValueAndValidity();
920
 		}
946
 		}
921
 		if (this.validateSpecimenForm.invalid) return;
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
 			return
950
 			return
925
 		}
951
 		}
926
 		if(type==2){
952
 		if(type==2){
@@ -1038,7 +1064,7 @@ export class PathologySampleComponent implements OnInit {
1038
 	// 监听输入字数
1064
 	// 监听输入字数
1039
 	specimenNameLength:any=0;
1065
 	specimenNameLength:any=0;
1040
 	specimenInput(e){
1066
 	specimenInput(e){
1041
-		if(e.length>15){
1067
+		if(e.length>20){
1042
 			return
1068
 			return
1043
 		}
1069
 		}
1044
 		this.specimenNameLength = e.length
1070
 		this.specimenNameLength = e.length
@@ -1078,6 +1104,7 @@ export class PathologySampleComponent implements OnInit {
1078
 	
1104
 	
1079
 	// 关闭标本
1105
 	// 关闭标本
1080
 	closeSpecimenModel(){
1106
 	closeSpecimenModel(){
1107
+		this.itemDataType = 2
1081
 		this.hideSpecimenModal()
1108
 		this.hideSpecimenModal()
1082
 	}
1109
 	}
1083
 	
1110
 	
@@ -1342,7 +1369,7 @@ export class PathologySampleComponent implements OnInit {
1342
 					}
1369
 					}
1343
 					this.btnLoading = false;
1370
 					this.btnLoading = false;
1344
 					this.printData = arr;
1371
 					this.printData = arr;
1345
-					this.searchSpecimen(this.adviceList.patientNo,'load');
1372
+					this.searchSpecimen(this.residenceNo,'load', 'new');
1346
 					setTimeout(() => {
1373
 					setTimeout(() => {
1347
 						const printContent = document.getElementById("report");
1374
 						const printContent = document.getElementById("report");
1348
 						const WindowPrt = window.open("", "", "width=100,height=1000");
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
 			</div>
28
 			</div>
29
 			<button class="right-btn" nz-button nzType="primary" (click)="specimenCheck()">标本核对</button>
29
 			<button class="right-btn" nz-button nzType="primary" (click)="specimenCheck()">标本核对</button>
30
     </div>
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
       <div class="wel">欢迎您:</div>
47
       <div class="wel">欢迎您:</div>
33
       <div class="user">
48
       <div class="user">
34
         <img src="../../assets/images/icon_keshi.png" alt="" />
49
         <img src="../../assets/images/icon_keshi.png" alt="" />
@@ -40,7 +55,7 @@
40
         <div class="logOut" (click)="setSpecimen()">切换科室</div>
55
         <div class="logOut" (click)="setSpecimen()">切换科室</div>
41
         <div class="logOut" (click)="logOut()">退出</div>
56
         <div class="logOut" (click)="logOut()">退出</div>
42
       </div>
57
       </div>
43
-    </div>
58
+    </div> -->
44
   </div>
59
   </div>
45
   <!-- 头部 end -->
60
   <!-- 头部 end -->
46
   <!-- 主体部分 start -->
61
   <!-- 主体部分 start -->
@@ -50,7 +65,7 @@
50
       <!-- 标题 start -->
65
       <!-- 标题 start -->
51
       <div class="pharmacy-main__title">
66
       <div class="pharmacy-main__title">
52
         <strong>手术间标本</strong>
67
         <strong>手术间标本</strong>
53
-				<span *ngIf="printPharmacyList.length>0">共 {{printPharmacyList.length}} 条</span>
68
+				<span *ngIf="otherData1">{{otherData1.pathologyFormNum}}申请单 {{otherData1.specimenNum}}标本</span>
54
         <span class="autoUpdate">{{ logTime }}秒</span>
69
         <span class="autoUpdate">{{ logTime }}秒</span>
55
       </div>
70
       </div>
56
       <!-- 标题 end -->
71
       <!-- 标题 end -->
@@ -82,6 +97,7 @@
82
                 <span title="住院号" class="weight">
97
                 <span title="住院号" class="weight">
83
 									<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
98
 									<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
84
 									<span *ngIf="item.pathologyFormType==0">普</span>
99
 									<span *ngIf="item.pathologyFormType==0">普</span>
100
+									<span *ngIf="item.pathologyFormType==2">细</span>
85
 									{{item.applyCode || '无'}}
101
 									{{item.applyCode || '无'}}
86
 								</span>
102
 								</span>
87
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
103
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
@@ -141,7 +157,7 @@
141
       <!-- 标题 start -->
157
       <!-- 标题 start -->
142
       <div class="pharmacy-main__title">
158
       <div class="pharmacy-main__title">
143
         <strong>标本间标本</strong>
159
         <strong>标本间标本</strong>
144
-				<span *ngIf="waitPharmacyList.length>0">共 {{waitPharmacyList.length}} 条</span>
160
+				<span *ngIf="otherData2">{{otherData2.pathologyFormNum}}申请单 {{otherData2.specimenNum}}标本</span>
145
         <span class="autoUpdate">{{ logTime }}秒</span>
161
         <span class="autoUpdate">{{ logTime }}秒</span>
146
       </div>
162
       </div>
147
       <!-- 标题 end -->
163
       <!-- 标题 end -->
@@ -173,6 +189,7 @@
173
                 <span title="住院号" class="weight">
189
                 <span title="住院号" class="weight">
174
 									<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
190
 									<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
175
 									<span *ngIf="item.pathologyFormType==0">普</span>
191
 									<span *ngIf="item.pathologyFormType==0">普</span>
192
+									<span *ngIf="item.pathologyFormType==2">细</span>
176
 									{{item.applyCode || '无'}}
193
 									{{item.applyCode || '无'}}
177
             		</span>
194
             		</span>
178
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
195
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
@@ -232,7 +249,7 @@
232
       <!-- 标题 start -->
249
       <!-- 标题 start -->
233
       <div class="pharmacy-main__title">
250
       <div class="pharmacy-main__title">
234
         <strong>今日离科标本</strong>
251
         <strong>今日离科标本</strong>
235
-				<span *ngIf="pharmacyList.length>0">共 {{pharmacyList.length}} 条</span>
252
+				<span *ngIf="otherData3">{{otherData3.pathologyFormNum}}申请单 {{otherData3.specimenNum}}标本</span>
236
         <span class="autoUpdate">{{ logTime }}秒</span>
253
         <span class="autoUpdate">{{ logTime }}秒</span>
237
       </div>
254
       </div>
238
       <!-- 标题 end -->
255
       <!-- 标题 end -->
@@ -264,6 +281,7 @@
264
                 <span title="住院号" class="weight">
281
                 <span title="住院号" class="weight">
265
             			<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
282
             			<span class="sign-red" *ngIf="item.pathologyFormType==1">速</span>
266
             			<span *ngIf="item.pathologyFormType==0">普</span>
283
             			<span *ngIf="item.pathologyFormType==0">普</span>
284
+									<span *ngIf="item.pathologyFormType==2">细</span>
267
 									{{item.applyCode || '无'}}
285
 									{{item.applyCode || '无'}}
268
             		</span>
286
             		</span>
269
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
287
                 <span title="姓名" class="weight text-right">{{item.patientDTO.patientName || '无'}}</span>
@@ -463,6 +481,9 @@
463
 		</overlay-scrollbars>
481
 		</overlay-scrollbars>
464
 		<div class="display_flex justify-content_flex-center">
482
 		<div class="display_flex justify-content_flex-center">
465
 			<button class="btn" nz-button nzType="primary" (click)="submitForm()" [nzLoading]="btnLoading">确定</button>
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
 		</div>
487
 		</div>
467
 	</div>
488
 	</div>
468
 </div>
489
 </div>
@@ -607,7 +628,7 @@
607
 						<input nz-input disabled formControlName="name" placeholder="请输入医生姓名" nzSize="default" />
628
 						<input nz-input disabled formControlName="name" placeholder="请输入医生姓名" nzSize="default" />
608
 					</nz-form-control>
629
 					</nz-form-control>
609
 				</nz-form-item>
630
 				</nz-form-item>
610
-				<nz-form-item>
631
+<!-- 				<nz-form-item>
611
 				  <nz-form-label nzRequired [nzSpan]="6" nzFor="nurseJobNumber">护士工号</nz-form-label>
632
 				  <nz-form-label nzRequired [nzSpan]="6" nzFor="nurseJobNumber">护士工号</nz-form-label>
612
 					<nz-form-control [nzSpan]="18" nzErrorTip="请输入护士工号!">
633
 					<nz-form-control [nzSpan]="18" nzErrorTip="请输入护士工号!">
613
 						<input nz-input (ngModelChange)="numberChange($event,2)" formControlName="nurseJobNumber" placeholder="请输入护士工号" nzSize="default" />
634
 						<input nz-input (ngModelChange)="numberChange($event,2)" formControlName="nurseJobNumber" placeholder="请输入护士工号" nzSize="default" />
@@ -618,10 +639,10 @@
618
 					<nz-form-control [nzSpan]="18" nzErrorTip="请输入护士姓名!">
639
 					<nz-form-control [nzSpan]="18" nzErrorTip="请输入护士姓名!">
619
 						<input nz-input disabled formControlName="nurseName" placeholder="请输入护士姓名" nzSize="default" />
640
 						<input nz-input disabled formControlName="nurseName" placeholder="请输入护士姓名" nzSize="default" />
620
 					</nz-form-control>
641
 					</nz-form-control>
621
-				</nz-form-item>
642
+				</nz-form-item> -->
622
 				<nz-form-item *ngIf="!ifFixType">
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
 				    <nz-input-group>
646
 				    <nz-input-group>
626
 							<nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择固定液类型" formControlName="fixative">
647
 							<nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择固定液类型" formControlName="fixative">
627
 							  <ng-container *ngFor="let option of fixativeData">
648
 							  <ng-container *ngFor="let option of fixativeData">
@@ -648,7 +669,7 @@
648
 		<div class="content">
669
 		<div class="content">
649
 			<div class="content-item boder-right">
670
 			<div class="content-item boder-right">
650
 				<nz-form-item class="form-title-box">
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
 					<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
673
 					<div class="form-title"><span class="font-weight-500">状态:</span>{{detailsData.status?detailsData.status.name:'-'}}</div>
653
 				</nz-form-item>
674
 				</nz-form-item>
654
 				<nz-form-item class="form-title-box">
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
     color: @primary-color!important;
14
     color: @primary-color!important;
15
     font-weight: bold !important;
15
     font-weight: bold !important;
16
   }
16
   }
17
-
17
+	
18
+	.mar-left{
19
+		margin-left: 10px;
20
+	}
21
+	
18
   h1,
22
   h1,
19
   h2,
23
   h2,
20
   h3,
24
   h3,
@@ -163,44 +167,118 @@
163
       }
167
       }
164
     }
168
     }
165
   }
169
   }
166
-  .userInfo {
167
-		width: 260px;
170
+		
171
+	.right {
172
+		width: 20%;
168
 		height: 100%;
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
   // 头部 end
282
   // 头部 end
205
   // 主体部分 start
283
   // 主体部分 start
206
   .pharmacy-main {
284
   .pharmacy-main {
@@ -649,7 +727,12 @@
649
 			}
727
 			}
650
 	  }
728
 	  }
651
 		.no-width{
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
 		this.hosId = this.tool.getCurrentHospital().id;
139
 		this.hosId = this.tool.getCurrentHospital().id;
140
 		this.userId = this.tool.getCurrentUserId()
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
     this.runTime();
147
     this.runTime();
142
-    // 统计
143
-    // this.total();
144
 		this.getDept()
148
 		this.getDept()
145
-    // 切换科室
146
-    // this.changeKs();
147
-
148
     this.initRole();
149
     this.initRole();
149
     // 自动刷新倒计时 start
150
     // 自动刷新倒计时 start
150
     this.autoUpdate();
151
     this.autoUpdate();
@@ -289,7 +290,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
289
 		this.fixationData = format(result, 'yyyy-MM-dd');
290
 		this.fixationData = format(result, 'yyyy-MM-dd');
290
 		console.log(this.fixationData)
291
 		console.log(this.fixationData)
291
 	}
292
 	}
292
-	fixationTimeSelect:any;
293
+	fixationTimeSelect:any = null;
293
 	fixationTimeChange(result){
294
 	fixationTimeChange(result){
294
 		if(result){
295
 		if(result){
295
 			this.fixationTimeSelect = format(result, 'HH:mm');
296
 			this.fixationTimeSelect = format(result, 'HH:mm');
@@ -310,8 +311,8 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
310
 		  fixationDate: [null, [Validators.required]],
311
 		  fixationDate: [null, [Validators.required]],
311
 			jobNumber: [null, [Validators.required]],
312
 			jobNumber: [null, [Validators.required]],
312
 			name:[null, [Validators.required]],
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
 			fixative:[null, [Validators.required]],
316
 			fixative:[null, [Validators.required]],
316
 		});
317
 		});
317
 		let date = new Date();
318
 		let date = new Date();
@@ -336,9 +337,9 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
336
 				new FormControl(null, Validators.required)
337
 				new FormControl(null, Validators.required)
337
 			);
338
 			);
338
 			this.validateVerificationForm.controls.fixationDate.setValue(inVitroDate);
339
 			this.validateVerificationForm.controls.fixationDate.setValue(inVitroDate);
339
-			// this.validateVerificationForm.controls.fixationTimes.setValue(date);
340
+			this.validateVerificationForm.controls.fixationTimes.setValue(date);
340
 			this.fixationData = inVitroDate;
341
 			this.fixationData = inVitroDate;
341
-			// this.fixationTimeSelect = format(date, 'HH:mm');
342
+			this.fixationTimeSelect = format(date, 'HH:mm');
342
 		}
343
 		}
343
 
344
 
344
 		this.btnLoading = true
345
 		this.btnLoading = true
@@ -417,7 +418,12 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
417
 	
418
 	
418
 	// 获取科室
419
 	// 获取科室
419
 	getDept(){
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
 		var that = this;
427
 		var that = this;
422
 		that.mainService.getDictionary("list", "dept_type").subscribe((res2) => {
428
 		that.mainService.getDictionary("list", "dept_type").subscribe((res2) => {
423
 			let item1 = res2.find(i=>i.name=='手术室科室')
429
 			let item1 = res2.find(i=>i.name=='手术室科室')
@@ -467,33 +473,28 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
467
 					this.validateForm.controls.operation.setValue(deptArr);
473
 					this.validateForm.controls.operation.setValue(deptArr);
468
 				}
474
 				}
469
 				this.validateForm.controls.specimen.setValue(data.dept.id);
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
 					this.validateForm.controls.generate.setValue(data.autoCreateOrder);
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
 	setSpecimen(){
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
 		this.relevanceModal = true
491
 		this.relevanceModal = true
495
 	}
492
 	}
496
-
493
+	
494
+	hideModal(){
495
+		this.relevanceModal = false
496
+	}
497
+	
497
 	// 确定关联科室
498
 	// 确定关联科室
498
 	btnLoading:boolean = false;
499
 	btnLoading:boolean = false;
499
 	submitForm(){
500
 	submitForm(){
@@ -568,6 +569,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
568
 				this.loginUser = data.data
569
 				this.loginUser = data.data
569
 	      let user = JSON.parse(localStorage.getItem("user"));
570
 	      let user = JSON.parse(localStorage.getItem("user"));
570
 	      user.user.dept = data["data"].dept;
571
 	      user.user.dept = data["data"].dept;
572
+				user.user.autoCreateOrder = data["data"].autoCreateOrder;
571
 	      user.user.currentHospital = data["data"].currentHospital;
573
 	      user.user.currentHospital = data["data"].currentHospital;
572
 	      localStorage.setItem("user", JSON.stringify(user));
574
 	      localStorage.setItem("user", JSON.stringify(user));
573
 	    }
575
 	    }
@@ -578,10 +580,10 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
578
 	handoverUserId:any = null; //医生工号
580
 	handoverUserId:any = null; //医生工号
579
 	nurseId:any = null; //护士工号
581
 	nurseId:any = null; //护士工号
580
 	numberChange(e,type){
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
 		let query = {
587
 		let query = {
586
 		  account: e
588
 		  account: e
587
 		};
589
 		};
@@ -593,8 +595,8 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
593
 						this.validateVerificationForm.controls.name.setValue(data.userName);
595
 						this.validateVerificationForm.controls.name.setValue(data.userName);
594
 						this.handoverUserId = data.userId
596
 						this.handoverUserId = data.userId
595
 					}else{
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
   loading3 = false;
779
   loading3 = false;
778
   loading4 = false;
780
   loading4 = false;
779
   loading5 = false;
781
   loading5 = false;
782
+	otherData1 = null;
783
+	otherData2 = null;
784
+	otherData3 = null;
780
   getPharmacyList(idx, type, searchKey) {
785
   getPharmacyList(idx, type, searchKey) {
781
     let hosId = JSON.parse(localStorage.getItem("user")).user.currentHospital.id;
786
     let hosId = JSON.parse(localStorage.getItem("user")).user.currentHospital.id;
782
     switch (type) {
787
     switch (type) {
@@ -828,6 +833,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
828
               } else {
833
               } else {
829
                 this.printPharmacyFlag = true;
834
                 this.printPharmacyFlag = true;
830
               }
835
               }
836
+							this.otherData1 = result.otherData;
831
               // 列表数据合并
837
               // 列表数据合并
832
               if (idx === 0) {
838
               if (idx === 0) {
833
                 this.printPharmacyList = result["list"];
839
                 this.printPharmacyList = result["list"];
@@ -848,6 +854,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
848
               } else {
854
               } else {
849
                 this.waitPharmacyFlag = true;
855
                 this.waitPharmacyFlag = true;
850
               }
856
               }
857
+							this.otherData2 = result.otherData;
851
               if (idx === 0) {
858
               if (idx === 0) {
852
                 this.waitPharmacyList = result["list"];
859
                 this.waitPharmacyList = result["list"];
853
               } else {
860
               } else {
@@ -867,6 +874,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
867
               } else {
874
               } else {
868
                 this.pharmacyFlag = true;
875
                 this.pharmacyFlag = true;
869
               }
876
               }
877
+							this.otherData3 = result.otherData;
870
               if (idx === 0) {
878
               if (idx === 0) {
871
                 this.pharmacyList = result["list"];
879
                 this.pharmacyList = result["list"];
872
               } else {
880
               } else {
@@ -963,6 +971,7 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
963
 
971
 
964
   // 右侧菜单
972
   // 右侧菜单
965
   showLastItems: boolean = false;
973
   showLastItems: boolean = false;
974
+	showDropdown:boolean = false;
966
   // 下拉
975
   // 下拉
967
   fixedMenuXiala() {
976
   fixedMenuXiala() {
968
     this.showLastItems = true;
977
     this.showLastItems = true;
@@ -972,7 +981,17 @@ export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
972
   fixedMenuShangla() {
981
   fixedMenuShangla() {
973
     this.showLastItems = false;
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
   mainRole: boolean = false; //回到系统管理权限
995
   mainRole: boolean = false; //回到系统管理权限
977
   initRole() {
996
   initRole() {
978
     let menus = JSON.parse(localStorage.getItem("menu"));
997
     let menus = JSON.parse(localStorage.getItem("menu"));