瀏覽代碼

工作分配自选排班工作组合增加科室绑定分组和绑定分组

seimin 3 年之前
父節點
當前提交
629db3efee

+ 170 - 38
src/app/views/group-management/group-management.component.html

@@ -2,47 +2,95 @@
2 2
   <div class="groupInfo">
3 3
     <div class="title">分组信息</div>
4 4
     <div class="operate">
5
-      <div *ngIf="coopBtns.add" class="add item" (click)="showCoopModal('add')">新增</div>
6
-      <div *ngIf="coopBtns.edit" class="edit item" (click)="showCoopModal('edit')">编辑</div>
7
-      <div *ngIf="coopBtns.del" class="del item" (click)="showDelModal()">删除</div>
5
+      <div *ngIf="coopBtns.add" class="add item" (click)="showCoopModal('add')">
6
+        新增
7
+      </div>
8
+      <div
9
+        *ngIf="coopBtns.edit"
10
+        class="edit item"
11
+        (click)="showCoopModal('edit')"
12
+      >
13
+        编辑
14
+      </div>
15
+      <div *ngIf="coopBtns.del" class="del item" (click)="showDelModal()">
16
+        删除
17
+      </div>
8 18
     </div>
9
-    <div class="groups" [ngStyle]="{display:!loading1?'block':'none'}">
10
-      <overlay-scrollbars #osComponentRef1 [ngStyle]="{ height:'100%' }">
11
-        <div [ngClass]="{'item':true,'checked':data.id==checkedGroup.id}" *ngFor="let data of groupList"
12
-          (click)="checkGroup(data)" [title]="data.scheduleClass.name+' '+data.groupName">
13
-          {{data.scheduleClass.name}} {{data.groupName}}</div>
19
+    <div class="groups" [ngStyle]="{ display: !loading1 ? 'block' : 'none' }">
20
+      <overlay-scrollbars #osComponentRef1 [ngStyle]="{ height: '100%' }">
21
+        <div
22
+          [ngClass]="{ item: true, checked: data.id == checkedGroup.id }"
23
+          *ngFor="let data of groupList"
24
+          (click)="checkGroup(data)"
25
+          [title]="data.scheduleClass.name + ' ' + data.groupName"
26
+        >
27
+          {{ data.scheduleClass.name }} {{ data.groupName }}
28
+        </div>
14 29
       </overlay-scrollbars>
15 30
     </div>
16 31
     <div class="groups" *ngIf="loading1">
17
-      <div class="loadingFull display_flex justify-content_flex-center align-items_center">
32
+      <div
33
+        class="loadingFull display_flex justify-content_flex-center align-items_center"
34
+      >
18 35
         <div class="loadingFullInner">
19
-          <img src="../../../assets/images/loading.gif" alt="">
36
+          <img src="../../../assets/images/loading.gif" alt="" />
20 37
           <div>加载中...</div>
21 38
         </div>
22 39
       </div>
23 40
     </div>
24 41
   </div>
25 42
   <div class="userInfo">
26
-    <div class="top display_flex justify-content_space-between align-items_center">
43
+    <div
44
+      class="top display_flex justify-content_space-between align-items_center"
45
+    >
27 46
       <div class="display_flex align-items_center">
28 47
         <span>用户信息:</span>
29
-        <input nz-input placeholder="请输入用户信息" [(ngModel)]="searchName" nzSize="default"
30
-          (ngModelChange)="searchInp($event)" />
48
+        <input
49
+          nz-input
50
+          placeholder="请输入用户信息"
51
+          [(ngModel)]="searchName"
52
+          nzSize="default"
53
+          (ngModelChange)="searchInp($event)"
54
+        />
31 55
       </div>
32 56
       <div class="display_flex align-items_center">
33
-        <span>已选择 {{usersArr.length}} 人</span>
34
-        <button class="btn default" *ngIf="coopBtns.edit&&groupList.length" nzType="primary" nz-button
35
-          [nzLoading]="saveLoading" (click)="save()">保存</button>
57
+        <span>已选择 {{ usersArr.length }} 人</span>
58
+        <button
59
+          class="btn default"
60
+          *ngIf="coopBtns.edit && groupList.length"
61
+          nzType="primary"
62
+          nz-button
63
+          [nzLoading]="saveLoading"
64
+          (click)="save()"
65
+        >
66
+          保存
67
+        </button>
36 68
       </div>
37 69
     </div>
38 70
     <div class="table" *ngIf="!loading1">
39
-      <nz-table class="groupManagementTable" #rowSelectionTable [nzPageSize]="9999" [nzData]="allUserList"
40
-        [nzShowPagination]="false" #fixedTable [nzScroll]="{ y: tableHeight+'px' }" [nzLoading]="loading2">
71
+      <nz-table
72
+        class="groupManagementTable"
73
+        #rowSelectionTable
74
+        [nzPageSize]="9999"
75
+        [nzData]="allUserList"
76
+        [nzShowPagination]="false"
77
+        #fixedTable
78
+        [nzScroll]="{ y: tableHeight + 'px' }"
79
+        [nzLoading]="loading2"
80
+      >
41 81
         <tbody>
42
-          <tr *ngFor="let data of rowSelectionTable.data" (click)="selectedUser(data)">
43
-            <td style="text-align: left;cursor: pointer;" nzShowCheckbox [(nzDisabled)]="!coopBtns.edit"
44
-              [(nzChecked)]="mapOfCheckedId[data.id]" (nzCheckedChange)="refreshStatus()"></td>
45
-            <td>{{data.dept.dept}} {{ data.name }}</td>
82
+          <tr
83
+            *ngFor="let data of rowSelectionTable.data"
84
+            (click)="selectedUser(data)"
85
+          >
86
+            <td
87
+              style="text-align: left; cursor: pointer"
88
+              nzShowCheckbox
89
+              [(nzDisabled)]="!coopBtns.edit"
90
+              [(nzChecked)]="mapOfCheckedId[data.id]"
91
+              (nzCheckedChange)="refreshStatus()"
92
+            ></td>
93
+            <td>{{ data.dept.dept }} {{ data.name }}</td>
46 94
           </tr>
47 95
         </tbody>
48 96
       </nz-table>
@@ -50,43 +98,127 @@
50 98
   </div>
51 99
 
52 100
   <!-- 新增/编辑模态框 -->
53
-  <div class="save display_flex justify-content_flex-center align-items_center add" *ngIf="coopModal">
101
+  <div
102
+    class="save display_flex justify-content_flex-center align-items_center add"
103
+    *ngIf="coopModal"
104
+  >
54 105
     <div class="modalBody">
55
-      <div class="title">{{add?'新增':'编辑'}}分组信息<i class="icon_transport transport-guanbi" (click)="hideCoopModal()"></i>
106
+      <div class="title">
107
+        {{ add ? "新增" : "编辑" }}分组信息<i
108
+          class="icon_transport transport-guanbi"
109
+          (click)="hideCoopModal()"
110
+        ></i>
56 111
       </div>
57 112
       <div class="content">
58
-        <form nz-form [formGroup]="validateForm" class="addForm" (ngSubmit)="submitForm()">
113
+        <form
114
+          nz-form
115
+          [formGroup]="validateForm"
116
+          class="addForm"
117
+          (ngSubmit)="submitForm()"
118
+        >
59 119
           <nz-form-item>
60
-            <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="classes">所属班次</nz-form-label>
120
+            <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="classes"
121
+              >所属班次</nz-form-label
122
+            >
61 123
             <nz-form-control nzErrorTip="请选择所属班次!">
62
-              <nz-select [nzDropdownMatchSelectWidth]="false" formControlName="classes" nzShowSearch nzAllowClear
63
-                nzPlaceHolder="请选择所属班次">
64
-                <nz-option nzLabel="{{data.name}}" nzValue="{{data.id}}" *ngFor="let data of scheduleList"></nz-option>
124
+              <nz-select
125
+                [nzDropdownMatchSelectWidth]="false"
126
+                formControlName="classes"
127
+                nzShowSearch
128
+                nzAllowClear
129
+                nzPlaceHolder="请选择所属班次"
130
+              >
131
+                <nz-option
132
+                  nzLabel="{{ data.name }}"
133
+                  nzValue="{{ data.id }}"
134
+                  *ngFor="let data of scheduleList"
135
+                ></nz-option>
65 136
               </nz-select>
66 137
             </nz-form-control>
67 138
           </nz-form-item>
68 139
           <nz-form-item>
69
-            <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="groupName">分组名称</nz-form-label>
140
+            <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="groupName"
141
+              >分组名称</nz-form-label
142
+            >
70 143
             <nz-form-control nzErrorTip="请输入分组名称!">
71 144
               <nz-input-group>
72
-                <input type="groupName" nz-input formControlName="groupName" placeholder="请输入分组名称" />
145
+                <input
146
+                  type="groupName"
147
+                  nz-input
148
+                  formControlName="groupName"
149
+                  placeholder="请输入分组名称"
150
+                />
73 151
               </nz-input-group>
74 152
             </nz-form-control>
75 153
           </nz-form-item>
154
+          <nz-form-item>
155
+            <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="groupLeader"
156
+              >分组组长</nz-form-label
157
+            >
158
+            <nz-form-control nzErrorTip="请输入分组组长!">
159
+              <nz-select
160
+                [nzDropdownMatchSelectWidth]="false"
161
+                class="formItem"
162
+                nzServerSearch
163
+                nzShowSearch
164
+                nzAllowClear
165
+                nzPlaceHolder="请选择分组组长"
166
+                formControlName="groupLeader"
167
+                (nzOnSearch)="changeInp($event)"
168
+                (nzOpenChange)="changeSearch($event)"
169
+              >
170
+                <ng-container *ngFor="let data of userList">
171
+                  <nz-option
172
+                    *ngIf="!isLoading"
173
+                    nzLabel="{{ data.name }}"
174
+                    nzValue="{{ data.id }}"
175
+                  ></nz-option>
176
+                </ng-container>
177
+                <nz-option *ngIf="isLoading" nzDisabled nzCustomContent>
178
+                  <i nz-icon nzType="loading" class="loading-icon"></i>
179
+                  搜索中...
180
+                </nz-option>
181
+              </nz-select>
182
+            </nz-form-control>
183
+          </nz-form-item>
76 184
         </form>
77 185
       </div>
78
-      <div class=" display_flex justify-content_flex-center">
79
-        <button nzType="primary" [nzLoading]="btnLoading" nz-button (click)="submitForm()">确认</button>
80
-        <button class="btn cancel" nz-button nzType="default" (click)="hideCoopModal()">取消</button>
186
+      <div class="display_flex justify-content_flex-center">
187
+        <button
188
+          nzType="primary"
189
+          [nzLoading]="btnLoading"
190
+          nz-button
191
+          (click)="submitForm()"
192
+        >
193
+          确认
194
+        </button>
195
+        <button
196
+          class="btn cancel"
197
+          nz-button
198
+          nzType="default"
199
+          (click)="hideCoopModal()"
200
+        >
201
+          取消
202
+        </button>
81 203
       </div>
82 204
     </div>
83 205
   </div>
84 206
   <!-- 删除模态框 -->
85
-  <app-dialog-delete [delModal]="delModal" (hideDelModalEvent)="hideDelModal()" [btnLoading]="btnLoading"
86
-    (confirmDelEvent)="confirmDel()" content="您确认要删除此分组吗?"></app-dialog-delete>
207
+  <app-dialog-delete
208
+    [delModal]="delModal"
209
+    (hideDelModalEvent)="hideDelModal()"
210
+    [btnLoading]="btnLoading"
211
+    (confirmDelEvent)="confirmDel()"
212
+    content="您确认要删除此分组吗?"
213
+  ></app-dialog-delete>
87 214
 </div>
88 215
 
89 216
 <!-- 操作成功/失败提示框 -->
90
-<app-prompt-modal *ngIf="promptModalShow" [content]="promptContent" [success]="ifSuccess" [show]="promptModalShow"
91
-  [info]="promptInfo">
217
+<app-prompt-modal
218
+  *ngIf="promptModalShow"
219
+  [content]="promptContent"
220
+  [success]="ifSuccess"
221
+  [show]="promptModalShow"
222
+  [info]="promptInfo"
223
+>
92 224
 </app-prompt-modal>

+ 67 - 11
src/app/views/group-management/group-management.component.ts

@@ -6,6 +6,8 @@ import { NzMessageService } from "ng-zorro-antd/message";
6 6
 import { MainService } from "../../services/main.service";
7 7
 import { OverlayScrollbarsComponent } from "overlayscrollbars-ngx";
8 8
 import { ToolService } from "../../services/tool.service";
9
+import { Subject } from "rxjs";
10
+import { debounceTime } from "rxjs/operators";
9 11
 
10 12
 @Component({
11 13
   selector: "app-group-management",
@@ -28,6 +30,11 @@ export class GroupManagementComponent implements OnInit {
28 30
   })
29 31
   osComponentRef1: OverlayScrollbarsComponent;
30 32
   ngOnInit() {
33
+    this.changeInpSubject
34
+      .pipe(debounceTime(500))
35
+      .subscribe((keyword: string) => {
36
+        this.getUserList(keyword);
37
+      });
31 38
     this.coopBtns = this.tool.initCoopBtns(this.route);
32 39
     this.initForm();
33 40
     this.getHospitalList();
@@ -46,6 +53,7 @@ export class GroupManagementComponent implements OnInit {
46 53
   hospitalList: Array<any> = []; //院区列表
47 54
   hosId: any; //当前选择的院区id
48 55
   scheduleList: Array<any> = []; //班次列表
56
+  userList: Array<any> = []; //用户列表
49 57
   searchName: string = ""; //用户信息搜索输入框
50 58
 
51 59
   promptContent: string; //操作提示框提示信息
@@ -55,10 +63,24 @@ export class GroupManagementComponent implements OnInit {
55 63
 
56 64
   btnLoading: boolean = false; //确认按钮loading状态
57 65
   saveLoading: boolean = false; //批量打印按钮loading状态
66
+  changeInpSubject = new Subject();
58 67
 
59 68
   // 初始化增删改按钮
60 69
   coopBtns: any = {};
61 70
 
71
+  // 边输边搜节流阀
72
+  isLoading = false;
73
+  changeInp(keyword: string = "") {
74
+    this.isLoading = true;
75
+    this.changeInpSubject.next(keyword);
76
+  }
77
+  // 打开搜索框
78
+  changeSearch(flag) {
79
+    if (flag) {
80
+      this.changeInp();
81
+    }
82
+  }
83
+
62 84
   // 分组列表
63 85
   loading1 = false;
64 86
   getGroupList() {
@@ -162,6 +184,26 @@ export class GroupManagementComponent implements OnInit {
162 184
         this.scheduleList = data.list;
163 185
       });
164 186
   }
187
+  // 用户列表
188
+  getUserList(keyword: string = "") {
189
+    const data = {
190
+      idx: 0,
191
+      user: {
192
+        hospital: { id: this.hosId },
193
+        name: keyword,
194
+        simpleQuery: true,
195
+      },
196
+      sum: 5,
197
+    };
198
+    this.mainService
199
+      .getFetchDataList("data", "user", data)
200
+      .subscribe((result) => {
201
+        this.isLoading = false;
202
+        if (result.status == 200) {
203
+          this.userList = result.list;
204
+        }
205
+      });
206
+  }
165 207
 
166 208
   // 选中分组
167 209
   positionY = 0; //记录其他建单Y轴滚动距离
@@ -229,23 +271,35 @@ export class GroupManagementComponent implements OnInit {
229 271
   coopModal: boolean = false; //模态框是否展示
230 272
   add: boolean = true; //true:新增;false:编辑
231 273
   showCoopModal(type) {
232
-    let that = this;
233
-    if (type == "edit" && !that.checkedGroup["groupName"]) {
234
-      that.msg.create("warning", "请选择需要编辑的分组!");
274
+    if (type == "edit" && !this.checkedGroup["groupName"]) {
275
+      this.msg.create("warning", "请选择需要编辑的分组!");
235 276
       return;
236 277
     }
237
-    that.coopModal = true;
238
-    that.add = type == "add";
278
+    this.coopModal = true;
279
+    this.add = type == "add";
239 280
     if (type == "edit") {
240
-      that.validateForm.controls.classes.setValue(
241
-        that.checkedGroup["scheduleClass"].id + ""
281
+      this.validateForm.controls.classes.setValue(
282
+        this.checkedGroup["scheduleClass"].id + ""
242 283
       );
243
-      that.validateForm.controls.groupName.setValue(
244
-        that.checkedGroup["groupName"]
284
+      this.validateForm.controls.groupName.setValue(
285
+        this.checkedGroup["groupName"]
245 286
       );
287
+      this.mainService
288
+        .getFetchData("data", "user", this.checkedGroup["manager"])
289
+        .subscribe((result) => {
290
+          if (result.status == 200) {
291
+            if (result.data) {
292
+              this.userList.unshift(result.data);
293
+            }
294
+            this.validateForm.controls.groupLeader.setValue(
295
+              this.checkedGroup["manager"].toString()
296
+            );
297
+          }
298
+        });
246 299
     } else {
247
-      that.validateForm.controls.classes.setValue(null);
248
-      that.validateForm.controls.groupName.setValue(null);
300
+      this.validateForm.controls.classes.setValue(null);
301
+      this.validateForm.controls.groupName.setValue(null);
302
+      this.validateForm.controls.groupLeader.setValue(null);
249 303
     }
250 304
   }
251 305
   // 隐藏分组信息模态框
@@ -258,6 +312,7 @@ export class GroupManagementComponent implements OnInit {
258 312
     this.validateForm = this.fb.group({
259 313
       classes: [null, [Validators.required]],
260 314
       groupName: [null, [Validators.required]],
315
+      groupLeader: [null, [Validators.required]],
261 316
     });
262 317
   }
263 318
 
@@ -276,6 +331,7 @@ export class GroupManagementComponent implements OnInit {
276 331
         groupName: that.validateForm.value.groupName,
277 332
         hospital: { id: that.hosId - 0 },
278 333
         scheduleClass: { id: that.validateForm.value.classes - 0 },
334
+        manager: that.validateForm.value.groupLeader,
279 335
       },
280 336
     };
281 337
     if (!that.add) {

+ 11 - 2
src/app/views/quick-combination/quick-combination.component.html

@@ -45,6 +45,7 @@
45 45
             <th nzWidth="16%">工作模式</th>
46 46
             <th nzWidth="10%" *ngIf="queryParamsType==1">科室</th>
47 47
             <th nzWidth="8%" *ngIf="queryParamsType==1">分配人员/组</th>
48
+            <th nzWidth="8%" *ngIf="queryParamsType==2">分配组</th>
48 49
             <th nzWidth="33%">操作</th>
49 50
           </tr>
50 51
         </thead>
@@ -70,6 +71,10 @@
70 71
               <div class="orderPlanTimeShow2" nz-tooltip nzTooltipTitle="{{data.allName?data.allName.join('、'):''}}">
71 72
                 {{data.allName?data.allName.join('、'):''}}</div>
72 73
             </td>
74
+            <td *ngIf="queryParamsType==2">
75
+              <div class="orderPlanTimeShow2" nz-tooltip nzTooltipTitle="{{data.allName?data.allName.join('、'):''}}">
76
+                {{data.allName?data.allName.join('、'):''}}</div>
77
+            </td>
73 78
             <td>
74 79
               <div class="coop">
75 80
                 <span (click)="addPersonModal($event,data)" *ngIf="data.ruleType == 3&&queryParamsType==1">分配人员</span>
@@ -147,6 +152,8 @@
147 152
                 <label nz-radio nzValue="2" *ngIf="queryParamsType==1">指定分组</label>
148 153
                 <label nz-radio nzValue="3">科室绑定人员</label>
149 154
                 <label nz-radio nzValue="4" *ngIf="queryParamsType==1">科室绑定分组</label>
155
+                <label nz-radio nzValue="5" *ngIf="queryParamsType==2">科室绑定分组</label>
156
+                <label nz-radio nzValue="6" *ngIf="queryParamsType==2">绑定分组</label>
150 157
               </nz-radio-group>
151 158
             </nz-form-control>
152 159
           </nz-form-item>
@@ -168,11 +175,13 @@
168 175
               </nz-select>
169 176
             </nz-form-control>
170 177
           </nz-form-item>
171
-          <nz-form-item *ngIf="queryParamsType==1" [hidden]="quickCombinationModel != 2||quickCombinationModel===''">
178
+          <nz-form-item [hidden]="
179
+          (queryParamsType==1&&(quickCombinationModel != 2||quickCombinationModel===''))||
180
+          (queryParamsType==2&&((quickCombinationModel != 5 && quickCombinationModel != 6)||quickCombinationModel===''))">
172 181
             <nz-form-label [nzSm]="6" [nzXs]="24" [nzRequired]="requireGroup" nzFor="quickCombinationGroup">选择分组
173 182
             </nz-form-label>
174 183
             <nz-form-control nzErrorTip="请选择分组!">
175
-              <nz-select [nzMode]="'multiple'" [nzDropdownMatchSelectWidth]="false"
184
+              <nz-select [nzMode]="quickCombinationModel == 6?'default':'multiple'" [nzDropdownMatchSelectWidth]="false"
176 185
                 formControlName="quickCombinationGroup" nzShowSearch nzAllowClear nzPlaceHolder="请选择分组" nzServerSearch
177 186
                 (nzOnSearch)="searchGroupList($event)" (nzOpenChange)="getGroupList($event)"
178 187
                 (ngModelChange)="selectGroupList($event)">

+ 122 - 38
src/app/views/quick-combination/quick-combination.component.ts

@@ -30,6 +30,8 @@ export class QuickCombinationComponent implements OnInit {
30 30
         this.allWorkModel = [
31 31
           { id: 1, name: "自由抢单" },
32 32
           { id: 3, name: "科室绑定人员" },
33
+          { id: 4, name: "科室绑定分组" },
34
+          { id: 2, name: "绑定分组" },
33 35
         ];
34 36
       }
35 37
     });
@@ -193,7 +195,17 @@ export class QuickCombinationComponent implements OnInit {
193 195
               this.validateForm.controls.quickCombinationType.setValue(
194 196
                 this.info.taskTypesId
195 197
               ); //任务类型
196
-              this.quickCombinationModel = this.info.ruleType + "";
198
+              if(this.queryParamsType == 1){
199
+                this.quickCombinationModel = this.info.ruleType + "";
200
+              }else if(this.queryParamsType == 2){
201
+                if(this.info.ruleType == 2){
202
+                  this.quickCombinationModel = '6';
203
+                }else if(this.info.ruleType == 4){
204
+                  this.quickCombinationModel = '5';
205
+                }else{
206
+                  this.quickCombinationModel = this.info.ruleType + "";
207
+                }
208
+              }
197 209
               this.taskListFlag = false;
198 210
               if (!this.copyFlag) {
199 211
                 if (this.info.ruleType == 2) {
@@ -265,7 +277,17 @@ export class QuickCombinationComponent implements OnInit {
265 277
               );
266 278
               console.log(obj);
267 279
               if (obj) {
268
-                this.quickCombinationModel = obj.ruleType + "";
280
+                if(this.queryParamsType == 1){
281
+                  this.quickCombinationModel = obj.ruleType + "";
282
+                }else if(this.queryParamsType == 2){
283
+                  if(obj.ruleType == 2){
284
+                    this.quickCombinationModel = '6';
285
+                  }else if(obj.ruleType == 4){
286
+                    this.quickCombinationModel = '5';
287
+                  }else{
288
+                    this.quickCombinationModel = obj.ruleType + "";
289
+                  }
290
+                }
269 291
                 this.radioIt(1); //选择任务类型
270 292
                 this.taskListFlag = false;
271 293
               } else {
@@ -324,6 +346,17 @@ export class QuickCombinationComponent implements OnInit {
324 346
       this.searchTaskList("");
325 347
     }
326 348
   }
349
+  //对应ruleType与quickCombinationModel
350
+  get quickCombinationModelComputed(){
351
+    console.log(this.quickCombinationModel,'---------------------')
352
+    if(this.quickCombinationModel == 5){//科室绑定分组
353
+      return 4;
354
+    }else if(this.quickCombinationModel == 6){//绑定分组
355
+      return 2;
356
+    }else{
357
+      return this.quickCombinationModel;
358
+    }
359
+  }
327 360
   // 选中工作模式
328 361
   radioIt(flag?) {
329 362
     //undefined 打开复制弹窗,1 选择任务类型
@@ -332,21 +365,29 @@ export class QuickCombinationComponent implements OnInit {
332 365
       // 回显储存的值
333 366
       console.log(this.info, this.quickCombinationModel);
334 367
       if (
335
-        this.info.ruleType == this.quickCombinationModel &&
336
-        this.quickCombinationModel == 2
368
+        this.info.ruleType == this.quickCombinationModelComputed &&
369
+        (this.quickCombinationModel == 2 || this.quickCombinationModel == 5 || this.quickCombinationModel == 6)
337 370
       ) {
338 371
         this.groupList = this.info.groups;
339 372
         if (!this.copyFlag) {
340
-          this.validateForm.controls.quickCombinationGroup.setValue(
341
-            this.info.groupsId
342
-          );
373
+          if(this.quickCombinationModel == 6){
374
+            this.validateForm.controls.quickCombinationGroup.setValue((this.info.groupsId?this.info.groupsId[0] + '':null));
375
+          }else{
376
+            this.validateForm.controls.quickCombinationGroup.setValue(
377
+              this.info.groupsId
378
+            );
379
+          }
343 380
         } else {
344 381
           if (!flag) {
345 382
             this.validateForm.controls.quickCombinationGroup.setValue(null);
346 383
           } else {
347
-            this.validateForm.controls.quickCombinationGroup.setValue(
348
-              this.info.groupsId
349
-            );
384
+            if(this.quickCombinationModel == 6){
385
+              this.validateForm.controls.quickCombinationGroup.setValue((this.info.groupsId?this.info.groupsId[0] + '':null));
386
+            }else{
387
+              this.validateForm.controls.quickCombinationGroup.setValue(
388
+                this.info.groupsId
389
+              );
390
+            }
350 391
           }
351 392
         }
352 393
       }
@@ -388,6 +429,12 @@ export class QuickCombinationComponent implements OnInit {
388 429
     } else if (this.quickCombinationModel == 4) {
389 430
       this.requireGroup = false;
390 431
       this.requireDept = true;
432
+    }else if (this.quickCombinationModel == 5) {
433
+      this.requireGroup = false;
434
+      this.requireDept = false;
435
+    }else if (this.quickCombinationModel == 6) {
436
+      this.requireGroup = false;
437
+      this.requireDept = false;
391 438
     }
392 439
     if (!this.requireGroup) {
393 440
       this.validateForm.get("quickCombinationGroup")!.clearValidators();
@@ -460,19 +507,23 @@ export class QuickCombinationComponent implements OnInit {
460 507
                 this.validateForm.controls.quickCombinationDept.setValue(arr);
461 508
                 break;
462 509
               case 4:
463
-                let arr1 = [];
464
-                let arr11 = [];
465
-                this.info.departmentDTOS.forEach((item) => {
466
-                  arr1.push(item.id + "");
467
-                });
468
-                this.info.departmentDTOS.forEach((item) => {
469
-                  let flag = this.deptList.some((v) => v.id == item.id);
470
-                  if (!flag) {
471
-                    arr11.push(item);
472
-                  }
473
-                });
474
-                this.deptList = [...arr11, ...this.deptList];
475
-                this.validateForm.controls.quickCombinationDept.setValue(arr1);
510
+                if(this.queryParamsType == 1){
511
+                  let arr1 = [];
512
+                  let arr11 = [];
513
+                  this.info.departmentDTOS.forEach((item) => {
514
+                    arr1.push(item.id + "");
515
+                  });
516
+                  this.info.departmentDTOS.forEach((item) => {
517
+                    let flag = this.deptList.some((v) => v.id == item.id);
518
+                    if (!flag) {
519
+                      arr11.push(item);
520
+                    }
521
+                  });
522
+                  this.deptList = [...arr11, ...this.deptList];
523
+                  this.validateForm.controls.quickCombinationDept.setValue(arr1);
524
+                }else if(this.queryParamsType == 2){
525
+                  this.validateForm.controls.quickCombinationDept.setValue(null);
526
+                }
476 527
                 break;
477 528
             }
478 529
           }
@@ -543,13 +594,33 @@ export class QuickCombinationComponent implements OnInit {
543 594
                 });
544 595
                 this.groupList = [...arrr, ...this.groupList];
545 596
                 console.log(this.groupList, arrr, arr);
546
-                this.validateForm.controls.quickCombinationGroup.setValue(arr);
597
+                if(this.queryParamsType == 1){
598
+                  this.validateForm.controls.quickCombinationGroup.setValue(arr);
599
+                }else if(this.queryParamsType == 2){
600
+                  this.validateForm.controls.quickCombinationGroup.setValue(arr[0] + '');
601
+                }
547 602
                 break;
548 603
               case 3:
549 604
                 this.validateForm.controls.quickCombinationGroup.setValue(null);
550 605
                 break;
551 606
               case 4:
552
-                this.validateForm.controls.quickCombinationGroup.setValue(null);
607
+                if(this.queryParamsType == 1){
608
+                  this.validateForm.controls.quickCombinationGroup.setValue(null);
609
+                }else if(this.queryParamsType == 2){
610
+                  let arr = [];
611
+                  let arrr = [];
612
+                  this.info.groups.forEach((item) => {
613
+                    let flag = this.groupList.some((v) => v.id == item.id);
614
+                    arr.push(item.id + "");
615
+                    console.log(flag);
616
+                    if (!flag) {
617
+                      arrr.push(item);
618
+                    }
619
+                  });
620
+                  this.groupList = [...arrr, ...this.groupList];
621
+                  console.log(this.groupList, arrr, arr);
622
+                  this.validateForm.controls.quickCombinationGroup.setValue(arr);
623
+                }
553 624
                 break;
554 625
             }
555 626
           }
@@ -906,7 +977,7 @@ export class QuickCombinationComponent implements OnInit {
906 977
           id: this.validateForm.value.quickCombinationClass,
907 978
         },
908 979
         taskTypes: taskTypesIds,
909
-        ruleType: this.validateForm.value.quickCombinationModel,
980
+        ruleType: this.quickCombinationModelComputed,
910 981
         workSchemeId: this.queryParamsId,
911 982
       },
912 983
     };
@@ -973,21 +1044,34 @@ export class QuickCombinationComponent implements OnInit {
973 1044
     console.log(this.validateForm.value.quickCombinationGroup);
974 1045
     if (
975 1046
       this.validateForm.value.quickCombinationGroup &&
976
-      this.quickCombinationModel == 2
1047
+      (this.quickCombinationModel == 2 || this.quickCombinationModel == 5 || this.quickCombinationModel == 6)
977 1048
     ) {
978
-      let groups = this.validateForm.value.quickCombinationGroup.map((item) => {
979
-        return {
980
-          id: item,
981
-        };
982
-      });
983
-      if (groups.length > 0) {
984
-        if (this.copyFlag) {
985
-          data["workAllocationQuickConfig"]["groups"] = null;
1049
+      if(this.quickCombinationModel == 5){
1050
+        let groups = this.validateForm.value.quickCombinationGroup.map((item) => {
1051
+          return {
1052
+            id: item,
1053
+          };
1054
+        });
1055
+        if (groups.length > 0) {
1056
+          if (this.copyFlag) {
1057
+            data["workAllocationQuickConfig"]["groups"] = null;
1058
+          } else {
1059
+            data["workAllocationQuickConfig"]["groups"] = groups;
1060
+          }
986 1061
         } else {
987
-          data["workAllocationQuickConfig"]["groups"] = groups;
1062
+          data["workAllocationQuickConfig"]["groups"] = null;
1063
+        }
1064
+      }else if(this.quickCombinationModel == 6){
1065
+        if(this.validateForm.value.quickCombinationGroup){
1066
+          let groups = [{id:this.validateForm.value.quickCombinationGroup}];
1067
+          if (this.copyFlag) {
1068
+            data["workAllocationQuickConfig"]["groups"] = null;
1069
+          } else {
1070
+            data["workAllocationQuickConfig"]["groups"] = groups;
1071
+          }
1072
+        }else{
1073
+          data["workAllocationQuickConfig"]["groups"] = null;
988 1074
         }
989
-      } else {
990
-        data["workAllocationQuickConfig"]["groups"] = null;
991 1075
       }
992 1076
     }
993 1077
     if (!this.add && !this.copyFlag) {