feat: 初始化项目结构并添加基础配置

添加前后端基础项目结构,包括.gitignore、package.json等配置文件
实现前端基础功能模块,包括路由、状态管理、API请求封装等
添加前端UI组件库和样式体系
配置开发环境Mock系统和构建工具链
This commit is contained in:
2026-03-18 14:03:35 +08:00
parent fc53f5620e
commit 9a387f3eec
504 changed files with 80629 additions and 0 deletions

View File

@@ -0,0 +1,47 @@
const { mock } = require('mockjs')
const List = []
const count = 50
for (let i = 0; i < count; i++) {
List.push(
mock({
uuid: '@uuid',
id: '@id',
account: '@account(1, 2)',
'type|1': ['操作日志', '数据库日志', '系统日志'],
'account|1': ['admin', 'editor', 'test'],
'executeResult|1': [
'登录成功',
'登录成功',
'登录失败',
'接口异常',
'dos攻击',
],
ip: '@ip',
datetime: '@datetime',
})
)
}
module.exports = [
{
url: '/systemLog/getList',
type: 'get',
response: (config) => {
const { account, pageNo = 1, pageSize = 20 } = config.query
const mockList = List.filter(
(item) => !(account && !item.account.includes(account))
)
const list = mockList.filter(
(item, index) =>
index < pageSize * pageNo &&
index >= pageSize * (pageNo - 1)
)
return {
code: 200,
msg: 'success',
data: { list, ...{ total: mockList.length } },
}
},
},
]