From 14ea3e82d5d2969d47d1b919fb32a6a906d2e89d Mon Sep 17 00:00:00 2001 From: zhaozhenfang Date: Thu, 21 Dec 2023 09:19:45 +0800 Subject: [PATCH] develop the home page --- atune/web/index.html | 28 +++--- atune/web/src/App.vue | 2 +- atune/web/src/api/atune.ts | 8 ++ atune/web/src/components/atuneList.vue | 127 +++++++++++------------- atune/web/src/components/taskDetail.vue | 0 atune/web/src/router/index.ts | 18 +++- atune/web/src/types/atune.d.ts | 9 ++ atune/web/src/views/Home.vue | 121 ++++++++++++---------- atune/web/src/vite-env.d.ts | 1 + atune/web/vite.config.ts | 7 +- 10 files changed, 181 insertions(+), 140 deletions(-) create mode 100644 atune/web/src/components/taskDetail.vue create mode 100644 atune/web/src/vite-env.d.ts diff --git a/atune/web/index.html b/atune/web/index.html index 338418c7..9437bd9e 100644 --- a/atune/web/index.html +++ b/atune/web/index.html @@ -1,14 +1,18 @@ - - - - - - 智能调优 - - -
- - - + + + + + + + 智能调优 + + + +
+
+ + + + \ No newline at end of file diff --git a/atune/web/src/App.vue b/atune/web/src/App.vue index 5bc96cbb..63ccd49e 100644 --- a/atune/web/src/App.vue +++ b/atune/web/src/App.vue @@ -9,7 +9,7 @@ diff --git a/atune/web/src/components/taskDetail.vue b/atune/web/src/components/taskDetail.vue new file mode 100644 index 00000000..e69de29b diff --git a/atune/web/src/router/index.ts b/atune/web/src/router/index.ts index 06d6afc2..20d23202 100644 --- a/atune/web/src/router/index.ts +++ b/atune/web/src/router/index.ts @@ -5,19 +5,29 @@ import Result from '@/views/ResultInfo.vue'; const routes: Array = [ { - path: '/plugin/atune', + path: '/', + redirect: '/atune' + }, + { + path: '/atune', component: Home, - meta: { title: '首页' }, + meta: { title: '任务列表' }, + children: [ + { + path: 'detail', + component: () => import("../components/atuneTemplete.vue") + } + ] }, { - path: '/plugin/atune/result', + path: '/result', component: Result, meta: { title: '结果展示' }, }, ]; const router = createRouter({ - history: createWebHistory('/'), + history: createWebHistory(), routes, }); diff --git a/atune/web/src/types/atune.d.ts b/atune/web/src/types/atune.d.ts index 32dbd226..340465d8 100644 --- a/atune/web/src/types/atune.d.ts +++ b/atune/web/src/types/atune.d.ts @@ -1,3 +1,12 @@ +export interface Task { + id: number; + name: string; + atune: string; + state: number; + createTime: string; + updateTime: string; +} + export interface Atune { id: number; tuneName: string; diff --git a/atune/web/src/views/Home.vue b/atune/web/src/views/Home.vue index 5057d958..dd4034fd 100644 --- a/atune/web/src/views/Home.vue +++ b/atune/web/src/views/Home.vue @@ -1,28 +1,33 @@