{ "type" : "page", "title" : "销项税发票", "body" : { "type" : "crud", "api" : "/api/flow/PM_OUTPUTTAXINVOICE_SEARCH", "syncLocation" : false, "selectable" : true, "checkOnItemClick" : true, "filter" : { "title" : "查询", "body" : [ { "name" : "ORGID", "label" : "(分)公司", "type" : "picker", "clearable" : true, "source" : "/api/picker/1a998b23-371d-4ebb-911f-6465a56a6809/list", "labelField" : "_label", "valueField" : "_id", "modalMode" : "dialog", "modalSize" : "lg", "pickerSchema" : { "mode" : "table", "headerToolbar" : [ { "type" : "search-box", "name" : "q", "placeholder" : "输入关键字搜索" } ], "footerToolbar" : [ "pagination" ] } }, { "name" : "PROJECTID", "label" : "工程名称", "type" : "picker", "clearable" : true, "source" : "/api/picker/66e57e6d-0cbb-40cf-8b84-c512345734b7/list", "labelField" : "_label", "valueField" : "_id", "modalMode" : "dialog", "modalSize" : "lg", "pickerSchema" : { "mode" : "table", "headerToolbar" : [ { "type" : "search-box", "name" : "q", "placeholder" : "输入关键字搜索" } ], "footerToolbar" : [ "pagination" ] }, "value" : "${currentProject}" }, { "name" : "BUILDCOMPANY", "label" : "建设单位", "type" : "picker", "clearable" : true, "source" : "/api/picker/1964fda1-b020-4a8b-95e2-dc32de36e74a/list", "labelField" : "_label", "valueField" : "_id", "modalMode" : "dialog", "modalSize" : "lg", "pickerSchema" : { "mode" : "table", "headerToolbar" : [ { "type" : "search-box", "name" : "q", "placeholder" : "输入关键字搜索" } ], "footerToolbar" : [ "pagination" ] } }, { "name" : "INVOICETYPE", "label" : "开票类型", "type" : "select", "clearable" : true, "source" : "/api/poc/dict/INVOICE_INVOICETYPE" }, { "name" : "INVOICENO", "label" : "票号", "type" : "input-text" }, { "name" : "INVOICEDATE", "label" : "开票日期", "type" : "input-date-range" }, { "name" : "INVOICEFORM", "label" : "征税方式", "type" : "select", "clearable" : true, "source" : "/api/poc/dict/INVOICE_INVOICEFORM" }, { "name" : "RECEIPTTYPE", "label" : "发票类型", "type" : "select", "clearable" : true, "source" : "/api/poc/dict/INVOICEMANAGEMENT_INVOICETYPE" }, { "name" : "STATUS", "label" : "审批状态", "type" : "select", "clearable" : true, "source" : "/api/poc/dict/WFSTATUS" } ] }, "columns" : [ { "name" : "PM_OUTPUTTAXINVOICE_ID", "label" : "主键", "width" : 200, "toggled" : false }, { "name" : "ORGID_DISPLAY__", "label" : "(分)公司", "width" : 200 }, { "name" : "PROJECTID_DISPLAY__", "label" : "工程名称", "width" : 350 }, { "name" : "BUILDCOMPANY_DISPLAY__", "label" : "建设单位", "width" : 200 }, { "name" : "INVOICETYPE", "label" : "开票类型", "width" : 100, "type" : "mapping", "map" : { "1" : "总包", "2" : "分包", "3" : "材料", "4" : "设备租赁与采购", "5" : "不动产", "6" : "农产品", "8" : "服务", "9" : "办公用品", "10" : "公司内部报销" } }, { "name" : "INVOICENO", "label" : "票号", "width" : 100 }, { "name" : "INVOICEMONEY", "label" : "不含税金额(元)", "width" : 130 }, { "name" : "SUBMONEY", "label" : "分包抵扣金额(元)", "width" : 150 }, { "name" : "TAXRATE", "label" : "税率(%)", "width" : 80 }, { "name" : "TAX", "label" : "税额(元)", "width" : 110 }, { "name" : "TOTALMONEY", "label" : "价税合计(元)", "width" : 130 }, { "name" : "INVOICEDATE", "label" : "开票日期", "width" : 100, "type" : "date", "format" : "YYYY-MM-DD", "inputFormat" : "YYYY-MM-DDTHH:mm:ss.SSSZ" }, { "name" : "INVOICEFORM", "label" : "征税方式", "width" : 80, "type" : "mapping", "map" : { "2" : "一般", "1" : "简易" } }, { "name" : "RECEIPTTYPE", "label" : "发票类型", "width" : 100, "type" : "mapping", "map" : { "1" : "营业税发票", "2" : "增值税普通发票", "3" : "增值税专项发票" } }, { "name" : "STATUS", "label" : "审批状态", "width" : 80, "type" : "mapping", "map" : { "1" : "未提交", "2" : "处理中", "3" : "通过", "4" : "未通过", "5" : "重新提交", "6" : "作废" } } ], "headerToolbar" : [ { "type" : "button", "id" : "添加", "label" : "添加", "level" : "primary", "actionType" : "dialog", "dialog" : { "type" : "dialog", "title" : "添加", "size" : "lg", "body" : { "type" : "service", "schemaApi" : "get:/api/page/schema/de7cbcfb-7182-4880-b727-c2a14d5e9451?format=amis", "api" : { "method" : "get", "url" : "/api/form/PM_OUTPUTTAXINVOICE/defaults?templateId=de7cbcfb-7182-4880-b727-c2a14d5e9451" } }, "actions" : [ { "type" : "button", "label" : "保存", "level" : "primary", "actionType" : "submit", "api" : "POST:/api/flow/PM_OUTPUTTAXINVOICE_ADD?__egtpl=de7cbcfb-7182-4880-b727-c2a14d5e9451", "close" : true }, { "type" : "button", "label" : "保存并提交审批", "level" : "primary", "actionType" : "submit", "api" : "POST:/api/flow/PM_OUTPUTTAXINVOICE_SAVE_AND_SUBMIT?__egtpl=de7cbcfb-7182-4880-b727-c2a14d5e9451", "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]}" }, "body" : { "type" : "service", "schemaApi" : "get:/api/page/schema/de7cbcfb-7182-4880-b727-c2a14d5e9451?format=amis", "api" : { "method" : "post", "url" : "/api/flow/PM_OUTPUTTAXINVOICE_LOAD?__egtpl=de7cbcfb-7182-4880-b727-c2a14d5e9451", "data" : { "PM_OUTPUTTAXINVOICE_ID" : "${PM_OUTPUTTAXINVOICE_ID}" }, "responseData" : { "&" : "${result}" } }, "onEvent" : { "inited" : { "actions" : [ { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 3, "item" : "${&}", "templateId" : "86c05eb5-753d-46e5-b958-cdbcefe7eabc" } }, "outputVar" : "scriptResult3" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult3.commands}" } } ] } } }, "actions" : [ { "type" : "button", "label" : "保存", "level" : "primary", "actionType" : "submit", "api" : "POST:/api/flow/PM_OUTPUTTAXINVOICE_UPDATE?__egtpl=de7cbcfb-7182-4880-b727-c2a14d5e9451", "close" : true }, { "type" : "button", "label" : "保存并提交审批", "level" : "primary", "actionType" : "submit", "api" : "POST:/api/flow/PM_OUTPUTTAXINVOICE_SAVE_AND_SUBMIT?__egtpl=de7cbcfb-7182-4880-b727-c2a14d5e9451", "close" : true }, { "type" : "button", "label" : "取消", "actionType" : "close" } ] } }, { "type" : "button", "id" : "删除", "label" : "删除", "level" : "danger", "actionType" : "ajax", "disabledOn" : "${!selectedItems || selectedItems.length === 0}", "confirmText" : "确认要删除此记录吗?", "api" : { "method" : "post", "url" : "/api/flow/PM_OUTPUTTAXINVOICE_DELETE", "data" : { "ids" : "${selectedItems|pick:PM_OUTPUTTAXINVOICE_ID|join:','}" } } }, { "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/de7cbcfb-7182-4880-b727-c2a14d5e9451?format=amis", "static" : true, "api" : { "method" : "post", "url" : "/api/flow/PM_OUTPUTTAXINVOICE_LOAD?__egtpl=de7cbcfb-7182-4880-b727-c2a14d5e9451", "data" : { "PM_OUTPUTTAXINVOICE_ID" : "${PM_OUTPUTTAXINVOICE_ID}" }, "responseData" : { "&" : "${result}" } } } } }, { "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/35151b53-4984-4d9c-95f0-95bf0cad8447?format=amis", "api" : { "method" : "post", "url" : "/api/flow/PM_OUTPUTTAXINVOICE_LOADREVOKE?__egtpl=35151b53-4984-4d9c-95f0-95bf0cad8447", "data" : { "PM_OUTPUTTAXINVOICE_ID" : "${PM_OUTPUTTAXINVOICE_ID}" }, "responseData" : { "&" : "${result}" } } }, "actions" : [ { "type" : "button", "label" : "保存", "level" : "primary", "actionType" : "submit", "api" : "POST:/api/flow/PM_OUTPUTTAXINVOICE_REVOKE?__egtpl=35151b53-4984-4d9c-95f0-95bf0cad8447", "close" : true }, { "type" : "button", "label" : "取消", "actionType" : "close" } ] } }, { "type" : "button", "id" : "提交审批", "label" : "提交审批", "actionType" : "ajax", "disabled" : true, "api" : { "method" : "post", "url" : "/api/flow/PM_OUTPUTTAXINVOICE_SUBMIT", "data" : { "PM_OUTPUTTAXINVOICE_ID" : "${selectedItems[0].PM_OUTPUTTAXINVOICE_ID}" } } }, { "type" : "button", "id" : "批量发票识别", "label" : "批量发票识别", "level" : "primary", "actionType" : "dialog", "dialog" : { "type" : "dialog", "title" : "批量发票识别", "size" : "lg", "body" : { "type" : "service", "schemaApi" : "get:/api/page/schema/605b3a01-53e0-4b65-b588-f6930fe772ee?format=amis", "api" : { "method" : "get", "url" : "/api/form/PM_OUTPUTTAXINVOICE/defaults?templateId=605b3a01-53e0-4b65-b588-f6930fe772ee" } }, "actions" : [ { "type" : "button", "label" : "保存", "level" : "primary", "actionType" : "submit", "api" : "POST:/api/flow/PM_INOUTPUTTAXINVOICE_ADDPL?__egtpl=605b3a01-53e0-4b65-b588-f6930fe772ee", "close" : true }, { "type" : "button", "label" : "取消", "actionType" : "close" } ] } }, { "type" : "button", "id" : "查看审批", "label" : "查看审批", "icon" : "fa fa-search", "disabledOn" : "${!selectedItems || selectedItems.length === 0}", "onEvent" : { "click" : { "actions" : [ { "actionType" : "openApprovalDrawer", "args" : { "taskName" : "审批详情", "processInstanceId" : "${selectedItems[0].processInstanceId || selectedItems[0].PROCESSINSTANCEID || ''}", "businessKey" : "${selectedItems[0].PM_OUTPUTTAXINVOICE_ID}", "businessTable" : "PM_OUTPUTTAXINVOICE", "readOnly" : true, "mode" : "read" } } ] } } }, "pagination" ], "primaryField" : "PM_OUTPUTTAXINVOICE_ID", "onEvent" : { "selectedChange" : { "actions" : [ { "actionType" : "disabled", "componentId" : "提交审批" }, { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 1, "item" : "${event.data.selectedItems[0]}", "templateId" : "86c05eb5-753d-46e5-b958-cdbcefe7eabc" } }, "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" : "86c05eb5-753d-46e5-b958-cdbcefe7eabc" } }, "outputVar" : "scriptResult2" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult2.commands}" } }, { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 3, "item" : "${&}", "templateId" : "86c05eb5-753d-46e5-b958-cdbcefe7eabc" } }, "outputVar" : "scriptResult3" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult3.commands}" } }, { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 6, "item" : "${&}", "templateId" : "86c05eb5-753d-46e5-b958-cdbcefe7eabc" } }, "outputVar" : "scriptResult6" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult6.commands}" } } ] } } } }