From 63ba0189a5796f41fd077c308519684ae45fb1f2 Mon Sep 17 00:00:00 2001 From: chenjinsong <523037378@qq.com> Date: Tue, 18 May 2021 20:45:46 +0800 Subject: [PATCH 1/6] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E4=B8=80=E4=BA=9B?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/common/popBox/guide.vue | 58 ++++++++++--------- .../common/table/settings/mibTable.vue | 8 +-- nezha-fronted/static/config.json | 2 +- 3 files changed, 35 insertions(+), 33 deletions(-) diff --git a/nezha-fronted/src/components/common/popBox/guide.vue b/nezha-fronted/src/components/common/popBox/guide.vue index 8f2a5f879..d67b17a72 100644 --- a/nezha-fronted/src/components/common/popBox/guide.vue +++ b/nezha-fronted/src/components/common/popBox/guide.vue @@ -12,52 +12,52 @@ @mouseenter="enter(index)" @mouseleave="leave(index)" >
{{guide.title}}
-
+
@@ -83,42 +83,42 @@ export default { title: this.$t('guide.dc'), icon: 'nz-icon nz-icon-datacenter1', tip: this.$t('guide.dcTip'), - buttonPermissions: 'dc_add' + permissionCode: 'dc_view' }, { route: '/agent', title: this.$t('guide.agent'), icon: 'nz-icon nz-icon-agent', tip: this.$t('guide.agentTip'), - buttonPermissions: 'agent_add' + permissionCode: 'agent_view' }, { route: '/asset', title: this.$t('guide.asset'), icon: 'nz-icon nz-icon-menu-assets', tip: this.$t('guide.assetTip'), - buttonPermissions: 'asset_add' + permissionCode: 'asset_view' }, { route: '/monitor/project', title: this.$t('guide.monitor'), icon: 'nz-icon nz-icon-menu-project', tip: this.$t('guide.monitorTip'), - buttonPermissions: 'project_add' + permissionCode: 'project_view' }, { route: '/panel', title: this.$t('guide.visualization'), icon: 'nz-icon nz-icon-visualization', tip: this.$t('guide.visualizationTip'), - buttonPermissions: 'panel_add' + permissionCode: 'panel_view' }, { route: '/alertRule', title: this.$t('guide.alert'), icon: 'nz-icon nz-icon-menu-alert', tip: this.$t('guide.alertTip'), - buttonPermissions: "alertRule_add" + permissionCode: 'alertRule_view' } ], interval: null @@ -157,13 +157,13 @@ export default { this.$store.commit('openConsole') }, jump (route) { - let buttonPermissions = true + let allowed = false this.guideList.forEach(ele => { - if (!this.hasButton(ele.buttonPermissions)){ - buttonPermissions = false + if (this.hasButton(ele.permissionCode)) { + allowed = true } }) - if (!buttonPermissions){ + if (!allowed) { return } this.$emit('close') @@ -407,6 +407,9 @@ export default { color: #ABABAB; } } + .item__icon.item__icon--disabled { + cursor: not-allowed; + } } .item__title { padding-top: 20px; @@ -483,9 +486,8 @@ export default { .guide__btn:hover { opacity: .9; } - .nz-btn-permissions { - pointer-events: none; - cursor: default; + .guide__btn.guide__btn--disabled { + cursor: not-allowed; opacity: 0.4; } } diff --git a/nezha-fronted/src/components/common/table/settings/mibTable.vue b/nezha-fronted/src/components/common/table/settings/mibTable.vue index e2acf4ae3..729f01cec 100644 --- a/nezha-fronted/src/components/common/table/settings/mibTable.vue +++ b/nezha-fronted/src/components/common/table/settings/mibTable.vue @@ -106,12 +106,12 @@ export default { prop: 'id', show: true, width: 80, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('overall.name'), prop: 'name', show: true, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('config.mib.fileName'), prop: 'fileName', @@ -127,11 +127,11 @@ export default { }, { label: this.$t('config.mib.updateUser'), prop: 'updateUser', - show: true + show: false }, { label: this.$t('config.mib.updateAt'), prop: 'updateAt', - show: true + show: false } ] } diff --git a/nezha-fronted/static/config.json b/nezha-fronted/static/config.json index 11023ada9..032748342 100644 --- a/nezha-fronted/static/config.json +++ b/nezha-fronted/static/config.json @@ -1 +1 @@ -{"baseUrl":"http://192.168.40.42:8080/nz-admin/", "version": "2.0.2021.05.11.19.43"} +{"baseUrl":"/", "version": "2.0.2021.05.11.19.43"} From c2aefa02088b22d457e8a964336185c26e022a22 Mon Sep 17 00:00:00 2001 From: chenjinsong <523037378@qq.com> Date: Tue, 18 May 2021 20:57:51 +0800 Subject: [PATCH 2/6] =?UTF-8?q?NEZ-626=20fix:=20overview=E6=A0=B7=E5=BC=8F?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nezha-fronted/src/assets/css/common/tableCommon.scss | 1 + .../src/components/page/dashboard/overview/overview2.scss | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/nezha-fronted/src/assets/css/common/tableCommon.scss b/nezha-fronted/src/assets/css/common/tableCommon.scss index 82b903cf6..388e89d77 100644 --- a/nezha-fronted/src/assets/css/common/tableCommon.scss +++ b/nezha-fronted/src/assets/css/common/tableCommon.scss @@ -2,6 +2,7 @@ .list-page { height: 100%; width: 100%; + box-sizing: border-box; background-color: #f6f6f6; .main-list { diff --git a/nezha-fronted/src/components/page/dashboard/overview/overview2.scss b/nezha-fronted/src/components/page/dashboard/overview/overview2.scss index 295a2dd80..5327ce5fd 100644 --- a/nezha-fronted/src/components/page/dashboard/overview/overview2.scss +++ b/nezha-fronted/src/components/page/dashboard/overview/overview2.scss @@ -1,6 +1,6 @@ .overview { - height: 100%; - padding: 0 10px; + height: calc(100% - 20px) !important; + padding: 0 0 0 10px; background-color: #f6f6f6; } .overview-content-header{ @@ -71,10 +71,10 @@ color: #666666; } .overview-content { - padding: 0 10px 15px; + padding: 0 10px; background-color: white; box-sizing: border-box; - height: calc(100% - 42px); + height: calc(100% - 50px); width: 100%; } .overview-content .content-row-box { From f12dd956bf9a33c6b53fbfa2c971c32a8f08e0c1 Mon Sep 17 00:00:00 2001 From: wangwenrui Date: Wed, 19 May 2021 09:53:32 +0800 Subject: [PATCH 3/6] =?UTF-8?q?fix:=E4=BF=AE=E5=A4=8D=E8=B7=AF=E5=BE=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nezha-fronted/build/script/buildEnd.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nezha-fronted/build/script/buildEnd.sh b/nezha-fronted/build/script/buildEnd.sh index f4c43dc2a..36c10888a 100644 --- a/nezha-fronted/build/script/buildEnd.sh +++ b/nezha-fronted/build/script/buildEnd.sh @@ -8,7 +8,7 @@ DIST_PATH=$CUR_PATH/dist echo 'dist dir path is '${DIST_PATH} -cp -f src/assets/img/log1-2.png $DIST_PATH/static +cp -f src/assets/img/logo1-2.png $DIST_PATH/static cd $DIST_PATH From 3a3553220eb8bc6eea1dd440ec06a56e67e5f0e7 Mon Sep 17 00:00:00 2001 From: wangwenrui Date: Wed, 19 May 2021 11:10:38 +0800 Subject: [PATCH 4/6] =?UTF-8?q?fix:=E4=BF=AE=E5=A4=8D=E8=B7=AF=E5=BE=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nezha-fronted/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nezha-fronted/index.html b/nezha-fronted/index.html index b9f5c1fdc..8ba95ba23 100644 --- a/nezha-fronted/index.html +++ b/nezha-fronted/index.html @@ -4,7 +4,7 @@ - + Nezha