提交 b5613129 编写于 作者: tony001's avatar tony001

zpc --- 完善实体工作流动态导航表格视图mock数据

上级 c95ea42e
......@@ -83,6 +83,48 @@ const mockDatas: Array<any> = [
</#if>
];
//getwflink
mock.onGet(new RegExp(/^\/wfcore\/${app.getPSSystem().getCodeName()?lower_case}-app-${app.getCodeName()?lower_case}\/${srfpluralize(item.codeName)?lower_case}\/[a-zA-Z0-9\-\;]+\/usertasks\/[a-zA-Z0-9\-\;]+\/ways$/)).reply((config: any) => {
console.groupCollapsed("实体:${item.codeName?lower_case} 方法: getwflink");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, {}];
}
return [status,[
{"sequenceFlowId":"dfdsfdsfdsfdsfds","sequenceFlowName":"同意",
"taskId":"aaaaddddccccddddd","processDefinitionKey":"support-workorders-approve-v1",
"processInstanceId":"ddlfldldfldsfds","refViewKey":""},
{"sequenceFlowId":"ddssdfdfdfdfsfdf","sequenceFlowName":"不同意",
"taskId":"aaaaddddccccddddd","processDefinitionKey":"support-workorders-approve-v1",
"processInstanceId":"ddfdsldlfdlldsf","refViewKey":"workorder_ltform_editview"}
]];
});
// getwfstep
mock.onGet(new RegExp(/^\/wfcore\/${app.getPSSystem().getCodeName()?lower_case}-app-${app.getCodeName()?lower_case}\/${srfpluralize(item.codeName)?lower_case}\/process-definitions-nodes$/)).reply((config: any) => {
console.groupCollapsed("实体:${item.codeName?lower_case} 方法: getwfstep");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, {}];
}
return [status, [
{"userTaskId":"sddfddfd-dfdf-fdfd-fdf-dfdfd",
"userTaskName":"待审",
"cnt":0,
"processDefinitionKey":"support-workorders-approve-v1",
"processDefinitionName":"工单审批流程v1"
},
{"userTaskId":"sddfddfd-dfdf-fdfd-fdf-87927",
"userTaskName":"待分配",
"cnt":3,
"processDefinitionKey":"support-workorders-approve-v1",
"processDefinitionName":"工单审批流程v1"}
]];
});
// createBatch
mock.onPost(new RegExp(/^\/${srfpluralize(item.codeName)?lower_case}\/batch$/)).reply((config: any) => {
console.groupCollapsed("实体:${item.codeName?lower_case} 方法: createBatch");
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册