ztxkui 4.2.18-21 → 4.2.18-220
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/App.js +315 -291
- package/dist/Demo.js +64 -43
- package/dist/DemoCom/BasicDemo.js +57 -56
- package/dist/DemoCom/CodeQueryDemo.js +3 -2
- package/dist/DemoCom/CollapseDemo.js +28 -27
- package/dist/DemoCom/DragSort.js +11 -10
- package/dist/DemoCom/FormDemo.js +36 -30
- package/dist/DemoCom/PrintContainerDemo.js +151 -150
- package/dist/DemoCom/PrintDemo.js +15 -14
- package/dist/DemoCom/SinaturesDemo.js +9 -8
- package/dist/DemoCom/SyhDemo.js +21 -20
- package/dist/DemoCom/TableAnalyse.js +34 -33
- package/dist/DemoCom/TableDemo.js +73 -69
- package/dist/DemoCom/TableDemo1.js +84 -34
- package/dist/DemoCom/TableDetail.d.ts +9 -0
- package/dist/DemoCom/TableDetail.js +259 -0
- package/dist/DemoCom/TestCom.js +22 -19
- package/dist/DemoCom/data.d.ts +110 -0
- package/dist/DemoCom/data.js +2308 -0
- package/dist/TableDemo/BasicTable.js +225 -25
- package/dist/TableDemo/EditableTable.js +146 -72
- package/dist/TableDemo/ModalTable.js +25 -24
- package/dist/TableDemo/ProEditableTable.js +30 -29
- package/dist/TableDemo/data.d.ts +34 -0
- package/dist/TableDemo/data.js +387 -10
- package/dist/TableDemo/index.js +3 -3
- package/dist/TreeDemo.js +8 -7
- package/dist/TreeSelectDemo.js +12 -8
- package/dist/UI/Form/index.d.ts +3 -0
- package/dist/UI/Form/index.js +347 -0
- package/dist/UI/Input/index.d.ts +17 -0
- package/dist/UI/Input/index.js +74 -0
- package/dist/UI/InputNumber/index.d.ts +3 -0
- package/dist/UI/InputNumber/index.js +45 -0
- package/dist/UI/OldForm/index.d.ts +9 -0
- package/dist/UI/OldForm/index.js +302 -0
- package/dist/UI/Select/EmpForQuitDemo.d.ts +15 -0
- package/dist/UI/Select/EmpForQuitDemo.js +120 -0
- package/dist/UI/Select/index.d.ts +10 -0
- package/dist/UI/Select/index.js +207 -0
- package/dist/UI/Table/BusinessListDemo.d.ts +15 -0
- package/dist/UI/Table/BusinessListDemo.js +227 -0
- package/dist/UI/Table/BusinessMemberDemo.d.ts +18 -0
- package/dist/UI/Table/BusinessMemberDemo.js +181 -0
- package/dist/UI/Table/index.d.ts +10 -0
- package/dist/UI/Table/index.js +850 -0
- package/dist/UI/TreeSelect/index.d.ts +3 -0
- package/dist/UI/TreeSelect/index.js +120 -0
- package/dist/UI/index.d.ts +2 -0
- package/dist/UI/index.js +34 -0
- package/dist/UploadDemo.js +27 -23
- package/dist/components/Button/button.d.ts +6 -0
- package/dist/components/Button/button.js +11 -4
- package/dist/components/Collapse/collapse.js +2 -1
- package/dist/components/DatePicker/data-picker.d.ts +3 -1
- package/dist/components/EnhanceSelect/index.d.ts +11 -1
- package/dist/components/EnhanceSelect/index.js +231 -49
- package/dist/components/EnhanceTree/index.js +4 -3
- package/dist/components/EnhanceTreeSelect/index.d.ts +5 -1
- package/dist/components/EnhanceTreeSelect/index.js +57 -7
- package/dist/components/Export/export.js +5 -4
- package/dist/components/Form/form.d.ts +11 -1
- package/dist/components/Form/form.js +5 -3
- package/dist/components/Input/input.d.ts +5 -3
- package/dist/components/Input/input.js +72 -3
- package/dist/components/InputNumber/input-number.js +3 -2
- package/dist/components/Layout/layout.d.ts +4 -4
- package/dist/components/Menu/menu.d.ts +1 -1
- package/dist/components/NumberCase/index.js +9 -7
- package/dist/components/Print/print.js +4 -3
- package/dist/components/PrintContainer/AttachPreviewModal.js +3 -2
- package/dist/components/PrintContainer/PrintModal.js +4 -3
- package/dist/components/PrintContainer/handle.d.ts +2 -4
- package/dist/components/PrintContainer/handle.js +3 -2
- package/dist/components/PrintContainer/lodop.js +2 -1
- package/dist/components/PrintContainer/print-container.js +74 -73
- package/dist/components/PrintContainer/service.js +5 -4
- package/dist/components/ProForm/hooks.d.ts +23 -0
- package/dist/components/ProForm/hooks.js +209 -0
- package/dist/components/ProForm/index.d.ts +9 -0
- package/dist/components/ProForm/index.js +168 -0
- package/dist/components/ProForm/interface.d.ts +200 -0
- package/dist/components/ProForm/interface.js +1 -0
- package/dist/components/ProForm/item.d.ts +13 -0
- package/dist/components/ProForm/item.js +222 -0
- package/dist/components/ProForm/items.d.ts +5 -0
- package/dist/components/ProForm/items.js +36 -0
- package/dist/components/ProForm/record-common-list.d.ts +18 -0
- package/dist/components/ProForm/record-common-list.js +83 -0
- package/dist/components/ProForm/search-drawer.d.ts +14 -0
- package/dist/components/ProForm/search-drawer.js +237 -0
- package/dist/components/ProForm/setting.d.ts +5 -0
- package/dist/components/ProForm/setting.js +12 -0
- package/dist/components/ProForm/useCommonSearch.d.ts +35 -0
- package/dist/components/ProForm/useCommonSearch.js +352 -0
- package/dist/components/ProFormList/index.d.ts +12 -0
- package/dist/components/ProFormList/index.js +34 -0
- package/dist/components/RangePicker/range-picker.js +5 -2
- package/dist/components/SortableCancel/sortable-cancel.d.ts +1 -0
- package/dist/components/SortableCancel/sortable-cancel.js +2 -2
- package/dist/components/Table/components/FillDown.js +2 -1
- package/dist/components/Table/components/FilterDropdown.d.ts +1 -0
- package/dist/components/Table/components/FilterDropdown.js +36 -12
- package/dist/components/Table/hooks/useColumns.d.ts +5 -0
- package/dist/components/Table/hooks/useColumns.js +396 -22
- package/dist/components/Table/hooks/useDropRef.js +2 -1
- package/dist/components/Table/hooks/useScuRfresh.d.ts +3 -0
- package/dist/components/Table/hooks/useScuRfresh.js +22 -0
- package/dist/components/Table/hooks/useSelectSubtotal.js +5 -1
- package/dist/components/Table/hooks/useVituralScrollBar.d.ts +10 -0
- package/dist/components/Table/hooks/useVituralScrollBar.js +234 -0
- package/dist/components/Table/index.d.ts +4 -0
- package/dist/components/Table/table-adddel-column.js +4 -3
- package/dist/components/Table/table-dynamic.d.ts +1 -0
- package/dist/components/Table/table-dynamic.js +447 -60
- package/dist/components/Table/table-enhance-cell.d.ts +3 -0
- package/dist/components/Table/table-enhance-cell.js +28 -8
- package/dist/components/Table/table-menu.d.ts +7 -0
- package/dist/components/Table/table-menu.js +359 -0
- package/dist/components/Table/table-resizable-title.js +1 -0
- package/dist/components/Table/table-sort.js +4 -3
- package/dist/components/Table/table.d.ts +16 -0
- package/dist/components/Table/table.js +241 -65
- package/dist/components/Table/utils/dom.js +2 -1
- package/dist/components/Table/utils/filterHandle.d.ts +1 -1
- package/dist/components/Table/utils/filterHandle.js +27 -12
- package/dist/components/Table/utils/getSummaryData.d.ts +1 -1
- package/dist/components/Table/utils/getSummaryData.js +279 -24
- package/dist/components/Table/utils/shallowEqual.js +2 -1
- package/dist/components/Table/utils/validate.js +25 -6
- package/dist/components/Tabs/tabs.d.ts +2 -0
- package/dist/components/Tabs/tabs.js +3 -1
- package/dist/components/TranslationButton/DownFile.d.ts +7 -0
- package/dist/components/TranslationButton/DownFile.js +95 -0
- package/dist/components/TranslationButton/PreviewFile.d.ts +5 -0
- package/dist/components/TranslationButton/PreviewFile.js +73 -0
- package/dist/components/TranslationButton/TranslationButton.d.ts +34 -0
- package/dist/components/TranslationButton/TranslationButton.js +245 -0
- package/dist/components/TranslationButton/hooks.d.ts +8 -0
- package/dist/components/TranslationButton/hooks.js +139 -0
- package/dist/components/TranslationButton/index.d.ts +4 -0
- package/dist/components/TranslationButton/index.js +4 -0
- package/dist/components/TreeSelect/index.d.ts +19 -0
- package/dist/components/TreeSelect/index.js +88 -0
- package/dist/components/Upload/upload-table.js +31 -26
- package/dist/components/Upload/upload.d.ts +20 -1
- package/dist/components/Upload/upload.js +172 -27
- package/dist/components/Upload/utils.d.ts +9 -2
- package/dist/components/Upload/utils.js +153 -38
- package/dist/components/UploadCustom/hooks/useDg.d.ts +6 -0
- package/dist/components/UploadCustom/hooks/useDg.js +55 -0
- package/dist/components/UploadSingle/upload-single.js +5 -4
- package/dist/components/Watermark/index.d.ts +2 -0
- package/dist/components/Watermark/index.js +2 -0
- package/dist/components/Watermark/interface.d.ts +20 -0
- package/dist/components/Watermark/interface.js +1 -0
- package/dist/components/Watermark/utils.d.ts +1 -0
- package/dist/components/Watermark/utils.js +70 -0
- package/dist/components/Watermark/water.d.ts +50 -0
- package/dist/components/Watermark/water.js +66 -0
- package/dist/components/Watermark/watermark-div.d.ts +4 -0
- package/dist/components/Watermark/watermark-div.js +41 -0
- package/dist/components/Watermark/watermark-shadow.d.ts +6 -0
- package/dist/components/Watermark/watermark-shadow.js +116 -0
- package/dist/components/Watermark/watermark.d.ts +3 -0
- package/dist/components/Watermark/watermark.js +102 -0
- package/dist/components/WorkflowPrintContainer/component/Gragh/Gragh.d.ts +9 -0
- package/dist/components/WorkflowPrintContainer/component/Gragh/Gragh.js +63 -0
- package/dist/components/WorkflowPrintContainer/component/Header.d.ts +12 -0
- package/dist/components/WorkflowPrintContainer/component/Header.js +109 -0
- package/dist/components/WorkflowPrintContainer/component/ProcessDetail.d.ts +18 -0
- package/dist/components/WorkflowPrintContainer/component/ProcessDetail.js +243 -0
- package/dist/components/WorkflowPrintContainer/component/Upload/index.d.ts +20 -0
- package/dist/components/WorkflowPrintContainer/component/Upload/index.js +59 -0
- package/dist/components/WorkflowPrintContainer/component/association/component/TableList.d.ts +10 -0
- package/dist/components/WorkflowPrintContainer/component/association/component/TableList.js +75 -0
- package/dist/components/WorkflowPrintContainer/component/association/index.d.ts +9 -0
- package/dist/components/WorkflowPrintContainer/component/association/index.js +92 -0
- package/dist/components/WorkflowPrintContainer/component/attention/component/TableList.d.ts +9 -0
- package/dist/components/WorkflowPrintContainer/component/attention/component/TableList.js +38 -0
- package/dist/components/WorkflowPrintContainer/component/attention/index.d.ts +10 -0
- package/dist/components/WorkflowPrintContainer/component/attention/index.js +95 -0
- package/dist/components/WorkflowPrintContainer/component/audit/component/TableList.d.ts +8 -0
- package/dist/components/WorkflowPrintContainer/component/audit/component/TableList.js +53 -0
- package/dist/components/WorkflowPrintContainer/component/audit/index.d.ts +7 -0
- package/dist/components/WorkflowPrintContainer/component/audit/index.js +88 -0
- package/dist/components/WorkflowPrintContainer/component/previewTable/component/TableList.d.ts +9 -0
- package/dist/components/WorkflowPrintContainer/component/previewTable/component/TableList.js +53 -0
- package/dist/components/WorkflowPrintContainer/component/previewTable/index.d.ts +11 -0
- package/dist/components/WorkflowPrintContainer/component/previewTable/index.js +60 -0
- package/dist/components/WorkflowPrintContainer/component/send/component/TableList.d.ts +9 -0
- package/dist/components/WorkflowPrintContainer/component/send/component/TableList.js +50 -0
- package/dist/components/WorkflowPrintContainer/component/send/index.d.ts +9 -0
- package/dist/components/WorkflowPrintContainer/component/send/index.js +92 -0
- package/dist/components/WorkflowPrintContainer/component/trail/component/TableList.d.ts +12 -0
- package/dist/components/WorkflowPrintContainer/component/trail/component/TableList.js +282 -0
- package/dist/components/WorkflowPrintContainer/component/trail/index.d.ts +11 -0
- package/dist/components/WorkflowPrintContainer/component/trail/index.js +56 -0
- package/dist/components/WorkflowPrintContainer/images.d.ts +2 -0
- package/dist/components/WorkflowPrintContainer/images.js +2 -0
- package/dist/components/WorkflowPrintContainer/index.d.ts +2 -0
- package/dist/components/WorkflowPrintContainer/index.js +2 -0
- package/dist/components/WorkflowPrintContainer/service.d.ts +14 -0
- package/dist/components/WorkflowPrintContainer/service.js +101 -0
- package/dist/components/WorkflowPrintContainer/usePagination.d.ts +14 -0
- package/dist/components/WorkflowPrintContainer/usePagination.js +22 -0
- package/dist/components/WorkflowPrintContainer/workflow-print-container.d.ts +100 -0
- package/dist/components/WorkflowPrintContainer/workflow-print-container.js +236 -0
- package/dist/components/ZtIcon/index.js +2 -0
- package/dist/components/business/Analyse/index.js +12 -11
- package/dist/components/business/CodeQuery/component/SearchForm.js +3 -2
- package/dist/components/business/CodeQuery/component/TableList.js +5 -4
- package/dist/components/business/CodeQuery/hooks.js +2 -1
- package/dist/components/business/CodeQuery/index.js +2 -1
- package/dist/components/business/Common/UserForgetPassword/index.js +36 -28
- package/dist/components/business/Common/UserInfo/component/MakingForm.js +11 -10
- package/dist/components/business/Common/UserInfo/index.js +5 -4
- package/dist/components/business/Common/UserPassword/index.js +14 -11
- package/dist/components/business/Common/validatePassword.d.ts +1 -1
- package/dist/components/business/Common/validatePassword.js +17 -7
- package/dist/components/business/DetailCard/index.js +7 -6
- package/dist/components/business/DetailHeader/index.js +7 -6
- package/dist/components/business/DetailList/index.js +5 -4
- package/dist/components/business/DgColumns/index.js +12 -11
- package/dist/components/business/ExportButton/index.js +6 -5
- package/dist/components/business/Footer/index.js +4 -1
- package/dist/components/business/GridList/item.d.ts +1 -1
- package/dist/components/business/List/item.d.ts +1 -1
- package/dist/components/business/NewList/item.d.ts +1 -1
- package/dist/components/business/NewList/item.js +1 -1
- package/dist/components/business/OperationBtnGroup/index.js +17 -16
- package/dist/components/business/SearchContainer/hooks/useDynamic.d.ts +2 -1
- package/dist/components/business/SearchContainer/hooks/useDynamic.js +6 -3
- package/dist/components/business/SearchContainer/hooks/useToggle.d.ts +1 -1
- package/dist/components/business/SearchContainer/hooks/useToggle.js +31 -12
- package/dist/components/business/SearchContainer/record-common-item.d.ts +14 -0
- package/dist/components/business/SearchContainer/record-common-item.js +83 -0
- package/dist/components/business/SearchContainer/record-common-list.d.ts +3 -0
- package/dist/components/business/SearchContainer/record-common-list.js +95 -0
- package/dist/components/business/SearchContainer/search-container.d.ts +22 -0
- package/dist/components/business/SearchContainer/search-container.js +66 -3
- package/dist/components/business/SearchContainer/search-drawer.d.ts +1 -0
- package/dist/components/business/SearchContainer/search-drawer.js +167 -13
- package/dist/components/business/SearchContainer/search-item.js +48 -5
- package/dist/components/business/SearchContainer/search-left.d.ts +8 -0
- package/dist/components/business/SearchContainer/search-left.js +105 -68
- package/dist/components/business/SearchContainer/search-right.d.ts +4 -0
- package/dist/components/business/SearchContainer/search-right.js +62 -5
- package/dist/components/business/SearchContainer/useRecordCommonInit.d.ts +18 -0
- package/dist/components/business/SearchContainer/useRecordCommonInit.js +258 -0
- package/dist/components/business/SearchContainer/useRecordCommonSearch.d.ts +8 -0
- package/dist/components/business/SearchContainer/useRecordCommonSearch.js +145 -0
- package/dist/components/business/SearchContainer/useRecordCommonSearchContext.d.ts +37 -0
- package/dist/components/business/SearchContainer/useRecordCommonSearchContext.js +8 -0
- package/dist/components/business/SearchContainer/useTemplate.d.ts +20 -0
- package/dist/components/business/SearchContainer/useTemplate.js +347 -0
- package/dist/components/business/Signatures/components/AttachOperation.js +7 -6
- package/dist/components/business/Signatures/components/CodeModal.d.ts +3 -0
- package/dist/components/business/Signatures/components/CodeModal.js +157 -0
- package/dist/components/business/Signatures/components/CompareResult.js +7 -6
- package/dist/components/business/Signatures/components/DetailTable.js +37 -34
- package/dist/components/business/Signatures/components/QunjSeal.js +5 -4
- package/dist/components/business/Signatures/components/SealCheckbox.js +3 -2
- package/dist/components/business/Signatures/components/TemplateAttach.js +2 -1
- package/dist/components/business/Signatures/index.js +64 -53
- package/dist/components/business/SortList/sort-drawer.js +5 -4
- package/dist/components/business/Template/index.js +11 -10
- package/dist/components/electron-signatures/content.d.ts +9 -0
- package/dist/components/electron-signatures/content.js +1146 -0
- package/dist/components/electron-signatures/demoComponents/coUseDetail.d.ts +8 -0
- package/dist/components/electron-signatures/demoComponents/coUseDetail.js +255 -0
- package/dist/components/electron-signatures/demoComponents/data.d.ts +58 -0
- package/dist/components/electron-signatures/demoComponents/data.js +1307 -0
- package/dist/components/electron-signatures/demoComponents/detail.d.ts +6 -0
- package/dist/components/electron-signatures/demoComponents/detail.js +283 -0
- package/dist/components/electron-signatures/demoComponents/index.d.ts +2 -0
- package/dist/components/electron-signatures/demoComponents/index.js +30 -0
- package/dist/components/electron-signatures/demoComponents/jgqrd.d.ts +6 -0
- package/dist/components/electron-signatures/demoComponents/jgqrd.js +135 -0
- package/dist/components/electron-signatures/demoComponents/making.d.ts +6 -0
- package/dist/components/electron-signatures/demoComponents/making.js +211 -0
- package/dist/components/electron-signatures/demoComponents/makingData.d.ts +675 -0
- package/dist/components/electron-signatures/demoComponents/makingData.js +1178 -0
- package/dist/components/electron-signatures/demoComponents/newDetail.d.ts +6 -0
- package/dist/components/electron-signatures/demoComponents/newDetail.js +283 -0
- package/dist/components/electron-signatures/demoComponents/preview.d.ts +3 -0
- package/dist/components/electron-signatures/demoComponents/preview.js +9 -0
- package/dist/components/electron-signatures/demoComponents/singleQjDetail.d.ts +6 -0
- package/dist/components/electron-signatures/demoComponents/singleQjDetail.js +530 -0
- package/dist/components/electron-signatures/demoComponents/singleQjMaking.d.ts +6 -0
- package/dist/components/electron-signatures/demoComponents/singleQjMaking.js +219 -0
- package/dist/components/electron-signatures/demoComponents/test.d.ts +6 -0
- package/dist/components/electron-signatures/demoComponents/test.js +119 -0
- package/dist/components/electron-signatures/dgComponents/contract-comparison.d.ts +39 -0
- package/dist/components/electron-signatures/dgComponents/contract-comparison.js +53 -0
- package/dist/components/electron-signatures/dgComponents/file-comparison-btn.d.ts +11 -0
- package/dist/components/electron-signatures/dgComponents/file-comparison-btn.js +180 -0
- package/dist/components/electron-signatures/dgComponents/new-contract-comparison.d.ts +45 -0
- package/dist/components/electron-signatures/dgComponents/new-contract-comparison.js +68 -0
- package/dist/components/electron-signatures/dgComponents/useContractColumns.d.ts +21 -0
- package/dist/components/electron-signatures/dgComponents/useContractColumns.js +171 -0
- package/dist/components/electron-signatures/electron-signatures-fragment.d.ts +8 -0
- package/dist/components/electron-signatures/electron-signatures-fragment.js +392 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-batch-download.d.ts +52 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-batch-download.js +509 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-detail.d.ts +8 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-detail.js +59 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-download.d.ts +16 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-download.js +85 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-firstLevelPerson.d.ts +9 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-firstLevelPerson.js +16 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-item-detail.d.ts +15 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-item-detail.js +16 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-item.d.ts +20 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-item.js +47 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-list.d.ts +11 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-list.js +191 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-personal-sign.d.ts +35 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-personal-sign.js +39 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-setting.d.ts +15 -0
- package/dist/components/electron-signatures/electronComponents/electron-seal-setting.js +10 -0
- package/dist/components/electron-signatures/electronComponents/last-qys-modal.d.ts +7 -0
- package/dist/components/electron-signatures/electronComponents/last-qys-modal.js +42 -0
- package/dist/components/electron-signatures/electronComponents/useCheckedSealInfoList.d.ts +3 -0
- package/dist/components/electron-signatures/electronComponents/useCheckedSealInfoList.js +43 -0
- package/dist/components/electron-signatures/electronComponents/useElectronColumns.d.ts +30 -0
- package/dist/components/electron-signatures/electronComponents/useElectronColumns.js +398 -0
- package/dist/components/electron-signatures/electronComponents/useFetchElectronData.d.ts +24 -0
- package/dist/components/electron-signatures/electronComponents/useFetchElectronData.js +254 -0
- package/dist/components/electron-signatures/electronComponents/useGetDeptInfo.d.ts +3 -0
- package/dist/components/electron-signatures/electronComponents/useGetDeptInfo.js +35 -0
- package/dist/components/electron-signatures/fileComponents/file-operation.d.ts +7 -0
- package/dist/components/electron-signatures/fileComponents/file-operation.js +67 -0
- package/dist/components/electron-signatures/fileComponents/file-type-select.d.ts +12 -0
- package/dist/components/electron-signatures/fileComponents/file-type-select.js +10 -0
- package/dist/components/electron-signatures/fileComponents/file-upload.d.ts +11 -0
- package/dist/components/electron-signatures/fileComponents/file-upload.js +146 -0
- package/dist/components/electron-signatures/fileComponents/fileUtils.d.ts +17 -0
- package/dist/components/electron-signatures/fileComponents/fileUtils.js +36 -0
- package/dist/components/electron-signatures/fileComponents/new-file-operation.d.ts +10 -0
- package/dist/components/electron-signatures/fileComponents/new-file-operation.js +73 -0
- package/dist/components/electron-signatures/fileComponents/useFetchFileTypeData.d.ts +13 -0
- package/dist/components/electron-signatures/fileComponents/useFetchFileTypeData.js +43 -0
- package/dist/components/electron-signatures/fileComponents/useFileColumns.d.ts +38 -0
- package/dist/components/electron-signatures/fileComponents/useFileColumns.js +329 -0
- package/dist/components/electron-signatures/fileComponents/useFileTypeColumns.d.ts +19 -0
- package/dist/components/electron-signatures/fileComponents/useFileTypeColumns.js +72 -0
- package/dist/components/electron-signatures/hooks/useGetQjVerifyCode.d.ts +30 -0
- package/dist/components/electron-signatures/hooks/useGetQjVerifyCode.js +132 -0
- package/dist/components/electron-signatures/hooks/useMergeRecords.d.ts +17 -0
- package/dist/components/electron-signatures/hooks/useMergeRecords.js +49 -0
- package/dist/components/electron-signatures/hooks/useParseElectronListData.d.ts +49 -0
- package/dist/components/electron-signatures/hooks/useParseElectronListData.js +111 -0
- package/dist/components/electron-signatures/hooks/useParseElectronSetting.d.ts +111 -0
- package/dist/components/electron-signatures/hooks/useParseElectronSetting.js +436 -0
- package/dist/components/electron-signatures/hooks/useParseIsNeedElectronData.d.ts +40 -0
- package/dist/components/electron-signatures/hooks/useParseIsNeedElectronData.js +139 -0
- package/dist/components/electron-signatures/hooks/useParseIsNeedQunjData.d.ts +36 -0
- package/dist/components/electron-signatures/hooks/useParseIsNeedQunjData.js +48 -0
- package/dist/components/electron-signatures/hooks/useParseQunjListData.d.ts +56 -0
- package/dist/components/electron-signatures/hooks/useParseQunjListData.js +204 -0
- package/dist/components/electron-signatures/hooks/useParseQunjSingleData.d.ts +34 -0
- package/dist/components/electron-signatures/hooks/useParseQunjSingleData.js +110 -0
- package/dist/components/electron-signatures/hooks/useParseRecords.d.ts +65 -0
- package/dist/components/electron-signatures/hooks/useParseRecords.js +165 -0
- package/dist/components/electron-signatures/index.d.ts +15 -0
- package/dist/components/electron-signatures/index.js +63 -0
- package/dist/components/electron-signatures/interface.d.ts +865 -0
- package/dist/components/electron-signatures/interface.js +57 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-apply.d.ts +6 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-apply.js +8 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-check.d.ts +21 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-check.js +41 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-detail.d.ts +35 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-detail.js +267 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-list.d.ts +24 -0
- package/dist/components/electron-signatures/qunjComponents/qunj-list.js +355 -0
- package/dist/components/electron-signatures/qunjComponents/useFetchQunjData.d.ts +20 -0
- package/dist/components/electron-signatures/qunjComponents/useFetchQunjData.js +66 -0
- package/dist/components/electron-signatures/qunjComponents/useQunjColumns.d.ts +36 -0
- package/dist/components/electron-signatures/qunjComponents/useQunjColumns.js +321 -0
- package/dist/components/electron-signatures/translateComponents/TranslateButton.d.ts +10 -0
- package/dist/components/electron-signatures/translateComponents/TranslateButton.js +44 -0
- package/dist/components/electron-signatures/translateComponents/useTranslateCom.d.ts +22 -0
- package/dist/components/electron-signatures/translateComponents/useTranslateCom.js +50 -0
- package/dist/components/electron-signatures/utils.d.ts +26 -0
- package/dist/components/electron-signatures/utils.js +67 -0
- package/dist/components/utils/MyStorage.d.ts +36 -0
- package/dist/components/utils/MyStorage.js +120 -0
- package/dist/components/utils/ZtxkContext.d.ts +67 -0
- package/dist/components/utils/ZtxkContext.js +20 -0
- package/dist/components/utils/checkSealCoUse.d.ts +16 -0
- package/dist/components/utils/checkSealCoUse.js +83 -0
- package/dist/components/utils/fetch.d.ts +10 -0
- package/dist/components/utils/fetch.js +119 -0
- package/dist/components/utils/index.d.ts +9 -0
- package/dist/components/utils/index.js +11 -0
- package/dist/components/utils/processNumber.d.ts +12 -0
- package/dist/components/utils/processNumber.js +106 -0
- package/dist/components/utils/upload.js +6 -3
- package/dist/components/utils/useBaseContext.d.ts +23 -0
- package/dist/components/utils/useBaseContext.js +31 -0
- package/dist/components/utils/useMemoizedFn.d.ts +4 -0
- package/dist/components/utils/useMemoizedFn.js +19 -0
- package/dist/components/utils/usePrevious.d.ts +3 -0
- package/dist/components/utils/usePrevious.js +13 -0
- package/dist/constants.d.ts +1 -1
- package/dist/constants.js +1 -1
- package/dist/index.css +2205 -58
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +12 -1
- package/dist/index.js +255 -86
- package/dist/locales/en-US.json +828 -0
- package/dist/locales/zh-CN.json +828 -0
- package/dist/request.js +7 -6
- package/package.json +13 -4
|
@@ -0,0 +1,850 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
12
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
13
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
14
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
15
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
16
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
17
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
18
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
19
|
+
});
|
|
20
|
+
};
|
|
21
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
22
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
23
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
24
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
25
|
+
function step(op) {
|
|
26
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
27
|
+
while (_) try {
|
|
28
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
29
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
30
|
+
switch (op[0]) {
|
|
31
|
+
case 0: case 1: t = op; break;
|
|
32
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
33
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
34
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
35
|
+
default:
|
|
36
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
37
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
38
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
39
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
40
|
+
if (t[2]) _.ops.pop();
|
|
41
|
+
_.trys.pop(); continue;
|
|
42
|
+
}
|
|
43
|
+
op = body.call(thisArg, _);
|
|
44
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
45
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
import React, { useState, useRef, useCallback } from 'react';
|
|
49
|
+
// 注意:直接从组件源文件导入,避免经过入口 index 形成循环依赖
|
|
50
|
+
import Button from '../../components/Button';
|
|
51
|
+
import message from '../../components/basic/message';
|
|
52
|
+
import Table from '../../components/Table';
|
|
53
|
+
import EnhanceSelect from '../../components/EnhanceSelect';
|
|
54
|
+
import DatePicker from '../../components/DatePicker';
|
|
55
|
+
import NumberCase from '../../components/NumberCase';
|
|
56
|
+
import dayjs from 'dayjs';
|
|
57
|
+
import BusinessListDemo from './BusinessListDemo';
|
|
58
|
+
import BusinessMemberDemo from './BusinessMemberDemo';
|
|
59
|
+
var sectionStyle = { margin: '32px 0 8px' };
|
|
60
|
+
var titleStyle = { fontSize: 16, fontWeight: 600 };
|
|
61
|
+
var descStyle = {
|
|
62
|
+
margin: '4px 0 12px',
|
|
63
|
+
fontSize: 12,
|
|
64
|
+
color: '#999',
|
|
65
|
+
lineHeight: '20px',
|
|
66
|
+
};
|
|
67
|
+
/* ==================== 一、编辑模式表格(多级表头) ==================== */
|
|
68
|
+
// 模拟物料下拉数据
|
|
69
|
+
var MATERIAL_LIST = [
|
|
70
|
+
{ id: '1', code: 'WL-001', name: '钢板 Q235B' },
|
|
71
|
+
{ id: '2', code: 'WL-002', name: '铝板 5052' },
|
|
72
|
+
{ id: '3', code: 'WL-003', name: '铜排 T2' },
|
|
73
|
+
];
|
|
74
|
+
var createRow = function () { return ({
|
|
75
|
+
id: Date.now() + "-" + Math.random(),
|
|
76
|
+
materialId: undefined,
|
|
77
|
+
materialName: '',
|
|
78
|
+
quantity: undefined,
|
|
79
|
+
price: undefined,
|
|
80
|
+
deliveryTime: '',
|
|
81
|
+
remark: '',
|
|
82
|
+
customerName: '',
|
|
83
|
+
warehouse: '',
|
|
84
|
+
weight: undefined,
|
|
85
|
+
createUserName: '',
|
|
86
|
+
}); };
|
|
87
|
+
/**
|
|
88
|
+
* 编辑模式表格
|
|
89
|
+
*
|
|
90
|
+
* 关键配置:
|
|
91
|
+
* 1. 列编辑:editable: true + editableConfig(type 支持 input / select /
|
|
92
|
+
* inputNumber / textArea),配合 onEditableSave 回调把单元格值合并回行数据;
|
|
93
|
+
* 2. 自定义编辑控件:render 中放受控组件(EnhanceSelect、DatePicker 等),
|
|
94
|
+
* 变更时同样调用 onEditableSave 合并行数据;
|
|
95
|
+
* 3. 校验:required + validate 配置的列参与校验,
|
|
96
|
+
* 通过 tableHandleRef.current.validate() 主动触发;
|
|
97
|
+
* 4. 多级表头:列配置 children 即可,编辑列放在 children 内同样生效;
|
|
98
|
+
* 5. 增删行:传入 onAddAndDelHandle 后表格自动生成操作列。
|
|
99
|
+
*/
|
|
100
|
+
var EditTableDemo = function () {
|
|
101
|
+
var _a = useState(function () { return [
|
|
102
|
+
createRow(),
|
|
103
|
+
createRow(),
|
|
104
|
+
]; }), records = _a[0], setRecords = _a[1];
|
|
105
|
+
var recordsRef = useRef(records);
|
|
106
|
+
var tableHandleRef = useRef();
|
|
107
|
+
// 保持 ref 指向最新数据,供异步回调读取
|
|
108
|
+
recordsRef.current = records;
|
|
109
|
+
/**
|
|
110
|
+
* @description 单元格编辑保存:合并新值到对应行
|
|
111
|
+
*/
|
|
112
|
+
var onEditableSaveHandle = useCallback(function (record, index, _dataIndex) {
|
|
113
|
+
var _a;
|
|
114
|
+
if (_dataIndex === void 0) { _dataIndex = ''; }
|
|
115
|
+
if (typeof index !== 'number') {
|
|
116
|
+
return;
|
|
117
|
+
}
|
|
118
|
+
var newRecords = recordsRef.current.slice();
|
|
119
|
+
var item = newRecords[index];
|
|
120
|
+
newRecords.splice(index, 1, _dataIndex
|
|
121
|
+
? __assign(__assign(__assign({}, record), item), (_a = {}, _a[_dataIndex] = record[_dataIndex], _a)) : __assign(__assign({}, item), record));
|
|
122
|
+
setRecords(newRecords);
|
|
123
|
+
}, []);
|
|
124
|
+
/**
|
|
125
|
+
* @description 新增/删除行(传入 Table 后自动生成操作列)
|
|
126
|
+
*/
|
|
127
|
+
var onAddAndDelHandle = useCallback(function (type, index) {
|
|
128
|
+
var newRecords = recordsRef.current.slice();
|
|
129
|
+
if (type === 'add') {
|
|
130
|
+
newRecords.splice(index + 1, 0, __assign(__assign({}, createRow()), { _isNewData: true }));
|
|
131
|
+
}
|
|
132
|
+
else if (type === 'del') {
|
|
133
|
+
if (newRecords.length === 1) {
|
|
134
|
+
newRecords.splice(index, 1, __assign(__assign({}, createRow()), { _isNewData: true }));
|
|
135
|
+
}
|
|
136
|
+
else {
|
|
137
|
+
newRecords.splice(index, 1);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
setRecords(newRecords);
|
|
141
|
+
}, []);
|
|
142
|
+
/**
|
|
143
|
+
* @description 校验全部可编辑单元格
|
|
144
|
+
*/
|
|
145
|
+
var onValidateHandle = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
146
|
+
var err_1, errorFields;
|
|
147
|
+
var _a;
|
|
148
|
+
return __generator(this, function (_b) {
|
|
149
|
+
switch (_b.label) {
|
|
150
|
+
case 0:
|
|
151
|
+
_b.trys.push([0, 2, , 3]);
|
|
152
|
+
return [4 /*yield*/, ((_a = tableHandleRef.current) === null || _a === void 0 ? void 0 : _a.validate())];
|
|
153
|
+
case 1:
|
|
154
|
+
_b.sent();
|
|
155
|
+
message.success('校验通过');
|
|
156
|
+
return [3 /*break*/, 3];
|
|
157
|
+
case 2:
|
|
158
|
+
err_1 = _b.sent();
|
|
159
|
+
errorFields = (err_1 || {}).errorFields;
|
|
160
|
+
if (errorFields) {
|
|
161
|
+
message.warning(errorFields[0].errors + '');
|
|
162
|
+
}
|
|
163
|
+
return [3 /*break*/, 3];
|
|
164
|
+
case 3: return [2 /*return*/];
|
|
165
|
+
}
|
|
166
|
+
});
|
|
167
|
+
}); }, []);
|
|
168
|
+
var columns = [
|
|
169
|
+
{
|
|
170
|
+
title: '序号',
|
|
171
|
+
width: 62,
|
|
172
|
+
fixed: 'left',
|
|
173
|
+
align: 'center',
|
|
174
|
+
key: 'index',
|
|
175
|
+
render: function (_text, _record, index) { return "" + (index + 1); },
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
title: '物料信息',
|
|
179
|
+
children: [
|
|
180
|
+
{
|
|
181
|
+
title: '物料编码',
|
|
182
|
+
width: 180,
|
|
183
|
+
dataIndex: 'materialId',
|
|
184
|
+
key: 'materialId',
|
|
185
|
+
// 自定义编辑控件:受控组件 + onEditableSave 合并行数据
|
|
186
|
+
render: function (text, _record, index) { return (React.createElement(EnhanceSelect, { value: text, list: MATERIAL_LIST, dataKey: "id", titleKey: "code", style: { width: '100%' }, placeholder: "\u8BF7\u9009\u62E9\u7269\u6599", onChange: function (value, _option, fullData) {
|
|
187
|
+
onEditableSaveHandle({ materialId: value, materialName: fullData === null || fullData === void 0 ? void 0 : fullData.name }, index);
|
|
188
|
+
} })); },
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
title: '物料名称',
|
|
192
|
+
width: 140,
|
|
193
|
+
dataIndex: 'materialName',
|
|
194
|
+
key: 'materialName',
|
|
195
|
+
},
|
|
196
|
+
],
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
title: '数量金额',
|
|
200
|
+
children: [
|
|
201
|
+
{
|
|
202
|
+
title: '数量',
|
|
203
|
+
width: 160,
|
|
204
|
+
dataIndex: 'quantity',
|
|
205
|
+
key: 'quantity',
|
|
206
|
+
// 内置编辑单元格:数字输入,必填校验
|
|
207
|
+
editable: true,
|
|
208
|
+
required: true,
|
|
209
|
+
validate: {},
|
|
210
|
+
editableConfig: {
|
|
211
|
+
type: 'inputNumber',
|
|
212
|
+
precision: 0,
|
|
213
|
+
minHandle: function () { return 1; },
|
|
214
|
+
maxHandle: function () { return 99999; },
|
|
215
|
+
},
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
title: '单价',
|
|
219
|
+
width: 160,
|
|
220
|
+
dataIndex: 'price',
|
|
221
|
+
key: 'price',
|
|
222
|
+
editable: true,
|
|
223
|
+
validate: {},
|
|
224
|
+
editableConfig: {
|
|
225
|
+
type: 'inputNumber',
|
|
226
|
+
precision: 2,
|
|
227
|
+
minHandle: function () { return 0; },
|
|
228
|
+
maxHandle: function () { return 1000000; },
|
|
229
|
+
formatterType: 'currency',
|
|
230
|
+
},
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
title: '金额',
|
|
234
|
+
width: 120,
|
|
235
|
+
dataIndex: 'amount',
|
|
236
|
+
key: 'amount',
|
|
237
|
+
align: 'right',
|
|
238
|
+
// 只读计算列:数量 × 单价
|
|
239
|
+
render: function (_text, record) {
|
|
240
|
+
var amount = (Number(record.quantity) || 0) * (Number(record.price) || 0);
|
|
241
|
+
return amount ? React.createElement(NumberCase, { num: amount }, amount) : '';
|
|
242
|
+
},
|
|
243
|
+
},
|
|
244
|
+
],
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
title: '其他',
|
|
248
|
+
children: [
|
|
249
|
+
{
|
|
250
|
+
title: '交货日期',
|
|
251
|
+
width: 160,
|
|
252
|
+
dataIndex: 'deliveryTime',
|
|
253
|
+
key: 'deliveryTime',
|
|
254
|
+
render: function (text, _record, index) { return (React.createElement(DatePicker, { value: text ? dayjs(text) : null, style: { width: '100%' }, onChange: function (value) {
|
|
255
|
+
onEditableSaveHandle({
|
|
256
|
+
deliveryTime: dayjs.isDayjs(value)
|
|
257
|
+
? value.format('YYYY-MM-DD')
|
|
258
|
+
: '',
|
|
259
|
+
}, index);
|
|
260
|
+
} })); },
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
title: '备注',
|
|
264
|
+
width: 200,
|
|
265
|
+
dataIndex: 'remark',
|
|
266
|
+
key: 'remark',
|
|
267
|
+
// 内置编辑单元格:多行文本
|
|
268
|
+
editable: true,
|
|
269
|
+
validate: {},
|
|
270
|
+
editableConfig: { type: 'textArea', rows: 1 },
|
|
271
|
+
},
|
|
272
|
+
],
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
title: '扩展信息',
|
|
276
|
+
children: [
|
|
277
|
+
{
|
|
278
|
+
title: '客户名称',
|
|
279
|
+
width: 180,
|
|
280
|
+
dataIndex: 'customerName',
|
|
281
|
+
key: 'customerName',
|
|
282
|
+
editable: true,
|
|
283
|
+
validate: {},
|
|
284
|
+
editableConfig: { type: 'input' },
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
title: '仓库',
|
|
288
|
+
width: 130,
|
|
289
|
+
dataIndex: 'warehouse',
|
|
290
|
+
key: 'warehouse',
|
|
291
|
+
editable: true,
|
|
292
|
+
validate: {},
|
|
293
|
+
editableConfig: { type: 'input' },
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
title: '重量(kg)',
|
|
297
|
+
width: 120,
|
|
298
|
+
dataIndex: 'weight',
|
|
299
|
+
key: 'weight',
|
|
300
|
+
align: 'right',
|
|
301
|
+
editable: true,
|
|
302
|
+
editableConfig: {
|
|
303
|
+
type: 'inputNumber',
|
|
304
|
+
precision: 2,
|
|
305
|
+
minHandle: function () { return 0; },
|
|
306
|
+
maxHandle: function () { return 999999; },
|
|
307
|
+
},
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
title: '创建人',
|
|
311
|
+
width: 110,
|
|
312
|
+
dataIndex: 'createUserName',
|
|
313
|
+
key: 'createUserName',
|
|
314
|
+
},
|
|
315
|
+
],
|
|
316
|
+
},
|
|
317
|
+
];
|
|
318
|
+
return (React.createElement("div", null,
|
|
319
|
+
React.createElement("div", { style: { marginBottom: 12 } },
|
|
320
|
+
React.createElement(Button, { type: "primary", onClick: onValidateHandle }, "\u6821\u9A8C"),
|
|
321
|
+
React.createElement(Button, { style: { marginLeft: 12 }, onClick: function () {
|
|
322
|
+
console.log('当前表格数据:', recordsRef.current);
|
|
323
|
+
} }, "\u83B7\u53D6\u6570\u636E")),
|
|
324
|
+
React.createElement(Table, { columns: columns, dataSource: records, rowKey: "id", scroll: { x: 2000 }, tableHandleRef: tableHandleRef,
|
|
325
|
+
// 编辑保存回调(editable 列与自定义编辑控件共用)
|
|
326
|
+
onEditableSave: onEditableSaveHandle,
|
|
327
|
+
// 传入后自动生成新增/删除行操作列
|
|
328
|
+
onAddAndDelHandle: onAddAndDelHandle })));
|
|
329
|
+
};
|
|
330
|
+
/* ==================== 二、详情模式表格(多级表头) ==================== */
|
|
331
|
+
var DETAIL_DATA = [
|
|
332
|
+
{
|
|
333
|
+
id: '1',
|
|
334
|
+
orderNo: 'SO-2026-0001',
|
|
335
|
+
materialCode: 'WL-001',
|
|
336
|
+
materialName: '钢板 Q235B',
|
|
337
|
+
quantity: 1200,
|
|
338
|
+
price: 4.35,
|
|
339
|
+
amount: 5220,
|
|
340
|
+
deliveryTime: '2026-10-30',
|
|
341
|
+
status: '已提交',
|
|
342
|
+
warehouse: '一号仓库',
|
|
343
|
+
weight: 8600.5,
|
|
344
|
+
taxRate: 13,
|
|
345
|
+
taxAmount: 678.6,
|
|
346
|
+
customerName: '上海宏图机械有限公司',
|
|
347
|
+
createUserName: '张三',
|
|
348
|
+
createDate: '2026-10-18',
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
id: '2',
|
|
352
|
+
orderNo: 'SO-2026-0002',
|
|
353
|
+
materialCode: 'WL-002',
|
|
354
|
+
materialName: '铝板 5052',
|
|
355
|
+
quantity: 800,
|
|
356
|
+
price: 18.6,
|
|
357
|
+
amount: 14880,
|
|
358
|
+
deliveryTime: '2026-11-05',
|
|
359
|
+
status: '草稿',
|
|
360
|
+
warehouse: '二号仓库',
|
|
361
|
+
weight: 4200.25,
|
|
362
|
+
taxRate: 13,
|
|
363
|
+
taxAmount: 1934.4,
|
|
364
|
+
customerName: '深圳华越电子科技有限公司',
|
|
365
|
+
createUserName: '李四',
|
|
366
|
+
createDate: '2026-10-20',
|
|
367
|
+
},
|
|
368
|
+
{
|
|
369
|
+
id: '3',
|
|
370
|
+
orderNo: 'SO-2026-0003',
|
|
371
|
+
materialCode: 'WL-003',
|
|
372
|
+
materialName: '铜排 T2',
|
|
373
|
+
quantity: 300,
|
|
374
|
+
price: 66.2,
|
|
375
|
+
amount: 19860,
|
|
376
|
+
deliveryTime: '2026-11-15',
|
|
377
|
+
status: '已提交',
|
|
378
|
+
warehouse: '三号仓库',
|
|
379
|
+
weight: 1560,
|
|
380
|
+
taxRate: 9,
|
|
381
|
+
taxAmount: 1787.4,
|
|
382
|
+
customerName: '宁波远大电气成套设备有限公司',
|
|
383
|
+
createUserName: '王五',
|
|
384
|
+
createDate: '2026-10-22',
|
|
385
|
+
},
|
|
386
|
+
];
|
|
387
|
+
/**
|
|
388
|
+
* 详情模式表格
|
|
389
|
+
*
|
|
390
|
+
* 与编辑表格的区别:
|
|
391
|
+
* 1. 纯展示,列不配置 editable,render 只做格式化(千分符、日期等);
|
|
392
|
+
* 2. 多级表头用 children 分组,与编辑表格写法一致;
|
|
393
|
+
* 3. summaryConfig 配置小计/合计行;
|
|
394
|
+
* 4. showColumnDynamic + dynamicStorageKey 支持用户自定义显示列并持久化。
|
|
395
|
+
*/
|
|
396
|
+
var DetailTableDemo = function () {
|
|
397
|
+
var columns = [
|
|
398
|
+
{
|
|
399
|
+
title: '序号',
|
|
400
|
+
width: 62,
|
|
401
|
+
align: 'center',
|
|
402
|
+
key: 'index',
|
|
403
|
+
render: function (_text, _record, index) { return "" + (index + 1); },
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
title: '订单信息',
|
|
407
|
+
children: [
|
|
408
|
+
{
|
|
409
|
+
title: '订单号',
|
|
410
|
+
width: 150,
|
|
411
|
+
dataIndex: 'orderNo',
|
|
412
|
+
key: 'orderNo',
|
|
413
|
+
},
|
|
414
|
+
{
|
|
415
|
+
title: '单据状态',
|
|
416
|
+
width: 100,
|
|
417
|
+
dataIndex: 'status',
|
|
418
|
+
key: 'status',
|
|
419
|
+
},
|
|
420
|
+
],
|
|
421
|
+
},
|
|
422
|
+
{
|
|
423
|
+
title: '物料信息',
|
|
424
|
+
children: [
|
|
425
|
+
{
|
|
426
|
+
title: '物料编码',
|
|
427
|
+
width: 120,
|
|
428
|
+
dataIndex: 'materialCode',
|
|
429
|
+
key: 'materialCode',
|
|
430
|
+
},
|
|
431
|
+
{
|
|
432
|
+
title: '物料名称',
|
|
433
|
+
width: 140,
|
|
434
|
+
dataIndex: 'materialName',
|
|
435
|
+
key: 'materialName',
|
|
436
|
+
},
|
|
437
|
+
],
|
|
438
|
+
},
|
|
439
|
+
{
|
|
440
|
+
title: '数量金额',
|
|
441
|
+
children: [
|
|
442
|
+
{
|
|
443
|
+
title: '数量',
|
|
444
|
+
width: 100,
|
|
445
|
+
dataIndex: 'quantity',
|
|
446
|
+
key: 'quantity',
|
|
447
|
+
align: 'right',
|
|
448
|
+
},
|
|
449
|
+
{
|
|
450
|
+
// 三级表头示例:子分组「价格信息」(数量金额 > 价格信息 > 单价/金额)
|
|
451
|
+
title: '价格信息',
|
|
452
|
+
children: [
|
|
453
|
+
{
|
|
454
|
+
title: '单价',
|
|
455
|
+
width: 100,
|
|
456
|
+
dataIndex: 'price',
|
|
457
|
+
key: 'price',
|
|
458
|
+
align: 'right',
|
|
459
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
460
|
+
},
|
|
461
|
+
{
|
|
462
|
+
title: '金额',
|
|
463
|
+
width: 120,
|
|
464
|
+
dataIndex: 'amount',
|
|
465
|
+
key: 'amount',
|
|
466
|
+
align: 'right',
|
|
467
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
468
|
+
},
|
|
469
|
+
],
|
|
470
|
+
},
|
|
471
|
+
],
|
|
472
|
+
},
|
|
473
|
+
{
|
|
474
|
+
title: '交货日期',
|
|
475
|
+
width: 120,
|
|
476
|
+
dataIndex: 'deliveryTime',
|
|
477
|
+
key: 'deliveryTime',
|
|
478
|
+
align: 'center',
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
title: '仓储信息',
|
|
482
|
+
children: [
|
|
483
|
+
{
|
|
484
|
+
title: '仓库',
|
|
485
|
+
width: 130,
|
|
486
|
+
dataIndex: 'warehouse',
|
|
487
|
+
key: 'warehouse',
|
|
488
|
+
},
|
|
489
|
+
{
|
|
490
|
+
title: '重量(kg)',
|
|
491
|
+
width: 120,
|
|
492
|
+
dataIndex: 'weight',
|
|
493
|
+
key: 'weight',
|
|
494
|
+
align: 'right',
|
|
495
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
496
|
+
},
|
|
497
|
+
],
|
|
498
|
+
},
|
|
499
|
+
{
|
|
500
|
+
title: '税务信息',
|
|
501
|
+
children: [
|
|
502
|
+
{
|
|
503
|
+
title: '税率(%)',
|
|
504
|
+
width: 100,
|
|
505
|
+
dataIndex: 'taxRate',
|
|
506
|
+
key: 'taxRate',
|
|
507
|
+
align: 'right',
|
|
508
|
+
},
|
|
509
|
+
{
|
|
510
|
+
title: '税额',
|
|
511
|
+
width: 120,
|
|
512
|
+
dataIndex: 'taxAmount',
|
|
513
|
+
key: 'taxAmount',
|
|
514
|
+
align: 'right',
|
|
515
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
516
|
+
},
|
|
517
|
+
],
|
|
518
|
+
},
|
|
519
|
+
{
|
|
520
|
+
title: '客户名称',
|
|
521
|
+
width: 180,
|
|
522
|
+
dataIndex: 'customerName',
|
|
523
|
+
key: 'customerName',
|
|
524
|
+
},
|
|
525
|
+
{
|
|
526
|
+
title: '创建人',
|
|
527
|
+
width: 110,
|
|
528
|
+
dataIndex: 'createUserName',
|
|
529
|
+
key: 'createUserName',
|
|
530
|
+
},
|
|
531
|
+
{
|
|
532
|
+
title: '创建日期',
|
|
533
|
+
width: 120,
|
|
534
|
+
dataIndex: 'createDate',
|
|
535
|
+
key: 'createDate',
|
|
536
|
+
align: 'center',
|
|
537
|
+
},
|
|
538
|
+
];
|
|
539
|
+
return (React.createElement(Table, { dataSource: DETAIL_DATA, columns: columns, rowKey: "id", scroll: { x: 2200 }, showColumnDynamic: true, showColumnDynamicKey: "ui-table-detail", summaryConfig: [
|
|
540
|
+
{
|
|
541
|
+
type: 'subtotal',
|
|
542
|
+
fields: ['quantity', 'amount'],
|
|
543
|
+
title: '小计',
|
|
544
|
+
},
|
|
545
|
+
] }));
|
|
546
|
+
};
|
|
547
|
+
/* ==================== 三、平级表头表格(排序 + 过滤) ==================== */
|
|
548
|
+
var FLAT_DATA = [
|
|
549
|
+
{
|
|
550
|
+
id: '1',
|
|
551
|
+
orderNo: 'SO-2026-0001',
|
|
552
|
+
materialCode: 'WL-001',
|
|
553
|
+
materialName: '钢板 Q235B',
|
|
554
|
+
quantity: 1200,
|
|
555
|
+
price: 4.35,
|
|
556
|
+
amount: 5220,
|
|
557
|
+
deliveryTime: '2026-10-30',
|
|
558
|
+
status: '已提交',
|
|
559
|
+
warehouse: '一号仓库',
|
|
560
|
+
weight: 8600.5,
|
|
561
|
+
taxRate: 13,
|
|
562
|
+
taxAmount: 678.6,
|
|
563
|
+
customerName: '上海宏图机械有限公司',
|
|
564
|
+
createUserName: '张三',
|
|
565
|
+
createDate: '2026-10-18',
|
|
566
|
+
},
|
|
567
|
+
{
|
|
568
|
+
id: '2',
|
|
569
|
+
orderNo: 'SO-2026-0002',
|
|
570
|
+
materialCode: 'WL-002',
|
|
571
|
+
materialName: '铝板 5052',
|
|
572
|
+
quantity: 800,
|
|
573
|
+
price: 18.6,
|
|
574
|
+
amount: 14880,
|
|
575
|
+
deliveryTime: '2026-11-05',
|
|
576
|
+
status: '草稿',
|
|
577
|
+
warehouse: '二号仓库',
|
|
578
|
+
weight: 4200.25,
|
|
579
|
+
taxRate: 13,
|
|
580
|
+
taxAmount: 1934.4,
|
|
581
|
+
customerName: '深圳华越电子科技有限公司',
|
|
582
|
+
createUserName: '李四',
|
|
583
|
+
createDate: '2026-10-20',
|
|
584
|
+
},
|
|
585
|
+
{
|
|
586
|
+
id: '3',
|
|
587
|
+
orderNo: 'SO-2026-0003',
|
|
588
|
+
materialCode: 'WL-003',
|
|
589
|
+
materialName: '铜排 T2',
|
|
590
|
+
quantity: 300,
|
|
591
|
+
price: 66.2,
|
|
592
|
+
amount: 19860,
|
|
593
|
+
deliveryTime: '2026-11-15',
|
|
594
|
+
status: '已提交',
|
|
595
|
+
warehouse: '三号仓库',
|
|
596
|
+
weight: 1560,
|
|
597
|
+
taxRate: 9,
|
|
598
|
+
taxAmount: 1787.4,
|
|
599
|
+
customerName: '宁波远大电气成套设备有限公司',
|
|
600
|
+
createUserName: '王五',
|
|
601
|
+
createDate: '2026-10-22',
|
|
602
|
+
},
|
|
603
|
+
{
|
|
604
|
+
id: '4',
|
|
605
|
+
orderNo: 'SO-2026-0004',
|
|
606
|
+
materialCode: 'WL-004',
|
|
607
|
+
materialName: '角钢 Q235',
|
|
608
|
+
quantity: 2600,
|
|
609
|
+
price: 3.9,
|
|
610
|
+
amount: 10140,
|
|
611
|
+
deliveryTime: '2026-10-20',
|
|
612
|
+
status: '已审批',
|
|
613
|
+
warehouse: '一号仓库',
|
|
614
|
+
weight: 12800,
|
|
615
|
+
taxRate: 13,
|
|
616
|
+
taxAmount: 1318.2,
|
|
617
|
+
customerName: '青岛重工程机械有限公司',
|
|
618
|
+
createUserName: '张三',
|
|
619
|
+
createDate: '2026-10-12',
|
|
620
|
+
},
|
|
621
|
+
{
|
|
622
|
+
id: '5',
|
|
623
|
+
orderNo: 'SO-2026-0005',
|
|
624
|
+
materialCode: 'WL-005',
|
|
625
|
+
materialName: '不锈钢管 304',
|
|
626
|
+
quantity: 500,
|
|
627
|
+
price: 25.8,
|
|
628
|
+
amount: 12900,
|
|
629
|
+
deliveryTime: '2026-12-01',
|
|
630
|
+
status: '草稿',
|
|
631
|
+
warehouse: '二号仓库',
|
|
632
|
+
weight: 3100.75,
|
|
633
|
+
taxRate: 13,
|
|
634
|
+
taxAmount: 1677,
|
|
635
|
+
customerName: '武汉长江管道安装工程有限公司',
|
|
636
|
+
createUserName: '赵六',
|
|
637
|
+
createDate: '2026-10-15',
|
|
638
|
+
},
|
|
639
|
+
{
|
|
640
|
+
id: '6',
|
|
641
|
+
orderNo: 'SO-2026-0006',
|
|
642
|
+
materialCode: 'WL-006',
|
|
643
|
+
materialName: '镀锌板 DX51D',
|
|
644
|
+
quantity: 1500,
|
|
645
|
+
price: 5.2,
|
|
646
|
+
amount: 7800,
|
|
647
|
+
deliveryTime: '2026-11-20',
|
|
648
|
+
status: '已审批',
|
|
649
|
+
warehouse: '三号仓库',
|
|
650
|
+
weight: 9500.4,
|
|
651
|
+
taxRate: 9,
|
|
652
|
+
taxAmount: 702,
|
|
653
|
+
customerName: '杭州永信金属制品有限公司',
|
|
654
|
+
createUserName: '李四',
|
|
655
|
+
createDate: '2026-10-19',
|
|
656
|
+
},
|
|
657
|
+
];
|
|
658
|
+
/**
|
|
659
|
+
* 平级表头表格(列表查询场景)
|
|
660
|
+
*
|
|
661
|
+
* 排序与过滤开关规则:
|
|
662
|
+
* 1. 全局默认:入口 ZtxkContext 配置 isTableSortEnabled / isTableFilterEnabled,
|
|
663
|
+
* 开启后所有列默认带排序与过滤;
|
|
664
|
+
* 2. 列级排序:sorter: true 默认比较;sorter: { compare } 自定义比较函数;
|
|
665
|
+
* sorter: false 单列关闭;
|
|
666
|
+
* 3. 列级过滤:isFilter: false 单列关闭(内置前端过滤支持
|
|
667
|
+
* 文本匹配、>、<、>=、<=、= 及 $0 表达式);
|
|
668
|
+
* 4. 整表关闭:Table props 传 isSort={false} / isFilter={false}。
|
|
669
|
+
*
|
|
670
|
+
* 排序图标的两种形态(悬浮显示 vs 一直显示):
|
|
671
|
+
* - sorter: true / sorter 函数 / 未配置 sorter(默认开启):
|
|
672
|
+
* 走内置 TableSortTitle,图标默认隐藏,悬浮表头时才显示;
|
|
673
|
+
* - sorter: { compare } 对象形式:走 antd 原生排序,
|
|
674
|
+
* 图标一直显示(当前排序列高亮)。
|
|
675
|
+
* 过滤图标默认悬浮显示,设置过滤条件后常显高亮。
|
|
676
|
+
*/
|
|
677
|
+
var FlatTableDemo = function () {
|
|
678
|
+
var columns = [
|
|
679
|
+
{
|
|
680
|
+
title: '序号',
|
|
681
|
+
width: 62,
|
|
682
|
+
align: 'center',
|
|
683
|
+
key: 'index',
|
|
684
|
+
// 序号列排序无意义,单列关闭
|
|
685
|
+
sorter: false,
|
|
686
|
+
render: function (_text, _record, index) { return "" + (index + 1); },
|
|
687
|
+
},
|
|
688
|
+
{
|
|
689
|
+
title: '订单号',
|
|
690
|
+
width: 150,
|
|
691
|
+
dataIndex: 'orderNo',
|
|
692
|
+
key: 'orderNo',
|
|
693
|
+
// 默认排序(依赖全局 isTableSortEnabled,也可显式 sorter: true)
|
|
694
|
+
sorter: true,
|
|
695
|
+
},
|
|
696
|
+
{
|
|
697
|
+
title: '单据状态',
|
|
698
|
+
width: 110,
|
|
699
|
+
dataIndex: 'status',
|
|
700
|
+
key: 'status',
|
|
701
|
+
sorter: true,
|
|
702
|
+
},
|
|
703
|
+
{
|
|
704
|
+
title: '物料编码',
|
|
705
|
+
width: 120,
|
|
706
|
+
dataIndex: 'materialCode',
|
|
707
|
+
key: 'materialCode',
|
|
708
|
+
},
|
|
709
|
+
{
|
|
710
|
+
title: '物料名称',
|
|
711
|
+
width: 150,
|
|
712
|
+
dataIndex: 'materialName',
|
|
713
|
+
key: 'materialName',
|
|
714
|
+
// 演示单列关闭过滤(表头无过滤图标)
|
|
715
|
+
isFilter: false,
|
|
716
|
+
},
|
|
717
|
+
{
|
|
718
|
+
title: '数量',
|
|
719
|
+
width: 110,
|
|
720
|
+
dataIndex: 'quantity',
|
|
721
|
+
key: 'quantity',
|
|
722
|
+
align: 'right',
|
|
723
|
+
// 自定义比较函数排序
|
|
724
|
+
sorter: {
|
|
725
|
+
compare: function (a, b) { return a.quantity - b.quantity; },
|
|
726
|
+
},
|
|
727
|
+
},
|
|
728
|
+
{
|
|
729
|
+
title: '单价',
|
|
730
|
+
width: 110,
|
|
731
|
+
dataIndex: 'price',
|
|
732
|
+
key: 'price',
|
|
733
|
+
align: 'right',
|
|
734
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
735
|
+
},
|
|
736
|
+
{
|
|
737
|
+
title: '金额',
|
|
738
|
+
width: 130,
|
|
739
|
+
dataIndex: 'amount',
|
|
740
|
+
key: 'amount',
|
|
741
|
+
align: 'right',
|
|
742
|
+
sorter: {
|
|
743
|
+
compare: function (a, b) { return a.amount - b.amount; },
|
|
744
|
+
},
|
|
745
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
746
|
+
},
|
|
747
|
+
{
|
|
748
|
+
title: '交货日期',
|
|
749
|
+
width: 120,
|
|
750
|
+
dataIndex: 'deliveryTime',
|
|
751
|
+
key: 'deliveryTime',
|
|
752
|
+
align: 'center',
|
|
753
|
+
// YYYY-MM-DD 格式字符串直接比较
|
|
754
|
+
sorter: {
|
|
755
|
+
compare: function (a, b) { return a.deliveryTime.localeCompare(b.deliveryTime); },
|
|
756
|
+
},
|
|
757
|
+
},
|
|
758
|
+
{
|
|
759
|
+
title: '仓库',
|
|
760
|
+
width: 130,
|
|
761
|
+
dataIndex: 'warehouse',
|
|
762
|
+
key: 'warehouse',
|
|
763
|
+
},
|
|
764
|
+
{
|
|
765
|
+
title: '重量(kg)',
|
|
766
|
+
width: 120,
|
|
767
|
+
dataIndex: 'weight',
|
|
768
|
+
key: 'weight',
|
|
769
|
+
align: 'right',
|
|
770
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
771
|
+
},
|
|
772
|
+
{
|
|
773
|
+
title: '税率(%)',
|
|
774
|
+
width: 100,
|
|
775
|
+
dataIndex: 'taxRate',
|
|
776
|
+
key: 'taxRate',
|
|
777
|
+
align: 'right',
|
|
778
|
+
},
|
|
779
|
+
{
|
|
780
|
+
title: '税额',
|
|
781
|
+
width: 120,
|
|
782
|
+
dataIndex: 'taxAmount',
|
|
783
|
+
key: 'taxAmount',
|
|
784
|
+
align: 'right',
|
|
785
|
+
render: function (text) { return React.createElement(NumberCase, { num: text }, text); },
|
|
786
|
+
},
|
|
787
|
+
{
|
|
788
|
+
title: '客户名称',
|
|
789
|
+
width: 200,
|
|
790
|
+
dataIndex: 'customerName',
|
|
791
|
+
key: 'customerName',
|
|
792
|
+
},
|
|
793
|
+
{
|
|
794
|
+
title: '创建人',
|
|
795
|
+
width: 110,
|
|
796
|
+
dataIndex: 'createUserName',
|
|
797
|
+
key: 'createUserName',
|
|
798
|
+
},
|
|
799
|
+
{
|
|
800
|
+
title: '创建日期',
|
|
801
|
+
width: 120,
|
|
802
|
+
dataIndex: 'createDate',
|
|
803
|
+
key: 'createDate',
|
|
804
|
+
align: 'center',
|
|
805
|
+
},
|
|
806
|
+
];
|
|
807
|
+
return (React.createElement(Table, { dataSource: FLAT_DATA, columns: columns, rowKey: "id", scroll: { x: 2200 },
|
|
808
|
+
// 用户自定义显示列并本地持久化
|
|
809
|
+
showColumnDynamic: true, showColumnDynamicKey: "ui-table-flat",
|
|
810
|
+
// 总计行(type: 'subtotal' 为小计、'total' 为总计)
|
|
811
|
+
summaryConfig: [
|
|
812
|
+
{
|
|
813
|
+
type: 'total',
|
|
814
|
+
fields: ['quantity', 'amount'],
|
|
815
|
+
title: '总计',
|
|
816
|
+
},
|
|
817
|
+
], isContextMenu: false }));
|
|
818
|
+
};
|
|
819
|
+
/**
|
|
820
|
+
* 表格组件模板
|
|
821
|
+
* 覆盖三类常用场景:
|
|
822
|
+
* 1. 编辑模式(多级表头):editable 列 + 自定义编辑控件 + 增删行 + 校验;
|
|
823
|
+
* 2. 详情模式(多级表头):纯展示 + 千分符 + 小计 + 动态列;
|
|
824
|
+
* 3. 平级表头:列表查询场景,表头排序 + 过滤。
|
|
825
|
+
*/
|
|
826
|
+
var TableDemo = function () {
|
|
827
|
+
return (React.createElement("div", { style: { padding: '10px 0 60px' } },
|
|
828
|
+
React.createElement("h2", null, "\u8868\u683C"),
|
|
829
|
+
React.createElement("div", { style: sectionStyle },
|
|
830
|
+
React.createElement("div", { style: titleStyle }, "\u4E00\u3001\u7F16\u8F91\u6A21\u5F0F\u8868\u683C\uFF08\u591A\u7EA7\u8868\u5934\uFF09"),
|
|
831
|
+
React.createElement("div", { style: descStyle }, "\u5185\u7F6E\u7F16\u8F91\u5217\uFF1Aeditable: true + editableConfig\uFF08type \u652F\u6301 input / select / inputNumber / textArea\uFF09\uFF0C\u5FC5\u586B\u6821\u9A8C\u7528 required + validate\uFF1B \u81EA\u5B9A\u4E49\u7F16\u8F91\u63A7\u4EF6\uFF1Arender \u91CC\u653E\u53D7\u63A7\u7EC4\u4EF6\uFF08EnhanceSelect\u3001DatePicker \u7B49\uFF09\uFF0C\u53D8\u66F4\u65F6\u8C03\u7528 onEditableSave \u5408\u5E76\u884C\u6570\u636E\uFF1B \u4E3B\u52A8\u6821\u9A8C\u7528 tableHandleRef.current.validate()\uFF1B\u4F20\u5165 onAddAndDelHandle \u81EA\u52A8\u751F\u6210\u589E\u5220\u884C\u64CD\u4F5C\u5217\uFF1B\u591A\u7EA7\u8868\u5934\u5728\u5217\u914D\u7F6E children \u4E2D\u5D4C\u5957\uFF0C\u7F16\u8F91\u5217\u540C\u6837\u751F\u6548\u3002"),
|
|
832
|
+
React.createElement(EditTableDemo, null)),
|
|
833
|
+
React.createElement("div", { style: sectionStyle },
|
|
834
|
+
React.createElement("div", { style: titleStyle }, "\u4E8C\u3001\u8BE6\u60C5\u6A21\u5F0F\u8868\u683C\uFF08\u591A\u7EA7\u8868\u5934\uFF09"),
|
|
835
|
+
React.createElement("div", { style: descStyle }, "\u7EAF\u5C55\u793A\uFF1A\u5217\u4E0D\u914D\u7F6E editable\uFF0Crender \u505A\u5343\u5206\u7B26\u7B49\u683C\u5F0F\u5316\uFF1BsummaryConfig \u914D\u7F6E\u5C0F\u8BA1/\u5408\u8BA1\u884C\uFF1BshowColumnDynamic + showColumnDynamicKey \u652F\u6301\u7528\u6237\u81EA\u5B9A\u4E49\u663E\u793A\u5217\u5E76\u672C\u5730\u6301\u4E45\u5316\u3002"),
|
|
836
|
+
React.createElement(DetailTableDemo, null)),
|
|
837
|
+
React.createElement("div", { style: sectionStyle },
|
|
838
|
+
React.createElement("div", { style: titleStyle }, "\u4E09\u3001\u5E73\u7EA7\u8868\u5934\u8868\u683C\uFF08\u6392\u5E8F + \u8FC7\u6EE4\uFF09"),
|
|
839
|
+
React.createElement("div", { style: descStyle }, "\u5217\u914D\u7F6E\u4E0D\u5199 children \u5373\u4E3A\u5E73\u7EA7\u8868\u5934\u3002\u6392\u5E8F\uFF1Asorter: true \u9ED8\u8BA4\u6BD4\u8F83\u3001sorter \u914D\u7F6E compare \u81EA\u5B9A\u4E49\u6BD4\u8F83\u51FD\u6570\u3001sorter: false \u5355\u5217\u5173\u95ED\uFF1B\u8FC7\u6EE4\uFF1A\u4F9D\u8D56\u5168\u5C40 isTableFilterEnabled\uFF0C\u5217\u914D\u7F6E isFilter: false \u5355\u5217\u5173\u95ED\uFF08\u5185\u7F6E\u8FC7\u6EE4\u652F\u6301\u6587\u672C\u5339\u914D\u3001\u5927\u4E8E/\u5C0F\u4E8E/\u7B49\u4E8E\u53CA $0 \u8868\u8FBE\u5F0F\uFF09\uFF1B\u6574\u8868\u5173\u95ED\u7528 Table props \u7684 isSort / isFilter\u3002\u6CE8\u610F\u6392\u5E8F\u56FE\u6807\u7684\u4E24\u79CD\u5F62\u6001\uFF1Asorter: true / sorter \u51FD\u6570 / \u9ED8\u8BA4\u5F00\u542F\u7684\u5217\u8D70\u5185\u7F6E TableSortTitle\uFF0C\u56FE\u6807\u60AC\u6D6E\u8868\u5934\u65F6\u624D\u663E\u793A\uFF1B sorter \u914D\u7F6E compare \u5BF9\u8C61\u7684\u5217\u8D70 antd \u539F\u751F\u6392\u5E8F\uFF0C\u56FE\u6807\u4E00\u76F4\u663E\u793A\u3002summaryConfig \u914D\u7F6E\u603B\u8BA1\u884C\uFF0C showColumnDynamic + showColumnDynamicKey \u652F\u6301\u81EA\u5B9A\u4E49\u663E\u793A\u5217\u5E76\u6301\u4E45\u5316\u3002"),
|
|
840
|
+
React.createElement(FlatTableDemo, null)),
|
|
841
|
+
React.createElement("div", { style: sectionStyle },
|
|
842
|
+
React.createElement("div", { style: titleStyle }, "\u56DB\u3001\u4E1A\u52A1\u8FD8\u539F\u7528\u4F8B\uFF08\u53F3\u952E\u67E5\u770B\u660E\u7EC6 / \u5168\u5C4F\uFF0C\u72EC\u7ACB\u7EC4\u4EF6\u6587\u4EF6\uFF09"),
|
|
843
|
+
React.createElement("div", { style: descStyle }, "\u590D\u523B\u4E1A\u52A1\u9879\u76EE\uFF08zthr \u5916\u4E8B\u56E2\u7EC4\u5217\u8868\uFF09\u7684\u8868\u683C\u7528\u6CD5\uFF0C\u7528\u4E8E\u590D\u73B0\u4E1A\u52A1\u53CD\u9988\u7684\u300C\u53F3\u952E\u67E5\u770B\u660E\u7EC6 / \u5168\u5C4F\u300D\u62A5\u9519\uFF1A\u5E8F\u53F7\u5217\u53EA\u6709 render \u6CA1\u6709 key/dataIndex\uFF1Bfixed left/right \u56FA\u5B9A\u5217\uFF1B\u6807\u9898/\u72B6\u6001\u5217 render \u8FD4\u56DE Button\uFF1B\u64CD\u4F5C\u5217 key=\"operation\" \u7684 render \u8FD4\u56DE\u300C\u4E3B\u6309\u94AE + Dropdown \u5176\u4ED6\u64CD\u4F5C\u300D\uFF0CoperateCodes \u4E3A\u7A7A\u6570\u7EC4\u6216\u7F3A\u5931\u65F6\u8FD4\u56DE null\uFF1BTable \u914D\u7F6E isFlex\u3001bordered\u3001 pagination=false\u3001scroll={{ x: 'max-content' }}\u3002 \u53F3\u952E\u8868\u683C\u884C \u2192 \u67E5\u770B\u660E\u7EC6 / \u5168\u5C4F\uFF0C\u89C2\u5BDF\u63A7\u5236\u53F0\u662F\u5426\u62A5\u9519\u3002\u7EC4\u4EF6\u4EE3\u7801\u5728\u72EC\u7ACB\u7684 BusinessListDemo.tsx \u6587\u4EF6\u4E2D\u3002"),
|
|
844
|
+
React.createElement(BusinessListDemo, null)),
|
|
845
|
+
React.createElement("div", { style: sectionStyle },
|
|
846
|
+
React.createElement("div", { style: titleStyle }, "\u4E94\u3001\u4E1A\u52A1\u8FD8\u539F\u7528\u4F8B\uFF08\u7F16\u8F91\u8868\u683C\u53F3\u952E\u67E5\u770B\u660E\u7EC6\uFF0C\u72EC\u7ACB\u7EC4\u4EF6\u6587\u4EF6\uFF09"),
|
|
847
|
+
React.createElement("div", { style: descStyle }, "\u590D\u523B\u4E1A\u52A1\u9879\u76EE\uFF08zthr \u56E2\u961F\u6210\u5458\u7EF4\u62A4\u8868\uFF09\u7684\u7F16\u8F91\u8868\u683C\u7528\u6CD5\uFF0C\u7528\u4E8E\u590D\u73B0\u4E1A\u52A1\u53CD\u9988\u7684\u300C\u53F3\u952E\u67E5\u770B\u660E\u7EC6\u5F39\u6846\u6CA1\u6709\u5185\u5BB9\u300D\uFF1A \u6240\u6709\u5217\u90FD\u53EA\u6709 title + render \u6CA1\u6709 key/dataIndex\uFF08\u6B64\u524D\u8FD9\u7C7B\u5217\u4F1A\u88AB\u660E\u7EC6\u5168\u90E8\u8DF3\u8FC7\u5BFC\u81F4\u7A7A\u767D\u5F39\u6846\uFF0C\u5DF2\u5728\u7EC4\u4EF6\u5185\u4FEE\u590D\uFF09\uFF1B \u5217\u5934\u5E26\u7EA2\u8272\u5FC5\u586B\u661F\u53F7\uFF08JSX \u6807\u9898\uFF09\uFF1B\u5355\u5143\u683C\u76F4\u63A5 render \u53D7\u63A7 Input\uFF0C\u4E0D\u4F20 onEditableSave\uFF1B\u64CD\u4F5C\u5217\u6CA1\u6709 key\uFF0C\u9996\u884C render \u8FD4\u56DE null\u3001\u5176\u4ED6\u884C\u8FD4\u56DE Popconfirm \u5220\u9664\uFF1BrowKey \u4F20\u51FD\u6570\u3001bordered\u3001pagination=false\u3001 scroll={{ x: 'max-content' }}\u3002 \u53F3\u952E\u8868\u683C\u884C \u2192 \u67E5\u770B\u660E\u7EC6\uFF0C\u5F39\u6846\u5E94\u5C55\u793A\u6240\u6709\u5217\u5185\u5BB9\u3002 \u8BE5\u8868\u683C\u5355\u5143\u683C\u5B9E\u9645\u90FD\u662F\u8F93\u5165\u6846\u4F46\u672A\u4F20 onEditableSave\uFF08\u4E0D\u7B97\u7EC4\u4EF6\u610F\u4E49\u4E0A\u7684\u7F16\u8F91\u8868\u683C\uFF09\uFF0C \u5168\u5C4F\u540E\u4E0B\u62C9\u6D6E\u5C42\u4F1A\u88AB\u906E\u6321\uFF0C\u56E0\u6B64\u901A\u8FC7 isContextMenuFullscreen=false \u5355\u72EC\u5173\u95ED\u53F3\u952E\u5168\u5C4F\u5165\u53E3\uFF08\u771F\u7F16\u8F91\u8868\u683C\u9ED8\u8BA4\u5C31\u6CA1\u6709\u5168\u5C4F\uFF09\u3002\u7EC4\u4EF6\u4EE3\u7801\u5728\u72EC\u7ACB\u7684 BusinessMemberDemo.tsx \u6587\u4EF6\u4E2D\u3002"),
|
|
848
|
+
React.createElement(BusinessMemberDemo, null))));
|
|
849
|
+
};
|
|
850
|
+
export default TableDemo;
|