seimin 1 year ago
parent
commit
a50a351424

+ 2 - 2
src/app/views/clinical-users-management/clinical-users-management.component.html

@@ -2,10 +2,10 @@
2
   <div class="list-template__content">
2
   <div class="list-template__content">
3
     <div class="list-template__top" nz-row>
3
     <div class="list-template__top" nz-row>
4
       <div nz-col nzXl='18' class="list-template__searchBox">
4
       <div nz-col nzXl='18' class="list-template__searchBox">
5
-        <div class="list-template__searchItem">
5
+        <div class="list-template__searchItem" *ngIf="isShowSelectHospital">
6
           <span class="label">院区</span>:
6
           <span class="label">院区</span>:
7
           <nz-select class="formItem" (nzOnSearch)="changeInpHospital(hosId,'search',$event)"
7
           <nz-select class="formItem" (nzOnSearch)="changeInpHospital(hosId,'search',$event)"
8
-            [nzDropdownMatchSelectWidth]="false" nzServerSearch nzShowSearch nzAllowClear nzPlaceHolder="请选择院区"
8
+            [nzDropdownMatchSelectWidth]="false" nzServerSearch nzShowSearch nzPlaceHolder="请选择院区"
9
             [(ngModel)]="hosId" (ngModelChange)="changeHosp1($event)">
9
             [(ngModel)]="hosId" (ngModelChange)="changeHosp1($event)">
10
             <ng-container *ngFor="let option of hospitals1">
10
             <ng-container *ngFor="let option of hospitals1">
11
               <nz-option *ngIf="!isLoading" [nzLabel]="option.hosName" [nzValue]="option.id"></nz-option>
11
               <nz-option *ngIf="!isLoading" [nzLabel]="option.hosName" [nzValue]="option.id"></nz-option>

+ 11 - 5
src/app/views/clinical-users-management/clinical-users-management.component.ts

@@ -87,7 +87,12 @@ export class ClinicalUsersManagementComponent implements OnInit {
87
     this.getList();
87
     this.getList();
88
   }
88
   }
89
   // 重置
89
   // 重置
90
+  isShowSelectHospital = true;
90
   reset() {
91
   reset() {
92
+    this.isShowSelectHospital = false;
93
+    setTimeout(()=>{
94
+      this.isShowSelectHospital = true;
95
+    },0)
91
     this.pageIndex = 1;
96
     this.pageIndex = 1;
92
     this.hosId = this.tool.getCurrentHospital().id;
97
     this.hosId = this.tool.getCurrentHospital().id;
93
     this.name = "";
98
     this.name = "";
@@ -148,11 +153,12 @@ export class ClinicalUsersManagementComponent implements OnInit {
148
   getAllHospital() {
153
   getAllHospital() {
149
     this.loading1 = true;
154
     this.loading1 = true;
150
     let topLevelParentHosList$ = this.mainService.apiPostAll("topLevelParentHosList", {});
155
     let topLevelParentHosList$ = this.mainService.apiPostAll("topLevelParentHosList", {});
151
-    let topLevelParentHos$ = this.mainService.apiPostAll("topLevelParentHos", {hosId: this.tool.getCurrentHospital().id});
152
-    forkJoin(topLevelParentHosList$, topLevelParentHos$).subscribe((dataArray:any[]) => {
153
-      let [data1, data2] = dataArray;
156
+    // let topLevelParentHos$ = this.mainService.apiPostAll("topLevelParentHos", {hosId: this.tool.getCurrentHospital().id});
157
+    forkJoin(topLevelParentHosList$).subscribe((dataArray:any[]) => {
158
+      let [data1] = dataArray;
154
       this.hospitals1 = data1.topLevelParentHosList || [];
159
       this.hospitals1 = data1.topLevelParentHosList || [];
155
-      this.hosId = data2.topHospital ? data2.topHospital.id : null;
160
+      // this.hosId = data2.topHospital ? data2.topHospital.id : null;
161
+      this.hosId = this.tool.getCurrentHospital().id;
156
       this.changeHosp1(this.hosId);
162
       this.changeHosp1(this.hosId);
157
       this.getList();
163
       this.getList();
158
     }, err => {
164
     }, err => {
@@ -321,7 +327,7 @@ export class ClinicalUsersManagementComponent implements OnInit {
321
         group: groups,
327
         group: groups,
322
         role: roles,
328
         role: roles,
323
         phone: that.validateForm.value.deptPhone,
329
         phone: that.validateForm.value.deptPhone,
324
-        hospital: { id: that.hosId },
330
+        hospital: { id: that.tool.getCurrentHospital().id },
325
         weixin: that.validateForm.value.weixin,
331
         weixin: that.validateForm.value.weixin,
326
       },
332
       },
327
     };
333
     };

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

@@ -445,6 +445,9 @@ export class MainComponent implements OnInit {
445
   maskFlag: any = false;
445
   maskFlag: any = false;
446
   hosFlag1 = false;
446
   hosFlag1 = false;
447
   submitFormHand1(id) {
447
   submitFormHand1(id) {
448
+    if(this.currentHospital.id == id){
449
+      return;
450
+    }
448
     this.maskFlag = this.msg.loading("正在加载中..", {
451
     this.maskFlag = this.msg.loading("正在加载中..", {
449
       nzDuration: 0,
452
       nzDuration: 0,
450
     }).messageId;
453
     }).messageId;

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

@@ -4,7 +4,7 @@
4
       <div nz-col nzLg='14' class="list-template__searchBox">
4
       <div nz-col nzLg='14' class="list-template__searchBox">
5
         <div class="list-template__searchItem">
5
         <div class="list-template__searchItem">
6
           <span class="label">院区</span>:
6
           <span class="label">院区</span>:
7
-          <nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzAllowClear nzPlaceHolder="请选择院区" [(ngModel)]="hospital">
7
+          <nz-select class="formItem" [nzDropdownMatchSelectWidth]="false" nzShowSearch nzPlaceHolder="请选择院区" [(ngModel)]="hospital">
8
             <ng-container *ngFor="let option of hospitals1">
8
             <ng-container *ngFor="let option of hospitals1">
9
               <nz-option *ngIf="!isLoading" [nzLabel]="option.hosName" [nzValue]="option.id"></nz-option>
9
               <nz-option *ngIf="!isLoading" [nzLabel]="option.hosName" [nzValue]="option.id"></nz-option>
10
             </ng-container>
10
             </ng-container>