Commit c3eee9c4 authored by wangqinghua's avatar wangqinghua

bug update

parent 251786ab
......@@ -547,7 +547,7 @@ export class BasicComponent implements OnInit {
} else {
type = 'server';
}
this.router.navigate([type], {
this.router.navigate([`app/main/${type}`], {
queryParams: {
hostId: item.hostid,
equipmentType: item.equipmentType
......
......@@ -106,6 +106,13 @@
</nz-form-control>
</nz-form-item>
<nz-form-item>
<nz-form-label [nzSpan]="7" nzRequired nzFor="name">完成时间</nz-form-label>
<nz-form-control [nzSpan]="15">
<nz-date-picker [(ngModel)]="modal.date" nzFormat="yyyy-MM-dd" [ngModelOptions]="{standalone: true}"></nz-date-picker>
<nz-time-picker [(ngModel)]="modal.time" [ngModelOptions]="{standalone: true}"></nz-time-picker>
</nz-form-control>
</nz-form-item>
<nz-form-item>
<nz-form-label [nzSpan]="7" nzRequired nzFor="name">处理情况</nz-form-label>
<nz-form-control [nzSpan]="12">
<textarea [(ngModel)]="modal.processRemark" [ngModelOptions]="{standalone: true}" row="4" nz-input></textarea>
......
......@@ -5,6 +5,7 @@ import {NzMessageService, NzModalService} from 'ng-zorro-antd';
import {PlanModalComponent} from '../modal/plan-modal/plan-modal.component';
import {LookPlanComponent} from '../modal/look-plan/look-plan.component';
import {CommonService} from '../../shared/common/common.service';
import {DatePipe} from '@angular/common';
@Component({
selector: 'smart-inspect-plan',
......@@ -39,10 +40,13 @@ export class InspectPlanComponent implements OnInit {
isOkLoading: false,
planId: '',
processResult: '0',
date: null,
time: null,
processRemark: ''
};
constructor(private workSer: WorkService, private message: NzMessageService,
private datePipe:DatePipe,
private commonSer: CommonService,
private modalSer: NzModalService) {
}
......@@ -154,14 +158,19 @@ export class InspectPlanComponent implements OnInit {
//确定
handleOk() {
if (!this.modal.date || !this.modal.time) {
this.message.error('请选择完成时间');
return false;
}
if (!this.modal.processRemark) {
this.message.error('请输入必填项');
return
this.message.error('请输入处理情况');
return;
}
const data = {
planId: this.modal.planId,
processResult: this.modal.processResult,
processRemark: this.modal.processRemark,
completeTime: new Date(this.datePipe.transform(this.modal.date, 'yyyy-MM-dd') + ' ' + this.datePipe.transform(this.modal.time, 'HH:mm:ss')).getTime()
};
this.modal.isOkLoading = true;
this.workSer.processPlan(data).subscribe(
......
......@@ -10,7 +10,7 @@
"noImplicitAny": false,
"skipLibCheck": true,
"suppressImplicitAnyIndexErrors": true,
"outDir": "build/www/app",
"outDir": "build/master/app",
"lib": ["es7", "dom"],
"typeRoots": [
"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