You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
511 lines
6.5 KiB
511 lines
6.5 KiB
/**
|
|
* 自动生成 Mock 数据
|
|
*/
|
|
|
|
import { MockMethod } from 'vite-plugin-mock';
|
|
|
|
const list = [
|
|
|
|
|
|
{
|
|
|
|
id: 'id_0',
|
|
|
|
msgNote: 'msgNote_0',
|
|
|
|
msgType: 'msgType_0',
|
|
|
|
sceneId: 'sceneId_0',
|
|
|
|
userId: 'userId_0',
|
|
|
|
url: 'url_0',
|
|
|
|
messageSendStatus: 'messageSendStatus_0',
|
|
|
|
createdAt: 'createdAt_0',
|
|
|
|
createdBy: 'createdBy_0',
|
|
|
|
updatedAt: 'updatedAt_0',
|
|
|
|
updatedBy: 'updatedBy_0',
|
|
|
|
deletedFlag: 'deletedFlag_0',
|
|
|
|
deviceId: 'deviceId_0',
|
|
|
|
roomId: 'roomId_0',
|
|
|
|
msgRead: 'msgRead_0',
|
|
|
|
funId: 'funId_0',
|
|
|
|
funParentId: 'funParentId_0',
|
|
|
|
funWarnLevel: 'funWarnLevel_0',
|
|
|
|
familyId: 'familyId_0',
|
|
|
|
statisticsDuration: 'statisticsDuration_0',
|
|
|
|
msgSourceId: 'msgSourceId_0',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_1',
|
|
|
|
msgNote: 'msgNote_1',
|
|
|
|
msgType: 'msgType_1',
|
|
|
|
sceneId: 'sceneId_1',
|
|
|
|
userId: 'userId_1',
|
|
|
|
url: 'url_1',
|
|
|
|
messageSendStatus: 'messageSendStatus_1',
|
|
|
|
createdAt: 'createdAt_1',
|
|
|
|
createdBy: 'createdBy_1',
|
|
|
|
updatedAt: 'updatedAt_1',
|
|
|
|
updatedBy: 'updatedBy_1',
|
|
|
|
deletedFlag: 'deletedFlag_1',
|
|
|
|
deviceId: 'deviceId_1',
|
|
|
|
roomId: 'roomId_1',
|
|
|
|
msgRead: 'msgRead_1',
|
|
|
|
funId: 'funId_1',
|
|
|
|
funParentId: 'funParentId_1',
|
|
|
|
funWarnLevel: 'funWarnLevel_1',
|
|
|
|
familyId: 'familyId_1',
|
|
|
|
statisticsDuration: 'statisticsDuration_1',
|
|
|
|
msgSourceId: 'msgSourceId_1',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_2',
|
|
|
|
msgNote: 'msgNote_2',
|
|
|
|
msgType: 'msgType_2',
|
|
|
|
sceneId: 'sceneId_2',
|
|
|
|
userId: 'userId_2',
|
|
|
|
url: 'url_2',
|
|
|
|
messageSendStatus: 'messageSendStatus_2',
|
|
|
|
createdAt: 'createdAt_2',
|
|
|
|
createdBy: 'createdBy_2',
|
|
|
|
updatedAt: 'updatedAt_2',
|
|
|
|
updatedBy: 'updatedBy_2',
|
|
|
|
deletedFlag: 'deletedFlag_2',
|
|
|
|
deviceId: 'deviceId_2',
|
|
|
|
roomId: 'roomId_2',
|
|
|
|
msgRead: 'msgRead_2',
|
|
|
|
funId: 'funId_2',
|
|
|
|
funParentId: 'funParentId_2',
|
|
|
|
funWarnLevel: 'funWarnLevel_2',
|
|
|
|
familyId: 'familyId_2',
|
|
|
|
statisticsDuration: 'statisticsDuration_2',
|
|
|
|
msgSourceId: 'msgSourceId_2',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_3',
|
|
|
|
msgNote: 'msgNote_3',
|
|
|
|
msgType: 'msgType_3',
|
|
|
|
sceneId: 'sceneId_3',
|
|
|
|
userId: 'userId_3',
|
|
|
|
url: 'url_3',
|
|
|
|
messageSendStatus: 'messageSendStatus_3',
|
|
|
|
createdAt: 'createdAt_3',
|
|
|
|
createdBy: 'createdBy_3',
|
|
|
|
updatedAt: 'updatedAt_3',
|
|
|
|
updatedBy: 'updatedBy_3',
|
|
|
|
deletedFlag: 'deletedFlag_3',
|
|
|
|
deviceId: 'deviceId_3',
|
|
|
|
roomId: 'roomId_3',
|
|
|
|
msgRead: 'msgRead_3',
|
|
|
|
funId: 'funId_3',
|
|
|
|
funParentId: 'funParentId_3',
|
|
|
|
funWarnLevel: 'funWarnLevel_3',
|
|
|
|
familyId: 'familyId_3',
|
|
|
|
statisticsDuration: 'statisticsDuration_3',
|
|
|
|
msgSourceId: 'msgSourceId_3',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_4',
|
|
|
|
msgNote: 'msgNote_4',
|
|
|
|
msgType: 'msgType_4',
|
|
|
|
sceneId: 'sceneId_4',
|
|
|
|
userId: 'userId_4',
|
|
|
|
url: 'url_4',
|
|
|
|
messageSendStatus: 'messageSendStatus_4',
|
|
|
|
createdAt: 'createdAt_4',
|
|
|
|
createdBy: 'createdBy_4',
|
|
|
|
updatedAt: 'updatedAt_4',
|
|
|
|
updatedBy: 'updatedBy_4',
|
|
|
|
deletedFlag: 'deletedFlag_4',
|
|
|
|
deviceId: 'deviceId_4',
|
|
|
|
roomId: 'roomId_4',
|
|
|
|
msgRead: 'msgRead_4',
|
|
|
|
funId: 'funId_4',
|
|
|
|
funParentId: 'funParentId_4',
|
|
|
|
funWarnLevel: 'funWarnLevel_4',
|
|
|
|
familyId: 'familyId_4',
|
|
|
|
statisticsDuration: 'statisticsDuration_4',
|
|
|
|
msgSourceId: 'msgSourceId_4',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_5',
|
|
|
|
msgNote: 'msgNote_5',
|
|
|
|
msgType: 'msgType_5',
|
|
|
|
sceneId: 'sceneId_5',
|
|
|
|
userId: 'userId_5',
|
|
|
|
url: 'url_5',
|
|
|
|
messageSendStatus: 'messageSendStatus_5',
|
|
|
|
createdAt: 'createdAt_5',
|
|
|
|
createdBy: 'createdBy_5',
|
|
|
|
updatedAt: 'updatedAt_5',
|
|
|
|
updatedBy: 'updatedBy_5',
|
|
|
|
deletedFlag: 'deletedFlag_5',
|
|
|
|
deviceId: 'deviceId_5',
|
|
|
|
roomId: 'roomId_5',
|
|
|
|
msgRead: 'msgRead_5',
|
|
|
|
funId: 'funId_5',
|
|
|
|
funParentId: 'funParentId_5',
|
|
|
|
funWarnLevel: 'funWarnLevel_5',
|
|
|
|
familyId: 'familyId_5',
|
|
|
|
statisticsDuration: 'statisticsDuration_5',
|
|
|
|
msgSourceId: 'msgSourceId_5',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_6',
|
|
|
|
msgNote: 'msgNote_6',
|
|
|
|
msgType: 'msgType_6',
|
|
|
|
sceneId: 'sceneId_6',
|
|
|
|
userId: 'userId_6',
|
|
|
|
url: 'url_6',
|
|
|
|
messageSendStatus: 'messageSendStatus_6',
|
|
|
|
createdAt: 'createdAt_6',
|
|
|
|
createdBy: 'createdBy_6',
|
|
|
|
updatedAt: 'updatedAt_6',
|
|
|
|
updatedBy: 'updatedBy_6',
|
|
|
|
deletedFlag: 'deletedFlag_6',
|
|
|
|
deviceId: 'deviceId_6',
|
|
|
|
roomId: 'roomId_6',
|
|
|
|
msgRead: 'msgRead_6',
|
|
|
|
funId: 'funId_6',
|
|
|
|
funParentId: 'funParentId_6',
|
|
|
|
funWarnLevel: 'funWarnLevel_6',
|
|
|
|
familyId: 'familyId_6',
|
|
|
|
statisticsDuration: 'statisticsDuration_6',
|
|
|
|
msgSourceId: 'msgSourceId_6',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_7',
|
|
|
|
msgNote: 'msgNote_7',
|
|
|
|
msgType: 'msgType_7',
|
|
|
|
sceneId: 'sceneId_7',
|
|
|
|
userId: 'userId_7',
|
|
|
|
url: 'url_7',
|
|
|
|
messageSendStatus: 'messageSendStatus_7',
|
|
|
|
createdAt: 'createdAt_7',
|
|
|
|
createdBy: 'createdBy_7',
|
|
|
|
updatedAt: 'updatedAt_7',
|
|
|
|
updatedBy: 'updatedBy_7',
|
|
|
|
deletedFlag: 'deletedFlag_7',
|
|
|
|
deviceId: 'deviceId_7',
|
|
|
|
roomId: 'roomId_7',
|
|
|
|
msgRead: 'msgRead_7',
|
|
|
|
funId: 'funId_7',
|
|
|
|
funParentId: 'funParentId_7',
|
|
|
|
funWarnLevel: 'funWarnLevel_7',
|
|
|
|
familyId: 'familyId_7',
|
|
|
|
statisticsDuration: 'statisticsDuration_7',
|
|
|
|
msgSourceId: 'msgSourceId_7',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_8',
|
|
|
|
msgNote: 'msgNote_8',
|
|
|
|
msgType: 'msgType_8',
|
|
|
|
sceneId: 'sceneId_8',
|
|
|
|
userId: 'userId_8',
|
|
|
|
url: 'url_8',
|
|
|
|
messageSendStatus: 'messageSendStatus_8',
|
|
|
|
createdAt: 'createdAt_8',
|
|
|
|
createdBy: 'createdBy_8',
|
|
|
|
updatedAt: 'updatedAt_8',
|
|
|
|
updatedBy: 'updatedBy_8',
|
|
|
|
deletedFlag: 'deletedFlag_8',
|
|
|
|
deviceId: 'deviceId_8',
|
|
|
|
roomId: 'roomId_8',
|
|
|
|
msgRead: 'msgRead_8',
|
|
|
|
funId: 'funId_8',
|
|
|
|
funParentId: 'funParentId_8',
|
|
|
|
funWarnLevel: 'funWarnLevel_8',
|
|
|
|
familyId: 'familyId_8',
|
|
|
|
statisticsDuration: 'statisticsDuration_8',
|
|
|
|
msgSourceId: 'msgSourceId_8',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
id: 'id_9',
|
|
|
|
msgNote: 'msgNote_9',
|
|
|
|
msgType: 'msgType_9',
|
|
|
|
sceneId: 'sceneId_9',
|
|
|
|
userId: 'userId_9',
|
|
|
|
url: 'url_9',
|
|
|
|
messageSendStatus: 'messageSendStatus_9',
|
|
|
|
createdAt: 'createdAt_9',
|
|
|
|
createdBy: 'createdBy_9',
|
|
|
|
updatedAt: 'updatedAt_9',
|
|
|
|
updatedBy: 'updatedBy_9',
|
|
|
|
deletedFlag: 'deletedFlag_9',
|
|
|
|
deviceId: 'deviceId_9',
|
|
|
|
roomId: 'roomId_9',
|
|
|
|
msgRead: 'msgRead_9',
|
|
|
|
funId: 'funId_9',
|
|
|
|
funParentId: 'funParentId_9',
|
|
|
|
funWarnLevel: 'funWarnLevel_9',
|
|
|
|
familyId: 'familyId_9',
|
|
|
|
statisticsDuration: 'statisticsDuration_9',
|
|
|
|
msgSourceId: 'msgSourceId_9',
|
|
|
|
},
|
|
|
|
|
|
];
|
|
|
|
export default [
|
|
|
|
{
|
|
url: '/api/health_msg/page',
|
|
method: 'get',
|
|
response: () => {
|
|
return {
|
|
code: 0,
|
|
data: {
|
|
records: list,
|
|
total: list.length,
|
|
},
|
|
};
|
|
},
|
|
},
|
|
|
|
{
|
|
url: '/api/health_msg',
|
|
method: 'post',
|
|
response: () => {
|
|
return {
|
|
code: 0,
|
|
message: 'success',
|
|
};
|
|
},
|
|
},
|
|
|
|
{
|
|
url: '/api/health_msg/:id',
|
|
method: 'delete',
|
|
response: () => {
|
|
return {
|
|
code: 0,
|
|
message: 'deleted',
|
|
};
|
|
},
|
|
},
|
|
|
|
] as MockMethod[];
|