diff options
author | cyuamber <xuranyjy@chinamobile.com> | 2020-07-14 18:55:22 +0800 |
---|---|---|
committer | cyuamber <xuranyjy@chinamobile.com> | 2020-07-14 18:56:39 +0800 |
commit | 81d841b1360abe51d501f3c2f8d1e9f5b97da8e8 (patch) | |
tree | d15b7730c4b0413b6824afa081e86920f6bdd4ea /usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management | |
parent | 59ec2ac4a3c93c6c4b68f09295416310d3093876 (diff) |
feat: Add prompt message for interface error3.0.5
Change-Id: I106e5c7586dd79874e6fec61c331c7a2d120302d
Issue-ID: USECASEUI-368
Signed-off-by: cyuamber <xuranyjy@chinamobile.com>
Diffstat (limited to 'usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management')
5 files changed, 27 insertions, 12 deletions
diff --git a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-model/nsi-model.component.ts b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-model/nsi-model.component.ts index 0ae21d45..71b3aba9 100644 --- a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-model/nsi-model.component.ts +++ b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-model/nsi-model.component.ts @@ -1,5 +1,5 @@ import {Component, Input, OnInit} from '@angular/core'; -import {NzModalService} from "ng-zorro-antd"; +import {NzModalService, NzMessageService} from "ng-zorro-antd"; import {SlicingTaskServices} from '.././../../../../../core/services/slicingTaskServices'; import { SlicingBusinessModelComponent } from '../../slicing-business-management/slicing-business-model/slicing-business-model.component'; import { NssiModelComponent } from '../../nssi-management/nssi-model/nssi-model.component'; @@ -12,7 +12,8 @@ export class NsiModelComponent implements OnInit { constructor( private myhttp: SlicingTaskServices, - private modalService: NzModalService + private modalService: NzModalService, + private message: NzMessageService ) { } @Input() nsiId; @@ -37,6 +38,8 @@ export class NsiModelComponent implements OnInit { return item } }); + }else{ + this.message.error(res.result_header.result_message) } }) } diff --git a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-table/nsi-table.component.ts b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-table/nsi-table.component.ts index 3c08463d..08716e98 100644 --- a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-table/nsi-table.component.ts +++ b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nsi-management/nsi-table/nsi-table.component.ts @@ -2,7 +2,7 @@ import {Component, Input, OnInit,SimpleChanges} from '@angular/core'; import {BUSINESS_STATUS} from '../../../../../../../constants/constants'; import {SlicingTaskServices} from "../../../../../../core/services/slicingTaskServices"; import {NsiModelComponent} from "../nsi-model/nsi-model.component"; -import {NzModalService} from 'ng-zorro-antd'; +import {NzModalService, NzMessageService} from 'ng-zorro-antd'; @Component({ selector: 'app-nsi-table', @@ -13,7 +13,8 @@ export class NsiTableComponent implements OnInit { constructor( private myhttp: SlicingTaskServices, - private modalService: NzModalService + private modalService: NzModalService, + private message: NzMessageService ) { } @@ -56,10 +57,12 @@ export class NsiTableComponent implements OnInit { if (nsi_service_instances !== null && nsi_service_instances.length > 0) { this.listOfData = nsi_service_instances; } + }else { + this.message.error(res.result_header.result_message) } }, (res) => { this.loading = false; - console.error(res); + this.message.error(res); }) } diff --git a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-model/nssi-model.component.ts b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-model/nssi-model.component.ts index e20d81ed..96abbeca 100644 --- a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-model/nssi-model.component.ts +++ b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-model/nssi-model.component.ts @@ -1,5 +1,5 @@ import {Component, Input, OnInit} from '@angular/core'; -import {NzModalService} from "ng-zorro-antd"; +import {NzModalService, NzMessageService} from "ng-zorro-antd"; import {SlicingTaskServices} from '.././../../../../../core/services/slicingTaskServices'; import { NsiModelComponent } from '../../nsi-management/nsi-model/nsi-model.component'; @Component({ @@ -11,7 +11,8 @@ export class NssiModelComponent implements OnInit { constructor( private myhttp: SlicingTaskServices, - private modalService: NzModalService + private modalService: NzModalService, + private message: NzMessageService ) { } @Input() nssiId; @@ -30,6 +31,8 @@ export class NssiModelComponent implements OnInit { return item } }); + }else{ + this.message.error(res.result_header.result_message) } }) } diff --git a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-table/nssi-table.component.ts b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-table/nssi-table.component.ts index 6dec5c72..ba2b8971 100644 --- a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-table/nssi-table.component.ts +++ b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/nssi-management/nssi-table/nssi-table.component.ts @@ -1,7 +1,7 @@ import {Component, Input, OnInit,SimpleChanges} from '@angular/core'; import {BUSINESS_STATUS} from '../../../../../../../constants/constants'; import {SlicingTaskServices} from "../../../../../../core/services/slicingTaskServices"; -import {NzModalService} from 'ng-zorro-antd'; +import {NzModalService, NzMessageService} from 'ng-zorro-antd'; import {NssiModelComponent} from "../nssi-model/nssi-model.component"; @Component({ @@ -13,7 +13,8 @@ export class NssiTableComponent implements OnInit { constructor( private myhttp: SlicingTaskServices, - private modalService: NzModalService + private modalService: NzModalService, + private message: NzMessageService ) { } @@ -56,10 +57,12 @@ export class NssiTableComponent implements OnInit { if (nssi_service_instances !== null && nssi_service_instances.length > 0) { this.listOfData = nssi_service_instances; } + }else{ + this.message.error(res.result_header.result_message) } }, (res) => { this.loading = false; - console.error(res); + this.message.error(res) }) } diff --git a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/slicing-business-management/slicing-business-model/slicing-business-model.component.ts b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/slicing-business-management/slicing-business-model/slicing-business-model.component.ts index e2867489..b27e5a31 100644 --- a/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/slicing-business-management/slicing-business-model/slicing-business-model.component.ts +++ b/usecaseui-portal/src/app/views/services/slicing-management/slicing-resource-management/slicing-business-management/slicing-business-model/slicing-business-model.component.ts @@ -1,5 +1,5 @@ import { Component, OnInit, Input } from '@angular/core'; -import { NzModalService } from "ng-zorro-antd"; +import { NzModalService, NzMessageService } from "ng-zorro-antd"; import { SlicingTaskServices } from '.././../../../../../core/services/slicingTaskServices'; import { NsiModelComponent } from "../../nsi-management/nsi-model/nsi-model.component"; @@ -12,7 +12,8 @@ export class SlicingBusinessModelComponent implements OnInit { constructor( private myhttp: SlicingTaskServices, - private modalService: NzModalService + private modalService: NzModalService, + private message: NzMessageService ) { } @@ -47,6 +48,8 @@ export class SlicingBusinessModelComponent implements OnInit { if (nsi_info.nsi_id !== null) { this.nsiInfo = [nsi_info]; } + }else{ + this.message.error(res.result_header.result_message) } }) } |