From b34a07505c315da6305aaa0aee6f7a2a0234a921 Mon Sep 17 00:00:00 2001
From: 沈斌 <bluelazysb@hotmail.com>
Date: Wed, 28 Feb 2018 11:22:53 +0800
Subject: [PATCH] 隐藏标题栏无用的图标
---
src/app/routes/devices/basic-info/device-edit/device-edit.component.ts | 24 ++++++++++++------------
1 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/src/app/routes/devices/basic-info/device-edit/device-edit.component.ts b/src/app/routes/devices/basic-info/device-edit/device-edit.component.ts
index fc97214..49cb12b 100644
--- a/src/app/routes/devices/basic-info/device-edit/device-edit.component.ts
+++ b/src/app/routes/devices/basic-info/device-edit/device-edit.component.ts
@@ -39,7 +39,7 @@
}
const validates:Device = {
name:[data.name,[Validators.required]],
- mac:[data.mac],
+ mac:[data.mac,[Validators.required]],
deviceVersionId:[data.deviceVersionId],
monitorPointId:[data.monitorPointId],
operateUserId:[data.operateUserId],
@@ -71,7 +71,7 @@
const pageBean: PageBean = {pageIndex: 0, pageSize: 20};
this.monitorPointService.getPagingList(pageBean, text).subscribe(
(res: PageBean) => {
- if (res != null && res.data != null) {
+ if (res != null && res.data != null) {
this.monitorPoints = res.data;
}
const monitorPoint = this.data.monitorPoint;
@@ -81,9 +81,9 @@
return item.id === monitorPoint.id;
}
);
- if ( hasSelectedValue ) {
+ if ( !hasSelectedValue ) {
this.monitorPoints.push(monitorPoint);
- }
+ }
}
}
);
@@ -92,7 +92,7 @@
const pageBean: PageBean = {pageIndex: 0, pageSize: 20};
this.versionService.getPagingList(pageBean, text).subscribe(
(res: PageBean) => {
- if (res != null && res.data != null) {
+ if (res != null && res.data != null) {
this.deviceVersions = res.data;
}
const deviceVersion = this.data.deviceVersion;
@@ -102,9 +102,9 @@
return item.id === deviceVersion.id;
}
);
- if ( hasSelectedValue ) {
- this.monitorPoints.push(deviceVersion);
- }
+ if ( !hasSelectedValue ) {
+ this.deviceVersions.push(deviceVersion);
+ }
}
}
);
@@ -113,7 +113,7 @@
const pageBean: PageBean = {pageIndex: 0, pageSize: 20};
this.operateUserService.getPagingList(pageBean, text).subscribe(
(res: PageBean) => {
- if (res != null && res.data != null) {
+ if (res != null && res.data != null) {
this.operateUsers = res.data;
}
const operateUser = this.data.operateUser;
@@ -123,9 +123,9 @@
return item.id === operateUser.id;
}
);
- if ( hasSelectedValue ) {
- this.monitorPoints.push(operateUser);
- }
+ if ( !hasSelectedValue ) {
+ this.operateUsers.push(operateUser);
+ }
}
}
);
--
Gitblit v1.8.0