diff options
author | 2019-12-11 09:16:41 +0800 | |
---|---|---|
committer | 2019-12-11 09:18:16 +0800 | |
commit | 27f241a7c7c9741d1834fbb13dd7250cb51de8c9 (patch) | |
tree | 5aeb03298ddd4f09462e497a2b476315505b31d9 /usecaseui-portal/src/app/views/services/slicing-management/slicing-task-management/slicing-task-model | |
parent | bff56675c3a12bafe443fbb52f5d9eea99461db7 (diff) |
feat: Optimize code and add English fields
Change-Id: Id61ab33f0bb612f8ae3a1debbc4c2d4887cf2b2d
Issue-ID: USECASEUI-368
Signed-off-by: cyuamber <xuranyjy@chinamobile.com>
Diffstat (limited to 'usecaseui-portal/src/app/views/services/slicing-management/slicing-task-management/slicing-task-model')
-rw-r--r-- | usecaseui-portal/src/app/views/services/slicing-management/slicing-task-management/slicing-task-model/subnet-params-model/subnet-params-model.component.html | 181 |
1 files changed, 128 insertions, 53 deletions
diff --git a/usecaseui-portal/src/app/views/services/slicing-management/slicing-task-management/slicing-task-model/subnet-params-model/subnet-params-model.component.html b/usecaseui-portal/src/app/views/services/slicing-management/slicing-task-management/slicing-task-model/subnet-params-model/subnet-params-model.component.html index 1dfc6338..127a5b98 100644 --- a/usecaseui-portal/src/app/views/services/slicing-management/slicing-task-management/slicing-task-model/subnet-params-model/subnet-params-model.component.html +++ b/usecaseui-portal/src/app/views/services/slicing-management/slicing-task-management/slicing-task-model/subnet-params-model/subnet-params-model.component.html @@ -1,54 +1,129 @@ -<nz-modal [(nzVisible)]="showModel" [nzTitle]="title + '参数'" (nzOnCancel)="handleCancel()" (nzOnOk)="handleOk()" nzWidth="700px"> - <div class="subnet_params_container"> - <form nz-form *ngIf="title === '无线域'"> - <nz-form-item *ngFor="let item of wirelessFormItems"> - <nz-form-label [nzSpan]="5" nzRequired [nzFor]="item.key">{{item.title}}</nz-form-label> - <nz-form-control [nzSpan]="10" *ngIf="item.key !== 'an_coverage_area_ta_list'"> - <input nz-input [(ngModel)]="detailData[item.key]" [name]="item.key" [id]="item.key"/> - </nz-form-control> - <div *ngIf="item.key === 'an_coverage_area_ta_list'"> - <div *ngFor="let area of areaList; let i = index"> - <nz-form-control [nzSpan]="4" [nzOffset]=" i && !ind ? 5 : 0" class="subnet_params_area" *ngFor="let item of area; let ind = index"> - <nz-select [(ngModel)]="item.selected" [name]="'area' +i + ind" (nzOpenChange)="handleChange(area, item)" (ngModelChange)="handleChangeSelected(area,item)"> - <nz-option [nzValue]="op.name" *ngFor="let op of item.options" [nzLabel]="op.name" ></nz-option> - </nz-select> - </nz-form-control> - <nz-form-control [nzSpan]="1" [nzOffset]="1"> - <button nz-button nzType="primary" nzSize="small" class="subnet_params_button" *ngIf="!i" (click)="creatAreaList()"> - <i nz-icon class="anticon anticon-plus subnet_params_icon"></i> - </button> - <button nz-button nzType="primary" nzSize="small" class="subnet_params_button" *ngIf="i" (click)="deleteAreaList(i)"> - <i nz-icon class="anticon anticon-minus subnet_params_icon"></i> - </button> - </nz-form-control> - </div> - - </div> - </nz-form-item> - </form> - <form nz-form *ngIf="title === '传输域'"> - <nz-form-item *ngFor="let item of transferFormItems"> - <nz-form-label [nzSpan]="7" nzRequired [nzFor]="item.key">{{item.title}}</nz-form-label> - <nz-form-control [nzSpan]="12"> - <input nz-input [(ngModel)]="detailData[item.key]" [name]="item.key" [id]="item.key"/> - </nz-form-control> - </nz-form-item> - </form> - <form nz-form *ngIf="title === '核心域'"> - <nz-form-item *ngFor="let item of coreFormItems"> - <nz-form-label [nzSpan]="10" nzRequired [nzFor]="item.key">{{item.title}}</nz-form-label> - <nz-form-control [nzSpan]="10" > - <input nz-input [(ngModel)]="detailData[item.key]" [name]="item.key" [id]="item.key" [readOnly]="item.title === 'S-NSSAI'" *ngIf="item.title !== '共享等级' && item.title !== '游牧性'"/> - <nz-radio-group [name]="item.key" [(ngModel)]="detailData[item.key]" *ngIf="item.title === '共享等级'"> - <label nz-radio [nzValue]="option.key" *ngFor="let option of item.options">{{option.title}}</label> - </nz-radio-group> - <nz-select [name]="item.key" [(ngModel)]="detailData[item.key]" *ngIf=" item.title === '游牧性'"> - <nz-option [nzValue]="option.key" *ngFor="let option of item.options" [nzLabel]="option.title"></nz-option> - </nz-select> - </nz-form-control> - - </nz-form-item> - </form> - - </div> +<nz-modal + [(nzVisible)]="showModel" + [nzTitle]="title + '参数'" + (nzOnCancel)="handleCancel()" + (nzOnOk)="handleOk()" + nzWidth="700px" +> + <div class="subnet_params_container"> + <form nz-form *ngIf="title === '无线域'"> + <nz-form-item *ngFor="let item of wirelessFormItems"> + <nz-form-label [nzSpan]="6" nzRequired [nzFor]="item.key"> + {{ item.title }} + </nz-form-label> + <nz-form-control + [nzSpan]="10" + *ngIf="item.key !== 'an_coverage_area_ta_list'" + > + <input + nz-input + [(ngModel)]="detailData[item.key]" + [name]="item.key" + [id]="item.key" + /> + </nz-form-control> + <div *ngIf="item.key === 'an_coverage_area_ta_list'"> + <div *ngFor="let area of areaList; let i = index"> + <nz-form-control + [nzSpan]="4" + [nzOffset]="i && !ind ? 6 : 0" + class="subnet_params_area" + *ngFor="let item of area; let ind = index" + > + <nz-select + [(ngModel)]="item.selected" + [name]="'area' + i + ind" + (nzOpenChange)="handleChange(area, item)" + (ngModelChange)=" handleChangeSelected(area, item) " + > + <nz-option + [nzValue]="op.name" + [nzLabel]="op.name" + *ngFor="let op of item.options" + ></nz-option> + </nz-select> + </nz-form-control> + <nz-form-control [nzSpan]="1" [nzOffset]="1"> + <button + nz-button + nzType="primary" + nzSize="small" + class="subnet_params_button" + *ngIf="!i" + (click)="creatAreaList()" + > + <i nz-icon class="anticon anticon-plus subnet_params_icon" ></i> + </button> + <button + nz-button + nzType="primary" + nzSize="small" + class="subnet_params_button" + *ngIf="i" + (click)="deleteAreaList(i)" + > + <i nz-icon class="anticon anticon-minus subnet_params_icon" ></i> + </button> + </nz-form-control> + </div> + </div> + </nz-form-item> + </form> + <form nz-form *ngIf="title === '传输域'"> + <nz-form-item *ngFor="let item of transferFormItems"> + <nz-form-label [nzSpan]="7" nzRequired [nzFor]="item.key"> + {{ item.title }} + </nz-form-label> + <nz-form-control [nzSpan]="12"> + <input + nz-input + [(ngModel)]="detailData[item.key]" + [name]="item.key" + [id]="item.key" + /> + </nz-form-control> + </nz-form-item> + </form> + <form nz-form *ngIf="title === '核心域'"> + <nz-form-item *ngFor="let item of coreFormItems"> + <nz-form-label [nzSpan]="10" nzRequired [nzFor]="item.key"> + {{ item.title }} + </nz-form-label> + <nz-form-control [nzSpan]="10"> + <input + nz-input + [id]="item.key" + [name]="item.key" + [(ngModel)]="detailData[item.key]" + [readOnly]="item.title === 'S-NSSAI'" + *ngIf=" item.title !== 'Resource Sharing Level' && item.title !== 'Mobility' " + /> + <nz-radio-group + [name]="item.key" + [(ngModel)]="detailData[item.key]" + *ngIf="item.title === 'Resource Sharing Level'" + > + <label + nz-radio + [nzValue]="option.key" + *ngFor="let option of item.options" + > + {{ option.title }} + </label> + </nz-radio-group> + <nz-select + [name]="item.key" + [(ngModel)]="detailData[item.key]" + *ngIf="item.title === 'Mobility'" + > + <nz-option + [nzValue]="option.key" + [nzLabel]="option.title" + *ngFor="let option of item.options" + ></nz-option> + </nz-select> + </nz-form-control> + </nz-form-item> + </form> + </div> </nz-modal> |