{ "type" : "page", "title" : "查询档案列表", "body" : { "type" : "crud", "api" : "/api/flow/DM_ARCHIVE_SEARCH", "syncLocation" : false, "selectable" : true, "checkOnItemClick" : true, "filter" : { "title" : "查询", "body" : [ { "name" : "NO", "label" : "编号", "type" : "input-text" }, { "name" : "NAME", "label" : "文件题名", "type" : "input-text" }, { "name" : "PERSONLIABLE", "label" : "责任人", "type" : "input-text" }, { "name" : "PAGENUM", "label" : "页次", "type" : "input-text" }, { "name" : "FILEDATE", "label" : "日期", "type" : "input-text" }, { "name" : "FILETYPE", "label" : "存储方式", "type" : "select", "clearable" : true, "source" : "/api/poc/dict/DM_FILE_TYPE" }, { "name" : "BORROWSTATUS", "label" : "状态", "type" : "select", "clearable" : true, "source" : "/api/poc/dict/DM_ARCHIVE_BORROWSTATUS" } ] }, "columns" : [ { "name" : "DM_ARCHIVE_ID", "label" : "主键", "width" : 200, "toggled" : false }, { "name" : "NO", "label" : "编号", "width" : 200 }, { "name" : "NAME", "label" : "文件题名", "width" : 200 }, { "name" : "PERSONLIABLE", "label" : "责任人", "width" : 200 }, { "name" : "PAGENUM", "label" : "页次", "width" : 200 }, { "name" : "FILEDATE", "label" : "日期", "width" : 200 }, { "name" : "FILETYPE", "label" : "存储方式", "width" : 200, "type" : "mapping", "map" : { "1" : "纸质存储", "2" : "电子存储" } }, { "name" : "BORROWSTATUS", "label" : "状态", "width" : 200, "type" : "mapping", "map" : { "0" : "在库", "2" : "已借出" } } ], "headerToolbar" : [ { "type" : "button", "id" : "借阅", "label" : "借阅", "actionType" : "dialog", "disabledOn" : "${!selectedItems || selectedItems.length === 0}", "dialog" : { "type" : "dialog", "title" : "借阅", "size" : "lg", "data" : { "&" : "${selectedItems[0]}" }, "body" : { "type" : "service", "schemaApi" : "get:/api/page/schema/d5192a02-b56a-4c48-b13b-c20afd5bcfd3?format=amis", "api" : { "method" : "post", "url" : "/api/flow/DM_ARCHIVE_LOADNOCREATEBY?__egtpl=d5192a02-b56a-4c48-b13b-c20afd5bcfd3", "data" : { "DM_ARCHIVE_ID" : "${DM_ARCHIVE_ID}" }, "responseData" : { "&" : "${result}" } }, "onEvent" : { "inited" : { "actions" : [ { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 2, "item" : "${&}", "templateId" : "30faea2c-95f0-4685-b3e8-358e6b73ab41" } }, "outputVar" : "scriptResult2" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult2.commands}" } } ] } } }, "actions" : [ { "type" : "button", "label" : "保存并提交审批", "level" : "primary", "actionType" : "submit", "api" : "POST:/api/flow/DM_ARCHIVESBORROW_SAVE_AND_SUBMIT?__egtpl=d5192a02-b56a-4c48-b13b-c20afd5bcfd3", "close" : true }, { "type" : "button", "label" : "取消", "actionType" : "close" } ] } }, { "type" : "button", "id" : "查看", "label" : "查看", "actionType" : "dialog", "disabledOn" : "${!selectedItems || selectedItems.length === 0}", "dialog" : { "type" : "dialog", "title" : "查看", "size" : "lg", "data" : { "&" : "${selectedItems[0]}", "__readonly" : true }, "body" : { "type" : "service", "schemaApi" : "get:/api/page/schema/f2ae4bf9-8de4-42ef-b9bd-26b524bdcfb8?format=amis", "static" : true, "api" : { "method" : "post", "url" : "/api/flow/DM_ARCHIVE_LOAD?__egtpl=f2ae4bf9-8de4-42ef-b9bd-26b524bdcfb8", "data" : { "DM_ARCHIVE_ID" : "${DM_ARCHIVE_ID}" }, "responseData" : { "&" : "${result}" } } } } }, { "type" : "button", "id" : "我的借阅", "label" : "我的借阅", "actionType" : "dialog", "dialog" : { "type" : "dialog", "title" : "我的借阅", "size" : "lg", "body" : { "type" : "service", "schemaApi" : "get:/api/page/schema/355de155-7253-44dd-8036-16ee132525a1?format=amis" }, "actions" : [ { "type" : "button", "label" : "关闭", "actionType" : "close" } ] } }, "pagination" ], "primaryField" : "DM_ARCHIVE_ID", "onEvent" : { "selectedChange" : { "actions" : [ { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 1, "item" : "${event.data.selectedItems[0]}", "templateId" : "30faea2c-95f0-4685-b3e8-358e6b73ab41" } }, "outputVar" : "scriptResult1" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult1.commands}" } } ] }, "inited" : { "actions" : [ { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 2, "item" : "${&}", "templateId" : "30faea2c-95f0-4685-b3e8-358e6b73ab41" } }, "outputVar" : "scriptResult2" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult2.commands}" } } ] } } } }