From e38a055451749af668044d6db620b471368ab69a Mon Sep 17 00:00:00 2001 From: Steven Zou Date: Thu, 30 Mar 2017 12:33:42 +0800 Subject: [PATCH] fix issues --- src/ui_ng/src/app/account/sign-in/sign-in.component.html | 3 +-- src/ui_ng/src/app/account/sign-in/sign-in.component.ts | 9 +++++++++ .../src/app/base/navigator/navigator.component.html | 2 +- .../confirmation-dialog.component.css | 2 +- .../confirmation-dialog.component.html | 4 ++-- .../app/shared/inline-alert/inline-alert.component.css | 5 +++++ .../app/shared/inline-alert/inline-alert.component.html | 4 ++-- src/ui_ng/src/app/user/user.component.css | 4 ++++ src/ui_ng/src/app/user/user.component.html | 2 +- src/ui_ng/src/app/user/user.component.ts | 3 +++ src/ui_ng/src/i18n/lang/en-us-lang.json | 5 +++-- src/ui_ng/src/i18n/lang/zh-cn-lang.json | 3 ++- 12 files changed, 34 insertions(+), 12 deletions(-) diff --git a/src/ui_ng/src/app/account/sign-in/sign-in.component.html b/src/ui_ng/src/app/account/sign-in/sign-in.component.html index 3cf3e4ba9..15cbd5af9 100644 --- a/src/ui_ng/src/app/account/sign-in/sign-in.component.html +++ b/src/ui_ng/src/app/account/sign-in/sign-in.component.html @@ -1,7 +1,6 @@
\ No newline at end of file diff --git a/src/ui_ng/src/app/user/user.component.css b/src/ui_ng/src/app/user/user.component.css index 0facbe86d..cbd04a9ad 100644 --- a/src/ui_ng/src/app/user/user.component.css +++ b/src/ui_ng/src/app/user/user.component.css @@ -30,4 +30,8 @@ right: 2px; top: 12px; cursor: pointer; +} + +.hide-create { + visibility: hidden !important; } \ No newline at end of file diff --git a/src/ui_ng/src/app/user/user.component.html b/src/ui_ng/src/app/user/user.component.html index a2c1e1a3a..6410d3cf5 100644 --- a/src/ui_ng/src/app/user/user.component.html +++ b/src/ui_ng/src/app/user/user.component.html @@ -3,7 +3,7 @@

{{'SIDE_NAV.SYSTEM_MGMT.USER' | translate}}

- + diff --git a/src/ui_ng/src/app/user/user.component.ts b/src/ui_ng/src/app/user/user.component.ts index ffafc8a7d..a6d8f92f2 100644 --- a/src/ui_ng/src/app/user/user.component.ts +++ b/src/ui_ng/src/app/user/user.component.ts @@ -206,6 +206,9 @@ export class UserComponent implements OnInit, OnDestroy { //Add new user addNewUser(): void { + if (!this.canCreateUser) { + return;// No response to this hacking action + } this.newUserDialog.open(); } diff --git a/src/ui_ng/src/i18n/lang/en-us-lang.json b/src/ui_ng/src/i18n/lang/en-us-lang.json index fcf96164b..688fc1209 100644 --- a/src/ui_ng/src/i18n/lang/en-us-lang.json +++ b/src/ui_ng/src/i18n/lang/en-us-lang.json @@ -1,5 +1,6 @@ { "APP_TITLE": { + "VMW_HARBOR": "VMware Harbor", "HARBOR": "Harbor", "VIC": "vSphere Integrated Containers", "MGMT": "Management", @@ -110,7 +111,7 @@ "COLUMN_REG_NAME": "Registration time", "IS_ADMIN": "Yes", "IS_NOT_ADMIN": "No", - "ADD_USER_TITLE": "Add User", + "ADD_USER_TITLE": "New User", "SAVE_SUCCESS": "New user added successfully", "DELETION_TITLE": "Confirm user deletion", "DELETION_SUMMARY": "Do you want to delete user {{param}}?", @@ -386,7 +387,7 @@ "TEST_MAIL_FAILED": "Failed to verify mail server with error: {{param}}", "TEST_LDAP_FAILED": "Failed to verify LDAP server with error: {{param}}", "LEAVING_CONFIRMATION_TITLE": "Confirm to leave", - "LEAVING_CONFIRMATION_SUMMARY": "Changes have not been saved yet, do you really want to leave currnet page?" + "LEAVING_CONFIRMATION_SUMMARY": "Changes have not been saved yet,do you really want to leave currnet page?" }, "PAGE_NOT_FOUND": { "MAIN_TITLE": "Page not found", diff --git a/src/ui_ng/src/i18n/lang/zh-cn-lang.json b/src/ui_ng/src/i18n/lang/zh-cn-lang.json index b686682da..076268668 100644 --- a/src/ui_ng/src/i18n/lang/zh-cn-lang.json +++ b/src/ui_ng/src/i18n/lang/zh-cn-lang.json @@ -1,5 +1,6 @@ { "APP_TITLE": { + "VMW_HARBOR": "VMware Harbor", "HARBOR": "Harbor", "VIC": "vSphere Integrated Containers", "MGMT": "Management", @@ -110,7 +111,7 @@ "COLUMN_REG_NAME": "注册时间", "IS_ADMIN": "是", "IS_NOT_ADMIN": "否", - "ADD_USER_TITLE": "添加用户", + "ADD_USER_TITLE": "创建用户", "SAVE_SUCCESS": "添加用户成功", "DELETION_TITLE": "删除用户确认", "DELETION_SUMMARY": "你确认删除用户 {{param}}?",