Commit 83c30170 authored by wangqinghua's avatar wangqinghua

bug update

parent 74840dd8
...@@ -31,7 +31,7 @@ export class NotificationInterceptor implements HttpInterceptor { ...@@ -31,7 +31,7 @@ export class NotificationInterceptor implements HttpInterceptor {
if (data && data.errCode) { if (data && data.errCode) {
const errCode = data.errCode; const errCode = data.errCode;
const errMsg = data.errMsg; const errMsg = data.errMsg;
if (errCode && errCode != 10000 && errCode != 10099 && errCode == 10103) { if (errCode && errCode != 10000 && errCode != 10099) {
this.notification.create('error', `错误码:${errCode}`, `${errMsg}`, {nzDuration: 2000}); this.notification.create('error', `错误码:${errCode}`, `${errMsg}`, {nzDuration: 2000});
} }
} }
......
...@@ -44,8 +44,8 @@ ...@@ -44,8 +44,8 @@
</div> </div>
<div nz-col nzSpan="12" class="spanBorder"> <div nz-col nzSpan="12" class="spanBorder">
<span (click)="reportDetail(item)">运行报告</span> <span (click)="reportDetail(item)">运行报告</span>
<span (click)="goTo(item)" >业务拓扑</span> <span (click)="goToTopo(item)" >业务拓扑</span>
<span routerLink="../effectAnalysis">效能分析</span> <span (click)="goToAnalysis(item)">效能分析</span>
</div> </div>
</div> </div>
<div nz-row> <div nz-row>
......
...@@ -206,7 +206,7 @@ export class BOverviewComponent implements OnInit { ...@@ -206,7 +206,7 @@ export class BOverviewComponent implements OnInit {
} }
//bTopology //bTopology
goTo(item){ goToTopo(item){
this.router.navigate(['app/main/bTopology'],{ this.router.navigate(['app/main/bTopology'],{
queryParams:{ queryParams:{
topoId:item.id topoId:item.id
...@@ -214,4 +214,12 @@ export class BOverviewComponent implements OnInit { ...@@ -214,4 +214,12 @@ export class BOverviewComponent implements OnInit {
}) })
} }
//effectAnalysis
goToAnalysis(item){
this.router.navigate(['app/main/effectAnalysis'],{
queryParams:{
topoId:item.id
}
})
}
} }
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<div nz-col nzSpan="12"> <div nz-col nzSpan="12">
<nz-select style="width: 200px;" nzPlaceHolder="选择业务" [(ngModel)]="topoId" (ngModelChange)="getDetail()"> <nz-select style="width: 200px;" nzPlaceHolder="选择业务" [(ngModel)]="topoId" (ngModelChange)="getDetail()">
<ng-container *ngFor="let item of rootList"> <ng-container *ngFor="let item of rootList">
<nz-option [nzLabel]="item.name" [nzValue]="item.serviceid"></nz-option> <nz-option [nzLabel]="item.name" nzValue="{{item.serviceid}}"></nz-option>
</ng-container> </ng-container>
</nz-select> </nz-select>
</div> </div>
......
...@@ -97,12 +97,13 @@ export class BTopologyComponent implements OnInit, AfterViewInit { ...@@ -97,12 +97,13 @@ export class BTopologyComponent implements OnInit, AfterViewInit {
editType = '只读模式'; editType = '只读模式';
constructor(private busineSer: BusinessService, private message: NzMessageService, constructor(private busineSer: BusinessService, private message: NzMessageService,
private routerInfo:ActivatedRoute) { private routerInfo: ActivatedRoute) {
this.routerInfo.queryParams.subscribe( this.routerInfo.queryParams.subscribe(
(res) => { (res) => {
console.log(res); if (res) {
this.topoId = res.topoId; this.topoId = res.topoId + '';
this.getDetail(); this.getDetail();
}
} }
); );
} }
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<div nz-col nzSpan="12"> <div nz-col nzSpan="12">
<nz-select style="width: 200px;" nzPlaceHolder="选择业务" [(ngModel)]="serviceId" (ngModelChange)="changeService()"> <nz-select style="width: 200px;" nzPlaceHolder="选择业务" [(ngModel)]="serviceId" (ngModelChange)="changeService()">
<ng-container *ngFor="let item of rootList"> <ng-container *ngFor="let item of rootList">
<nz-option [nzLabel]="item.name" [nzValue]="item.serviceid"></nz-option> <nz-option [nzLabel]="item.name" nzValue="{{item.serviceid}}"></nz-option>
</ng-container> </ng-container>
</nz-select> </nz-select>
</div> </div>
......
...@@ -5,6 +5,7 @@ import {DatePipe} from '@angular/common'; ...@@ -5,6 +5,7 @@ import {DatePipe} from '@angular/common';
import {color} from '../../app.constants'; import {color} from '../../app.constants';
import {NzMessageService} from 'ng-zorro-antd'; import {NzMessageService} from 'ng-zorro-antd';
import {CommonService} from '../../shared/common/common.service'; import {CommonService} from '../../shared/common/common.service';
import {ActivatedRoute} from '@angular/router';
@Component({ @Component({
selector: 'smart-effect-analysis', selector: 'smart-effect-analysis',
...@@ -82,8 +83,17 @@ export class EffectAnalysisComponent implements OnInit { ...@@ -82,8 +83,17 @@ export class EffectAnalysisComponent implements OnInit {
chartUser; chartUser;
constructor(private busineSer: BusinessService, private overAllSer: OverAllService, constructor(private busineSer: BusinessService, private overAllSer: OverAllService,
private commonSer:CommonService, private commonSer: CommonService,
private routerInfo: ActivatedRoute,
private datePipe: DatePipe, private message: NzMessageService) { private datePipe: DatePipe, private message: NzMessageService) {
this.routerInfo.queryParams.subscribe(
(res) => {
if (res) {
this.serviceId = res.topoId + '';
this.changeService();
}
}
);
} }
ngOnInit() { ngOnInit() {
...@@ -211,8 +221,10 @@ export class EffectAnalysisComponent implements OnInit { ...@@ -211,8 +221,10 @@ export class EffectAnalysisComponent implements OnInit {
(res) => { (res) => {
this.rootList = res.data; this.rootList = res.data;
if (this.rootList.length > 0) { if (this.rootList.length > 0) {
this.serviceId = this.rootList[0].serviceid; if (!this.serviceId) {
this.changeService(); this.serviceId = this.rootList[0].serviceid;
this.changeService();
}
} }
} }
); );
...@@ -336,7 +348,7 @@ export class EffectAnalysisComponent implements OnInit { ...@@ -336,7 +348,7 @@ export class EffectAnalysisComponent implements OnInit {
//时间改变 //时间改变
changeType() { changeType() {
this.isSpinning = true; this.isSpinning = true;
if(this.timeType =='99') return ; if (this.timeType == '99') return;
this.obj.startTime = this.commonSer.getTimeByType(this.timeType).startTime; this.obj.startTime = this.commonSer.getTimeByType(this.timeType).startTime;
this.obj.endTime = this.commonSer.getTimeByType(this.timeType).endTime; this.obj.endTime = this.commonSer.getTimeByType(this.timeType).endTime;
this.findChart(); this.findChart();
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
<nz-form-item nzFlex> <nz-form-item nzFlex>
<nz-form-label [nzSpan]="6" nzRequired nzFor="webName">网站名称</nz-form-label> <nz-form-label [nzSpan]="6" nzRequired nzFor="webName">网站名称</nz-form-label>
<nz-form-control [nzSpan]="14"> <nz-form-control [nzSpan]="14">
<input id="webName" name="webName" nz-input placeholder="网站名称" [(ngModel)]="validateForm.name"> <input id="webName" maxlength="20" name="webName" nz-input placeholder="网站名称" [(ngModel)]="validateForm.name">
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
</div> </div>
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
<nz-form-item nzFlex> <nz-form-item nzFlex>
<nz-form-label [nzSpan]="3" nzFor="http_proxy">Http代理</nz-form-label> <nz-form-label [nzSpan]="3" nzFor="http_proxy">Http代理</nz-form-label>
<nz-form-control [nzSpan]="18"> <nz-form-control [nzSpan]="18">
<input id="http_proxy" name="http_proxy" nz-input placeholder="默认" <input id="http_proxy" maxlength="40" name="http_proxy" nz-input placeholder="默认"
[(ngModel)]="validateForm.http_proxy"> [(ngModel)]="validateForm.http_proxy">
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
......
...@@ -87,8 +87,8 @@ ...@@ -87,8 +87,8 @@
<td class="handle main-color"> <td class="handle main-color">
<span (click)="lookPlan(data.id,data.title)">查看</span> <span (click)="lookPlan(data.id,data.title)">查看</span>
<span *ngIf="data.status == 1" (click)="dealPlan(data.id)">处理</span> <span *ngIf="data.status == 1" (click)="dealPlan(data.id)">处理</span>
<span *ngIf="data.status != 2" (click)="editPlan(data.id)">编辑</span> <span *ngIf="data.status == 0 || data.status == 2"(click)="editPlan(data.id)">编辑</span>
<span class="handle-delete" (click)="deletePlan(data)">删除</span> <span *ngIf="data.status != 1" class="handle-delete" (click)="deletePlan(data)">删除</span>
</td> </td>
</tr> </tr>
</tbody> </tbody>
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
"noImplicitAny": false, "noImplicitAny": false,
"skipLibCheck": true, "skipLibCheck": true,
"suppressImplicitAnyIndexErrors": true, "suppressImplicitAnyIndexErrors": true,
"outDir": "build/master/app", "outDir": "build/www/app",
"lib": ["es7", "dom"], "lib": ["es7", "dom"],
"typeRoots": [ "typeRoots": [
"node_modules/@types" "node_modules/@types"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment