83
83
:sm =" 24"
84
84
:xs =" 24"
85
85
>
86
- <el-card shadow =" hover" class =" mr-5px mt-5px" >
86
+ <el-card
87
+ shadow =" hover"
88
+ class =" mr-5px mt-5px cursor-pointer"
89
+ @click =" handleProjectClick(item.message)"
90
+ >
87
91
<div class =" flex items-center" >
88
- <Icon :icon =" item.icon" :size =" 25" class =" mr-8px" />
92
+ <Icon :icon =" item.icon" :size =" 25" class =" mr-8px" :style = " { color: item.color } " />
89
93
<span class =" text-16px" >{{ item.name }}</span >
90
94
</div >
91
- <div class =" mt-12px text-9px text-gray-400" >{{ t(item.message) }}</div >
95
+ <div class =" mt-12px text-12px text-gray-400" >{{ t(item.message) }}</div >
92
96
<div class =" mt-12px flex justify-between text-12px text-gray-400" >
93
97
<span >{{ item.personal }}</span >
94
98
<span >{{ formatTime(item.time, 'yyyy-MM-dd') }}</span >
131
135
<el-row >
132
136
<el-col v-for =" item in shortcut" :key =" `team-${item.name}`" :span =" 8" class =" mb-8px" >
133
137
<div class =" flex items-center" >
134
- <Icon :icon =" item.icon" class =" mr-8px" />
135
- <el-link type =" default" :underline =" false" @click =" setWatermark (item.name )" >
138
+ <Icon :icon =" item.icon" class =" mr-8px" :style = " { color: item.color } " />
139
+ <el-link type =" default" :underline =" false" @click =" handleShortcutClick (item.url )" >
136
140
{{ item.name }}
137
141
</el-link >
138
142
</div >
@@ -180,10 +184,12 @@ import { useUserStore } from '@/store/modules/user'
180
184
import { useWatermark } from ' @/hooks/web/useWatermark'
181
185
import type { WorkplaceTotal , Project , Notice , Shortcut } from ' ./types'
182
186
import { pieOptions , barOptions } from ' ./echarts-data'
187
+ import { useRouter } from ' vue-router'
183
188
184
189
defineOptions ({ name: ' Home' })
185
190
186
191
const { t } = useI18n ()
192
+ const router = useRouter ()
187
193
const userStore = useUserStore ()
188
194
const { setWatermark } = useWatermark ()
189
195
const loading = ref (true )
@@ -212,45 +218,51 @@ const getProject = async () => {
212
218
const data = [
213
219
{
214
220
name: ' ruoyi-vue-pro' ,
215
- icon: ' akar -icons:github-fill ' ,
216
- message: ' https:// github.com/YunaiV/ruoyi-vue-pro' ,
221
+ icon: ' simple -icons:springboot ' ,
222
+ message: ' github.com/YunaiV/ruoyi-vue-pro' ,
217
223
personal: ' Spring Boot 单体架构' ,
218
- time: new Date ()
224
+ time: new Date (' 2025-01-02' ),
225
+ color: ' #6DB33F'
219
226
},
220
227
{
221
228
name: ' yudao-ui-admin-vue3' ,
222
- icon: ' logos:vue' ,
223
- message: ' https://github.com/yudaocode/yudao-ui-admin-vue3' ,
224
- personal: ' Vue3 + element-plus' ,
225
- time: new Date ()
229
+ icon: ' ep:element-plus' ,
230
+ message: ' github.com/yudaocode/yudao-ui-admin-vue3' ,
231
+ personal: ' Vue3 + element-plus 管理后台' ,
232
+ time: new Date (' 2025-02-03' ),
233
+ color: ' #409EFF'
226
234
},
227
235
{
228
- name: ' yudao-ui-admin-vben' ,
229
- icon: ' logos:vue' ,
230
- message: ' https://github.com/yudaocode/yudao-ui-admin-vben' ,
231
- personal: ' Vue3 + vben(antd)' ,
232
- time: new Date ()
236
+ name: ' yudao-ui-mall-uniapp' ,
237
+ icon: ' icon-park-outline:mall-bag' ,
238
+ message: ' github.com/yudaocode/yudao-ui-mall-uniapp' ,
239
+ personal: ' Vue3 + uniapp 商城手机端' ,
240
+ time: new Date (' 2025-03-04' ),
241
+ color: ' #ff4d4f'
233
242
},
234
243
{
235
244
name: ' yudao-cloud' ,
236
- icon: ' akar-icons:github ' ,
237
- message: ' https:// github.com/YunaiV/yudao-cloud' ,
245
+ icon: ' material-symbols:cloud-outline ' ,
246
+ message: ' github.com/YunaiV/yudao-cloud' ,
238
247
personal: ' Spring Cloud 微服务架构' ,
239
- time: new Date ()
248
+ time: new Date (' 2025-04-05' ),
249
+ color: ' #1890ff'
240
250
},
241
251
{
242
- name: ' yudao-ui-mall-uniapp' ,
243
- icon: ' logos:vue' ,
244
- message: ' https://github.com/yudaocode/yudao-ui-admin-uniapp' ,
245
- personal: ' Vue3 + uniapp' ,
246
- time: new Date ()
252
+ name: ' yudao-ui-admin-vben' ,
253
+ icon: ' devicon:antdesign' ,
254
+ message: ' github.com/yudaocode/yudao-ui-admin-vben' ,
255
+ personal: ' Vue3 + vben5(antd) 管理后台' ,
256
+ time: new Date (' 2025-05-06' ),
257
+ color: ' #e18525'
247
258
},
248
259
{
249
- name: ' yudao-ui-admin-vue2' ,
250
- icon: ' logos:vue' ,
251
- message: ' https://github.com/yudaocode/yudao-ui-admin-vue2' ,
252
- personal: ' Vue2 + element-ui' ,
253
- time: new Date ()
260
+ name: ' yudao-ui-admin-uniapp' ,
261
+ icon: ' ant-design:mobile' ,
262
+ message: ' github.com/yudaocode/yudao-ui-admin-uniapp' ,
263
+ personal: ' Vue3 + uniapp 管理手机端' ,
264
+ time: new Date (' 2025-06-01' ),
265
+ color: ' #2979ff'
254
266
}
255
267
]
256
268
projects = Object .assign (projects , data )
@@ -262,26 +274,26 @@ const getNotice = async () => {
262
274
const data = [
263
275
{
264
276
title: ' 系统支持 JDK 8/17/21,Vue 2/3' ,
265
- type: ' 通知 ' ,
266
- keys: [' 通知 ' , ' 8 ' , ' 17 ' , ' 21 ' , ' 2 ' , ' 3 ' ],
277
+ type: ' 技术兼容性 ' ,
278
+ keys: [' JDK ' , ' Vue ' ],
267
279
date: new Date ()
268
280
},
269
281
{
270
282
title: ' 后端提供 Spring Boot 2.7/3.2 + Cloud 双架构' ,
271
- type: ' 公告 ' ,
272
- keys: [' 公告 ' , ' Boot' , ' Cloud' ],
283
+ type: ' 架构灵活性 ' ,
284
+ keys: [' Boot' , ' Cloud' ],
273
285
date: new Date ()
274
286
},
275
287
{
276
288
title: ' 全部开源,个人与企业可 100% 直接使用,无需授权' ,
277
- type: ' 通知 ' ,
278
- keys: [' 通知 ' , ' 无需授权' ],
289
+ type: ' 开源免授权 ' ,
290
+ keys: [' 无需授权' ],
279
291
date: new Date ()
280
292
},
281
293
{
282
- title: ' 国内使用最广泛的快速开发平台,超 300+ 人贡献 ' ,
283
- type: ' 公告 ' ,
284
- keys: [' 公告 ' , ' 最广泛 ' ],
294
+ title: ' 国内使用最广泛的快速开发平台,远超 10w+ 企业使用 ' ,
295
+ type: ' 广泛企业认可 ' ,
296
+ keys: [' 最广泛 ' , ' 10w+ ' ],
285
297
date: new Date ()
286
298
}
287
299
]
@@ -294,34 +306,40 @@ let shortcut = reactive<Shortcut[]>([])
294
306
const getShortcut = async () => {
295
307
const data = [
296
308
{
297
- name: ' Github' ,
298
- icon: ' akar-icons:github-fill' ,
299
- url: ' github.io'
309
+ name: ' 首页' ,
310
+ icon: ' ion:home-outline' ,
311
+ url: ' /' ,
312
+ color: ' #1fdaca'
300
313
},
301
314
{
302
- name: ' Vue' ,
303
- icon: ' logos:vue' ,
304
- url: ' vuejs.org'
315
+ name: ' 商城中心' ,
316
+ icon: ' ep:shop' ,
317
+ url: ' /mall/home' ,
318
+ color: ' #ff6b6b'
305
319
},
306
320
{
307
- name: ' Vite' ,
308
- icon: ' vscode-icons:file-type-vite' ,
309
- url: ' https://vitejs.dev/'
321
+ name: ' AI 大模型' ,
322
+ icon: ' tabler:ai' ,
323
+ url: ' /ai/chat' ,
324
+ color: ' #7c3aed'
310
325
},
311
326
{
312
- name: ' Angular' ,
313
- icon: ' logos:angular-icon' ,
314
- url: ' github.io'
327
+ name: ' ERP 系统' ,
328
+ icon: ' simple-icons:erpnext' ,
329
+ url: ' /erp/home' ,
330
+ color: ' #3fb27f'
315
331
},
316
332
{
317
- name: ' React' ,
318
- icon: ' logos:react' ,
319
- url: ' github.io'
333
+ name: ' CRM 系统' ,
334
+ icon: ' simple-icons:civicrm' ,
335
+ url: ' /crm/backlog' ,
336
+ color: ' #4daf1bc9'
320
337
},
321
338
{
322
- name: ' Webpack' ,
323
- icon: ' logos:webpack' ,
324
- url: ' github.io'
339
+ name: ' IoT 物联网' ,
340
+ icon: ' fa-solid:hdd' ,
341
+ url: ' /iot/home' ,
342
+ color: ' #1a73e8'
325
343
}
326
344
]
327
345
shortcut = Object .assign (shortcut , data )
@@ -387,5 +405,13 @@ const getAllApi = async () => {
387
405
loading .value = false
388
406
}
389
407
408
+ const handleProjectClick = (message : string ) => {
409
+ window .open (` https://${message } ` , ' _blank' )
410
+ }
411
+
412
+ const handleShortcutClick = (url : string ) => {
413
+ router .push (url )
414
+ }
415
+
390
416
getAllApi ()
391
417
</script >
0 commit comments