import { CheckProcessModelComponent } from './views/services/slicing-management/slicing-task-management/check-process-model/check-process-model.component'
import { NsiTableComponent } from './views/services/slicing-management/slicing-resource-management/nsi-management/nsi-table/nsi-table.component'
import { NssiTableComponent } from './views/services/slicing-management/slicing-resource-management/nssi-management/nssi-table/nssi-table.component'
-import { SlicingBusinessModelComponent } from './views/services/slicing-management/slicing-resource-management/slicing-business-management/slicing-business-model/slicing-business-model.component'
+import { SlicingBusinessModelComponent } from './views/services/slicing-management/slicing-resource-management/slicing-business-management/slicing-business-model/slicing-business-model.component';
+import { NsiModelComponent } from './views/services/slicing-management/slicing-resource-management/nsi-management/nsi-model/nsi-model.component';
@NgModule({
providers: [
CheckProcessModelComponent,
NsiTableComponent,
NssiTableComponent,
- SlicingBusinessModelComponent
+ SlicingBusinessModelComponent,
+ NsiModelComponent,
],
imports: [
BrowserModule,
NgxEchartsModule,
AppRoutingModule
],
- bootstrap: [AppComponent]
+ bootstrap: [AppComponent],
+ entryComponents: [
+ SlicingBusinessModelComponent,
+ NsiModelComponent
+ ]
})
export class AppModule { }
\ No newline at end of file
let url = this.url.queryOperationProgress.replace("{serviceId}", paramsObj.serviceId);\r
return this.http.get<any>(url);\r
}\r
+ //get slicingBusinessDetail\r
+ getSlicingBusinessDetail(businessId: string){\r
+ let url = this.url.slicingBusinessDetail.replace("{businessId}",businessId);\r
+ return this.http.get<any>(url);\r
+ }\r
// Get slicing nsi list\r
getSlicingNsiList (paramsObj,isSelect: boolean) {\r
let url = this.url.slicingNsiList .replace("{pageNo}", paramsObj.pageNo)\r
--- /dev/null
+<p>
+ nsi-model works!
+ <button (click)="button()">我是nsi--button</button>
+</p>
--- /dev/null
+import { async, ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { NsiModelComponent } from './nsi-model.component';
+
+describe('NsiModelComponent', () => {
+ let component: NsiModelComponent;
+ let fixture: ComponentFixture<NsiModelComponent>;
+
+ beforeEach(async(() => {
+ TestBed.configureTestingModule({
+ declarations: [ NsiModelComponent ]
+ })
+ .compileComponents();
+ }));
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(NsiModelComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
--- /dev/null
+import { Component, OnInit } from '@angular/core';
+import {NzModalService} from "ng-zorro-antd";
+import { SlicingBusinessModelComponent } from '../../slicing-business-management/slicing-business-model/slicing-business-model.component';
+@Component({
+ selector: 'app-nsi-model',
+ templateUrl: './nsi-model.component.html',
+ styleUrls: ['./nsi-model.component.less']
+})
+export class NsiModelComponent implements OnInit {
+
+ constructor(
+ private modalService: NzModalService
+ ) {
+ }
+
+ ngOnInit() {
+ }
+ button(){
+ this.modalService.create({nzContent:SlicingBusinessModelComponent});
+ console.log(2222)
+ }
+}
-<p>
- slicing-business-model works!
-</p>
+<app-basic-info
+ [businessRequirement]="businessRequirement"
+ [NSTinfo]="NSTinfo"
+ [taskModel]="taskModel"
+>
+</app-basic-info>
+<nz-list class="taskmodel_list" nzBordered [nzHeader]="'Slicing NSI £º'" [nzFooter]="null">
+ <nz-table
+ #basicTable
+ [nzData]="nsiInfo"
+ [nzShowPagination]="false"
+ nzHideOnSinglePage
+ >
+ <thead>
+ <tr>
+ <th>Service Instance Id</th>
+ <th>Service Instance Name</th>
+ <th>Service Type</th>
+ <th>Status</th>
+ <th width="100px">Detail</th>
+ </tr>
+ </thead>
+ <tbody>
+ <ng-template ngFor let-data [ngForOf]="basicTable.data" let-i="index">
+ <tr>
+ <td>{{ data.nsi_id }}</td>
+ <td>{{ data.nsi_name }}</td>
+ <td>{{ data.nsi_type }}</td>
+ <td>{{ data.nsi_orchestration-status }}</td>
+ <td>
+ <a (click)="showdetail(data)">detail</a>
+ </td>
+ </tr>
+ </ng-template>
+ </tbody>
+ </nz-table>
+</nz-list>
\ No newline at end of file
+.taskmodel_list{
+ margin-bottom: 20px;
+}
\ No newline at end of file
-import { Component, OnInit } from '@angular/core';
+import {Component, OnInit, Input} from '@angular/core';
+import {NzModalService} from "ng-zorro-antd";
+import {SlicingTaskServices} from '.././../../../../../core/services/slicingTaskServices';
+import {NsiModelComponent} from "../../nsi-management/nsi-model/nsi-model.component";
@Component({
- selector: 'app-slicing-business-model',
- templateUrl: './slicing-business-model.component.html',
- styleUrls: ['./slicing-business-model.component.less']
+ selector: 'app-slicing-business-model',
+ templateUrl: './slicing-business-model.component.html',
+ styleUrls: ['./slicing-business-model.component.less']
})
export class SlicingBusinessModelComponent implements OnInit {
- constructor() { }
+ constructor(
+ private myhttp: SlicingTaskServices,
+ private modalService: NzModalService
+ ) {
+ }
- ngOnInit() {
- }
+ @Input() businessId;
+ businessRequirement: any[];
+ NSTinfo: any[];
+ nsiInfo: any[];
+ taskModel: boolean = false;
+ ngOnInit() {
+ console.log(this.businessId, "id");
+ this.getDetail()
+ }
+ getDetail() {
+ this.myhttp.getSlicingBusinessDetail(this.businessId).subscribe(res => {
+ const {result_header: {result_code}, result_body: {business_demand_info,nst_info,nsi_info} } = res;
+ if (+result_code === 200) {
+ // business_demand_info.coverage_area_ta_list.map((item)=>{
+ // item.replace(";"," ")
+ // });
+ this.businessRequirement = [business_demand_info];
+ this.NSTinfo = [nst_info];
+ this.nsiInfo = [nsi_info];
+ }
+ })
+ }
+ showdetail(data) {
+ console.log(data,"data.nsi_id");
+ const nsiModal = this.modalService.create({
+ nzTitle:"Detail",
+ nzContent: NsiModelComponent,
+ nzWidth:"70%",
+ nzOkText: null,
+ nzCancelText: null,
+ nzComponentParams:{
+ businessId:data.nsi_id
+ }
+ });
+ }
}
import {SlicingTaskServices} from '.././../../../../../core/services/slicingTaskServices';
import {BUSINESS_STATUS} from '../../../../../../../constants/constants';
import { NzModalService } from 'ng-zorro-antd';
-
+import { SlicingBusinessModelComponent } from '../slicing-business-model/slicing-business-model.component';
@Component({
selector: 'app-slicing-business-table',
templateUrl: './slicing-business-table.component.html',
}
});
}
- showdetail(data){
-
+ showdetail(data) {
+ const BusinessModal = this.modalService.create({
+ nzTitle:"Detail",
+ nzContent: SlicingBusinessModelComponent,
+ nzWidth:"70%",
+ nzOkText: null,
+ nzCancelText: null,
+ nzComponentParams:{
+ businessId:data.service_instance_id
+ }
+ })
}
queryProgress(obj, callback) {
return new Promise( res => {