浏览代码

拉取代码

maotao 8 月之前
父节点
当前提交
5361a11355

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

@@ -11,6 +11,8 @@ import { MainGuard } from './guard/main.guard';
11 11
 import { PharmacyGuard } from './guard/pharmacy.guard';
12 12
 // 标本视图权限
13 13
 import { SpecimenView2Guard } from './guard/SpecimenView2Guard.guard';
14
+// 标本间端权限
15
+import { SpecimenRoomViewGuard } from './guard/SpecimenRoomViewGuard.guard';
14 16
 // 全局业务查看权限
15 17
 import { DisinfectionSupplyGuard } from './guard/DisinfectionSupplyGuard.guard';
16 18
 // 配置中心查看权限
@@ -69,6 +71,12 @@ const routes: Routes = [
69 71
     loadChildren: () => import('./views/specimen-view2/specimen-view2.module').then(m => m.SpecimenView2Module),
70 72
     canActivate: [SpecimenView2Guard]
71 73
   },
74
+	// 标本间端
75
+	{
76
+	  path: 'specimenRoomView',
77
+	  loadChildren: () => import('./views/specimen-room-view/specimen-room-view.module').then(m => m.SpecimenRoomViewModule),
78
+	  canActivate: [SpecimenRoomViewGuard]
79
+	},
72 80
   // 全局业务查看
73 81
   {
74 82
     path: 'disinfectionSupply',

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

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

+ 219 - 0
src/app/share/pathology-add/pathology-add.component.html

@@ -0,0 +1,219 @@
1
+<div class="pathology-box display_flex align-items_center justify-content_flex-center">
2
+	<div class="pathology-content">
3
+		<div class="title">病理申请单<i class="icon_transport transport-guanbi" (click)="hideModal()"></i>
4
+		</div>
5
+		<div class="content">
6
+			<form nz-form [formGroup]="validateForm" class="addForm" (ngSubmit)="submitForm()">
7
+				<div class="content-item boder-right">
8
+					<nz-form-item class="form-item">
9
+						<nz-form-label nzRequired nzFor="knowledgeClass" [nzSm]="6" [nzXs]="24">是否术中快速</nz-form-label>
10
+						<nz-form-control nzErrorTip="请选择!" [nzSm]="18" [nzXs]="24">
11
+							<nz-radio-group formControlName="knowledgeClass">
12
+								<label nz-radio [nzValue]="1">是</label>
13
+								<label nz-radio [nzValue]="0">否</label>
14
+							</nz-radio-group>
15
+						</nz-form-control>
16
+					</nz-form-item>
17
+					<nz-form-item class="form-title-box">
18
+						<div class="form-title"><span class="font-weight-500">申请单编号:</span>1008611</div>
19
+						<div class="form-title"><span class="font-weight-500">状态:</span>未打印</div>
20
+					</nz-form-item>
21
+					<nz-form-item class="form-title-box">
22
+						<div class="form-title"><span class="font-weight-500">科室名称:</span>科室111</div>
23
+						<div class="form-title"><span class="font-weight-500">住院号:</span>008622</div>
24
+					</nz-form-item>
25
+					<nz-form-item class="form-title-box">
26
+						<div class="form-title"><span class="font-weight-500">患者信息:</span>张三</div>
27
+						<div class="form-title"><span class="font-weight-500">年龄:</span>18</div>
28
+					</nz-form-item>
29
+					<nz-form-item>
30
+						<div class="form-title width-100 font-weight-500">诊断:</div>
31
+						<div>
32
+							<div>1.有病</div>
33
+							<div>2.有病</div>
34
+						</div>
35
+					</nz-form-item>
36
+					
37
+					<nz-form-item>
38
+						<div class="form-title font-weight-500">病理摘要:</div>
39
+						<div>患者因“胆囊息肉4月余”于2024-08-05入院。
40
+						患者4月前我院彩超提示胆囊息肉,大小约1.3*cds  0.7cm,无腹痛腹胀,无恶心呕吐,无发热,无胸闷、无返酸,无呕血、黑便,无腹泻,无尿频、尿急、尿痛。未进一步处理,今患者再次来我院,要求进一步治疗住院,</div>
41
+					</nz-form-item>
42
+					
43
+					<nz-form-item class="form-item">
44
+						<nz-form-label nzRequired nzFor="scheme" [nzSm]="24" [nzXs]="24">手术方案</nz-form-label>
45
+						<nz-form-control nzErrorTip="请输入手术方案" [nzSm]="24" [nzXs]="24">
46
+							<textarea rows="3" nz-input formControlName="scheme" placeholder="请输入手术方案"></textarea>
47
+						</nz-form-control>
48
+					</nz-form-item>
49
+				</div>
50
+				
51
+				<div class="content-item">
52
+					<nz-form-item class="form-item">
53
+						<nz-form-label nzRequired nzFor="sees" [nzSm]="6" [nzXs]="24">术中所见</nz-form-label>
54
+						<nz-form-control nzErrorTip="请输入术中所见" [nzSm]="24" [nzXs]="24">
55
+							<textarea rows="3" nz-input formControlName="sees" placeholder="请输入术中所见"></textarea>
56
+						</nz-form-control>
57
+					</nz-form-item>
58
+					
59
+					<nz-form-item class="form-item">
60
+						<nz-form-label nzRequired nzFor="specimen" [nzSm]="5" [nzXs]="24">标本类型</nz-form-label>
61
+						<nz-form-control nzErrorTip="请选择标本类型!" [nzSm]="19" [nzXs]="24">
62
+							<nz-input-group>
63
+								<nz-select nzSearch nzShowSearch nzPlaceHolder="请选择标本类型" formControlName="specimen">
64
+									<ng-container *ngFor="let option of specimenData">
65
+										<nz-option *ngIf="!isDeptLoading" [nzLabel]="option.name" [nzValue]="option.id"></nz-option>
66
+									</ng-container>
67
+									<nz-option *ngIf="isDeptLoading" nzDisabled nzCustomContent>
68
+										<i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
69
+									</nz-option>
70
+								</nz-select>
71
+							</nz-input-group>
72
+						</nz-form-control>
73
+					</nz-form-item>
74
+					
75
+					<nz-form-item class="form-item">
76
+						<nz-form-label nzRequired nzFor="number" [nzSm]="5" [nzXs]="24">标本件数</nz-form-label>
77
+						<nz-form-control nzErrorTip="请输入标本件数!" [nzSm]="19" [nzXs]="24">
78
+							<input nz-input formControlName="number"  placeholder="请输入标本件数" nzSize="default" />
79
+						</nz-form-control>
80
+					</nz-form-item>
81
+					
82
+					<nz-form-item class="form-item">
83
+						<nz-form-label nzRequired nzFor="part" [nzSm]="5" [nzXs]="24">采取部位</nz-form-label>
84
+						<nz-form-control nzErrorTip="请输入采取部位!" [nzSm]="19" [nzXs]="24">
85
+							<input nz-input formControlName="part"  placeholder="请输入采取部位" nzSize="default" />
86
+						</nz-form-control>
87
+					</nz-form-item>
88
+					
89
+					<nz-form-item class="form-title-box">
90
+						<div class="form-title">取标本位置:A01</div>
91
+						<div class="form-title">取材医生:王医生</div>
92
+					</nz-form-item>
93
+					
94
+					<nz-form-item class="form-item">
95
+						<nz-form-label nzRequired [nzSm]="3" [nzXs]="24">标本</nz-form-label>
96
+						<div class="add-icon-class" (click)='openSpecimen()'>
97
+							<span class="icon_transport transport-tag27fuben form-icon"></span>
98
+						</div>
99
+					</nz-form-item>
100
+					
101
+					<div class="specimen-list">
102
+						<div *ngFor="let item of specimenList;let index=index;" class="specimen-item">
103
+							<div>{{item.name}}</div>
104
+							<span class="icon_transport transport-lajitong specimen-icon" (click)="specimenDel($event,item,index)"></span>
105
+						</div>
106
+					</div>
107
+				</div>
108
+			</form>
109
+		</div>
110
+		<div class="display_flex justify-content_flex-center bottom-btn">
111
+		  <button class="btn btn-right" nz-button nzType="primary" (click)="submitForm()" [nzLoading]="btnLoading">打印标本</button>
112
+			<button class="btn cancel" nz-button nzType="default" (click)="hideModal()">取消</button>
113
+		</div>
114
+	</div>
115
+</div>
116
+
117
+<!-- 选择标本 -->
118
+<div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="specimenModal">
119
+	<div class="modalBody">
120
+		<div class="title">新增病理标本<i class="icon_transport transport-guanbi" (click)="hideSpecimenModal()"></i>
121
+		</div>
122
+		<div class="content">
123
+			<form nz-form [formGroup]="validateSpecimenForm" class="addForm" (ngSubmit)="submitSpecimen()">
124
+				<nz-form-item class="form-item">
125
+					<nz-form-label nzRequired [nzSm]="3" [nzXs]="24">位置来源</nz-form-label>
126
+					<div class="specimen-list">
127
+						<div>
128
+							<div *ngFor="let item of placeList;let index=index;" class="select-item"
129
+							[ngClass]="{'activeClass': index == placeIndex}" (click)="placeClick($event,item,index)" class="select-item">{{item.name}}</div>
130
+						</div>
131
+					</div>
132
+				</nz-form-item>
133
+				
134
+				<nz-form-item class="form-item">
135
+					<nz-form-label nzRequired [nzSm]="3" [nzXs]="24">系统</nz-form-label>
136
+					<div class="specimen-list">
137
+						<div *ngFor="let item of systemList;let index=index;" class="select-box"
138
+							[ngClass]="{'activeClass': index == systemIndex}" (click)="systemClick($event,item,index)">
139
+							<div class="select-item">{{item.name}}</div>
140
+						</div>
141
+					</div>
142
+				</nz-form-item>
143
+				
144
+				<nz-form-item class="form-item">
145
+					<nz-form-label nzRequired [nzSm]="3" [nzXs]="24">器官</nz-form-label>
146
+					<div class="specimen-list">
147
+						<div *ngFor="let item of apparatusList;let index=index;" class="select-box"
148
+							[ngClass]="{'activeClass': index == apparatusIndex}" (click)="apparatusClick($event,item,index)">
149
+							<div class="select-item">{{item.name}}</div>
150
+						</div>
151
+					</div>
152
+				</nz-form-item>
153
+				
154
+				<nz-form-item class="form-item">
155
+					<nz-form-label nzRequired [nzSm]="3" [nzXs]="24">标本名称</nz-form-label>
156
+					<div class="specimen-list">
157
+						<div *ngFor="let item of specimenNameList;let index=index;" class="select-box"
158
+							[ngClass]="{'activeClass': index == specimenNameIndex}" (click)="specimenNameClick($event,item,index)">
159
+							<div class="select-item">{{item.name}}</div>
160
+						</div>
161
+					</div>
162
+				</nz-form-item>
163
+				
164
+				<nz-form-item class="form-item">
165
+					<nz-form-label nzRequired nzFor="remark" [nzSm]="3" [nzXs]="24">备注</nz-form-label>
166
+					<nz-form-control nzErrorTip="请输入备注" [nzSm]="21" [nzXs]="24">
167
+						<textarea rows="3" nz-input formControlName="remark" placeholder="请输入备注"></textarea>
168
+					</nz-form-control>
169
+				</nz-form-item>
170
+			</form>
171
+		</div>
172
+		<div class="display_flex justify-content_flex-center bottom-btn">
173
+			<button class="btn btn-right" nz-button nzType="primary" (click)="submitSpecimen()" [nzLoading]="btnLoading">确定</button>
174
+			<button class="btn cancel" nz-button nzType="default" (click)="hideSpecimenModal()">取消</button>
175
+		</div>
176
+	</div>
177
+</div>
178
+
179
+<!-- 操作成功/失败提示框 -->
180
+<app-prompt-modal *ngIf="promptModalShow" [content]="promptContent" [success]="ifSuccess" [show]="promptModalShow"
181
+  [info]="promptInfo" (closeModel)="closeModel"></app-prompt-modal>
182
+	
183
+<!-- 未打印 -->
184
+<div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="notModal">
185
+	<div class="modalBody no-width">
186
+		<div class="title">未打印<i class="icon_transport transport-guanbi" (click)="hideNotModal()"></i>
187
+		</div>
188
+		<div class="content">
189
+			<form nz-form [formGroup]="validatePrintForm" class="addForm" (ngSubmit)="submitPrintForm()">
190
+				<nz-form-item>
191
+				  <nz-form-label nzRequired [nzSpan]="8" nzFor="time">标本离体时间</nz-form-label>
192
+				  <nz-form-control [nzSpan]="16" nzErrorTip="请选择标本离体时间!">
193
+				    <nz-input-group>
194
+							<nz-date-picker formControlName="time" 
195
+							[nzShowTime]="{ nzFormat: 'yyyy-MM-dd HH:mm:ss' }" nzFormat="yyyy-MM-dd HH:mm:ss"
196
+							(ngModelChange)="formChangeDate($event)"></nz-date-picker>
197
+						</nz-input-group>
198
+				  </nz-form-control>
199
+				</nz-form-item>
200
+				<nz-form-item>
201
+				  <nz-form-label nzRequired [nzSpan]="5" nzFor="jobNumber">工号</nz-form-label>
202
+					<nz-form-control [nzSpan]="19" nzErrorTip="请输入工号!">
203
+						<input nz-input (input)="numberChange($event)" formControlName="jobNumber" placeholder="请输入工号" nzSize="default" />
204
+					</nz-form-control>
205
+				</nz-form-item>
206
+				<nz-form-item>
207
+				  <nz-form-label nzRequired [nzSpan]="5" nzFor="name">姓名</nz-form-label>
208
+					<nz-form-control [nzSpan]="19" nzErrorTip="请输入姓名!">
209
+						<input nz-input disabled formControlName="name" placeholder="请输入姓名" nzSize="default" />
210
+					</nz-form-control>
211
+				</nz-form-item>
212
+			</form>
213
+		</div>
214
+		<div class="display_flex justify-content_flex-center bottom-btn">
215
+			<button class="btn btn-right" nz-button nzType="primary" (click)="submitPrintForm()" [nzLoading]="btnLoading">确定</button>
216
+			<button class="btn cancel" nz-button nzType="default" (click)="hideNotModal()">取消</button>
217
+		</div>
218
+	</div>
219
+</div>

+ 198 - 0
src/app/share/pathology-add/pathology-add.component.less

@@ -0,0 +1,198 @@
1
+.pathology-box {
2
+  position: fixed;
3
+	left: 0;
4
+	top: 0;
5
+	width: 100%;
6
+	height: 100%;
7
+	background: rgba(0, 0, 0, 0.4);
8
+	z-index: 99;
9
+	.pathology-content{
10
+		width: 80%;
11
+		background: #fff;
12
+		border-radius: 5px;
13
+		padding: 10px 20px;
14
+		color: #000;
15
+		.title {
16
+		  width: 100%;
17
+		  text-align: center;
18
+		  font-size: 18px;
19
+		  position: relative;
20
+		
21
+		  i {
22
+		    position: absolute;
23
+		    right: 0;
24
+		    top: 0;
25
+		    font-size: 20px;
26
+		    color: #666;
27
+		    cursor: pointer;
28
+		    padding: 0 5px;
29
+		  }
30
+		}
31
+		.content{
32
+			width: 100%;
33
+			background: #f9fafb;
34
+			border: 1px solid #e5e9ed;
35
+			border-radius: 5px;
36
+			overflow: hidden;
37
+			margin-top: 12px;
38
+			height: auto;
39
+			// padding: 19px 14px 10px 0;
40
+			max-height: 460px;
41
+			overflow-y: auto;
42
+			.addForm{
43
+				display: flex;
44
+				.width-100{
45
+					width: 100%;
46
+				}
47
+				.font-weight-500{
48
+					color: #000;
49
+					font-weight: 500;
50
+				}
51
+				.ant-select{
52
+					width: 100%;
53
+				}
54
+				.content-item{
55
+					flex: 1;
56
+					padding: 0 15px;
57
+					.form-title-box{
58
+						display: flex;
59
+						.form-title{
60
+							color: #333;
61
+							margin-right: 40px;
62
+						}
63
+					}
64
+					.ant-form-item {
65
+					  margin-bottom: 14px;
66
+						display: flex;
67
+						flex-wrap: wrap;
68
+					  .ant-form-item-label {
69
+					    text-align: left;
70
+							font-weight: 500;
71
+					  }
72
+						.ant-form-item-control-wrapper{
73
+							.ant-form-item-control{
74
+								width: 400px;
75
+							}
76
+						}
77
+					}
78
+					.add-icon-class{
79
+						border: 1px solid #e5e9ed;
80
+						border-radius: 3px;
81
+						width: 26px;
82
+						height: 26px;
83
+						line-height: 26px;
84
+						text-align: center;
85
+						position: relative;
86
+						top: 7px;
87
+						cursor: pointer;
88
+						.form-icon{
89
+							
90
+						}
91
+					}
92
+				}
93
+				.boder-right{
94
+					border-right: 1px solid #e5e9ed;
95
+				}
96
+				.specimen-item{
97
+					display: flex;
98
+					margin-bottom: 10px;
99
+					.specimen-icon{
100
+						color: #64BD7B;
101
+						cursor: pointer;
102
+						font-size: 20px;
103
+						position: relative;
104
+						top: -4px;
105
+						left: 2px;
106
+					}
107
+				}
108
+			}
109
+		}
110
+		.bottom-btn{
111
+			margin-top: 10px;
112
+			.btn-right{
113
+				margin-right: 10px;
114
+			}
115
+		}
116
+	}
117
+	
118
+}
119
+	// 新增
120
+	&.add {
121
+		position: fixed;
122
+		left: 0;
123
+		top: 0;
124
+		width: 100%;
125
+		height: 100%;
126
+		background: rgba(0, 0, 0, 0.4);
127
+		z-index: 999;
128
+	  .modalBody {
129
+	    width: 80%;
130
+	    height: auto;
131
+			padding: 10px 20px;
132
+			border-radius: 5px;
133
+			background: #fff;
134
+			.title {
135
+			  width: 100%;
136
+			  text-align: center;
137
+			  font-size: 18px;
138
+			  position: relative;
139
+			
140
+			  i {
141
+			    position: absolute;
142
+			    right: 0;
143
+			    top: 0;
144
+			    font-size: 20px;
145
+			    color: #666;
146
+			    cursor: pointer;
147
+			    padding: 0 5px;
148
+			  }
149
+			}
150
+	    .content {
151
+	      width: 100%;
152
+	      height: auto;
153
+	      padding: 19px 14px 0 14px;
154
+	      max-height: 500px;
155
+	      overflow-y: auto;
156
+				.ant-form-item {
157
+				  margin-bottom: 14px;
158
+					display: flex;
159
+					flex-wrap: wrap;
160
+				  .ant-form-item-label {
161
+				    text-align: left;
162
+						font-weight: 500;
163
+				  }
164
+					.ant-form-item-control-wrapper{
165
+						.ant-form-item-control{
166
+							width: 400px;
167
+						}
168
+					}
169
+				}
170
+				.select-item{
171
+					margin-top: 5px;
172
+					display: flex;
173
+					flex-wrap: wrap;
174
+					padding: 3px 8px;
175
+					border: 1px solid #e5e9ed;
176
+					border-radius: 5px;
177
+					margin-right: 10px;
178
+					cursor: pointer;
179
+					display: inline-block;
180
+				}
181
+				
182
+				.activeClass{
183
+					color: #64BD7B;
184
+					border-color: #64BD7B;
185
+				}
186
+	      
187
+	    }
188
+			.bottom-btn{
189
+				margin-top: 10px;
190
+				.btn-right{
191
+					margin-right: 10px;
192
+				}
193
+			}
194
+	  }
195
+		.no-width{
196
+			width: 30% !important;
197
+		}
198
+	}

+ 246 - 0
src/app/share/pathology-add/pathology-add.component.ts

@@ -0,0 +1,246 @@
1
+import { Component, ElementRef, Output, Input, OnInit, EventEmitter } from '@angular/core';
2
+import { HttpHeaders, HttpRequest, HttpClient  } from "@angular/common/http";
3
+import host from "../../../assets/js/http";
4
+import { NzMessageService } from "ng-zorro-antd";
5
+import { MainService } from '../../services/main.service';
6
+import {
7
+  FormBuilder,
8
+  Validators,
9
+  FormGroup,
10
+  FormControl,
11
+} from "@angular/forms";
12
+import { format, startOfDay, endOfDay, subDays} from "date-fns";
13
+
14
+@Component({
15
+  selector: 'app-pathology-add',
16
+  templateUrl: './pathology-add.component.html',
17
+  styleUrls: ['./pathology-add.component.less']
18
+})
19
+export class PathologyAddComponent implements OnInit {
20
+	
21
+	@Output() pathologyCancel = new EventEmitter();
22
+	@Input() content: string;
23
+
24
+	constructor(
25
+		private http: HttpClient,
26
+		private message: NzMessageService,
27
+		private mainService: MainService,
28
+		private fb: FormBuilder,
29
+	) { }
30
+	
31
+	btnLoading:boolean = false;
32
+	validateForm: FormGroup; //新增/编辑表单
33
+	validateSpecimenForm: FormGroup; //选择标本表单
34
+	validatePrintForm: FormGroup;
35
+	specimenData:any=[]; //标本类型
36
+	isDeptLoading:boolean = false;
37
+	specimenModal:boolean = false; //选择标本状态
38
+	specimenList:any=[
39
+		{
40
+			name:'aaa'
41
+		},
42
+		{
43
+			name:'bbbb'
44
+		}
45
+	]; //已选标本
46
+	placeIndex:any;
47
+	systemIndex:any;
48
+	apparatusIndex:any;
49
+	specimenNameIndex:any;
50
+	placeList:any=[
51
+		{
52
+			name:'通用'
53
+		},
54
+		{
55
+			name:'左侧'
56
+		},
57
+		{
58
+			name:'通用'
59
+		},
60
+		{
61
+			name:'左侧'
62
+		},
63
+		{
64
+			name:'通用'
65
+		},
66
+		{
67
+			name:'左侧'
68
+		},
69
+		{
70
+			name:'通用'
71
+		},
72
+		{
73
+			name:'左侧'
74
+		},
75
+		{
76
+			name:'通用'
77
+		},
78
+		{
79
+			name:'左侧'
80
+		},
81
+	]; //位置来源数据
82
+	systemList:any=[]; //系统数据
83
+	apparatusList:any=[]; //器官数据
84
+	specimenNameList:any=[]; //标本名称数据
85
+	promptContent: string; //操作提示框提示信息
86
+	ifSuccess: boolean; //操作成功/失败
87
+	promptInfo: string; //操作结果提示信息
88
+	promptModalShow: boolean; //操作提示框是否展示
89
+	type:any = '未打印';
90
+	notModal:boolean = false;
91
+  ngOnInit() {
92
+		this.initForm()
93
+  }
94
+	
95
+	// 初始化新增form表单
96
+	initForm() {
97
+		this.validateForm = this.fb.group({
98
+		  knowledgeClass: [1, [Validators.required]],
99
+			specimen: [null, [Validators.required]],
100
+			sees: [null, [Validators.required]],
101
+			scheme: [null, [Validators.required]],
102
+			number: [null,[Validators.required]],
103
+			part: [null, [Validators.required]]
104
+		});
105
+	}
106
+	
107
+	specimenDel(e,item,index){
108
+		this.specimenList.splice(index,1)
109
+	}
110
+	
111
+	// 选择标本
112
+	openSpecimen(){
113
+		this.validateSpecimenForm = this.fb.group({
114
+		  remark: [null, [Validators.required]]
115
+		});
116
+		this.specimenModal = true
117
+	}
118
+	
119
+	// 选择位置来源
120
+	placeClick(e,item,index){
121
+		this.placeIndex = index
122
+	}
123
+	
124
+	// 选择系统
125
+	systemClick(e,item,index){
126
+		this.systemIndex = index
127
+		this.getApparatus(item)
128
+	}
129
+	
130
+	// 选择器官
131
+	apparatusClick(e,item,index){
132
+		this.apparatusIndex = index
133
+		this.getSpecimenName(item)
134
+	}
135
+	
136
+	// 选择标本名称
137
+	specimenNameClick(e,item,index){
138
+		this.specimenNameIndex = index
139
+	}
140
+	
141
+	// 获取器官
142
+	getApparatus(item){
143
+		
144
+	}
145
+	
146
+	// 获取标本名称
147
+	getSpecimenName(item){
148
+		
149
+	}
150
+	
151
+	submitSpecimen(){
152
+		this.hideSpecimenModal()
153
+	}
154
+	
155
+	hideSpecimenModal(){
156
+		this.specimenModal = false
157
+	}
158
+	
159
+	hideNotModal(){
160
+		this.notModal = false
161
+	}
162
+	
163
+	// 日期选择
164
+	startDate: string; //时间开始
165
+	formChangeDate(result?): void {
166
+	  this.startDate = format(result[0], 'yyyy-MM-dd HH:mm:ss');
167
+		
168
+	}
169
+	
170
+	submitPrintForm(): void{
171
+		// for (const i in that.validateForm.controls) {
172
+		//   that.validateForm.controls[i].markAsDirty();
173
+		//   that.validateForm.controls[i].updateValueAndValidity();
174
+		// }
175
+		// if (that.validateForm.invalid) return;
176
+		this.hideNotModal()
177
+	}
178
+	
179
+	// 监听工号数据
180
+	numberChange(e){
181
+		console.log(555,e)
182
+	}
183
+	
184
+	submitForm(): void{
185
+		if(this.type=='未打印'){
186
+			this.notModal = true
187
+			this.validatePrintForm = this.fb.group({
188
+			  time: [null, [Validators.required]],
189
+				jobNumber: [null, [Validators.required]],
190
+				name:[null, [Validators.required]],
191
+			});
192
+			let date = new Date();
193
+			this.startDate = format(date, "yyyy-MM-dd HH:mm:ss")
194
+			console.log(444,this.startDate)
195
+			this.validatePrintForm.controls.time.setValue(this.startDate);
196
+			return
197
+		}
198
+		var that = this;
199
+		// for (const i in that.validateForm.controls) {
200
+		//   that.validateForm.controls[i].markAsDirty();
201
+		//   that.validateForm.controls[i].updateValueAndValidity();
202
+		// }
203
+		// if (that.validateForm.invalid) return;
204
+		// let data: any = {
205
+		// 	startTime:this.formStartDate?this.formStartDate:this.loadStartTime,//发起时间开始
206
+		// 	endTime:this.formEndDate?this.formEndDate:this.loadEndTime,//发起时间结束
207
+		// 	hosId:this.hosId,
208
+		// 	pharmacy:this.validateForm.value.department,
209
+		// 	loadAllConsumeDept:this.validateForm.value.loadAllConsumeDept?1:0
210
+		// };
211
+		  
212
+		// that.btnLoading = true;
213
+		// that.mainService
214
+		//   .simplePost("addData", "drugsBatch", data)
215
+		//   .subscribe((data) => {
216
+		//     that.btnLoading = false;
217
+		//     that.hideModal();
218
+		//     that.initForm();
219
+		//     if (data.status == 200) {
220
+		//       that.showPromptModal("操作", true, "");
221
+		//     } else {
222
+		//       that.showPromptModal("操作", false, data.msg);
223
+		//     }
224
+		//   });
225
+		this.hideModal()
226
+	}
227
+	
228
+	closeModel(){
229
+		this.hideModal()
230
+	}
231
+	hideModal(){
232
+		this.pathologyCancel.emit()
233
+	}
234
+	
235
+	// 展示信息提示框(con:提示信息,success:操作是否成功,promptInfo:操作结果提示信息)
236
+	showPromptModal(con, success, promptInfo?) {
237
+	  this.promptModalShow = false;
238
+	  this.promptContent = con;
239
+	  this.ifSuccess = success;
240
+	  this.promptInfo = promptInfo;
241
+	  setTimeout(() => {
242
+	    this.promptModalShow = true;
243
+	  }, 100);
244
+	}
245
+}
246
+

+ 4 - 0
src/app/share/share.module.ts

@@ -54,6 +54,8 @@ import { MedicalWasteLogPromptModalComponent } from './medical-waste-log-prompt-
54 54
 import { OutgoingRecordDetailComponent } from './outgoing-record-detail/outgoing-record-detail.component';
55 55
 import { InspectionExecuteDetailComponent } from './inspection-execute-detail/inspection-execute-detail.component';
56 56
 import { wangEditorComponent } from './wang-editor/wang-editor.component';
57
+import { PathologyAddComponent } from './pathology-add/pathology-add.component';
58
+
57 59
 @NgModule({
58 60
   declarations: [
59 61
     DetailSampleComponent,
@@ -83,6 +85,7 @@ import { wangEditorComponent } from './wang-editor/wang-editor.component';
83 85
     OutgoingRecordDetailComponent,
84 86
     InspectionExecuteDetailComponent,
85 87
 		wangEditorComponent,
88
+		PathologyAddComponent,
86 89
     DateTransformPipe,
87 90
     DataToNamePipe,
88 91
     DialogDeleteComponent,
@@ -146,6 +149,7 @@ import { wangEditorComponent } from './wang-editor/wang-editor.component';
146 149
     OutgoingRecordDetailComponent,
147 150
     InspectionExecuteDetailComponent,
148 151
 		wangEditorComponent,
152
+		PathologyAddComponent,
149 153
     CommonModule,
150 154
     NgZorroAntdModule,
151 155
     FormsModule,

+ 5 - 0
src/app/views/hushijiandan/hushijiandan.component.html

@@ -566,6 +566,7 @@
566 566
                       nzSpan="8"
567 567
                       class="borderL alignC display_flex justify-content_flex-center align-items_center h100p"
568 568
                     >
569
+											<button *ngIf="surgeryWKOMsg.patientDTO && surgeryConfigs && surgeryConfigs.isPathologyForm == 1" nz-button nzType="primary" class="btn txtC mr8" (click)="pathologyAdd($event)">病理申请单</button>
569 570
                       <button *ngIf="surgeryWKOMsg.patientDTO && surgeryConfigs && surgeryConfigs.remandClinical == 1" nz-button nzType="primary" class="btn txtC mr8" (click)="sendWard($event, surgeryWKOMsg)">送回病房</button>
570 571
                       <button *ngIf="surgeryWKOMsg.patientDTO && surgeryConfigs && surgeryConfigs.remandRecovery == 1" nz-button nzType="primary" class="btn txtC" (click)="sendAwakeningRoom($event, surgeryWKOMsg)">送回苏醒间</button>
571 572
                     </div>
@@ -3952,3 +3953,7 @@
3952 3953
   </div>
3953 3954
 </div>
3954 3955
 <button ngxPrint printSectionId="print-section" #printBtn hidden [printStyle]="{ '@page': { margin: '0 !important' }, 'body': { margin: '0 !important' } }">打印</button>
3956
+
3957
+<!-- 病理申请单 -->
3958
+
3959
+<app-pathology-add *ngIf="pathologyModal" (pathologyCancel)="pathologyCancel($event)"></app-pathology-add>

+ 1 - 0
src/app/views/hushijiandan/hushijiandan.component.less

@@ -1622,6 +1622,7 @@
1622 1622
 
1623 1623
 .alignC {
1624 1624
   display: flex;
1625
+	flex-wrap: wrap;
1625 1626
   justify-content: center;
1626 1627
   align-items: center;
1627 1628
 }

+ 10 - 2
src/app/views/hushijiandan/hushijiandan.component.ts

@@ -164,7 +164,7 @@ export class HushijiandanComponent implements OnInit {
164 164
   orderListTime = 0; //工单列表自动刷新秒数
165 165
   orderListTimeConst = 60; //工单列表自动刷新秒数
166 166
   deptDisplay; //护士端是否显示可以别名,1是显示科室名称,2是显示科室别名
167
-
167
+	pathologyModal:boolean = false; //病理申请单
168 168
   // 初始化权限按钮
169 169
   coopBtns: any = {};
170 170
 
@@ -305,7 +305,15 @@ export class HushijiandanComponent implements OnInit {
305 305
     this.coopBtns = coopBtns;
306 306
     console.log(this.coopBtns);
307 307
   }
308
-
308
+	
309
+	// 病理申请单
310
+	pathologyAdd(e){
311
+		this.pathologyModal = true
312
+	}
313
+	
314
+	pathologyCancel(){
315
+		this.pathologyModal = false
316
+	}
309 317
   // 切换综合日志和一键报修
310 318
   smallTabs = [];
311 319
   smallTabId = 2; //默认显示一键报修

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

@@ -41,6 +41,7 @@
41 41
           <button nz-button nzType="primary" *ngIf="largeScreenRole2" (click)="toBigScreen('largeScreen2')">大屏端2</button>
42 42
           <button nz-button nzType="primary" *ngIf="specimenViewRole" (click)="toBigScreen('specimenView')" [nzLoading]="deptTypeLoading">业务视图</button>
43 43
           <button nz-button nzType="primary" *ngIf="specimenViewRole2" (click)="toSpecimenView2()">标本视图</button>
44
+					<button nz-button nzType="primary" *ngIf="specimenRoomView" (click)="toSpecimenRoomView()">标本间端</button>
44 45
           <button nz-button nzType="primary" *ngIf="disinfectionSupplyRole" (click)="toDisinfectionSupply()">全局业务查看</button>
45 46
           <button nz-button nzType="primary" *ngIf="configurationCenterRole" (click)="toConfigurationCenter()">配置中心</button>
46 47
         </div>

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

@@ -29,6 +29,7 @@ export class MainComponent implements OnInit {
29 29
   largeScreenRole2: boolean = false; //大屏端权限
30 30
   specimenViewRole: boolean = false; //业务视图权限
31 31
   specimenViewRole2: boolean = false; //标本视图权限
32
+	specimenRoomView: boolean = false; //标本间权限
32 33
   disinfectionSupplyRole: boolean = false; //全局业务查看权限
33 34
   configurationCenterRole: boolean = false; //配置中心权限
34 35
   PCCommutesToWork: boolean = false; //PC上下班权限
@@ -289,6 +290,10 @@ export class MainComponent implements OnInit {
289 290
         this.specimenViewRole2 = true;
290 291
         console.log("标本视图权限");
291 292
       }
293
+			if (e.link == "specimenRoomView") {
294
+			  this.specimenRoomView = true;
295
+			  console.log("标本间权限");
296
+			}
292 297
       if (e.link == "disinfectionSupply") {
293 298
         this.disinfectionSupplyRole = true;
294 299
         console.log("全局业务查看权限");
@@ -408,6 +413,10 @@ export class MainComponent implements OnInit {
408 413
   toSpecimenView2(): void {
409 414
     this.router.navigateByUrl("specimenView2");
410 415
   }
416
+	// 标本间
417
+	toSpecimenRoomView(): void {
418
+	  this.router.navigateByUrl("specimenRoomView");
419
+	}
411 420
   // 全局业务查看
412 421
   toDisinfectionSupply(): void {
413 422
     this.router.navigateByUrl("disinfectionSupply");

+ 10 - 0
src/app/views/operation-config/operation-config.component.html

@@ -84,6 +84,11 @@
84 84
           <nz-form-label class="label">是否开启手术即将开始通知</nz-form-label>
85 85
           <nz-checkbox-group [(ngModel)]="surgeryBegin"></nz-checkbox-group>
86 86
         </div>
87
+				<!-- 是否开启病理申请单 -->
88
+				<div class="display_flex align-items_center mb8">
89
+				  <nz-form-label class="label">是否开启病理申请单</nz-form-label>
90
+				  <nz-checkbox-group [(ngModel)]="isPathologyForm"></nz-checkbox-group>
91
+				</div>
87 92
       </div>
88 93
       <!-- 自动建单配置 -->
89 94
       <div *ngIf="tabModalName=='automaticOrderCreation'">
@@ -93,6 +98,11 @@
93 98
           <nz-checkbox-group [(ngModel)]="autoCreateOrders" (ngModelChange)="changeAutoCreateOrders($event)"></nz-checkbox-group>
94 99
           <nz-time-picker [(ngModel)]="autoTime" nzFormat="HH:mm" *ngIf="autoCreateOrders[0].checked"></nz-time-picker>
95 100
         </div>
101
+				<!-- 是否开启速冻标本自动建单 -->
102
+				<div class="display_flex align-items_center mb8">
103
+				  <nz-form-label class="label">是否开启速冻标本自动建单</nz-form-label>
104
+				  <nz-checkbox-group [(ngModel)]="isFrozenSpecimen"></nz-checkbox-group>
105
+				</div>
96 106
       </div>
97 107
       <div class="bottom">
98 108
         <button class="login-form-button" nzType="primary" [nzLoading]="btnLoading" nz-button (click)="submitForm()">保存</button>

+ 13 - 1
src/app/views/operation-config/operation-config.component.ts

@@ -44,6 +44,14 @@ export class OperationConfigComponent implements OnInit {
44 44
   surgeryBegin:any[] = [
45 45
     {label:'是否开启',value: 0}
46 46
   ];
47
+	// 是否开启病理申请单
48
+	isPathologyForm:any[] = [
49
+	  {label:'是否开启',value: 0}
50
+	];
51
+	// 是否开启速冻标本自动建单
52
+	isFrozenSpecimen:any[] = [
53
+	  {label:'是否开启',value: 0}
54
+	];
47 55
   // 建单时间
48 56
   autoTime:Date | null = null;
49 57
   tasktype1Id:any;
@@ -143,6 +151,8 @@ export class OperationConfigComponent implements OnInit {
143 151
       recoveryTypeId: this.tasktype2Id || undefined,
144 152
       remandClean: this.autoRemandClean[0].checked ? 1 : 0,
145 153
       surgeryBegin: this.surgeryBegin[0].checked ? 1 : 0,
154
+			isPathologyForm: this.isPathologyForm[0].checked ? 1 : 0,
155
+			isFrozenSpecimen: this.isFrozenSpecimen[0].checked ? 1 : 0,
146 156
       cleanTypeId: this.cleanTypeId || undefined,
147 157
     };
148 158
     let postData = Object.assign({}, this.configs, editData);
@@ -331,7 +341,9 @@ export class OperationConfigComponent implements OnInit {
331 341
                 }
332 342
 
333 343
                 this.surgeryBegin[0].checked = this.configs.surgeryBegin == 1;
334
-              }
344
+								this.isPathologyForm[0].checked = this.configs.isPathologyForm == 1;
345
+								this.isFrozenSpecimen[0].checked = this.configs.isFrozenSpecimen == 1;
346
+							}
335 347
             });
336 348
         }else{
337 349
           this.loading = false;

+ 24 - 0
src/app/views/specimen-room-view/specimen-room-view-routing.module.ts

@@ -0,0 +1,24 @@
1
+import { NgModule } from "@angular/core";
2
+import { Routes, RouterModule } from "@angular/router";
3
+import { SpecimenRoomViewComponent } from "./specimen-room-view.component";
4
+import { DetailSampleComponent } from 'src/app/share/detail-sample/detail-sample.component';
5
+
6
+const routes: Routes = [
7
+  {
8
+    path: "",
9
+    component: SpecimenRoomViewComponent,
10
+    // children: [
11
+    //   {
12
+    //     // 工单详情-标本
13
+    //     path: "detailSample/:id",
14
+    //     component: DetailSampleComponent,
15
+    //   },
16
+    // ],
17
+  },
18
+];
19
+
20
+@NgModule({
21
+  imports: [RouterModule.forChild(routes)],
22
+  exports: [RouterModule],
23
+})
24
+export class SpecimenRoomViewRoutingModule {}

+ 587 - 0
src/app/views/specimen-room-view/specimen-room-view.component.html

@@ -0,0 +1,587 @@
1
+<div class="pharmacy">
2
+  <!-- 头部 start -->
3
+  <div class="pharmacy-header">
4
+   <div class="pharmacy-logo">
5
+<!--      <img
6
+        [src]="tool.logoUrl"
7
+        class="pharmacy-logo__img"
8
+        [alt]="tool.logoTitle"
9
+      />
10
+      <h1 class="pharmacy-logo__name">{{tool.logoTitle}}</h1> -->
11
+			<h2 class="pharmacy-name__title">
12
+			  <span>标本间</span>
13
+			  <!-- <span class="currentDate">{{ time | date: "yyyy年MM月dd日" }}</span> -->
14
+			</h2>
15
+    </div>
16
+    <div class="pharmacy-name">
17
+      <div class="pharmacy-name__total">
18
+				<div class="pharmacy-title">标本条码:</div>
19
+				<nz-input-group nzSearch nzSize="large" [nzAddOnAfter]="suffixButton">
20
+					<input type="text" [(ngModel)]="barCode" nz-input placeholder="请输入条码" />
21
+				</nz-input-group>
22
+				<ng-template #suffixButton>
23
+					<button nz-button nzType="primary" nzSize="large" nzSearch (click)="searchSpecimen()">搜索</button>
24
+				</ng-template>
25
+      </div>
26
+    </div>
27
+    <div class="userInfo">
28
+      <div class="wel">欢迎您:</div>
29
+      <div class="user">
30
+        <img src="../../assets/images/icon_keshi.png" alt="" />
31
+        <span *ngIf="deptDisplay">{{
32
+          deptDisplay == 2 ? loginUser.dept.deptalias : loginUser.dept.dept
33
+        }}</span>
34
+      </div>
35
+      <div class="userInfo-wrap">
36
+        <div class="logOut" (click)="changeKsNow()">切换科室</div>
37
+        <div class="logOut" (click)="logOut()">退出</div>
38
+      </div>
39
+    </div>
40
+  </div>
41
+  <!-- 头部 end -->
42
+  <!-- 主体部分 start -->
43
+  <div class="pharmacy-main">
44
+    <!-- 手术间标本start -->
45
+    <div class="pharmacy-main__list pharmacy-main__print">
46
+      <!-- 标题 start -->
47
+      <div class="pharmacy-main__title">
48
+        <strong>手术间标本</strong>
49
+        <span class="autoUpdate">{{ logTime }}秒</span>
50
+      </div>
51
+      <!-- 标题 end -->
52
+      <!-- 搜索框 start -->
53
+      <div class="pharmacy-main__search">
54
+        <div class="pharmacy-main__searchInput">
55
+          <input
56
+            nz-input
57
+            placeholder="请输入关键字"
58
+            [(ngModel)]="printPharmacySearchKey"
59
+          />
60
+          <div class="pharmacy-main__searchText" (click)="searchKeyHandle('delegation')">
61
+            <i nz-icon nzType="search"></i>
62
+            <span>搜索</span>
63
+          </div>
64
+        </div>
65
+      </div>
66
+      <!-- 搜索框 end -->
67
+      <!-- 列表 start -->
68
+      <overlay-scrollbars #osComponentRef1 class="pharmacy-main__selectionWrap">
69
+        <div *ngIf="!loading1" style="height: 100%">
70
+          <div
71
+            class="pharmacy-main__selection noPointer"
72
+            *ngFor="let item of printPharmacyList"
73
+						(click)="viewDetail(item)"
74
+          >
75
+            <div class="pharmacy-main__selectionInfo">
76
+              <div class="pharmacy-main__selectionItem">
77
+                <span title="住院号" class="weight">
78
+									<span class="sign-red">速冻</span>
79
+									{{item.code || '无'}}
80
+								</span>
81
+                <span title="姓名" class="weight">{{item.name || '无'}}</span>
82
+              </div>
83
+              <div class="pharmacy-main__selectionItem">
84
+                <span title="部位">部位:{{item.bw || '无'}}</span>
85
+                <span title="标本数">标本数:{{item.bbs || '无'}}</span>
86
+              </div>
87
+              <div class="pharmacy-main__selectionItem">
88
+                <span title="手术间">手术间:{{item.ssj || '无'}}</span>
89
+                <span title="离体时间">离体时间:{{item.time || '无'}}</span>
90
+              </div>
91
+            </div>
92
+          </div>
93
+          <div
94
+            class="pharmacy-main__selection pharmacy-main__selection--noData"
95
+            *ngIf="printPharmacyList.length === 0"
96
+          >
97
+            <img src="./../../assets/images/image_kongbaiye.png" alt="" />
98
+          </div>
99
+          <!-- <div
100
+            (click)="loadMore(1)"
101
+            class="pharmacy-main__selection pharmacy-main__selection--more"
102
+            *ngIf="printPharmacyFlag"
103
+          >
104
+            <div class="pharmacy-main__selectionInfo">
105
+              <i
106
+                nz-icon
107
+                nzType="loading"
108
+                nzTheme="outline"
109
+                class="pharmacy-main__selection--icon"
110
+                *ngIf="printPharmacyLoad"
111
+              ></i
112
+              >查看更多
113
+            </div>
114
+          </div> -->
115
+        </div>
116
+        <div
117
+          *ngIf="loading1"
118
+          style="height: calc(100vh - 212px); min-height: 556px"
119
+        >
120
+          <div
121
+            class="loadingFull display_flex justify-content_flex-center align-items_center"
122
+          >
123
+            <div class="loadingFullInner">
124
+              <img src="../../../assets/images/loading.gif" alt="" />
125
+              <div>加载中...</div>
126
+            </div>
127
+          </div>
128
+        </div>
129
+      </overlay-scrollbars>
130
+      <!-- 列表 end -->
131
+    </div>
132
+
133
+    <!-- 标本间标本 start -->
134
+    <div class="pharmacy-main__list pharmacy-main__waitDelivery">
135
+      <!-- 标题 start -->
136
+      <div class="pharmacy-main__title">
137
+        <strong>标本间标本</strong>
138
+        <span class="autoUpdate">{{ logTime }}秒</span>
139
+      </div>
140
+      <!-- 标题 end -->
141
+      <!-- 搜索框 start -->
142
+      <div class="pharmacy-main__search">
143
+        <div class="pharmacy-main__searchInput">
144
+          <input
145
+            nz-input
146
+            placeholder="请输入关键字"
147
+            [(ngModel)]="waitPharmacySearchKey"
148
+          />
149
+          <div class="pharmacy-main__searchText" (click)="searchKeyHandle('take')">
150
+            <i nz-icon nzType="search"></i>
151
+            <span>搜索</span>
152
+          </div>
153
+        </div>
154
+      </div>
155
+      <!-- 搜索框 end -->
156
+      <!-- 列表 start -->
157
+      <overlay-scrollbars #osComponentRef2 class="pharmacy-main__selectionWrap">
158
+        <div *ngIf="!loading2" style="height: 100%">
159
+          <div
160
+            (click)="showOrderList(item)"
161
+            class="pharmacy-main__selection"
162
+            *ngFor="let item of waitPharmacyList; let i = index"
163
+          >
164
+            <div class="pharmacy-main__selectionInfo">
165
+              <div class="pharmacy-main__selectionItem">
166
+                <span title="执行人姓名">{{item.userName || '无'}}</span>
167
+                <span title="工单数量">{{item.orderNum || '无'}}</span>
168
+              </div>
169
+            </div>
170
+          </div>
171
+          <div
172
+            class="pharmacy-main__selection pharmacy-main__selection--noData"
173
+            *ngIf="waitPharmacyList.length === 0"
174
+          >
175
+            <img src="./../../assets/images/image_kongbaiye.png" alt="" />
176
+          </div>
177
+          <!-- <div
178
+            (click)="loadMore(2)"
179
+            class="pharmacy-main__selection pharmacy-main__selection--more"
180
+            *ngIf="waitPharmacyFlag"
181
+          >
182
+            <div class="pharmacy-main__selectionInfo">
183
+              <i
184
+                nz-icon
185
+                nzType="loading"
186
+                nzTheme="outline"
187
+                class="pharmacy-main__selection--icon"
188
+                *ngIf="waitPharmacyLoad"
189
+              ></i
190
+              >查看更多
191
+            </div>
192
+          </div> -->
193
+        </div>
194
+        <div
195
+          *ngIf="loading2"
196
+          style="height: calc(100vh - 212px); min-height: 556px"
197
+        >
198
+          <div
199
+            class="loadingFull display_flex justify-content_flex-center align-items_center"
200
+          >
201
+            <div class="loadingFullInner">
202
+              <img src="../../../assets/images/loading.gif" alt="" />
203
+              <div>加载中...</div>
204
+            </div>
205
+          </div>
206
+        </div>
207
+      </overlay-scrollbars>
208
+      <!-- 列表 end -->
209
+    </div>
210
+
211
+    <!-- 今日离科标本 start -->
212
+    <div class="pharmacy-main__list pharmacy-main__delivery">
213
+      <!-- 标题 start -->
214
+      <div class="pharmacy-main__title">
215
+        <strong>今日离科标本</strong>
216
+        <span class="autoUpdate">{{ logTime }}秒</span>
217
+      </div>
218
+      <!-- 标题 end -->
219
+      <!-- 搜索框 start -->
220
+      <div class="pharmacy-main__search">
221
+        <div class="pharmacy-main__searchInput">
222
+          <input
223
+            nz-input
224
+            placeholder="请输入关键字"
225
+            [(ngModel)]="pharmacySearchKey"
226
+          />
227
+          <div class="pharmacy-main__searchText" (click)="searchKeyHandle('trans')">
228
+            <i nz-icon nzType="search"></i>
229
+            <span>搜索</span>
230
+          </div>
231
+        </div>
232
+      </div>
233
+      <!-- 搜索框 end -->
234
+      <!-- 列表 start -->
235
+      <overlay-scrollbars #osComponentRef3 class="pharmacy-main__selectionWrap">
236
+        <div *ngIf="!loading3" style="height: 100%">
237
+          <div
238
+            (click)="showSpeList(item)"
239
+            class="pharmacy-main__selection"
240
+            *ngFor="let item of pharmacyList; let i = index"
241
+          >
242
+            <div class="pharmacy-main__selectionInfo">
243
+              <div class="pharmacy-main__selectionItem">
244
+                <span title="检验科室名称" class="moreContent left">{{item.check_dept || '无'}}</span>
245
+                <span title="配送标本数量">{{item.count || '无'}}</span>
246
+              </div>
247
+            </div>
248
+          </div>
249
+          <div
250
+            class="pharmacy-main__selection pharmacy-main__selection--noData"
251
+            *ngIf="pharmacyList.length === 0"
252
+          >
253
+            <img src="./../../assets/images/image_kongbaiye.png" alt="" />
254
+          </div>
255
+          <!-- <div
256
+            (click)="loadMore(3)"
257
+            class="pharmacy-main__selection pharmacy-main__selection--more"
258
+            *ngIf="pharmacyFlag"
259
+          >
260
+            <div class="pharmacy-main__selectionInfo">
261
+              <i
262
+                nz-icon
263
+                nzType="loading"
264
+                nzTheme="outline"
265
+                class="pharmacy-main__selection--icon"
266
+                *ngIf="pharmacyLoad"
267
+              ></i
268
+              >查看更多
269
+            </div>
270
+          </div> -->
271
+        </div>
272
+        <div
273
+          *ngIf="loading3"
274
+          style="height: calc(100vh - 212px); min-height: 556px"
275
+        >
276
+          <div
277
+            class="loadingFull display_flex justify-content_flex-center align-items_center"
278
+          >
279
+            <div class="loadingFullInner">
280
+              <img src="../../../assets/images/loading.gif" alt="" />
281
+              <div>加载中...</div>
282
+            </div>
283
+          </div>
284
+        </div>
285
+      </overlay-scrollbars>
286
+      <!-- 列表 end -->
287
+    </div>
288
+  </div>
289
+  <!-- 主体部分 end -->
290
+  <router-outlet></router-outlet>
291
+</div>
292
+
293
+<!-- 药房端科室切换提示框 -->
294
+<app-hs-prompt-modal
295
+  [changeShow]="changeShow"
296
+  [closeTime]="closeTime"
297
+  [closeTimeFlag]="closeTimeFlag"
298
+  [show]="hsPromptModalShow"
299
+  (closeModelHs)="closeModelHs($event)"
300
+  (clearModelHs)="clearModelHs($event)"
301
+  deptType="pharmacy"
302
+> 
303
+  <!-- 返回系统按钮 -->
304
+  <!-- 右侧悬浮框 -->
305
+   <div id="fixedMenu" class="fixed" *ngIf="mainRole">
306
+    <div class="right">
307
+      <div class="fixedMenu hujiaozhongxin">
308
+        <div class="menuItems">
309
+          <div class="item">快捷菜单</div>
310
+        </div>
311
+      </div>
312
+      <div class="fixedMenu">
313
+        <div class="menuItems">
314
+          <div
315
+            class="others"
316
+            [ngStyle]="{
317
+              height: showLastItems
318
+                ? mainRole
319
+                  ? 35 * 2 + 'px'
320
+                  : 35 * 1 + 'px'
321
+                : 0
322
+            }"
323
+          >
324
+            <div
325
+              [ngClass]="{ item: true, checked: fixedTab == 'back' }"
326
+              *ngIf="mainRole"
327
+              (click)="checkFixedTab('toSystem')"
328
+            >
329
+              返回系统
330
+            </div>
331
+          </div>
332
+        </div>
333
+        <div class="arrow" *ngIf="!showLastItems" (click)="fixedMenuXiala()">
334
+          <i class="icon_transport transport-xiala2-01"></i>
335
+        </div>
336
+        <div class="arrow" *ngIf="showLastItems" (click)="fixedMenuShangla()">
337
+          <i class="icon_transport transport-shangla-"></i>
338
+        </div>
339
+      </div>
340
+    </div>
341
+    <div
342
+      *ngIf="showLastItems && fixedTab != ''"
343
+      (click)="fixedMenuShangla()"
344
+      class="fixedMark"
345
+    ></div>
346
+  </div>
347
+</app-hs-prompt-modal>
348
+
349
+<!-- 标本历史记录查看 -->
350
+<app-history-prompt-modal
351
+  *ngIf="logPromptModalShow"
352
+  [show]="logPromptModalShow"
353
+  [scode]="scode"
354
+  (closeModelHs)="closeModelLog($event)"
355
+></app-history-prompt-modal>
356
+
357
+<!-- 标本列表查看 -->
358
+<app-spe-prompt-modal
359
+  *ngIf="spePromptModalShow"
360
+  [show]="spePromptModalShow"
361
+  [checkDeptId]="checkDeptId"
362
+  [pharmacySearchKey]="pharmacySearchKey"
363
+  [printDate]="printDate"
364
+  (closeModelHs)="closeModelSpe($event)"
365
+></app-spe-prompt-modal>
366
+
367
+<!-- 工单列表查看 -->
368
+<app-order-prompt-modal
369
+  *ngIf="orderPromptModalShow"
370
+  [show]="orderPromptModalShow"
371
+  [workId]="workId"
372
+  (closeModelHs)="closeModelOrder($event)"
373
+></app-order-prompt-modal>
374
+
375
+<!-- 关联标本/手术室 -->
376
+<div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="relevanceModal">
377
+	<div class="modalBody">
378
+		<div class="title">关联科室</div>
379
+		<overlay-scrollbars #osComponentRef1 class="content">
380
+		 <form nz-form [formGroup]="validateForm" class="addForm" (ngSubmit)="submitForm()">
381
+			<nz-form-item>
382
+				<nz-form-label nzRequired nzFor="specimen" [nzSm]="5" [nzXs]="24">关联标本间</nz-form-label>
383
+				<nz-form-control nzErrorTip="请选择标本间!" [nzSm]="19" [nzXs]="24">
384
+					<nz-input-group>
385
+						<nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择标本间" formControlName="specimen">
386
+							<ng-container *ngFor="let option of specimenData">
387
+								<nz-option *ngIf="!isDeptLoading" [nzLabel]="option.dept" [nzValue]="option.id"></nz-option>
388
+							</ng-container>
389
+							<nz-option *ngIf="isDeptLoading" nzDisabled nzCustomContent>
390
+								<i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
391
+							</nz-option>
392
+						</nz-select>
393
+					</nz-input-group>
394
+				</nz-form-control>
395
+			</nz-form-item>
396
+			
397
+			<nz-form-item>
398
+				<nz-form-label nzRequired nzFor="operation" [nzSm]="5" [nzXs]="24">关联手术间</nz-form-label>
399
+				<nz-form-control nzErrorTip="请选择手术间!" [nzSm]="19" [nzXs]="24">
400
+					<nz-input-group>
401
+						<nz-select class="formItem" nzMode="multiple" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择请选择手术间" formControlName="operation">
402
+							<ng-container *ngFor="let option of operationData">
403
+								<nz-option *ngIf="!isDeptLoading" [nzLabel]="option.dept" [nzValue]="option.id"></nz-option>
404
+							</ng-container>
405
+							<nz-option *ngIf="isDeptLoading" nzDisabled nzCustomContent>
406
+								<i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
407
+							</nz-option>
408
+						</nz-select>
409
+					</nz-input-group>
410
+				</nz-form-control>
411
+			</nz-form-item>
412
+			
413
+			<nz-form-item>
414
+				<nz-form-label nzRequired nzFor="generate">标本是否直接生成配送单</nz-form-label>
415
+				<nz-form-control nzErrorTip="请选择!">
416
+					<nz-radio-group formControlName="generate">
417
+						<label nz-radio [nzValue]="1">是</label>
418
+						<label nz-radio [nzValue]="0">否</label>
419
+					</nz-radio-group>
420
+				</nz-form-control>
421
+			</nz-form-item>
422
+		 </form>
423
+		</overlay-scrollbars>
424
+		<div class="display_flex justify-content_flex-center">
425
+			<button class="btn" nz-button nzType="primary" (click)="submitForm()" [nzLoading]="btnLoading">确定</button>
426
+		</div>
427
+	</div>
428
+</div>
429
+
430
+
431
+<!-- 标本接收 -->
432
+<div class="pathology-box display_flex align-items_center justify-content_flex-center" *ngIf="fixationModal">
433
+	<div class="pathology-content">
434
+		<div class="title">标本接收固定
435
+		<i class="icon_transport transport-guanbi" (click)="hideSpecimenModal()"></i></div>
436
+		<div class="content">
437
+			<div class="content-item boder-right">
438
+				<div class="form-title-box">
439
+					<div class="form-title"><span class="font-weight-500">是否术中快速:</span>是</div>
440
+				</div>
441
+				<div class="form-title-box">
442
+					<div class="form-title"><span class="font-weight-500">申请单编号:</span>1008611</div>
443
+					<div class="form-title"><span class="font-weight-500">状态:</span>未打印</div>
444
+				</div>
445
+				<div class="form-title-box">
446
+					<div class="form-title"><span class="font-weight-500">科室名称:</span>科室111</div>
447
+					<div class="form-title"><span class="font-weight-500">住院号:</span>008622</div>
448
+				</div>
449
+				<div class="form-title-box">
450
+					<div class="form-title"><span class="font-weight-500">患者信息:</span>张三</div>
451
+					<div class="form-title"><span class="font-weight-500">年龄:</span>18</div>
452
+				</div>
453
+				<div class="form-list">
454
+					<div class="form-title font-weight-500">诊断:</div>
455
+					<div>
456
+						<div>1.有病</div>
457
+						<div>2.有病</div>
458
+					</div>
459
+				</div>
460
+				
461
+				<div class="form-list">
462
+					<div class="form-title font-weight-500">病理摘要:</div>
463
+					<div>患者因“胆囊息肉4月余”于2024-08-05入院。
464
+					患者4月前我院彩超提示胆囊息肉,大小约1.3*cds  0.7cm,无腹痛腹胀,无恶心呕吐,无发热,无胸闷、无返酸,无呕血、黑便,无腹泻,无尿频、尿急、尿痛。未进一步处理,今患者再次来我院,要求进一步治疗住院,</div>
465
+				</div>
466
+				<div class="form-list">
467
+					<div class="form-title font-weight-500">手术方案:</div>
468
+					<div>患者因“胆囊息肉4月余”于2024-08-05入院。
469
+					患者4月前我院彩超提示胆囊息肉,大小约1.3*cds  0.7cm,无腹痛腹胀,无恶心呕吐,无发热,无胸闷、无返酸,无呕血、黑便,无腹泻,无尿频、尿急、尿痛。未进一步处理,今患者再次来我院,要求进一步治疗住院,</div>
470
+				</div>
471
+				<div class="form-list">
472
+					<div class="form-title font-weight-500">术中所见:</div>
473
+					<div>患者因“胆囊息肉4月余”于2024-08-05入院。
474
+					患者4月前我院彩超提示胆囊息肉,大小约1.3*cds  0.7cm,无腹痛腹胀,无恶心呕吐,无发热,无胸闷、无返酸,无呕血、黑便,无腹泻,无尿频、尿急、尿痛。未进一步处理,今患者再次来我院,要求进一步治疗住院,</div>
475
+				</div>
476
+				<div class="form-title-box">
477
+					<div class="form-title"><span class="font-weight-500">标本类型:</span>张三</div>
478
+					<div class="form-title"><span class="font-weight-500">标本件数:</span>18</div>
479
+					<div class="form-title"><span class="font-weight-500">采取部位:</span>张三</div>
480
+				</div>
481
+				<div class="form-title-box">
482
+					<div class="form-title"><span class="font-weight-500">取标本位置:</span>张三</div>
483
+					<div class="form-title"><span class="font-weight-500">取材医生:</span>18</div>
484
+				</div>
485
+				<div class="form-list">
486
+					<div class="form-title font-weight-500">标本:</div>
487
+					<div>标本1</div>
488
+					<div>标本2</div>
489
+				</div>
490
+			</div>
491
+			
492
+			<div class="content-item">
493
+				<div class="center">提示:申请单含2只标本,已扫1只,请继续扫描标本。</div>
494
+				<div class="disp-fl">
495
+					<div class="width-120">标本条码:</div>
496
+					<!-- <nz-input-group autofocus> -->
497
+						<input nz-input id="specimen" [(ngModel)]="specimenCode" />
498
+					<!-- </nz-input-group> -->
499
+				</div>
500
+				<div class="list-template">
501
+				  <div class="list-template__content">
502
+						<div class="list-template__bottom" style="padding: 0 !important;">
503
+							<nz-table class="list-template__nzTable" [nzData]="listOfData" nzSize="middle" [nzShowPagination]="false"
504
+								[nzLoading]="loading1">
505
+								<thead>
506
+									<tr class="thead">
507
+										<th nzWidth="10%">序号</th>
508
+										<th>条码号</th>
509
+										<th>标本名称</th>
510
+									</tr>
511
+								</thead>
512
+								<tbody>
513
+									<tr *ngFor="let data of listOfData let index = index">
514
+										<td>{{index+1}}</td>
515
+										<td>{{ data.code}}</td>
516
+										<td>{{ data.name}}</td>
517
+									</tr>
518
+								</tbody>
519
+							</nz-table>
520
+						</div>
521
+					</div>
522
+				</div>
523
+			</div>
524
+		</div>
525
+		<div class="display_flex justify-content_flex-center bottom-btn">
526
+			<button class="btn btn-right" nz-button nzType="primary" (click)="submitFixationForm()" [nzLoading]="btnLoading">确定</button>
527
+			<button class="btn cancel" nz-button nzType="default" (click)="hideSpecimenModal()">取消</button>
528
+		</div>
529
+	</div>
530
+</div>
531
+
532
+<!-- 操作成功/失败提示框 -->
533
+<app-prompt-modal *ngIf="promptModalShow" [content]="promptContent" [success]="ifSuccess" [show]="promptModalShow"
534
+  [info]="promptInfo" (closeModel)="closeModel"></app-prompt-modal>
535
+	
536
+<!-- 标本核验 -->
537
+<div class="save add display_flex align-items_center justify-content_flex-center" *ngIf="verificationMoadl">
538
+	<div class="modalBody no-width">
539
+		<div class="title">标本核验<i class="icon_transport transport-guanbi" (click)="hideVerificationModal()"></i>
540
+		</div>
541
+		<div class="content">
542
+			<form nz-form [formGroup]="validateVerificationForm" class="addForm" (ngSubmit)="submitVerificationForm()">
543
+				<nz-form-item>
544
+				  <nz-form-label nzRequired [nzSpan]="6" nzFor="time">固定时间</nz-form-label>
545
+				  <nz-form-control [nzSpan]="18" nzErrorTip="请选择固定时间!">
546
+				    <nz-input-group>
547
+							<nz-date-picker formControlName="time" 
548
+							[nzShowTime]="{ nzFormat: 'yyyy-MM-dd HH:mm:ss' }" nzFormat="yyyy-MM-dd HH:mm:ss"
549
+							(ngModelChange)="formChangeDate($event)"></nz-date-picker>
550
+						</nz-input-group>
551
+				  </nz-form-control>
552
+				</nz-form-item>
553
+				<nz-form-item>
554
+				  <nz-form-label nzRequired [nzSpan]="6" nzFor="jobNumber">工号</nz-form-label>
555
+					<nz-form-control [nzSpan]="18" nzErrorTip="请输入工号!">
556
+						<input nz-input (input)="numberChange($event)" formControlName="jobNumber" placeholder="请输入工号" nzSize="default" />
557
+					</nz-form-control>
558
+				</nz-form-item>
559
+				<nz-form-item>
560
+				  <nz-form-label nzRequired [nzSpan]="6" nzFor="name">姓名</nz-form-label>
561
+					<nz-form-control [nzSpan]="18" nzErrorTip="请输入姓名!">
562
+						<input nz-input disabled formControlName="name" placeholder="请输入姓名" nzSize="default" />
563
+					</nz-form-control>
564
+				</nz-form-item>
565
+				<nz-form-item>
566
+				  <nz-form-label nzRequired [nzSpan]="8" nzFor="fixative">固体液类型</nz-form-label>
567
+				  <nz-form-control [nzSpan]="16" nzErrorTip="请选择固体液类型!">
568
+				    <nz-input-group>
569
+							<nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择固体液类型" formControlName="fixative">
570
+							  <ng-container *ngFor="let option of fixativeData">
571
+							    <nz-option *ngIf="!isDeptLoading" [nzLabel]="option.dept" [nzValue]="option.id"></nz-option>
572
+							  </ng-container>
573
+							  <nz-option *ngIf="isDeptLoading" nzDisabled nzCustomContent>
574
+							    <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
575
+							  </nz-option>
576
+							</nz-select>
577
+						</nz-input-group>
578
+				  </nz-form-control>
579
+				</nz-form-item>
580
+			</form>
581
+		</div>
582
+		<div class="display_flex justify-content_flex-center bottom-btn">
583
+			<button class="btn btn-right" nz-button nzType="primary" (click)="submitVerificationForm()" [nzLoading]="btnLoading">确定</button>
584
+			<button class="btn cancel" nz-button nzType="default" (click)="hideVerificationModal()">取消</button>
585
+		</div>
586
+	</div>
587
+</div>

+ 741 - 0
src/app/views/specimen-room-view/specimen-room-view.component.less

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

+ 677 - 0
src/app/views/specimen-room-view/specimen-room-view.component.ts

@@ -0,0 +1,677 @@
1
+import { Component, OnInit, ViewChild, OnDestroy } from "@angular/core";
2
+import { MainService } from "../../services/main.service";
3
+import { Router } from "@angular/router";
4
+import { OverlayScrollbarsComponent } from "overlayscrollbars-ngx";
5
+import { startOfDay, format, endOfDay } from "date-fns";
6
+import { ToolService } from 'src/app/services/tool.service';
7
+import {
8
+  FormBuilder,
9
+  Validators,
10
+  FormGroup,
11
+  FormControl,
12
+} from "@angular/forms";
13
+
14
+@Component({
15
+  selector: "app-specimen-room-view",
16
+  templateUrl: "./specimen-room-view.component.html",
17
+  styleUrls: ["./specimen-room-view.component.less"],
18
+})
19
+export class SpecimenRoomViewComponent implements OnInit, OnDestroy {
20
+  @ViewChild("osComponentRef1", {
21
+    read: OverlayScrollbarsComponent,
22
+    static: false,
23
+  })
24
+  osComponentRef1: OverlayScrollbarsComponent;
25
+  @ViewChild("osComponentRef2", {
26
+    read: OverlayScrollbarsComponent,
27
+    static: false,
28
+  })
29
+  osComponentRef2: OverlayScrollbarsComponent;
30
+  @ViewChild("osComponentRef3", {
31
+    read: OverlayScrollbarsComponent,
32
+    static: false,
33
+  })
34
+  osComponentRef3: OverlayScrollbarsComponent;
35
+  @ViewChild("osComponentRef4", {
36
+    read: OverlayScrollbarsComponent,
37
+    static: false,
38
+  })
39
+  osComponentRef4: OverlayScrollbarsComponent;
40
+  @ViewChild("osComponentRef5", {
41
+    read: OverlayScrollbarsComponent,
42
+    static: false,
43
+  })
44
+  osComponentRef5: OverlayScrollbarsComponent;
45
+  constructor(
46
+	private mainService: MainService, 
47
+	public router: Router, 
48
+	public tool: ToolService,
49
+	private fb: FormBuilder,
50
+	) {}
51
+  // 今日药单量
52
+  todayTotal: undefined;
53
+  // 今日已完成
54
+  todayComplete: undefined;
55
+  //待配药数据
56
+  // 待配药
57
+  printPharmacyList = [
58
+		{
59
+			code:'222',
60
+			name:'张珊',
61
+			bw:'肺部',
62
+			bbs:'8',
63
+			ssj:'手术间5',
64
+			time:'08-15 10:00'
65
+		},
66
+		{
67
+			code:'222',
68
+			name:'张珊',
69
+			bw:'肺部',
70
+			bbs:'8',
71
+			ssj:'手术间5',
72
+			time:'08-15 10:00'
73
+		},
74
+	]; //数据列表
75
+  printPharmacyIdx = 0; //页码
76
+  printPharmacyTotal = 0; //总数
77
+  printPharmacyFlag = false; //是否查看更多
78
+  printPharmacySearchKey = ""; //搜索的内容
79
+  printPharmacyLoad = false; //按钮的loading
80
+  // 配药中列表
81
+  waitPharmacyList = [];
82
+  waitPharmacyIdx = 0;
83
+  waitPharmacyTotal = 0;
84
+  waitPharmacyFlag = false;
85
+  waitPharmacySearchKey = "";
86
+  waitPharmacyLoad = false;
87
+  // 核对中列表
88
+  pharmacyList = [];
89
+  pharmacyIdx = 0;
90
+  pharmacyTotal = 0;
91
+  pharmacyFlag = false;
92
+  pharmacySearchKey = "";
93
+  pharmacyLoad = false;
94
+  // 配送中列表
95
+  distributionList = [];
96
+  distributionIdx = 0;
97
+  distributionTotal = 0;
98
+  distributionFlag = false;
99
+  distributionSearchKey = "";
100
+  distributionLoad = false;
101
+  // 已完成列表
102
+  completedList = [];
103
+  completedIdx = 0;
104
+  completedTotal = 0;
105
+  completedFlag = false;
106
+  completedSearchKey = "";
107
+  completedLoad = false;
108
+	
109
+	barCode:any; //条码搜索
110
+  // other
111
+  loginUser: any = localStorage.getItem("user")
112
+    ? JSON.parse(localStorage.getItem("user")).user
113
+    : null; //登录人信息
114
+
115
+  logTimer = null; //定时器
116
+  logTime = 0; //自动刷新秒数
117
+  logTimeConst = 60; //自动刷新秒数
118
+
119
+  time = new Date().getTime(); // 时间戳
120
+  timer = null; // 时间定时器
121
+	relevanceModal:boolean = false //关联标本和手术室
122
+	validateForm: FormGroup; //关联标本和手术室表单
123
+	validateVerificationForm: FormGroup; //核验标本
124
+	specimenData:any = []; //标本间数据
125
+	operationData:any = []; //手术间数据
126
+	fixationModal:boolean = false //标本接收固定
127
+	verificationMoadl:boolean = false //标本核验
128
+	specimenCode:any; //标本条码
129
+	listOfData:any=[
130
+		{
131
+			code:'222',
132
+			name:'张珊',
133
+		},
134
+	]; 
135
+	fixativeData:any = []; //固体液类型
136
+  ngOnDestroy() {
137
+    clearTimeout(this.timer);
138
+    clearTimeout(this.logTimer);
139
+  }
140
+
141
+  ngOnInit() {
142
+    this.runTime();
143
+    // 统计
144
+    this.total();
145
+		
146
+		this.setSpecimen()
147
+    // 切换科室
148
+    // this.changeKs();
149
+    // 手术间列表
150
+    // this.getPharmacyList(this.printPharmacyIdx, 'delegation', this.printPharmacySearchKey);
151
+    // // 标本间列表
152
+    // this.getPharmacyList(this.waitPharmacyIdx, 'take', this.waitPharmacySearchKey);
153
+    // // 今日离科标本列表
154
+    // this.getPharmacyList(this.pharmacyIdx, 'trans', this.pharmacySearchKey);
155
+
156
+    this.initRole();
157
+    // 自动刷新倒计时 start
158
+    this.autoUpdate();
159
+    // 自动刷新倒计时 end
160
+  }
161
+  // 当前时间日期
162
+  runTime() {
163
+    clearTimeout(this.timer);
164
+    this.timer = setTimeout(() => {
165
+      this.time = Date.now();
166
+      this.runTime();
167
+    }, 500);
168
+  }
169
+	
170
+	// 标本搜索
171
+	searchSpecimen(){
172
+		this.fixationModal = true
173
+		setTimeout(_=>{
174
+			document.getElementById('specimen').focus();
175
+		},200)
176
+	}
177
+	
178
+	// 确定接受固定标本
179
+	startDate:any;
180
+	submitFixationForm(){
181
+		this.validateVerificationForm = this.fb.group({
182
+		  time: [null, [Validators.required]],
183
+			jobNumber: [null, [Validators.required]],
184
+			name:[null, [Validators.required]],
185
+			immobilization:[null, [Validators.required]],
186
+		});
187
+		let date = new Date();
188
+		this.startDate = format(date, "yyyy-MM-dd HH:mm:ss")
189
+		this.validateVerificationForm.controls.time.setValue(this.startDate);
190
+		this.verificationMoadl = true
191
+		// this.fixationModal = false
192
+	}
193
+	
194
+	// 关闭接受固定标本
195
+	hideSpecimenModal(){
196
+		this.fixationModal = false
197
+	}
198
+	
199
+	// 获取是否关联标本间
200
+	setSpecimen(){
201
+		this.validateForm = this.fb.group({
202
+		  specimen: [null, [Validators.required]],
203
+			operation: [null, [Validators.required]],
204
+			generate:[null, [Validators.required]],
205
+		});
206
+		this.relevanceModal = true
207
+	}
208
+	
209
+	submitForm(){
210
+		// for (const i in that.validateForm.controls) {
211
+		//   that.validateForm.controls[i].markAsDirty();
212
+		//   that.validateForm.controls[i].updateValueAndValidity();
213
+		// }
214
+		// if (that.validateForm.invalid) return;
215
+		this.relevanceModal = false
216
+	}
217
+	
218
+	// 输入工号查询姓名
219
+	numberChange(e){
220
+		
221
+	}
222
+	
223
+	// 提交固定标本接收
224
+	submitVerificationForm(){
225
+		// for (const i in that.validateForm.controls) {
226
+		//   that.validateForm.controls[i].markAsDirty();
227
+		//   that.validateForm.controls[i].updateValueAndValidity();
228
+		// }
229
+		// if (that.validateForm.invalid) return;
230
+		this.hideVerificationModal()
231
+	}
232
+	hideVerificationModal(){
233
+		this.verificationMoadl = false
234
+	}
235
+  // 统计
236
+  total() {
237
+    let launch = JSON.parse(localStorage.getItem("user")).user.dept.id;
238
+    let startTime = format(startOfDay(new Date()), "yyyy-MM-dd HH:mm:ss");
239
+    let endTime = format(endOfDay(new Date()), "yyyy-MM-dd HH:mm:ss");
240
+    let postData = {
241
+      startTime,
242
+      endTime,
243
+      launch,
244
+    };
245
+
246
+    this.mainService.getDrugsBagStateCount(postData).subscribe((res: any) => {
247
+      if (res.status == 200) {
248
+        this.todayTotal = res.countMap.todayTotal;
249
+        this.todayComplete = res.countMap.todayComplete;
250
+      }
251
+    });
252
+  }
253
+  // 查看工单详情
254
+  goToOrderDetail(item){
255
+    console.log(item);
256
+    this.router.navigateByUrl(`specimenView2/detailSample/${item.id}`);
257
+  }
258
+	// 查看详情
259
+	viewDetail(item){
260
+		
261
+	}
262
+	
263
+  // 查看流程信息弹窗
264
+  logPromptModalShow = false; //弹窗开关
265
+  scode = ""; //查看记录携带
266
+  showLogs(data) {
267
+    clearInterval(this.logTimer);
268
+    this.scode = data.scode;
269
+    this.logPromptModalShow = true;
270
+  }
271
+  // 关闭流程信息弹窗
272
+  closeModelLog(e) {
273
+    this.logPromptModalShow = JSON.parse(e).show;
274
+    this.autoUpdate(false);
275
+  }
276
+  // 查看标本列表弹窗
277
+  spePromptModalShow = false; //弹窗开关
278
+  checkDeptId = ""; //检查科室id
279
+  printDate = ""; //采集日期
280
+  showSpeList(data) {
281
+    clearInterval(this.logTimer);
282
+    this.checkDeptId = data.check_dept_id;
283
+    this.printDate = data.startTime;
284
+    this.spePromptModalShow = true;
285
+  }
286
+  // 关闭标本列表弹窗
287
+  closeModelSpe(e) {
288
+    this.spePromptModalShow = JSON.parse(e).show;
289
+    this.autoUpdate(false);
290
+  }
291
+   // 查看工单列表弹窗
292
+   orderPromptModalShow = false; //弹窗开关
293
+   workId = ""; //配送人员ID
294
+   showOrderList(data) {
295
+     clearInterval(this.logTimer);
296
+     this.workId = data.workerid;
297
+     this.orderPromptModalShow = true;
298
+   }
299
+   // 关闭工单列表弹窗
300
+   closeModelOrder(e) {
301
+     this.orderPromptModalShow = JSON.parse(e).show;
302
+     this.autoUpdate(false);
303
+   }
304
+  // 自动刷新倒计时
305
+  autoUpdate(flag = true) {
306
+    if (flag) {
307
+      this.logTime = this.logTimeConst;
308
+    }
309
+    clearInterval(this.logTimer);
310
+    this.logTimer = setInterval(() => {
311
+      this.logTime--;
312
+      if (this.logTime === 0) {
313
+        this.logTime = this.logTimeConst;
314
+        // 代收急查标本(标本信息)列表
315
+        // this.getPharmacyList(0, 'delegation', this.printPharmacySearchKey);
316
+        // // 已收取(工单信息)列表
317
+        // this.getPharmacyList(0, 'take', this.waitPharmacySearchKey);
318
+        // // 中转标本(标本统计信息)列表
319
+        // this.getPharmacyList(0, 'trans', this.pharmacySearchKey);
320
+        // // 中转配送中(工单信息)列表
321
+        // this.getPharmacyList(0, 'trans_send', this.distributionSearchKey);
322
+        // // 异常标本(标本信息)列表
323
+        // this.getPharmacyList(0, 'error', this.completedSearchKey);
324
+      }
325
+    }, 1000);
326
+  }
327
+  // 药房端药房列表查询、搜索
328
+  // 1为pc待打印状态、2为pc配药中、3为pc核对中、4为pc配送中
329
+  // searchKey  为搜索的关键字,没有就不传
330
+  loading1 = false;
331
+  loading2 = false;
332
+  loading3 = false;
333
+  loading4 = false;
334
+  loading5 = false;
335
+  getPharmacyList(idx, type, searchKey) {
336
+    let hosId = JSON.parse(localStorage.getItem("user")).user.currentHospital.id;
337
+    switch (type) {
338
+      case 'delegation':
339
+        this.loading1 = true;
340
+        break;
341
+      case 'take':
342
+        this.loading2 = true;
343
+        break;
344
+      case 'trans':
345
+        this.loading3 = true;
346
+        break;
347
+      case 'trans_send':
348
+        this.loading4 = true;
349
+        break;
350
+      case 'error':
351
+        this.loading5 = true;
352
+        break;
353
+    }
354
+    let postData = {
355
+      viewType: type,
356
+      keyWord: searchKey,
357
+      hosId,
358
+    };
359
+    this.mainService
360
+      .specimenView2(postData)
361
+      .subscribe((result) => {
362
+        switch (type) {
363
+          case 'delegation':
364
+            this.loading1 = false;
365
+            break;
366
+          case 'take':
367
+            this.loading2 = false;
368
+            break;
369
+          case 'trans':
370
+            this.loading3 = false;
371
+            break;
372
+          case 'trans_send':
373
+            this.loading4 = false;
374
+            break;
375
+          case 'error':
376
+            this.loading5 = false;
377
+            break;
378
+        }
379
+        if (result["state"] == 200) {
380
+          switch (type) {
381
+            case 'delegation':
382
+              // 总数
383
+              this.printPharmacyTotal = result.totalNum;
384
+              // 隐藏按钮的loading
385
+              this.printPharmacyLoad = false;
386
+              // 查看更多,是否显示
387
+              if (result["data"].length < 10) {
388
+                this.printPharmacyFlag = false;
389
+              } else if (result["data"].length === 0 && idx === 0) {
390
+                this.printPharmacyFlag = false;
391
+              } else {
392
+                this.printPharmacyFlag = true;
393
+              }
394
+              // 列表数据合并
395
+              if (idx === 0) {
396
+                this.printPharmacyList = result["data"];
397
+              } else {
398
+                this.printPharmacyList = [
399
+                  ...this.printPharmacyList,
400
+                  ...result["data"],
401
+                ];
402
+              }
403
+              break;
404
+            case 'take':
405
+              this.waitPharmacyTotal = result.totalNum;
406
+              this.waitPharmacyLoad = false;
407
+              if (result["data"].length < 10) {
408
+                this.waitPharmacyFlag = false;
409
+              } else if (result["data"].length === 0 && idx === 0) {
410
+                this.waitPharmacyFlag = false;
411
+              } else {
412
+                this.waitPharmacyFlag = true;
413
+              }
414
+              if (idx === 0) {
415
+                this.waitPharmacyList = result["data"];
416
+              } else {
417
+                this.waitPharmacyList = [
418
+                  ...this.waitPharmacyList,
419
+                  ...result["data"],
420
+                ];
421
+              }
422
+              break;
423
+            case 'trans':
424
+              this.pharmacyTotal = result.totalNum;
425
+              this.pharmacyLoad = false;
426
+              if (result["data"].length < 10) {
427
+                this.pharmacyFlag = false;
428
+              } else if (result["data"].length === 0 && idx === 0) {
429
+                this.pharmacyFlag = false;
430
+              } else {
431
+                this.pharmacyFlag = true;
432
+              }
433
+              if (idx === 0) {
434
+                this.pharmacyList = result["data"];
435
+              } else {
436
+                this.pharmacyList = [...this.pharmacyList, ...result["data"]];
437
+              }
438
+              break;
439
+            case 'trans_send':
440
+              this.distributionTotal = result.totalNum;
441
+              this.distributionLoad = false;
442
+              if (result["data"].length < 10) {
443
+                this.distributionFlag = false;
444
+              } else if (result["data"].length === 0 && idx === 0) {
445
+                this.distributionFlag = false;
446
+              } else {
447
+                this.distributionFlag = true;
448
+              }
449
+              // 处理数据
450
+              result["data"].forEach(v=>{
451
+                v.deptList = v.deptList?v.deptList.join(','):'';
452
+              })
453
+              if (idx === 0) {
454
+                this.distributionList = result["data"];
455
+              } else {
456
+                this.distributionList = [
457
+                  ...this.distributionList,
458
+                  ...result["data"],
459
+                ];
460
+              }
461
+              break;
462
+            case 'error':
463
+              this.completedTotal = result.totalNum;
464
+              this.completedLoad = false;
465
+              if (result["data"].length < 10) {
466
+                this.completedFlag = false;
467
+              } else if (result["data"].length === 0 && idx === 0) {
468
+                this.completedFlag = false;
469
+              } else {
470
+                this.completedFlag = true;
471
+              }
472
+              if (idx === 0) {
473
+                this.completedList = result["data"];
474
+              } else {
475
+                this.completedList = [...this.completedList, ...result["data"]];
476
+              }
477
+              break;
478
+          }
479
+        }
480
+      });
481
+  }
482
+  // 加载更多
483
+  loadMore(type) {
484
+    switch (type) {
485
+      case 'delegation':
486
+        this.printPharmacyIdx++;
487
+        this.printPharmacyLoad = true;
488
+        this.getPharmacyList(
489
+          this.printPharmacyIdx,
490
+          type,
491
+          this.printPharmacySearchKey
492
+        );
493
+        break;
494
+      case 'take':
495
+        this.waitPharmacyIdx++;
496
+        this.waitPharmacyLoad = true;
497
+        this.getPharmacyList(
498
+          this.waitPharmacyIdx,
499
+          type,
500
+          this.waitPharmacySearchKey
501
+        );
502
+        break;
503
+      case 'trans':
504
+        this.pharmacyIdx++;
505
+        this.pharmacyLoad = true;
506
+        this.getPharmacyList(this.pharmacyIdx, type, this.pharmacySearchKey);
507
+        break;
508
+      case 'trans_send':
509
+        this.distributionIdx++;
510
+        this.distributionLoad = true;
511
+        this.getPharmacyList(
512
+          this.distributionIdx,
513
+          type,
514
+          this.distributionSearchKey
515
+        );
516
+        break;
517
+      case 'error':
518
+        this.completedIdx++;
519
+        this.completedLoad = true;
520
+        this.getPharmacyList(this.completedIdx, type, this.completedSearchKey);
521
+        break;
522
+    }
523
+  }
524
+  // 搜索关键词
525
+  searchKeyHandle(type) {
526
+    switch (type) {
527
+      case 'delegation':
528
+        this.printPharmacyIdx = 0; //页码重置
529
+        this.printPharmacyList = []; //列表重置
530
+        this.getPharmacyList(
531
+          this.printPharmacyIdx,
532
+          type,
533
+          this.printPharmacySearchKey
534
+        );
535
+        break;
536
+      case 'take':
537
+        this.waitPharmacyIdx = 0; //页码重置
538
+        this.waitPharmacyList = []; //列表重置
539
+        this.getPharmacyList(
540
+          this.waitPharmacyIdx,
541
+          type,
542
+          this.waitPharmacySearchKey
543
+        );
544
+        break;
545
+      case 'trans':
546
+        this.pharmacyIdx = 0; //页码重置
547
+        this.pharmacyList = []; //列表重置
548
+        this.getPharmacyList(this.pharmacyIdx, type, this.pharmacySearchKey);
549
+        break;
550
+      case 'trans_send':
551
+        this.distributionIdx = 0; //页码重置
552
+        this.distributionList = []; //列表重置
553
+        this.getPharmacyList(
554
+          this.distributionIdx,
555
+          type,
556
+          this.distributionSearchKey
557
+        );
558
+        break;
559
+      case 'error':
560
+        this.completedIdx = 0; //页码重置
561
+        this.completedList = []; //列表重置
562
+        this.getPharmacyList(this.completedIdx, type, this.completedSearchKey);
563
+        break;
564
+    }
565
+  }
566
+  // 退出
567
+  logOut(): void {
568
+    // 假退出
569
+    let hospital = this.tool.getCurrentHospital();
570
+    if(hospital){
571
+      this.router.navigate(["login", hospital.id]);
572
+    }else{
573
+      this.router.navigateByUrl("login");
574
+    }
575
+    localStorage.removeItem("user");
576
+    localStorage.removeItem("menu");
577
+    localStorage.removeItem("phones");
578
+    localStorage.removeItem("index");
579
+    // 假退出
580
+    this.mainService.logOut().subscribe((data) => {
581
+      if (data.status == 200) {
582
+        if(hospital){
583
+          this.router.navigate(["login", hospital.id]);
584
+        }else{
585
+          this.router.navigateByUrl("login");
586
+        }
587
+        localStorage.removeItem("user");
588
+        localStorage.removeItem("menu");
589
+        localStorage.removeItem("phones");
590
+        localStorage.removeItem("index");
591
+      }
592
+    });
593
+
594
+  }
595
+
596
+  // 右侧菜单
597
+  showLastItems: boolean = false;
598
+  // 下拉
599
+  fixedMenuXiala() {
600
+    this.showLastItems = true;
601
+  }
602
+
603
+  // 上拉
604
+  fixedMenuShangla() {
605
+    this.showLastItems = false;
606
+  }
607
+
608
+  mainRole: boolean = false; //回到系统管理权限
609
+  initRole() {
610
+    let menus = JSON.parse(localStorage.getItem("menu"));
611
+    console.log("菜单数量" + menus.length);
612
+    if (menus.length >= 2) {
613
+      this.mainRole = true;
614
+      return;
615
+    }
616
+  }
617
+
618
+  // 切换右侧菜单Tab
619
+  fixedTab: string = "";
620
+  checkFixedTab(type: string) {
621
+    if (type == "toSystem") {
622
+      this.router.navigateByUrl("main");
623
+    }
624
+    if (this.fixedTab == type) {
625
+      this.fixedTab = "";
626
+    } else {
627
+      this.fixedTab = type;
628
+    }
629
+  }
630
+  //药房端科室切换
631
+  changeShow = true;
632
+  closeTime = 3;
633
+  closeTimeFlag = 0;
634
+  hsPromptModalShow: boolean = false; //科室切换提示框是否展示
635
+  timerCloseTime = null;
636
+  deptDisplay = 1; //护士端是否显示可以别名,1是显示科室名称,2是显示科室别名
637
+  //子传父接收
638
+  closeModelHs(e) {
639
+    this.hsPromptModalShow = JSON.parse(e).show;
640
+    this.changeShow = JSON.parse(e).changeShow;
641
+  }
642
+  //子传父接收
643
+  clearModelHs(e) {
644
+    if (JSON.parse(e).clear === true) {
645
+      clearInterval(this.timerCloseTime);
646
+    }
647
+    this.changeShow = JSON.parse(e).changeShow;
648
+  }
649
+  // 头部切换科室
650
+  changeKsNow() {
651
+    this.hsPromptModalShow = true;
652
+    clearInterval(this.timerCloseTime);
653
+    this.changeShow = false;
654
+  }
655
+  // 切换科室
656
+  changeKs() {
657
+    this.hsPromptModalShow = true;
658
+    // (1)	当用户设置为正数时,用户必须查看此窗体指定秒数。
659
+    // (2)	当用户设置为负数时,用户可点击知道了也可倒计时自动关闭。
660
+    // (3)	如果用户填写0则为无自动关闭和强制查看时间。
661
+    if (this.closeTimeFlag === 0) {
662
+      return;
663
+    }
664
+    this.closeTime = Math.abs(this.closeTimeFlag);
665
+    clearInterval(this.timerCloseTime);
666
+    this.timerCloseTime = setInterval(() => {
667
+      this.closeTime = Math.max(--this.closeTime, 0);
668
+      if (this.closeTime === 0) {
669
+        if (this.closeTimeFlag <= 0) {
670
+          this.hsPromptModalShow = false;
671
+        }
672
+        clearInterval(this.timerCloseTime);
673
+      }
674
+    }, 1000);
675
+  }
676
+}
677
+

+ 17 - 0
src/app/views/specimen-room-view/specimen-room-view.module.ts

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