初始化拉取,原文件名:admin-plus-webpack5
Some checks failed
Call HTTPS API / build (push) Has been cancelled

This commit is contained in:
2025-12-26 20:43:10 +08:00
parent 7c68ec3a42
commit 3e2da1115e
420 changed files with 75413 additions and 2 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',
taskName: '@account(1, 2)',
'status|1': [0, 1],
'account|1': ['admin', 'editor', 'test'],
'executeResult|1': [
'登录成功',
'登录成功',
'登录失败',
'接口异常',
'dos攻击',
],
ip: '@ip',
datetime: '@datetime',
})
)
}
module.exports = [
{
url: '/taskManagement/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 } },
}
},
},
]