diff --git a/src/pages/index.tsx b/src/pages/index.tsx index 4ebc352..1dfb925 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -1,3 +1,92 @@ -export default function index() { - return
欢迎登录
; +import React from 'react'; +import { useMyState } from '@/common'; +import { + BuildingOutlined, + ImportOutlined, + TeamOutlined, +} from '@ant-design/icons'; +import QuickActionCard from './components/QuickActionCard'; + +export default function Index() { + const { snap } = useMyState(); + const username = snap.session?.user?.username || '用户'; + + const quickActions = [ + { + icon: , + title: '添加机构', + description: '快速创建新的机构', + themeColor: '#1890ff', + path: '/company/list', + }, + { + icon: , + title: '导入项目', + description: '批量导入项目数据', + themeColor: '#52c41a', + path: '/asset/list', + }, + { + icon: , + title: '导入员工', + description: '批量导入员工数据', + themeColor: '#fa8c16', + path: '/company/employees', + }, + ]; + + return ( +
+
+ {/* 欢迎语区域 */} +
+

+ 欢迎回来,{username}! +

+

+ 这里是您的快捷工作台,点击下方卡片快速开始常用操作 +

+
+ + {/* 快捷操作卡片区域 */} +
+ {quickActions.map((action) => ( + + ))} +
+
+
+ ); }