From 92760c6a3778c7cf4f74a610127edff8e48b0f22 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=9C=E9=B9=B0?= <17kungfuboy@gmail.com> Date: Tue, 28 Jun 2022 11:45:32 +0800 Subject: [PATCH] feat: update env --- .../src/app/pages/api/api.component.html | 39 ++++++++++++------- .../src/app/pages/api/api.component.scss | 9 +++++ .../src/app/pages/api/api.component.ts | 6 +++ .../shared/components/env/env.component.html | 6 +-- 4 files changed, 44 insertions(+), 16 deletions(-) diff --git a/src/workbench/browser/src/app/pages/api/api.component.html b/src/workbench/browser/src/app/pages/api/api.component.html index 969aa3b86..87397dc00 100644 --- a/src/workbench/browser/src/app/pages/api/api.component.html +++ b/src/workbench/browser/src/app/pages/api/api.component.html @@ -2,10 +2,12 @@ - + - + + +
@@ -13,13 +15,17 @@ - + + + - + + + @@ -32,15 +38,22 @@
- - - +
+ + + + + + 管理环境 + +
diff --git a/src/workbench/browser/src/app/pages/api/api.component.scss b/src/workbench/browser/src/app/pages/api/api.component.scss index 08aa888f0..7b175e4f4 100644 --- a/src/workbench/browser/src/app/pages/api/api.component.scss +++ b/src/workbench/browser/src/app/pages/api/api.component.scss @@ -68,3 +68,12 @@ nz-sider { } } +nz-divider { + margin-top: 0.5em; + margin-bottom: 0.5em; +} + +.manager-env { + color: #00785a; +} + diff --git a/src/workbench/browser/src/app/pages/api/api.component.ts b/src/workbench/browser/src/app/pages/api/api.component.ts index 2ed041eb6..21f8561b2 100644 --- a/src/workbench/browser/src/app/pages/api/api.component.ts +++ b/src/workbench/browser/src/app/pages/api/api.component.ts @@ -38,6 +38,7 @@ export class ApiComponent implements OnInit, OnDestroy { envInfo: any = {}; envList: Array = []; activeUuid: number | string = 0; + tabsIndex = 0; private destroy$: Subject = new Subject(); constructor( @@ -127,6 +128,11 @@ export class ApiComponent implements OnInit, OnDestroy { this.messageService.send({ type: 'beforeChangeRouter', data }); } + gotoEnvManager() { + // * switch to env + this.tabsIndex = 2; + } + getAllEnv(uuid?: number) { const projectID = 1; return new Promise((resolve) => { diff --git a/src/workbench/browser/src/app/shared/components/env/env.component.html b/src/workbench/browser/src/app/shared/components/env/env.component.html index 8a45ca78e..1d6d1ef48 100644 --- a/src/workbench/browser/src/app/shared/components/env/env.component.html +++ b/src/workbench/browser/src/app/shared/components/env/env.component.html @@ -11,10 +11,10 @@ 管理环境 -->
-
+
Environment
{{ item.name }}