Browse Source

班次修改

seimin 8 months ago
parent
commit
f6108d7b09

+ 6 - 3
src/app/components/configurationCenter/configuration-dictionary/configuration-dictionary.component.ts

@@ -6,6 +6,7 @@ import { ToolService } from 'src/app/services/tool.service';
6
 import { OverlayScrollbarsComponent } from 'overlayscrollbars-ngx';
6
 import { OverlayScrollbarsComponent } from 'overlayscrollbars-ngx';
7
 import { NzMessageService } from 'ng-zorro-antd';
7
 import { NzMessageService } from 'ng-zorro-antd';
8
 import { v4 as uuidv4, validate as uuidValidate } from 'uuid';
8
 import { v4 as uuidv4, validate as uuidValidate } from 'uuid';
9
+import { ConsoleReporter } from 'jasmine';
9
 
10
 
10
 @Component({
11
 @Component({
11
   selector: "app-configuration-dictionary",
12
   selector: "app-configuration-dictionary",
@@ -175,6 +176,7 @@ export class ConfigurationDictionaryComponent implements OnInit {
175
           }
176
           }
176
         }
177
         }
177
       })
178
       })
179
+      console.log(this.validateDictionaryForm.controls)
178
     })
180
     })
179
   }
181
   }
180
 
182
 
@@ -228,12 +230,13 @@ export class ConfigurationDictionaryComponent implements OnInit {
228
 
230
 
229
     //增加
231
     //增加
230
     postData = [];
232
     postData = [];
233
+    let rawValueObj = this.validateDictionaryForm.getRawValue();
231
     for (let i = 0; i < this.dictionaryList.length; i++) {
234
     for (let i = 0; i < this.dictionaryList.length; i++) {
232
       postData.push({
235
       postData.push({
233
         id: uuidValidate(this.dictionaryList[i].id) ? undefined : this.dictionaryList[i].id,
236
         id: uuidValidate(this.dictionaryList[i].id) ? undefined : this.dictionaryList[i].id,
234
-        name: this.validateDictionaryForm.value['name_' + this.dictionaryList[i].id],
235
-        value: this.validateDictionaryForm.value['value_' + this.dictionaryList[i].id],
236
-        orders: this.validateDictionaryForm.value['orders_' + this.dictionaryList[i].id],
237
+        name: rawValueObj['name_' + this.dictionaryList[i].id],
238
+        value: rawValueObj['value_' + this.dictionaryList[i].id],
239
+        orders: rawValueObj['orders_' + this.dictionaryList[i].id],
237
         system: uuidValidate(this.dictionaryList[i].id) ? false : this.dictionaryList[i].system,
240
         system: uuidValidate(this.dictionaryList[i].id) ? false : this.dictionaryList[i].system,
238
         key: this.activeDictionaryKey.key,
241
         key: this.activeDictionaryKey.key,
239
       })
242
       })

+ 27 - 5
src/app/views/classes-management/classes-management.component.html

@@ -12,17 +12,21 @@
12
         [nzLoading]="loading1">
12
         [nzLoading]="loading1">
13
         <thead>
13
         <thead>
14
           <tr class="thead">
14
           <tr class="thead">
15
-            <th nzWidth="20%">班次名称</th>
16
-            <th nzWidth="20%">班次描述</th>
17
-            <th nzWidth="20%">工作时间</th>
18
-            <th nzWidth="20%">工作日/节假日</th>
19
-            <th nzWidth="20%">操作</th>
15
+            <th nzWidth="14%">班次名称</th>
16
+            <th nzWidth="14%">班次描述</th>
17
+            <th nzWidth="14%">呼叫中心班次</th>
18
+            <th nzWidth="14%">优先级班次</th>
19
+            <th nzWidth="14%">工作时间</th>
20
+            <th nzWidth="14%">工作日/节假日</th>
21
+            <th nzWidth="16%">操作</th>
20
           </tr>
22
           </tr>
21
         </thead>
23
         </thead>
22
         <tbody>
24
         <tbody>
23
           <tr *ngFor="let data of listOfData">
25
           <tr *ngFor="let data of listOfData">
24
             <td>{{ data.name }}</td>
26
             <td>{{ data.name }}</td>
25
             <td>{{ (data.describe?data.describe:'-') }}</td>
27
             <td>{{ (data.describe?data.describe:'-') }}</td>
28
+            <td>{{ data.bindCall == 1 ? '是' : '否' }}</td>
29
+            <td>{{ data.bindPriority == 1 ? '是' : '否' }}</td>
26
             <td>
30
             <td>
27
               <div *ngIf="data.scheduleClassTimes">
31
               <div *ngIf="data.scheduleClassTimes">
28
                 <div *ngFor="let time of data.scheduleClassTimes">
32
                 <div *ngFor="let time of data.scheduleClassTimes">
@@ -77,6 +81,24 @@
77
           </nz-form-control>
81
           </nz-form-control>
78
         </nz-form-item>
82
         </nz-form-item>
79
         <nz-form-item>
83
         <nz-form-item>
84
+          <nz-form-label [nzSpan]="9" nzRequired nzFor="bindCall">呼叫中心班次</nz-form-label>
85
+          <nz-form-control [nzSpan]="15" nzErrorTip="请选择呼叫中心班次!">
86
+            <nz-radio-group formControlName="bindCall">
87
+              <label nz-radio [nzValue]="1">是</label>
88
+              <label nz-radio [nzValue]="0">否</label>
89
+            </nz-radio-group>
90
+          </nz-form-control>
91
+        </nz-form-item>
92
+        <nz-form-item>
93
+          <nz-form-label [nzSpan]="9" nzRequired nzFor="bindPriority">优先级班次</nz-form-label>
94
+          <nz-form-control [nzSpan]="15" nzErrorTip="请选择优先级班次!">
95
+            <nz-radio-group formControlName="bindPriority">
96
+              <label nz-radio [nzValue]="1">是</label>
97
+              <label nz-radio [nzValue]="0">否</label>
98
+            </nz-radio-group>
99
+          </nz-form-control>
100
+        </nz-form-item>
101
+        <nz-form-item>
80
           <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="datesType">适用日期类型</nz-form-label>
102
           <nz-form-label [nzSm]="24" [nzXs]="24" nzRequired nzFor="datesType">适用日期类型</nz-form-label>
81
           <nz-form-control nzErrorTip="请选择适用日期类型!">
103
           <nz-form-control nzErrorTip="请选择适用日期类型!">
82
             <nz-checkbox-group formControlName="datesType" [(ngModel)]="oneOption"
104
             <nz-checkbox-group formControlName="datesType" [(ngModel)]="oneOption"

+ 6 - 0
src/app/views/classes-management/classes-management.component.ts

@@ -101,6 +101,8 @@ export class ClassesManagementComponent implements OnInit {
101
     this.validateForm = this.fb.group({
101
     this.validateForm = this.fb.group({
102
       classesName: [null, [Validators.required]],
102
       classesName: [null, [Validators.required]],
103
       description: [null, [Validators.required]],
103
       description: [null, [Validators.required]],
104
+      bindCall: [0, [Validators.required]],
105
+      bindPriority: [0, [Validators.required]],
104
       datesType: [null, [this.dateValidator]],
106
       datesType: [null, [this.dateValidator]],
105
       // 时间段1
107
       // 时间段1
106
       timerF1: [null, [Validators.required]],
108
       timerF1: [null, [Validators.required]],
@@ -189,6 +191,8 @@ export class ClassesManagementComponent implements OnInit {
189
       {
191
       {
190
         name: that.validateForm.value.classesName,
192
         name: that.validateForm.value.classesName,
191
         describe: that.validateForm.value.description,
193
         describe: that.validateForm.value.description,
194
+        bindCall: that.validateForm.value.bindCall,
195
+        bindPriority: that.validateForm.value.bindPriority,
192
         scheduleClassTimes: times,
196
         scheduleClassTimes: times,
193
         type: that.validateForm.value.datesType,
197
         type: that.validateForm.value.datesType,
194
         hospital: { id: this.hospital },
198
         hospital: { id: this.hospital },
@@ -258,6 +262,8 @@ export class ClassesManagementComponent implements OnInit {
258
     this.coopId = data.id;
262
     this.coopId = data.id;
259
     this.validateForm.controls.classesName.setValue(data.name);
263
     this.validateForm.controls.classesName.setValue(data.name);
260
     this.validateForm.controls.description.setValue(data.describe);
264
     this.validateForm.controls.description.setValue(data.describe);
265
+    this.validateForm.controls.bindCall.setValue(data.bindCall);
266
+    this.validateForm.controls.bindPriority.setValue(data.bindPriority);
261
     if (data.type == 1) {
267
     if (data.type == 1) {
262
       this.oneOption[0]['checked'] = true;
268
       this.oneOption[0]['checked'] = true;
263
     } else if (data.type == 2) {
269
     } else if (data.type == 2) {