Browse Source

bug修复

seimin 8 months ago
parent
commit
d27ca51132

+ 4 - 4
src/app/views/configuration-center/configuration-center.component.html

@@ -22,21 +22,21 @@
22
           <div class="contentHead">一级故障现象<button nz-button nzType="primary" nzSize="small" (click)="addCategoryModal(1)">新增</button></div>
22
           <div class="contentHead">一级故障现象<button nz-button nzType="primary" nzSize="small" (click)="addCategoryModal(1)">新增</button></div>
23
           <overlay-scrollbars #osComponentRef1 class="contentBody">
23
           <overlay-scrollbars #osComponentRef1 class="contentBody">
24
             <nz-spin nzSimple [nzSpinning]="categoryLoading1" class="mt8 text_align_center"></nz-spin>
24
             <nz-spin nzSimple [nzSpinning]="categoryLoading1" class="mt8 text_align_center"></nz-spin>
25
-            <div [hidden]="categoryLoading1" class="contentItem" [ngClass]="{ active: item.id === activeCategory1.id }" (click)="clickCategory(item, 1)" *ngFor="let item of categoryList1">{{ item.category }}</div>
25
+            <div [hidden]="categoryLoading1" class="contentItem" [title]="item.category" [ngClass]="{ active: item.id === activeCategory1.id }" (click)="clickCategory(item, 1)" *ngFor="let item of categoryList1">{{ item.category }}</div>
26
           </overlay-scrollbars>
26
           </overlay-scrollbars>
27
         </div>
27
         </div>
28
         <div class="address">
28
         <div class="address">
29
           <div class="contentHead">二级故障现象<button nz-button nzType="primary" nzSize="small" *ngIf="activeCategory1.id" (click)="addCategoryModal(2)">新增</button></div>
29
           <div class="contentHead">二级故障现象<button nz-button nzType="primary" nzSize="small" *ngIf="activeCategory1.id" (click)="addCategoryModal(2)">新增</button></div>
30
           <overlay-scrollbars #osComponentRef2 class="contentBody">
30
           <overlay-scrollbars #osComponentRef2 class="contentBody">
31
             <nz-spin nzSimple [nzSpinning]="categoryLoading2" class="mt8 text_align_center"></nz-spin>
31
             <nz-spin nzSimple [nzSpinning]="categoryLoading2" class="mt8 text_align_center"></nz-spin>
32
-            <div [hidden]="categoryLoading2" class="contentItem" [ngClass]="{ active: item.id === activeCategory2.id }" (click)="clickCategory(item, 2)" *ngFor="let item of categoryList2">{{ item.category }}</div>
32
+            <div [hidden]="categoryLoading2" class="contentItem" [title]="item.category" [ngClass]="{ active: item.id === activeCategory2.id }" (click)="clickCategory(item, 2)" *ngFor="let item of categoryList2">{{ item.category }}</div>
33
           </overlay-scrollbars>
33
           </overlay-scrollbars>
34
         </div>
34
         </div>
35
         <div class="address">
35
         <div class="address">
36
           <div class="contentHead">三级故障现象<button nz-button nzType="primary" nzSize="small" *ngIf="activeCategory2.id" (click)="addCategoryModal(3)">新增</button></div>
36
           <div class="contentHead">三级故障现象<button nz-button nzType="primary" nzSize="small" *ngIf="activeCategory2.id" (click)="addCategoryModal(3)">新增</button></div>
37
           <overlay-scrollbars #osComponentRef3 class="contentBody">
37
           <overlay-scrollbars #osComponentRef3 class="contentBody">
38
             <nz-spin nzSimple [nzSpinning]="categoryLoading3" class="mt8 text_align_center"></nz-spin>
38
             <nz-spin nzSimple [nzSpinning]="categoryLoading3" class="mt8 text_align_center"></nz-spin>
39
-            <div [hidden]="categoryLoading3" class="contentItem" [ngClass]="{ active: item.id === activeCategory3.id }" (click)="clickCategory(item, 3)" *ngFor="let item of categoryList3">{{ item.category }}</div>
39
+            <div [hidden]="categoryLoading3" class="contentItem" [title]="item.category" [ngClass]="{ active: item.id === activeCategory3.id }" (click)="clickCategory(item, 3)" *ngFor="let item of categoryList3">{{ item.category }}</div>
40
           </overlay-scrollbars>
40
           </overlay-scrollbars>
41
         </div>
41
         </div>
42
         <div class="addressAssign">
42
         <div class="addressAssign">
@@ -137,7 +137,7 @@
137
       <div class="contentInner">
137
       <div class="contentInner">
138
         <div class="address">
138
         <div class="address">
139
           <overlay-scrollbars #osComponentRef5 class="contentBody">
139
           <overlay-scrollbars #osComponentRef5 class="contentBody">
140
-            <div class="contentItem" [ngClass]="{ active: item.id === activeDictionaryKey.id }" (click)="clickDictionaryKey(item)" *ngFor="let item of dictionaryKeyList">{{ item.name }}</div>
140
+            <div class="contentItem" [title]="item.name" [ngClass]="{ active: item.id === activeDictionaryKey.id }" (click)="clickDictionaryKey(item)" *ngFor="let item of dictionaryKeyList">{{ item.name }}</div>
141
           </overlay-scrollbars>
141
           </overlay-scrollbars>
142
         </div>
142
         </div>
143
         <div class="addressAssign">
143
         <div class="addressAssign">

+ 3 - 0
src/app/views/configuration-center/configuration-center.component.less

@@ -131,6 +131,9 @@
131
       .contentItem{
131
       .contentItem{
132
         padding: 4px 16px;
132
         padding: 4px 16px;
133
         cursor: pointer;
133
         cursor: pointer;
134
+        overflow: hidden;
135
+        text-overflow: ellipsis;
136
+        white-space: nowrap;
134
         &.active{
137
         &.active{
135
           color: @primary-color;
138
           color: @primary-color;
136
           background-color: #F0F6ED;
139
           background-color: #F0F6ED;

+ 6 - 3
src/app/views/configuration-center/configuration-center.component.ts

@@ -102,7 +102,8 @@ export class ConfigurationCenterComponent implements OnInit, AfterViewInit {
102
       }, 0)
102
       }, 0)
103
       if(this.currentHospital.type && this.currentHospital.type.value === '6'){
103
       if(this.currentHospital.type && this.currentHospital.type.value === '6'){
104
         // 是责任部门
104
         // 是责任部门
105
-        this.hospitalConfigList.unshift({ id: 1, name: '部门设置',});
105
+        let flag = this.hospitalConfigList.some(v => v.id === 1);
106
+        !flag && this.hospitalConfigList.unshift({ id: 1, name: '部门设置',});
106
       }
107
       }
107
       this.getCategoryList(1);
108
       this.getCategoryList(1);
108
       this.getHospitals(1);
109
       this.getHospitals(1);
@@ -158,6 +159,8 @@ export class ConfigurationCenterComponent implements OnInit, AfterViewInit {
158
     this.activeCategory1 = {};
159
     this.activeCategory1 = {};
159
     this.activeCategory2 = {};
160
     this.activeCategory2 = {};
160
     this.activeCategory3 = {};
161
     this.activeCategory3 = {};
162
+
163
+    this.categoryConfigList = [];
161
   }
164
   }
162
 
165
 
163
   // 获取优先级列表
166
   // 获取优先级列表
@@ -525,11 +528,11 @@ export class ConfigurationCenterComponent implements OnInit, AfterViewInit {
525
             categoryId,
528
             categoryId,
526
             priority: this.validateConfigForm.value.priority,
529
             priority: this.validateConfigForm.value.priority,
527
             score: { id: this.validateConfigForm.value.score },
530
             score: { id: this.validateConfigForm.value.score },
528
-            dutyId: this.validateConfigForm.value.dutyId,
531
+            // dutyId: this.validateConfigForm.value.dutyId,
529
             userGroup: this.validateConfigForm.value.userGroup,
532
             userGroup: this.validateConfigForm.value.userGroup,
530
             groupId: this.validateConfigForm.value.userGroup === 2 ? this.validateConfigForm.value.groupId : undefined,
533
             groupId: this.validateConfigForm.value.userGroup === 2 ? this.validateConfigForm.value.groupId : undefined,
531
             userId: this.validateConfigForm.value.userGroup === 1 ? this.validateConfigForm.value.userId : undefined,
534
             userId: this.validateConfigForm.value.userGroup === 1 ? this.validateConfigForm.value.userId : undefined,
532
-            hosId: this.currentHospital.id,
535
+            // hosId: this.currentHospital.id,
533
           }
536
           }
534
         }
537
         }
535
       };
538
       };