lyflowchart 1.0.115 → 1.0.130
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ActionsConfig-BuvSvRbv.js +395 -0
- package/dist/ActionsConfig-BuvSvRbv.js.map +1 -0
- package/dist/ApprovalEditorModal-DZfXupU3.js +48 -0
- package/dist/ApprovalEditorModal-DZfXupU3.js.map +1 -0
- package/dist/CancelModal-BUi3ieI8.js +61 -0
- package/dist/CancelModal-BUi3ieI8.js.map +1 -0
- package/dist/Cell_click_approve-CBh0j--6.js +244 -0
- package/dist/Cell_click_approve-CBh0j--6.js.map +1 -0
- package/dist/JsonTags-BbWLqghI.js +66 -0
- package/dist/JsonTags-BbWLqghI.js.map +1 -0
- package/dist/MyProcess-FWGEwQcv.js +26434 -0
- package/dist/MyProcess-FWGEwQcv.js.map +1 -0
- package/dist/MyProcess.vue.d.ts +991 -0
- package/dist/approval-BW2WjPxY.js +167 -0
- package/dist/approval-BW2WjPxY.js.map +1 -0
- package/dist/approval-CuUNtG9u.js +18 -0
- package/dist/approval-CuUNtG9u.js.map +1 -0
- package/dist/approvalHistory-B2gpQbFC.js +868 -0
- package/dist/approvalHistory-B2gpQbFC.js.map +1 -0
- package/dist/approvalHistoryViewModal-DgLpv2ot.js +114 -0
- package/dist/approvalHistoryViewModal-DgLpv2ot.js.map +1 -0
- package/dist/approvalPageConfig-D0zPXOUf.js +2437 -0
- package/dist/approvalPageConfig-D0zPXOUf.js.map +1 -0
- package/dist/approveLeftConfig-BOU_UgHp.js +136 -0
- package/dist/approveLeftConfig-BOU_UgHp.js.map +1 -0
- package/dist/codeHistoryViewModal-BfSjIbEU.js +103 -0
- package/dist/codeHistoryViewModal-BfSjIbEU.js.map +1 -0
- package/dist/columnTables-DLwtgcC7.js +1272 -0
- package/dist/columnTables-DLwtgcC7.js.map +1 -0
- package/dist/components/Cell_click_approve.vue.d.ts +5 -0
- package/dist/components/Cell_click_data_source.vue.d.ts +6 -0
- package/dist/components/Process/common/bpmnUtils.d.ts +8 -0
- package/dist/components/Process/common/global.d.ts +16 -0
- package/dist/components/Process/common/index.d.ts +5 -0
- package/dist/components/Process/component/JsonTags2.vue.d.ts +60 -0
- package/dist/components/Process/component/ValueInput2.vue.d.ts +74 -0
- package/dist/components/Process/component/columnNameField2.vue.d.ts +51 -0
- package/dist/components/Process/component/data.d.ts +157 -0
- package/dist/components/Process/customPanel/CustomContextPad.d.ts +31 -0
- package/dist/components/Process/customPanel/CustomPalette.d.ts +89 -0
- package/dist/components/Process/customPanel/customTranslate.d.ts +1 -0
- package/dist/components/Process/customPanel/index.d.ts +8 -0
- package/dist/components/Process/designer.vue.d.ts +589 -0
- package/dist/components/Process/flowable/init.d.ts +1 -0
- package/dist/components/Process/index.vue.d.ts +812 -0
- package/dist/components/Process/lang/zh.d.ts +249 -0
- package/dist/components/Process/panel/ButtonsPanel.vue.d.ts +24 -0
- package/dist/components/Process/panel/PropertiesPanel.vue.d.ts +24 -0
- package/dist/components/Process/panel/commonPanel.vue.d.ts +40 -0
- package/dist/components/Process/panel/conditionPanel.vue.d.ts +271 -0
- package/dist/components/Process/panel/executionListener.vue.d.ts +66 -0
- package/dist/components/Process/panel/formPanel.vue.d.ts +7 -0
- package/dist/components/Process/panel/multiInstance.vue.d.ts +33 -0
- package/dist/components/Process/panel/otherPanel.vue.d.ts +17 -0
- package/dist/components/Process/panel/taskListener.vue.d.ts +64 -0
- package/dist/components/Process/panel/taskPanel.vue.d.ts +254 -0
- package/dist/components/Process/viewer/index.vue.d.ts +41 -0
- package/dist/components/approval/ApprovalEditorModal.vue.d.ts +26 -0
- package/dist/components/approval/CostCompanySelect.vue.d.ts +29 -0
- package/dist/components/approval/CostDepartmentSelect.vue.d.ts +35 -0
- package/dist/components/approval/CreateByCascader.vue.d.ts +27 -0
- package/dist/components/approval/CreateBySelect.vue.d.ts +35 -0
- package/dist/components/approval/PostionCascader.vue.d.ts +26 -0
- package/dist/components/approval/SystemTime.vue.d.ts +38 -0
- package/dist/components/approval/approvalViewId.d.ts +36 -0
- package/dist/components/approval/components/CancelModal.vue.d.ts +25 -0
- package/dist/components/approval/components/FormCodeInput.vue.d.ts +33 -0
- package/dist/components/approval/components/FormContextInput.vue.d.ts +33 -0
- package/dist/components/approval/components/FormFlowOrgInput.vue.d.ts +40 -0
- package/dist/components/approval/components/actionsBar.vue.d.ts +17 -0
- package/dist/components/approval/components/approvalHistory/approvalHistoryViewModal.vue.d.ts +41 -0
- package/dist/components/approval/components/approvalHistory/dataStoreSettingHistory.vue.d.ts +55 -0
- package/dist/components/approval/components/approvalHistory/dataStoreSettingHistoryViewModal.vue.d.ts +41 -0
- package/dist/components/approval/components/approvalHistory/flowHistoryViewModal.vue.d.ts +41 -0
- package/dist/components/approval/components/approvalHistory/flowSettingHistory.vue.d.ts +55 -0
- package/dist/components/approval/components/approvalHistory/index.vue.d.ts +212 -0
- package/dist/components/approval/components/approvalHistory/pageSettingHistory.vue.d.ts +55 -0
- package/dist/components/approval/components/approvalPageConfig/ActionsConfig.vue.d.ts +112 -0
- package/dist/components/approval/components/approvalPageConfig/BaseConditions.vue.d.ts +205 -0
- package/dist/components/approval/components/approvalPageConfig/CodeEditorWraper.vue.d.ts +51 -0
- package/dist/components/approval/components/approvalPageConfig/ColumnConfig.vue.d.ts +145 -0
- package/dist/components/approval/components/approvalPageConfig/ConditionFieldMulType.vue.d.ts +137 -0
- package/dist/components/approval/components/approvalPageConfig/JsonInput.vue.d.ts +38 -0
- package/dist/components/approval/components/approvalPageConfig/JsonTags.vue.d.ts +26 -0
- package/dist/components/approval/components/approvalPageConfig/JsonText.vue.d.ts +36 -0
- package/dist/components/approval/components/approvalPageConfig/approveLeftConfig.vue.d.ts +6 -0
- package/dist/components/approval/components/approvalPageConfig/baseConfig.vue.d.ts +10 -0
- package/dist/components/approval/components/approvalPageConfig/cellEdit.vue.d.ts +23 -0
- package/dist/components/approval/components/approvalPageConfig/configSync.vue.d.ts +76 -0
- package/dist/components/approval/components/approvalPageConfig/confirmInput.vue.d.ts +26 -0
- package/dist/components/approval/components/approvalPageConfig/defaultOperatorSelect.vue.d.ts +18 -0
- package/dist/components/approval/components/approvalPageConfig/index.vue.d.ts +11 -0
- package/dist/components/approval/components/approvalPageConfig/jsonConfig.vue.d.ts +16 -0
- package/dist/components/approval/components/approvalPageConfig/layoutSetting.vue.d.ts +9 -0
- package/dist/components/approval/components/approvalPageConfig/leftColumn.vue.d.ts +1184 -0
- package/dist/components/approval/components/approvalPageConfig/middleColumn.vue.d.ts +145 -0
- package/dist/components/approval/components/approvalPageConfig/operatorSelect.vue.d.ts +18 -0
- package/dist/components/approval/components/approvalPageConfig/searchConfig.vue.d.ts +166 -0
- package/dist/components/approval/components/approvalPageConfig/tableConfig.vue.d.ts +802 -0
- package/dist/components/approval/components/codeHistory/codeHistory.vue.d.ts +53 -0
- package/dist/components/approval/components/codeHistory/codeHistoryViewModal.vue.d.ts +32 -0
- package/dist/components/approval/components/columnDataList.vue.d.ts +454 -0
- package/dist/components/approval/components/columnForm.vue.d.ts +26 -0
- package/dist/components/approval/components/columnTables.vue.d.ts +502 -0
- package/dist/components/approval/components/columnUnknown.vue.d.ts +2 -0
- package/dist/components/approval/components/dataStoreConfig/ConditionConfig.vue.d.ts +199 -0
- package/dist/components/approval/components/dataStoreConfig/ValueInput.vue.d.ts +37 -0
- package/dist/components/approval/components/dataStoreConfig/dataSourceDetial.vue.d.ts +22 -0
- package/dist/components/approval/components/dataStoreConfig/dataStoreConfig.vue.d.ts +554 -0
- package/dist/components/approval/components/dataStoreConfig/dataStoreConfigItem.vue.d.ts +434 -0
- package/dist/components/approval/components/dataStoreConfig/dataStoreTest.vue.d.ts +39 -0
- package/dist/components/approval/components/dataStoreConfig/dataStoreTestsItem.vue.d.ts +17 -0
- package/dist/components/approval/components/dataStoreConfig/formField.vue.d.ts +28 -0
- package/dist/components/approval/components/dataStoreConfig/formFieldMulType.vue.d.ts +96 -0
- package/dist/components/approval/components/dataStoreConfig/selectExcelColumn.vue.d.ts +26 -0
- package/dist/components/approval/components/dataStoreConfig/selectExcelType.vue.d.ts +28 -0
- package/dist/components/approval/components/debugCode/debugCode.vue.d.ts +214 -0
- package/dist/components/approval/components/drawerDataList.vue.d.ts +504 -0
- package/dist/components/approval/components/drawerTablesList.vue.d.ts +551 -0
- package/dist/components/approval/components/flowConfig/flowConfig.vue.d.ts +1097 -0
- package/dist/components/approval/components/flowConfig/selectCcGroup.vue.d.ts +9 -0
- package/dist/components/approval/components/flowConfig/selectUsers.vue.d.ts +9 -0
- package/dist/components/approval/components/modelTablesList.vue.d.ts +551 -0
- package/dist/components/approval/components/pageConfigHistory.vue.d.ts +2 -0
- package/dist/components/approval/components/search.vue.d.ts +238 -0
- package/dist/components/approval/components/searchSummary.vue.d.ts +100 -0
- package/dist/components/approval/components/table.vue.d.ts +416 -0
- package/dist/components/approval/components/tableModal.vue.d.ts +84 -0
- package/dist/components/approval/configs/approval/default.d.ts +11 -0
- package/dist/components/approval/configs/approval/recordActions.d.ts +22 -0
- package/dist/components/approval/core.vue.d.ts +48 -0
- package/dist/components/approval/example_code/example_code.d.ts +11 -0
- package/dist/components/approval/index.d.ts +18 -0
- package/dist/components/approval/index.vue.d.ts +2 -0
- package/dist/components/approval/migrate/index.d.ts +1 -0
- package/dist/components/approval/migrate/v0001.d.ts +2 -0
- package/dist/components/approval/store/context.d.ts +48 -0
- package/dist/components/approval/store/debugCode.d.ts +7 -0
- package/dist/components/approval/store/settingsState.d.ts +15 -0
- package/dist/components/approval/typing.d.ts +210 -0
- package/dist/components/approval/useApprovalRecordActions.d.ts +83 -0
- package/dist/components/approval/utils.d.ts +164 -0
- package/dist/components/approval_for_details.vue.d.ts +9 -0
- package/dist/components/flow/ElInputTag/index.vue.d.ts +46 -0
- package/dist/components/flow/Expression/index.vue.d.ts +48 -0
- package/dist/components/flow/Role/index.vue.d.ts +68 -0
- package/dist/components/flow/User/index.vue.d.ts +76 -0
- package/dist/config/packed-config.d.ts +26 -0
- package/dist/constants.d.ts +1 -0
- package/dist/core-CctSle2c.js +1629 -0
- package/dist/core-CctSle2c.js.map +1 -0
- package/dist/dataStoreSettingHistoryViewModal-D_so-KLp.js +114 -0
- package/dist/dataStoreSettingHistoryViewModal-D_so-KLp.js.map +1 -0
- package/dist/debugCode-Cm9-WiUG.js +565 -0
- package/dist/debugCode-Cm9-WiUG.js.map +1 -0
- package/dist/debugCode-dD1YnQSD.js +11 -0
- package/dist/debugCode-dD1YnQSD.js.map +1 -0
- package/dist/default-VdDMlY4e.js +560 -0
- package/dist/default-VdDMlY4e.js.map +1 -0
- package/dist/example_code-C_xF8RRG.js +129 -0
- package/dist/example_code-C_xF8RRG.js.map +1 -0
- package/dist/flowHistoryViewModal-D8DJP7Te.js +109 -0
- package/dist/flowHistoryViewModal-D8DJP7Te.js.map +1 -0
- package/dist/index.d.ts +81 -0
- package/dist/index.js +507 -26691
- package/dist/index.js.map +1 -1
- package/dist/init-plugin-fQTSQzui.js +48 -0
- package/dist/init-plugin-fQTSQzui.js.map +1 -0
- package/dist/init-plugin.d.ts +57 -0
- package/dist/leftColumn-CsPjufue.js +209 -0
- package/dist/leftColumn-CsPjufue.js.map +1 -0
- package/dist/lyflowchart.css +1 -1
- package/dist/middleColumn-C7M6-eVo.js +107 -0
- package/dist/middleColumn-C7M6-eVo.js.map +1 -0
- package/dist/recordActions-BgFlNsGU.js +51 -0
- package/dist/recordActions-BgFlNsGU.js.map +1 -0
- package/dist/settingsState-CI81PG-i.js +19 -0
- package/dist/settingsState-CI81PG-i.js.map +1 -0
- package/dist/style.d.ts +3 -0
- package/dist/styles.d.ts +7 -0
- package/dist/tableConfig-uLXue-BS.js +2408 -0
- package/dist/tableConfig-uLXue-BS.js.map +1 -0
- package/dist/tableModal-BcYfVL02.js +124 -0
- package/dist/tableModal-BcYfVL02.js.map +1 -0
- package/dist/useApprovalRecordActions-BQ6MgV2L.js +843 -0
- package/dist/useApprovalRecordActions-BQ6MgV2L.js.map +1 -0
- package/dist/utils/StrUtil.d.ts +52 -0
- package/dist/utils/function.d.ts +8 -0
- package/dist/utils-CLet2gLV.js +420 -0
- package/dist/utils-CLet2gLV.js.map +1 -0
- package/dist/v0001-OaBeBCXI.js +4 -0
- package/dist/v0001-OaBeBCXI.js.map +1 -0
- package/dist/{Cell_click_data_source-C8WEsBGB.js → viewer-Dv3kQsMf.js} +1839 -2724
- package/dist/viewer-Dv3kQsMf.js.map +1 -0
- package/dist/vue-print-next-HRweUmNi.js +683 -0
- package/dist/vue-print-next-HRweUmNi.js.map +1 -0
- package/package.json +39 -8
- package/dist/Cell_click_data_source-C8WEsBGB.js.map +0 -1
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
//#region src/components/approval/example_code/table_row_process.js?raw
|
|
2
|
+
var e = "async function run({ table_id, record, context, settings }) {\n console.log('record', JSON.stringify(record));\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const currentTable = tables[table_id];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return { ...formModel, name: 'test' };\n}\n", t = "async function run({ table_id, context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const currentTable = tables[table_id];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return { ...formModel, name: 'test' };\n}\n", n = "async function run({ context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n // const table = tables['approve-approve_record'];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return { ...formModel, name: 'test' };\n}\n", r = "async function run({ context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n // const table = tables['approve-approve_record'];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return { data: context.formModel };\n}\n", i = "async function run({ table_id, record, context, settings }) {\n // console.log('record', JSON.stringify(record));\n // console.log('context', JSON.stringify(context));\n // console.log('settings', JSON.stringify(settings));\n // const { tables, formModel } = context;\n // const currentTable = tables[table_id];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n if (record.process_status != 'init') {\n throw new Error('仅能编辑未提交的审批数据');\n }\n return { id: record.id };\n}\n", a = "async function run({ table_id, context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const table = tables['approve-approve_record'];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n if (!selectedRowKeys || selectedRowKeys.length != 1) {\n throw new Error('请选择一条未提交的审批数据');\n }\n for (const item of selectedRecord) {\n if (item.process_status != 'init') {\n throw new Error('仅能编辑未提交的审批数据');\n }\n }\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return { id: selectedRowKeys[0] };\n}\n", o = "async function run({ table_id, record, context, settings }) {\n // console.log('record', JSON.stringify(record));\n // console.log('context', JSON.stringify(context));\n // console.log('settings', JSON.stringify(settings));\n // const { tables, formModel } = context;\n // const currentTable = tables[table_id];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n if (record.process_status != 'init') {\n throw new Error('仅能提交未提交的审批数据');\n }\n return { ids: [record.id] };\n}\n", s = "async function run({ table_id, context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const table = tables['approve-approve_record'];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n if (!selectedRowKeys || selectedRowKeys.length == 0) {\n throw new Error('请选择未提交的审批数据');\n }\n for (const item of selectedRecord) {\n if (item.process_status != 'init') {\n throw new Error('仅能提交未提交的审批数据');\n }\n }\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return { ids: selectedRowKeys };\n}\n", c = "async function run({ table_id, record, context, settings }) {\n // console.log('record', JSON.stringify(record));\n // console.log('context', JSON.stringify(context));\n // console.log('settings', JSON.stringify(settings));\n // const { tables, formModel } = context;\n // const currentTable = tables[table_id];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n if (record.process_status != 'init') {\n throw new Error('仅能删除未提交的审批数据');\n }\n return { ids: [record.id] };\n}\n", l = "async function run({ table_id, context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const table = tables['approve-approve_record'];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n if (!selectedRecord || selectedRecord.length == 0) {\n throw new Error('请选择需要删除的数据');\n }\n for (const item of selectedRecord) {\n if (item.process_status != 'init') {\n throw new Error('仅能删除未提交的审批数据');\n }\n }\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return { ids: selectedRowKeys };\n}\n", u = "async function run({ context, value }) {\n // value 为数组,对应明细的当前值\n console.log('context', JSON.stringify(context));\n const { tables, formModel } = context;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n // 返回新的记录\n return { name: 'test' };\n}\n", d = "async function run({ context, value }) {\n // value 为数组,对应明细的当前值\n console.log('context', JSON.stringify(context));\n const { tables, formModel } = context;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n // 返回数组,明细最终的值\n return [{ name: 'test' }];\n}\n", f = "async function run({ table_id, record, context, settings }) {\n console.log('record', JSON.stringify(record));\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const currentTable = tables[table_id];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return true;\n}\n", p = "async function run({ table_id, context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const currentTable = tables[table_id];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return true;\n}\n", m = "async function run({ context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n // const table = tables['approve-approve_record'];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return true;\n}\n", h = "async function run({ table_id, record, context, settings }) {\n console.log('record', JSON.stringify(record));\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const currentTable = tables[table_id];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return true;\n}\n", g = "async function run({ table_id, context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n const currentTable = tables[table_id];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return true;\n}\n", _ = "async function run({ context, settings }) {\n console.log('context', JSON.stringify(context));\n console.log('settings', JSON.stringify(settings));\n const { tables, formModel } = context;\n // const table = tables['approve-approve_record'];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return true;\n}\n", v = [
|
|
3
|
+
{
|
|
4
|
+
label: "表格行数据处理",
|
|
5
|
+
value: e,
|
|
6
|
+
actions: ["process", null],
|
|
7
|
+
types: ["click"]
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
label: "表格底部数据处理",
|
|
11
|
+
value: t,
|
|
12
|
+
actions: ["process", null],
|
|
13
|
+
types: ["click"]
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
label: "表单底部数据处理",
|
|
17
|
+
value: n,
|
|
18
|
+
actions: ["process", null],
|
|
19
|
+
types: ["click"]
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
label: "审批保存",
|
|
23
|
+
value: r,
|
|
24
|
+
actions: ["save_approve"],
|
|
25
|
+
types: ["click"]
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
label: "审批表格行编辑",
|
|
29
|
+
value: i,
|
|
30
|
+
actions: ["edit_approve"],
|
|
31
|
+
types: ["click"]
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
label: "底部按钮编辑审批",
|
|
35
|
+
value: a,
|
|
36
|
+
actions: ["edit_approve"],
|
|
37
|
+
types: ["click"]
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
label: "审批表格行提交",
|
|
41
|
+
value: o,
|
|
42
|
+
actions: ["commit_approve"],
|
|
43
|
+
types: ["click"]
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
label: "底部按钮提交审批",
|
|
47
|
+
value: s,
|
|
48
|
+
actions: ["commit_approve"],
|
|
49
|
+
types: ["click"]
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
label: "审批表格行删除",
|
|
53
|
+
value: c,
|
|
54
|
+
actions: ["delete_approve"],
|
|
55
|
+
types: ["click"]
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
label: "底部按钮删除审批",
|
|
59
|
+
value: l,
|
|
60
|
+
actions: ["delete_approve"],
|
|
61
|
+
types: ["click"]
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
label: "审批表格行催办",
|
|
65
|
+
value: "async function run({ table_id, record, context, settings }) {\n if (record.process_status != 'approving') {\n throw new Error('仅能催办审批中的审批');\n }\n return { ids: [record.process_instance_id] };\n}\n",
|
|
66
|
+
actions: ["send_reminder"],
|
|
67
|
+
types: ["click"]
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
label: "底部按钮催办审批",
|
|
71
|
+
value: "async function run({ table_id, context, settings }) {\n const { tables, formModel } = context;\n const table = tables['approve-approve_record'];\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n if (!selectedRowKeys || selectedRowKeys.length == 0) {\n throw new Error('请选择审批中的审批数据');\n }\n const process_instance_id_ids = [];\n for (const item of selectedRecord) {\n if (item.process_status != 'approving') {\n throw new Error('仅能催办审批中的审批');\n }\n process_instance_id_ids.push(item.process_instance_id);\n }\n return { ids: process_instance_id_ids };\n}\n",
|
|
72
|
+
actions: ["send_reminder"],
|
|
73
|
+
types: ["click"]
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
label: "明细添加",
|
|
77
|
+
value: u,
|
|
78
|
+
actions: ["add"],
|
|
79
|
+
types: ["click"]
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
label: "明细整体更新",
|
|
83
|
+
value: d,
|
|
84
|
+
actions: ["update"],
|
|
85
|
+
types: ["click"]
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
label: "表格行按钮显示控制",
|
|
89
|
+
value: f,
|
|
90
|
+
types: ["show"]
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
label: "表格底部按钮显示控制",
|
|
94
|
+
value: p,
|
|
95
|
+
types: ["show"]
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
label: "表单底部按钮显示控制",
|
|
99
|
+
value: m,
|
|
100
|
+
types: ["show"]
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
label: "表格行按钮禁用控制",
|
|
104
|
+
value: h,
|
|
105
|
+
types: ["disable"]
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
label: "表格底部按钮禁用控制",
|
|
109
|
+
value: g,
|
|
110
|
+
types: ["disable"]
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
label: "表单底部按钮禁用控制",
|
|
114
|
+
value: _,
|
|
115
|
+
types: ["disable"]
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
label: "审批表单保存按钮",
|
|
119
|
+
value: "async function run({ context, settings }) {\n // console.log('context', JSON.stringify(context));\n // console.log('settings', JSON.stringify(settings));\n const { isEdit } = context;\n // const table = tables['approve-approve_record'];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return !isEdit;\n}\n",
|
|
120
|
+
types: ["show"]
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
label: "审批表单编辑按钮",
|
|
124
|
+
value: "async function run({ context, settings }) {\n // console.log('context', JSON.stringify(context));\n // console.log('settings', JSON.stringify(settings));\n const { isEdit } = context;\n // const table = tables['approve-approve_record'];\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\n\n // try {\n // const res = await self.callHost('getApiData')({}, '/test/');\n // } catch (e) {\n // console.error('call error', JSON.stringify(e));\n // }\n return !!isEdit;\n}\n",
|
|
125
|
+
types: ["show"]
|
|
126
|
+
}
|
|
127
|
+
];
|
|
128
|
+
//#endregion
|
|
129
|
+
export { _ as n, m as r, v as t };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"example_code-C_xF8RRG.js","names":[],"sources":["../src/components/approval/example_code/table_row_process.js?raw","../src/components/approval/example_code/table_bottom_process.js?raw","../src/components/approval/example_code/form_bottom_process.js?raw","../src/components/approval/example_code/form_bottom_save.js?raw","../src/components/approval/example_code/approve_table_row_edit.js?raw","../src/components/approval/example_code/bottom_edit.js?raw","../src/components/approval/example_code/approve_table_row_commit.js?raw","../src/components/approval/example_code/bottom_commit.js?raw","../src/components/approval/example_code/approve_table_row_delete.js?raw","../src/components/approval/example_code/bottom_delete.js?raw","../src/components/approval/example_code/remote_table_pro_add.js?raw","../src/components/approval/example_code/remote_table_pro_update.js?raw","../src/components/approval/example_code/table_row_show.js?raw","../src/components/approval/example_code/table_bottom_show.js?raw","../src/components/approval/example_code/form_bottom_show.js?raw","../src/components/approval/example_code/table_row_disable.js?raw","../src/components/approval/example_code/table_bottom_disable.js?raw","../src/components/approval/example_code/form_bottom_disable.js?raw","../src/components/approval/example_code/form_bottom_show_for_save.js?raw","../src/components/approval/example_code/form_bottom_show_for_edit.js?raw","../src/components/approval/example_code/approve_table_row_send_reminder.js?raw","../src/components/approval/example_code/bottom_send_reminder.js?raw","../src/components/approval/example_code/example_code.ts"],"sourcesContent":["export default \"async function run({ table_id, record, context, settings }) {\\n console.log('record', JSON.stringify(record));\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const currentTable = tables[table_id];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return { ...formModel, name: 'test' };\\n}\\n\"","export default \"async function run({ table_id, context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const currentTable = tables[table_id];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return { ...formModel, name: 'test' };\\n}\\n\"","export default \"async function run({ context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n // const table = tables['approve-approve_record'];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return { ...formModel, name: 'test' };\\n}\\n\"","export default \"async function run({ context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n // const table = tables['approve-approve_record'];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return { data: context.formModel };\\n}\\n\"","export default \"async function run({ table_id, record, context, settings }) {\\n // console.log('record', JSON.stringify(record));\\n // console.log('context', JSON.stringify(context));\\n // console.log('settings', JSON.stringify(settings));\\n // const { tables, formModel } = context;\\n // const currentTable = tables[table_id];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n if (record.process_status != 'init') {\\n throw new Error('仅能编辑未提交的审批数据');\\n }\\n return { id: record.id };\\n}\\n\"","export default \"async function run({ table_id, context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const table = tables['approve-approve_record'];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n if (!selectedRowKeys || selectedRowKeys.length != 1) {\\n throw new Error('请选择一条未提交的审批数据');\\n }\\n for (const item of selectedRecord) {\\n if (item.process_status != 'init') {\\n throw new Error('仅能编辑未提交的审批数据');\\n }\\n }\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return { id: selectedRowKeys[0] };\\n}\\n\"","export default \"async function run({ table_id, record, context, settings }) {\\n // console.log('record', JSON.stringify(record));\\n // console.log('context', JSON.stringify(context));\\n // console.log('settings', JSON.stringify(settings));\\n // const { tables, formModel } = context;\\n // const currentTable = tables[table_id];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n if (record.process_status != 'init') {\\n throw new Error('仅能提交未提交的审批数据');\\n }\\n return { ids: [record.id] };\\n}\\n\"","export default \"async function run({ table_id, context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const table = tables['approve-approve_record'];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n if (!selectedRowKeys || selectedRowKeys.length == 0) {\\n throw new Error('请选择未提交的审批数据');\\n }\\n for (const item of selectedRecord) {\\n if (item.process_status != 'init') {\\n throw new Error('仅能提交未提交的审批数据');\\n }\\n }\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return { ids: selectedRowKeys };\\n}\\n\"","export default \"async function run({ table_id, record, context, settings }) {\\n // console.log('record', JSON.stringify(record));\\n // console.log('context', JSON.stringify(context));\\n // console.log('settings', JSON.stringify(settings));\\n // const { tables, formModel } = context;\\n // const currentTable = tables[table_id];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n if (record.process_status != 'init') {\\n throw new Error('仅能删除未提交的审批数据');\\n }\\n return { ids: [record.id] };\\n}\\n\"","export default \"async function run({ table_id, context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const table = tables['approve-approve_record'];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n if (!selectedRecord || selectedRecord.length == 0) {\\n throw new Error('请选择需要删除的数据');\\n }\\n for (const item of selectedRecord) {\\n if (item.process_status != 'init') {\\n throw new Error('仅能删除未提交的审批数据');\\n }\\n }\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return { ids: selectedRowKeys };\\n}\\n\"","export default \"async function run({ context, value }) {\\n // value 为数组,对应明细的当前值\\n console.log('context', JSON.stringify(context));\\n const { tables, formModel } = context;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n // 返回新的记录\\n return { name: 'test' };\\n}\\n\"","export default \"async function run({ context, value }) {\\n // value 为数组,对应明细的当前值\\n console.log('context', JSON.stringify(context));\\n const { tables, formModel } = context;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n // 返回数组,明细最终的值\\n return [{ name: 'test' }];\\n}\\n\"","export default \"async function run({ table_id, record, context, settings }) {\\n console.log('record', JSON.stringify(record));\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const currentTable = tables[table_id];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return true;\\n}\\n\"","export default \"async function run({ table_id, context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const currentTable = tables[table_id];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return true;\\n}\\n\"","export default \"async function run({ context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n // const table = tables['approve-approve_record'];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return true;\\n}\\n\"","export default \"async function run({ table_id, record, context, settings }) {\\n console.log('record', JSON.stringify(record));\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const currentTable = tables[table_id];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return true;\\n}\\n\"","export default \"async function run({ table_id, context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n const currentTable = tables[table_id];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = currentTable;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return true;\\n}\\n\"","export default \"async function run({ context, settings }) {\\n console.log('context', JSON.stringify(context));\\n console.log('settings', JSON.stringify(settings));\\n const { tables, formModel } = context;\\n // const table = tables['approve-approve_record'];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return true;\\n}\\n\"","export default \"async function run({ context, settings }) {\\n // console.log('context', JSON.stringify(context));\\n // console.log('settings', JSON.stringify(settings));\\n const { isEdit } = context;\\n // const table = tables['approve-approve_record'];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return !isEdit;\\n}\\n\"","export default \"async function run({ context, settings }) {\\n // console.log('context', JSON.stringify(context));\\n // console.log('settings', JSON.stringify(settings));\\n const { isEdit } = context;\\n // const table = tables['approve-approve_record'];\\n // const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n\\n // try {\\n // const res = await self.callHost('getApiData')({}, '/test/');\\n // } catch (e) {\\n // console.error('call error', JSON.stringify(e));\\n // }\\n return !!isEdit;\\n}\\n\"","export default \"async function run({ table_id, record, context, settings }) {\\n if (record.process_status != 'approving') {\\n throw new Error('仅能催办审批中的审批');\\n }\\n return { ids: [record.process_instance_id] };\\n}\\n\"","export default \"async function run({ table_id, context, settings }) {\\n const { tables, formModel } = context;\\n const table = tables['approve-approve_record'];\\n const { searchConditions, selectedRowKeys, selectedRecord, datasource } = table;\\n if (!selectedRowKeys || selectedRowKeys.length == 0) {\\n throw new Error('请选择审批中的审批数据');\\n }\\n const process_instance_id_ids = [];\\n for (const item of selectedRecord) {\\n if (item.process_status != 'approving') {\\n throw new Error('仅能催办审批中的审批');\\n }\\n process_instance_id_ids.push(item.process_instance_id);\\n }\\n return { ids: process_instance_id_ids };\\n}\\n\"","import table_row_process from './table_row_process.js?raw';\nimport table_bottom_process from './table_bottom_process.js?raw';\nimport form_bottom_process from './form_bottom_process.js?raw';\nimport form_bottom_save from './form_bottom_save.js?raw';\nimport approve_table_row_edit from './approve_table_row_edit.js?raw';\nimport bottom_edit from './bottom_edit.js?raw';\nimport approve_table_row_commit from './approve_table_row_commit.js?raw';\nimport bottom_commit from './bottom_commit.js?raw';\nimport approve_table_row_delete from './approve_table_row_delete.js?raw';\nimport bottom_delete from './bottom_delete.js?raw';\nimport remote_table_pro_add from './remote_table_pro_add.js?raw';\nimport remote_table_pro_update from './remote_table_pro_update.js?raw';\nimport table_row_show from './table_row_show.js?raw';\nimport table_bottom_show from './table_bottom_show.js?raw';\nimport form_bottom_show from './form_bottom_show.js?raw';\nimport table_row_disable from './table_row_disable.js?raw';\nimport table_bottom_disable from './table_bottom_disable.js?raw';\nimport form_bottom_disable from './form_bottom_disable.js?raw';\nimport form_bottom_show_for_save from './form_bottom_show_for_save.js?raw';\nimport form_bottom_show_for_edit from './form_bottom_show_for_edit.js?raw';\nimport approve_table_row_send_reminder from './approve_table_row_send_reminder.js?raw';\nimport bottom_send_reminder from './bottom_send_reminder.js?raw';\nexport const exampleCodeList = [\n {\n label: '表格行数据处理',\n value: table_row_process,\n actions: ['process', null],\n types: ['click'],\n },\n {\n label: '表格底部数据处理',\n value: table_bottom_process,\n actions: ['process', null],\n types: ['click'],\n },\n {\n label: '表单底部数据处理',\n value: form_bottom_process,\n actions: ['process', null],\n types: ['click'],\n },\n { label: '审批保存', value: form_bottom_save, actions: ['save_approve'], types: ['click'] },\n {\n label: '审批表格行编辑',\n value: approve_table_row_edit,\n actions: ['edit_approve'],\n types: ['click'],\n },\n { label: '底部按钮编辑审批', value: bottom_edit, actions: ['edit_approve'], types: ['click'] },\n {\n label: '审批表格行提交',\n value: approve_table_row_commit,\n actions: ['commit_approve'],\n types: ['click'],\n },\n {\n label: '底部按钮提交审批',\n value: bottom_commit,\n actions: ['commit_approve'],\n types: ['click'],\n },\n {\n label: '审批表格行删除',\n value: approve_table_row_delete,\n actions: ['delete_approve'],\n types: ['click'],\n },\n {\n label: '底部按钮删除审批',\n value: bottom_delete,\n actions: ['delete_approve'],\n types: ['click'],\n },\n {\n label: '审批表格行催办',\n value: approve_table_row_send_reminder,\n actions: ['send_reminder'],\n types: ['click'],\n },\n {\n label: '底部按钮催办审批',\n value: bottom_send_reminder,\n actions: ['send_reminder'],\n types: ['click'],\n },\n { label: '明细添加', value: remote_table_pro_add, actions: ['add'], types: ['click'] },\n { label: '明细整体更新', value: remote_table_pro_update, actions: ['update'], types: ['click'] },\n { label: '表格行按钮显示控制', value: table_row_show, types: ['show'] },\n { label: '表格底部按钮显示控制', value: table_bottom_show, types: ['show'] },\n { label: '表单底部按钮显示控制', value: form_bottom_show, types: ['show'] },\n { label: '表格行按钮禁用控制', value: table_row_disable, types: ['disable'] },\n { label: '表格底部按钮禁用控制', value: table_bottom_disable, types: ['disable'] },\n { label: '表单底部按钮禁用控制', value: form_bottom_disable, types: ['disable'] },\n { label: '审批表单保存按钮', value: form_bottom_show_for_save, types: ['show'] },\n { label: '审批表单编辑按钮', value: form_bottom_show_for_edit, types: ['show'] },\n];\n"],"mappings":";AAAA,IAAA,IAAe,kmBCAf,IAAe,wiBCAf,IAAe,siBCAf,IAAe,miBCAf,IAAe,4rBCAf,IAAe,gxBCAf,IAAe,+rBCAf,IAAe,4wBCAf,IAAe,+rBCAf,IAAe,2wBCAf,IAAe,wXCAf,IAAe,+XCAf,IAAe,wkBCAf,IAAe,8gBCAf,IAAe,4gBCAf,IAAe,wkBCAf,IAAe,8gBCAf,IAAe,4gBKsBF,IAAkB;CAC7B;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,WAAW,KAAK;EAC1B,OAAO,CAAC,QAAQ;EACjB;CACD;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,WAAW,KAAK;EAC1B,OAAO,CAAC,QAAQ;EACjB;CACD;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,WAAW,KAAK;EAC1B,OAAO,CAAC,QAAQ;EACjB;CACD;EAAE,OAAO;EAAQ,OAAO;EAAkB,SAAS,CAAC,eAAe;EAAE,OAAO,CAAC,QAAQ;EAAE;CACvF;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,eAAe;EACzB,OAAO,CAAC,QAAQ;EACjB;CACD;EAAE,OAAO;EAAY,OAAO;EAAa,SAAS,CAAC,eAAe;EAAE,OAAO,CAAC,QAAQ;EAAE;CACtF;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,iBAAiB;EAC3B,OAAO,CAAC,QAAQ;EACjB;CACD;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,iBAAiB;EAC3B,OAAO,CAAC,QAAQ;EACjB;CACD;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,iBAAiB;EAC3B,OAAO,CAAC,QAAQ;EACjB;CACD;EACE,OAAO;EACP,OAAO;EACP,SAAS,CAAC,iBAAiB;EAC3B,OAAO,CAAC,QAAQ;EACjB;CACD;EACE,OAAO;EACP,OF3EW;EE4EX,SAAS,CAAC,gBAAgB;EAC1B,OAAO,CAAC,QAAQ;EACjB;CACD;EACE,OAAO;EACP,ODjFW;ECkFX,SAAS,CAAC,gBAAgB;EAC1B,OAAO,CAAC,QAAQ;EACjB;CACD;EAAE,OAAO;EAAQ,OAAO;EAAsB,SAAS,CAAC,MAAM;EAAE,OAAO,CAAC,QAAQ;EAAE;CAClF;EAAE,OAAO;EAAU,OAAO;EAAyB,SAAS,CAAC,SAAS;EAAE,OAAO,CAAC,QAAQ;EAAE;CAC1F;EAAE,OAAO;EAAa,OAAO;EAAgB,OAAO,CAAC,OAAO;EAAE;CAC9D;EAAE,OAAO;EAAc,OAAO;EAAmB,OAAO,CAAC,OAAO;EAAE;CAClE;EAAE,OAAO;EAAc,OAAO;EAAkB,OAAO,CAAC,OAAO;EAAE;CACjE;EAAE,OAAO;EAAa,OAAO;EAAmB,OAAO,CAAC,UAAU;EAAE;CACpE;EAAE,OAAO;EAAc,OAAO;EAAsB,OAAO,CAAC,UAAU;EAAE;CACxE;EAAE,OAAO;EAAc,OAAO;EAAqB,OAAO,CAAC,UAAU;EAAE;CACvE;EAAE,OAAO;EAAY,OJ7FR;EI6F0C,OAAO,CAAC,OAAO;EAAE;CACxE;EAAE,OAAO;EAAY,OH9FR;EG8F0C,OAAO,CAAC,OAAO;EAAE;CACzE"}
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { o as e, v as t } from "./init-plugin-fQTSQzui.js";
|
|
2
|
+
import { Fragment as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, createVNode as s, defineComponent as c, onMounted as l, openBlock as u, ref as d, renderList as f, resolveComponent as p, withCtx as m } from "vue";
|
|
3
|
+
//#region src/components/approval/components/approvalHistory/flowHistoryViewModal.vue?vue&type=script&lang.ts
|
|
4
|
+
var h = c({
|
|
5
|
+
name: "flowHistoryViewModal",
|
|
6
|
+
props: {
|
|
7
|
+
height: {
|
|
8
|
+
type: Number,
|
|
9
|
+
default: () => 1e3
|
|
10
|
+
},
|
|
11
|
+
history_ids: {
|
|
12
|
+
type: Array,
|
|
13
|
+
default: () => []
|
|
14
|
+
},
|
|
15
|
+
org_id: {
|
|
16
|
+
type: Number,
|
|
17
|
+
default: () => 0
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
components: {},
|
|
21
|
+
emits: ["ok", "cancel"],
|
|
22
|
+
setup(t, { emit: n }) {
|
|
23
|
+
let r = () => {
|
|
24
|
+
n("cancel");
|
|
25
|
+
}, i = () => {}, a = d(!1), o = d([]), s = async () => {
|
|
26
|
+
let n = [{
|
|
27
|
+
field_name: "id",
|
|
28
|
+
operator: "in",
|
|
29
|
+
value: t.history_ids,
|
|
30
|
+
format: "input",
|
|
31
|
+
class_name: "str"
|
|
32
|
+
}];
|
|
33
|
+
e({
|
|
34
|
+
org_id: t.org_id,
|
|
35
|
+
is_pagination: !1,
|
|
36
|
+
column_fields: [
|
|
37
|
+
"id",
|
|
38
|
+
"create_time",
|
|
39
|
+
"content"
|
|
40
|
+
],
|
|
41
|
+
sort_fields: ["-id"],
|
|
42
|
+
conditions: [n]
|
|
43
|
+
}, "/approve/query_flow_setting_history_list").then((e) => {
|
|
44
|
+
let n = {};
|
|
45
|
+
a.value = !0, e.data.forEach((e) => {
|
|
46
|
+
n[e.id] = {
|
|
47
|
+
name: `[${e.id}]${e.create_time}`,
|
|
48
|
+
content: e.content
|
|
49
|
+
};
|
|
50
|
+
}), o.value.length = 0, t.history_ids.forEach((e) => {
|
|
51
|
+
o.value.push(n[e]);
|
|
52
|
+
}), a.value = !1;
|
|
53
|
+
}).catch(() => {
|
|
54
|
+
a.value = !1;
|
|
55
|
+
});
|
|
56
|
+
};
|
|
57
|
+
return l(() => {
|
|
58
|
+
s();
|
|
59
|
+
}), {
|
|
60
|
+
handleCancel: r,
|
|
61
|
+
handleOk: i,
|
|
62
|
+
loading: a,
|
|
63
|
+
history_records: o
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
}), g = { class: "json-obj-container" };
|
|
67
|
+
function _(e, t, c, l, d, h) {
|
|
68
|
+
let _ = p("TextDiff"), v = p("a-tab-pane"), y = p("code-editor"), b = p("a-tabs"), x = p("a-modal");
|
|
69
|
+
return u(), r(x, {
|
|
70
|
+
open: !0,
|
|
71
|
+
title: e.$t("历史版本"),
|
|
72
|
+
width: "100%",
|
|
73
|
+
"wrap-class-name": "full-modal",
|
|
74
|
+
onCancel: e.handleCancel
|
|
75
|
+
}, {
|
|
76
|
+
footer: m(() => [...t[0] ||= []]),
|
|
77
|
+
default: m(() => [s(b, {
|
|
78
|
+
type: "card",
|
|
79
|
+
size: "middle",
|
|
80
|
+
class: "tab-content"
|
|
81
|
+
}, {
|
|
82
|
+
default: m(() => [e.history_ids.length === 2 ? (u(), r(v, {
|
|
83
|
+
key: 0,
|
|
84
|
+
tab: e.$t("版本比较")
|
|
85
|
+
}, {
|
|
86
|
+
default: m(() => [s(_, {
|
|
87
|
+
left: e.history_records[0] || {},
|
|
88
|
+
right: e.history_records[1] || {}
|
|
89
|
+
}, null, 8, ["left", "right"])]),
|
|
90
|
+
_: 1
|
|
91
|
+
}, 8, ["tab"])) : i("", !0), (u(!0), a(n, null, f(e.history_records, (e) => (u(), r(v, {
|
|
92
|
+
tab: e.name,
|
|
93
|
+
key: e.name
|
|
94
|
+
}, {
|
|
95
|
+
default: m(() => [o("div", g, [s(y, {
|
|
96
|
+
editorValue: e.content,
|
|
97
|
+
mode: "xml",
|
|
98
|
+
lineWrapping: !0
|
|
99
|
+
}, null, 8, ["editorValue"])])]),
|
|
100
|
+
_: 2
|
|
101
|
+
}, 1032, ["tab"]))), 128))]),
|
|
102
|
+
_: 1
|
|
103
|
+
})]),
|
|
104
|
+
_: 1
|
|
105
|
+
}, 8, ["title", "onCancel"]);
|
|
106
|
+
}
|
|
107
|
+
var v = /* @__PURE__ */ t(h, [["render", _], ["__scopeId", "data-v-7a87c333"]]);
|
|
108
|
+
//#endregion
|
|
109
|
+
export { v as default };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flowHistoryViewModal-D8DJP7Te.js","names":[],"sources":["../src/components/approval/components/approvalHistory/flowHistoryViewModal.vue","../src/components/approval/components/approvalHistory/flowHistoryViewModal.vue"],"sourcesContent":["<template>\n <a-modal\n :open=\"true\"\n :title=\"$t('历史版本')\"\n width=\"100%\"\n wrap-class-name=\"full-modal\"\n @cancel=\"handleCancel\"\n >\n <template #footer></template>\n <a-tabs\n type=\"card\"\n size=\"middle\"\n class=\"tab-content\"\n >\n <a-tab-pane\n :key=\"0\"\n v-if=\"history_ids.length === 2\"\n :tab=\"$t('版本比较')\"\n >\n <TextDiff\n :left=\"history_records[0] || {}\"\n :right=\"history_records[1] || {}\"\n />\n </a-tab-pane>\n <a-tab-pane\n v-for=\"record in history_records\"\n :tab=\"record.name\"\n :key=\"record.name\"\n >\n <div class=\"json-obj-container\">\n <code-editor\n :editorValue=\"record.content\"\n mode=\"xml\"\n :lineWrapping=\"true\"\n />\n </div>\n </a-tab-pane>\n </a-tabs>\n </a-modal>\n</template>\n<script lang=\"ts\">\nimport { defineComponent, onMounted, PropType, ref } from 'vue';\nimport { getApiData } from '@/init-plugin';\nexport default defineComponent({\n name: 'flowHistoryViewModal',\n props: {\n height: {\n type: Number,\n default: () => 1000,\n },\n history_ids: {\n type: Array as PropType<string[]>,\n default: () => [],\n },\n org_id: {\n type: Number,\n default: () => 0,\n },\n },\n components: {\n },\n emits: ['ok', 'cancel'],\n\n setup(props, { emit }) {\n const handleCancel = () => {\n emit('cancel');\n };\n const handleOk = () => {};\n const loading = ref(false);\n const history_records = ref([]);\n const getHistoryRecords = async () => {\n const conditions = [\n {\n field_name: 'id',\n operator: 'in',\n value: props.history_ids,\n format: 'input',\n class_name: 'str',\n },\n ];\n\n const queryParams = {\n org_id: props.org_id,\n is_pagination: false,\n column_fields: ['id', 'create_time', 'content'],\n sort_fields: ['-id'],\n conditions: [conditions],\n };\n getApiData(queryParams, '/approve/query_flow_setting_history_list')\n .then((res: any) => {\n const tmpMap = {};\n loading.value = true;\n res.data.forEach((item: any) => {\n tmpMap[item.id] = {\n name: `[${item.id}]${item.create_time}`,\n content: item.content,\n };\n });\n history_records.value.length = 0;\n props.history_ids.forEach(id => {\n history_records.value.push(tmpMap[id]);\n });\n loading.value = false;\n })\n .catch(() => {\n loading.value = false;\n });\n };\n onMounted(() => {\n getHistoryRecords();\n });\n return {\n handleCancel,\n handleOk,\n loading,\n history_records,\n };\n },\n});\n</script>\n<style scoped lang=\"less\">\n.ant-layout-content,\n.ant-layout-sider {\n overflow: auto;\n background-color: white;\n outline: 1px #ebeef5 solid;\n}\n.tab-content {\n padding: 0;\n display: flex;\n flex-direction: column;\n gap: 16px;\n}\n.ant-tabs {\n height: 100%;\n\n ::v-deep(.ant-tabs-content-top) {\n height: 100%;\n }\n}\n.json-obj-container {\n height: 100%;\n overflow-y: auto;\n}\n</style>\n","<template>\n <a-modal\n :open=\"true\"\n :title=\"$t('历史版本')\"\n width=\"100%\"\n wrap-class-name=\"full-modal\"\n @cancel=\"handleCancel\"\n >\n <template #footer></template>\n <a-tabs\n type=\"card\"\n size=\"middle\"\n class=\"tab-content\"\n >\n <a-tab-pane\n :key=\"0\"\n v-if=\"history_ids.length === 2\"\n :tab=\"$t('版本比较')\"\n >\n <TextDiff\n :left=\"history_records[0] || {}\"\n :right=\"history_records[1] || {}\"\n />\n </a-tab-pane>\n <a-tab-pane\n v-for=\"record in history_records\"\n :tab=\"record.name\"\n :key=\"record.name\"\n >\n <div class=\"json-obj-container\">\n <code-editor\n :editorValue=\"record.content\"\n mode=\"xml\"\n :lineWrapping=\"true\"\n />\n </div>\n </a-tab-pane>\n </a-tabs>\n </a-modal>\n</template>\n<script lang=\"ts\">\nimport { defineComponent, onMounted, PropType, ref } from 'vue';\nimport { getApiData } from '@/init-plugin';\nexport default defineComponent({\n name: 'flowHistoryViewModal',\n props: {\n height: {\n type: Number,\n default: () => 1000,\n },\n history_ids: {\n type: Array as PropType<string[]>,\n default: () => [],\n },\n org_id: {\n type: Number,\n default: () => 0,\n },\n },\n components: {\n },\n emits: ['ok', 'cancel'],\n\n setup(props, { emit }) {\n const handleCancel = () => {\n emit('cancel');\n };\n const handleOk = () => {};\n const loading = ref(false);\n const history_records = ref([]);\n const getHistoryRecords = async () => {\n const conditions = [\n {\n field_name: 'id',\n operator: 'in',\n value: props.history_ids,\n format: 'input',\n class_name: 'str',\n },\n ];\n\n const queryParams = {\n org_id: props.org_id,\n is_pagination: false,\n column_fields: ['id', 'create_time', 'content'],\n sort_fields: ['-id'],\n conditions: [conditions],\n };\n getApiData(queryParams, '/approve/query_flow_setting_history_list')\n .then((res: any) => {\n const tmpMap = {};\n loading.value = true;\n res.data.forEach((item: any) => {\n tmpMap[item.id] = {\n name: `[${item.id}]${item.create_time}`,\n content: item.content,\n };\n });\n history_records.value.length = 0;\n props.history_ids.forEach(id => {\n history_records.value.push(tmpMap[id]);\n });\n loading.value = false;\n })\n .catch(() => {\n loading.value = false;\n });\n };\n onMounted(() => {\n getHistoryRecords();\n });\n return {\n handleCancel,\n handleOk,\n loading,\n history_records,\n };\n },\n});\n</script>\n<style scoped lang=\"less\">\n.ant-layout-content,\n.ant-layout-sider {\n overflow: auto;\n background-color: white;\n outline: 1px #ebeef5 solid;\n}\n.tab-content {\n padding: 0;\n display: flex;\n flex-direction: column;\n gap: 16px;\n}\n.ant-tabs {\n height: 100%;\n\n ::v-deep(.ant-tabs-content-top) {\n height: 100%;\n }\n}\n.json-obj-container {\n height: 100%;\n overflow-y: auto;\n}\n</style>\n"],"mappings":";;;AA2CA,IAAA,IAAe,EAAgB;CAC7B,MAAM;CACN,OAAO;EACL,QAAQ;GACN,MAAM;GACN,eAAe;GAChB;EACD,aAAa;GACX,MAAM;GACN,eAAe,EAAE;GAClB;EACD,QAAQ;GACN,MAAM;GACN,eAAe;GAChB;EACF;CACD,YAAY,EACX;CACD,OAAO,CAAC,MAAM,SAAS;CAEvB,MAAM,GAAO,EAAE,WAAQ;EACrB,IAAM,UAAqB;AACzB,KAAK,SAAS;KAEV,UAAiB,IACjB,IAAU,EAAI,GAAM,EACpB,IAAkB,EAAI,EAAE,CAAC,EACzB,IAAoB,YAAY;GACpC,IAAM,IAAa,CACjB;IACE,YAAY;IACZ,UAAU;IACV,OAAO,EAAM;IACb,QAAQ;IACR,YAAY;IACb,CACF;AASD,KAPoB;IAClB,QAAQ,EAAM;IACd,eAAe;IACf,eAAe;KAAC;KAAM;KAAe;KAAU;IAC/C,aAAa,CAAC,MAAM;IACpB,YAAY,CAAC,EAAW;IACzB,EACuB,2CAA0C,CAC/D,MAAM,MAAa;IAClB,IAAM,IAAS,EAAE;AAYjB,IAXA,EAAQ,QAAQ,IAChB,EAAI,KAAK,SAAS,MAAc;AAC9B,OAAO,EAAK,MAAM;MAChB,MAAM,IAAI,EAAK,GAAG,GAAG,EAAK;MAC1B,SAAS,EAAK;MACf;MACD,EACF,EAAgB,MAAM,SAAS,GAC/B,EAAM,YAAY,SAAQ,MAAM;AAC9B,OAAgB,MAAM,KAAK,EAAO,GAAI;MACtC,EACF,EAAQ,QAAQ;KACjB,CACA,YAAY;AACX,MAAQ,QAAQ;KAChB;;AAKN,SAHA,QAAgB;AACd,MAAmB;IACnB,EACK;GACL;GACA;GACA;GACA;GACD;;CAEJ,CAAC,QCzFW,OAAM,sBAAoB;;;aA5BrC,EAqCU,GAAA;EApCP,MAAM;EACN,OAAO,EAAA,GAAE,OAAA;EACV,OAAM;EACN,mBAAgB;EACf,UAAQ,EAAA;;EAEE,QAAM,QAAY,CAAA,GAAA,AAAA,EAAA,OAAA,EAAA,CAAA,CAAA;mBA6BpB,CA5BT,EA4BS,GAAA;GA3BP,MAAK;GACL,MAAK;GACL,OAAM;;oBAWO,CAPL,EAAA,YAAY,WAAM,KAAA,GAAA,EAF1B,EASa,GAAA;IARV,KAAK;IAEL,KAAK,EAAA,GAAE,OAAA;;qBAKN,CAHF,EAGE,GAAA;KAFC,MAAM,EAAA,gBAAe,MAAA,EAAA;KACrB,OAAO,EAAA,gBAAe,MAAA,EAAA;;;wCAG3B,EAYa,GAAA,MAAA,EAXM,EAAA,kBAAV,YADT,EAYa,GAAA;IAVV,KAAK,EAAO;IACZ,KAAK,EAAO;;qBAQP,CANN,EAMM,OANN,GAMM,CALJ,EAIE,GAAA;KAHC,aAAa,EAAO;KACrB,MAAK;KACJ,cAAc"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import './styles';
|
|
2
|
+
import MyProcess from './MyProcess.vue';
|
|
3
|
+
import MyProcessViewer from './components/Process/viewer/index.vue';
|
|
4
|
+
import ApprovalForDetails from './components/approval_for_details.vue';
|
|
5
|
+
import CellClickDataSource from './components/Cell_click_data_source.vue';
|
|
6
|
+
/**
|
|
7
|
+
* 审批作废(= 删除)弹窗:填作废原因 → `/approve/cancel_agree_approve_record`。
|
|
8
|
+
*
|
|
9
|
+
* ⚠️ **静态**导出(不包 `defineAsyncComponent`):本文件自己的 `import` 就把它放进了
|
|
10
|
+
* 宿主首屏静态闭包,而它本身只有约 2KB;再包一层异步外壳会产出
|
|
11
|
+
* 「同一个模块既被静态 import 又被 `import()`」的形状,宿主构建随即报
|
|
12
|
+
* `INEFFECTIVE_DYNAMIC_IMPORT`,对一个已加载的小模块也没有意义。
|
|
13
|
+
* (历史上它还被 `approval_for_details.vue` 静态引用过;现在按钮/弹窗都已外置到
|
|
14
|
+
* `Cell_click_approve` / `Cell_click_data_source`,本组件不再引用它。)
|
|
15
|
+
*/
|
|
16
|
+
import ApprovalCancelModal from './components/approval/components/CancelModal.vue';
|
|
17
|
+
import type { Component } from 'vue';
|
|
18
|
+
/**
|
|
19
|
+
* 审批相关的 4 个组件走**懒加载导出**(`defineAsyncComponent` + 动态 `import()`)。
|
|
20
|
+
*
|
|
21
|
+
* 为什么:静态 import 会让整块审批代码 —— 包括它依赖的 bpmn-js 流程图引擎 —— 一起进入宿主的
|
|
22
|
+
* **首屏静态闭包**(实测宿主里是约 1 018 KiB 的 `dist-*.js`,被入口 `main-*.js` 静态 `from` 引入),
|
|
23
|
+
* 而宿主可能整场会话都不会渲染审批页。改成动态 import 后构建器会把它拆成独立 chunk,
|
|
24
|
+
* 宿主只在真正路由过去 / 挂载该组件时才下载。
|
|
25
|
+
*
|
|
26
|
+
* 宿主侧的用法**完全不变**(`componentMap: { '...': ApprovalIndex }`、
|
|
27
|
+
* `settingsExtra.tabs[].component = ApprovalSettings`),**不需要**再套一层
|
|
28
|
+
* `defineAsyncComponent(() => ApprovalIndex)` —— 那会变成双层异步包装。
|
|
29
|
+
*
|
|
30
|
+
* 其余静态导出(MyProcess / MyProcessViewer / ApprovalForDetails / CellClickDataSource /
|
|
31
|
+
* ApprovalCancelModal)引用方拿到的依然是**同步组件** —— `ApprovalCancelModal` 是静态的,
|
|
32
|
+
* 原因见文件顶部它 import 处的注释。
|
|
33
|
+
*
|
|
34
|
+
* ⚠️ `: Component` 这个显式注解**不能删**:不加注解时 TS 会把 `defineAsyncComponent` 的推导弹出
|
|
35
|
+
* 类型写进 `dist/index.d.ts`,而该类型引用了 `.vue` 文件里没有导出的私有 `Props`
|
|
36
|
+
* (`error TS4023: Exported variable 'ApprovalSettings' has or is using name 'Props' from external
|
|
37
|
+
* module ".../approvalPageConfig/index.vue" but cannot be named`),后果是整个 `index.d.ts`
|
|
38
|
+
* 静默不产出、宿主全部解析失败。注解成公开类型 `Component` 就能切断这条私有名的传播链。
|
|
39
|
+
*/
|
|
40
|
+
declare const ApprovalIndex: Component;
|
|
41
|
+
declare const ApprovalSettings: Component;
|
|
42
|
+
declare const ApprovalHistory: Component;
|
|
43
|
+
declare const ApprovalDebugCode: Component;
|
|
44
|
+
/**
|
|
45
|
+
* 全屏编辑模态框(详情页/列表单元格上的「修改」用它打开)。
|
|
46
|
+
* 同样必须懒加载:它内部是 core.vue → formConfig/flowConfig → bpmn-js 那条重链。
|
|
47
|
+
* 宿主用法:`<ApprovalEditorModal v-if="editorOpen" v-model:open="editorOpen" v-bind="editorProps" />`
|
|
48
|
+
* —— `v-if` 不能省,否则异步加载器在挂载时就会被触发,懒加载形同虚设。
|
|
49
|
+
*/
|
|
50
|
+
declare const ApprovalEditorModal: Component;
|
|
51
|
+
/**
|
|
52
|
+
* 「审批」单元格组件(表格里那个点开看审批详情的链接按钮)—— 从
|
|
53
|
+
* `PSM_ApproveSystemPC/src/components/cellComponent/Cell_click_approve.vue` 移植进库。
|
|
54
|
+
*
|
|
55
|
+
* ⚠️ 必须**懒加载导出 + 懒加载注册**(`install()` 里 `.component('Cell_click_approve', CellClickApprove)`):
|
|
56
|
+
* - 通用表格是用**单元格类型字符串**找组件的(`resolveAsset` 只查全局注册与 `components` 选项),
|
|
57
|
+
* 所以名字必须真的注册进 app 组件表,否则那一格渲染空白、只留一行 warning;
|
|
58
|
+
* - 它内部整条链(`approval_for_details` / `core.vue` / bpmn-js)很重,而**大部分页面根本用不到这一格**,
|
|
59
|
+
* 所以连组件自身也走异步:宿主首屏不为它付任何体积,代价是每一格按钮比同行晚一帧出现。
|
|
60
|
+
*
|
|
61
|
+
* ⛔ 别顺手改成静态 `import`:一旦本文件静态引入它,同时 `install()` 里又保留这层 `defineAsyncComponent`,
|
|
62
|
+
* 就构成「同一 chunk 既静态 import 又被 `import()`」→ 宿主构建直接报 `INEFFECTIVE_DYNAMIC_IMPORT`。
|
|
63
|
+
* (`CancelModal` 正好是相反的情形:它必须静态,原因见文件顶部。)
|
|
64
|
+
*
|
|
65
|
+
* `: Component` 注解同样不能删(TS4023,见上面 ApprovalIndex 处的说明)。
|
|
66
|
+
*/
|
|
67
|
+
declare const CellClickApprove: Component;
|
|
68
|
+
export { MyProcess, MyProcessViewer, ApprovalForDetails, CellClickDataSource, CellClickApprove, ApprovalIndex, ApprovalSettings, ApprovalHistory, ApprovalDebugCode, ApprovalEditorModal, ApprovalCancelModal, };
|
|
69
|
+
/**
|
|
70
|
+
* 审批记录「修改 / 删除 / 打印」的**统一封装**:是否显示(判断函数)+ 点击行为。
|
|
71
|
+
*
|
|
72
|
+
* 纯逻辑模块(只依赖 init-plugin 与一份 action 配置片段),可以静态导出:
|
|
73
|
+
* 它不会把审批页或 bpmn 拖进来。宿主/详情壳的按钮都应当走它,别再各写一遍判断,
|
|
74
|
+
* 否则详情页与列表页行按钮的行为迟早漂移。
|
|
75
|
+
*/
|
|
76
|
+
export { useApproveRecordActions, APPROVE_DETAIL_ACTION_KEYS, } from './components/approval/useApprovalRecordActions';
|
|
77
|
+
export type { ApproveDetailActionKey, UseApproveRecordActionsOptions, } from './components/approval/useApprovalRecordActions';
|
|
78
|
+
declare const _default: {
|
|
79
|
+
install(app: any, options: any): void;
|
|
80
|
+
};
|
|
81
|
+
export default _default;
|