Browse Source

Merge branch 'lmm' into develop

seimin 3 years ago
parent
commit
7b38bc0446
32 changed files with 826 additions and 209 deletions
  1. 4 4
      package-lock.json
  2. 1 1
      package.json
  3. 1 1
      proxy.conf.json
  4. 4 0
      src/app/services/tool.service.ts
  5. 6 6
      src/app/share/appraise-detail/appraise-detail.component.html
  6. 1 1
      src/app/share/detail-patients/detail-patients.component.html
  7. 20 4
      src/app/share/hs-prompt-modal/hs-prompt-modal.component.html
  8. 11 17
      src/app/share/hs-prompt-modal/hs-prompt-modal.component.less
  9. 57 32
      src/app/share/hs-prompt-modal/hs-prompt-modal.component.ts
  10. 6 6
      src/app/share/order-detail/order-detail.component.html
  11. 12 0
      src/app/views/drug-search/drug-search-routing.module.ts
  12. 1 0
      src/app/views/drug-search/drug-search.component.html
  13. 0 0
      src/app/views/drug-search/drug-search.component.less
  14. 15 0
      src/app/views/drug-search/drug-search.component.ts
  15. 17 0
      src/app/views/drug-search/drug-search.module.ts
  16. 20 20
      src/app/views/fuwutai/fuwutai.component.html
  17. 3 3
      src/app/views/hushijiandan/hushijiandan.component.html
  18. 22 13
      src/app/views/hushijiandan/hushijiandan.component.ts
  19. 12 0
      src/app/views/jp-search/jp-search-routing.module.ts
  20. 80 0
      src/app/views/jp-search/jp-search.component.html
  21. 167 0
      src/app/views/jp-search/jp-search.component.less
  22. 128 0
      src/app/views/jp-search/jp-search.component.ts
  23. 17 0
      src/app/views/jp-search/jp-search.module.ts
  24. 14 0
      src/app/views/main/main-routing.module.ts
  25. 5 3
      src/app/views/main/main.component.ts
  26. 1 1
      src/app/views/office-management/office-management.component.html
  27. 4 1
      src/app/views/office-management/office-management.component.ts
  28. 72 25
      src/app/views/round-robin/round-robin.component.html
  29. 5 5
      src/app/views/round-robin/round-robin.component.less
  30. 114 52
      src/app/views/round-robin/round-robin.component.ts
  31. 2 1
      src/app/views/task-type-management/task-type-management.component.html
  32. 4 13
      src/app/views/task-type-management/task-type-management.component.ts

+ 4 - 4
package-lock.json

@@ -853,7 +853,7 @@
853
     },
853
     },
854
     "@types/zrender": {
854
     "@types/zrender": {
855
       "version": "4.0.0",
855
       "version": "4.0.0",
856
-      "resolved": "https://registry.nlark.com/@types/zrender/download/@types/zrender-4.0.0.tgz",
856
+      "resolved": "https://registry.npm.taobao.org/@types/zrender/download/@types/zrender-4.0.0.tgz",
857
       "integrity": "sha1-poBvEuxOzKrr2bDYFvBJrKYYj70=",
857
       "integrity": "sha1-poBvEuxOzKrr2bDYFvBJrKYYj70=",
858
       "dev": true
858
       "dev": true
859
     },
859
     },
@@ -2608,9 +2608,9 @@
2608
       }
2608
       }
2609
     },
2609
     },
2610
     "core-js": {
2610
     "core-js": {
2611
-      "version": "3.14.0",
2612
-      "resolved": "https://registry.nlark.com/core-js/download/core-js-3.14.0.tgz",
2613
-      "integrity": "sha1-YjIrmMccwgGLAnlxppQZ4kJcKmw="
2611
+      "version": "3.15.1",
2612
+      "resolved": "https://registry.nlark.com/core-js/download/core-js-3.15.1.tgz?cache=0&sync_timestamp=1624386897006&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fcore-js%2Fdownload%2Fcore-js-3.15.1.tgz",
2613
+      "integrity": "sha1-bAiriKvfVlRQRcz1/YH0f0B+fxo="
2614
     },
2614
     },
2615
     "core-util-is": {
2615
     "core-util-is": {
2616
       "version": "1.0.2",
2616
       "version": "1.0.2",

+ 1 - 1
package.json

@@ -24,7 +24,7 @@
24
     "@angular/router": "~8.1.1",
24
     "@angular/router": "~8.1.1",
25
     "@types/crypto-js": "^3.1.47",
25
     "@types/crypto-js": "^3.1.47",
26
     "@types/overlayscrollbars": "^1.9.0",
26
     "@types/overlayscrollbars": "^1.9.0",
27
-    "core-js": "^3.14.0",
27
+    "core-js": "^3.15.1",
28
     "crypto-js": "^4.0.0",
28
     "crypto-js": "^4.0.0",
29
     "datatables.net": "^1.10.25",
29
     "datatables.net": "^1.10.25",
30
     "date-fns": "^2.22.1",
30
     "date-fns": "^2.22.1",

+ 1 - 1
proxy.conf.json

@@ -1,6 +1,6 @@
1
 {
1
 {
2
   "/service": {
2
   "/service": {
3
-    "target": "http://192.168.3.108",
3
+    "target": "http://192.168.3.96",
4
     "logLevel": "debug",
4
     "logLevel": "debug",
5
     "changeOrigin": true,
5
     "changeOrigin": true,
6
     "pathRewrite": {
6
     "pathRewrite": {

+ 4 - 0
src/app/services/tool.service.ts

@@ -21,6 +21,10 @@ export class ToolService {
21
       ? JSON.parse(localStorage.getItem("user")).user.currentHospital
21
       ? JSON.parse(localStorage.getItem("user")).user.currentHospital
22
       : JSON.parse(localStorage.getItem("user")).infoPermission.hospitals[0];
22
       : JSON.parse(localStorage.getItem("user")).infoPermission.hospitals[0];
23
   }
23
   }
24
+  //获取当前用户科室
25
+  getCurrentUserDept() {
26
+    return JSON.parse(localStorage.getItem("user")).user.dept;
27
+  }
24
   //获取当前菜单的权限
28
   //获取当前菜单的权限
25
   initCoopBtns(route) {
29
   initCoopBtns(route) {
26
     let link;
30
     let link;

+ 6 - 6
src/app/share/appraise-detail/appraise-detail.component.html

@@ -8,7 +8,7 @@
8
       <div [ngClass]="{'item':true, 'flex_1':true, checked:tabType==3}" (click)="checkTab(3)">调解</div>
8
       <div [ngClass]="{'item':true, 'flex_1':true, checked:tabType==3}" (click)="checkTab(3)">调解</div>
9
     </div>
9
     </div>
10
     <!-- 其他类型工单信息 -->
10
     <!-- 其他类型工单信息 -->
11
-    <div *ngIf="(tabType==1)&&(orderInfo.workOrderObj.taskType.associationType.id==259)" class="content orders">
11
+    <div *ngIf="(tabType==1)&&(orderInfo.workOrderObj.taskType.associationType.value=='other')" class="content orders">
12
       <div class="top">
12
       <div class="top">
13
         <div class="num">
13
         <div class="num">
14
           <span class="left">单号:{{orderInfo.workOrderObj.gdcode}}</span>
14
           <span class="left">单号:{{orderInfo.workOrderObj.gdcode}}</span>
@@ -56,7 +56,7 @@
56
     </div>
56
     </div>
57
     <!-- 标本类型工单信息 -->
57
     <!-- 标本类型工单信息 -->
58
     <div
58
     <div
59
-      *ngIf="tabType==1&&(orderInfo.workOrderObj.taskType.associationType.id==256||orderInfo.workOrderObj.taskType.associationType.id==380)"
59
+      *ngIf="tabType==1&&(orderInfo.workOrderObj.taskType.associationType.value=='specimen'||orderInfo.workOrderObj.taskType.associationType.value=='specimenPlan')"
60
       class="content orders">
60
       class="content orders">
61
       <div class="top">
61
       <div class="top">
62
         <div class="num">
62
         <div class="num">
@@ -143,7 +143,7 @@
143
     </div>
143
     </div>
144
     <!-- 药品/静配配送类型工单信息 -->
144
     <!-- 药品/静配配送类型工单信息 -->
145
     <div
145
     <div
146
-      *ngIf="tabType==1&&(orderInfo.workOrderObj.taskType.associationType.id==257||orderInfo.workOrderObj.taskType.associationType.id==258)"
146
+      *ngIf="tabType==1&&(orderInfo.workOrderObj.taskType.associationType.value=='drugsBag'||orderInfo.workOrderObj.taskType.associationType.value=='jPBag')"
147
       class="content orders">
147
       class="content orders">
148
       <div class="top">
148
       <div class="top">
149
         <div class="num">
149
         <div class="num">
@@ -246,7 +246,7 @@
246
     </div>
246
     </div>
247
     <!-- 患者陪检/患者转运类型工单信息 -->
247
     <!-- 患者陪检/患者转运类型工单信息 -->
248
     <div
248
     <div
249
-      *ngIf="tabType==1&&(orderInfo.workOrderObj.taskType.associationType.id==260||orderInfo.workOrderObj.taskType.associationType.id==255)"
249
+      *ngIf="tabType==1&&(orderInfo.workOrderObj.taskType.associationType.value=='inspect'||orderInfo.workOrderObj.taskType.associationType.value=='patientTransport')"
250
       class="content orders">
250
       class="content orders">
251
       <div class="top">
251
       <div class="top">
252
         <div class="num">
252
         <div class="num">
@@ -304,7 +304,7 @@
304
                 <span class="label">床位</span>
304
                 <span class="label">床位</span>
305
                 <span>{{orderInfo.workOrderObj.patient.bedNum}}</span>
305
                 <span>{{orderInfo.workOrderObj.patient.bedNum}}</span>
306
               </p>
306
               </p>
307
-              <p *ngIf="orderInfo.workOrderObj.taskType.associationType.id==260">
307
+              <p *ngIf="orderInfo.workOrderObj.taskType.associationType.value=='inspect'">
308
                 <span class="label">检查项目</span>
308
                 <span class="label">检查项目</span>
309
                 <span>
309
                 <span>
310
                   <span *ngFor="let item of orderInfo.workOrderObj.checkList;let i = index;">
310
                   <span *ngFor="let item of orderInfo.workOrderObj.checkList;let i = index;">
@@ -323,7 +323,7 @@
323
                 <span class="label">携带物品</span>
323
                 <span class="label">携带物品</span>
324
                 <span>{{orderInfo.workOrderObj.goods}}</span>
324
                 <span>{{orderInfo.workOrderObj.goods}}</span>
325
               </p>
325
               </p>
326
-              <p *ngIf="orderInfo.workOrderObj.taskType.associationType.id==260">
326
+              <p *ngIf="orderInfo.workOrderObj.taskType.associationType.value=='inspect'">
327
                 <span class="label">预约时间</span>
327
                 <span class="label">预约时间</span>
328
                 <span>{{orderInfo.workOrderObj.yyTime?orderInfo.workOrderObj.yyTime:''}}</span>
328
                 <span>{{orderInfo.workOrderObj.yyTime?orderInfo.workOrderObj.yyTime:''}}</span>
329
               </p>
329
               </p>

+ 1 - 1
src/app/share/detail-patients/detail-patients.component.html

@@ -85,7 +85,7 @@
85
             </div>
85
             </div>
86
           </div>
86
           </div>
87
         </div>
87
         </div>
88
-        <ng-container *ngIf="orderInfo.taskType.associationType.id==260">
88
+        <ng-container *ngIf="orderInfo.taskType.associationType.value=='inspect'">
89
           <div class="info" *ngFor="let item of orderInfo.checkList">
89
           <div class="info" *ngFor="let item of orderInfo.checkList">
90
             <div nz-row class="top">
90
             <div nz-row class="top">
91
               <div nz-col nzSpan="8">
91
               <div nz-col nzSpan="8">

+ 20 - 4
src/app/share/hs-prompt-modal/hs-prompt-modal.component.html

@@ -2,7 +2,7 @@
2
   <div class="modalBody" *ngIf="changeShow">
2
   <div class="modalBody" *ngIf="changeShow">
3
     <div class="title">当前科室<i class="icon_transport transport-guanbi" (click)="hideModal()"></i></div>
3
     <div class="title">当前科室<i class="icon_transport transport-guanbi" (click)="hideModal()"></i></div>
4
     <div class="content">
4
     <div class="content">
5
-      <div class="defeat">{{currentDept}}</div>
5
+      <div class="defeat">{{currentDept.dept}}</div>
6
       <div class="countDown">关闭倒计时<em>{{closeTime}}s</em></div>
6
       <div class="countDown">关闭倒计时<em>{{closeTime}}s</em></div>
7
     </div>
7
     </div>
8
     <div class="display_flex justify-content_flex-center">
8
     <div class="display_flex justify-content_flex-center">
@@ -15,16 +15,32 @@
15
     <div class="content content-search">
15
     <div class="content content-search">
16
       <div class="defeat-search display_flex justify-content_flex-center flex-direction_column">
16
       <div class="defeat-search display_flex justify-content_flex-center flex-direction_column">
17
         <span>当前院区:<em>{{currentHospital.hosName}}</em></span>
17
         <span>当前院区:<em>{{currentHospital.hosName}}</em></span>
18
-        <span>当前科室:<em>{{currentDept}}</em></span>
18
+        <span>当前科室:<em>{{currentDept.dept}}</em></span>
19
       </div>
19
       </div>
20
       <div class="form">
20
       <div class="form">
21
         <form nz-form [formGroup]="validateForm">
21
         <form nz-form [formGroup]="validateForm">
22
+          <nz-form-item style="margin-bottom: 0;">
23
+            <nz-form-label class="label" [nzSm]="24" [nzXs]="24" nzRequired nzFor="hospital">搜索院区
24
+            </nz-form-label>
25
+            <nz-form-control class="control" [nzSm]="24" [nzXs]="24" nzErrorTip="请选择院区!">
26
+              <nz-select formControlName="hospital" [nzDropdownMatchSelectWidth]="false"
27
+                (ngModelChange)="searchHospital($event)" nzPlaceHolder="请选择院区">
28
+                <ng-container *ngFor="let option of hospitals">
29
+                  <nz-option *ngIf="!isLoading" [nzLabel]="option.hosName" [nzValue]="option.id"></nz-option>
30
+                </ng-container>
31
+                <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
32
+                  <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
33
+                </nz-option>
34
+              </nz-select>
35
+            </nz-form-control>
36
+          </nz-form-item>
22
           <nz-form-item>
37
           <nz-form-item>
23
-            <nz-form-label class="label" [nzSm]="24" [nzXs]="24" nzRequired nzFor="dutyDeptFc">搜索当值科室
38
+            <nz-form-label class="label" [nzSm]="24" [nzXs]="24" nzRequired nzFor="dutyDeptFc">搜索当值科室<span
39
+                class="red ml8">(可通过拼音首字母检索科室)</span>
24
             </nz-form-label>
40
             </nz-form-label>
25
             <nz-form-control class="control" [nzSm]="24" [nzXs]="24" nzErrorTip="请选择当值科室!">
41
             <nz-form-control class="control" [nzSm]="24" [nzXs]="24" nzErrorTip="请选择当值科室!">
26
               <nz-select formControlName="dutyDeptFc" [nzDropdownMatchSelectWidth]="false" nzServerSearch nzShowSearch
42
               <nz-select formControlName="dutyDeptFc" [nzDropdownMatchSelectWidth]="false" nzServerSearch nzShowSearch
27
-                (nzOnSearch)="searchDept($event)" nzAllowClear nzPlaceHolder="请选择当值科室" [(ngModel)]="dutyDept">
43
+                (nzOnSearch)="searchDept(validateForm.controls.hospital.value,$event)" nzPlaceHolder="请选择当值科室">
28
                 <ng-container *ngFor="let option of dutyDepts">
44
                 <ng-container *ngFor="let option of dutyDepts">
29
                   <nz-option *ngIf="!isLoading" [nzLabel]="option.dept" [nzValue]="option.id"></nz-option>
45
                   <nz-option *ngIf="!isLoading" [nzLabel]="option.dept" [nzValue]="option.id"></nz-option>
30
                 </ng-container>
46
                 </ng-container>

+ 11 - 17
src/app/share/hs-prompt-modal/hs-prompt-modal.component.less

@@ -1,4 +1,3 @@
1
-
2
 @import "../../../../src/theme.less";
1
 @import "../../../../src/theme.less";
3
 .modal {
2
 .modal {
4
   position: fixed;
3
   position: fixed;
@@ -6,7 +5,7 @@
6
   top: 0;
5
   top: 0;
7
   width: 100%;
6
   width: 100%;
8
   height: 100%;
7
   height: 100%;
9
-  background: rgba(0, 0, 0, .4);
8
+  background: rgba(0, 0, 0, 0.4);
10
   z-index: 99;
9
   z-index: 99;
11
 
10
 
12
   .modalBody {
11
   .modalBody {
@@ -16,7 +15,7 @@
16
     border-radius: 5px;
15
     border-radius: 5px;
17
     padding: 10px 20px;
16
     padding: 10px 20px;
18
     color: #333;
17
     color: #333;
19
-    &.modalBody-search{
18
+    &.modalBody-search {
20
       width: 480px;
19
       width: 480px;
21
       min-height: 250px;
20
       min-height: 250px;
22
     }
21
     }
@@ -49,42 +48,42 @@
49
       flex-direction: column;
48
       flex-direction: column;
50
       justify-content: center;
49
       justify-content: center;
51
       align-items: center;
50
       align-items: center;
52
-      &.content-search{
51
+      &.content-search {
53
         min-height: 147px;
52
         min-height: 147px;
54
         justify-content: start;
53
         justify-content: start;
55
-        .defeat-search{
54
+        .defeat-search {
56
           width: 100%;
55
           width: 100%;
57
           height: 52px;
56
           height: 52px;
58
           display: flex;
57
           display: flex;
59
           justify-content: center;
58
           justify-content: center;
60
           align-items: center;
59
           align-items: center;
61
           border-bottom: solid 1px #e5e9ed;
60
           border-bottom: solid 1px #e5e9ed;
62
-          em{
61
+          em {
63
             color: #666;
62
             color: #666;
64
             font-style: normal;
63
             font-style: normal;
65
           }
64
           }
66
         }
65
         }
67
-        .form{
66
+        .form {
68
           width: 100%;
67
           width: 100%;
69
           padding: 0 16px;
68
           padding: 0 16px;
70
-          .ant-form-item-label,.ant-form-explain{
71
-            text-align: left!important;
69
+          .ant-form-item-label,
70
+          .ant-form-explain {
71
+            text-align: left !important;
72
           }
72
           }
73
         }
73
         }
74
       }
74
       }
75
 
75
 
76
       div {
76
       div {
77
-        text-align: center;
78
         margin: 0;
77
         margin: 0;
79
 
78
 
80
         &.defeat {
79
         &.defeat {
81
           color: #333;
80
           color: #333;
82
           font-size: 28px;
81
           font-size: 28px;
83
         }
82
         }
84
-        &.countDown{
83
+        &.countDown {
85
           font-size: 14px;
84
           font-size: 14px;
86
           color: 666;
85
           color: 666;
87
-          em{
86
+          em {
88
             font-style: normal;
87
             font-style: normal;
89
             color: @primary-color;
88
             color: @primary-color;
90
           }
89
           }
@@ -105,7 +104,6 @@
105
         margin-left: 8px;
104
         margin-left: 8px;
106
       }
105
       }
107
     }
106
     }
108
-
109
   }
107
   }
110
 
108
 
111
   // 新增
109
   // 新增
@@ -138,17 +136,13 @@
138
             }
136
             }
139
           }
137
           }
140
         }
138
         }
141
-
142
       }
139
       }
143
 
140
 
144
       button {
141
       button {
145
         &:nth-child(1) {
142
         &:nth-child(1) {
146
           margin-right: 20px;
143
           margin-right: 20px;
147
-
148
         }
144
         }
149
       }
145
       }
150
-
151
     }
146
     }
152
   }
147
   }
153
-
154
 }
148
 }

+ 57 - 32
src/app/share/hs-prompt-modal/hs-prompt-modal.component.ts

@@ -1,10 +1,5 @@
1
 import { Component, OnInit, Input, Output, EventEmitter } from "@angular/core";
1
 import { Component, OnInit, Input, Output, EventEmitter } from "@angular/core";
2
-import {
3
-  FormBuilder,
4
-  FormControl,
5
-  FormGroup,
6
-  Validators,
7
-} from "@angular/forms";
2
+import { FormBuilder, FormGroup, Validators } from "@angular/forms";
8
 import { MainService } from "../../services/main.service";
3
 import { MainService } from "../../services/main.service";
9
 import { ToolService } from "../../services/tool.service";
4
 import { ToolService } from "../../services/tool.service";
10
 import { Subject } from "rxjs";
5
 import { Subject } from "rxjs";
@@ -20,11 +15,11 @@ export class HsPromptModalComponent implements OnInit {
20
   // 切换科室,切换弹窗
15
   // 切换科室,切换弹窗
21
   // changeShow = true //true显示第一个弹窗,false显示选择科室的弹窗
16
   // changeShow = true //true显示第一个弹窗,false显示选择科室的弹窗
22
   validateForm!: FormGroup;
17
   validateForm!: FormGroup;
23
-  dutyDept; //当值科室
24
   dutyDepts = []; //当值科室列表
18
   dutyDepts = []; //当值科室列表
25
   isLoading = false;
19
   isLoading = false;
26
   currentHospital; //当前院区
20
   currentHospital; //当前院区
27
-  currentDept = JSON.parse(localStorage.getItem("user")).user.dept.dept; //当前科室
21
+  hospitals = []; //所有院区
22
+  currentDept; //当前科室
28
   @Input() show: Boolean;
23
   @Input() show: Boolean;
29
   @Input() changeShow: Boolean;
24
   @Input() changeShow: Boolean;
30
   @Input() closeTime: Number;
25
   @Input() closeTime: Number;
@@ -40,17 +35,24 @@ export class HsPromptModalComponent implements OnInit {
40
   ) {}
35
   ) {}
41
   searchDeptSubject = new Subject();
36
   searchDeptSubject = new Subject();
42
   ngOnInit() {
37
   ngOnInit() {
43
-    this.searchDeptSubject.pipe(debounceTime(500)).subscribe((v) => {
44
-      this.search(v);
38
+    this.searchDeptSubject.pipe(debounceTime(500)).subscribe((v: any) => {
39
+      this.search(v.hosId, v.e);
45
     });
40
     });
41
+    this.hospitals = this.tool.getHospitalList();
46
     this.currentHospital = this.tool.getCurrentHospital();
42
     this.currentHospital = this.tool.getCurrentHospital();
43
+    this.currentDept = this.tool.getCurrentUserDept();
44
+    this.initForm();
45
+  }
46
+  initForm() {
47
+    this.search(this.currentHospital.id, "");
47
     this.validateForm = this.fb.group({
48
     this.validateForm = this.fb.group({
49
+      hospital: [this.currentHospital.id, [Validators.required]], //院区
48
       dutyDeptFc: [null, [Validators.required]], //当班科室
50
       dutyDeptFc: [null, [Validators.required]], //当班科室
49
     });
51
     });
50
-    this.search(false);
51
   }
52
   }
52
   // 关闭弹窗
53
   // 关闭弹窗
53
   hideModal() {
54
   hideModal() {
55
+    this.initForm();
54
     this.closeModelHs.emit(JSON.stringify({ show: false, changeShow: true })); //emits(向上弹射)事件
56
     this.closeModelHs.emit(JSON.stringify({ show: false, changeShow: true })); //emits(向上弹射)事件
55
   }
57
   }
56
   // 切换科室
58
   // 切换科室
@@ -60,9 +62,12 @@ export class HsPromptModalComponent implements OnInit {
60
   // 获取当前用户信息
62
   // 获取当前用户信息
61
   getCurrentUserNow() {
63
   getCurrentUserNow() {
62
     this.mainService.getCurrentUser1().subscribe((data) => {
64
     this.mainService.getCurrentUser1().subscribe((data) => {
65
+      this.msg.remove(this.maskFlag);
66
+      this.maskFlag = false;
63
       if (data["status"] == 200) {
67
       if (data["status"] == 200) {
64
         let user = JSON.parse(localStorage.getItem("user"));
68
         let user = JSON.parse(localStorage.getItem("user"));
65
         user.user.dept = data["data"].dept;
69
         user.user.dept = data["data"].dept;
70
+        user.user.currentHospital = data["data"].currentHospital;
66
         localStorage.setItem("user", JSON.stringify(user));
71
         localStorage.setItem("user", JSON.stringify(user));
67
         this.showPromptModal("切换科室", true, "");
72
         this.showPromptModal("切换科室", true, "");
68
         this.hideModal();
73
         this.hideModal();
@@ -77,31 +82,40 @@ export class HsPromptModalComponent implements OnInit {
77
       this.validateForm.controls[i].markAsDirty();
82
       this.validateForm.controls[i].markAsDirty();
78
       this.validateForm.controls[i].updateValueAndValidity();
83
       this.validateForm.controls[i].updateValueAndValidity();
79
       if (this.validateForm.controls[i].valid === false) {
84
       if (this.validateForm.controls[i].valid === false) {
80
-        //携带物品非必填
81
         flag = false;
85
         flag = false;
82
       }
86
       }
83
     }
87
     }
84
     if (!flag) {
88
     if (!flag) {
85
       return;
89
       return;
86
     }
90
     }
87
-    let dataObj = {
88
-      user: {
89
-        dept: {
90
-          id: this.validateForm.controls.dutyDeptFc.value,
91
-        },
92
-        id: JSON.parse(localStorage.getItem("user")).user.id,
93
-      },
94
-    };
95
     this.maskFlag = this.msg.loading("正在加载中..", {
91
     this.maskFlag = this.msg.loading("正在加载中..", {
96
       nzDuration: 0,
92
       nzDuration: 0,
97
     }).messageId;
93
     }).messageId;
98
-    this.mainService.coopData("updData", "user", dataObj).subscribe((data) => {
99
-      this.msg.remove(this.maskFlag);
100
-      this.maskFlag = false;
101
-      if (data.status == 200) {
102
-        this.getCurrentUserNow();
103
-      } else {
104
-        this.showPromptModal("切换科室", false, "");
94
+    let postData = {
95
+      currentHosId: this.validateForm.controls.hospital.value,
96
+      loginType: "PC",
97
+    };
98
+    this.mainService.changeHospital(postData).subscribe((result) => {
99
+      if (result.status == 200) {
100
+        let dataObj = {
101
+          user: {
102
+            dept: {
103
+              id: this.validateForm.controls.dutyDeptFc.value,
104
+            },
105
+            id: JSON.parse(localStorage.getItem("user")).user.id,
106
+          },
107
+        };
108
+        this.mainService
109
+          .coopData("updData", "user", dataObj)
110
+          .subscribe((data) => {
111
+            if (data.status == 200) {
112
+              this.getCurrentUserNow();
113
+            } else {
114
+              this.showPromptModal("切换科室", false, "");
115
+              this.msg.remove(this.maskFlag);
116
+              this.maskFlag = false;
117
+            }
118
+          });
105
       }
119
       }
106
     });
120
     });
107
   }
121
   }
@@ -121,26 +135,37 @@ export class HsPromptModalComponent implements OnInit {
121
     }, 100);
135
     }, 100);
122
   }
136
   }
123
   //当值科室搜索
137
   //当值科室搜索
124
-  searchDept(e) {
125
-    this.searchDeptSubject.next(e);
138
+  searchDept(hosId, e) {
139
+    this.isLoading = true;
140
+    this.searchDeptSubject.next({ hosId, e });
141
+  }
142
+  // 院区选择
143
+  searchHospital(hosId) {
144
+    this.validateForm.controls.dutyDeptFc.setValue(null);
145
+    this.searchDept(hosId, "");
126
   }
146
   }
127
   // 当值科室搜索
147
   // 当值科室搜索
128
-  search(e) {
148
+  currentKeywords = "";
149
+  search(hosId, e) {
129
     let keywords = "";
150
     let keywords = "";
130
     if (e) {
151
     if (e) {
131
       keywords = e;
152
       keywords = e;
132
     }
153
     }
154
+    this.currentKeywords = keywords;
133
     let dataObj = {
155
     let dataObj = {
134
       idx: 0,
156
       idx: 0,
135
-      sum: 20,
157
+      sum: 10,
136
       department: {
158
       department: {
137
-        hospital: { id: this.currentHospital.id },
159
+        hospital: { id: hosId },
138
         keyWord: keywords,
160
         keyWord: keywords,
139
       },
161
       },
140
     };
162
     };
141
     this.mainService
163
     this.mainService
142
       .getFetchDataList("data", "department", dataObj)
164
       .getFetchDataList("data", "department", dataObj)
143
       .subscribe((data) => {
165
       .subscribe((data) => {
166
+        if (this.currentKeywords == keywords) {
167
+          this.isLoading = false;
168
+        }
144
         if (data.status == 200) {
169
         if (data.status == 200) {
145
           this.dutyDepts = data.list;
170
           this.dutyDepts = data.list;
146
         }
171
         }

+ 6 - 6
src/app/share/order-detail/order-detail.component.html

@@ -9,7 +9,7 @@
9
     </div>
9
     </div>
10
     <!-- 其他类型工单信息 -->
10
     <!-- 其他类型工单信息 -->
11
     <overlay-scrollbars #osComponentRef3 style="max-height: 400px;">
11
     <overlay-scrollbars #osComponentRef3 style="max-height: 400px;">
12
-      <div *ngIf="(tabType==1)&&(orderInfo.taskType.associationType.id==259)" class="content orders">
12
+      <div *ngIf="(tabType==1)&&(orderInfo.taskType.associationType.value=='other')" class="content orders">
13
         <div class="top">
13
         <div class="top">
14
           <div class="num">
14
           <div class="num">
15
             <span class="left">单号:{{orderInfo.gdcode}}</span>
15
             <span class="left">单号:{{orderInfo.gdcode}}</span>
@@ -64,7 +64,7 @@
64
     </overlay-scrollbars>
64
     </overlay-scrollbars>
65
     <!-- 标本类型工单信息 -->
65
     <!-- 标本类型工单信息 -->
66
     <overlay-scrollbars #osComponentRef4 style="max-height: 400px;">
66
     <overlay-scrollbars #osComponentRef4 style="max-height: 400px;">
67
-      <div *ngIf="tabType==1&&orderInfo.taskType.associationType.id==256" class="content orders">
67
+      <div *ngIf="tabType==1&&orderInfo.taskType.associationType.value=='specimen'" class="content orders">
68
         <div class="top">
68
         <div class="top">
69
           <div class="num">
69
           <div class="num">
70
             <span class="left">单号:{{orderInfo.gdcode}}</span>
70
             <span class="left">单号:{{orderInfo.gdcode}}</span>
@@ -154,7 +154,7 @@
154
     </overlay-scrollbars>
154
     </overlay-scrollbars>
155
     <!-- 标本轮巡工单信息 -->
155
     <!-- 标本轮巡工单信息 -->
156
     <overlay-scrollbars #osComponentRef5 style="max-height: 400px;">
156
     <overlay-scrollbars #osComponentRef5 style="max-height: 400px;">
157
-      <div *ngIf="tabType==1&&orderInfo.taskType.associationType.id==380" class="content orders">
157
+      <div *ngIf="tabType==1&&orderInfo.taskType.associationType.value=='specimenPlan'" class="content orders">
158
         <div class="top">
158
         <div class="top">
159
           <div class="num">
159
           <div class="num">
160
             <span class="left">单号:{{orderInfo.gdcode}}</span>
160
             <span class="left">单号:{{orderInfo.gdcode}}</span>
@@ -244,7 +244,7 @@
244
     </overlay-scrollbars>
244
     </overlay-scrollbars>
245
     <!-- 药品/静配配送类型工单信息 -->
245
     <!-- 药品/静配配送类型工单信息 -->
246
     <overlay-scrollbars #osComponentRef6 style="max-height: 400px;">
246
     <overlay-scrollbars #osComponentRef6 style="max-height: 400px;">
247
-      <div *ngIf="tabType==1&&(orderInfo.taskType.associationType.id==257||orderInfo.taskType.associationType.id==258)"
247
+      <div *ngIf="tabType==1&&(orderInfo.taskType.associationType.value=='drugsBag'||orderInfo.taskType.associationType.value=='jPBag')"
248
         class="content orders">
248
         class="content orders">
249
         <div class="top">
249
         <div class="top">
250
           <div class="num">
250
           <div class="num">
@@ -353,7 +353,7 @@
353
     </overlay-scrollbars>
353
     </overlay-scrollbars>
354
     <!-- 患者陪检/患者转运类型工单信息 -->
354
     <!-- 患者陪检/患者转运类型工单信息 -->
355
     <overlay-scrollbars #osComponentRef1 style="max-height: 400px;">
355
     <overlay-scrollbars #osComponentRef1 style="max-height: 400px;">
356
-      <div *ngIf="tabType==1&&(orderInfo.taskType.associationType.id==260||orderInfo.taskType.associationType.id==255)"
356
+      <div *ngIf="tabType==1&&(orderInfo.taskType.associationType.value=='inspect'||orderInfo.taskType.associationType.value=='patientTransport')"
357
         class="content orders">
357
         class="content orders">
358
         <div class="top">
358
         <div class="top">
359
           <div class="num">
359
           <div class="num">
@@ -434,7 +434,7 @@
434
               </div>
434
               </div>
435
             </div>
435
             </div>
436
           </div>
436
           </div>
437
-          <ng-container *ngIf="orderInfo.taskType.associationType.id==260">
437
+          <ng-container *ngIf="orderInfo.taskType.associationType.value=='inspect'">
438
             <div class="info" *ngFor="let item of orderInfo.checkList">
438
             <div class="info" *ngFor="let item of orderInfo.checkList">
439
               <div nz-row class="top">
439
               <div nz-row class="top">
440
                 <div nz-col nzSpan="8">
440
                 <div nz-col nzSpan="8">

+ 12 - 0
src/app/views/drug-search/drug-search-routing.module.ts

@@ -0,0 +1,12 @@
1
+import { NgModule } from '@angular/core';
2
+import { Routes, RouterModule } from '@angular/router';
3
+import { DrugSearchComponent } from './drug-search.component';
4
+
5
+
6
+const routes: Routes = [{ path: "", component: DrugSearchComponent }];
7
+
8
+@NgModule({
9
+  imports: [RouterModule.forChild(routes)],
10
+  exports: [RouterModule]
11
+})
12
+export class DrugSearchRoutingModule { }

+ 1 - 0
src/app/views/drug-search/drug-search.component.html

@@ -0,0 +1 @@
1
+<p>drug-search works!</p>

+ 0 - 0
src/app/views/drug-search/drug-search.component.less


+ 15 - 0
src/app/views/drug-search/drug-search.component.ts

@@ -0,0 +1,15 @@
1
+import { Component, OnInit } from '@angular/core';
2
+
3
+@Component({
4
+  selector: 'app-drug-search',
5
+  templateUrl: './drug-search.component.html',
6
+  styleUrls: ['./drug-search.component.less']
7
+})
8
+export class DrugSearchComponent implements OnInit {
9
+
10
+  constructor() { }
11
+
12
+  ngOnInit() {
13
+  }
14
+
15
+}

+ 17 - 0
src/app/views/drug-search/drug-search.module.ts

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

+ 20 - 20
src/app/views/fuwutai/fuwutai.component.html

@@ -102,7 +102,7 @@
102
                 </div>
102
                 </div>
103
                 <!-- 地点 -->
103
                 <!-- 地点 -->
104
                 <div class="didian" (click)='openDetails(data.id,data.taskType.associationType.id)'>
104
                 <div class="didian" (click)='openDetails(data.id,data.taskType.associationType.id)'>
105
-                  <span class="left" *ngIf="data.taskType.associationType.id==260">
105
+                  <span class="left" *ngIf="data.taskType.associationType.value=='inspect'">
106
                     {{data.startDept?data.startDept.dept:''}}
106
                     {{data.startDept?data.startDept.dept:''}}
107
                     <span *ngFor="let item of data.middleDept">
107
                     <span *ngFor="let item of data.middleDept">
108
                       ->{{item.dept}}
108
                       ->{{item.dept}}
@@ -121,14 +121,14 @@
121
                   <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
121
                   <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
122
                     <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
122
                     <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
123
                     <ng-container
123
                     <ng-container
124
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
124
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
125
                       <i *ngIf="data.patient.illnessState.value === '2'"
125
                       <i *ngIf="data.patient.illnessState.value === '2'"
126
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
126
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
127
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
127
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
128
                         nz-tooltip nzTooltipTitle="病重"></i>
128
                         nz-tooltip nzTooltipTitle="病重"></i>
129
                     </ng-container>
129
                     </ng-container>
130
                     <ng-container
130
                     <ng-container
131
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
131
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
132
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
132
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
133
                         nzTooltipTitle="特级护理"></i>
133
                         nzTooltipTitle="特级护理"></i>
134
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
134
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
@@ -143,14 +143,14 @@
143
                   <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
143
                   <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
144
                     <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
144
                     <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
145
                     <ng-container
145
                     <ng-container
146
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
146
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
147
                       <i *ngIf="data.patient.illnessState.value === '2'"
147
                       <i *ngIf="data.patient.illnessState.value === '2'"
148
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
148
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
149
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
149
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
150
                         nz-tooltip nzTooltipTitle="病重"></i>
150
                         nz-tooltip nzTooltipTitle="病重"></i>
151
                     </ng-container>
151
                     </ng-container>
152
                     <ng-container
152
                     <ng-container
153
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
153
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
154
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
154
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
155
                         nzTooltipTitle="特级护理"></i>
155
                         nzTooltipTitle="特级护理"></i>
156
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
156
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
@@ -266,7 +266,7 @@
266
                 </div>
266
                 </div>
267
                 <!-- 地点 -->
267
                 <!-- 地点 -->
268
                 <div class="didian" (click)='openDetails(data.id,data.taskType.associationType.id)'>
268
                 <div class="didian" (click)='openDetails(data.id,data.taskType.associationType.id)'>
269
-                  <span class="left" *ngIf="data.taskType.associationType&&data.taskType.associationType.id==260">
269
+                  <span class="left" *ngIf="data.taskType.associationType&&data.taskType.associationType.value=='inspect'">
270
                     {{data.startDept?data.startDept.dept:''}}
270
                     {{data.startDept?data.startDept.dept:''}}
271
                     <span *ngFor="let item of data.middleDept">
271
                     <span *ngFor="let item of data.middleDept">
272
                       ->{{item.dept}}
272
                       ->{{item.dept}}
@@ -285,14 +285,14 @@
285
                   <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
285
                   <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
286
                     <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
286
                     <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
287
                     <ng-container
287
                     <ng-container
288
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
288
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
289
                       <i *ngIf="data.patient.illnessState.value === '2'"
289
                       <i *ngIf="data.patient.illnessState.value === '2'"
290
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
290
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
291
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
291
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
292
                         nz-tooltip nzTooltipTitle="病重"></i>
292
                         nz-tooltip nzTooltipTitle="病重"></i>
293
                     </ng-container>
293
                     </ng-container>
294
                     <ng-container
294
                     <ng-container
295
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
295
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
296
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
296
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
297
                         nzTooltipTitle="特级护理"></i>
297
                         nzTooltipTitle="特级护理"></i>
298
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
298
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
@@ -307,14 +307,14 @@
307
                   <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
307
                   <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
308
                     <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
308
                     <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
309
                     <ng-container
309
                     <ng-container
310
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
310
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
311
                       <i *ngIf="data.patient.illnessState.value === '2'"
311
                       <i *ngIf="data.patient.illnessState.value === '2'"
312
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
312
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
313
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
313
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
314
                         nz-tooltip nzTooltipTitle="病重"></i>
314
                         nz-tooltip nzTooltipTitle="病重"></i>
315
                     </ng-container>
315
                     </ng-container>
316
                     <ng-container
316
                     <ng-container
317
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
317
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
318
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
318
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
319
                         nzTooltipTitle="特级护理"></i>
319
                         nzTooltipTitle="特级护理"></i>
320
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
320
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
@@ -427,7 +427,7 @@
427
                 </div>
427
                 </div>
428
                 <!-- 地点 -->
428
                 <!-- 地点 -->
429
                 <div class="didian">
429
                 <div class="didian">
430
-                  <span class="left" *ngIf="data.taskType.associationType&&data.taskType.associationType.id==260">
430
+                  <span class="left" *ngIf="data.taskType.associationType&&data.taskType.associationType.value=='inspect'">
431
                     {{data.startDept?data.startDept.dept:''}}
431
                     {{data.startDept?data.startDept.dept:''}}
432
                     <span *ngFor="let item of data.middleDept">
432
                     <span *ngFor="let item of data.middleDept">
433
                       ->{{item.dept}}
433
                       ->{{item.dept}}
@@ -446,14 +446,14 @@
446
                   <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
446
                   <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
447
                     <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
447
                     <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
448
                     <ng-container
448
                     <ng-container
449
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
449
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
450
                       <i *ngIf="data.patient.illnessState.value === '2'"
450
                       <i *ngIf="data.patient.illnessState.value === '2'"
451
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
451
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
452
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
452
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
453
                         nz-tooltip nzTooltipTitle="病重"></i>
453
                         nz-tooltip nzTooltipTitle="病重"></i>
454
                     </ng-container>
454
                     </ng-container>
455
                     <ng-container
455
                     <ng-container
456
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
456
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
457
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
457
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
458
                         nzTooltipTitle="特级护理"></i>
458
                         nzTooltipTitle="特级护理"></i>
459
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
459
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
@@ -468,14 +468,14 @@
468
                   <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
468
                   <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
469
                     <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
469
                     <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
470
                     <ng-container
470
                     <ng-container
471
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
471
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
472
                       <i *ngIf="data.patient.illnessState.value === '2'"
472
                       <i *ngIf="data.patient.illnessState.value === '2'"
473
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
473
                         class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
474
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
474
                       <i *ngIf="data.patient.illnessState.value === '3'" class="colorRed icon_transport transport-zhong"
475
                         nz-tooltip nzTooltipTitle="病重"></i>
475
                         nz-tooltip nzTooltipTitle="病重"></i>
476
                     </ng-container>
476
                     </ng-container>
477
                     <ng-container
477
                     <ng-container
478
-                      *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
478
+                      *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
479
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
479
                       <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1" nz-tooltip
480
                         nzTooltipTitle="特级护理"></i>
480
                         nzTooltipTitle="特级护理"></i>
481
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
481
                       <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
@@ -1143,7 +1143,7 @@
1143
                     </div>
1143
                     </div>
1144
                     <!-- 地点 -->
1144
                     <!-- 地点 -->
1145
                     <div class="didian">
1145
                     <div class="didian">
1146
-                      <span class="left" *ngIf="data.taskType.associationType.id==260">
1146
+                      <span class="left" *ngIf="data.taskType.associationType.value=='inspect'">
1147
                         {{data.startDept?data.startDept.dept:''}}
1147
                         {{data.startDept?data.startDept.dept:''}}
1148
                         <span *ngFor="let item of data.middleDept">
1148
                         <span *ngFor="let item of data.middleDept">
1149
                           ->{{item.dept}}
1149
                           ->{{item.dept}}
@@ -1162,14 +1162,14 @@
1162
                       <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
1162
                       <span class="left" *ngIf="data.expectTimeNum&&data.timeOut!=true">
1163
                         <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
1163
                         <i class="icon_transport transport-shouye10" nz-tooltip nzTooltipTitle="进行中"></i>
1164
                         <ng-container
1164
                         <ng-container
1165
-                          *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
1165
+                          *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
1166
                           <i *ngIf="data.patient.illnessState.value === '2'"
1166
                           <i *ngIf="data.patient.illnessState.value === '2'"
1167
                             class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
1167
                             class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
1168
                           <i *ngIf="data.patient.illnessState.value === '3'"
1168
                           <i *ngIf="data.patient.illnessState.value === '3'"
1169
                             class="colorRed icon_transport transport-zhong" nz-tooltip nzTooltipTitle="病重"></i>
1169
                             class="colorRed icon_transport transport-zhong" nz-tooltip nzTooltipTitle="病重"></i>
1170
                         </ng-container>
1170
                         </ng-container>
1171
                         <ng-container
1171
                         <ng-container
1172
-                          *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
1172
+                          *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
1173
                           <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1"
1173
                           <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1"
1174
                             nz-tooltip nzTooltipTitle="特级护理"></i>
1174
                             nz-tooltip nzTooltipTitle="特级护理"></i>
1175
                           <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
1175
                           <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
@@ -1184,14 +1184,14 @@
1184
                       <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
1184
                       <span class="left" *ngIf="data.timeOutLength&&data.timeOut==true">
1185
                         <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
1185
                         <i class="colorRed icon_transport transport-daojishi" nz-tooltip nzTooltipTitle="超时"></i>
1186
                         <ng-container
1186
                         <ng-container
1187
-                          *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.illnessState">
1187
+                          *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.illnessState">
1188
                           <i *ngIf="data.patient.illnessState.value === '2'"
1188
                           <i *ngIf="data.patient.illnessState.value === '2'"
1189
                             class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
1189
                             class="colorRed icon_transport transport-tubiao_wei" nz-tooltip nzTooltipTitle="病危"></i>
1190
                           <i *ngIf="data.patient.illnessState.value === '3'"
1190
                           <i *ngIf="data.patient.illnessState.value === '3'"
1191
                             class="colorRed icon_transport transport-zhong" nz-tooltip nzTooltipTitle="病重"></i>
1191
                             class="colorRed icon_transport transport-zhong" nz-tooltip nzTooltipTitle="病重"></i>
1192
                         </ng-container>
1192
                         </ng-container>
1193
                         <ng-container
1193
                         <ng-container
1194
-                          *ngIf="(data.taskType.associationType.id==255||data.taskType.associationType.id==260)&&data.patient?.careLevel">
1194
+                          *ngIf="(data.taskType.associationType.value=='patientTransport'||data.taskType.associationType.value=='inspect')&&data.patient?.careLevel">
1195
                           <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1"
1195
                           <i *ngIf="data.patient.careLevel.value === '0'" class="icon_transport transport-te1"
1196
                             nz-tooltip nzTooltipTitle="特级护理"></i>
1196
                             nz-tooltip nzTooltipTitle="特级护理"></i>
1197
                           <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"
1197
                           <i *ngIf="data.patient.careLevel.value === '1'" class="icon_transport transport-1_round_solid"

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

@@ -647,7 +647,7 @@
647
                             <div nz-col nzSpan="12" class="col txtL">
647
                             <div nz-col nzSpan="12" class="col txtL">
648
                               {{item.taskType.taskName}}
648
                               {{item.taskType.taskName}}
649
                               <span
649
                               <span
650
-                                *ngIf="item.patient&&(item.taskType.associationType.id == 255||item.taskType.associationType.id == 260)">
650
+                                *ngIf="item.patient&&(item.taskType.associationType.value=='patientTransport'||item.taskType.associationType.value=='inspect')">
651
                                 ({{item.patient.patientName}})
651
                                 ({{item.patient.patientName}})
652
                               </span>
652
                               </span>
653
                             </div>
653
                             </div>
@@ -726,7 +726,7 @@
726
 
726
 
727
 <!-- 返回系统按钮 -->
727
 <!-- 返回系统按钮 -->
728
 <!-- 右侧悬浮框 -->
728
 <!-- 右侧悬浮框 -->
729
-<div id="fixedMenu" class="fixed" *ngIf="mainRole">
729
+<!-- <div id="fixedMenu" class="fixed" *ngIf="mainRole">
730
   <div class="right">
730
   <div class="right">
731
     <div class="fixedMenu hujiaozhongxin">
731
     <div class="fixedMenu hujiaozhongxin">
732
       <div class="menuItems">
732
       <div class="menuItems">
@@ -752,7 +752,7 @@
752
   </div>
752
   </div>
753
   <div *ngIf="showLastItems&&fixedTab!=''" (click)="fixedMenuShangla()" class="fixedMark">
753
   <div *ngIf="showLastItems&&fixedTab!=''" (click)="fixedMenuShangla()" class="fixedMark">
754
   </div>
754
   </div>
755
-</div>
755
+</div> -->
756
 
756
 
757
 <!-- 患者信息一键建单模态框 -->
757
 <!-- 患者信息一键建单模态框 -->
758
 <div class="save display_flex align-items_center justify-content_flex-center patient" *ngIf="patientModal">
758
 <div class="save display_flex align-items_center justify-content_flex-center patient" *ngIf="patientModal">

+ 22 - 13
src/app/views/hushijiandan/hushijiandan.component.ts

@@ -414,9 +414,10 @@ export class HushijiandanComponent implements OnInit {
414
   }
414
   }
415
 
415
 
416
   // 药品静配提示信息
416
   // 药品静配提示信息
417
-  drugJpLoading = true;
417
+  drugJpLoading = false;
418
   getJpDrugsWKOMsg() {
418
   getJpDrugsWKOMsg() {
419
     let that = this;
419
     let that = this;
420
+    this.drugJpLoading = true;
420
     that.mainService
421
     that.mainService
421
       .postCustom("nurse", "getJpDrugsWKOMsg", {})
422
       .postCustom("nurse", "getJpDrugsWKOMsg", {})
422
       .subscribe((data) => {
423
       .subscribe((data) => {
@@ -613,13 +614,13 @@ export class HushijiandanComponent implements OnInit {
613
           that.othersList = [];
614
           that.othersList = [];
614
           that.patientMsgList = [];
615
           that.patientMsgList = [];
615
           data.data.allTaskTypes.forEach((e) => {
616
           data.data.allTaskTypes.forEach((e) => {
616
-            if (e.associationType.id == 259) {
617
+            if (e.associationType.value=='other') {
617
               that.othersList.push(e);
618
               that.othersList.push(e);
618
-            } else if (e.associationType.id == 256) {
619
+            } else if (e.associationType.value=='specimen') {
619
               that.bbMsg = e;
620
               that.bbMsg = e;
620
             } else if (
621
             } else if (
621
-              e.associationType.id == 255 ||
622
-              e.associationType.id == 260
622
+              e.associationType.value=='patientTransport' ||
623
+              e.associationType.value=='inspect'
623
             ) {
624
             ) {
624
               that.patientMsgList.push(e);
625
               that.patientMsgList.push(e);
625
             }
626
             }
@@ -668,9 +669,10 @@ export class HushijiandanComponent implements OnInit {
668
     }
669
     }
669
     let postData = {
670
     let postData = {
670
       idx: 0,
671
       idx: 0,
671
-      sum: 50,
672
+      sum: 20,
672
       department: {
673
       department: {
673
         searchType: 1,
674
         searchType: 1,
675
+        hospital: { id: this.currentHospital.id },
674
       },
676
       },
675
     };
677
     };
676
     if (key) {
678
     if (key) {
@@ -995,7 +997,7 @@ export class HushijiandanComponent implements OnInit {
995
     let flag = this.checkTypeLis.some((item) => {
997
     let flag = this.checkTypeLis.some((item) => {
996
       return (
998
       return (
997
         item.id == this.patientForm.controls.checkedType.value &&
999
         item.id == this.patientForm.controls.checkedType.value &&
998
-        item.associationType.id == 255
1000
+        item.associationType.value=='patientTransport'
999
       );
1001
       );
1000
     });
1002
     });
1001
     //预约时间-患者陪检不能为空
1003
     //预约时间-患者陪检不能为空
@@ -1317,7 +1319,7 @@ export class HushijiandanComponent implements OnInit {
1317
     let appointmentZyBuildFlag = this.checkTypeLis.filter(
1319
     let appointmentZyBuildFlag = this.checkTypeLis.filter(
1318
       (item) =>
1320
       (item) =>
1319
         item.id == this.patientForm.controls.checkedType.value &&
1321
         item.id == this.patientForm.controls.checkedType.value &&
1320
-        item.associationType.id == 255
1322
+        item.associationType.value=='patientTransport'
1321
     );
1323
     );
1322
     if (appointmentZyBuildFlag.length) {
1324
     if (appointmentZyBuildFlag.length) {
1323
       this.appointmentZyBuildFlag =
1325
       this.appointmentZyBuildFlag =
@@ -1397,12 +1399,19 @@ export class HushijiandanComponent implements OnInit {
1397
   }
1399
   }
1398
   // 需要预约建单-事件
1400
   // 需要预约建单-事件
1399
   yyInspectChange(e) {
1401
   yyInspectChange(e) {
1400
-    if (this.filterLinkCheckLis.length) {
1401
-      this.showDateTime();
1402
+    if (this.currentTasktype.associationType.value === "inspect") {
1403
+      //陪检
1404
+      if (this.filterLinkCheckLis.length) {
1405
+        this.showDateTime();
1406
+      } else {
1407
+        this.yyTime = null;
1408
+        this.yyDate = new Date();
1409
+        console.log(this.isYyInspect);
1410
+      }
1402
     } else {
1411
     } else {
1403
-      this.yyTime = null;
1404
-      this.yyDate = null;
1405
-      console.log(this.isYyInspect);
1412
+      //转运
1413
+      this.yyTimeZy = null;
1414
+      this.yyDateZy = new Date();
1406
     }
1415
     }
1407
   }
1416
   }
1408
   //回显时间日期
1417
   //回显时间日期

+ 12 - 0
src/app/views/jp-search/jp-search-routing.module.ts

@@ -0,0 +1,12 @@
1
+import { NgModule } from '@angular/core';
2
+import { Routes, RouterModule } from '@angular/router';
3
+import { JpSearchComponent } from './jp-search.component';
4
+
5
+
6
+const routes: Routes = [{ path: "", component: JpSearchComponent }];
7
+
8
+@NgModule({
9
+  imports: [RouterModule.forChild(routes)],
10
+  exports: [RouterModule]
11
+})
12
+export class JpSearchRoutingModule { }

+ 80 - 0
src/app/views/jp-search/jp-search.component.html

@@ -0,0 +1,80 @@
1
+<div class="list-template">
2
+  <div class="list-template__content">
3
+    <div class="list-template__top" nz-row>
4
+      <div nz-col nzXl='16' class="list-template__searchBox">
5
+        <div class="list-template__searchItem">
6
+          <span class="label">请领单号:</span>
7
+          <input nz-input class="formItem" placeholder="请输入请领单号" [(ngModel)]="searchCriteria.patientName" />
8
+        </div>
9
+        <!-- <div class="list-template__searchItem">
10
+          <span class="label">检查单号:</span>
11
+          <input nz-input class="formItem" placeholder="请输入检查单号" [(ngModel)]="searchCriteria.inspectCode" />
12
+        </div> -->
13
+        <div class="list-template__searchItem">
14
+          <span class="label">发药科室:</span>
15
+          <nz-select [nzDropdownMatchSelectWidth]="false" class="formItem" nzServerSearch nzShowSearch nzAllowClear
16
+            nzPlaceHolder="请选择发药科室" [(ngModel)]="searchCriteria.workerId" (nzOnSearch)="changeInp($event)"
17
+            (nzOpenChange)="changeSearch($event)">
18
+            <ng-container *ngFor="let data of workerSearch">
19
+              <nz-option *ngIf="!isLoading" nzLabel="{{data.name}}" nzValue="{{data.id}}"></nz-option>
20
+            </ng-container>
21
+            <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
22
+              <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
23
+            </nz-option>
24
+          </nz-select>
25
+        </div>
26
+        <div class="list-template__searchItem">
27
+          <span class="label">申请科室:</span>
28
+          <nz-select [nzDropdownMatchSelectWidth]="false" class="formItem" nzServerSearch nzShowSearch nzAllowClear
29
+            nzPlaceHolder="请选择申请科室" [(ngModel)]="searchCriteria.workerId" (nzOnSearch)="changeInp($event)"
30
+            (nzOpenChange)="changeSearch($event)">
31
+            <ng-container *ngFor="let data of workerSearch">
32
+              <nz-option *ngIf="!isLoading" nzLabel="{{data.name}}" nzValue="{{data.id}}"></nz-option>
33
+            </ng-container>
34
+            <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
35
+              <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
36
+            </nz-option>
37
+          </nz-select>
38
+        </div>
39
+      </div>
40
+      <div nz-col nzXl="8" class="list-template__btns">
41
+        <button nz-button class="btn default" (click)='reset()'>重置</button>
42
+        <button nz-button class="btn default ml8" (click)='getList(1)'>搜索</button>
43
+      </div>
44
+    </div>
45
+    <div class="list-template__bottom">
46
+      <nz-table class="list-template__nzTable" [nzData]="listOfData" nzSize="middle" [nzShowPagination]="false"
47
+        [nzLoading]="loading1">
48
+        <thead>
49
+          <tr class="thead">
50
+            <th nzWidth="6%">序号</th>
51
+            <th nzWidth="14%">发药科室</th>
52
+            <th nzWidth="14%">申请科室</th>
53
+            <th nzWidth="14%">创建时间</th>
54
+            <th nzWidth="14%">药品状态</th>
55
+            <th nzWidth="14%">批次号</th>
56
+            <th nzWidth="12%">请领单号</th>
57
+            <th nzWidth="12%">药品标识</th>
58
+          </tr>
59
+        </thead>
60
+        <tbody>
61
+          <tr *ngFor="let data of listOfData;let i = index">
62
+            <td>{{i+1}}</td>
63
+            <td>{{ data.patientName||'-' }}</td>
64
+            <td>{{ data.patientCode||'-' }}</td>
65
+            <td>{{ data.inspectCode||'-' }}</td>
66
+            <td>{{ data.patientBedNum||'-' }}</td>
67
+            <td>{{data.inspectName||'-'}}</td>
68
+            <td>{{ data.yyTime||'-' }}</td>
69
+            <td>{{data.arriveTime||'-'}}</td>
70
+          </tr>
71
+        </tbody>
72
+      </nz-table>
73
+      <div class="list-template__pagination">
74
+        <nz-pagination [(nzPageIndex)]="pageIndex" [(nzTotal)]="listLength" [(nzPageSize)]="pageSize"
75
+          (nzPageIndexChange)="getList(0)" (nzPageSizeChange)="getList(0)">
76
+        </nz-pagination>
77
+      </div>
78
+    </div>
79
+  </div>
80
+</div>

+ 167 - 0
src/app/views/jp-search/jp-search.component.less

@@ -0,0 +1,167 @@
1
+@import "../../../../src/theme.less";
2
+
3
+.save {
4
+  position: fixed;
5
+  left: 0;
6
+  top: 0;
7
+  width: 100%;
8
+  height: 100%;
9
+  background: rgba(0, 0, 0, 0.4);
10
+  z-index: 99;
11
+
12
+  .modalBody {
13
+    width: 350px;
14
+    height: 220px;
15
+    background: #fff;
16
+    border-radius: 5px;
17
+    padding: 10px 20px;
18
+    color: #333;
19
+
20
+    .title {
21
+      width: 100%;
22
+      text-align: center;
23
+      font-size: 18px;
24
+      position: relative;
25
+
26
+      i {
27
+        position: absolute;
28
+        right: 0;
29
+        top: 0;
30
+        font-size: 20px;
31
+        color: #666;
32
+        cursor: pointer;
33
+        padding: 0 5px;
34
+      }
35
+    }
36
+
37
+    .content {
38
+      width: 310px;
39
+      height: 117px;
40
+      background: #f9fafb;
41
+      border: 1px solid #e5e9ed;
42
+      border-radius: 5px;
43
+      overflow: hidden;
44
+      margin-top: 12px;
45
+
46
+      & > div {
47
+        text-align: center;
48
+        margin: 0;
49
+
50
+        &.icon {
51
+          margin-top: 17px;
52
+
53
+          i {
54
+            color: #34b349;
55
+            font-size: 30px !important;
56
+
57
+            &.transport-wenhao {
58
+              color: #f5a523;
59
+            }
60
+
61
+            &.transport-shibai {
62
+              color: #ff3a52;
63
+            }
64
+          }
65
+        }
66
+
67
+        &.defeat {
68
+          color: #333;
69
+          font-size: 18px;
70
+        }
71
+
72
+        &:nth-child(3) {
73
+          font-size: 14px;
74
+          color: #666;
75
+        }
76
+      }
77
+      .roundRobinTips {
78
+        font-size: 12px;
79
+      }
80
+    }
81
+
82
+    button {
83
+      margin-top: 10px;
84
+
85
+      &.btn {
86
+        margin-left: 8px;
87
+      }
88
+    }
89
+  }
90
+
91
+  // 新增
92
+  &.add {
93
+    .modalBody {
94
+      width: 480px;
95
+      height: auto;
96
+
97
+      .content {
98
+        width: 100%;
99
+        height: auto;
100
+        padding: 18px 14px 0 14px;
101
+        max-height: 497px;
102
+        overflow-y: auto;
103
+
104
+        .addForm {
105
+          .ant-form-item {
106
+            margin-bottom: 15px;
107
+
108
+            .ant-form-item-label {
109
+              line-height: 14px;
110
+              text-align: left;
111
+            }
112
+
113
+            .desc {
114
+              margin-top: 5px;
115
+            }
116
+          }
117
+
118
+          .datesControl {
119
+            margin-top: -16px;
120
+
121
+            .ant-form-item-label {
122
+              line-height: 40px;
123
+            }
124
+          }
125
+
126
+          .timer {
127
+            .ant-form-item-label {
128
+              width: 100%;
129
+              text-align: left;
130
+            }
131
+
132
+            .numInp {
133
+              margin-right: 5px;
134
+            }
135
+
136
+            .line {
137
+              margin-right: 5px;
138
+            }
139
+          }
140
+
141
+          .timer2 {
142
+            .ant-form-item-label {
143
+              line-height: 20px;
144
+            }
145
+          }
146
+        }
147
+
148
+        .editForm {
149
+          .ant-form-item {
150
+            margin-bottom: 15px;
151
+
152
+            .ant-form-item-label {
153
+              line-height: 14px;
154
+              text-align: left;
155
+            }
156
+          }
157
+        }
158
+      }
159
+
160
+      button {
161
+        &:nth-child(1) {
162
+          margin-right: 20px;
163
+        }
164
+      }
165
+    }
166
+  }
167
+}

+ 128 - 0
src/app/views/jp-search/jp-search.component.ts

@@ -0,0 +1,128 @@
1
+import { Component, OnInit } from "@angular/core";
2
+import { Subject } from "rxjs";
3
+import { debounceTime } from "rxjs/operators";
4
+import { MainService } from "src/app/services/main.service";
5
+import { ToolService } from "src/app/services/tool.service";
6
+
7
+@Component({
8
+  selector: "app-jp-search",
9
+  templateUrl: "./jp-search.component.html",
10
+  styleUrls: ["./jp-search.component.less"],
11
+})
12
+export class JpSearchComponent implements OnInit {
13
+  constructor(private mainService: MainService, private tool: ToolService) {}
14
+
15
+  searchCriteria = {
16
+    //搜索条件
17
+    patientName: "",
18
+    inspectCode: "",
19
+    hospital: null,
20
+    workerId: null,
21
+  };
22
+  workerSearch = []; // 院区下的支助人员列表(搜索框)
23
+  allHospital: any = []; //院区下拉框
24
+  listOfData: any[] = []; //表格数据
25
+  pageIndex: number = 1; //表格当前页码
26
+  pageSize: number = 10; //表格每页展示条数
27
+  listLength: number = 10; //表格总数据量
28
+  changeInpSubject = new Subject();
29
+  ngOnInit() {
30
+    this.changeInpSubject.pipe(debounceTime(500)).subscribe((v) => {
31
+      this.searchWorker(v);
32
+    });
33
+    this.getAllHospital();
34
+  }
35
+  // 重置
36
+  reset() {
37
+    this.searchCriteria = {
38
+      //搜索条件
39
+      patientName: "",
40
+      inspectCode: "",
41
+      hospital: this.allHospital[0] ? this.allHospital[0]["id"] + "" : null,
42
+      workerId: null,
43
+    };
44
+    this.getList(1);
45
+  }
46
+
47
+  // 获取所有院区
48
+  getAllHospital() {
49
+    this.allHospital = [this.tool.getCurrentHospital()];
50
+    this.searchCriteria.hospital = this.tool.getCurrentHospital().id + "";
51
+    this.getList(1);
52
+  }
53
+  // 查看标本历史记录
54
+  historyPromptModalShow = false; //标本历史记录弹窗开关
55
+  scode = ""; //查看历史记录携带
56
+  viewSpecimenHistory(data) {
57
+    this.scode = data.scode;
58
+    this.historyPromptModalShow = true;
59
+  }
60
+  // 关闭标本历史记录弹窗
61
+  closeModelHistory(e) {
62
+    this.historyPromptModalShow = JSON.parse(e).show;
63
+  }
64
+  // 打开搜索框
65
+  changeSearch(flag) {
66
+    if (flag) {
67
+      this.changeInp("no");
68
+    }
69
+  }
70
+  // 边输边搜节流阀
71
+  isLoading = false;
72
+  changeInp(worker) {
73
+    if (!worker) {
74
+      return;
75
+    }
76
+    if (worker === "no") {
77
+      worker = "";
78
+    }
79
+    this.isLoading = true;
80
+    this.changeInpSubject.next(worker);
81
+  }
82
+  // 搜索支助人员
83
+  searchWorker(worker) {
84
+    let postData = {
85
+      user: {
86
+        name: worker,
87
+        hospital: { id: this.searchCriteria.hospital },
88
+        usertype: { id: 106 },
89
+      },
90
+      idx: 0,
91
+      sum: 10,
92
+    };
93
+    this.mainService
94
+      .getFetchDataList("data", "user", postData)
95
+      .subscribe((result) => {
96
+        if (result.status == 200) {
97
+          this.isLoading = false;
98
+          this.workerSearch = result.list;
99
+        }
100
+      });
101
+  }
102
+
103
+  // 表格数据
104
+  loading1 = false;
105
+  getList(type) {
106
+    if (type == 1) {
107
+      this.pageIndex = 1;
108
+    }
109
+    let postData = {
110
+      idx: this.pageIndex - 1,
111
+      sum: this.pageSize,
112
+      hosId: this.searchCriteria.hospital,
113
+      patientName: this.searchCriteria.patientName,
114
+      inspectCode: this.searchCriteria.inspectCode,
115
+      workerId: this.searchCriteria.workerId,
116
+    };
117
+    this.loading1 = true;
118
+    this.mainService
119
+      .listMsgByMain("listInspect", postData)
120
+      .subscribe((data) => {
121
+        this.loading1 = false;
122
+        if (data["status"] == 200) {
123
+          this.listOfData = data["list"];
124
+          this.listLength = data["totalNum"];
125
+        }
126
+      });
127
+  }
128
+}

+ 17 - 0
src/app/views/jp-search/jp-search.module.ts

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

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

@@ -250,6 +250,20 @@ const routes: Routes = [
250
           ),
250
           ),
251
       },
251
       },
252
       {
252
       {
253
+        // 药品信息
254
+        path: "drugSearch",
255
+        loadChildren: () =>
256
+          import("../drug-search/drug-search.module").then(
257
+            (m) => m.DrugSearchModule
258
+          ),
259
+      },
260
+      {
261
+        // 静配信息
262
+        path: "jpSearch",
263
+        loadChildren: () =>
264
+          import("../jp-search/jp-search.module").then((m) => m.JpSearchModule),
265
+      },
266
+      {
253
         // 院区系统配置
267
         // 院区系统配置
254
         path: "hospitalConfig",
268
         path: "hospitalConfig",
255
         loadChildren: () =>
269
         loadChildren: () =>

+ 5 - 3
src/app/views/main/main.component.ts

@@ -170,9 +170,11 @@ export class MainComponent implements OnInit {
170
       menus.forEach((item1) => {
170
       menus.forEach((item1) => {
171
         item1.flagBg = false;
171
         item1.flagBg = false;
172
         // item1.flag = false;
172
         // item1.flag = false;
173
-        item1.childrens.forEach((value) => {
174
-          value.flag = false;
175
-        });
173
+        if (item1.childrens) {
174
+          item1.childrens.forEach((value) => {
175
+            value.flag = false;
176
+          });
177
+        }
176
       });
178
       });
177
       localStorage.setItem("menu", JSON.stringify(menus));
179
       localStorage.setItem("menu", JSON.stringify(menus));
178
       // 操作菜单一级 二级
180
       // 操作菜单一级 二级

+ 1 - 1
src/app/views/office-management/office-management.component.html

@@ -142,7 +142,7 @@
142
             </nz-form-control>
142
             </nz-form-control>
143
             <nz-form-control style="display: inline-block;">
143
             <nz-form-control style="display: inline-block;">
144
               <nz-select [nzDropdownMatchSelectWidth]="false" style="width:120px;" class="mr8" type="floor" nzShowSearch
144
               <nz-select [nzDropdownMatchSelectWidth]="false" style="width:120px;" class="mr8" type="floor" nzShowSearch
145
-                nzAllowClear formControlName="floor" nzPlaceHolder="请选择楼层">
145
+                nzAllowClear formControlName="floor" nzPlaceHolder="请选择楼层" [nzLoading]="floorLoading">
146
                 <nz-option nzLabel="{{data.floorName}}" nzValue="{{data.id}}" *ngFor="let data of floors"></nz-option>
146
                 <nz-option nzLabel="{{data.floorName}}" nzValue="{{data.id}}" *ngFor="let data of floors"></nz-option>
147
               </nz-select>
147
               </nz-select>
148
             </nz-form-control>
148
             </nz-form-control>

+ 4 - 1
src/app/views/office-management/office-management.component.ts

@@ -193,6 +193,7 @@ export class OfficeManagementComponent implements OnInit {
193
 
193
 
194
   // 切换楼栋信息
194
   // 切换楼栋信息
195
   floors: Array<any> = []; //楼层
195
   floors: Array<any> = []; //楼层
196
+  floorLoading: boolean = false;
196
   changeBuilding(buildingId?, obj?) {
197
   changeBuilding(buildingId?, obj?) {
197
     var that = this;
198
     var that = this;
198
     that.floors = [];
199
     that.floors = [];
@@ -207,7 +208,9 @@ export class OfficeManagementComponent implements OnInit {
207
     let data = {
208
     let data = {
208
       buildingId: bid,
209
       buildingId: bid,
209
     };
210
     };
211
+    this.floorLoading = true;
210
     that.mainService.getBuildingOrFloor("floor", data).subscribe((data) => {
212
     that.mainService.getBuildingOrFloor("floor", data).subscribe((data) => {
213
+      this.floorLoading = false;
211
       this.message.remove(this.maskFlag);
214
       this.message.remove(this.maskFlag);
212
       this.maskFlag = false;
215
       this.maskFlag = false;
213
       this.modal = true;
216
       this.modal = true;
@@ -500,7 +503,6 @@ export class OfficeManagementComponent implements OnInit {
500
   confirmDel() {
503
   confirmDel() {
501
     var that = this;
504
     var that = this;
502
     that.btnLoading = true;
505
     that.btnLoading = true;
503
-    that.delModal = false;
504
     that.mainService
506
     that.mainService
505
       .coopData(
507
       .coopData(
506
         "rmvData",
508
         "rmvData",
@@ -509,6 +511,7 @@ export class OfficeManagementComponent implements OnInit {
509
       )
511
       )
510
       .subscribe((data) => {
512
       .subscribe((data) => {
511
         that.btnLoading = false;
513
         that.btnLoading = false;
514
+        that.delModal = false;
512
         if (data.status == 200) {
515
         if (data.status == 200) {
513
           if (
516
           if (
514
             that.listOfData.length == 1 &&
517
             that.listOfData.length == 1 &&

+ 72 - 25
src/app/views/round-robin/round-robin.component.html

@@ -45,11 +45,20 @@
45
             <td>{{ i+1 }}</td>
45
             <td>{{ i+1 }}</td>
46
             <td>{{ data.title }}</td>
46
             <td>{{ data.title }}</td>
47
             <td>{{ data.taskType.taskName }}</td>
47
             <td>{{ data.taskType.taskName }}</td>
48
-            <td>{{ data.timePlan&&data.timePlan.name }}
49
-              {{data.dayType == 0?'':'('+dayType[data.dayType]+')'}}</td>
50
-            <td>
51
-              <div class="orderPlanTimeShow" nz-tooltip nzTooltipTitle="{{data.orderPlanTimeShow.join()}}">{{
52
-                data.orderPlanTimeShow.join() }}</div>
48
+            <td [ngSwitch]="data.timeStep">
49
+              <ng-container *ngSwitchCase="'day'">每日{{data.dayType == 0?'':'('+dayType[data.dayType]+')'}}</ng-container>
50
+              <ng-container *ngSwitchCase="'week'">每周{{data.dayType == 0?'':'('+dayType[data.dayType]+')'}}
51
+              </ng-container>
52
+              <ng-container *ngSwitchCase="'month'">每月{{data.dayType == 0?'':'('+dayType[data.dayType]+')'}}
53
+              </ng-container>
54
+              <ng-container *ngSwitchCase="'year'">每年{{data.dayType == 0?'':'('+dayType[data.dayType]+')'}}
55
+              </ng-container>
56
+            </td>
57
+            <td [ngSwitch]="data.timeStep">
58
+              <ng-container *ngSwitchCase="'day'">{{ data.executeTime|date:'HH时mm分' }}</ng-container>
59
+              <ng-container *ngSwitchCase="'week'">{{data.weekName}} {{ data.executeTime|date:'HH时mm分' }}</ng-container>
60
+              <ng-container *ngSwitchCase="'month'">{{data.extra1}}日 {{ data.executeTime|date:'HH时mm分' }}</ng-container>
61
+              <ng-container *ngSwitchCase="'year'">{{ data.executeTime|date:'MM月dd日HH时mm分' }}</ng-container>
53
             </td>
62
             </td>
54
             <td>
63
             <td>
55
               <div class="targetDept" nz-tooltip nzTooltipTitle="{{data.targetDeptShow}}">{{ data.targetDeptShow }}
64
               <div class="targetDept" nz-tooltip nzTooltipTitle="{{data.targetDeptShow}}">{{ data.targetDeptShow }}
@@ -57,7 +66,7 @@
57
             </td>
66
             </td>
58
             <td>
67
             <td>
59
               <div class="coop">
68
               <div class="coop">
60
-                <span *ngIf="coopBtns.edit&&data.taskType.associationType.id == 259&&!data.taskTypeDeptOrder"
69
+                <span *ngIf="coopBtns.edit&&data.taskType.associationType.value=='other'&&!data.taskTypeDeptOrder"
61
                   (click)="batchOrdersHandler(data)">批量建单设置</span>
70
                   (click)="batchOrdersHandler(data)">批量建单设置</span>
62
                 <span *ngIf="coopBtns.look" (click)="detail(data.id)">查看</span>
71
                 <span *ngIf="coopBtns.look" (click)="detail(data.id)">查看</span>
63
                 <span *ngIf="coopBtns.edit" (click)="edit(data)">修改</span>
72
                 <span *ngIf="coopBtns.edit" (click)="edit(data)">修改</span>
@@ -111,22 +120,21 @@
111
             </nz-form-control>
120
             </nz-form-control>
112
           </nz-form-item>
121
           </nz-form-item>
113
           <nz-form-item>
122
           <nz-form-item>
114
-            <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="roundRobinStrategy">轮巡策略</nz-form-label>
115
-            <nz-form-control nzErrorTip="请选择轮巡策略!">
116
-              <nz-select [nzDropdownMatchSelectWidth]="false" [nzDisabled]="true" formControlName="roundRobinStrategy"
117
-                nzShowSearch nzAllowClear nzPlaceHolder="请选择轮巡策略">
118
-                <nz-option nzLabel="{{data.hosName}}" nzValue="{{data.id}}" *ngFor="let data of roundRobinStrategys">
119
-                </nz-option>
120
-              </nz-select>
121
-            </nz-form-control>
122
-          </nz-form-item>
123
-          <nz-form-item class="datesControl">
124
-            <nz-form-control nzErrorTip="请选择适用日期类型!" class="datesGroup">
123
+            <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="datesType">工作日或节假日</nz-form-label>
124
+            <nz-form-control nzErrorTip="请选择工作日或节假日!" class="datesGroup">
125
               <nz-checkbox-group formControlName="datesType" [(ngModel)]="oneOption">
125
               <nz-checkbox-group formControlName="datesType" [(ngModel)]="oneOption">
126
               </nz-checkbox-group>
126
               </nz-checkbox-group>
127
             </nz-form-control>
127
             </nz-form-control>
128
           </nz-form-item>
128
           </nz-form-item>
129
           <nz-form-item>
129
           <nz-form-item>
130
+            <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="timeStep">轮巡策略</nz-form-label>
131
+            <nz-form-control nzErrorTip="请选择轮巡策略!">
132
+              <nz-radio-group formControlName="timeStep" (ngModelChange)="timeStepChange($event)">
133
+                <label nz-radio [nzValue]="data.key" *ngFor="let data of timeSteps">{{data.name}}</label>
134
+              </nz-radio-group>
135
+            </nz-form-control>
136
+          </nz-form-item>
137
+          <!-- <nz-form-item>
130
             <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="executionTime">执行时间</nz-form-label>
138
             <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="executionTime">执行时间</nz-form-label>
131
             <nz-form-control nzErrorTip="请选择执行时间!">
139
             <nz-form-control nzErrorTip="请选择执行时间!">
132
               <nz-select formControlName="executionTime" class="select-seimin" nzMode="multiple" nzPlaceHolder="请选择执行时间"
140
               <nz-select formControlName="executionTime" class="select-seimin" nzMode="multiple" nzPlaceHolder="请选择执行时间"
@@ -142,11 +150,49 @@
142
                 <button nz-button nzSize="small" nzType="primary" (click)="timePickerClick()">确定</button>
150
                 <button nz-button nzSize="small" nzType="primary" (click)="timePickerClick()">确定</button>
143
               </ng-template>
151
               </ng-template>
144
             </nz-form-control>
152
             </nz-form-control>
153
+          </nz-form-item> -->
154
+          <nz-form-item *ngIf="validateForm.value.timeStep == 'week'">
155
+            <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="doWeek">计划执行周(每周)</nz-form-label>
156
+            <nz-form-control nzErrorTip="请选择周!">
157
+              <nz-select formControlName="doWeek" nzPlaceHolder="请选择周">
158
+                <nz-option nzValue="1" nzLabel="周一"></nz-option>
159
+                <nz-option nzValue="2" nzLabel="周二"></nz-option>
160
+                <nz-option nzValue="3" nzLabel="周三"></nz-option>
161
+                <nz-option nzValue="4" nzLabel="周四"></nz-option>
162
+                <nz-option nzValue="5" nzLabel="周五"></nz-option>
163
+                <nz-option nzValue="6" nzLabel="周六"></nz-option>
164
+                <nz-option nzValue="7" nzLabel="周日"></nz-option>
165
+              </nz-select>
166
+            </nz-form-control>
167
+          </nz-form-item>
168
+          <nz-form-item *ngIf="validateForm.value.timeStep == 'month'">
169
+            <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="doMonth">计划执行(每月)</nz-form-label>
170
+            <nz-form-control nzErrorTip="请选择日!">
171
+              <nz-select formControlName="doMonth" nzPlaceHolder="请选择日">
172
+                <nz-option nzValue="{{item}}" nzLabel="{{item}}号" *ngFor="let item of months">
173
+                </nz-option>
174
+              </nz-select>
175
+            </nz-form-control>
176
+          </nz-form-item>
177
+          <nz-form-item *ngIf="validateForm.value.timeStep == 'year'">
178
+            <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="doYear">计划执行(每年)</nz-form-label>
179
+            <nz-form-control nzErrorTip="请选择月日!">
180
+              <nz-date-picker nzFormat="MM-dd" formControlName="doYear" nzPlaceHolder="请选择月日"></nz-date-picker>
181
+            </nz-form-control>
182
+          </nz-form-item>
183
+          <nz-form-item>
184
+            <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="executeTime">执行时间</nz-form-label>
185
+            <nz-form-control nzErrorTip="请选择执行时间!">
186
+              <nz-time-picker nzFormat="HH:mm" formControlName="executeTime" class="w100" nzPlaceHolder="请选择执行时间"
187
+                [nzAllowEmpty]="false">
188
+              </nz-time-picker>
189
+            </nz-form-control>
145
           </nz-form-item>
190
           </nz-form-item>
146
           <ng-container *ngIf="selectedTasktype">
191
           <ng-container *ngIf="selectedTasktype">
147
-            <nz-form-item *ngIf="selectedTasktype.associationType.id == 380">
148
-              <nz-form-label [nzSm]="6" [nzXs]="24" [nzRequired]="selectedTasktype.associationType.id == 380"
149
-                nzFor="endDepartment">终点科室</nz-form-label>
192
+            <nz-form-item *ngIf="selectedTasktype.associationType.value=='specimenPlan'">
193
+              <nz-form-label [nzSm]="6" [nzXs]="24"
194
+                [nzRequired]="selectedTasktype.associationType.value=='specimenPlan'" nzFor="endDepartment">终点科室
195
+              </nz-form-label>
150
               <nz-form-control nzErrorTip="请选择终点科室!">
196
               <nz-form-control nzErrorTip="请选择终点科室!">
151
                 <nz-select [nzMode]="'multiple'" [nzDropdownMatchSelectWidth]="false" formControlName="endDepartment"
197
                 <nz-select [nzMode]="'multiple'" [nzDropdownMatchSelectWidth]="false" formControlName="endDepartment"
152
                   nzShowSearch nzAllowClear nzPlaceHolder="请选择终点科室" nzServerSearch
198
                   nzShowSearch nzAllowClear nzPlaceHolder="请选择终点科室" nzServerSearch
@@ -161,7 +207,7 @@
161
               </nz-form-control>
207
               </nz-form-control>
162
             </nz-form-item>
208
             </nz-form-item>
163
             <nz-form-item
209
             <nz-form-item
164
-              *ngIf="selectedTasktype.associationType.id == 259&&(selectedTasktype.carryingCourses[0].departmentStrategy.value==1||selectedTasktype.carryingCourses[1].departmentStrategy.value==1)">
210
+              *ngIf="selectedTasktype.associationType.value=='other'&&(selectedTasktype.carryingCourses[0].departmentStrategy.value==1||selectedTasktype.carryingCourses[1].departmentStrategy.value==1)">
165
               <nz-form-control>
211
               <nz-form-control>
166
                 <label nz-checkbox formControlName="openDepartments">
212
                 <label nz-checkbox formControlName="openDepartments">
167
                   <span>是否根据开通科室建单</span>
213
                   <span>是否根据开通科室建单</span>
@@ -172,14 +218,14 @@
172
           </ng-container>
218
           </ng-container>
173
         </form>
219
         </form>
174
         <ng-container *ngIf="selectedTasktype">
220
         <ng-container *ngIf="selectedTasktype">
175
-          <p *ngIf="selectedTasktype.associationType.id == 380" class="roundRobinTips">
221
+          <p *ngIf="selectedTasktype.associationType.value=='specimenPlan'" class="roundRobinTips">
176
             提示:起点科室即为标本开通科室;执行人即为科室绑定人员设定;前往设置<a [routerLink]="['/main','officeManagement']">开通科室</a>、<a
222
             提示:起点科室即为标本开通科室;执行人即为科室绑定人员设定;前往设置<a [routerLink]="['/main','officeManagement']">开通科室</a>、<a
177
               [routerLink]="['/main','workAssignment']">工作分配</a>>>
223
               [routerLink]="['/main','workAssignment']">工作分配</a>>>
178
           </p>
224
           </p>
179
-          <p *ngIf="selectedTasktype.associationType.id == 259&&(selectedTasktype.carryingCourses[0].departmentStrategy.value==1||selectedTasktype.carryingCourses[1].departmentStrategy.value==1)"
225
+          <p *ngIf="selectedTasktype.associationType.value=='other'&&(selectedTasktype.carryingCourses[0].departmentStrategy.value==1||selectedTasktype.carryingCourses[1].departmentStrategy.value==1)"
180
             class="roundRobinTips">
226
             class="roundRobinTips">
181
             提示:您选择的任务类型,需要根据发起科室进行建单,您需要再批量建单中增加发起科室。</p>
227
             提示:您选择的任务类型,需要根据发起科室进行建单,您需要再批量建单中增加发起科室。</p>
182
-          <p *ngIf="selectedTasktype.associationType.id == 259&&selectedTasktype.carryingCourses[0].departmentStrategy.value!=1&&selectedTasktype.carryingCourses[1].departmentStrategy.value!=1"
228
+          <p *ngIf="selectedTasktype.associationType.value=='other'&&selectedTasktype.carryingCourses[0].departmentStrategy.value!=1&&selectedTasktype.carryingCourses[1].departmentStrategy.value!=1"
183
             class="roundRobinTips">
229
             class="roundRobinTips">
184
             提示:您选择的任务类型,需要选择起点科室和终点科室,请在”批量建单“中进行设置。</p>
230
             提示:您选择的任务类型,需要选择起点科室和终点科室,请在”批量建单“中进行设置。</p>
185
         </ng-container>
231
         </ng-container>
@@ -204,4 +250,5 @@
204
 <!-- 遮罩 -->
250
 <!-- 遮罩 -->
205
 <app-mask *ngIf="maskFlag"></app-mask>
251
 <app-mask *ngIf="maskFlag"></app-mask>
206
 <!-- 批量建单设置 -->
252
 <!-- 批量建单设置 -->
207
-<app-batch-orders *ngIf="batchOrdersFlag" [selectedBatchOrder]="selectedBatchOrder" (close)="close($event)"></app-batch-orders>
253
+<app-batch-orders *ngIf="batchOrdersFlag" [selectedBatchOrder]="selectedBatchOrder" (close)="close($event)">
254
+</app-batch-orders>

+ 5 - 5
src/app/views/round-robin/round-robin.component.less

@@ -9,7 +9,7 @@
9
     text-overflow: ellipsis;
9
     text-overflow: ellipsis;
10
     white-space: nowrap;
10
     white-space: nowrap;
11
   }
11
   }
12
-  .orderPlanTimeShow {
12
+  .executeTime {
13
     overflow: hidden;
13
     overflow: hidden;
14
     width: 142px;
14
     width: 142px;
15
     text-overflow: ellipsis;
15
     text-overflow: ellipsis;
@@ -28,10 +28,10 @@
28
   }
28
   }
29
 }
29
 }
30
 // 时间选择框相关
30
 // 时间选择框相关
31
-::ng-deep .ant-time-picker-panel[ng-reflect-nz-place-holder="请选择执行时间"] {
32
-  left: -155px;
33
-  top: -103px;
34
-}
31
+// ::ng-deep .ant-time-picker-panel[ng-reflect-nz-place-holder="请选择执行时间"] {
32
+//   left: -155px;
33
+//   top: -103px;
34
+// }
35
 
35
 
36
 .save {
36
 .save {
37
   position: fixed;
37
   position: fixed;

+ 114 - 52
src/app/views/round-robin/round-robin.component.ts

@@ -13,6 +13,7 @@ import { ToolService } from "../../services/tool.service";
13
 import { Subject } from "rxjs";
13
 import { Subject } from "rxjs";
14
 import { debounceTime } from "rxjs/operators";
14
 import { debounceTime } from "rxjs/operators";
15
 import { NzMessageService } from "ng-zorro-antd";
15
 import { NzMessageService } from "ng-zorro-antd";
16
+import { format } from "date-fns";
16
 @Component({
17
 @Component({
17
   selector: "app-round-robin",
18
   selector: "app-round-robin",
18
   templateUrl: "./round-robin.component.html",
19
   templateUrl: "./round-robin.component.html",
@@ -42,7 +43,13 @@ export class RoundRobinComponent implements OnInit {
42
     endDepartment: null,
43
     endDepartment: null,
43
   };
44
   };
44
   roundRobinTypes = []; //轮巡类型
45
   roundRobinTypes = []; //轮巡类型
45
-  roundRobinStrategys = [{ id: "381", hosName: "每天轮巡" }]; //轮巡类型
46
+  timeSteps = [
47
+    // { id: "381", name: "每天轮巡" },
48
+    { key: "day", name: "每天" },
49
+    { key: "week", name: "每周" },
50
+    { key: "month", name: "每月" },
51
+    { key: "year", name: "每年" },
52
+  ]; //轮巡类型
46
   createUser = "";
53
   createUser = "";
47
   dayType = ["全部", "节假日", "工作日"]; //执行策略里的复选框数据字典
54
   dayType = ["全部", "节假日", "工作日"]; //执行策略里的复选框数据字典
48
   department = []; // 院区下的科室列表
55
   department = []; // 院区下的科室列表
@@ -154,7 +161,7 @@ export class RoundRobinComponent implements OnInit {
154
   selectedTasktypeHandler(e) {
161
   selectedTasktypeHandler(e) {
155
     this.selectedTasktype = this.roundRobinTypes.find((item) => item.id == e);
162
     this.selectedTasktype = this.roundRobinTypes.find((item) => item.id == e);
156
     this.requiredChange(
163
     this.requiredChange(
157
-      this.selectedTasktype.associationType.id == 380,
164
+      this.selectedTasktype.associationType.value == "specimenPlan",
158
       "endDepartment"
165
       "endDepartment"
159
     );
166
     );
160
     console.log(this.selectedTasktype);
167
     console.log(this.selectedTasktype);
@@ -255,6 +262,20 @@ export class RoundRobinComponent implements OnInit {
255
         if (data.status == 200) {
262
         if (data.status == 200) {
256
           this.listOfData = data.list;
263
           this.listOfData = data.list;
257
           this.listLength = data.totalNum;
264
           this.listLength = data.totalNum;
265
+          this.listOfData.forEach((item) => {
266
+            if (item.timeStep == "week") {
267
+              let weeks = [
268
+                "周一",
269
+                "周二",
270
+                "周三",
271
+                "周四",
272
+                "周五",
273
+                "周六",
274
+                "周日",
275
+              ];
276
+              item.weekName = weeks[item.extra1 - 1];
277
+            }
278
+          });
258
         }
279
         }
259
       });
280
       });
260
   }
281
   }
@@ -317,18 +338,52 @@ export class RoundRobinComponent implements OnInit {
317
     this.validateForm = this.fb.group({
338
     this.validateForm = this.fb.group({
318
       roundRobinName: [null, [Validators.required]],
339
       roundRobinName: [null, [Validators.required]],
319
       roundRobinType: [null, [Validators.required]],
340
       roundRobinType: [null, [Validators.required]],
320
-      roundRobinStrategy: [null, [Validators.required]],
341
+      timeStep: [null, [Validators.required]],
321
       datesType: [null, [this.dateValidator]],
342
       datesType: [null, [this.dateValidator]],
322
-      executionTime: [null, [Validators.required]],
323
-      time: [null],
343
+      executeTime: [null, [Validators.required]],
344
+      // executionTime: [null, [Validators.required]],
345
+      // time: [null],
324
       endDepartment: [null, [Validators.required]],
346
       endDepartment: [null, [Validators.required]],
325
       openDepartments: [false],
347
       openDepartments: [false],
326
     });
348
     });
327
-    this.validateForm.controls.roundRobinStrategy.setValue(
328
-      this.roundRobinStrategys[0].id
329
-    );
349
+    this.validateForm.controls.timeStep.setValue(this.timeSteps[0].key);
330
     this.timeSelectedValue = [];
350
     this.timeSelectedValue = [];
331
   }
351
   }
352
+  // 修改轮巡策略
353
+  months = [...Array(32).keys()].slice(1);
354
+  timeStepChange(e) {
355
+    switch (e) {
356
+      case "day":
357
+        this.validateForm.removeControl("doWeek");
358
+        this.validateForm.removeControl("doMonth");
359
+        this.validateForm.removeControl("doYear");
360
+        break;
361
+      case "week":
362
+        this.validateForm.addControl(
363
+          "doWeek",
364
+          new FormControl(null, Validators.required)
365
+        );
366
+        this.validateForm.removeControl("doMonth");
367
+        this.validateForm.removeControl("doYear");
368
+        break;
369
+      case "month":
370
+        this.validateForm.addControl(
371
+          "doMonth",
372
+          new FormControl(null, Validators.required)
373
+        );
374
+        this.validateForm.removeControl("doWeek");
375
+        this.validateForm.removeControl("doYear");
376
+        break;
377
+      case "year":
378
+        this.validateForm.addControl(
379
+          "doYear",
380
+          new FormControl(null, Validators.required)
381
+        );
382
+        this.validateForm.removeControl("doWeek");
383
+        this.validateForm.removeControl("doMonth");
384
+        break;
385
+    }
386
+  }
332
 
387
 
333
   //创建自定义校验规则dateValidator,用于复选框组校验时调用。
388
   //创建自定义校验规则dateValidator,用于复选框组校验时调用。
334
   selectedDate: any = [];
389
   selectedDate: any = [];
@@ -372,63 +427,66 @@ export class RoundRobinComponent implements OnInit {
372
       this.btnLoading = false;
427
       this.btnLoading = false;
373
       return;
428
       return;
374
     }
429
     }
375
-    let data: any = {};
430
+    let postData: any = {};
376
 
431
 
377
     if (this.add) {
432
     if (this.add) {
378
       //增加
433
       //增加
379
-      data = {
434
+      postData = {
380
         orderPlan: {
435
         orderPlan: {
381
           title: this.validateForm.value.roundRobinName,
436
           title: this.validateForm.value.roundRobinName,
382
           hospital: this.hosId,
437
           hospital: this.hosId,
383
           taskType: { id: this.validateForm.value.roundRobinType },
438
           taskType: { id: this.validateForm.value.roundRobinType },
384
-          timePlan: {
385
-            id: this.validateForm.value.roundRobinStrategy,
386
-          },
439
+          timeStep: this.validateForm.value.timeStep,
387
           dayType: this.validateForm.value.datesType,
440
           dayType: this.validateForm.value.datesType,
388
-          orderPlanTimeShow: this.validateForm.value.executionTime,
441
+          executeTime: new Date(this.validateForm.value.executeTime).getTime(),
389
         },
442
         },
390
       };
443
       };
391
-      if (this.selectedTasktype.associationType.id == 380) {
444
+      if (this.selectedTasktype.associationType.value == "specimenPlan") {
392
         //标本轮巡
445
         //标本轮巡
393
-        data.orderPlan.targetDept =
446
+        postData.orderPlan.targetDept =
394
           this.validateForm.value.endDepartment.join();
447
           this.validateForm.value.endDepartment.join();
395
-      } else if (this.selectedTasktype.associationType.id == 259) {
448
+      } else if (this.selectedTasktype.associationType.value == "other") {
396
         //其他配送
449
         //其他配送
397
-        data.orderPlan.taskTypeDeptOrder =
450
+        postData.orderPlan.taskTypeDeptOrder =
398
           this.validateForm.value.openDepartments;
451
           this.validateForm.value.openDepartments;
399
       }
452
       }
400
     } else {
453
     } else {
401
       //编辑
454
       //编辑
402
-      let timeSelectedValue = JSON.parse(
403
-        JSON.stringify(this.timeSelectedValue)
404
-      );
405
-      let diff =
406
-        timeSelectedValue.sort().join("-") ===
407
-        this.executionTimeTemporaryStorage.sort().join("-")
408
-          ? []
409
-          : this.timeSelectedValue;
410
-      data = {
455
+      postData = {
411
         id: this.coopId,
456
         id: this.coopId,
412
         title: this.validateForm.value.roundRobinName,
457
         title: this.validateForm.value.roundRobinName,
413
         hospital: this.hosId,
458
         hospital: this.hosId,
414
         taskType: { id: this.validateForm.value.roundRobinType },
459
         taskType: { id: this.validateForm.value.roundRobinType },
415
-        timePlan: {
416
-          id: this.validateForm.value.roundRobinStrategy,
417
-        },
460
+        timeStep: this.validateForm.value.timeStep,
418
         dayType: this.validateForm.value.datesType,
461
         dayType: this.validateForm.value.datesType,
419
-        orderPlanTimeShow: diff,
462
+        executeTime: new Date(this.validateForm.value.executeTime).getTime(),
420
       };
463
       };
421
-      if (this.selectedTasktype.associationType.id == 380) {
464
+      if (this.selectedTasktype.associationType.value == "specimenPlan") {
422
         //标本轮巡
465
         //标本轮巡
423
-        data.targetDept = this.validateForm.value.endDepartment.join();
424
-      } else if (this.selectedTasktype.associationType.id == 259) {
466
+        postData.targetDept = this.validateForm.value.endDepartment.join();
467
+      } else if (this.selectedTasktype.associationType.value == "other") {
425
         //其他配送
468
         //其他配送
426
-        data.taskTypeDeptOrder = this.validateForm.value.openDepartments;
469
+        postData.taskTypeDeptOrder = this.validateForm.value.openDepartments;
427
       }
470
       }
428
     }
471
     }
429
-    console.log(data);
472
+    if (this.validateForm.value.timeStep == "day") {
473
+      delete postData.extra1;
474
+    } else if (this.validateForm.value.timeStep == "week") {
475
+      postData.extra1 = this.validateForm.value.doWeek;
476
+    } else if (this.validateForm.value.timeStep == "month") {
477
+      postData.extra1 = this.validateForm.value.doMonth;
478
+    } else if (this.validateForm.value.timeStep == "year") {
479
+      delete postData.extra1;
480
+      postData.executeTime = new Date(
481
+        format(new Date(this.validateForm.value.doYear), "yyyy-MM-dd") +
482
+          " " +
483
+          format(new Date(this.validateForm.value.executeTime), "HH:mm:ss")
484
+      ).getTime();
485
+    }
486
+    console.log(postData);
487
+    // return; //baba
430
     this.mainService
488
     this.mainService
431
-      .addRoundRobin(this.add ? "addPlan" : "updatePlan", data)
489
+      .addRoundRobin(this.add ? "addPlan" : "updatePlan", postData)
432
       .subscribe((data) => {
490
       .subscribe((data) => {
433
         this.btnLoading = false;
491
         this.btnLoading = false;
434
         this.hideAddModal();
492
         this.hideAddModal();
@@ -449,7 +507,7 @@ export class RoundRobinComponent implements OnInit {
449
   maskFlagLoading2 = false;
507
   maskFlagLoading2 = false;
450
   edit(data) {
508
   edit(data) {
451
     this.requiredChange(
509
     this.requiredChange(
452
-      data.taskType.associationType.id == 380,
510
+      data.taskType.associationType.value == "specimenPlan",
453
       "endDepartment"
511
       "endDepartment"
454
     );
512
     );
455
     this.maskFlag = this.message.loading("正在加载中..", {
513
     this.maskFlag = this.message.loading("正在加载中..", {
@@ -461,7 +519,7 @@ export class RoundRobinComponent implements OnInit {
461
     this.coopId = data.id;
519
     this.coopId = data.id;
462
     this.createUser = data.createUser ? data.createUser.name : ""; //创建人
520
     this.createUser = data.createUser ? data.createUser.name : ""; //创建人
463
     this.validateForm.controls.roundRobinName.setValue(data.title); //名称
521
     this.validateForm.controls.roundRobinName.setValue(data.title); //名称
464
-    // 轮巡类型
522
+    // 轮巡类型 start
465
     {
523
     {
466
       this.selectedTasktype = data.taskType;
524
       this.selectedTasktype = data.taskType;
467
       let postData = {
525
       let postData = {
@@ -496,19 +554,23 @@ export class RoundRobinComponent implements OnInit {
496
           }
554
           }
497
         });
555
         });
498
     }
556
     }
499
-    // 轮巡类型
500
-    this.validateForm.controls.roundRobinStrategy.setValue(
501
-      this.roundRobinStrategys[0].id
502
-    ); //轮巡策略
503
-    this.defaultSelectTimesOption = JSON.parse(
504
-      JSON.stringify(data.orderPlanTimeShow)
505
-    ); //轮巡策略(时间)
506
-    this.timeSelectedValue = JSON.parse(JSON.stringify(data.orderPlanTimeShow)); //轮巡策略(时间)
507
-    this.executionTimeTemporaryStorage = JSON.parse(
508
-      JSON.stringify(data.orderPlanTimeShow)
509
-    ); //轮巡策略(时间暂存)
557
+    // 轮巡类型end
558
+    this.validateForm.controls.timeStep.setValue(data.timeStep); //轮巡策略
559
+    this.validateForm.controls.executeTime.setValue(new Date(data.executeTime)); //轮巡策略
560
+    this.defaultSelectTimesOption = data.executeTime;
561
+    //轮巡策略(时间) start
562
+    if (data.timeStep == "year") {
563
+      this.validateForm.controls.doYear.setValue(
564
+        format(data.executeTime, "yyyy-MM-dd HH:mm:ss")
565
+      );
566
+    } else if (data.timeStep == "month") {
567
+      this.validateForm.controls.doMonth.setValue(data.extra1);
568
+    } else if (data.timeStep == "week") {
569
+      this.validateForm.controls.doWeek.setValue(data.extra1);
570
+    }
571
+    //轮巡策略(时间)end
510
     // --------终点科室---
572
     // --------终点科室---
511
-    if (data.taskType.associationType.id == 380) {
573
+    if (data.taskType.associationType.value == "specimenPlan") {
512
       //标本轮巡,则回显
574
       //标本轮巡,则回显
513
       let targetDeptArr = [];
575
       let targetDeptArr = [];
514
       let targetDept = data.targetDept.split(",");
576
       let targetDept = data.targetDept.split(",");
@@ -550,7 +612,7 @@ export class RoundRobinComponent implements OnInit {
550
     }
612
     }
551
     // --------/终点科室---
613
     // --------/终点科室---
552
     if (
614
     if (
553
-      data.taskType.associationType.id == 259 &&
615
+      data.taskType.associationType.value == "other" &&
554
       (data.taskType.carryingCourses[0].departmentStrategy.value == 1 ||
616
       (data.taskType.carryingCourses[0].departmentStrategy.value == 1 ||
555
         data.taskType.carryingCourses[1].departmentStrategy.value == 1)
617
         data.taskType.carryingCourses[1].departmentStrategy.value == 1)
556
     ) {
618
     ) {

+ 2 - 1
src/app/views/task-type-management/task-type-management.component.html

@@ -51,8 +51,9 @@
51
           </div>
51
           </div>
52
         </div>
52
         </div>
53
         <nz-form-label class="label" nzRequired>关联类型</nz-form-label>
53
         <nz-form-label class="label" nzRequired>关联类型</nz-form-label>
54
+        <!-- 关联类型禁止修改 -->
54
         <nz-select class="mb8 w100" nzShowSearch nzAllowClear nzPlaceHolder="请选择关联类型" [(ngModel)]="association.id"
55
         <nz-select class="mb8 w100" nzShowSearch nzAllowClear nzPlaceHolder="请选择关联类型" [(ngModel)]="association.id"
55
-          (ngModelChange)="asso(association)">
56
+          (ngModelChange)="asso(association)" [nzDisabled]="!add">
56
           <nz-option nzLabel="{{data.name}}" nzValue="{{data.id}}" *ngFor="let data of allAssociation"></nz-option>
57
           <nz-option nzLabel="{{data.name}}" nzValue="{{data.id}}" *ngFor="let data of allAssociation"></nz-option>
57
         </nz-select>
58
         </nz-select>
58
         <nz-form-label *ngIf="association['id'] == 256" class="label" nzRequired>空单默认科室</nz-form-label>
59
         <nz-form-label *ngIf="association['id'] == 256" class="label" nzRequired>空单默认科室</nz-form-label>

+ 4 - 13
src/app/views/task-type-management/task-type-management.component.ts

@@ -1,5 +1,5 @@
1
 import { Component, OnInit, ViewChild } from "@angular/core";
1
 import { Component, OnInit, ViewChild } from "@angular/core";
2
-import { ActivatedRoute, Router } from "@angular/router";
2
+import { ActivatedRoute } from "@angular/router";
3
 import { MainService } from "../../services/main.service";
3
 import { MainService } from "../../services/main.service";
4
 import { OverlayScrollbarsComponent } from "overlayscrollbars-ngx";
4
 import { OverlayScrollbarsComponent } from "overlayscrollbars-ngx";
5
 import { FormBuilder, FormGroup } from "@angular/forms";
5
 import { FormBuilder, FormGroup } from "@angular/forms";
@@ -387,6 +387,7 @@ export class TaskTypeManagementComponent implements OnInit {
387
   // 获取所有院区
387
   // 获取所有院区
388
   getAllHospital() {
388
   getAllHospital() {
389
     this.hosId = this.tool.getCurrentHospital().id;
389
     this.hosId = this.tool.getCurrentHospital().id;
390
+    this.hosName = this.tool.getCurrentHospital().hosName;
390
     this.onSearch("");
391
     this.onSearch("");
391
   }
392
   }
392
   // 获取所有关联类型
393
   // 获取所有关联类型
@@ -600,7 +601,6 @@ export class TaskTypeManagementComponent implements OnInit {
600
     };
601
     };
601
     this.taskData.taskType["id"] = data.id;
602
     this.taskData.taskType["id"] = data.id;
602
     this.taskName = data.taskName;
603
     this.taskName = data.taskName;
603
-    this.hosName = data.hosId.hosName;
604
     this.association.id = data.associationType.id + "";
604
     this.association.id = data.associationType.id + "";
605
     this.association.value = data.associationType.value;
605
     this.association.value = data.associationType.value;
606
     if (data.deptIds) {
606
     if (data.deptIds) {
@@ -673,12 +673,12 @@ export class TaskTypeManagementComponent implements OnInit {
673
 
673
 
674
       if (this.allScheduleClass[i].checked) {
674
       if (this.allScheduleClass[i].checked) {
675
         this.scheduleClassChecked.push(this.allScheduleClass[i]);
675
         this.scheduleClassChecked.push(this.allScheduleClass[i]);
676
-        if (data.associationType.id == 256) {
676
+        if (data.associationType.value=='specimen') {
677
           this.autoClass.push(this.allScheduleClass[i]);
677
           this.autoClass.push(this.allScheduleClass[i]);
678
         }
678
         }
679
       }
679
       }
680
     }
680
     }
681
-    if (data.associationType.id == 256) {
681
+    if (data.associationType.value=='specimen') {
682
       let ids = data.carryingCourses[0].createRuleConfiguration
682
       let ids = data.carryingCourses[0].createRuleConfiguration
683
         ? data.carryingCourses[0].createRuleConfiguration.map(
683
         ? data.carryingCourses[0].createRuleConfiguration.map(
684
             (item) => item.classesId
684
             (item) => item.classesId
@@ -739,7 +739,6 @@ export class TaskTypeManagementComponent implements OnInit {
739
       data.remarksPrompts === undefined ? "" : data.remarksPrompts + ""; //备注信息提示用语
739
       data.remarksPrompts === undefined ? "" : data.remarksPrompts + ""; //备注信息提示用语
740
     this.quickRemarks =
740
     this.quickRemarks =
741
       data.customRemarks === undefined ? "" : data.customRemarks; //备注快速输入
741
       data.customRemarks === undefined ? "" : data.customRemarks; //备注快速输入
742
-    // this.optionList
743
     let addEndDeptIdsArr = data.carryingCourses[0].endDepartmentList || [];
742
     let addEndDeptIdsArr = data.carryingCourses[0].endDepartmentList || [];
744
     let ids = [];
743
     let ids = [];
745
     let arrMiddle = [];
744
     let arrMiddle = [];
@@ -1686,14 +1685,6 @@ export class TaskTypeManagementComponent implements OnInit {
1686
           );
1685
           );
1687
         }
1686
         }
1688
       });
1687
       });
1689
-      // 双层for循环取name
1690
-      // for (var i = 0; i < this.autoClass.length; i++) {
1691
-      //   for (var k = 0; k < this.createRuleConfiguration.length; k++) {
1692
-      //     if (this.autoClass[i].id == this.createRuleConfiguration[k].classesId) {
1693
-      //       this.createRuleConfiguration[k]['name'] = this.autoClass[i].name
1694
-      //     }
1695
-      //   }
1696
-      // }
1697
     } else {
1688
     } else {
1698
       this.createRuleConfiguration = [];
1689
       this.createRuleConfiguration = [];
1699
     }
1690
     }