seimin 1 年之前
父節點
當前提交
0dd93c402c

+ 94 - 9
src/app/views/hushijiandan/hushijiandan.component.html

@@ -44,11 +44,11 @@
44 44
             class="checkItem checked"
45 45
             (click)="changeInfo()"
46 46
           >
47
-            患者信息
47
+          {{currentDept.typeValue == 'surgery' ? '手术安排信息' : '患者信息'}}
48 48
           </button>
49 49
         </div>
50 50
         <!-- 患者信息 -->
51
-        <div class="checkedInfo patient" style="padding-bottom: 0">
51
+        <div class="checkedInfo patient" style="padding-bottom: 0" *ngIf="currentDept.typeValue != 'surgery'; else elseBlock">
52 52
           <overlay-scrollbars #osComponentRef4 class="box">
53 53
             <div
54 54
               class="loading display_flex align-items_center justify-content_flex-center"
@@ -128,9 +128,9 @@
128 128
                   nz-row
129 129
                   *ngIf="
130 130
                     followFlag === '1' &&
131
-                    currentUser.typeValue != 'checkRoom2' &&
132
-                    currentUser.typeValue != 'outpatientDept' &&
133
-                    currentUser.typeValue != 'checkRoom'
131
+                    currentDept.typeValue != 'checkRoom2' &&
132
+                    currentDept.typeValue != 'outpatientDept' &&
133
+                    currentDept.typeValue != 'checkRoom'
134 134
                   "
135 135
                 >
136 136
                   <span
@@ -160,9 +160,9 @@
160 160
                   nz-row
161 161
                   *ngIf="
162 162
                     followFlag === '0' ||
163
-                    currentUser.typeValue == 'checkRoom2' ||
164
-                    currentUser.typeValue == 'outpatientDept' ||
165
-                    currentUser.typeValue == 'checkRoom'
163
+                    currentDept.typeValue == 'checkRoom2' ||
164
+                    currentDept.typeValue == 'outpatientDept' ||
165
+                    currentDept.typeValue == 'checkRoom'
166 166
                   "
167 167
                 >
168 168
                   <span nz-col nzSpan="2"></span>
@@ -177,6 +177,87 @@
177 177
             </div>
178 178
           </overlay-scrollbars>
179 179
         </div>
180
+        <ng-template #elseBlock>
181
+          <!-- 手术安排信息 -->
182
+          <div class="checkedInfo patient" style="padding-bottom: 0">
183
+            <overlay-scrollbars #osComponentRef4 class="box">
184
+              <div
185
+                class="loading display_flex align-items_center justify-content_flex-center"
186
+                *ngIf="
187
+                  pLoading &&
188
+                  (deptTaskTypeRules.openInspection ||
189
+                    deptTaskTypeRules.openPatientTransport)
190
+                "
191
+              >
192
+                <div>
193
+                  <img src="../../assets/images/loading.gif" alt="" />
194
+                  <div>加载中...</div>
195
+                </div>
196
+              </div>
197
+              <div
198
+                class="loading display_flex align-items_center justify-content_flex-center"
199
+                *ngIf="!patientList.length && !pLoading"
200
+              >
201
+                <div>
202
+                  <div>暂无数据</div>
203
+                </div>
204
+              </div>
205
+              <div *ngIf="patientList.length && !pLoading">
206
+                <div class="item" *ngFor="let item of patientList">
207
+                  <div class="itemTit txtC" style="font-weight: bold">
208
+                    <ng-container *ngIf="item.patientDTO && item.patientDTO.illnessState">
209
+                      <i
210
+                        *ngIf="item.patientDTO && item.patientDTO.illnessState.value === '2'"
211
+                        class="colorRed icon_transport transport-wei"
212
+                        nz-tooltip
213
+                        nzTooltipTitle="病危"
214
+                      ></i>
215
+                      <i
216
+                        *ngIf="item.patientDTO && item.patientDTO.illnessState.value === '3'"
217
+                        class="colorRed icon_transport transport-zhong1"
218
+                        nz-tooltip
219
+                        nzTooltipTitle="病重"
220
+                      ></i>
221
+                    </ng-container>
222
+                    <ng-container *ngIf="item.patientDTO && item.patientDTO.careLevel">
223
+                      <i
224
+                        *ngIf="item.patientDTO && item.patientDTO.careLevel.value === '0'"
225
+                        class="icon_transport transport-te1"
226
+                        nz-tooltip
227
+                        nzTooltipTitle="特级护理"
228
+                      ></i>
229
+                      <i
230
+                        *ngIf="item.patientDTO && item.patientDTO.careLevel.value === '1'"
231
+                        class="icon_transport transport-Bduanshuzi1"
232
+                        nz-tooltip
233
+                        nzTooltipTitle="一级护理"
234
+                      ></i>
235
+                      <i
236
+                        *ngIf="item.patientDTO && item.patientDTO.careLevel.value === '2'"
237
+                        class="icon_transport transport-Bduanshuzi"
238
+                        nz-tooltip
239
+                        nzTooltipTitle="二级护理"
240
+                      ></i>
241
+                      <i
242
+                        *ngIf="item.patientDTO && item.patientDTO.careLevel.value === '3'"
243
+                        class="icon_transport transport-Bduanshuzi11"
244
+                        nz-tooltip
245
+                        nzTooltipTitle="三级护理"
246
+                      ></i>
247
+                    </ng-container>
248
+                    <span>{{ item.patientDTO ? item.patientDTO.patientName : '' }}({{ item.patientDTO ? item.patientDTO.residenceNo : '' }})</span>
249
+                  </div>
250
+                  <div class="checkInfo" nz-row>
251
+                    <span nz-col nzSpan="24">{{ item.applyDate | date:'HH:mm' }}({{ item.orders }})</span>
252
+                    <span nz-col nzSpan="24">{{ item.areaDept ? (deptDisplay == 2 ? item.areaDept.deptalias : item.areaDept.dept) : '' }}</span>
253
+                    <span nz-col nzSpan="24">{{ item.surgeryName }}</span>
254
+                  </div>
255
+                  <div class="btn" (click)="pickUpPatient($event, item)">一键接患者</div>
256
+                </div>
257
+              </div>
258
+            </overlay-scrollbars>
259
+          </div>
260
+        </ng-template>
180 261
         <!-- 翻页 -->
181 262
         <!-- <div class="paging">
182 263
           <div>
@@ -228,7 +309,7 @@
228 309
           <div class="mainInfo" nz-row>
229 310
             <div nz-col nzSpan="17" class="cont">
230 311
               <div class="top">
231
-                <div class="nums borderB" nz-row>
312
+                <div class="nums borderB" nz-row *ngIf="currentDept.typeValue != 'surgery'">
232 313
                   <!-- 标本信息未开通 -->
233 314
                   <div
234 315
                     *ngIf="!deptTaskTypeRules.openSpecimen"
@@ -3470,3 +3551,7 @@
3470 3551
   cancelTxt="否"
3471 3552
   (cancelDelEvent)="hideRepeatModal()"
3472 3553
 ></app-dialog-delete>
3554
+
3555
+<!-- 是否一键接患者模态框 -->
3556
+<app-dialog-delete [delModal]="pickUpModal" (hideDelModalEvent)="hidePickUpModal()" [btnLoading]="btnLoading"
3557
+(confirmDelEvent)="confirmPickUp()" content="您本次需要从某某科室接某某患者到某某手术间进行手术,您确认接患者吗?"></app-dialog-delete>

+ 81 - 18
src/app/views/hushijiandan/hushijiandan.component.ts

@@ -139,7 +139,7 @@ export class HushijiandanComponent implements OnInit {
139 139
   timerCloseTime = null;
140 140
   changeShow = true;
141 141
   currentHospital; //当前院区
142
-  currentUser; //当前用户
142
+  currentDept; //当前科室
143 143
   logTimer = null; //综合日志定时器
144 144
   logTime = 0; //综合日志自动刷新秒数
145 145
   logTimeConst = 60; //综合日志自动刷新秒数
@@ -157,10 +157,10 @@ export class HushijiandanComponent implements OnInit {
157 157
     });
158 158
     this.getItsmIncident();
159 159
     this.getUpdateTipsForNurses();
160
-    this.getSpecimenButton();
161 160
     this.getCloseTimeFlag();
162
-    this.currentUser = this.tool.getCurrentUserDept();
163
-    console.log(this.currentUser, this.tabSearchCont);
161
+    this.currentDept = this.tool.getCurrentUserDept();
162
+    console.log(this.currentDept, this.tabSearchCont);
163
+    this.getSpecimenButton();
164 164
     //防抖
165 165
     this.searchTabInpSubject.pipe(debounceTime(500)).subscribe((v) => {
166 166
       this.getPatient(v);
@@ -445,6 +445,9 @@ export class HushijiandanComponent implements OnInit {
445 445
   // 获取护士端更新提示
446 446
   specimenButton = "";
447 447
   getSpecimenButton() {
448
+    if(this.currentDept.typeValue == 'surgery'){
449
+      return;
450
+    }
448 451
     let postData = {
449 452
       idx: 0,
450 453
       sum: 1,
@@ -538,6 +541,9 @@ export class HushijiandanComponent implements OnInit {
538 541
   yyDate = null; //预约日期-陪检
539 542
   yyDateZy = null; //预约日期-转运
540 543
   getRecentInfo(patientCode) {
544
+    if(this.currentDept.typeValue == 'surgery'){
545
+      return;
546
+    }
541 547
     this.recentInfo = "";
542 548
     clearTimeout(this.recentInfoTimer);
543 549
     this.recentInfoTimer = setTimeout(() => {
@@ -721,6 +727,9 @@ export class HushijiandanComponent implements OnInit {
721 727
 
722 728
   // 急标普标数量
723 729
   getSpecimenWorkOrderMsg() {
730
+    if(this.currentDept.typeValue == 'surgery'){
731
+      return;
732
+    }
724 733
     let that = this;
725 734
 
726 735
     that.mainService
@@ -735,6 +744,9 @@ export class HushijiandanComponent implements OnInit {
735 744
   // 药品静配提示信息
736 745
   drugJpLoading = false;
737 746
   getJpDrugsWKOMsg() {
747
+    if(this.currentDept.typeValue == 'surgery'){
748
+      return;
749
+    }
738 750
     let that = this;
739 751
     this.drugJpLoading = true;
740 752
     that.mainService
@@ -1143,9 +1155,9 @@ export class HushijiandanComponent implements OnInit {
1143 1155
   snum = 0;
1144 1156
   getPatient(e?) {
1145 1157
     if (
1146
-      (this.currentUser.typeValue == "checkRoom2" ||
1147
-        this.currentUser.typeValue == "outpatientDept" ||
1148
-        this.currentUser.typeValue == "checkRoom") &&
1158
+      (this.currentDept.typeValue == "checkRoom2" ||
1159
+        this.currentDept.typeValue == "outpatientDept" ||
1160
+        this.currentDept.typeValue == "checkRoom") &&
1149 1161
       !this.tabSearchCont
1150 1162
     ) {
1151 1163
       this.pLoading = false;
@@ -1159,29 +1171,32 @@ export class HushijiandanComponent implements OnInit {
1159 1171
       sum: 10,
1160 1172
     };
1161 1173
     // 患者信息
1162
-    postData["patient"] = {
1163
-      keyWord: e ? e : this.tabSearchCont,
1174
+    postData["surgery"] = {
1175
+      searchKey: e ? e : this.tabSearchCont,
1176
+      applyDateStart: format(startOfDay(new Date()), "yyyy-MM-dd HH:mm:ss"),
1177
+      applyDateEnd: format(endOfDay(new Date()), "yyyy-MM-dd HH:mm:ss"),
1178
+      hosId: this.currentHospital.id,
1164 1179
     };
1165 1180
     // 查询父级科室患者
1166
-    postData["patient"]["parentIdOnly"] = true;
1181
+    // postData["surgery"]["parentIdOnly"] = true;
1167 1182
     if (
1168
-      this.currentUser.typeValue == "checkRoom2" ||
1169
-      this.currentUser.typeValue == "outpatientDept" ||
1170
-      this.currentUser.typeValue == "checkRoom"
1183
+      this.currentDept.typeValue == "checkRoom2" ||
1184
+      this.currentDept.typeValue == "outpatientDept" ||
1185
+      this.currentDept.typeValue == "checkRoom"
1171 1186
     ) {
1172
-      delete postData["patient"]["department"]; //搜索范围为全院在院患者
1187
+      delete postData["surgery"]["surgeryDept"]; //搜索范围为全院在院患者
1173 1188
     } else {
1174
-      postData["patient"]["department"] = { id: this.loginUserDeptId };
1189
+      postData["surgery"]["surgeryDept"] = this.loginUserDeptId;
1175 1190
     }
1176 1191
     this.snum++;
1177 1192
     this.mainService
1178
-      .getFetchDataList("nurse", "patient", postData)
1193
+      .getFetchDataList("simple/data", "surgery", postData)
1179 1194
       .subscribe((data) => {
1180 1195
         this.snum--;
1181 1196
         if (data.list.length > 0) {
1182 1197
           data.list.forEach((item) => {
1183
-            if (item.focusPatient === undefined) {
1184
-              item.focusPatient = 0;
1198
+            if (item.patientDTO && item.patientDTO.focusPatient === undefined) {
1199
+              item.patientDTO.focusPatient = 0;
1185 1200
             }
1186 1201
           });
1187 1202
         }
@@ -1380,6 +1395,54 @@ export class HushijiandanComponent implements OnInit {
1380 1395
       return { required: true };
1381 1396
     }
1382 1397
   };
1398
+  pickUpModal: boolean = false; //模态框
1399
+  pickUpItem: any = {};
1400
+  hidePickUpModal() {
1401
+    this.pickUpModal = false;
1402
+  }
1403
+  // 确认
1404
+  confirmPickUp() {
1405
+    console.log(this.pickUpItem);
1406
+    return;
1407
+    this.showPromptModal("创建", true, "");
1408
+    this.getOrderList();
1409
+    this.getDeptTaskType();
1410
+    this.getTodayNum();
1411
+    // var that = this;
1412
+    // that.btnLoading = true;
1413
+    // that.mainService
1414
+    //   .coopData(
1415
+    //     "rmvData",
1416
+    //     "department",
1417
+    //     1
1418
+    //   )
1419
+    //   .subscribe((data) => {
1420
+    //     that.btnLoading = false;
1421
+    //     that.pickUpModal = false;
1422
+    //     if (data.data && data.data[0]) {
1423
+    //       if (!data.data[0].msg) {
1424
+    //         if (
1425
+    //           that.listOfData.length == 1 &&
1426
+    //           that.pageIndex == Math.ceil(that.listLength / that.pageSize)
1427
+    //         ) {
1428
+    //           that.listLength--;
1429
+    //           that.pageIndex = Math.ceil(that.listLength / that.pageSize);
1430
+    //         }
1431
+    //         that.showPromptModal("删除", true, "");
1432
+    //       } else {
1433
+    //         that.showPromptModal("删除", false, data.data[0].msg);
1434
+    //       }
1435
+    //     } else {
1436
+    //       that.showPromptModal("删除", false, "");
1437
+    //     }
1438
+    //   });
1439
+  }
1440
+  // 手术安排信息-一键接患者
1441
+  pickUpPatient(e, item){
1442
+    e.stopPropagation();
1443
+    this.pickUpModal = true;
1444
+    this.pickUpItem = item;
1445
+  }
1383 1446
 
1384 1447
   // 患者信息一键建单
1385 1448
   patientModal: boolean = false; //患者信息一键建单模态框

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

@@ -108,6 +108,14 @@ const routes: Routes = [
108 108
           ),
109 109
       },
110 110
       {
111
+        // 手术页面控制
112
+        path: "operationConfig",
113
+        loadChildren: () =>
114
+          import("../operation-config/operation-config.module").then(
115
+            (m) => m.OperationConfigModule
116
+          ),
117
+      },
118
+      {
111 119
         // 工作分配方案列表
112 120
         path: "workAssignment",
113 121
         loadChildren: () =>

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

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

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

@@ -0,0 +1,50 @@
1
+<div class="TaskTypeManagement">
2
+  <div class="taskTypeInfo">
3
+    <div class="top">
4
+      <div class="item" (click)="tabModal('characteristics')" [ngClass]="{'items':tabModalName=='characteristics'}">
5
+        特性配置
6
+      </div>
7
+      <div class="item" (click)="tabModal('automaticOrderCreation')" [ngClass]="{'items':tabModalName=='automaticOrderCreation'}">
8
+        自动建单配置
9
+      </div>
10
+    </div>
11
+    <div class="list" *ngIf="!loading">
12
+      <!-- 特性配置 -->
13
+      <div *ngIf="tabModalName=='characteristics'">
14
+        <!-- 接手术关联任务类型 -->
15
+        <div class="display_flex align-items_center">
16
+          <nz-form-label class="label" nzRequired>接手术关联任务类型</nz-form-label>
17
+          <nz-select class="w320px" [nzDropdownMatchSelectWidth]="false" nzServerSearch nzShowSearch
18
+            (nzOnSearch)="changeTasktype($event)" nzPlaceHolder="请选择接手术关联任务类型" [(ngModel)]="tasktypeId">
19
+            <ng-container *ngFor="let option of taskTypes">
20
+              <nz-option *ngIf="!isLoading" [nzLabel]="option.taskName" [nzValue]="option.id"></nz-option>
21
+            </ng-container>
22
+            <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
23
+              <i nz-icon nzType="loading" class="loading-icon"></i> 搜索中...
24
+            </nz-option>
25
+          </nz-select>
26
+        </div>
27
+      </div>
28
+      <!-- 自动建单配置 -->
29
+      <div *ngIf="tabModalName=='automaticOrderCreation'">
30
+        <!-- 自动建单 -->
31
+        <div class="display_flex align-items_center mb8">
32
+          <nz-form-label class="label">自动建单</nz-form-label>
33
+          <nz-checkbox-group [(ngModel)]="autoCreateOrders" (ngModelChange)="changeAutoCreateOrders($event)"></nz-checkbox-group>
34
+          <nz-time-picker [(ngModel)]="autoTime" nzFormat="HH:mm" *ngIf="autoCreateOrders[0].checked"></nz-time-picker>
35
+        </div>
36
+      </div>
37
+      <div class="bottom">
38
+        <button class="login-form-button" nzType="primary" [nzLoading]="btnLoading" nz-button (click)="submitForm()">保存</button>
39
+      </div>
40
+    </div>
41
+    <div class="list" *ngIf="loading">
42
+      <div class="loadingFull display_flex justify-content_flex-center align-items_center">
43
+        <div class="loadingFullInner">
44
+          <img src="../../../assets/images/loading.gif" alt="">
45
+          <div>加载中...</div>
46
+        </div>
47
+      </div>
48
+    </div>
49
+  </div>
50
+</div>

文件差異過大導致無法顯示
+ 1251 - 0
src/app/views/operation-config/operation-config.component.less


+ 161 - 0
src/app/views/operation-config/operation-config.component.ts

@@ -0,0 +1,161 @@
1
+import { Component, OnInit } from "@angular/core";
2
+import { MainService } from 'src/app/services/main.service';
3
+import { ToolService } from 'src/app/services/tool.service';
4
+import { NzMessageService } from 'ng-zorro-antd';
5
+import { Subject } from 'rxjs';
6
+import { debounceTime } from 'rxjs/operators';
7
+import { format } from 'date-fns';
8
+
9
+@Component({
10
+  selector: "app-operation-config",
11
+  templateUrl: "./operation-config.component.html",
12
+  styleUrls: ["./operation-config.component.less"],
13
+})
14
+export class OperationConfigComponent implements OnInit {
15
+  loading:boolean = false; //页面加载的loading
16
+  btnLoading:boolean = false; //提交按钮的loading
17
+  tabModalName:string = 'characteristics'; //当前选中的tab
18
+  surgeryField = null; //手术关联业务
19
+  hosId = this.tool.getCurrentHospital().id; //当前院区
20
+  // 接手术关联任务类型
21
+  tasktypeId:any;
22
+  taskTypes:any[] = [];
23
+  // 自动建单
24
+  autoCreateOrders:any[] = [
25
+    {label:'是否开启',value: 0}
26
+  ];
27
+  // 建单时间
28
+  autoTime:Date | null = null;
29
+  // 配置
30
+  configs:any = {};
31
+  searchTimerSubject = new Subject();
32
+  constructor(private mainService: MainService,private tool: ToolService,private msg: NzMessageService) {}
33
+
34
+  ngOnInit():void {
35
+    // todo
36
+    this.searchTimerSubject.pipe(debounceTime(500)).subscribe((v) => {
37
+      let fun = v[0];
38
+      fun.call(this, v[1]);
39
+    });
40
+    this.getTaskTypes('', true);
41
+  }
42
+
43
+  // 切换tab
44
+  tabModal(tabModalName:string){
45
+    this.tabModalName = tabModalName;
46
+  }
47
+  // 修改是否自动建单
48
+  changeAutoCreateOrders(e){
49
+    console.log(e);
50
+    if(!e[0].checked){
51
+      // todo
52
+      this.autoTime = null;
53
+    }
54
+  }
55
+
56
+  // 保存
57
+  submitForm() {
58
+    if(!this.tasktypeId){
59
+      this.msg.create("warning", "请选择接手术关联任务类型!");
60
+      return;
61
+    }
62
+    if(this.autoCreateOrders[0].checked && !this.autoTime){
63
+      this.msg.create("warning", "请选择建单时间!");
64
+      return;
65
+    }
66
+    let postData:any = {
67
+      id: this.configs.id,
68
+      hosId: this.hosId,
69
+      autoCreate: this.autoCreateOrders[0].checked ? 1 : 0,
70
+      taskType: this.tasktypeId || undefined,
71
+      createTime: this.autoTime ? format(this.autoTime, "yyyy-MM-dd HH:mm:ss") : undefined,
72
+      ordinaryField: this.surgeryField
73
+    };
74
+    console.log(postData);
75
+    this.btnLoading = true;
76
+    this.mainService
77
+      .simplePost("addData", "taskTypeConfig", postData)
78
+      .subscribe((result) => {
79
+        this.btnLoading = false;
80
+        if (result.status == 200) {
81
+          this.getConfig();
82
+        }
83
+      });
84
+  }
85
+
86
+  // 用户输入搜索任务类型
87
+  isLoading: boolean = false;
88
+  changeTasktype(e) {
89
+    this.searchTimer(this.getTaskTypes, e);
90
+  }
91
+
92
+  // 边输入边搜索节流阀
93
+  searchTimer(fun, e) {
94
+    this.isLoading = true;
95
+    this.searchTimerSubject.next([fun, e]);
96
+  }
97
+
98
+  //获取接手术关联任务类型
99
+  getTaskTypes(e:string = '', isFirst:boolean = false) {
100
+    this.loading = true;
101
+    let postData = {
102
+      idx: 0,
103
+      sum: 1000,
104
+      taskType: {
105
+        taskName: e,
106
+        simpleQuery: true,
107
+        hosId: {
108
+          id: this.hosId
109
+        },
110
+        associationType: {
111
+          key: 'association_types',
112
+          value: 'patientTransport'
113
+        }
114
+      }
115
+    };
116
+    this.isLoading = true;
117
+    this.mainService
118
+      .getFetchDataList("simple/data", "taskType", postData)
119
+      .subscribe((result) => {
120
+        this.isLoading = false;
121
+        if (result.status == 200) {
122
+          this.taskTypes = result.list || [];
123
+          isFirst && this.getConfig();
124
+        }
125
+      });
126
+  }
127
+  // 获取配置
128
+  getConfig() {
129
+    this.loading = true;
130
+    this.mainService
131
+      .getDictionary("list", "ordinary_field")
132
+      .subscribe((data) => {
133
+        this.surgeryField = data.find(v => v.value == 'surgery');
134
+        if(this.surgeryField){
135
+          let postData = {
136
+            idx: 0,
137
+            sum: 10,
138
+            taskTypeConfig: {
139
+              hosId: this.hosId,
140
+              ordinaryField: this.surgeryField
141
+            }
142
+          };
143
+          this.mainService
144
+            .getFetchDataList("simple/data", "taskTypeConfig", postData)
145
+            .subscribe((result) => {
146
+              this.loading = false;
147
+              if (result.status == 200) {
148
+                this.configs = result.list[0] || {};
149
+                this.tasktypeId = this.configs.taskTypeDTO ? this.configs.taskTypeDTO.id : null;
150
+                this.autoCreateOrders[0].checked = this.configs.autoCreate == 1;
151
+                this.autoTime = this.configs.createTime ? new Date(this.configs.createTime) : null;
152
+              }
153
+            });
154
+        }else{
155
+          this.loading = false;
156
+        }
157
+      });
158
+  }
159
+}
160
+
161
+

+ 17 - 0
src/app/views/operation-config/operation-config.module.ts

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

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

@@ -52,9 +52,9 @@
52 52
         </div>
53 53
         <nz-form-label class="label" nzRequired>关联类型</nz-form-label>
54 54
         <!-- 关联类型禁止修改 -->
55
-        <nz-select class="mb8 w100" nzShowSearch nzAllowClear nzPlaceHolder="请选择关联类型" [(ngModel)]="association.id"
55
+        <nz-select class="mb8 w100" nzShowSearch nzPlaceHolder="请选择关联类型" [(ngModel)]="association" [compareWith]="compareFn"
56 56
           (ngModelChange)="asso(association)" [nzDisabled]="!add">
57
-          <nz-option nzLabel="{{data.name}}" nzValue="{{data.id}}" *ngFor="let data of allAssociation"></nz-option>
57
+          <nz-option [nzLabel]="data.name" [nzValue]="data" *ngFor="let data of allAssociation"></nz-option>
58 58
         </nz-select>
59 59
         <ng-container *ngIf="association.value == 'ordinary'">
60 60
           <nz-form-label class="label" nzRequired>关联业务</nz-form-label>

+ 11 - 14
src/app/views/task-type-management/task-type-management.component.ts

@@ -82,10 +82,7 @@ export class TaskTypeManagementComponent implements OnInit {
82 82
   allScheduleClass; //班次列表
83 83
   //基础信息详情字段
84 84
   taskName; //任务名称
85
-  association: any = {
86
-    id: "",
87
-    value: "",
88
-  }; //关联类型
85
+  association: any = {}; //关联类型
89 86
   relatedBusiness: any = {
90 87
     id: "",
91 88
     value: "",
@@ -606,6 +603,7 @@ export class TaskTypeManagementComponent implements OnInit {
606 603
       this.getSearchTaskList();
607 604
     }
608 605
   }
606
+  compareFn = (o1: any, o2: any) => (o1 && o2 ? o1.id === o2.id : o1 === o2);
609 607
   //选择类型
610 608
   currentChoice;
611 609
   itemChoice(data, index) {
@@ -613,13 +611,6 @@ export class TaskTypeManagementComponent implements OnInit {
613 611
     if (data === undefined) {
614 612
       return;
615 613
     }
616
-    this.getType();
617
-    this.departments = [];
618
-    this.mapOfCheckedId = {};
619
-    this.pageIndex = 1;
620
-    this.styleType = true;
621
-    this.styleDes(this.styleType);
622
-    this.createRuleConfiguration = [];
623 614
     this.index = index;
624 615
     this.allTaskTypeShow = data.taskName;
625 616
     this.currentChoice = data;
@@ -629,8 +620,14 @@ export class TaskTypeManagementComponent implements OnInit {
629 620
     };
630 621
     this.taskData.taskType["id"] = data.id;
631 622
     this.taskName = data.taskName;
632
-    this.association.id = data.associationType.id + "";
633
-    this.association.value = data.associationType.value;
623
+    this.association = data.associationType;
624
+    this.getType();
625
+    this.departments = [];
626
+    this.mapOfCheckedId = {};
627
+    this.pageIndex = 1;
628
+    this.styleType = true;
629
+    this.styleDes(this.styleType);
630
+    this.createRuleConfiguration = [];
634 631
     if(data.ordinaryField){
635 632
       this.relatedBusiness.id = data.ordinaryField.id + "";
636 633
       this.relatedBusiness.value = data.ordinaryField.value;
@@ -1208,7 +1205,7 @@ export class TaskTypeManagementComponent implements OnInit {
1208 1205
     this.departmentIds = "";
1209 1206
     this.departmentTypeIds = "";
1210 1207
     this.taskName = ""; //任务名称
1211
-    this.association.id = null; //关联类型
1208
+    this.association = {}; //关联类型
1212 1209
     this.getAllGoods(); //获取携带设备
1213 1210
     this.getAllScheduleClass(); //获取班次列表
1214 1211
     this.allowUrgent = "1"; //是否加急

+ 1 - 1
src/main.ts

@@ -8,7 +8,7 @@ if (environment.production) {
8 8
   enableProdMode();
9 9
   if (window) {
10 10
     window.console.log = function () { };
11
-    console.info('v2.4.27');
11
+    console.info('v2.4.28');
12 12
   }
13 13
 }
14 14
 platformBrowserDynamic().bootstrapModule(AppModule)