cnhis-design-vue 3.1.6 → 3.1.7-beta.3
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/es/_virtual/_commonjsHelpers.mjs +5 -1
- package/es/_virtual/inherits.mjs +3 -1
- package/es/_virtual/inherits_browser.mjs +3 -1
- package/es/node_modules/date-fns/esm/_lib/getTimezoneOffsetInMilliseconds/index.mjs +18 -0
- package/es/node_modules/date-fns/esm/_lib/requiredArgs/index.mjs +7 -0
- package/es/node_modules/date-fns/esm/compareAsc/index.mjs +56 -0
- package/es/node_modules/date-fns/esm/differenceInCalendarDays/index.mjs +53 -0
- package/es/node_modules/date-fns/esm/differenceInCalendarMonths/index.mjs +39 -0
- package/es/node_modules/date-fns/esm/differenceInDays/index.mjs +90 -0
- package/es/node_modules/date-fns/esm/differenceInMonths/index.mjs +63 -0
- package/es/node_modules/date-fns/esm/endOfDay/index.mjs +34 -0
- package/es/node_modules/date-fns/esm/endOfMonth/index.mjs +36 -0
- package/es/node_modules/date-fns/esm/isLastDayOfMonth/index.mjs +34 -0
- package/es/node_modules/date-fns/esm/startOfDay/index.mjs +34 -0
- package/es/node_modules/date-fns/esm/toDate/index.mjs +55 -0
- package/es/node_modules/diagram-js/lib/command/CommandInterceptor.mjs +139 -1
- package/es/node_modules/diagram-js/lib/draw/BaseRenderer.mjs +88 -1
- package/es/node_modules/diagram-js/lib/features/popup-menu/PopupMenu.mjs +572 -1
- package/es/node_modules/diagram-js/lib/features/rules/RuleProvider.mjs +88 -1
- package/es/node_modules/diagram-js/lib/navigation/movecanvas/MoveCanvas.mjs +120 -1
- package/es/node_modules/diagram-js/lib/navigation/movecanvas/index.mjs +8 -1
- package/es/node_modules/diagram-js/lib/navigation/zoomscroll/ZoomScroll.mjs +227 -1
- package/es/node_modules/diagram-js/lib/navigation/zoomscroll/ZoomUtil.mjs +24 -1
- package/es/node_modules/diagram-js/lib/util/ClickTrap.mjs +23 -1
- package/es/node_modules/diagram-js/lib/util/Cursor.mjs +20 -1
- package/es/node_modules/diagram-js/lib/util/Event.mjs +22 -1
- package/es/node_modules/diagram-js/lib/util/Math.mjs +9 -1
- package/es/node_modules/diagram-js/lib/util/Mouse.mjs +30 -1
- package/es/node_modules/diagram-js/lib/util/Platform.mjs +5 -1
- package/es/node_modules/diagram-js/lib/util/PositionUtil.mjs +8 -1
- package/es/node_modules/diagram-js/lib/util/RenderUtil.mjs +25 -1
- package/es/node_modules/diagram-js/lib/util/SvgTransformUtil.mjs +48 -1
- package/es/node_modules/ids/dist/index.esm.mjs +164 -1
- package/es/node_modules/inherits/inherits.mjs +19 -1
- package/es/node_modules/inherits/inherits_browser.mjs +38 -1
- package/es/node_modules/inherits-browser/dist/index.es.mjs +3 -1
- package/es/node_modules/min-dash/dist/index.esm.mjs +169 -1
- package/es/node_modules/min-dom/dist/index.esm.mjs +588 -1
- package/es/node_modules/tiny-svg/dist/index.esm.mjs +525 -1
- package/es/packages/big-table/index.mjs +1 -1
- package/es/packages/big-table/index2.mjs +17 -1
- package/es/packages/big-table/src/BigTable.mjs +2 -1
- package/es/packages/big-table/src/BigTable.vue_vue_type_script_setup_true_lang.mjs +2340 -1
- package/es/packages/big-table/src/BigTable2.mjs +4 -1
- package/es/packages/big-table/src/bigTableEmits.mjs +1 -1
- package/es/packages/big-table/src/bigTableEmits2.mjs +49 -1
- package/es/packages/big-table/src/bigTableProps.mjs +1 -1
- package/es/packages/big-table/src/bigTableProps2.mjs +116 -1
- package/es/packages/big-table/src/bigTableState.mjs +1 -1
- package/es/packages/big-table/src/bigTableState2.mjs +52 -1
- package/es/packages/big-table/src/components/NoData.mjs +2 -1
- package/es/packages/big-table/src/components/NoData.vue_vue_type_script_setup_true_lang.mjs +71 -1
- package/es/packages/big-table/src/components/NoData2.mjs +4 -1
- package/es/packages/big-table/src/components/edit-form/edit-date.mjs +1 -1
- package/es/packages/big-table/src/components/edit-form/edit-date2.mjs +114 -1
- package/es/packages/big-table/src/components/edit-form/edit-input.mjs +1 -1
- package/es/packages/big-table/src/components/edit-form/edit-input2.mjs +54 -1
- package/es/packages/big-table/src/components/edit-form/edit-select-table.d.ts +1 -1
- package/es/packages/big-table/src/components/edit-form/edit-select-table.mjs +1 -1
- package/es/packages/big-table/src/components/edit-form/edit-select-table2.mjs +148 -1
- package/es/packages/big-table/src/components/edit-form/edit-select.mjs +1 -1
- package/es/packages/big-table/src/components/edit-form/edit-select2.mjs +89 -1
- package/es/packages/big-table/src/hooks/useBatchEditing.mjs +1 -1
- package/es/packages/big-table/src/hooks/useBatchEditing2.mjs +289 -1
- package/es/packages/big-table/src/hooks/useEdit.mjs +1 -1
- package/es/packages/big-table/src/hooks/useEdit2.mjs +115 -1
- package/es/packages/big-table/src/hooks/useEvent.mjs +1 -1
- package/es/packages/big-table/src/hooks/useEvent2.mjs +70 -1
- package/es/packages/big-table/src/hooks/useFormat.mjs +1 -1
- package/es/packages/big-table/src/hooks/useFormat2.mjs +484 -1
- package/es/packages/big-table/src/hooks/useNestTable.mjs +1 -1
- package/es/packages/big-table/src/hooks/useNestTable2.mjs +85 -1
- package/es/packages/big-table/src/hooks/useTableParse.mjs +1 -1
- package/es/packages/big-table/src/hooks/useTableParse2.mjs +135 -1
- package/es/packages/big-table/src/utils.mjs +1 -1
- package/es/packages/big-table/src/utils2.mjs +607 -1
- package/es/packages/bpmn-workflow/index.mjs +1 -1
- package/es/packages/bpmn-workflow/index2.mjs +11 -1
- package/es/packages/bpmn-workflow/src/BpmnWorkflow.mjs +2 -1
- package/es/packages/bpmn-workflow/src/BpmnWorkflow.vue_vue_type_script_setup_true_lang.mjs +251 -1
- package/es/packages/bpmn-workflow/src/BpmnWorkflow2.mjs +4 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/BpmnRenderer.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/BpmnRenderer2.mjs +1427 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomContextPadProvider.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomContextPadProvider2.mjs +373 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomPalette.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomPalette2.mjs +141 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomPathMap.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomPathMap2.mjs +99 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRenderer.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRenderer2.mjs +119 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRules.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRules2.mjs +40 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/index.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/customBpmn/index2.mjs +25 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/index.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customModeler/index2.mjs +12 -1
- package/es/packages/bpmn-workflow/src/custom/customOtherModule/CustomPopupMenu.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customOtherModule/CustomPopupMenu2.mjs +47 -1
- package/es/packages/bpmn-workflow/src/custom/customOtherModule/customViewerRenderer.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customOtherModule/customViewerRenderer2.mjs +14 -1
- package/es/packages/bpmn-workflow/src/custom/customOtherModule/zoomScroll.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customOtherModule/zoomScroll2.mjs +10 -1
- package/es/packages/bpmn-workflow/src/custom/customRules/no-task.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customRules/no-task2.mjs +16 -1
- package/es/packages/bpmn-workflow/src/custom/customTranslate/customTranslate.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customTranslate/customTranslate2.mjs +15 -1
- package/es/packages/bpmn-workflow/src/custom/customTranslate/zh.mjs +1 -1
- package/es/packages/bpmn-workflow/src/custom/customTranslate/zh2.mjs +227 -1
- package/es/packages/button-print/index.mjs +1 -1
- package/es/packages/button-print/index2.mjs +11 -1
- package/es/packages/button-print/src/ButtonPrint.mjs +2 -1
- package/es/packages/button-print/src/ButtonPrint.vue_vue_type_script_setup_true_lang.mjs +452 -1
- package/es/packages/button-print/src/ButtonPrint2.mjs +4 -1
- package/es/packages/button-print/src/components/IdentityVerification.mjs +2 -1
- package/es/packages/button-print/src/components/IdentityVerification.vue.d.ts +52 -103
- package/es/packages/button-print/src/components/IdentityVerification.vue_vue_type_script_setup_true_lang.mjs +127 -1
- package/es/packages/button-print/src/components/IdentityVerification2.mjs +4 -1
- package/es/packages/button-print/src/utils/print.es.min.mjs +1 -1
- package/es/packages/button-print/src/utils/print.es.min2.mjs +2080 -1
- package/es/packages/chunk-upload/index.mjs +1 -1
- package/es/packages/chunk-upload/index2.mjs +16 -1
- package/es/packages/chunk-upload/src/chunk-upload-new.mjs +2 -1
- package/es/packages/chunk-upload/src/chunk-upload-new.vue_vue_type_script_setup_true_lang.mjs +465 -1
- package/es/packages/chunk-upload/src/chunk-upload-new2.mjs +4 -1
- package/es/packages/chunk-upload/src/hooks/upload-computed.mjs +1 -1
- package/es/packages/chunk-upload/src/hooks/upload-computed2.mjs +68 -1
- package/es/packages/chunk-upload/src/hooks/upload-data.mjs +1 -1
- package/es/packages/chunk-upload/src/hooks/upload-data2.mjs +93 -1
- package/es/packages/chunk-upload/src/hooks/vod-computed.mjs +1 -1
- package/es/packages/chunk-upload/src/hooks/vod-computed2.mjs +79 -1
- package/es/packages/chunk-upload/src/hooks/vod-data.mjs +1 -1
- package/es/packages/chunk-upload/src/hooks/vod-data2.mjs +33 -1
- package/es/packages/chunk-upload/src/vod-chunk-upload/index.mjs +2 -1
- package/es/packages/chunk-upload/src/vod-chunk-upload/index2.mjs +3 -1
- package/es/packages/chunk-upload/src/vod-chunk-upload/vod-chunk-upload.mjs +2 -1
- package/es/packages/chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue_vue_type_script_setup_true_lang.mjs +325 -1
- package/es/packages/chunk-upload/src/vod-chunk-upload/vod-chunk-upload2.mjs +4 -1
- package/es/packages/chunk-upload/src/vod-upload-modal.mjs +1 -1
- package/es/packages/chunk-upload/src/vod-upload-modal2.mjs +95 -1
- package/es/packages/drag-layout/index.d.ts +289 -415
- package/es/packages/drag-layout/index.mjs +1 -1
- package/es/packages/drag-layout/index2.mjs +13 -1
- package/es/packages/drag-layout/src/DragFormLeftItem.mjs +2 -1
- package/es/packages/drag-layout/src/DragFormLeftItem.vue.d.ts +89 -113
- package/es/packages/drag-layout/src/DragFormLeftItem.vue_vue_type_script_setup_true_lang.mjs +121 -1
- package/es/packages/drag-layout/src/DragFormLeftItem2.mjs +4 -1
- package/es/packages/drag-layout/src/DragFormRightItem.mjs +2 -1
- package/es/packages/drag-layout/src/DragFormRightItem.vue.d.ts +77 -95
- package/es/packages/drag-layout/src/DragFormRightItem.vue_vue_type_script_setup_true_lang.mjs +266 -1
- package/es/packages/drag-layout/src/DragFormRightItem2.mjs +4 -1
- package/es/packages/drag-layout/src/DragLayout.mjs +2 -1
- package/es/packages/drag-layout/src/DragLayout.vue.d.ts +289 -415
- package/es/packages/drag-layout/src/DragLayout.vue_vue_type_script_setup_true_lang.mjs +658 -1
- package/es/packages/drag-layout/src/DragLayout2.mjs +4 -1
- package/es/packages/editor/index.mjs +1 -1
- package/es/packages/editor/index2.mjs +10 -1
- package/es/packages/editor/src/Editor.mjs +1 -1
- package/es/packages/editor/src/Editor2.mjs +77 -1
- package/es/packages/field-set/index.mjs +1 -1
- package/es/packages/field-set/index2.mjs +11 -1
- package/es/packages/field-set/src/FieldSet.mjs +2 -1
- package/es/packages/field-set/src/FieldSet.vue_vue_type_script_setup_true_lang.mjs +329 -1
- package/es/packages/field-set/src/FieldSet2.mjs +4 -1
- package/es/packages/field-set/src/Index.mjs +2 -0
- package/es/packages/field-set/src/Index.vue_vue_type_script_setup_true_lang.mjs +25 -0
- package/es/packages/field-set/src/Index2.mjs +4 -0
- package/es/packages/field-set/src/NewFieldSet.mjs +2 -0
- package/es/packages/field-set/src/NewFieldSet.vue_vue_type_script_setup_true_lang.mjs +298 -0
- package/es/packages/field-set/src/NewFieldSet2.mjs +4 -0
- package/es/packages/field-set/src/index.vue_vue_type_script_setup_true_lang2.mjs +25 -0
- package/es/packages/field-set/src/index3.mjs +4 -0
- package/es/packages/form-render/index.mjs +10 -0
- package/es/packages/form-render/index2.mjs +15 -0
- package/es/packages/form-render/src/FormRender.mjs +2 -0
- package/es/packages/form-render/src/FormRender.vue_vue_type_script_setup_true_lang.mjs +91 -0
- package/es/packages/form-render/src/FormRender2.mjs +4 -0
- package/es/packages/form-render/src/components/cascader.d.ts +40 -0
- package/es/packages/form-render/src/components/cascader.mjs +1 -0
- package/es/packages/form-render/src/components/cascader2.mjs +108 -0
- package/es/packages/form-render/src/components/checkbox.d.ts +24 -0
- package/es/packages/form-render/src/components/checkbox.mjs +1 -0
- package/es/packages/form-render/src/components/checkbox2.mjs +42 -0
- package/es/packages/form-render/src/components/collapse.d.ts +31 -0
- package/es/packages/form-render/src/components/collapse.mjs +1 -0
- package/es/packages/form-render/src/components/collapse2.mjs +54 -0
- package/es/packages/form-render/src/components/combination.d.ts +142 -0
- package/es/packages/form-render/src/components/combination.mjs +1 -0
- package/es/packages/form-render/src/components/combination2.mjs +116 -0
- package/es/packages/form-render/src/components/date.d.ts +5033 -0
- package/es/packages/form-render/src/components/date.mjs +1 -0
- package/es/packages/form-render/src/components/date2.mjs +34 -0
- package/es/packages/form-render/src/components/formItem.d.ts +292 -0
- package/es/packages/form-render/src/components/formItem.mjs +1 -0
- package/es/packages/form-render/src/components/formItem2.mjs +22 -0
- package/es/packages/form-render/src/components/index.d.ts +15 -0
- package/es/packages/form-render/src/components/index.mjs +15 -0
- package/es/packages/form-render/src/components/index2.mjs +15 -0
- package/es/packages/form-render/src/components/input.d.ts +15 -0
- package/es/packages/form-render/src/components/input.mjs +1 -0
- package/es/packages/form-render/src/components/input2.mjs +40 -0
- package/es/packages/form-render/src/components/inputGroup.d.ts +11 -0
- package/es/packages/form-render/src/components/inputGroup.mjs +1 -0
- package/es/packages/form-render/src/components/inputGroup2.mjs +8 -0
- package/es/packages/{map/src/Map.vue.d.ts → form-render/src/components/inputNumber.d.ts} +1002 -1148
- package/es/packages/form-render/src/components/inputNumber.mjs +1 -0
- package/es/packages/form-render/src/components/inputNumber2.mjs +7 -0
- package/es/packages/form-render/src/components/labelSelect.d.ts +1 -0
- package/es/packages/form-render/src/components/labelSelect.mjs +1 -0
- package/es/packages/form-render/src/components/labelSelect2.mjs +18 -0
- package/es/packages/form-render/src/components/radio.d.ts +24 -0
- package/es/packages/form-render/src/components/radio.mjs +1 -0
- package/es/packages/form-render/src/components/radio2.mjs +44 -0
- package/es/packages/form-render/src/components/select.d.ts +29 -0
- package/es/packages/form-render/src/components/select.mjs +1 -0
- package/es/packages/form-render/src/components/select2.mjs +97 -0
- package/es/packages/form-render/src/components/slider.d.ts +347 -0
- package/es/packages/form-render/src/components/slider.mjs +1 -0
- package/es/packages/form-render/src/components/slider2.mjs +16 -0
- package/es/packages/form-render/src/components/switch.d.ts +21 -0
- package/es/packages/form-render/src/components/switch.mjs +1 -0
- package/es/packages/form-render/src/components/switch2.mjs +48 -0
- package/es/packages/form-render/src/components/textarea.d.ts +845 -0
- package/es/packages/form-render/src/components/textarea.mjs +1 -0
- package/es/packages/form-render/src/components/textarea2.mjs +11 -0
- package/es/packages/form-render/src/constants/index.d.ts +23 -0
- package/es/packages/form-render/src/constants/index.mjs +1 -0
- package/es/packages/form-render/src/constants/index2.mjs +24 -0
- package/es/packages/form-render/src/hooks/index.d.ts +9 -0
- package/es/packages/form-render/src/hooks/index.mjs +9 -0
- package/es/packages/form-render/src/hooks/useAsyncQueue.d.ts +60 -0
- package/es/packages/form-render/src/hooks/useAsyncQueue.mjs +1 -0
- package/es/packages/form-render/src/hooks/useAsyncQueue2.mjs +138 -0
- package/es/packages/form-render/src/hooks/useBusinessBinding.d.ts +13 -0
- package/es/packages/form-render/src/hooks/useBusinessBinding.mjs +1 -0
- package/es/packages/form-render/src/hooks/useBusinessBinding2.mjs +48 -0
- package/es/packages/form-render/src/hooks/useCommonLog.d.ts +3 -0
- package/es/packages/form-render/src/hooks/useCommonLog.mjs +1 -0
- package/es/packages/form-render/src/hooks/useCommonLog2.mjs +10 -0
- package/es/packages/form-render/src/hooks/useFieldList2Schema.d.ts +64 -0
- package/es/packages/form-render/src/hooks/useFieldList2Schema.mjs +1 -0
- package/es/packages/form-render/src/hooks/useFieldList2Schema2.mjs +184 -0
- package/es/packages/form-render/src/hooks/useFieldVisitor.d.ts +4 -0
- package/es/packages/form-render/src/hooks/useFieldVisitor.mjs +1 -0
- package/es/packages/form-render/src/hooks/useFieldVisitor2.mjs +38 -0
- package/es/packages/form-render/src/hooks/useFormField.d.ts +4 -0
- package/es/packages/form-render/src/hooks/useFormField.mjs +1 -0
- package/es/packages/form-render/src/hooks/useFormField2.mjs +9 -0
- package/es/packages/form-render/src/hooks/useFormRequest.d.ts +6 -0
- package/es/packages/form-render/src/hooks/useFormRequest.mjs +1 -0
- package/es/packages/form-render/src/hooks/useFormRequest2.mjs +12 -0
- package/es/packages/form-render/src/hooks/useFormValidator.d.ts +5 -0
- package/es/packages/form-render/src/hooks/useFormValidator.mjs +1 -0
- package/es/packages/form-render/src/hooks/useFormValidator2.mjs +48 -0
- package/es/packages/form-render/src/hooks/useTypeNormalize.d.ts +4 -0
- package/es/packages/form-render/src/hooks/useTypeNormalize.mjs +1 -0
- package/es/packages/form-render/src/hooks/useTypeNormalize2.mjs +37 -0
- package/es/packages/form-render/src/types/fieldItem.d.ts +44 -0
- package/es/packages/{popper/index.mjs → form-render/src/types/fieldItem.mjs} +0 -0
- package/es/packages/form-render/src/types/index.d.ts +26 -0
- package/es/packages/{popper → form-render}/src/types/index.mjs +0 -0
- package/es/packages/form-render/src/utils/index.d.ts +10 -0
- package/es/packages/form-render/src/utils/index.mjs +1 -0
- package/es/packages/form-render/src/utils/index2.mjs +59 -0
- package/es/packages/form-render/style/index.css +80 -0
- package/es/packages/form-render/style/index.less +116 -0
- package/es/packages/form-table/index.mjs +1 -1
- package/es/packages/form-table/index2.mjs +11 -1
- package/es/packages/form-table/src/FormTable.mjs +2 -1
- package/es/packages/form-table/src/FormTable.vue_vue_type_script_setup_true_lang.mjs +473 -1
- package/es/packages/form-table/src/FormTable2.mjs +4 -1
- package/es/packages/form-table/src/components/index.mjs +1 -1
- package/es/packages/form-table/src/components/index2.mjs +54 -1
- package/es/packages/form-table/src/components/table-age.mjs +2 -1
- package/es/packages/form-table/src/components/table-age.vue_vue_type_script_setup_true_lang.mjs +231 -1
- package/es/packages/form-table/src/components/table-age2.mjs +4 -1
- package/es/packages/form-table/src/components/table-date-picker.mjs +2 -1
- package/es/packages/form-table/src/components/table-date-picker.vue_vue_type_script_setup_true_lang.mjs +177 -1
- package/es/packages/form-table/src/components/table-date-picker2.mjs +4 -1
- package/es/packages/form-table/src/components/table-digital.mjs +2 -1
- package/es/packages/form-table/src/components/table-digital.vue_vue_type_script_setup_true_lang.mjs +137 -1
- package/es/packages/form-table/src/components/table-digital2.mjs +4 -1
- package/es/packages/form-table/src/components/table-input-password.mjs +2 -1
- package/es/packages/form-table/src/components/table-input-password.vue_vue_type_script_setup_true_lang.mjs +137 -1
- package/es/packages/form-table/src/components/table-input-password2.mjs +4 -1
- package/es/packages/form-table/src/components/table-input.mjs +2 -1
- package/es/packages/form-table/src/components/table-input.vue_vue_type_script_setup_true_lang.mjs +123 -1
- package/es/packages/form-table/src/components/table-input2.mjs +4 -1
- package/es/packages/form-table/src/components/table-month-picker.mjs +2 -1
- package/es/packages/form-table/src/components/table-month-picker.vue_vue_type_script_setup_true_lang.mjs +98 -1
- package/es/packages/form-table/src/components/table-month-picker2.mjs +4 -1
- package/es/packages/form-table/src/components/table-search-more.mjs +2 -1
- package/es/packages/form-table/src/components/table-search-more.vue_vue_type_script_setup_true_lang.mjs +275 -1
- package/es/packages/form-table/src/components/table-search-more2.mjs +4 -1
- package/es/packages/form-table/src/components/table-search.mjs +2 -1
- package/es/packages/form-table/src/components/table-search.vue_vue_type_script_setup_true_lang.mjs +275 -1
- package/es/packages/form-table/src/components/table-search2.mjs +4 -1
- package/es/packages/form-table/src/components/table-select-multiple.mjs +2 -1
- package/es/packages/form-table/src/components/table-select-multiple.vue_vue_type_script_setup_true_lang.mjs +159 -1
- package/es/packages/form-table/src/components/table-select-multiple2.mjs +4 -1
- package/es/packages/form-table/src/components/table-select.mjs +2 -1
- package/es/packages/form-table/src/components/table-select.vue_vue_type_script_setup_true_lang.mjs +154 -1
- package/es/packages/form-table/src/components/table-select2.mjs +4 -1
- package/es/packages/form-table/src/components/table-textarea.mjs +2 -1
- package/es/packages/form-table/src/components/table-textarea.vue_vue_type_script_setup_true_lang.mjs +152 -1
- package/es/packages/form-table/src/components/table-textarea2.mjs +4 -1
- package/es/packages/form-table/src/components/table-time-picker.mjs +2 -1
- package/es/packages/form-table/src/components/table-time-picker.vue_vue_type_script_setup_true_lang.mjs +144 -1
- package/es/packages/form-table/src/components/table-time-picker2.mjs +4 -1
- package/es/packages/form-table/src/components/table-tree-select.mjs +2 -1
- package/es/packages/form-table/src/components/table-tree-select.vue_vue_type_script_setup_true_lang.mjs +278 -1
- package/es/packages/form-table/src/components/table-tree-select2.mjs +4 -1
- package/es/packages/form-table/src/components/text-over-tooltip.mjs +2 -1
- package/es/packages/form-table/src/components/text-over-tooltip.vue_vue_type_script_setup_true_lang.mjs +61 -1
- package/es/packages/form-table/src/components/text-over-tooltip2.mjs +4 -1
- package/es/packages/form-table/src/configs/index.mjs +1 -1
- package/es/packages/form-table/src/configs/index2.mjs +74 -1
- package/es/packages/form-table/src/hooks/index.mjs +5 -1
- package/es/packages/form-table/src/hooks/useBoundDate.mjs +1 -1
- package/es/packages/form-table/src/hooks/useBoundDate2.mjs +411 -1
- package/es/packages/form-table/src/hooks/useDateType.mjs +1 -1
- package/es/packages/form-table/src/hooks/useDateType2.mjs +160 -1
- package/es/packages/form-table/src/hooks/useFormCommon.mjs +1 -1
- package/es/packages/form-table/src/hooks/useFormCommon2.mjs +95 -1
- package/es/packages/form-table/src/hooks/useFormEvent.mjs +1 -1
- package/es/packages/form-table/src/hooks/useFormEvent2.mjs +71 -1
- package/es/packages/form-table/src/hooks/useItemDefault.mjs +1 -1
- package/es/packages/form-table/src/hooks/useItemDefault2.mjs +218 -1
- package/es/packages/form-table/src/hooks/useSearch.mjs +1 -1
- package/es/packages/form-table/src/hooks/useSearch2.mjs +1216 -1
- package/es/packages/form-table/src/hooks/useValidate.mjs +1 -1
- package/es/packages/form-table/src/hooks/useValidate2.mjs +480 -1
- package/es/packages/grid/index.mjs +1 -1
- package/es/packages/grid/index2.mjs +14 -1
- package/es/packages/grid/src/Grid.mjs +1 -1
- package/es/packages/grid/src/Grid2.mjs +28 -1
- package/es/packages/grid/src/hooks.mjs +1 -1
- package/es/packages/grid/src/hooks2.mjs +165 -1
- package/es/packages/index.css +214 -1
- package/es/packages/index.d.ts +5 -2
- package/es/packages/index.less +286 -1
- package/es/packages/index.mjs +26 -1
- package/es/packages/index2.mjs +64 -1
- package/es/packages/info-header/index.mjs +1 -1
- package/es/packages/info-header/index2.mjs +11 -1
- package/es/packages/info-header/src/HiddenContent.mjs +2 -0
- package/es/packages/info-header/src/HiddenContent.vue_vue_type_script_setup_true_lang.mjs +60 -0
- package/es/packages/info-header/src/HiddenContent2.mjs +4 -0
- package/es/packages/info-header/src/InfoHeader.mjs +2 -0
- package/es/packages/info-header/src/InfoHeader.vue_vue_type_script_setup_true_lang.mjs +217 -0
- package/es/packages/info-header/src/InfoHeader2.mjs +4 -0
- package/es/packages/info-header/src/SlotRender.d.ts +22 -0
- package/es/packages/info-header/src/SlotRender.mjs +1 -0
- package/es/packages/info-header/src/SlotRender2.mjs +35 -0
- package/es/packages/info-header/style/index.css +3 -0
- package/es/packages/info-header/style/index.less +5 -1
- package/es/packages/map/index.mjs +1 -1
- package/es/packages/map/index2.mjs +11 -1
- package/es/packages/map/src/Map.mjs +2 -1
- package/es/packages/map/src/Map.vue_vue_type_script_setup_true_lang.mjs +335 -1
- package/es/packages/map/src/Map2.mjs +4 -1
- package/es/packages/scale-view/index.mjs +1 -1
- package/es/packages/scale-view/index2.mjs +37 -1
- package/es/packages/scale-view/src/ScaleView.mjs +2 -1
- package/es/packages/scale-view/src/ScaleView.vue_vue_type_script_setup_true_lang.mjs +372 -1
- package/es/packages/scale-view/src/ScaleView2.mjs +4 -1
- package/es/packages/scale-view/src/components/AnswerParse.mjs +2 -1
- package/es/packages/scale-view/src/components/AnswerParse.vue_vue_type_script_setup_true_lang.mjs +77 -1
- package/es/packages/scale-view/src/components/AnswerParse2.mjs +4 -1
- package/es/packages/scale-view/src/components/EvaluateCountdown.mjs +2 -1
- package/es/packages/scale-view/src/components/EvaluateCountdown.vue_vue_type_script_setup_true_lang.mjs +108 -1
- package/es/packages/scale-view/src/components/EvaluateCountdown2.mjs +4 -1
- package/es/packages/scale-view/src/components/EvaluatePage.mjs +2 -1
- package/es/packages/scale-view/src/components/EvaluatePage.vue_vue_type_script_setup_true_lang.mjs +138 -1
- package/es/packages/scale-view/src/components/EvaluatePage2.mjs +4 -1
- package/es/packages/scale-view/src/components/NoData.mjs +2 -1
- package/es/packages/scale-view/src/components/NoData.vue_vue_type_script_setup_true_lang.mjs +71 -1
- package/es/packages/scale-view/src/components/NoData2.mjs +4 -1
- package/es/packages/scale-view/src/components/ScaleScore.mjs +1 -1
- package/es/packages/scale-view/src/components/ScaleScore2.mjs +63 -1
- package/es/packages/scale-view/src/components/composables/choose-common.d.ts +1 -1
- package/es/packages/scale-view/src/components/composables/choose-common.mjs +1 -1
- package/es/packages/scale-view/src/components/composables/choose-common2.mjs +78 -1
- package/es/packages/scale-view/src/components/formitem/address.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/address2.mjs +3993 -1
- package/es/packages/scale-view/src/components/formitem/r-address.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-address2.mjs +225 -1
- package/es/packages/scale-view/src/components/formitem/r-cascader.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-cascader2.mjs +121 -1
- package/es/packages/scale-view/src/components/formitem/r-checkbox.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-checkbox2.mjs +228 -1
- package/es/packages/scale-view/src/components/formitem/r-collection.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-collection2.mjs +111 -1
- package/es/packages/scale-view/src/components/formitem/r-datetime.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-datetime2.mjs +198 -1
- package/es/packages/scale-view/src/components/formitem/r-input.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-input2.mjs +88 -1
- package/es/packages/scale-view/src/components/formitem/r-map.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-map2.mjs +104 -1
- package/es/packages/scale-view/src/components/formitem/r-radio.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-radio2.mjs +220 -1
- package/es/packages/scale-view/src/components/formitem/r-select.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-select2.mjs +134 -1
- package/es/packages/scale-view/src/components/formitem/r-upload.mjs +1 -1
- package/es/packages/scale-view/src/components/formitem/r-upload2.mjs +210 -1
- package/es/packages/scale-view/src/components/formitem/text-over-tooltip/TextOverTooltip.mjs +2 -1
- package/es/packages/scale-view/src/components/formitem/text-over-tooltip/TextOverTooltip.vue.d.ts +2 -3
- package/es/packages/scale-view/src/components/formitem/text-over-tooltip/TextOverTooltip.vue_vue_type_script_setup_true_lang.mjs +77 -1
- package/es/packages/scale-view/src/components/formitem/text-over-tooltip/TextOverTooltip2.mjs +4 -1
- package/es/packages/scale-view/src/hooks/scaleview-computed.mjs +1 -1
- package/es/packages/scale-view/src/hooks/scaleview-computed2.mjs +300 -1
- package/es/packages/scale-view/src/hooks/scaleview-init.mjs +1 -1
- package/es/packages/scale-view/src/hooks/scaleview-init2.mjs +441 -1
- package/es/packages/scale-view/src/hooks/scaleview-props.mjs +1 -1
- package/es/packages/scale-view/src/hooks/scaleview-props2.mjs +56 -1
- package/es/packages/scale-view/src/hooks/scaleview-state.mjs +1 -1
- package/es/packages/scale-view/src/hooks/scaleview-state2.mjs +42 -1
- package/es/packages/scale-view/src/hooks/scaleview-submit.mjs +1 -1
- package/es/packages/scale-view/src/hooks/scaleview-submit2.mjs +162 -1
- package/es/packages/scale-view/src/hooks/scaleview-validate.mjs +1 -1
- package/es/packages/scale-view/src/hooks/scaleview-validate2.mjs +164 -1
- package/es/packages/scale-view/src/hooks/use-component.mjs +1 -1
- package/es/packages/scale-view/src/hooks/use-component2.mjs +80 -1
- package/es/packages/scale-view/src/hooks/use-evaluate.mjs +1 -1
- package/es/packages/scale-view/src/hooks/use-evaluate2.mjs +150 -1
- package/es/packages/scale-view/src/hooks/use-event.d.ts +1 -1
- package/es/packages/scale-view/src/hooks/use-event.mjs +1 -1
- package/es/packages/scale-view/src/hooks/use-event2.mjs +128 -1
- package/es/packages/scale-view/src/hooks/use-noData.mjs +1 -1
- package/es/packages/scale-view/src/hooks/use-noData2.mjs +41 -1
- package/es/packages/scale-view/src/utils/judge-types.mjs +1 -1
- package/es/packages/scale-view/src/utils/judge-types2.mjs +40 -1
- package/es/packages/scale-view/style/index.css +13 -1
- package/es/packages/scale-view/style/index.less +15 -1
- package/es/packages/select-label/index.mjs +1 -1
- package/es/packages/select-label/index2.mjs +17 -1
- package/es/packages/select-label/src/LabelFormContent.mjs +2 -1
- package/es/packages/select-label/src/LabelFormContent.vue.d.ts +94 -296
- package/es/packages/select-label/src/LabelFormContent.vue_vue_type_script_setup_true_lang.mjs +441 -1
- package/es/packages/select-label/src/LabelFormContent2.mjs +4 -1
- package/es/packages/select-label/src/SelectLabel.mjs +2 -1
- package/es/packages/select-label/src/SelectLabel.vue_vue_type_script_setup_true_lang.mjs +433 -1
- package/es/packages/select-label/src/SelectLabel2.mjs +4 -1
- package/es/packages/select-label/src/components/label-classify.mjs +2 -1
- package/es/packages/select-label/src/components/label-classify.vue.d.ts +66 -229
- package/es/packages/select-label/src/components/label-classify.vue_vue_type_script_setup_true_lang.mjs +123 -1
- package/es/packages/select-label/src/components/label-classify2.mjs +4 -1
- package/es/packages/select-person/index.mjs +1 -1
- package/es/packages/select-person/index2.mjs +11 -1
- package/es/packages/select-person/src/SearchTree.mjs +2 -1
- package/es/packages/select-person/src/SearchTree.vue_vue_type_script_setup_true_lang.mjs +232 -1
- package/es/packages/select-person/src/SearchTree2.mjs +4 -1
- package/es/packages/select-person/src/SelectPerson.mjs +2 -1
- package/es/packages/select-person/src/SelectPerson.vue_vue_type_script_setup_true_lang.mjs +894 -1
- package/es/packages/select-person/src/SelectPerson2.mjs +4 -1
- package/es/packages/select-person/src/utils/index.d.ts +8 -8
- package/es/packages/select-person/src/utils/index.mjs +1 -1
- package/es/packages/select-person/src/utils/index2.mjs +57 -1
- package/es/packages/time-line/index.d.ts +28 -28
- package/es/packages/time-line/index.mjs +1 -1
- package/es/packages/time-line/index2.mjs +11 -1
- package/es/packages/time-line/src/TimeLine.mjs +2 -1
- package/es/packages/time-line/src/TimeLine.vue.d.ts +28 -28
- package/es/packages/time-line/src/TimeLine.vue_vue_type_script_setup_true_lang.mjs +62 -1
- package/es/packages/time-line/src/TimeLine2.mjs +4 -1
- package/es/src/components/SelectPage/SelectPage.mjs +2 -1
- package/es/src/components/SelectPage/SelectPage.vue_vue_type_script_setup_true_lang.mjs +60 -1
- package/es/src/components/SelectPage/SelectPage2.mjs +4 -1
- package/es/src/components/SelectPage/index.mjs +2 -1
- package/es/src/components/SelectPage/index2.mjs +3 -1
- package/es/src/components/SvgIcon/SvgIcon.mjs +2 -1
- package/es/src/components/SvgIcon/SvgIcon.vue_vue_type_script_setup_true_lang.mjs +33 -1
- package/es/src/components/SvgIcon/SvgIcon2.mjs +4 -1
- package/es/src/components/SvgIcon/index.mjs +2 -1
- package/es/src/components/SvgIcon/index2.mjs +3 -1
- package/es/src/components/TextOverTooltip/TextOverTooltip.mjs +2 -1
- package/es/src/components/TextOverTooltip/TextOverTooltip.vue.d.ts +2 -3
- package/es/src/components/TextOverTooltip/TextOverTooltip.vue_vue_type_script_setup_true_lang.mjs +73 -1
- package/es/src/components/TextOverTooltip/TextOverTooltip2.mjs +4 -1
- package/es/src/components/TextOverTooltip/index.mjs +2 -1
- package/es/src/components/TextOverTooltip/index2.mjs +3 -1
- package/es/src/components/player-vod/index.mjs +2 -1
- package/es/src/components/player-vod/index.vue_vue_type_script_setup_true_lang.mjs +11 -1
- package/es/src/components/player-vod/index2.mjs +4 -1
- package/es/src/components/player-vod/player.mjs +1 -1
- package/es/src/components/player-vod/player2.mjs +121 -1
- package/es/src/components/player-vod/video-list.mjs +1 -1
- package/es/src/components/player-vod/video-list2.mjs +125 -1
- package/es/src/components/player-vod/video-modal.mjs +1 -1
- package/es/src/components/player-vod/video-modal2.mjs +91 -1
- package/es/src/core/create.mjs +1 -1
- package/es/src/core/create2.mjs +8 -1
- package/es/src/global/variable.mjs +1 -1
- package/es/src/global/variable2.mjs +4 -1
- package/es/src/utils/anime.d.ts +35 -0
- package/es/src/utils/anime.mjs +1 -0
- package/es/src/utils/anime2.mjs +126 -0
- package/es/src/utils/clickoutside.mjs +1 -1
- package/es/src/utils/clickoutside2.mjs +48 -1
- package/es/src/utils/crypto.mjs +1 -1
- package/es/src/utils/crypto2.mjs +25 -1
- package/es/src/utils/index.d.ts +0 -2
- package/es/src/utils/index.mjs +1 -1
- package/es/src/utils/index2.mjs +19 -1
- package/es/src/utils/loadViewer.d.ts +2 -0
- package/es/src/utils/loadViewer.mjs +1 -0
- package/es/src/utils/loadViewer2.mjs +11 -0
- package/es/src/utils/loadVxe.d.ts +2 -0
- package/es/src/utils/loadVxe.mjs +1 -0
- package/es/src/utils/loadVxe2.mjs +12 -0
- package/es/src/utils/utilExpand.d.ts +1 -0
- package/es/src/utils/utilExpand.mjs +1 -0
- package/es/src/utils/utilExpand2.mjs +714 -0
- package/es/src/utils/vexutils.mjs +3 -1
- package/es/src/utils/vexutils2.mjs +80 -1
- package/md-plugin.ts +201 -0
- package/package.json +125 -122
- package/uno.config.ts +22 -0
- package/.prettierrc.js +0 -23
- package/es/packages/big-table/index.d.ts +0 -2044
- package/es/packages/big-table/src/BigTable.vue.d.ts +0 -2043
- package/es/packages/big-table/src/components/NoData.vue.d.ts +0 -51
- package/es/packages/bpmn-workflow/index.d.ts +0 -74
- package/es/packages/bpmn-workflow/src/BpmnWorkflow.vue.d.ts +0 -77
- package/es/packages/button-print/index.d.ts +0 -7373
- package/es/packages/button-print/src/ButtonPrint.vue.d.ts +0 -7372
- package/es/packages/chunk-upload/index.d.ts +0 -1748
- package/es/packages/chunk-upload/src/chunk-upload-new.vue.d.ts +0 -1905
- package/es/packages/chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue.d.ts +0 -1749
- package/es/packages/field-set/index.d.ts +0 -2647
- package/es/packages/field-set/src/FieldSet.vue.d.ts +0 -2599
- package/es/packages/form-table/index.d.ts +0 -35903
- package/es/packages/form-table/src/FormTable.vue.d.ts +0 -35912
- package/es/packages/form-table/src/components/index.d.ts +0 -35662
- package/es/packages/form-table/src/components/table-age.vue.d.ts +0 -4305
- package/es/packages/form-table/src/components/table-date-picker.vue.d.ts +0 -5286
- package/es/packages/form-table/src/components/table-digital.vue.d.ts +0 -2916
- package/es/packages/form-table/src/components/table-input-password.vue.d.ts +0 -1622
- package/es/packages/form-table/src/components/table-input.vue.d.ts +0 -1579
- package/es/packages/form-table/src/components/table-month-picker.vue.d.ts +0 -5229
- package/es/packages/form-table/src/components/table-search-more.vue.d.ts +0 -1785
- package/es/packages/form-table/src/components/table-search.vue.d.ts +0 -3111
- package/es/packages/form-table/src/components/table-select-multiple.vue.d.ts +0 -1567
- package/es/packages/form-table/src/components/table-select.vue.d.ts +0 -1566
- package/es/packages/form-table/src/components/table-textarea.vue.d.ts +0 -1638
- package/es/packages/form-table/src/components/table-time-picker.vue.d.ts +0 -2673
- package/es/packages/form-table/src/components/table-tree-select.vue.d.ts +0 -1883
- package/es/packages/form-table/src/components/text-over-tooltip.vue.d.ts +0 -543
- package/es/packages/info-header/index.d.ts +0 -1827
- package/es/packages/info-header/src/hidden-content.mjs +0 -1
- package/es/packages/info-header/src/hidden-content.vue.d.ts +0 -363
- package/es/packages/info-header/src/hidden-content.vue_vue_type_script_setup_true_lang.mjs +0 -1
- package/es/packages/info-header/src/hidden-content2.mjs +0 -1
- package/es/packages/info-header/src/info-header.mjs +0 -1
- package/es/packages/info-header/src/info-header.vue.d.ts +0 -1828
- package/es/packages/info-header/src/info-header.vue_vue_type_script_setup_true_lang.mjs +0 -1
- package/es/packages/info-header/src/info-header2.mjs +0 -1
- package/es/packages/map/index.d.ts +0 -2313
- package/es/packages/popper/index.d.ts +0 -0
- package/es/packages/popper/src/components/popover.mjs +0 -1
- package/es/packages/popper/src/components/popover.vue.d.ts +0 -33
- package/es/packages/popper/src/components/popover.vue_vue_type_script_setup_true_lang.mjs +0 -1
- package/es/packages/popper/src/components/popover2.mjs +0 -1
- package/es/packages/popper/src/hooks/useAutoHidden.d.ts +0 -8
- package/es/packages/popper/src/hooks/useAutoHidden.mjs +0 -1
- package/es/packages/popper/src/hooks/useAutoHidden2.mjs +0 -1
- package/es/packages/popper/src/types/index.d.ts +0 -1
- package/es/packages/scale-view/index.d.ts +0 -4297
- package/es/packages/scale-view/src/ScaleView.vue.d.ts +0 -4141
- package/es/packages/scale-view/src/components/AnswerParse.vue.d.ts +0 -72
- package/es/packages/scale-view/src/components/EvaluateCountdown.vue.d.ts +0 -150
- package/es/packages/scale-view/src/components/EvaluatePage.vue.d.ts +0 -1503
- package/es/packages/scale-view/src/components/NoData.vue.d.ts +0 -51
- package/es/packages/scale-view/src/hooks/use-component.d.ts +0 -2673
- package/es/packages/select-label/index.d.ts +0 -12091
- package/es/packages/select-label/src/SelectLabel.vue.d.ts +0 -7526
- package/es/packages/select-person/index.d.ts +0 -3500
- package/es/packages/select-person/src/SearchTree.vue.d.ts +0 -344
- package/es/packages/select-person/src/SelectPerson.vue.d.ts +0 -3501
- package/es/src/components/SelectPage/SelectPage.vue.d.ts +0 -1446
|
@@ -1 +1,2340 @@
|
|
|
1
|
-
import{defineComponent as e,ref as t,reactive as l,useAttrs as i,computed as n,onMounted as o,onUnmounted as r,onActivated as a,createVNode as s,h as c,resolveComponent as d,createTextVNode as u,isVNode as h,nextTick as p,watch as g,openBlock as m,createElementBlock as f,normalizeClass as b,normalizeStyle as v,createElementVNode as C,createCommentVNode as w,withDirectives as T,toDisplayString as k,unref as y,vShow as S,Fragment as x,mergeProps as N,withCtx as E,createBlock as R,renderSlot as I}from"vue";import O from"./bigTableState2.mjs";import L from"./bigTableProps2.mjs";import F from"./bigTableEmits2.mjs";import{useFormat as A}from"./hooks/useFormat2.mjs";import{useTableParse as D}from"./hooks/useTableParse2.mjs";import{useBatchEditing as _}from"./hooks/useBatchEditing2.mjs";import{useNestTable as M}from"./hooks/useNestTable2.mjs";import{useEdit as B,comps as P}from"./hooks/useEdit2.mjs";import{useEvent as V}from"./hooks/useEvent2.mjs";import{SettingsSharp as j,CaretDown as z,CaretForward as $,CopyOutline as K,SyncOutline as U}from"@vicons/ionicons5";import"./components/NoData2.mjs";import H from"cnhis-design-vue/es/src/components/TextOverTooltip";import q from"cnhis-design-vue/es/src/components/SvgIcon";import{useMessage as W,NIcon as J,NTooltip as G,NPopconfirm as Z,NButton as Q,NInputGroup as X,NInput as Y,NCheckbox as ee,NCheckboxGroup as te,NSpace as le,NProgress as ie,NDropdown as ne,NSwitch as oe,NPopover as re}from"naive-ui";import ae from"cnhis-design-vue/es/packages/grid";import se from"cnhis-design-vue/es/src/utils/vexutils";import{handleTableHeight as ce,setTableConfig as de,handleGroupColums as ue,checkMethod as he,setTreeGroupTitle as pe,handleName as ge,generateEditRender as me,handlerInitSearchItem as fe,getEvaluate as be,getMapVal as ve,getCandidateComponents as Ce,getageShowType as we,isLink as Te,showFilter as ke,reScrollFilterWrap as ye,hideFilterWrap as Se,mergeConObjFn as xe,setDefaultFormData as Ne,handleImgArr as Ee,handleImgSrc as Re,modalDetailImage as Ie,handleQrCodeContent as Oe,getInlineEditBtn as Le,isCopy as Fe,setVisibleCheckAllWrap as Ae,setFilterStatus as De,handleTableImageSize as _e,getRowStyle as Me,getFooterGroup as Be,flattenRow as Pe,intersectRow as Ve,removeCheckedDisabledRows as je}from"./utils2.mjs";import ze from"cnhis-design-vue/es/src/assets/img/xb_big.png";import $e from"cnhis-design-vue/es/src/assets/img/qr.png";import Ke from"./components/NoData.vue_vue_type_script_setup_true_lang.mjs";const Ue={key:0,class:"check-wrap"},He=C("span",null,"系统检测到有数据更新,",-1),qe={class:"check-wrap"},We={class:"check-wrap-title"},Je={key:0},Ge={key:1},Ze={class:"check-wrap"},Qe={class:"check-wrap-title"},Xe={key:0},Ye=C("i",{class:"disabled-checked-tips"},null,-1),et=["innerHTML"],tt=["innerHTML"],lt={class:"refresh-row"};function it(e){return"function"==typeof e||"[object Object]"===Object.prototype.toString.call(e)&&!h(e)}var nt=e({name:"BigTable",props:L,emits:F,setup(e,{expose:h,emit:L}){const F=e;let nt=null,ot=[],rt="";const at="group-show-title",st=W(),ct=t({}),dt=se.clone(O,!0),ut=l(dt),{formatData:ht,htmlToText:pt,getBtnStyle:gt}=A(ut),{imgs2imgArr:mt,parseDurationValue:ft,parseCombinationValue:bt,formatFieldText:vt}=D(ht),{allSelectedLength:Ct,checkOperateCurrentTable:wt,setRowStatus:Tt,resetBatchOperationRowStatus:kt,checkListFormUnionSettingParamsList:yt,handleClickCancelBtnByInline:St,setAllRowInlineStatus:xt,hideSelectCloumns:Nt,handleEditFormLength:Et,resetOperationRowStatus:Rt,recordClickBtnInfo:It,getInlineOpreateRow:Ot}=_(F,ut,L,ct),{initEditTable:Lt,activeMethod:Ft,deleteRow:At,onClickSelectTable:Dt,onFormChange:_t,getDefaultValue:Mt}=B(F,ut,L,ct),{isAboutNestTable:Bt,isExpandTable:Pt,handleRowId:Vt,toggleExpandMethod:jt,loadExpandMethod:zt,nestHandleClickRow:$t}=M(F,ut,L),{keyDown:Kt,scroll:Ut}=V(F,ut,L,ct),Ht=i(),qt=n((()=>{var e;return(null==(e=ut.checkedRows)?void 0:e.map((e=>e[F.primaryKey])))||[]})),Wt=n((()=>{let e=ut.currentPageSelectedLength===ut.curAbleCheckedLen,t=qt.value.length===F.maxCheckSize,l=qt.value.length===F.pageVO.total;return t||!e||l})),Jt=n((()=>{const e=qt.value||[];return 1==e.length?e[0]:""})),Gt=n((()=>{var e;let{noSetting:t}=xl()||{};return t||1==(null==(e=F.showSettings)?void 0:e.hideSettingBtn)})),Zt=n((()=>{var e;return null==(e=F.columnConfig)?void 0:e.isScanMultiTable})),Qt=n((()=>({userInfo:F.userInfo||{},sysImageSize:F.sysImageSize||{}}))),Xt=n((()=>ut.isTree>0&&F.primaryKey||"theUniqueKey")),Yt=n((()=>{if(F.isNestTable)return{startIndex:0};if(F.isBatchEditing)return{startIndex:0};let e=(F.pageVO.pageIndex-1)*F.pageVO.pageSize;return{startIndex:e<0?0:e}})),el=n((()=>{let e=null;switch(Number(ut.isTree)){case 1:case 3:e={children:"childrenList",accordion:ut.openOnly>0,reserve:!0};break;case 2:e={lazy:!0,reserve:!0,children:"childrenList",hasChild:"hasChildren",loadMethod:Ll,accordion:ut.openOnly>0}}return e})),tl=e=>{const t=e.path||e.composedPath&&e.composedPath();var l;(l="big-table-filter-wrap",!t.some((e=>e.className&&e.className.includes&&e.className.includes(l))))&&Se(ut,F)},ll=()=>{nt=tl.bind(this),window.document.addEventListener("click",nt,!0)};o((()=>{ll(),ut.tableHeight=ce(ut,F)||"auto",F.isNestTable&&(nl(F.columnConfig),ol(F.data))})),r((()=>{window.document.removeEventListener("click",nt,!0)})),a((()=>{il()}));const il=async()=>{var e;if(0!=ut.isTree)return!1;const t=ct.value;let{tableData:l}=t.getTableData();l&&l.length&&l.forEach((e=>{(null==e?void 0:e.__isInsertRow)&&t.remove(e)})),(null==(e=ut.originFormatList)?void 0:e.length)&&(await t.loadData(ut.originFormatList),kt())},nl=e=>{de(e,ut);let t=cl(e);t=ue(t,F),ct.value&&ct.value.reloadColumn(t),Tl(),kl()},ol=async e=>{ut.isShowEmpty=!(null==e?void 0:e.length);const t=JSON.parse(JSON.stringify(e));let l=ct.value;if(!l)return;ut.checkedRows=[];let i=Al(t);ut.originFormatList=i,rl(i),ut.curAbleCheckedLen=t.filter((e=>he({row:e}))).length,F.isNestTable||await ii(),i=i.map((e=>({...e,selectTableShow:!1,selectTableDisable:!1}))),await l.loadData(i),l.setCurrentRow({}),al(),Tl(),kl()},rl=e=>{var t;if(3!=ut.isTree)return;let l=null==(t=ct.value.getTableColumn().tableColumn)?void 0:t.find((e=>!!e.property)).property;pe(e,l,at)},al=()=>{var e;let t=ct.value;if(!t)return;let l=(null==(e=t.getTableData())?void 0:e.tableData).filter((e=>F.primaryKey?qt.value.includes(e[F.primaryKey]):e.checked));sl(),l&&l.length?t.setCheckboxRow(l,!0):t.setAllCheckboxRow(!1)},sl=()=>{let e=ct.value.getTableData().fullData.filter((e=>qt.value.includes(e[F.primaryKey])||e.checked));ut.currentPageSelectedLength=e.length},cl=e=>{var t,l;let{selectType:i}=xl()||{},{isBatchSelect:n,fieldList:o=[],showButtonTop:r,isScanMultiTable:a,isEdit:c=!1,editConfig:d={},rowConfig:u={}}=e;c&&(ut.editConfig=Object.assign(ut.editConfig,d),ut.rowConfig.height=48),ut.rowConfig.height=Object.assign(ut.rowConfig.height,u),i&&(n=1),i=i||"checkbox";let{listType:h}=F.tableOptions;"scanList"==h&&(i="radio"),ut.selectType=i;let p=(null==(t=F.styleSetting)?void 0:t.tableHeight)||"table-simple",g=ut.checkWidth[p]||"30";const m={default:e=>he(e)?null:s(G,{placement:"right",trigger:"hover"},{default:()=>e.row.forbiddenBatchSelectReason,trigger:()=>s("i",{class:"disabled-checked-tips"},null)})};let f=1==n&&!F.isNestTable&&!a||!1,b=[{fixed:"left",align:"center",visible:a||!1,width:"60",slots:{header:()=>"操作",default:Xl}},{type:"seq",fixed:F.isNestTable?"":"left",align:"center",resizable:!0,width:"34",showOverflow:!0,slots:{header:()=>[Gt.value?null:s(J,{size:"14",color:"#777",component:j,onClick:()=>Wl()},null)]}},{type:i,fixed:F.isNestTable?"":"left",align:"center",visible:f,resizable:!1,width:g,slots:"checkbox"===i?m:null,showOverflow:!0}];const v=b.find((e=>"seq"==e.type));(null==(l=null==F?void 0:F.columnConfig)?void 0:l.seqSlotFn)&&(v.slots.default=e=>{var t;return null==(t=F.columnConfig)?void 0:t.seqSlotFn(e)});const C=o.map(((e,t)=>{var l,i,n,o;let d="manual"===(null==(i=null==(l=null==e?void 0:e.fieldSetting)?void 0:l.mapping)?void 0:i.type)&&1!=e.isMerge,u=(null==(n=null==e?void 0:e.fieldSetting)?void 0:n.notParticipatingSort)||"",h=Bt.value?"":e.isFixed?1==e.isFixed?"left":"right":"",p=!F.isNestTable&&(!d&&1==e.isSort&&1!=u&&1!=e.isMerge),g=!F.isNestTable&&(0!=ut.isTree&&0===t),m=0===t&&F.showNestTable?"expand":"";a&&(h="",p=!1,g=!1,m="");const f=Object.assign(e,{visible:"operatorColumn"==e.columnName?0==r:1==e.isShow,field:e.columnName,title:ge(e,"title"),minWidth:e.colWidth,fixed:h,sortable:p,headerClassName:"mycolumn",showOverflow:"title",treeNode:g,type:m,slots:{edit:t=>c&&e.isEdit&&"operatorColumn"!==e.columnName?dl(t,e):s("span",null,[t.row[e.columnName]]),default:t=>c&&"operatorColumn"!==e.columnName&&e.isEdit?c&&e.isEdit&&e.checkEditStatus&&e.checkEditStatus(t)?dl(t,e):s("span",null,[Mt(t,e)]):ul(t,e)},editRender:c?{}:me(e)});if(!d||F.isNestTable||a)f.slots.header=yl(e);else{ut.filterFields[e.columnName]=Object.assign({},se.clone(e,!0),{visible:!1,left:"initial",right:"initial",top:"initial",indeterminate:!1,checkAll:!1,searchFilterText:"",searchFilterCONVERT:[],filterSort:""});let t=ut.filterFields[e.columnName];fe([t]),f.slots.header=hl(e)}return a||(f.slots.footer="tooltip_footer"),F.showNestTable&&0==ut.isTree&&0==(null==(o=F.curNestColumnConfig)?void 0:o.isTree)&&(f.slots.content="nest_table_content"),f}));return b.push(...C),ut.columnLen=C.filter((e=>e.visible)).length,b},dl=(e,t)=>{let{row:l,column:i,$rowIndex:n,rowIndex:o}=e,r=i.formType||t.formType||"",a=i.formatMap||t.formatMap||null;if(!r)return null;if("custom"===r&&t.slotFn)return t.slotFn(e);const s=P[r]||"";if(!s)return null;const d={col:t,row:l,index:n,type:r,onFormChange:_t};return"date"===r?d.formattedValue=l[t.columnName]:d.value=a?l[a.value]:l[t.columnName],"select"===r&&(d.onSetOptions=e=>l[`${t.columnName}_options`]=e),c(s,d)},ul=(e,t)=>{var l,i;let{row:n,column:o,$rowIndex:r}=e,a=(null==o?void 0:o._own)||(null==o?void 0:o.own)||t,c=(null==a?void 0:a.attrType)||"",u=Yl(n,o,r);if(u){if(ei(u,n,o))return L("setWaitEditKeys",o.property),null}if(se.has(n,at))return n[at];if("PICTURE"==c||"HEADPORTRAIT"==c)return ni(n,a,c);if("COLOR"==c)return oi(n,a);if("EVALUATE"==c)return be(n,a);if("MAP"==c)return ve(n,a);if("DATE"==c||"TASKDATE"==c)return ri(n,a);if("PERCENTAGE"==c)return ai(n,a);if("VIDEO"==c)return si(n,a);if("CANDIDATE_COMPONENTS"==c)return Ce(n,a);if("AGE"==c)return we(n,a);if("COUNTDOWN"===c)return s(G,null,{trigger:()=>s("span",{innerHTML:n[a.columnName+"_countdown"]||""},null),default:()=>n[a.columnName+"_countdownTip"]});if("DURATION"===c){const e=n[a.columnName],t=null==(l=null==a?void 0:a.fieldSetting)?void 0:l.duration;return ft(e,t)}if("COMBINATION"===c){const e=n[a.columnName],t=a.fieldSetting||{},l=bt(e,t);return l?[s("span",{title:l},[l])]:""}if("PASSWORD"===c){const e=n[a.columnName];return[s(d("password-com"),{value:e,styleSetting:F.styleSetting},null)]}if("QR_CODE"===c)return ci(n,a);if("operatorColumn"===o.property){if("custom"===(null==t?void 0:t.formType)&&t.slotFn&&!n.initRow)return t.slotFn(n,t,r);if(F.columnConfig.isEdit&&!n.initRow)return((e,t,l)=>{var i;return null==(i=t.tileBtnList)?void 0:i.map((i=>"DELETE"===i.settingObj[0].trigger_type?s(Z,{onPositiveClick:()=>At(e,t,l)},{trigger:()=>s(Q,{color:i.settingObj[0].color||"#999",text:!0},{default:()=>[i.name]}),default:()=>"是否确认删除?"}):null))})(n,t,r);if(0!=ut.showButtonTop||F.isBatchEditing)return;const e=ui(n),l=hi(n,r),i=mi(n,r);return[s("span",null,[l,i,e])]}if(Te(F,a,n)&&!Zt.value){if(a.btnLinkSwitch){let e=!1,t=null==(i=n.btnList)?void 0:i.find((e=>e.name==a.columnName));return t&&"authorizedMark"in t&&(t.authorizedMark||(e=!0)),fi(n,a,e,r)}return bi(n,a,r,!0)}return bi(n,a,r,!1)},hl=e=>{let t=ut.filterFields[e.columnName];return()=>{var l;let i,n;return[s("div",{class:"filter-box"},[yl(e,"format"),s("i",{class:["vxe-filter--icon","vxe-filter--btn","vxe-icon--funnel",{active:t.visible||t.filterSort},{checked:null==(l=t.CONVERT)?void 0:l.length}],onClick:l=>ke(t,e.columnName,l,F,ut)},null),t.visible?s(d("teleport"),{to:F.filterDomPortal},{default:()=>[s("div",{class:"big-table-filter-wrap",style:{left:t.left,right:t.right,top:t.top,width:ut.filterWidth+ut.distance+"px"}},[s("div",{class:"sort-list",style:{display:t.isSort?"block":"none"}},[s("div",{class:["sort-item",{active:"asc"===t.filterSort}],onClick:()=>pl("asc",t)},[s("i",{class:"sort-icon sort-icon-asc"},null),s("span",{class:"sort-text"},[u("升序 A to Z")])]),s("div",{class:["sort-item",{active:"desc"===t.filterSort}],onClick:()=>pl("desc",t)},[s("i",{class:"sort-icon sort-icon-asc"},null),s("span",{class:"sort-text"},[u("降序 Z to A")])])]),s("div",{class:"filter-header"},[s("i",{class:"filter-header-icon vxe-filter--btn vxe-icon--funnel"},null),s("span",{class:"filter-header-text"},[u("筛选")])]),t.setting.showSetting.length>5?s("div",{class:"checkbox-wrap checkbox-wrap--search"},[s("div",{class:"check-search-wrap"},[s(X,null,{default:()=>[s(Y,{style:{width:"50%"},placeholder:"字段搜索",class:"check-seach-input"},null),s(Q,{type:"primary",onClick:e=>{gl(e,t)}},{default:()=>[u("搜索")]})]})])]):"",s("div",{class:"checkbox-box"},[s("div",{class:"checkbox-wrap js-checkbox-wrap",style:{height:ut.filterHeight+ut.distance+"px"}},[t.searchFilterText?"":s("div",{class:"ant-checkbox-group"},[s(ee,{indeterminate:t.indeterminate,checked:t.checkAll,onUpdateChecked:e=>{ml(e,t)}},{default:()=>[u("全选")]})]),t.searchFilterText?s(te,{value:t.searchFilterCONVERT,onUpdateValue:l=>bl(l,e.columnName,t)},{default:()=>[s(le,{"item-style":"display: flex;"},it(n=t.setting.showSetting.filter((e=>{if(!t.searchFilterText)return e;return new RegExp(t.searchFilterText).test(e.label)})).map((e=>s(ee,{value:e.value,label:e.label},null))))?n:{default:()=>[n]})]}):s(te,{value:t.CONVERT,onUpdateValue:l=>fl(l,e.columnName,t)},{default:()=>[s(le,{"item-style":"display: flex;"},it(i=t.setting.showSetting.map((e=>s(ee,{value:e.value,label:e.label},null))))?i:{default:()=>[i]})]})])]),s("div",{class:"checkbox-btn-wrap",style:{justifyContent:t.CONVERT.length?"space-between":"flex-end"}},[t.CONVERT.length?s("div",{class:"checkbox-btn-status"},[s("span",null,[u("已选择"),t.CONVERT.length,u("项")]),s(Q,{class:"checkbox-btn checkbox-btn-clear",text:!0,onClick:()=>vl(t)},{default:()=>[u("清空")]})]):null,s("div",null,[s(Q,{class:"checkbox-btn",onClick:()=>Cl()},{default:()=>[u("取消")]}),s(Q,{class:"checkbox-btn",type:"primary",onClick:()=>wl(t)},{default:()=>[u("确定")]})])]),s("div",{class:"arrows-icon"},null)])]}):""])]}},pl=(e,t)=>{t.filterSort===e?e=null:ct.value.clearSort(),t.filterSort=e,L("sortChange",{prop:t.columnName,order:e})},gl=(e,t)=>{if(t.searchFilterText=e,""===e)return t.checkAll=t.CONVERT.length===t.setting.showSetting.length,void(t.indeterminate=!!t.CONVERT.length&&t.CONVERT.length!==t.setting.showSetting.length);t.searchFilterCONVERT=t.setting.showSetting.filter((e=>t.searchFilterText===e.label&&t.CONVERT.includes(e.value))).map((e=>e.value)),ot=t.searchFilterCONVERT},ml=(e,t)=>{ye();let l=e.target.checked;t.indeterminate=!1,t.checkAll=l,ut.filterFields[t.columnName].CONVERT=l?t.setting.showSetting.map((e=>e.value)):[]},fl=(e,t,l)=>{ye(),ut.filterFields[t].CONVERT=e,l.checkAll=e.length===l.setting.showSetting.length,l.indeterminate=!!e.length&&e.length!==l.setting.showSetting.length},bl=(e,t,l)=>{if(ye(),ot.length<e.length){let l=e.filter((e=>!ot.includes(e)));ut.filterFields[t].CONVERT.push(...l)}else{let l=ot.filter((t=>!e.includes(t)));ut.filterFields[t].CONVERT=ut.filterFields[t].CONVERT.filter((e=>!l.includes(e)))}l.searchFilterCONVERT=e,ot=se.clone(e,!0)},vl=e=>{e.indeterminate=!1,e.checkAll=!1,ut.filterFields[e.columnName].CONVERT=[],e.searchFilterCONVERT&&(ut.filterFields[e.columnName].searchFilterCONVERT=[]),wl(e)},Cl=()=>{Se(ut,F)},wl=e=>{let t=xe(ut,F);L("onSave",t,!1,[],[],{isBigTable:!0}),e.visible=!1},Tl=()=>{let e=1==ut.isTree&&1==ut.isExpand&&ut.total<1001;if(3==ut.isTree||e){let e=ct.value;p((()=>{e.setAllTreeExpand(!0)}))}},kl=()=>{if(!wt())return!1;St()},yl=(e,t)=>{var l;let i=e.formTitle||e.alias||e.title,n=e.alias,o=!1;return"guage"==(null==(l=F.tableOptions)?void 0:l.dataSourceType)&&(n=e.alias||e.title),i&&n&&i!==n&&(o=!!n),"format"===t?s(H,{tooltipTitle:n,content:i,isAlias:o},null):()=>[s(H,{tooltipTitle:n,content:i,isAlias:o},{default:()=>[e.treeNode&&1==ut.isTree?s(J,{component:ut.isExpand&&ut.total<1001?z:$,onClick:e=>Sl(e,ut.isExpand)},null):""]})]},Sl=(e,t)=>{e.preventDefault(),e.stopPropagation();let l=ct.value;ut.total>1e3?st.warning("当前数据量超过1000条,无法全部展开!"):(ut.isExpand=!t,t?l.clearTreeExpand():(L("triggerSpinning",!0),setTimeout((()=>{l.setAllTreeExpand(!0).then((()=>{L("triggerSpinning",!1)}))}),100)))},xl=()=>{let e=(null==Ht?void 0:Ht.tableOptions)||F.tableOptions||{};return(null==e?void 0:e.config)||{}||void 0},Nl=()=>{ut.hasRefresh=!1,L("refreshTable")},El=()=>{if(F.pageVO.total>F.maxCheckSize){let e=`当前列表共${F.pageVO.total}条数据,为了确保系统安全,只能单次操作${F.maxCheckSize}条,你可以通过高级筛选过滤再次尝试`;st.warning(e)}L("selectionChangeAll")},Rl=()=>{L("selectionChangeAllCancel")},Il=()=>"checkbox"===ut.selectType?({row:e})=>{const t=Jt.value;return t&&t===e[F.primaryKey]?"single--checked":""}:()=>{},Ol=({columns:e,data:t})=>{if(!F.groupCountFields||!F.groupCountFields.length)return[e.map(((e,t)=>null))];let l=Be(e,t,F),i=e.map(((e,t)=>0===t?null:1===t?l:null));return L("setGroupText",l),ut.groupText=l,[i]},Ll=({row:e})=>{const t=t=>{const l="checkbox"==ut.selectType&&e.checked&&t.findIndex((e=>!he({row:e})))>=0;l&&(l&&(e.checked=!1),setTimeout((()=>{var t;null==(t=ct.value)||t.setCheckboxRow(e,!0)}),0))};if(2==ut.isTree){const{tableId:l,page:i,pageSize:n,autograph:o,isTreeOrList:r}=F.tableParams;return e[F.primaryKey],Fl().then((({data:e})=>{if("SUCCESS"==e.result){let l=JSON.parse(JSON.stringify(e.map.rows)),{fieldList:i,btnList:n,showButtonTop:o}=F.columnConfig,r=ht({tableList:e.map.rows,fieldList:i,btnList:n,showButtonTop:o});return r=Al(r),L("refreshOldTableData",l),t(r),r}}))}return t(e.childrenList),Promise.resolve(e.childrenList)},Fl=e=>Promise.resolve(),Al=e=>e.map((e=>{if(e.checked=e.checked||!1,2==ut.isTree){const t=ut.levelLazyLoadSetting.childCountKey,{isTreeOrList:l=""}=F.tableParams;t&&Number(e[t])>0&&"LIST"!=l&&(e.hasChildren=!0)}return e.childrenList&&e.childrenList.length&&(e.childrenList=Al(e.childrenList)),Object.keys(e).map((t=>{e[t]&&"string"==typeof e[t]&&-1!==e[t].indexOf("<p")&&-1===t.indexOf("_temp_"+e.id)&&(e[t+"_temp_"+e.id]=e[t]||"",e[t]=pt(e[t]))})),e.checked&&ut.checkedRows.push(e),{...e}})),Dl=({row:e,column:t,_rowIndex:l,_columnIndex:i})=>{if(3!=ut.isTree)return{rowspan:1,colspan:1};let n=ct.value,o=n.getTableColumn().tableColumn.findIndex((e=>!!e.property)),r=n.getTableColumn().tableColumn.length-o;return e.childrenList&&e.childrenList.length&&n?t.treeNode?{rowspan:1,colspan:r}:t.property?{rowspan:0,colspan:0}:{rowspan:1,colspan:1}:void 0},_l=e=>{if(!F.groupCountFields||!F.groupCountFields.length)return{rowspan:1,colspan:1};let{$rowIndex:t,_columnIndex:l,column:i}=e,n=ut.columnLen||99,{isBatchSelect:o}=F.columnConfig;return 0===t?1==o?0===l?{rowspan:1,colspan:2}:1===l?{rowspan:1,colspan:0}:2===l?{rowspan:1,colspan:n}:{rowspan:1,colspan:0}:0===l?{rowspan:1,colspan:1}:1===l?{rowspan:1,colspan:n}:{rowspan:1,colspan:0}:void 0},Ml=({row:e,column:t})=>!Zt.value&&!F.isInlineOperating&&(!se.has(e,at)&&(L("setNestTableClick",F.isNestTable),void L("rowdblclick",e,t,!0,!0))),Bl=(e=[])=>{ut.treeTableLength=e.filter((e=>!se.has(e,at))).length,ut.visibleTreeCheck=e.length>1,L("selectionChange",e)},Pl=(e,t=!1)=>{let l={isUpdate:!0,updateRows:e,isTree:t};t&&Object.assign(l,{isTree:t,isCheckedChange:!0,checkedRows:ut.checkedRows}),L("selectionChangeLocal",l)},Vl=(e,t)=>{je(ut);let l=ut.checkedRows,i=[];for(let t=0;t<e.length;t++){let l=e[t],n=qt.value.findIndex((e=>e===l[F.primaryKey]));n>=0&&i.push(n)}i.sort(((e,t)=>t-e)),L("selectionChangeLocal",{isAdd:!1,isCheckedChange:t,needRemoveIndexs:i,newCheckedRows:[],checkedRows:l})},jl=e=>{if(Zt.value||F.isInlineOperating)return!1;if(se.has(null==e?void 0:e.row,at))return!1;if(ut.isTriggerSelectionChange&&0==ut.isTree)return!1;let t=ct.value;Bt.value&&L("resetNestLastClickTable",t);let{row:l,$event:i={},$rowIndex:n}=e,{className:o}=i.target||{};if(o&&se.isString(o)&&o.includes("vxe-table--expand-btn"))return;if(Bt.value&&L("setNestLastClickTable",t,F.isNestTable,l[Vt.value],l),L("setNestTableClick",!1),F.isNestTable)return null==t||t.setAllCheckboxRow(!1),void $t(t,e);let r=!he(e);if("checkbox"==ut.selectType&&r){null==t||t.setAllCheckboxRow(!1);const e="single--checked"==Il()({row:l})?[]:[l];return ut.checkedRows=e,Bl(e),void L("handlerClickRow",l,n)}ut.visibleCheckAllWrap=!1,ut.visibleCheckAllWrapMore=!1;let a=!1;a="radio"==ut.selectType?t.isCheckedByRadioRow(l):t.isCheckedByCheckboxRow(l),ut.isradioChange&&(a=!1,ut.isradioChange=!1);let s=t.getCheckboxRecords(),c=ut.checkedRows.filter((e=>!se.has(e,at))).length,d=[];if(0!=ut.isTree){let{className:e}=i.target||{};if(e&&e.includes("vxe-tree--node-btn"))return;if("checkbox"===ut.selectType){let e={};if(ut.isTriggerSelectionChange){if(s.length>1)return!1;e=a||1===s.length&&!a?s[0]:{},ut.checkedRows=[e]}else t.setAllCheckboxRow(!1),ut.checkedRows=[l],Bl([l]),e=l;return Pl(e,!0),void L("handlerClickRow",e)}let n=[];Pe(l,d,n,Vt.value),c=Ve(s,n,Vt.value)?s.filter((e=>!se.has(e,at))).length:1}t.setAllCheckboxRow(!1);let u=a;c>1?("radio"!=ut.selectType&&t.setCheckboxRow([l],!0),0!=ut.isTree&&"radio"!=ut.selectType&&Bl(d),"radio"!=ut.selectType&&L("handlerClickRow",l,n)):(u=!u,u?("radio"==ut.selectType&&t.setRadioRow(l),0!=ut.isTree&&"radio"!=ut.selectType&&Bl(d)):(t.clearCurrentRow(),"radio"==ut.selectType&&t.clearRadioRow(),0!=ut.isTree&&"radio"!=ut.selectType&&Bl([])),"radio"!=ut.selectType&&t.setCheckboxRow([l],u)),0==ut.isTree?(((e,t)=>{e?Pl(t):F.pageVO.pageIndex==ut.lastPageIndex&&qt.value.includes(t[F.primaryKey])?Vl([t]):Pl(t)})(u,l),(u||c>1||!c)&&(ut.checkedRows=[l]),u||1!==c||(ut.checkedRows=[]),sl(),ut.lastPageIndex=F.pageVO.pageIndex,u&&L("handlerClickRow",l,n)):u&&L("handlerClickRow",l,n)},zl=e=>{je(ut);let t=ut.checkedRows;if(qt.value.length+e.length>F.maxCheckSize)return st.warning(`为了保证系统安全,单次操作数据量限额为${F.maxCheckSize}条,你可以通过高级筛选过滤后再次尝试`),!1;let l=e.filter((e=>!qt.value.includes(e[F.primaryKey])));t.push(...l),L("selectionChangeLocal",{isAdd:!0,isCheckedChange:!0,newCheckedRows:l,checkedRows:t})},$l=e=>0!=ut.isTree&&(Bl(e),!0),Kl=({checked:e,row:t,records:l})=>{ct.value.clearCurrentRow(),ut.isTriggerSelectionChange=!0,setTimeout((()=>{ut.isTriggerSelectionChange=!1}),0),$l(l)||(e?zl([t]):Vl([t],!0),sl())},Ul=({checked:e,records:t})=>{$l(t)||(e?zl(t):Vl(F.data),sl())},Hl=(e={})=>{let{data:t,row:l,$rowIndex:i}=e;L("selectionChange",[{...l}])},ql=({property:e,order:t})=>{if(F.isInlineOperating)return!1;Object.values(ut.filterFields).forEach((e=>e.filterSort=null)),L("sortChange",{prop:e,order:t})},Wl=()=>{const e=ct.value.$el.childNodes[0].childNodes[1].childNodes[0].getElementsByClassName("mycolumn");L("setNestTableClickSetting",F.isNestTable),L("showDrawer",e)},Jl=({column:e,$event:t})=>{if("title"===e.showOverflow){const e=null==t?void 0:t.currentTarget,l=null==e?void 0:e.className,i=" vxe-body--column ";if(l&&` ${l} `.includes(i)&&e&&e.hasAttribute("title")){const t=e.querySelector(".vxe-cell");t&&t.hasAttribute("title")&&t.removeAttribute("title"),F.isInlineOperating&&e&&e.hasAttribute("title")&&e.removeAttribute("title")}}},Gl=e=>{let t="";return se.has(F.sumData,e.property)&&(t+=`<p class="table-footer-tooltip-label-wrap">\n <span class="table-footer-tooltip-label">求和:</span>\n ${se.round(Number(F.sumData[e.property]),4)}\n </p>`),se.has(F.avgData,e.property)&&(t+=`<p class="table-footer-tooltip-label-wrap">\n <span class="table-footer-tooltip-label">平均值:</span>\n ${se.round(Number(F.avgData[e.property]),4)}</p>`),t},Zl=e=>se.has(F.sumData,e.property)?se.round(Number(F.sumData[e.property]),2):se.has(F.avgData,e.property)?se.round(Number(F.avgData[e.property]),2):void 0,Ql=()=>{L("pubTableRefresh")},Xl=e=>s(Z,{onPositiveClick:()=>(e=>{let{row:t,$rowIndex:l}=e||{};t&&(L("scanMultiRemove",l,e),ct.value.remove(t))})(e)},{trigger:()=>s(q,{class:"scan-multi-delete",iconClass:"shanchu"},null),default:()=>"是否确认删除?"}),Yl=(e,t,l)=>{if(!F.isMatchComponent||F.isNestTable||Zt.value)return!1;if(F.isBatchEditing||F.isInlineEditing||F.isInlineAdding){let i=ut.editColumnMap[t.property];if(!i||!i.matchItem||!i.fieldItem)return!1;if(F.isBatchEditing&&!F.isEditAllRow){if(ut.checkedRows.findIndex((t=>t[F.primaryKey]==e[F.primaryKey]))<0)return!1}return(!F.isInlineEditing&&!F.isInlineAdding||0===l)&&i.matchItem}return!1},ei=(e,t,l,i)=>{let n=t[F.primaryKey],o=F.batchDynamicPropsCache[n];if(o&&o[e.tableField])return o[e.tableField];let r=ut.editColumnMap[l.property],{fieldItem:a={}}=r||{},s={};if(!F.isInlineAdding){let e=F.pageIndexOldtableData.find((e=>e[F.primaryKey]==t[F.primaryKey]));s=Ne(l.property,a,e)}let c={props:{formPrimaryKey:n,defaultForm:{fieldList:[JSON.parse(JSON.stringify(a))],defaultCombinationForm:s},banRequest:!0,propsFormBtn:!0,propsDelSetting:!0,parentConfig:{is_edit:"1"},configuration:Qt.value,isPure:!0,isOpenShortcut:!1,cacheUniqueKey:ut.cacheUniqueKey,styleSetting:{}},on:{handleSubmit:ti,banSubmit:li}};return L("setBatchDynamicPropsCache",{primaryKey:t[F.primaryKey],tableField:e.tableField,dynamicProps:c}),c},ti=(e={})=>{F.isInlineEditing||F.isInlineAdding?L("submitEditFormSuccess",e):F.isBatchEditing&&L("submitEditFormSuccessBatch",e)},li=e=>{F.isInlineEditing||F.isInlineAdding?L("submitEditFormError"):F.isBatchEditing&&L("submitEditFormErrorBatch",e)},ii=async()=>{var e;L("initInlineEditFormConfig",{listFormUnionSetting:F.listFormUnionSetting,inlineEditFormConfig:F.inlineEditFormConfig});null==(e=F.btnList)||e.find((e=>{var t;let l=e.settingObj&&(null==(t=e.settingObj[0])?void 0:t.trigger_type);return 1==e.isShow&&"EDIT_ROW"==l}))},ni=(e,t,l)=>[s("div",{class:["img-wrap","HEADPORTRAIT"===l?"img-circle":""]},[Ee(e[t.columnName],l,mt).map(((l,i)=>s("img",{key:i,src:Re(l,F.sysImageSize,"LIST_FIELD_SMALL"),style:Ie(F.sysImageSize,"LIST_FIELD_SMALL","36px"),onClick:l=>((e,t,l)=>{l.preventDefault(),l.stopPropagation(),e||(e=ze),L("handlePreView",e,t)})(e[t.columnName],i,l)},null)))])],oi=(e,t)=>{let l=e[t.columnName];if(null==l?void 0:l.includes("-")){let e=l.split("-")[1];l=se.oldColorMap(e)}return[s("div",{class:"color-wrap",style:"height: 100%; padding: 4px;"},[s("div",{style:{background:l,height:"100%"}},null)])]},ri=(e,t)=>{let l=e[t.columnName]||"";return!se.isEmpty(l)&&se.isObject(l)&&"tooltip"in l?[s(d("n-tooltip"),null,{default:()=>[{trigger:()=>s("span",null,[l.value])},s("span",{innerHTML:l.tooltip},null)]})]:[s("span",{innerHTML:l},null)]},ai=(e,t)=>{let l=e[t.columnName];if(!l&&0!==l)return;let i=l;if(/<\/?span.*?>/g.test(l)){let e=document.createElement("span");e.innerHTML=l,l=e.textContent,i=l}l&&se.isString(l)&&l.includes("%")&&(i=Number(l.replace("%","")));let n="#52c41a";return i<15?n="#ff5500":i<50?n="#ff8b01":i<90&&(n="#1890ff"),i>100?i=100:i<0&&(i=0),[s("div",{class:"percent-wrap"},[s("span",{class:"percent-value"},[i,u("%")]),s(ie,{percentage:i,showIndicator:!1,color:n},null)])]},si=(e,t)=>{let l=e[t.columnName];return Array.isArray(l)&&(l=JSON.stringify(l)),null},ci=(e,t,l)=>[s("span",{class:"bigTable-qr-span",onClick:l=>di(l,e,t)},[s("img",{class:"bigTable-qr-img",src:$e},null),s("span",null,[s(q,{iconClass:"fangda"},null)])])],di=(e,t,l)=>{e.preventDefault(),e.stopPropagation();let i=Oe(t,l);L("qrCodeEvent",i)},ui=(e,t)=>{if(F.isNestTable)return;let l=[];return l.push(...Le(e,"tileBtnList")),l.push(...Le(e,"foldBtnList")),(null==l?void 0:l.length)?[s("span",null,[s(Q,{style:{display:e.__isInlineEditing?"inline-block":"none"},onClick:e=>{e.stopPropagation(),L("SET_SAVE_ROW_STATUS",!0)},class:"btn-custom-class row-btn",size:"small",text:!0},{default:()=>"保存"}),s(Q,{style:{display:e.__isInlineEditing?"inline-block":"none"},onClick:e=>{e.stopPropagation(),L("SET_CANCEL_ROW_STATUS",!0)},class:"btn-custom-class row-btn",size:"small",text:!0},{default:()=>"取消"})])]:void 0},hi=(e,t)=>{var l;return[(null==(l=e.tileBtnList)?void 0:l.length)&&e.tileBtnList.map(((l,i)=>"1"==l.isShow&&"LINK"!=l.type&&s(Q,{key:l.sid,onClick:i=>pi(e,l,t,i),class:"btn-custom-class row-btn",style:{...gt(l),display:e.__isInlineEditing?"none":"inline-block"},disabled:e.__isDisableInlineEdit,ghost:"white_bg"==l.showStyle,size:"small"},{default:()=>[gi(l),"only_icon"===l.showStyle?"":ge(l)]})))||""]},pi=(e,t,l,i,n)=>{i.preventDefault(),i.stopPropagation(),It(e,l),L("setNestTableClick",F.isNestTable),L("setCurRowIndex",l),L("clickBtn",e,t,e[Xt.value],l)},gi=(e,t="8px")=>{let l;return e.icon?l=ut.btnIcons[e.icon]?s(d("a-icon"),{type:ut.btnIcons[e.icon]},null):s(G,null,{trigger:()=>s(q,{iconClass:e.icon,style:{marginRight:t}},null),default:()=>ge(e)}):e.iconSetting&&(l=s(q,{iconClass:JSON.parse(e.iconSetting).icon,style:{marginRight:t}},null)),[l]},mi=(e,t)=>{var l;return[(null==(l=e.foldBtnList)?void 0:l.length)&&s(ne,{style:{display:e.__isInlineEditing?"none":"inline-block"},disabled:F.isInlineOperating,options:e.foldBtnList.map(((l,i)=>({label:`${ge(l)}${gi(l,"0")}`,key:l.sid,props:{onClick:i=>{pi(e,l,t,i.domEvent)}}})))},{default:()=>[s(Q,{size:"small",style:"margin-left: 8px"},{default:()=>"更多 ..."})]})||""]},fi=(e,t,l,i)=>{let n=(0!==ut.isTree?e:F.oldtableData[i])[t.columnName];if("string"==typeof n&&n&&n.startsWith("###{")){let e=JSON.parse(n.replace("###",""));n=e.tooltip||e.value}return[s(oe,{value:n==t.btnLinkSwitchDefVal,disabled:l,onUpdateValue:l=>((e,t,l,i)=>{L("switchBtnOnChange",e,t,l,i)})(l,e,t,i)},null)]},bi=(e,t,l,i)=>{const n=vt(e,t,F.columnConfig.fieldList,F.fieldListOriginal),o=[i&&n?s("a",{onClick:i=>vi(e,t,l,i),innerHTML:n},null):s("span",{class:"domPropsInnerHTML-span",innerHTML:n},null)];return Fe(t,e)?[s(re,{placement:"right",trigger:"hover",arrowPointToCenter:!0},{default:()=>[{trigger:()=>o},s(J,{component:K,onClick:l=>Ci(l,e[t.columnName])},null)]})]:[o]},vi=(e,t,l,i)=>{if(F.isInlineOperating)return!1;let n=ct.value;i.preventDefault(),n.isCheckedByCheckboxRow(e)&&i.stopPropagation(),n.setCurrentRow(e),L("setNestTableClick",F.isNestTable),L("setCurRowIndex",l),L("linkDetail",e,t,e[Xt.value],null,!1,l)},Ci=(e,t)=>{e.preventDefault(),e.stopPropagation(),L("hanldeCopyContent",e,t)},wi=()=>{let e=ct.value;e&&e.scrollTo(e.getScroll().scrollLeft,0)},Ti=()=>{if(F.inlineError)return F.resetEditRowStatus(),L("triggerSpinning",!1),!1;let{formId:e}=F.listFormUnionSetting,{id:t}=F.inlineOriginalTableRow;if(!e)return console.log("缺少formId"),void L("triggerSpinning",!1);if(ut.isSaveForm)return!1;ut.isSaveForm=!0;let l=Object.assign({},F.inlineFormData,{formId:e,id:t,editMode:"row"});l=JSON.parse(JSON.stringify(l));let i=l[Vt.value]===rt;F.isInlineAdding&&i&&delete l[Vt.value],F.submitForm(l).then((async({data:e})=>{if(L("triggerSpinning",!1),"SUCCESS"!==e.result)return ut.isSaveForm=!1,st.error(e.resultMsg),F.resetEditRowStatus(),!1;await F.resetInlineEdit(),Rt(),L("pubTableReload")})).finally((()=>{ut.isSaveForm=!1,L("triggerSpinning",!1),F.resetEditRowStatus()}))};return g((()=>F.columnConfig),(e=>{p((()=>{e&&Object.keys(e).length&&nl(e)}))}),{immediate:!0}),g((()=>F.data),(e=>{p((()=>{ol(e)}))}),{immediate:!0,deep:!0}),g((()=>qt),(e=>{Ae(ut,F,qt.value)})),g((()=>F.quickSearchConfig),(e=>{De(ut,F)}),{deep:!0}),g((()=>F.tableDataCache),(e=>{(e=>{if(!F.isNestTable&&e&&e.length){const t=se.handleBigArrayCopy(e);ut.checkedRows=Object.freeze(t),ct.value.setAllCheckboxRow(!0)}})(e)}),{deep:!0}),g((()=>F.pageVO.pageSize),(e=>{F.isNestTable||(Ae(ut,F,qt.value),kl())})),g((()=>F.pageVO.pageIndex),(e=>{F.isNestTable||(wi(),kl())})),g((()=>F.styleSetting.tableHeight),(e=>{F.isNestTable||Object.keys(F.columnConfig).length>0&&(nl(F.columnConfig),ol(F.data),wi())})),g((()=>F.sysImageSize),(e=>{var t;const l="table-simple"===(null==(t=F.styleSetting)?void 0:t.tableHeight)?"26":"22";p((()=>{_e(e,"LIST_FIELD_SMALL",l+"px")}))}),{deep:!0,immediate:!0}),g((()=>F.inlineEditFormSubmitDone),(e=>{if(e&&!F.isNestTable)return!(0!=ut.isTree||!F.isMatchComponent)&&(!!wt()&&void Ti())})),g((()=>F.isInlineEditing),(e=>{if(e&&!F.isNestTable)return!(0!=ut.isTree||!F.isMatchComponent)&&(!!wt()&&void Ti())})),g((()=>F.isInlineAdding),(e=>!(!e||F.isNestTable)&&(!(0!=ut.isTree||!F.isMatchComponent)&&(wt()?(Nt(),void(async()=>{if(!yt())return St(),!1;await F.resetInlineEdit(),L("handleClickBtnByInline",{type:"ADD",listFormUnionSetting:F.listFormUnionSetting,inlineEditFormConfig:F.inlineEditFormConfig}),rt=Date.now();let e={[Vt.value]:rt,__isInsertRow:!0},{paramsList:t}=F.listFormUnionSetting;t.forEach((t=>{e[t.tableField]=void 0}));let l=ct.value;await l.insert(e),await l.loadData([e]),xt(!0),Tt(l.$el,0,"66")})()):(Rt(),!1))))),g((()=>F.isInlineSave),(e=>!(!e||F.isNestTable)&&(!(0!=ut.isTree||!F.isMatchComponent)&&(!!wt()&&void(()=>{if(F.spinning)return!1;L("handleClickBtnByInline",{type:"SAVE"});let e=document.querySelectorAll(".js-inlineEditForm"),t=Et();e=[...e].slice(0,t),e.forEach((e=>{e.__vue__.handleSubmitForm()}))})())))),g((()=>F.isInlineCancel),(e=>!(!e||F.isNestTable)&&(!(0!=ut.isTree||!F.isMatchComponent)&&(!!wt()&&((()=>{if(!F.isInlineAdding)return!1;const e=ct.value;let{tableData:t}=e.getTableData();e.remove(t[0])})(),void St()))))),g((()=>F.tableRefreshCache),((e,t)=>{var l,i;if(F.isNestTable)return;const{orgId:n}=(null==(i=null==(l=null==F?void 0:F.userInfo)?void 0:l.map)?void 0:i.sysParams)||{};e!=t&&F.tableParams&&e[F.tableParams.tableId]&&n==e[F.tableParams.tableId]&&(ut.hasRefresh=!0)}),{immediate:!0,deep:!0}),g((()=>F.tableParams.tableId),(e=>{p((()=>{e&&F.tableRefreshCache[e]&&(ut.hasRefresh=!0)}))})),h({formatData:ht,xGrid:ct}),(e,t)=>(m(),f("div",{class:b(["big-table custom-big-table",{mt:ut.visibleCheckAllWrap||ut.visibleTreeCheck||ut.hasRefresh,"expand-padding":!F.isNestTable}]),style:v({height:ut.tableHeight})},[ut.hasRefresh&&!F.isNestTable?(m(),f("div",Ue,[C("p",{class:"check-wrap-title"},[He,C("span",{class:"check-wrap-btn",onClick:Nl},"点击查看")])])):w("v-if",!0),w(" 全选 选择框 "),T(C("div",qe,[C("p",We,[C("span",null,"已勾选数据共"+k(y(Ct))+"条",1),T(C("span",null," (当前页"+k(ut.currentPageSelectedLength)+"条) ",513),[[S,ut.visibleCheckAllWrapMore]])]),ut.visibleCheckAllWrapMore&&!F.asyncCount?(m(),f(x,{key:0},[y(Wt)?(m(),f("p",{key:1,class:"check-wrap-btn",onClick:Rl},"取消全部勾选")):(m(),f("p",{key:0,class:"check-wrap-btn",onClick:El},[e.pageVO.total>e.maxCheckSize?(m(),f("span",Je,[w(" {{ `最大勾选“${tableName}” ${maxCheckSize}条数据` }} "),u(k(`勾选全部页 ${e.maxCheckSize}条数据`),1)])):(m(),f("span",Ge,[w(' {{ $t("1.9.598", { name: tableName, total }) }} '),u(k(`勾选全部页 ${e.pageVO.total}条数据`),1)]))]))],64)):w("v-if",!0)],512),[[S,ut.visibleCheckAllWrap&&!F.isInlineOperating&&!F.isNestTable]]),w(" 树状表格已选 "),T(C("div",Ze,[C("p",Qe,[C("span",null,"已勾选数据共"+k(ut.treeTableLength)+"条",1)])],512),[[S,ut.visibleTreeCheck&&!F.isInlineOperating&&!F.isNestTable]]),s(y(ae),N({ref_key:"xGrid",ref:ct,border:"","show-overflow":"","show-header-overflow":"","highlight-hover-row":"","highlight-current-row":"","show-footer-overflow":"title","keep-source":"",resizable:"","auto-resize":""},F.height?{height:"auto"}:{},{"seq-config":y(Yt),"tree-config":y(el),"row-id":y(Vt),"row-class-name":Il,"row-config":ut.rowConfig,"show-footer":e.showFooter&&!F.isInlineOperating,"footer-method":Ol,"sort-config":{trigger:"cell",remote:!0},"span-method":Dl,"footer-span-method":_l,"tooltip-config":{enterable:!1},"checkbox-config":{checkField:"checked",labelField:"checked",checkMethod:y(he),trigger:"cell",reserve:!0,highlight:!0},"radio-config":{checkField:"checked",trigger:"cell",reserve:!0,highlight:!0},"scroll-x":{enabled:!1},"scroll-y":{gt:50},"row-style":y(Me),"edit-config":ut.editConfig,"expand-config":{lazy:!0,accordion:e.columnConfig&&e.columnConfig.accordion,loadMethod:y(zt),toggleMethod:y(jt),iconOpen:"iconfont icon-a-xitongtubiaozhediejian",iconClose:"iconfont icon-a-xitongtubiaotianjia"},"keyboard-config":e.columnConfig.keyboardConfig||{},"edit-rules":e.columnConfig.editRules||{},onCellDblclick:Ml,onCellClick:jl,onCheckboxChange:Kl,onCheckboxAll:Ul,onRadioChange:Hl,onSortChange:ql,onScroll:y(Ut),onCellMouseenter:Jl,onKeydown:y(Kt)}),{empty:E((()=>[ut.isShowEmpty?(m(),f("div",Xe,[s(Ke,{"no-data-img":F.emptyItems.noDataImg,"no-data-tip":F.emptyItems.noDataTip,"show-img":!F.isNestTable},null,8,["no-data-img","no-data-tip","show-img"])])):w("v-if",!0)])),tooltip_checkbox:E((({row:e,checked:t})=>[e.forbiddenBatchSelect?(m(),R(y(G),{key:0,trigger:"hover",placement:"right"},{trigger:E((()=>[Ye])),default:E((()=>[u(" "+k(e.forbiddenBatchSelectReason),1)])),_:2},1024)):(m(),R(y(ee),{key:1,class:"tooltip-checkbox-item",checked:t},null,8,["checked"]))])),tooltip_footer:E((({column:t})=>[w(" 分组统计 "),e.groupCountFields&&e.groupCountFields.length?(m(),f("span",{key:0,innerHTML:ut.groupText},null,8,et)):(m(),f(x,{key:1},[w(" 一般统计 "),s(y(G),{trigger:"hover"},{trigger:E((()=>[u(k(Zl(t)),1)])),default:E((()=>[C("div",{innerHTML:Gl(t)},null,8,tt)])),_:2},1024)],2112))])),nest_table_content:E((({row:t,rowIndex:l,$rowIndex:i,column:n})=>[I(e.$slots,"content",{data:{row:t,rowIndex:l,$rowIndex:i,column:n}})])),_:3},16,["seq-config","tree-config","row-id","row-config","show-footer","checkbox-config","row-style","edit-config","expand-config","keyboard-config","edit-rules","onScroll","onKeydown"]),w(" `${refreshRow}条更新` "),T(C("div",{class:"refresh",onClick:Ql},[s(y(J),{size:"14",component:y(U)},null,8,["component"]),C("p",lt,k(e.refreshRow)+"条更新",1)],512),[[S,F.refreshRow>0&&!F.isNestTable]])],6))}});export{nt as default};
|
|
1
|
+
import { defineComponent, ref, reactive, useAttrs, computed, onMounted, onUnmounted, onActivated, createVNode, h, resolveComponent, Teleport, createTextVNode, isVNode, nextTick, watch, openBlock, createElementBlock, normalizeClass, unref, normalizeStyle, createElementVNode, createCommentVNode, withDirectives, toDisplayString, vShow, Fragment, mergeProps, withCtx, createBlock, renderSlot } from 'vue';
|
|
2
|
+
import bigTableState from './bigTableState2.mjs';
|
|
3
|
+
import bigTableProps from './bigTableProps2.mjs';
|
|
4
|
+
import bigTableEmits from './bigTableEmits2.mjs';
|
|
5
|
+
import { useFormat } from './hooks/useFormat2.mjs';
|
|
6
|
+
import { useTableParse } from './hooks/useTableParse2.mjs';
|
|
7
|
+
import { useBatchEditing } from './hooks/useBatchEditing2.mjs';
|
|
8
|
+
import { useNestTable } from './hooks/useNestTable2.mjs';
|
|
9
|
+
import { useEdit, comps } from './hooks/useEdit2.mjs';
|
|
10
|
+
import { useEvent } from './hooks/useEvent2.mjs';
|
|
11
|
+
import { SettingsSharp, CaretDown, CaretForward, CopyOutline, SyncOutline } from '@vicons/ionicons5';
|
|
12
|
+
import './components/NoData2.mjs';
|
|
13
|
+
import TextOverTooltip from 'cnhis-design-vue/es/src/components/TextOverTooltip';
|
|
14
|
+
import SvgIcon from 'cnhis-design-vue/es/src/components/SvgIcon';
|
|
15
|
+
import { useMessage, NIcon, NTooltip, NPopconfirm, NButton, NInputGroup, NInput, NCheckbox, NCheckboxGroup, NSpace, NProgress, NDropdown, NSwitch, NPopover } from 'naive-ui';
|
|
16
|
+
import CGrid from 'cnhis-design-vue/es/packages/grid';
|
|
17
|
+
import vexutils from 'cnhis-design-vue/es/src/utils/vexutils';
|
|
18
|
+
import { handleTableHeight, setTableConfig, handleGroupColums, checkMethod, setTreeGroupTitle, handleName, handlerInitSearchItem, getEvaluate, getMapVal, getCandidateComponents, getageShowType, isLink, showFilter, reScrollFilterWrap, hideFilterWrap, mergeConObjFn, setDefaultFormData, handleImgArr, handleImgSrc, modalDetailImage, handleQrCodeContent, getInlineEditBtn, isCopy, setVisibleCheckAllWrap, setFilterStatus, handleTableImageSize, getRowStyle, getFooterGroup, flattenRow, intersectRow, removeCheckedDisabledRows } from './utils2.mjs';
|
|
19
|
+
import xb_big from 'cnhis-design-vue/es/src/assets/img/xb_big.png';
|
|
20
|
+
import qr from 'cnhis-design-vue/es/src/assets/img/qr.png';
|
|
21
|
+
import script$1 from './components/NoData.vue_vue_type_script_setup_true_lang.mjs';
|
|
22
|
+
|
|
23
|
+
const _hoisted_1 = {
|
|
24
|
+
key: 0,
|
|
25
|
+
class: "check-wrap"
|
|
26
|
+
};
|
|
27
|
+
const _hoisted_2 = /* @__PURE__ */ createElementVNode("span", null, "\u7CFB\u7EDF\u68C0\u6D4B\u5230\u6709\u6570\u636E\u66F4\u65B0,", -1);
|
|
28
|
+
const _hoisted_3 = {
|
|
29
|
+
class: "check-wrap"
|
|
30
|
+
};
|
|
31
|
+
const _hoisted_4 = {
|
|
32
|
+
class: "check-wrap-title"
|
|
33
|
+
};
|
|
34
|
+
const _hoisted_5 = {
|
|
35
|
+
key: 0
|
|
36
|
+
};
|
|
37
|
+
const _hoisted_6 = {
|
|
38
|
+
key: 1
|
|
39
|
+
};
|
|
40
|
+
const _hoisted_7 = {
|
|
41
|
+
class: "check-wrap"
|
|
42
|
+
};
|
|
43
|
+
const _hoisted_8 = {
|
|
44
|
+
class: "check-wrap-title"
|
|
45
|
+
};
|
|
46
|
+
const _hoisted_9 = {
|
|
47
|
+
key: 0
|
|
48
|
+
};
|
|
49
|
+
const _hoisted_10 = /* @__PURE__ */ createElementVNode("i", {
|
|
50
|
+
class: "disabled-checked-tips"
|
|
51
|
+
}, null, -1);
|
|
52
|
+
const _hoisted_11 = ["innerHTML"];
|
|
53
|
+
const _hoisted_12 = ["innerHTML"];
|
|
54
|
+
const _hoisted_13 = {
|
|
55
|
+
class: "refresh-row"
|
|
56
|
+
};
|
|
57
|
+
function _isSlot(s) {
|
|
58
|
+
return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !isVNode(s);
|
|
59
|
+
}
|
|
60
|
+
var script = /* @__PURE__ */ defineComponent({
|
|
61
|
+
props: bigTableProps,
|
|
62
|
+
emits: bigTableEmits,
|
|
63
|
+
setup(__props, {
|
|
64
|
+
expose,
|
|
65
|
+
emit
|
|
66
|
+
}) {
|
|
67
|
+
const props = __props;
|
|
68
|
+
let _hideAllWrap = null;
|
|
69
|
+
let _beforeSearchConvert = [];
|
|
70
|
+
let addInlineEditPrimaryKey = "";
|
|
71
|
+
const GROUP_TITLE_KEY = "group-show-title";
|
|
72
|
+
const $message = useMessage();
|
|
73
|
+
const xGrid = ref({});
|
|
74
|
+
const copyState = vexutils.clone(bigTableState, true);
|
|
75
|
+
const state = reactive(copyState);
|
|
76
|
+
const {
|
|
77
|
+
formatData,
|
|
78
|
+
htmlToText,
|
|
79
|
+
getBtnStyle
|
|
80
|
+
} = useFormat(state);
|
|
81
|
+
const {
|
|
82
|
+
imgs2imgArr,
|
|
83
|
+
parseDurationValue,
|
|
84
|
+
parseCombinationValue,
|
|
85
|
+
formatFieldText
|
|
86
|
+
} = useTableParse(formatData);
|
|
87
|
+
const {
|
|
88
|
+
allSelectedLength,
|
|
89
|
+
checkOperateCurrentTable,
|
|
90
|
+
setRowStatus,
|
|
91
|
+
resetBatchOperationRowStatus,
|
|
92
|
+
checkListFormUnionSettingParamsList,
|
|
93
|
+
handleClickCancelBtnByInline,
|
|
94
|
+
setAllRowInlineStatus,
|
|
95
|
+
hideSelectCloumns,
|
|
96
|
+
handleEditFormLength,
|
|
97
|
+
resetOperationRowStatus,
|
|
98
|
+
recordClickBtnInfo,
|
|
99
|
+
getInlineOpreateRow
|
|
100
|
+
} = useBatchEditing(props, state, emit, xGrid);
|
|
101
|
+
const {
|
|
102
|
+
initEditTable,
|
|
103
|
+
activeMethod,
|
|
104
|
+
deleteRow,
|
|
105
|
+
onClickSelectTable,
|
|
106
|
+
onFormChange,
|
|
107
|
+
getDefaultValue
|
|
108
|
+
} = useEdit(props, state, emit, xGrid);
|
|
109
|
+
const {
|
|
110
|
+
isAboutNestTable,
|
|
111
|
+
isExpandTable,
|
|
112
|
+
handleRowId,
|
|
113
|
+
toggleExpandMethod,
|
|
114
|
+
loadExpandMethod,
|
|
115
|
+
nestHandleClickRow
|
|
116
|
+
} = useNestTable(props, state, emit);
|
|
117
|
+
const {
|
|
118
|
+
keyDown,
|
|
119
|
+
scroll
|
|
120
|
+
} = useEvent(props, state, emit, xGrid);
|
|
121
|
+
const attr = useAttrs();
|
|
122
|
+
const currentCheckedKeys = computed(() => {
|
|
123
|
+
var _a;
|
|
124
|
+
return ((_a = state.checkedRows) == null ? void 0 : _a.map((row) => row[props.primaryKey])) || [];
|
|
125
|
+
});
|
|
126
|
+
const visibleCancelCheckAllBtn = computed(() => {
|
|
127
|
+
let isCurrentPageAllCheck = state.currentPageSelectedLength === state.curAbleCheckedLen;
|
|
128
|
+
let isMaxChecked = currentCheckedKeys.value.length === props.maxCheckSize;
|
|
129
|
+
let isCheckedTotal = currentCheckedKeys.value.length === props.pageVO.total;
|
|
130
|
+
return isMaxChecked || !isCurrentPageAllCheck || isCheckedTotal;
|
|
131
|
+
});
|
|
132
|
+
const singleCheckedKey = computed(() => {
|
|
133
|
+
const checkedKeys = currentCheckedKeys.value || [];
|
|
134
|
+
return checkedKeys.length == 1 ? checkedKeys[0] : "";
|
|
135
|
+
});
|
|
136
|
+
const tableNoSetting = computed(() => {
|
|
137
|
+
var _a;
|
|
138
|
+
let {
|
|
139
|
+
noSetting
|
|
140
|
+
} = getOtherConfigInit() || {};
|
|
141
|
+
return noSetting || ((_a = props.showSettings) == null ? void 0 : _a.hideSettingBtn) == 1;
|
|
142
|
+
});
|
|
143
|
+
const isScanMultiTable = computed(() => {
|
|
144
|
+
var _a;
|
|
145
|
+
return (_a = props.columnConfig) == null ? void 0 : _a.isScanMultiTable;
|
|
146
|
+
});
|
|
147
|
+
const configuration = computed(() => {
|
|
148
|
+
return {
|
|
149
|
+
userInfo: props.userInfo || {},
|
|
150
|
+
sysImageSize: props.sysImageSize || {}
|
|
151
|
+
};
|
|
152
|
+
});
|
|
153
|
+
const handlePrimaryKey = computed(() => {
|
|
154
|
+
return state.isTree > 0 ? props.primaryKey || "theUniqueKey" : "theUniqueKey";
|
|
155
|
+
});
|
|
156
|
+
const handleSeqConfig = computed(() => {
|
|
157
|
+
if (props.isNestTable)
|
|
158
|
+
return {
|
|
159
|
+
startIndex: 0
|
|
160
|
+
};
|
|
161
|
+
if (props.isBatchEditing) {
|
|
162
|
+
return {
|
|
163
|
+
startIndex: 0
|
|
164
|
+
};
|
|
165
|
+
}
|
|
166
|
+
let startIndex = (props.pageVO.pageIndex - 1) * props.pageVO.pageSize;
|
|
167
|
+
return {
|
|
168
|
+
startIndex: startIndex < 0 ? 0 : startIndex
|
|
169
|
+
};
|
|
170
|
+
});
|
|
171
|
+
const treeConfig = computed(() => {
|
|
172
|
+
let result = null;
|
|
173
|
+
switch (Number(state.isTree)) {
|
|
174
|
+
case 1:
|
|
175
|
+
case 3:
|
|
176
|
+
result = {
|
|
177
|
+
children: "childrenList",
|
|
178
|
+
accordion: state.openOnly > 0,
|
|
179
|
+
reserve: true
|
|
180
|
+
};
|
|
181
|
+
break;
|
|
182
|
+
case 2:
|
|
183
|
+
result = {
|
|
184
|
+
lazy: true,
|
|
185
|
+
reserve: true,
|
|
186
|
+
children: "childrenList",
|
|
187
|
+
hasChild: "hasChildren",
|
|
188
|
+
loadMethod: loadChildrenMethod,
|
|
189
|
+
accordion: state.openOnly > 0
|
|
190
|
+
};
|
|
191
|
+
break;
|
|
192
|
+
}
|
|
193
|
+
return result;
|
|
194
|
+
});
|
|
195
|
+
const hideAllWrap = (e) => {
|
|
196
|
+
const path = e.path || e.composedPath && e.composedPath();
|
|
197
|
+
const noWrap = (className) => {
|
|
198
|
+
return !path.some((p) => {
|
|
199
|
+
return p.className && p.className.includes && p.className.includes(className);
|
|
200
|
+
});
|
|
201
|
+
};
|
|
202
|
+
let notFilterWrap = noWrap("big-table-filter-wrap");
|
|
203
|
+
if (notFilterWrap) {
|
|
204
|
+
hideFilterWrap(state, props);
|
|
205
|
+
}
|
|
206
|
+
};
|
|
207
|
+
const bindDocumentClick = () => {
|
|
208
|
+
_hideAllWrap = hideAllWrap.bind(this);
|
|
209
|
+
window.document.addEventListener("click", _hideAllWrap, true);
|
|
210
|
+
};
|
|
211
|
+
const unBindDocumentClick = () => {
|
|
212
|
+
window.document.removeEventListener("click", _hideAllWrap, true);
|
|
213
|
+
};
|
|
214
|
+
onMounted(() => {
|
|
215
|
+
bindDocumentClick();
|
|
216
|
+
state.tableHeight = handleTableHeight(state, props) || "auto";
|
|
217
|
+
if (!props.isNestTable)
|
|
218
|
+
return;
|
|
219
|
+
loadColumn(props.columnConfig);
|
|
220
|
+
loadData(props.data);
|
|
221
|
+
});
|
|
222
|
+
onUnmounted(() => {
|
|
223
|
+
unBindDocumentClick();
|
|
224
|
+
});
|
|
225
|
+
onActivated(() => {
|
|
226
|
+
removeInsert();
|
|
227
|
+
});
|
|
228
|
+
const removeInsert = async () => {
|
|
229
|
+
var _a;
|
|
230
|
+
if (state.isTree != 0)
|
|
231
|
+
return false;
|
|
232
|
+
const vxeTable = xGrid.value;
|
|
233
|
+
let {
|
|
234
|
+
tableData
|
|
235
|
+
} = vxeTable.getTableData();
|
|
236
|
+
if (tableData && tableData.length) {
|
|
237
|
+
tableData.forEach((row) => {
|
|
238
|
+
if (row == null ? void 0 : row.__isInsertRow) {
|
|
239
|
+
vxeTable.remove(row);
|
|
240
|
+
}
|
|
241
|
+
});
|
|
242
|
+
}
|
|
243
|
+
if (!((_a = state.originFormatList) == null ? void 0 : _a.length))
|
|
244
|
+
return;
|
|
245
|
+
await vxeTable.loadData(state.originFormatList);
|
|
246
|
+
resetBatchOperationRowStatus();
|
|
247
|
+
};
|
|
248
|
+
const loadColumn = (config) => {
|
|
249
|
+
setTableConfig(config, state);
|
|
250
|
+
let columns = formatColumns(config);
|
|
251
|
+
columns = handleGroupColums(columns, props);
|
|
252
|
+
xGrid.value && xGrid.value.reloadColumn(columns);
|
|
253
|
+
setGroupTreeExpand();
|
|
254
|
+
resetTableInlineEditStatus();
|
|
255
|
+
};
|
|
256
|
+
const loadData = async (data) => {
|
|
257
|
+
state.isShowEmpty = !(data == null ? void 0 : data.length);
|
|
258
|
+
const list = JSON.parse(JSON.stringify(data));
|
|
259
|
+
let table = xGrid.value;
|
|
260
|
+
if (!table)
|
|
261
|
+
return;
|
|
262
|
+
state.checkedRows = [];
|
|
263
|
+
let formatList = setChecklist(list);
|
|
264
|
+
state.originFormatList = formatList;
|
|
265
|
+
setGroupTitleToFristColumnFieldData(formatList);
|
|
266
|
+
state.curAbleCheckedLen = list.filter((item) => checkMethod({
|
|
267
|
+
row: item
|
|
268
|
+
})).length;
|
|
269
|
+
if (!props.isNestTable) {
|
|
270
|
+
await handleFormTheUniqueKey();
|
|
271
|
+
}
|
|
272
|
+
formatList = formatList.map((v) => {
|
|
273
|
+
return {
|
|
274
|
+
...v,
|
|
275
|
+
selectTableShow: false,
|
|
276
|
+
selectTableDisable: false
|
|
277
|
+
};
|
|
278
|
+
});
|
|
279
|
+
await table.loadData(formatList);
|
|
280
|
+
table.setCurrentRow({});
|
|
281
|
+
setCurrentPageRowChecked();
|
|
282
|
+
setGroupTreeExpand();
|
|
283
|
+
resetTableInlineEditStatus();
|
|
284
|
+
};
|
|
285
|
+
const setGroupTitleToFristColumnFieldData = (formatList) => {
|
|
286
|
+
var _a;
|
|
287
|
+
if (state.isTree != 3)
|
|
288
|
+
return;
|
|
289
|
+
let table = xGrid.value;
|
|
290
|
+
let key = (_a = table.getTableColumn().tableColumn) == null ? void 0 : _a.find((column) => {
|
|
291
|
+
return !!column.property;
|
|
292
|
+
}).property;
|
|
293
|
+
setTreeGroupTitle(formatList, key, GROUP_TITLE_KEY);
|
|
294
|
+
};
|
|
295
|
+
const setCurrentPageRowChecked = () => {
|
|
296
|
+
var _a;
|
|
297
|
+
let table = xGrid.value;
|
|
298
|
+
if (!table)
|
|
299
|
+
return;
|
|
300
|
+
let currentPageTableData = (_a = table.getTableData()) == null ? void 0 : _a.tableData;
|
|
301
|
+
let currentPageSelectedRows = currentPageTableData.filter((row) => {
|
|
302
|
+
if (props.primaryKey) {
|
|
303
|
+
return currentCheckedKeys.value.includes(row[props.primaryKey]);
|
|
304
|
+
}
|
|
305
|
+
return row.checked;
|
|
306
|
+
});
|
|
307
|
+
setCurrentCheckedLength();
|
|
308
|
+
if (!currentPageSelectedRows || !currentPageSelectedRows.length) {
|
|
309
|
+
table.setAllCheckboxRow(false);
|
|
310
|
+
return;
|
|
311
|
+
}
|
|
312
|
+
table.setCheckboxRow(currentPageSelectedRows, true);
|
|
313
|
+
};
|
|
314
|
+
const setCurrentCheckedLength = () => {
|
|
315
|
+
let table = xGrid.value;
|
|
316
|
+
let currentPageTableData = table.getTableData().fullData;
|
|
317
|
+
let currentPageSelectedRows = currentPageTableData.filter((row) => {
|
|
318
|
+
return currentCheckedKeys.value.includes(row[props.primaryKey]) || row.checked;
|
|
319
|
+
});
|
|
320
|
+
state.currentPageSelectedLength = currentPageSelectedRows.length;
|
|
321
|
+
};
|
|
322
|
+
const formatColumns = (map) => {
|
|
323
|
+
var _a, _b;
|
|
324
|
+
let {
|
|
325
|
+
selectType
|
|
326
|
+
} = getOtherConfigInit() || {};
|
|
327
|
+
let {
|
|
328
|
+
isBatchSelect,
|
|
329
|
+
fieldList = [],
|
|
330
|
+
showButtonTop,
|
|
331
|
+
isScanMultiTable: isScanMultiTable2,
|
|
332
|
+
isEdit = false,
|
|
333
|
+
editConfig = {},
|
|
334
|
+
rowConfig = {}
|
|
335
|
+
} = map;
|
|
336
|
+
if (isEdit) {
|
|
337
|
+
state.editConfig = Object.assign(state.editConfig, editConfig);
|
|
338
|
+
state.rowConfig.height = 48;
|
|
339
|
+
}
|
|
340
|
+
state.rowConfig.height = Object.assign(state.rowConfig.height, rowConfig);
|
|
341
|
+
if (selectType) {
|
|
342
|
+
isBatchSelect = 1;
|
|
343
|
+
}
|
|
344
|
+
selectType = selectType || "checkbox";
|
|
345
|
+
let {
|
|
346
|
+
listType
|
|
347
|
+
} = props.tableOptions;
|
|
348
|
+
if (listType == "scanList") {
|
|
349
|
+
selectType = "radio";
|
|
350
|
+
}
|
|
351
|
+
state.selectType = selectType;
|
|
352
|
+
let tableHeight = ((_a = props.styleSetting) == null ? void 0 : _a.tableHeight) || "table-simple";
|
|
353
|
+
let checkMinWidth = state.checkWidth[tableHeight] || "30";
|
|
354
|
+
const checkboxSlot = {
|
|
355
|
+
default: (data) => {
|
|
356
|
+
return checkMethod(data) ? null : createVNode(NTooltip, {
|
|
357
|
+
"placement": "right",
|
|
358
|
+
"trigger": "hover"
|
|
359
|
+
}, {
|
|
360
|
+
default: () => data.row.forbiddenBatchSelectReason,
|
|
361
|
+
trigger: () => createVNode("i", {
|
|
362
|
+
"class": "disabled-checked-tips"
|
|
363
|
+
}, null)
|
|
364
|
+
});
|
|
365
|
+
}
|
|
366
|
+
};
|
|
367
|
+
let checkVisible = isBatchSelect == 1 && !props.isNestTable && !isScanMultiTable2 || false;
|
|
368
|
+
let columns = [{
|
|
369
|
+
fixed: "left",
|
|
370
|
+
align: "center",
|
|
371
|
+
visible: isScanMultiTable2 || false,
|
|
372
|
+
width: "60",
|
|
373
|
+
slots: {
|
|
374
|
+
header: () => "\u64CD\u4F5C",
|
|
375
|
+
default: scanMultiOperate
|
|
376
|
+
}
|
|
377
|
+
}, {
|
|
378
|
+
type: "seq",
|
|
379
|
+
fixed: props.isNestTable ? "" : "left",
|
|
380
|
+
align: "center",
|
|
381
|
+
resizable: true,
|
|
382
|
+
width: "34",
|
|
383
|
+
showOverflow: true,
|
|
384
|
+
slots: {
|
|
385
|
+
header: () => {
|
|
386
|
+
return [tableNoSetting.value ? null : createVNode(NIcon, {
|
|
387
|
+
"size": "14",
|
|
388
|
+
"color": "#777",
|
|
389
|
+
"component": SettingsSharp,
|
|
390
|
+
"onClick": () => showDrawer()
|
|
391
|
+
}, null)];
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
}, {
|
|
395
|
+
type: selectType,
|
|
396
|
+
fixed: props.isNestTable ? "" : "left",
|
|
397
|
+
align: "center",
|
|
398
|
+
visible: checkVisible,
|
|
399
|
+
resizable: false,
|
|
400
|
+
width: checkMinWidth,
|
|
401
|
+
slots: selectType === "checkbox" ? checkboxSlot : null,
|
|
402
|
+
showOverflow: true
|
|
403
|
+
}];
|
|
404
|
+
const seqObj = columns.find((v) => v.type == "seq");
|
|
405
|
+
if ((_b = props == null ? void 0 : props.columnConfig) == null ? void 0 : _b.seqSlotFn) {
|
|
406
|
+
seqObj.slots.default = (params) => {
|
|
407
|
+
var _a2;
|
|
408
|
+
return (_a2 = props.columnConfig) == null ? void 0 : _a2.seqSlotFn(params);
|
|
409
|
+
};
|
|
410
|
+
}
|
|
411
|
+
const currentColumns = fieldList.map((item, index) => {
|
|
412
|
+
var _a2, _b2, _c, _d;
|
|
413
|
+
let filterField = ((_b2 = (_a2 = item == null ? void 0 : item.fieldSetting) == null ? void 0 : _a2.mapping) == null ? void 0 : _b2.type) === "manual" && item.isMerge != 1;
|
|
414
|
+
let notParticipatingSort = ((_c = item == null ? void 0 : item.fieldSetting) == null ? void 0 : _c.notParticipatingSort) || "";
|
|
415
|
+
let fixed = isAboutNestTable.value ? "" : item.isFixed ? item.isFixed == 1 ? "left" : "right" : "";
|
|
416
|
+
let sortable = props.isNestTable ? false : !filterField && item.isSort == 1 && notParticipatingSort != 1 && item.isMerge != 1;
|
|
417
|
+
let treeNode = props.isNestTable ? false : state.isTree != 0 ? index === 0 : false;
|
|
418
|
+
let type = index === 0 && props.showNestTable ? "expand" : "";
|
|
419
|
+
if (isScanMultiTable2) {
|
|
420
|
+
fixed = "";
|
|
421
|
+
sortable = false;
|
|
422
|
+
treeNode = false;
|
|
423
|
+
type = "";
|
|
424
|
+
}
|
|
425
|
+
const col = Object.assign(item, {
|
|
426
|
+
visible: item.columnName == "operatorColumn" ? showButtonTop == 0 : item.isShow == 1,
|
|
427
|
+
field: item.columnName,
|
|
428
|
+
title: handleName(item, "title"),
|
|
429
|
+
minWidth: item.colWidth,
|
|
430
|
+
fixed,
|
|
431
|
+
sortable,
|
|
432
|
+
headerClassName: "mycolumn",
|
|
433
|
+
showOverflow: "title",
|
|
434
|
+
treeNode,
|
|
435
|
+
type,
|
|
436
|
+
slots: {
|
|
437
|
+
edit: (params) => {
|
|
438
|
+
if (isEdit && item.isEdit && item.columnName !== "operatorColumn") {
|
|
439
|
+
return formatterEdit(params, item);
|
|
440
|
+
} else {
|
|
441
|
+
return createVNode("span", null, [params.row[item.columnName]]);
|
|
442
|
+
}
|
|
443
|
+
},
|
|
444
|
+
default: (params) => {
|
|
445
|
+
if (!isEdit || item.columnName === "operatorColumn" || !item.isEdit) {
|
|
446
|
+
return formatter(params, item);
|
|
447
|
+
} else if (isEdit && item.isEdit && item.checkEditStatus && item.checkEditStatus(params)) {
|
|
448
|
+
return formatterEdit(params, item);
|
|
449
|
+
} else {
|
|
450
|
+
return createVNode("span", null, [getDefaultValue(params, item)]);
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
},
|
|
454
|
+
editRender: {}
|
|
455
|
+
});
|
|
456
|
+
if (filterField && !props.isNestTable && !isScanMultiTable2) {
|
|
457
|
+
state.filterFields[item.columnName] = Object.assign({}, vexutils.clone(item, true), {
|
|
458
|
+
visible: false,
|
|
459
|
+
left: "initial",
|
|
460
|
+
right: "initial",
|
|
461
|
+
top: "initial",
|
|
462
|
+
indeterminate: false,
|
|
463
|
+
checkAll: false,
|
|
464
|
+
searchFilterText: "",
|
|
465
|
+
searchFilterCONVERT: [],
|
|
466
|
+
filterSort: ""
|
|
467
|
+
});
|
|
468
|
+
let field = state.filterFields[item.columnName];
|
|
469
|
+
handlerInitSearchItem([field]);
|
|
470
|
+
col.slots.header = formatterHeader(item);
|
|
471
|
+
} else {
|
|
472
|
+
col.slots.header = toolTipTitle(item);
|
|
473
|
+
}
|
|
474
|
+
if (!isScanMultiTable2) {
|
|
475
|
+
col.slots.footer = "tooltip_footer";
|
|
476
|
+
}
|
|
477
|
+
if (props.showNestTable && state.isTree == 0 && ((_d = props.curNestColumnConfig) == null ? void 0 : _d.isTree) == 0) {
|
|
478
|
+
col.slots.content = "nest_table_content";
|
|
479
|
+
}
|
|
480
|
+
return col;
|
|
481
|
+
});
|
|
482
|
+
columns.push(...currentColumns);
|
|
483
|
+
state.columnLen = currentColumns.filter((item) => item.visible).length;
|
|
484
|
+
return columns;
|
|
485
|
+
};
|
|
486
|
+
const formatterEdit = (params, col) => {
|
|
487
|
+
let {
|
|
488
|
+
row,
|
|
489
|
+
column,
|
|
490
|
+
$rowIndex,
|
|
491
|
+
rowIndex
|
|
492
|
+
} = params;
|
|
493
|
+
let formType = column.formType || col.formType || "";
|
|
494
|
+
let formatMap = column.formatMap || col.formatMap || null;
|
|
495
|
+
if (!formType)
|
|
496
|
+
return null;
|
|
497
|
+
if (formType === "custom" && col.slotFn) {
|
|
498
|
+
return col.slotFn(params);
|
|
499
|
+
}
|
|
500
|
+
const Comp = comps[formType] || "";
|
|
501
|
+
if (!Comp)
|
|
502
|
+
return null;
|
|
503
|
+
const propsData = {
|
|
504
|
+
col,
|
|
505
|
+
row,
|
|
506
|
+
index: $rowIndex,
|
|
507
|
+
type: formType,
|
|
508
|
+
onFormChange
|
|
509
|
+
};
|
|
510
|
+
if (formType === "date") {
|
|
511
|
+
propsData.formattedValue = row[col.columnName];
|
|
512
|
+
} else if (formatMap) {
|
|
513
|
+
propsData.value = row[formatMap.value];
|
|
514
|
+
} else {
|
|
515
|
+
propsData.value = row[col.columnName];
|
|
516
|
+
}
|
|
517
|
+
if (formType === "select") {
|
|
518
|
+
propsData.onSetOptions = (options) => row[`${col.columnName}_options`] = options;
|
|
519
|
+
}
|
|
520
|
+
return h(Comp, propsData);
|
|
521
|
+
};
|
|
522
|
+
const getEditBtn = (row, col, index) => {
|
|
523
|
+
var _a;
|
|
524
|
+
return (_a = col.tileBtnList) == null ? void 0 : _a.map((btn) => {
|
|
525
|
+
if (btn.settingObj[0].trigger_type === "DELETE") {
|
|
526
|
+
return createVNode(NPopconfirm, {
|
|
527
|
+
"onPositiveClick": () => deleteRow(row, col, index)
|
|
528
|
+
}, {
|
|
529
|
+
trigger: () => createVNode(NButton, {
|
|
530
|
+
"color": btn.settingObj[0].color || "#999",
|
|
531
|
+
"text": true
|
|
532
|
+
}, {
|
|
533
|
+
default: () => [btn.name]
|
|
534
|
+
}),
|
|
535
|
+
default: () => "\u662F\u5426\u786E\u8BA4\u5220\u9664\uFF1F"
|
|
536
|
+
});
|
|
537
|
+
} else {
|
|
538
|
+
return null;
|
|
539
|
+
}
|
|
540
|
+
});
|
|
541
|
+
};
|
|
542
|
+
const formatter = (params, col) => {
|
|
543
|
+
var _a, _b;
|
|
544
|
+
let {
|
|
545
|
+
row,
|
|
546
|
+
column,
|
|
547
|
+
$rowIndex
|
|
548
|
+
} = params;
|
|
549
|
+
let own = (column == null ? void 0 : column._own) || (column == null ? void 0 : column.own) || col;
|
|
550
|
+
let attrType = (own == null ? void 0 : own.attrType) || "";
|
|
551
|
+
let formUnionItem = showEditForm(row, column, $rowIndex);
|
|
552
|
+
if (formUnionItem) {
|
|
553
|
+
let dynamicProps = initBatchDynamicProps(formUnionItem, row, column);
|
|
554
|
+
if (dynamicProps) {
|
|
555
|
+
emit("setWaitEditKeys", column.property);
|
|
556
|
+
return null;
|
|
557
|
+
}
|
|
558
|
+
}
|
|
559
|
+
if (attrType === "custom" && col.slotFn) {
|
|
560
|
+
return col.slotFn(params);
|
|
561
|
+
}
|
|
562
|
+
if (vexutils.has(row, GROUP_TITLE_KEY)) {
|
|
563
|
+
return row[GROUP_TITLE_KEY];
|
|
564
|
+
}
|
|
565
|
+
if (attrType == "PICTURE" || attrType == "HEADPORTRAIT") {
|
|
566
|
+
return getPicture(row, own, attrType);
|
|
567
|
+
}
|
|
568
|
+
if (attrType == "COLOR") {
|
|
569
|
+
return getColor(row, own);
|
|
570
|
+
}
|
|
571
|
+
if (attrType == "EVALUATE") {
|
|
572
|
+
return getEvaluate(row, own);
|
|
573
|
+
}
|
|
574
|
+
if (attrType == "MAP") {
|
|
575
|
+
return getMapVal(row, own);
|
|
576
|
+
}
|
|
577
|
+
if (attrType == "DATE" || attrType == "TASKDATE") {
|
|
578
|
+
return getDate(row, own);
|
|
579
|
+
}
|
|
580
|
+
if (attrType == "PERCENTAGE") {
|
|
581
|
+
return getPercentage(row, own);
|
|
582
|
+
}
|
|
583
|
+
if (attrType == "VIDEO") {
|
|
584
|
+
return getvideoList(row, own);
|
|
585
|
+
}
|
|
586
|
+
if (attrType == "CANDIDATE_COMPONENTS") {
|
|
587
|
+
return getCandidateComponents(row, own);
|
|
588
|
+
}
|
|
589
|
+
if (attrType == "AGE") {
|
|
590
|
+
return getageShowType(row, own);
|
|
591
|
+
}
|
|
592
|
+
if (attrType === "COUNTDOWN") {
|
|
593
|
+
return createVNode(NTooltip, null, {
|
|
594
|
+
trigger: () => createVNode("span", {
|
|
595
|
+
"innerHTML": row[own.columnName + "_countdown"] || ""
|
|
596
|
+
}, null),
|
|
597
|
+
default: () => row[own.columnName + "_countdownTip"]
|
|
598
|
+
});
|
|
599
|
+
}
|
|
600
|
+
if (attrType === "DURATION") {
|
|
601
|
+
const value = row[own.columnName];
|
|
602
|
+
const duration = (_a = own == null ? void 0 : own.fieldSetting) == null ? void 0 : _a.duration;
|
|
603
|
+
return parseDurationValue(value, duration);
|
|
604
|
+
}
|
|
605
|
+
if (attrType === "COMBINATION") {
|
|
606
|
+
const value = row[own.columnName];
|
|
607
|
+
const params2 = own.fieldSetting || {};
|
|
608
|
+
const data = parseCombinationValue(value, params2);
|
|
609
|
+
return data ? [createVNode("span", {
|
|
610
|
+
"title": data
|
|
611
|
+
}, [data])] : "";
|
|
612
|
+
}
|
|
613
|
+
if (attrType === "PASSWORD") {
|
|
614
|
+
const value = row[own.columnName];
|
|
615
|
+
return [createVNode(resolveComponent("password-com"), {
|
|
616
|
+
"value": value,
|
|
617
|
+
"styleSetting": props.styleSetting
|
|
618
|
+
}, null)];
|
|
619
|
+
}
|
|
620
|
+
if (attrType === "QR_CODE") {
|
|
621
|
+
return getOrCode(row, own);
|
|
622
|
+
}
|
|
623
|
+
if (column.property === "operatorColumn") {
|
|
624
|
+
if ((col == null ? void 0 : col.formType) === "custom" && col.slotFn && !row.initRow) {
|
|
625
|
+
return col.slotFn(row, col, $rowIndex);
|
|
626
|
+
}
|
|
627
|
+
if (props.columnConfig.isEdit && !row.initRow) {
|
|
628
|
+
return getEditBtn(row, col, $rowIndex);
|
|
629
|
+
}
|
|
630
|
+
if (state.showButtonTop != 0 || props.isBatchEditing)
|
|
631
|
+
return;
|
|
632
|
+
const inlineBtnList = generateInlineBtnList(row);
|
|
633
|
+
const tileBtnList = getTileBtnList(row, $rowIndex);
|
|
634
|
+
const foldBtnList = getFoldBtnList(row, $rowIndex);
|
|
635
|
+
return [createVNode("span", null, [tileBtnList, foldBtnList, inlineBtnList])];
|
|
636
|
+
}
|
|
637
|
+
if (isLink(props, own, row) && !isScanMultiTable.value) {
|
|
638
|
+
if (own.btnLinkSwitch) {
|
|
639
|
+
let disabled = false;
|
|
640
|
+
let curBtn = (_b = row.btnList) == null ? void 0 : _b.find((v) => v.name == own.columnName);
|
|
641
|
+
if (curBtn && "authorizedMark" in curBtn) {
|
|
642
|
+
if (!curBtn.authorizedMark) {
|
|
643
|
+
disabled = true;
|
|
644
|
+
}
|
|
645
|
+
}
|
|
646
|
+
return getBtnLinkSwitch(row, own, disabled, $rowIndex);
|
|
647
|
+
} else {
|
|
648
|
+
return getField(row, own, $rowIndex, true);
|
|
649
|
+
}
|
|
650
|
+
} else {
|
|
651
|
+
return getField(row, own, $rowIndex, false);
|
|
652
|
+
}
|
|
653
|
+
};
|
|
654
|
+
const formatterHeader = (item) => {
|
|
655
|
+
let field = state.filterFields[item.columnName];
|
|
656
|
+
return () => {
|
|
657
|
+
var _a;
|
|
658
|
+
let _slot, _slot2;
|
|
659
|
+
return [createVNode("div", {
|
|
660
|
+
"class": "filter-box"
|
|
661
|
+
}, [toolTipTitle(item, "format"), createVNode("i", {
|
|
662
|
+
"class": ["vxe-filter--icon", "vxe-filter--btn", "vxe-icon--funnel", {
|
|
663
|
+
active: field.visible || field.filterSort
|
|
664
|
+
}, {
|
|
665
|
+
checked: (_a = field.CONVERT) == null ? void 0 : _a.length
|
|
666
|
+
}],
|
|
667
|
+
"onClick": (event) => showFilter(field, item.columnName, event, props, state)
|
|
668
|
+
}, null), field.visible ? createVNode(Teleport, {
|
|
669
|
+
"to": props.filterDomPortal
|
|
670
|
+
}, {
|
|
671
|
+
default: () => [createVNode("div", {
|
|
672
|
+
"class": "big-table-filter-wrap",
|
|
673
|
+
"style": {
|
|
674
|
+
left: field.left,
|
|
675
|
+
right: field.right,
|
|
676
|
+
top: field.top,
|
|
677
|
+
width: state.filterWidth + state.distance + "px"
|
|
678
|
+
}
|
|
679
|
+
}, [createVNode("div", {
|
|
680
|
+
"class": "sort-list",
|
|
681
|
+
"style": {
|
|
682
|
+
display: field.isSort ? "block" : "none"
|
|
683
|
+
}
|
|
684
|
+
}, [createVNode("div", {
|
|
685
|
+
"class": ["sort-item", {
|
|
686
|
+
active: field.filterSort === "asc"
|
|
687
|
+
}],
|
|
688
|
+
"onClick": () => handlefilterBoxClickSort("asc", field)
|
|
689
|
+
}, [createVNode("i", {
|
|
690
|
+
"class": "sort-icon sort-icon-asc"
|
|
691
|
+
}, null), createVNode("span", {
|
|
692
|
+
"class": "sort-text"
|
|
693
|
+
}, [createTextVNode("\u5347\u5E8F A to Z")])]), createVNode("div", {
|
|
694
|
+
"class": ["sort-item", {
|
|
695
|
+
active: field.filterSort === "desc"
|
|
696
|
+
}],
|
|
697
|
+
"onClick": () => handlefilterBoxClickSort("desc", field)
|
|
698
|
+
}, [createVNode("i", {
|
|
699
|
+
"class": "sort-icon sort-icon-asc"
|
|
700
|
+
}, null), createVNode("span", {
|
|
701
|
+
"class": "sort-text"
|
|
702
|
+
}, [createTextVNode("\u964D\u5E8F Z to A")])])]), createVNode("div", {
|
|
703
|
+
"class": "filter-header"
|
|
704
|
+
}, [createVNode("i", {
|
|
705
|
+
"class": "filter-header-icon vxe-filter--btn vxe-icon--funnel"
|
|
706
|
+
}, null), createVNode("span", {
|
|
707
|
+
"class": "filter-header-text"
|
|
708
|
+
}, [createTextVNode("\u7B5B\u9009")])]), field.setting.showSetting.length > 5 ? createVNode("div", {
|
|
709
|
+
"class": "checkbox-wrap checkbox-wrap--search"
|
|
710
|
+
}, [createVNode("div", {
|
|
711
|
+
"class": "check-search-wrap"
|
|
712
|
+
}, [createVNode(NInputGroup, null, {
|
|
713
|
+
default: () => [createVNode(NInput, {
|
|
714
|
+
"style": {
|
|
715
|
+
width: "50%"
|
|
716
|
+
},
|
|
717
|
+
"placeholder": "\u5B57\u6BB5\u641C\u7D22",
|
|
718
|
+
"class": "check-seach-input"
|
|
719
|
+
}, null), createVNode(NButton, {
|
|
720
|
+
"type": "primary",
|
|
721
|
+
"onClick": (val) => {
|
|
722
|
+
handleFilterSeach(val, field);
|
|
723
|
+
}
|
|
724
|
+
}, {
|
|
725
|
+
default: () => [createTextVNode("\u641C\u7D22")]
|
|
726
|
+
})]
|
|
727
|
+
})])]) : "", createVNode("div", {
|
|
728
|
+
"class": "checkbox-box"
|
|
729
|
+
}, [createVNode("div", {
|
|
730
|
+
"class": "checkbox-wrap js-checkbox-wrap",
|
|
731
|
+
"style": {
|
|
732
|
+
height: state.filterHeight + state.distance + "px"
|
|
733
|
+
}
|
|
734
|
+
}, [!field.searchFilterText ? createVNode("div", {
|
|
735
|
+
"class": "ant-checkbox-group"
|
|
736
|
+
}, [createVNode(NCheckbox, {
|
|
737
|
+
"indeterminate": field.indeterminate,
|
|
738
|
+
"checked": field.checkAll,
|
|
739
|
+
"onUpdate:checked": (val) => {
|
|
740
|
+
handleFilterChangeAll(val, field);
|
|
741
|
+
}
|
|
742
|
+
}, {
|
|
743
|
+
default: () => [createTextVNode("\u5168\u9009")]
|
|
744
|
+
})]) : "", !field.searchFilterText ? createVNode(NCheckboxGroup, {
|
|
745
|
+
"value": field.CONVERT,
|
|
746
|
+
"onUpdate:value": (val) => handleFilterChange(val, item.columnName, field)
|
|
747
|
+
}, {
|
|
748
|
+
default: () => [createVNode(NSpace, {
|
|
749
|
+
"item-style": "display: flex;"
|
|
750
|
+
}, _isSlot(_slot = field.setting.showSetting.map((item2) => {
|
|
751
|
+
return createVNode(NCheckbox, {
|
|
752
|
+
"value": item2.value,
|
|
753
|
+
"label": item2.label
|
|
754
|
+
}, null);
|
|
755
|
+
})) ? _slot : {
|
|
756
|
+
default: () => [_slot]
|
|
757
|
+
})]
|
|
758
|
+
}) : createVNode(NCheckboxGroup, {
|
|
759
|
+
"value": field.searchFilterCONVERT,
|
|
760
|
+
"onUpdate:value": (val) => handleFilterSearchChange(val, item.columnName, field)
|
|
761
|
+
}, {
|
|
762
|
+
default: () => [createVNode(NSpace, {
|
|
763
|
+
"item-style": "display: flex;"
|
|
764
|
+
}, _isSlot(_slot2 = field.setting.showSetting.filter((item2) => {
|
|
765
|
+
if (!field.searchFilterText)
|
|
766
|
+
return item2;
|
|
767
|
+
let reg = new RegExp(field.searchFilterText);
|
|
768
|
+
return reg.test(item2.label);
|
|
769
|
+
}).map((item2) => {
|
|
770
|
+
return createVNode(NCheckbox, {
|
|
771
|
+
"value": item2.value,
|
|
772
|
+
"label": item2.label
|
|
773
|
+
}, null);
|
|
774
|
+
})) ? _slot2 : {
|
|
775
|
+
default: () => [_slot2]
|
|
776
|
+
})]
|
|
777
|
+
})])]), createVNode("div", {
|
|
778
|
+
"class": "checkbox-btn-wrap",
|
|
779
|
+
"style": {
|
|
780
|
+
justifyContent: field.CONVERT.length ? "space-between" : "flex-end"
|
|
781
|
+
}
|
|
782
|
+
}, [field.CONVERT.length ? createVNode("div", {
|
|
783
|
+
"class": "checkbox-btn-status"
|
|
784
|
+
}, [createVNode("span", null, [createTextVNode("\u5DF2\u9009\u62E9"), field.CONVERT.length, createTextVNode("\u9879")]), createVNode(NButton, {
|
|
785
|
+
"class": "checkbox-btn checkbox-btn-clear",
|
|
786
|
+
"text": true,
|
|
787
|
+
"onClick": () => handleFilterClearAll(field)
|
|
788
|
+
}, {
|
|
789
|
+
default: () => [createTextVNode("\u6E05\u7A7A")]
|
|
790
|
+
})]) : null, createVNode("div", null, [createVNode(NButton, {
|
|
791
|
+
"class": "checkbox-btn",
|
|
792
|
+
"onClick": () => handleCancelFilter()
|
|
793
|
+
}, {
|
|
794
|
+
default: () => [createTextVNode("\u53D6\u6D88")]
|
|
795
|
+
}), createVNode(NButton, {
|
|
796
|
+
"class": "checkbox-btn",
|
|
797
|
+
"type": "primary",
|
|
798
|
+
"onClick": () => handleFilter(field)
|
|
799
|
+
}, {
|
|
800
|
+
default: () => [createTextVNode("\u786E\u5B9A")]
|
|
801
|
+
})])]), createVNode("div", {
|
|
802
|
+
"class": "arrows-icon"
|
|
803
|
+
}, null)])]
|
|
804
|
+
}) : ""])];
|
|
805
|
+
};
|
|
806
|
+
};
|
|
807
|
+
const handlefilterBoxClickSort = (sort, field) => {
|
|
808
|
+
if (field.filterSort === sort) {
|
|
809
|
+
sort = null;
|
|
810
|
+
} else {
|
|
811
|
+
xGrid.value.clearSort();
|
|
812
|
+
}
|
|
813
|
+
field.filterSort = sort;
|
|
814
|
+
emit("sortChange", {
|
|
815
|
+
prop: field.columnName,
|
|
816
|
+
order: sort
|
|
817
|
+
});
|
|
818
|
+
};
|
|
819
|
+
const handleFilterSeach = (val, field) => {
|
|
820
|
+
field.searchFilterText = val;
|
|
821
|
+
if (val === "") {
|
|
822
|
+
field.checkAll = field.CONVERT.length === field.setting.showSetting.length;
|
|
823
|
+
field.indeterminate = !!field.CONVERT.length && field.CONVERT.length !== field.setting.showSetting.length;
|
|
824
|
+
return;
|
|
825
|
+
}
|
|
826
|
+
field.searchFilterCONVERT = field.setting.showSetting.filter((item) => {
|
|
827
|
+
return field.searchFilterText === item.label && field.CONVERT.includes(item.value);
|
|
828
|
+
}).map((item) => item.value);
|
|
829
|
+
_beforeSearchConvert = field.searchFilterCONVERT;
|
|
830
|
+
};
|
|
831
|
+
const handleFilterChangeAll = (val, field) => {
|
|
832
|
+
reScrollFilterWrap();
|
|
833
|
+
let checked = val;
|
|
834
|
+
field.indeterminate = false;
|
|
835
|
+
field.checkAll = checked;
|
|
836
|
+
state.filterFields[field.columnName].CONVERT = checked ? field.setting.showSetting.map((item) => {
|
|
837
|
+
return item.value;
|
|
838
|
+
}) : [];
|
|
839
|
+
};
|
|
840
|
+
const handleFilterChange = (value, name, field) => {
|
|
841
|
+
reScrollFilterWrap();
|
|
842
|
+
state.filterFields[name].CONVERT = value;
|
|
843
|
+
field.checkAll = value.length === field.setting.showSetting.length;
|
|
844
|
+
field.indeterminate = !!value.length && value.length !== field.setting.showSetting.length;
|
|
845
|
+
};
|
|
846
|
+
const handleFilterSearchChange = (value, columnName, field) => {
|
|
847
|
+
reScrollFilterWrap();
|
|
848
|
+
let isAdd = _beforeSearchConvert.length < value.length;
|
|
849
|
+
if (isAdd) {
|
|
850
|
+
let addItems = value.filter((item) => {
|
|
851
|
+
return !_beforeSearchConvert.includes(item);
|
|
852
|
+
});
|
|
853
|
+
state.filterFields[columnName].CONVERT.push(...addItems);
|
|
854
|
+
} else {
|
|
855
|
+
let removeItems = _beforeSearchConvert.filter((item) => {
|
|
856
|
+
return !value.includes(item);
|
|
857
|
+
});
|
|
858
|
+
state.filterFields[columnName].CONVERT = state.filterFields[columnName].CONVERT.filter((item) => {
|
|
859
|
+
return !removeItems.includes(item);
|
|
860
|
+
});
|
|
861
|
+
}
|
|
862
|
+
field.searchFilterCONVERT = value;
|
|
863
|
+
_beforeSearchConvert = vexutils.clone(value, true);
|
|
864
|
+
};
|
|
865
|
+
const handleFilterClearAll = (field) => {
|
|
866
|
+
field.indeterminate = false;
|
|
867
|
+
field.checkAll = false;
|
|
868
|
+
state.filterFields[field.columnName].CONVERT = [];
|
|
869
|
+
if (field.searchFilterCONVERT) {
|
|
870
|
+
state.filterFields[field.columnName].searchFilterCONVERT = [];
|
|
871
|
+
}
|
|
872
|
+
handleFilter(field);
|
|
873
|
+
};
|
|
874
|
+
const handleCancelFilter = () => {
|
|
875
|
+
hideFilterWrap(state, props);
|
|
876
|
+
};
|
|
877
|
+
const handleFilter = (field) => {
|
|
878
|
+
let conObj = mergeConObjFn(state, props);
|
|
879
|
+
emit("onSave", conObj, false, [], [], {
|
|
880
|
+
isBigTable: true
|
|
881
|
+
});
|
|
882
|
+
field.visible = false;
|
|
883
|
+
};
|
|
884
|
+
const setGroupTreeExpand = () => {
|
|
885
|
+
let isExpand = state.isTree == 1 && state.isExpand == 1 && state.total < 1001;
|
|
886
|
+
if (state.isTree == 3 || isExpand) {
|
|
887
|
+
let table = xGrid.value;
|
|
888
|
+
nextTick(() => {
|
|
889
|
+
table.setAllTreeExpand(true);
|
|
890
|
+
});
|
|
891
|
+
}
|
|
892
|
+
};
|
|
893
|
+
const resetTableInlineEditStatus = () => {
|
|
894
|
+
if (!checkOperateCurrentTable())
|
|
895
|
+
return false;
|
|
896
|
+
handleClickCancelBtnByInline();
|
|
897
|
+
};
|
|
898
|
+
const toolTipTitle = (item, type) => {
|
|
899
|
+
var _a;
|
|
900
|
+
let name = item.formTitle || item.alias || item.title;
|
|
901
|
+
let tooltipTitle = item.alias;
|
|
902
|
+
let isAlias = false;
|
|
903
|
+
if (((_a = props.tableOptions) == null ? void 0 : _a.dataSourceType) == "guage") {
|
|
904
|
+
tooltipTitle = item.alias || item.title;
|
|
905
|
+
}
|
|
906
|
+
if (name && tooltipTitle && name !== tooltipTitle) {
|
|
907
|
+
isAlias = !!tooltipTitle;
|
|
908
|
+
}
|
|
909
|
+
if (type === "format")
|
|
910
|
+
return createVNode(TextOverTooltip, {
|
|
911
|
+
"tooltipTitle": tooltipTitle,
|
|
912
|
+
"content": name,
|
|
913
|
+
"isAlias": isAlias
|
|
914
|
+
}, null);
|
|
915
|
+
return () => {
|
|
916
|
+
return [createVNode(TextOverTooltip, {
|
|
917
|
+
"tooltipTitle": tooltipTitle,
|
|
918
|
+
"content": name,
|
|
919
|
+
"isAlias": isAlias
|
|
920
|
+
}, {
|
|
921
|
+
default: () => [item.treeNode && state.isTree == 1 ? createVNode(NIcon, {
|
|
922
|
+
"component": state.isExpand && state.total < 1001 ? CaretDown : CaretForward,
|
|
923
|
+
"onClick": (e) => triggerExpand(e, state.isExpand)
|
|
924
|
+
}, null) : ""]
|
|
925
|
+
})];
|
|
926
|
+
};
|
|
927
|
+
};
|
|
928
|
+
const triggerExpand = (e, isExpand) => {
|
|
929
|
+
e.preventDefault();
|
|
930
|
+
e.stopPropagation();
|
|
931
|
+
let table = xGrid.value;
|
|
932
|
+
if (state.total > 1e3) {
|
|
933
|
+
$message.warning("\u5F53\u524D\u6570\u636E\u91CF\u8D85\u8FC71000\u6761\uFF0C\u65E0\u6CD5\u5168\u90E8\u5C55\u5F00\uFF01");
|
|
934
|
+
} else {
|
|
935
|
+
state.isExpand = !isExpand;
|
|
936
|
+
if (isExpand) {
|
|
937
|
+
table.clearTreeExpand();
|
|
938
|
+
} else {
|
|
939
|
+
emit("triggerSpinning", true);
|
|
940
|
+
setTimeout(() => {
|
|
941
|
+
table.setAllTreeExpand(true).then(() => {
|
|
942
|
+
emit("triggerSpinning", false);
|
|
943
|
+
});
|
|
944
|
+
}, 100);
|
|
945
|
+
}
|
|
946
|
+
}
|
|
947
|
+
};
|
|
948
|
+
const getOtherConfigInit = () => {
|
|
949
|
+
let tableOptions = (attr == null ? void 0 : attr.tableOptions) || props.tableOptions || {};
|
|
950
|
+
const config = (tableOptions == null ? void 0 : tableOptions.config) || {};
|
|
951
|
+
return config || void 0;
|
|
952
|
+
};
|
|
953
|
+
const refreshTable = () => {
|
|
954
|
+
state.hasRefresh = false;
|
|
955
|
+
emit("refreshTable");
|
|
956
|
+
};
|
|
957
|
+
const handleCheckAll = () => {
|
|
958
|
+
if (props.pageVO.total > props.maxCheckSize) {
|
|
959
|
+
let text = `\u5F53\u524D\u5217\u8868\u5171${props.pageVO.total}\u6761\u6570\u636E\uFF0C\u4E3A\u4E86\u786E\u4FDD\u7CFB\u7EDF\u5B89\u5168\uFF0C\u53EA\u80FD\u5355\u6B21\u64CD\u4F5C${props.maxCheckSize}\u6761\uFF0C\u4F60\u53EF\u4EE5\u901A\u8FC7\u9AD8\u7EA7\u7B5B\u9009\u8FC7\u6EE4\u518D\u6B21\u5C1D\u8BD5`;
|
|
960
|
+
$message.warning(text);
|
|
961
|
+
}
|
|
962
|
+
emit("selectionChangeAll");
|
|
963
|
+
};
|
|
964
|
+
const handleCancelAllCheck = () => {
|
|
965
|
+
emit("selectionChangeAllCancel");
|
|
966
|
+
};
|
|
967
|
+
const getRowClassName = () => {
|
|
968
|
+
return state.selectType === "checkbox" ? ({
|
|
969
|
+
row
|
|
970
|
+
}) => {
|
|
971
|
+
const k = singleCheckedKey.value;
|
|
972
|
+
return k && k === row[props.primaryKey] ? "single--checked" : "";
|
|
973
|
+
} : () => {
|
|
974
|
+
};
|
|
975
|
+
};
|
|
976
|
+
const footerMethod = ({
|
|
977
|
+
columns,
|
|
978
|
+
data
|
|
979
|
+
}) => {
|
|
980
|
+
if (!props.groupCountFields || !props.groupCountFields.length) {
|
|
981
|
+
return [columns.map((column, index) => {
|
|
982
|
+
if (index === 0) {
|
|
983
|
+
return null;
|
|
984
|
+
}
|
|
985
|
+
return null;
|
|
986
|
+
})];
|
|
987
|
+
}
|
|
988
|
+
let groupText = getFooterGroup(columns, data, props);
|
|
989
|
+
let groupColumns = columns.map((column, index) => {
|
|
990
|
+
if (index === 0) {
|
|
991
|
+
return null;
|
|
992
|
+
} else if (index === 1) {
|
|
993
|
+
return groupText;
|
|
994
|
+
}
|
|
995
|
+
return null;
|
|
996
|
+
});
|
|
997
|
+
emit("setGroupText", groupText);
|
|
998
|
+
state.groupText = groupText;
|
|
999
|
+
return [groupColumns];
|
|
1000
|
+
};
|
|
1001
|
+
const loadChildrenMethod = ({
|
|
1002
|
+
row
|
|
1003
|
+
}) => {
|
|
1004
|
+
const fixCheckedStatus = (children) => {
|
|
1005
|
+
const needFix = state.selectType == "checkbox" && row.checked && children.findIndex((item) => !checkMethod({
|
|
1006
|
+
row: item
|
|
1007
|
+
})) >= 0;
|
|
1008
|
+
if (needFix) {
|
|
1009
|
+
needFix && (row.checked = false);
|
|
1010
|
+
setTimeout(() => {
|
|
1011
|
+
var _a;
|
|
1012
|
+
(_a = xGrid.value) == null ? void 0 : _a.setCheckboxRow(row, true);
|
|
1013
|
+
}, 0);
|
|
1014
|
+
}
|
|
1015
|
+
};
|
|
1016
|
+
if (state.isTree == 2) {
|
|
1017
|
+
const {
|
|
1018
|
+
tableId,
|
|
1019
|
+
page,
|
|
1020
|
+
pageSize,
|
|
1021
|
+
autograph,
|
|
1022
|
+
isTreeOrList
|
|
1023
|
+
} = props.tableParams;
|
|
1024
|
+
({
|
|
1025
|
+
levelLazyLoadPrimaryKeyValue: row[props.primaryKey],
|
|
1026
|
+
tableId,
|
|
1027
|
+
page,
|
|
1028
|
+
pageSize,
|
|
1029
|
+
autograph,
|
|
1030
|
+
isTreeOrList
|
|
1031
|
+
});
|
|
1032
|
+
return getAsyncTableData().then(({
|
|
1033
|
+
data
|
|
1034
|
+
}) => {
|
|
1035
|
+
if (data.result == "SUCCESS") {
|
|
1036
|
+
let cloneRows = JSON.parse(JSON.stringify(data.map.rows));
|
|
1037
|
+
let {
|
|
1038
|
+
fieldList,
|
|
1039
|
+
btnList,
|
|
1040
|
+
showButtonTop
|
|
1041
|
+
} = props.columnConfig;
|
|
1042
|
+
let rowNodes = formatData({
|
|
1043
|
+
tableList: data.map.rows,
|
|
1044
|
+
fieldList,
|
|
1045
|
+
btnList,
|
|
1046
|
+
showButtonTop
|
|
1047
|
+
});
|
|
1048
|
+
rowNodes = setChecklist(rowNodes);
|
|
1049
|
+
emit("refreshOldTableData", cloneRows);
|
|
1050
|
+
fixCheckedStatus(rowNodes);
|
|
1051
|
+
return rowNodes;
|
|
1052
|
+
}
|
|
1053
|
+
});
|
|
1054
|
+
} else {
|
|
1055
|
+
fixCheckedStatus(row.childrenList);
|
|
1056
|
+
return Promise.resolve(row.childrenList);
|
|
1057
|
+
}
|
|
1058
|
+
};
|
|
1059
|
+
const getAsyncTableData = (params) => {
|
|
1060
|
+
return Promise.resolve();
|
|
1061
|
+
};
|
|
1062
|
+
const setChecklist = (list) => {
|
|
1063
|
+
return list.map((i) => {
|
|
1064
|
+
i["checked"] = i.checked || false;
|
|
1065
|
+
if (state.isTree == 2) {
|
|
1066
|
+
const treeNodeKey = state.levelLazyLoadSetting.childCountKey;
|
|
1067
|
+
const {
|
|
1068
|
+
isTreeOrList = ""
|
|
1069
|
+
} = props.tableParams;
|
|
1070
|
+
if (treeNodeKey && Number(i[treeNodeKey]) > 0) {
|
|
1071
|
+
isTreeOrList != "LIST" && (i["hasChildren"] = true);
|
|
1072
|
+
}
|
|
1073
|
+
}
|
|
1074
|
+
if (i.childrenList && i.childrenList.length) {
|
|
1075
|
+
i.childrenList = setChecklist(i.childrenList);
|
|
1076
|
+
}
|
|
1077
|
+
Object.keys(i).map((item) => {
|
|
1078
|
+
if (i[item] && typeof i[item] == "string" && i[item].indexOf("<p") !== -1 && item.indexOf("_temp_" + i.id) === -1) {
|
|
1079
|
+
i[item + "_temp_" + i.id] = i[item] || "";
|
|
1080
|
+
i[item] = htmlToText(i[item]);
|
|
1081
|
+
}
|
|
1082
|
+
});
|
|
1083
|
+
i.checked && state.checkedRows.push(i);
|
|
1084
|
+
return {
|
|
1085
|
+
...i
|
|
1086
|
+
};
|
|
1087
|
+
});
|
|
1088
|
+
};
|
|
1089
|
+
const colspanMethod = ({
|
|
1090
|
+
row,
|
|
1091
|
+
column,
|
|
1092
|
+
_rowIndex,
|
|
1093
|
+
_columnIndex
|
|
1094
|
+
}) => {
|
|
1095
|
+
if (state.isTree != 3) {
|
|
1096
|
+
return {
|
|
1097
|
+
rowspan: 1,
|
|
1098
|
+
colspan: 1
|
|
1099
|
+
};
|
|
1100
|
+
}
|
|
1101
|
+
let xTree = xGrid.value;
|
|
1102
|
+
let fristKeyIndex = xTree.getTableColumn().tableColumn.findIndex((column2) => {
|
|
1103
|
+
return !!column2.property;
|
|
1104
|
+
});
|
|
1105
|
+
let colspan = xTree.getTableColumn().tableColumn.length - fristKeyIndex;
|
|
1106
|
+
if (row.childrenList && row.childrenList.length && xTree) {
|
|
1107
|
+
if (column.treeNode) {
|
|
1108
|
+
return {
|
|
1109
|
+
rowspan: 1,
|
|
1110
|
+
colspan
|
|
1111
|
+
};
|
|
1112
|
+
} else if (!column.property) {
|
|
1113
|
+
return {
|
|
1114
|
+
rowspan: 1,
|
|
1115
|
+
colspan: 1
|
|
1116
|
+
};
|
|
1117
|
+
} else {
|
|
1118
|
+
return {
|
|
1119
|
+
rowspan: 0,
|
|
1120
|
+
colspan: 0
|
|
1121
|
+
};
|
|
1122
|
+
}
|
|
1123
|
+
}
|
|
1124
|
+
};
|
|
1125
|
+
const footerRowspanMethod = (obj) => {
|
|
1126
|
+
if (!props.groupCountFields || !props.groupCountFields.length)
|
|
1127
|
+
return {
|
|
1128
|
+
rowspan: 1,
|
|
1129
|
+
colspan: 1
|
|
1130
|
+
};
|
|
1131
|
+
let {
|
|
1132
|
+
$rowIndex,
|
|
1133
|
+
_columnIndex,
|
|
1134
|
+
column
|
|
1135
|
+
} = obj;
|
|
1136
|
+
let len = state.columnLen || 99;
|
|
1137
|
+
let {
|
|
1138
|
+
isBatchSelect
|
|
1139
|
+
} = props.columnConfig;
|
|
1140
|
+
if ($rowIndex === 0) {
|
|
1141
|
+
if (isBatchSelect == 1) {
|
|
1142
|
+
if (_columnIndex === 0) {
|
|
1143
|
+
return {
|
|
1144
|
+
rowspan: 1,
|
|
1145
|
+
colspan: 2
|
|
1146
|
+
};
|
|
1147
|
+
} else if (_columnIndex === 1) {
|
|
1148
|
+
return {
|
|
1149
|
+
rowspan: 1,
|
|
1150
|
+
colspan: 0
|
|
1151
|
+
};
|
|
1152
|
+
} else if (_columnIndex === 2) {
|
|
1153
|
+
return {
|
|
1154
|
+
rowspan: 1,
|
|
1155
|
+
colspan: len
|
|
1156
|
+
};
|
|
1157
|
+
}
|
|
1158
|
+
return {
|
|
1159
|
+
rowspan: 1,
|
|
1160
|
+
colspan: 0
|
|
1161
|
+
};
|
|
1162
|
+
}
|
|
1163
|
+
if (_columnIndex === 0) {
|
|
1164
|
+
return {
|
|
1165
|
+
rowspan: 1,
|
|
1166
|
+
colspan: 1
|
|
1167
|
+
};
|
|
1168
|
+
} else if (_columnIndex === 1) {
|
|
1169
|
+
return {
|
|
1170
|
+
rowspan: 1,
|
|
1171
|
+
colspan: len
|
|
1172
|
+
};
|
|
1173
|
+
}
|
|
1174
|
+
return {
|
|
1175
|
+
rowspan: 1,
|
|
1176
|
+
colspan: 0
|
|
1177
|
+
};
|
|
1178
|
+
}
|
|
1179
|
+
};
|
|
1180
|
+
const rowdblclick = ({
|
|
1181
|
+
row,
|
|
1182
|
+
column
|
|
1183
|
+
}) => {
|
|
1184
|
+
if (isScanMultiTable.value || !!props.isInlineOperating)
|
|
1185
|
+
return false;
|
|
1186
|
+
if (vexutils.has(row, GROUP_TITLE_KEY))
|
|
1187
|
+
return false;
|
|
1188
|
+
emit("setNestTableClick", props.isNestTable);
|
|
1189
|
+
emit("rowdblclick", row, column, true, true);
|
|
1190
|
+
};
|
|
1191
|
+
const pubCheckChange = (rows = []) => {
|
|
1192
|
+
state.treeTableLength = rows.filter((item) => {
|
|
1193
|
+
let isGroupRow = vexutils.has(item, GROUP_TITLE_KEY);
|
|
1194
|
+
return !isGroupRow;
|
|
1195
|
+
}).length;
|
|
1196
|
+
state.visibleTreeCheck = rows.length > 1;
|
|
1197
|
+
emit("selectionChange", rows);
|
|
1198
|
+
};
|
|
1199
|
+
const updateAddCheckedRows = (rows, isTree = false) => {
|
|
1200
|
+
let obj = {
|
|
1201
|
+
isUpdate: true,
|
|
1202
|
+
updateRows: rows,
|
|
1203
|
+
isTree
|
|
1204
|
+
};
|
|
1205
|
+
if (isTree) {
|
|
1206
|
+
Object.assign(obj, {
|
|
1207
|
+
isTree,
|
|
1208
|
+
isCheckedChange: true,
|
|
1209
|
+
checkedRows: state.checkedRows
|
|
1210
|
+
});
|
|
1211
|
+
}
|
|
1212
|
+
emit("selectionChangeLocal", obj);
|
|
1213
|
+
};
|
|
1214
|
+
const removeCheckedRows = (rows, isCheckedChange) => {
|
|
1215
|
+
removeCheckedDisabledRows(state);
|
|
1216
|
+
let checkedRows = state.checkedRows;
|
|
1217
|
+
let needRemoveIndexs = [];
|
|
1218
|
+
for (let i = 0; i < rows.length; i++) {
|
|
1219
|
+
let row = rows[i];
|
|
1220
|
+
let removeIndex = currentCheckedKeys.value.findIndex((item) => {
|
|
1221
|
+
return item === row[props.primaryKey];
|
|
1222
|
+
});
|
|
1223
|
+
removeIndex >= 0 && needRemoveIndexs.push(removeIndex);
|
|
1224
|
+
}
|
|
1225
|
+
needRemoveIndexs.sort((a, b) => b - a);
|
|
1226
|
+
emit("selectionChangeLocal", {
|
|
1227
|
+
isAdd: false,
|
|
1228
|
+
isCheckedChange,
|
|
1229
|
+
needRemoveIndexs,
|
|
1230
|
+
newCheckedRows: [],
|
|
1231
|
+
checkedRows
|
|
1232
|
+
});
|
|
1233
|
+
};
|
|
1234
|
+
const setCheckedMehod = (setChecked, row) => {
|
|
1235
|
+
if (setChecked) {
|
|
1236
|
+
updateAddCheckedRows(row);
|
|
1237
|
+
return;
|
|
1238
|
+
}
|
|
1239
|
+
if (props.pageVO.pageIndex != state.lastPageIndex) {
|
|
1240
|
+
updateAddCheckedRows(row);
|
|
1241
|
+
return;
|
|
1242
|
+
}
|
|
1243
|
+
if (currentCheckedKeys.value.includes(row[props.primaryKey])) {
|
|
1244
|
+
removeCheckedRows([row]);
|
|
1245
|
+
return;
|
|
1246
|
+
}
|
|
1247
|
+
updateAddCheckedRows(row);
|
|
1248
|
+
};
|
|
1249
|
+
const handlerClickRow = (data) => {
|
|
1250
|
+
if (isScanMultiTable.value || props.isInlineOperating)
|
|
1251
|
+
return false;
|
|
1252
|
+
if (vexutils.has(data == null ? void 0 : data.row, GROUP_TITLE_KEY))
|
|
1253
|
+
return false;
|
|
1254
|
+
if (state.isTriggerSelectionChange && state.isTree == 0)
|
|
1255
|
+
return false;
|
|
1256
|
+
let table = xGrid.value;
|
|
1257
|
+
isAboutNestTable.value && emit("resetNestLastClickTable", table);
|
|
1258
|
+
let {
|
|
1259
|
+
row,
|
|
1260
|
+
$event = {},
|
|
1261
|
+
$rowIndex
|
|
1262
|
+
} = data;
|
|
1263
|
+
let {
|
|
1264
|
+
className,
|
|
1265
|
+
tagName
|
|
1266
|
+
} = $event.target || {};
|
|
1267
|
+
if (tagName == "INPUT" || tagName == "svg" || tagName == "path")
|
|
1268
|
+
return;
|
|
1269
|
+
if (className && vexutils.isString(className)) {
|
|
1270
|
+
if (className.includes("n-input") || className.includes("n-base-selection-label"))
|
|
1271
|
+
return;
|
|
1272
|
+
if (className.includes("vxe-table--expand-btn"))
|
|
1273
|
+
return;
|
|
1274
|
+
}
|
|
1275
|
+
isAboutNestTable.value && emit("setNestLastClickTable", table, props.isNestTable, row[handleRowId.value], row);
|
|
1276
|
+
emit("setNestTableClick", false);
|
|
1277
|
+
if (props.isNestTable) {
|
|
1278
|
+
table == null ? void 0 : table.setAllCheckboxRow(false);
|
|
1279
|
+
nestHandleClickRow(table, data);
|
|
1280
|
+
return;
|
|
1281
|
+
}
|
|
1282
|
+
let forbiddenBatchSelect = !checkMethod(data);
|
|
1283
|
+
if (state.selectType == "checkbox" && forbiddenBatchSelect) {
|
|
1284
|
+
table == null ? void 0 : table.setAllCheckboxRow(false);
|
|
1285
|
+
const value = getRowClassName()({
|
|
1286
|
+
row
|
|
1287
|
+
}) == "single--checked" ? [] : [row];
|
|
1288
|
+
state.checkedRows = value;
|
|
1289
|
+
pubCheckChange(value);
|
|
1290
|
+
emit("handlerClickRow", row, $rowIndex);
|
|
1291
|
+
return;
|
|
1292
|
+
}
|
|
1293
|
+
state.visibleCheckAllWrap = false;
|
|
1294
|
+
state.visibleCheckAllWrapMore = false;
|
|
1295
|
+
let checked = false;
|
|
1296
|
+
if (state.selectType == "radio") {
|
|
1297
|
+
checked = table.isCheckedByRadioRow(row);
|
|
1298
|
+
} else {
|
|
1299
|
+
checked = table.isCheckedByCheckboxRow(row);
|
|
1300
|
+
}
|
|
1301
|
+
if (state.isradioChange) {
|
|
1302
|
+
checked = false;
|
|
1303
|
+
state.isradioChange = false;
|
|
1304
|
+
}
|
|
1305
|
+
let checkedRow = table.getCheckboxRecords();
|
|
1306
|
+
let rowLen = state.checkedRows.filter((item) => !vexutils.has(item, GROUP_TITLE_KEY)).length;
|
|
1307
|
+
let newRow = [];
|
|
1308
|
+
if (state.isTree != 0) {
|
|
1309
|
+
let {
|
|
1310
|
+
className: className2
|
|
1311
|
+
} = $event.target || {};
|
|
1312
|
+
if (className2 && className2.includes("vxe-tree--node-btn"))
|
|
1313
|
+
return;
|
|
1314
|
+
if (state.selectType === "checkbox") {
|
|
1315
|
+
let rowVal = {};
|
|
1316
|
+
if (!state.isTriggerSelectionChange) {
|
|
1317
|
+
table.setAllCheckboxRow(false);
|
|
1318
|
+
state.checkedRows = [row];
|
|
1319
|
+
pubCheckChange([row]);
|
|
1320
|
+
rowVal = row;
|
|
1321
|
+
} else {
|
|
1322
|
+
if (checkedRow.length > 1)
|
|
1323
|
+
return false;
|
|
1324
|
+
rowVal = checked || checkedRow.length === 1 && !checked ? checkedRow[0] : {};
|
|
1325
|
+
state.checkedRows = [rowVal];
|
|
1326
|
+
}
|
|
1327
|
+
updateAddCheckedRows(rowVal, true);
|
|
1328
|
+
emit("handlerClickRow", rowVal);
|
|
1329
|
+
return;
|
|
1330
|
+
}
|
|
1331
|
+
let newTheUniqueKeyArr = [];
|
|
1332
|
+
flattenRow(row, newRow, newTheUniqueKeyArr, handleRowId.value);
|
|
1333
|
+
let res = intersectRow(checkedRow, newTheUniqueKeyArr, handleRowId.value);
|
|
1334
|
+
if (!res) {
|
|
1335
|
+
rowLen = 1;
|
|
1336
|
+
} else {
|
|
1337
|
+
rowLen = checkedRow.filter((item) => !vexutils.has(item, GROUP_TITLE_KEY)).length;
|
|
1338
|
+
}
|
|
1339
|
+
}
|
|
1340
|
+
table.setAllCheckboxRow(false);
|
|
1341
|
+
let setChecked = checked;
|
|
1342
|
+
if (rowLen > 1) {
|
|
1343
|
+
state.selectType != "radio" && table.setCheckboxRow([row], true);
|
|
1344
|
+
state.isTree != 0 && state.selectType != "radio" && pubCheckChange(newRow);
|
|
1345
|
+
state.selectType != "radio" && emit("handlerClickRow", row, $rowIndex);
|
|
1346
|
+
} else {
|
|
1347
|
+
setChecked = !setChecked;
|
|
1348
|
+
if (!setChecked) {
|
|
1349
|
+
table.clearCurrentRow();
|
|
1350
|
+
state.selectType == "radio" && table.clearRadioRow();
|
|
1351
|
+
state.isTree != 0 && state.selectType != "radio" && pubCheckChange([]);
|
|
1352
|
+
} else {
|
|
1353
|
+
state.selectType == "radio" && table.setRadioRow(row);
|
|
1354
|
+
state.isTree != 0 && state.selectType != "radio" && pubCheckChange(newRow);
|
|
1355
|
+
}
|
|
1356
|
+
state.selectType != "radio" && table.setCheckboxRow([row], setChecked);
|
|
1357
|
+
}
|
|
1358
|
+
if (state.isTree != 0) {
|
|
1359
|
+
setChecked && emit("handlerClickRow", row, $rowIndex);
|
|
1360
|
+
return;
|
|
1361
|
+
}
|
|
1362
|
+
setCheckedMehod(setChecked, row);
|
|
1363
|
+
if (setChecked || rowLen > 1 || !rowLen) {
|
|
1364
|
+
state.checkedRows = [row];
|
|
1365
|
+
}
|
|
1366
|
+
if (!setChecked && rowLen === 1) {
|
|
1367
|
+
state.checkedRows = [];
|
|
1368
|
+
}
|
|
1369
|
+
setCurrentCheckedLength();
|
|
1370
|
+
state.lastPageIndex = props.pageVO.pageIndex;
|
|
1371
|
+
setChecked && emit("handlerClickRow", row, $rowIndex);
|
|
1372
|
+
};
|
|
1373
|
+
const addCheckedRows = (rows) => {
|
|
1374
|
+
removeCheckedDisabledRows(state);
|
|
1375
|
+
let checkedRows = state.checkedRows;
|
|
1376
|
+
if (currentCheckedKeys.value.length + rows.length > props.maxCheckSize) {
|
|
1377
|
+
$message.warning(`\u4E3A\u4E86\u4FDD\u8BC1\u7CFB\u7EDF\u5B89\u5168\uFF0C\u5355\u6B21\u64CD\u4F5C\u6570\u636E\u91CF\u9650\u989D\u4E3A${props.maxCheckSize}\u6761\uFF0C\u4F60\u53EF\u4EE5\u901A\u8FC7\u9AD8\u7EA7\u7B5B\u9009\u8FC7\u6EE4\u540E\u518D\u6B21\u5C1D\u8BD5`);
|
|
1378
|
+
return false;
|
|
1379
|
+
}
|
|
1380
|
+
let newCheckedRows = rows.filter((row) => {
|
|
1381
|
+
return !currentCheckedKeys.value.includes(row[props.primaryKey]);
|
|
1382
|
+
});
|
|
1383
|
+
checkedRows.push(...newCheckedRows);
|
|
1384
|
+
emit("selectionChangeLocal", {
|
|
1385
|
+
isAdd: true,
|
|
1386
|
+
isCheckedChange: true,
|
|
1387
|
+
newCheckedRows,
|
|
1388
|
+
checkedRows
|
|
1389
|
+
});
|
|
1390
|
+
};
|
|
1391
|
+
const treeTableSelectionChange = (records) => {
|
|
1392
|
+
if (state.isTree == 0) {
|
|
1393
|
+
return false;
|
|
1394
|
+
}
|
|
1395
|
+
pubCheckChange(records);
|
|
1396
|
+
return true;
|
|
1397
|
+
};
|
|
1398
|
+
const selectionChange = ({
|
|
1399
|
+
checked,
|
|
1400
|
+
row,
|
|
1401
|
+
records
|
|
1402
|
+
}) => {
|
|
1403
|
+
let table = xGrid.value;
|
|
1404
|
+
table.clearCurrentRow();
|
|
1405
|
+
state.isTriggerSelectionChange = true;
|
|
1406
|
+
setTimeout(() => {
|
|
1407
|
+
state.isTriggerSelectionChange = false;
|
|
1408
|
+
}, 0);
|
|
1409
|
+
if (treeTableSelectionChange(records))
|
|
1410
|
+
return;
|
|
1411
|
+
if (checked) {
|
|
1412
|
+
addCheckedRows([row]);
|
|
1413
|
+
} else {
|
|
1414
|
+
removeCheckedRows([row], true);
|
|
1415
|
+
}
|
|
1416
|
+
setCurrentCheckedLength();
|
|
1417
|
+
};
|
|
1418
|
+
const selectionChangeAll = ({
|
|
1419
|
+
checked,
|
|
1420
|
+
records
|
|
1421
|
+
}) => {
|
|
1422
|
+
if (treeTableSelectionChange(records))
|
|
1423
|
+
return;
|
|
1424
|
+
if (checked) {
|
|
1425
|
+
addCheckedRows(records);
|
|
1426
|
+
} else {
|
|
1427
|
+
removeCheckedRows(props.data);
|
|
1428
|
+
}
|
|
1429
|
+
setCurrentCheckedLength();
|
|
1430
|
+
};
|
|
1431
|
+
const radioOnChange = (rowData = {}) => {
|
|
1432
|
+
let {
|
|
1433
|
+
data,
|
|
1434
|
+
row,
|
|
1435
|
+
$rowIndex
|
|
1436
|
+
} = rowData;
|
|
1437
|
+
emit("selectionChange", [{
|
|
1438
|
+
...row
|
|
1439
|
+
}]);
|
|
1440
|
+
};
|
|
1441
|
+
const sortChange = ({
|
|
1442
|
+
property,
|
|
1443
|
+
order
|
|
1444
|
+
}) => {
|
|
1445
|
+
if (props.isInlineOperating)
|
|
1446
|
+
return false;
|
|
1447
|
+
Object.values(state.filterFields).forEach((item) => item.filterSort = null);
|
|
1448
|
+
emit("sortChange", {
|
|
1449
|
+
prop: property,
|
|
1450
|
+
order
|
|
1451
|
+
});
|
|
1452
|
+
};
|
|
1453
|
+
const showDrawer = () => {
|
|
1454
|
+
const theads = xGrid.value.$el.childNodes[0].childNodes[1].childNodes[0].getElementsByClassName("mycolumn");
|
|
1455
|
+
emit("setNestTableClickSetting", props.isNestTable);
|
|
1456
|
+
emit("showDrawer", theads);
|
|
1457
|
+
};
|
|
1458
|
+
const handleCellMouseenter = ({
|
|
1459
|
+
column,
|
|
1460
|
+
$event
|
|
1461
|
+
}) => {
|
|
1462
|
+
if (column.showOverflow === "title") {
|
|
1463
|
+
const target = $event == null ? void 0 : $event.currentTarget;
|
|
1464
|
+
const cls = target == null ? void 0 : target.className;
|
|
1465
|
+
const bodyCls = " vxe-body--column ";
|
|
1466
|
+
if (cls && ` ${cls} `.includes(bodyCls) && target && target.hasAttribute("title")) {
|
|
1467
|
+
const cellElem = target.querySelector(".vxe-cell");
|
|
1468
|
+
if (cellElem && cellElem.hasAttribute("title")) {
|
|
1469
|
+
cellElem.removeAttribute("title");
|
|
1470
|
+
}
|
|
1471
|
+
if (props.isInlineOperating) {
|
|
1472
|
+
if (target && target.hasAttribute("title")) {
|
|
1473
|
+
target.removeAttribute("title");
|
|
1474
|
+
}
|
|
1475
|
+
}
|
|
1476
|
+
}
|
|
1477
|
+
}
|
|
1478
|
+
};
|
|
1479
|
+
const getFooterTooltipTitle = (column) => {
|
|
1480
|
+
let t = "";
|
|
1481
|
+
if (vexutils.has(props.sumData, column.property)) {
|
|
1482
|
+
t += `<p class="table-footer-tooltip-label-wrap">
|
|
1483
|
+
<span class="table-footer-tooltip-label">\u6C42\u548C\uFF1A</span>
|
|
1484
|
+
${vexutils.round(Number(props.sumData[column.property]), 4)}
|
|
1485
|
+
</p>`;
|
|
1486
|
+
}
|
|
1487
|
+
if (vexutils.has(props.avgData, column.property)) {
|
|
1488
|
+
t += `<p class="table-footer-tooltip-label-wrap">
|
|
1489
|
+
<span class="table-footer-tooltip-label">\u5E73\u5747\u503C\uFF1A</span>
|
|
1490
|
+
${vexutils.round(Number(props.avgData[column.property]), 4)}</p>`;
|
|
1491
|
+
}
|
|
1492
|
+
return t;
|
|
1493
|
+
};
|
|
1494
|
+
const getFooterTitle = (column) => {
|
|
1495
|
+
if (vexutils.has(props.sumData, column.property)) {
|
|
1496
|
+
return vexutils.round(Number(props.sumData[column.property]), 2);
|
|
1497
|
+
}
|
|
1498
|
+
if (vexutils.has(props.avgData, column.property)) {
|
|
1499
|
+
return vexutils.round(Number(props.avgData[column.property]), 2);
|
|
1500
|
+
}
|
|
1501
|
+
};
|
|
1502
|
+
const hanldeClickRefresh = () => {
|
|
1503
|
+
emit("pubTableRefresh");
|
|
1504
|
+
};
|
|
1505
|
+
const confirmScanMulti = (params) => {
|
|
1506
|
+
let {
|
|
1507
|
+
row,
|
|
1508
|
+
$rowIndex
|
|
1509
|
+
} = params || {};
|
|
1510
|
+
if (!row)
|
|
1511
|
+
return;
|
|
1512
|
+
emit("scanMultiRemove", $rowIndex, params);
|
|
1513
|
+
let vxeTable = xGrid.value;
|
|
1514
|
+
vxeTable.remove(row);
|
|
1515
|
+
};
|
|
1516
|
+
const scanMultiOperate = (params) => {
|
|
1517
|
+
return createVNode(NPopconfirm, {
|
|
1518
|
+
"onPositiveClick": () => confirmScanMulti(params)
|
|
1519
|
+
}, {
|
|
1520
|
+
trigger: () => createVNode(SvgIcon, {
|
|
1521
|
+
"class": "scan-multi-delete",
|
|
1522
|
+
"iconClass": "shanchu"
|
|
1523
|
+
}, null),
|
|
1524
|
+
default: () => "\u662F\u5426\u786E\u8BA4\u5220\u9664\uFF1F"
|
|
1525
|
+
});
|
|
1526
|
+
};
|
|
1527
|
+
const showEditForm = (row, column, $rowIndex) => {
|
|
1528
|
+
if (!props.isMatchComponent || props.isNestTable || isScanMultiTable.value)
|
|
1529
|
+
return false;
|
|
1530
|
+
if (props.isBatchEditing || props.isInlineEditing || props.isInlineAdding) {
|
|
1531
|
+
let matchObj = state.editColumnMap[column.property];
|
|
1532
|
+
if (!matchObj || !matchObj.matchItem || !matchObj.fieldItem)
|
|
1533
|
+
return false;
|
|
1534
|
+
if (props.isBatchEditing && !props.isEditAllRow) {
|
|
1535
|
+
let matchIndex = state.checkedRows.findIndex((v) => v[props.primaryKey] == row[props.primaryKey]);
|
|
1536
|
+
if (matchIndex < 0)
|
|
1537
|
+
return false;
|
|
1538
|
+
}
|
|
1539
|
+
if (props.isInlineEditing || props.isInlineAdding) {
|
|
1540
|
+
if ($rowIndex !== 0)
|
|
1541
|
+
return false;
|
|
1542
|
+
}
|
|
1543
|
+
return matchObj.matchItem;
|
|
1544
|
+
}
|
|
1545
|
+
return false;
|
|
1546
|
+
};
|
|
1547
|
+
const initBatchDynamicProps = (unionItem, row, column, $rowIndex) => {
|
|
1548
|
+
let id = row[props.primaryKey];
|
|
1549
|
+
let dynamicPropsCache = props.batchDynamicPropsCache[id];
|
|
1550
|
+
if (dynamicPropsCache && dynamicPropsCache[unionItem.tableField]) {
|
|
1551
|
+
return dynamicPropsCache[unionItem.tableField];
|
|
1552
|
+
}
|
|
1553
|
+
let matchObj = state.editColumnMap[column.property];
|
|
1554
|
+
let {
|
|
1555
|
+
fieldItem = {}
|
|
1556
|
+
} = matchObj || {};
|
|
1557
|
+
let defaultCombinationForm = {};
|
|
1558
|
+
if (!props.isInlineAdding) {
|
|
1559
|
+
let originalRow = props.pageIndexOldtableData.find((item) => item[props.primaryKey] == row[props.primaryKey]);
|
|
1560
|
+
defaultCombinationForm = setDefaultFormData(column.property, fieldItem, originalRow);
|
|
1561
|
+
}
|
|
1562
|
+
let tempFieldItem = JSON.parse(JSON.stringify(fieldItem));
|
|
1563
|
+
let defaultForm = {
|
|
1564
|
+
fieldList: [tempFieldItem],
|
|
1565
|
+
defaultCombinationForm
|
|
1566
|
+
};
|
|
1567
|
+
let dynamicProps = {
|
|
1568
|
+
props: {
|
|
1569
|
+
formPrimaryKey: id,
|
|
1570
|
+
defaultForm,
|
|
1571
|
+
banRequest: true,
|
|
1572
|
+
propsFormBtn: true,
|
|
1573
|
+
propsDelSetting: true,
|
|
1574
|
+
parentConfig: {
|
|
1575
|
+
is_edit: "1"
|
|
1576
|
+
},
|
|
1577
|
+
configuration: configuration.value,
|
|
1578
|
+
isPure: true,
|
|
1579
|
+
isOpenShortcut: false,
|
|
1580
|
+
cacheUniqueKey: state.cacheUniqueKey,
|
|
1581
|
+
styleSetting: {}
|
|
1582
|
+
},
|
|
1583
|
+
on: {
|
|
1584
|
+
handleSubmit: handleSubmitEditForm,
|
|
1585
|
+
banSubmit
|
|
1586
|
+
}
|
|
1587
|
+
};
|
|
1588
|
+
emit("setBatchDynamicPropsCache", {
|
|
1589
|
+
primaryKey: row[props.primaryKey],
|
|
1590
|
+
tableField: unionItem.tableField,
|
|
1591
|
+
dynamicProps
|
|
1592
|
+
});
|
|
1593
|
+
return dynamicProps;
|
|
1594
|
+
};
|
|
1595
|
+
const handleSubmitEditForm = (obj = {}) => {
|
|
1596
|
+
if (props.isInlineEditing || props.isInlineAdding) {
|
|
1597
|
+
emit("submitEditFormSuccess", obj);
|
|
1598
|
+
return;
|
|
1599
|
+
}
|
|
1600
|
+
if (props.isBatchEditing) {
|
|
1601
|
+
emit("submitEditFormSuccessBatch", obj);
|
|
1602
|
+
return;
|
|
1603
|
+
}
|
|
1604
|
+
};
|
|
1605
|
+
const banSubmit = (obj) => {
|
|
1606
|
+
if (props.isInlineEditing || props.isInlineAdding) {
|
|
1607
|
+
emit("submitEditFormError");
|
|
1608
|
+
return;
|
|
1609
|
+
}
|
|
1610
|
+
if (props.isBatchEditing) {
|
|
1611
|
+
emit("submitEditFormErrorBatch", obj);
|
|
1612
|
+
return;
|
|
1613
|
+
}
|
|
1614
|
+
};
|
|
1615
|
+
const handleFormTheUniqueKey = async () => {
|
|
1616
|
+
var _a;
|
|
1617
|
+
emit("initInlineEditFormConfig", {
|
|
1618
|
+
listFormUnionSetting: props.listFormUnionSetting,
|
|
1619
|
+
inlineEditFormConfig: props.inlineEditFormConfig
|
|
1620
|
+
});
|
|
1621
|
+
let hasEditRow = (_a = props.btnList) == null ? void 0 : _a.find((item) => {
|
|
1622
|
+
var _a2;
|
|
1623
|
+
let trigger_type = item.settingObj && ((_a2 = item.settingObj[0]) == null ? void 0 : _a2.trigger_type);
|
|
1624
|
+
if (item.isShow == 1 && trigger_type == "EDIT_ROW")
|
|
1625
|
+
return true;
|
|
1626
|
+
return false;
|
|
1627
|
+
});
|
|
1628
|
+
if (!hasEditRow)
|
|
1629
|
+
return;
|
|
1630
|
+
};
|
|
1631
|
+
const handlePreView = (data, i, e) => {
|
|
1632
|
+
e.preventDefault();
|
|
1633
|
+
e.stopPropagation();
|
|
1634
|
+
if (!data)
|
|
1635
|
+
data = xb_big;
|
|
1636
|
+
emit("handlePreView", data, i);
|
|
1637
|
+
};
|
|
1638
|
+
const getPicture = (row, item, type) => {
|
|
1639
|
+
return [createVNode("div", {
|
|
1640
|
+
"class": ["img-wrap", type === "HEADPORTRAIT" ? "img-circle" : ""]
|
|
1641
|
+
}, [handleImgArr(row[item.columnName], type, imgs2imgArr).map((v, i) => createVNode("img", {
|
|
1642
|
+
"key": i,
|
|
1643
|
+
"src": handleImgSrc(v, props.sysImageSize, "LIST_FIELD_SMALL"),
|
|
1644
|
+
"style": modalDetailImage(props.sysImageSize, "LIST_FIELD_SMALL", "36px"),
|
|
1645
|
+
"onClick": (e) => handlePreView(row[item.columnName], i, e)
|
|
1646
|
+
}, null))])];
|
|
1647
|
+
};
|
|
1648
|
+
const getColor = (row, item) => {
|
|
1649
|
+
let color = row[item.columnName];
|
|
1650
|
+
if (color == null ? void 0 : color.includes("-")) {
|
|
1651
|
+
let colorName = color.split("-")[1];
|
|
1652
|
+
color = vexutils.oldColorMap(colorName);
|
|
1653
|
+
}
|
|
1654
|
+
return [createVNode("div", {
|
|
1655
|
+
"class": "color-wrap",
|
|
1656
|
+
"style": "height: 100%; padding: 4px;"
|
|
1657
|
+
}, [createVNode("div", {
|
|
1658
|
+
"style": {
|
|
1659
|
+
background: color,
|
|
1660
|
+
height: "100%"
|
|
1661
|
+
}
|
|
1662
|
+
}, null)])];
|
|
1663
|
+
};
|
|
1664
|
+
const getDate = (row, item) => {
|
|
1665
|
+
let obj = row[item.columnName] || "";
|
|
1666
|
+
if (!vexutils.isEmpty(obj)) {
|
|
1667
|
+
if (vexutils.isObject(obj) && "tooltip" in obj) {
|
|
1668
|
+
return [createVNode(resolveComponent("n-tooltip"), null, {
|
|
1669
|
+
default: () => [{
|
|
1670
|
+
trigger: () => createVNode("span", null, [obj.value])
|
|
1671
|
+
}, createVNode("span", {
|
|
1672
|
+
"innerHTML": obj.tooltip
|
|
1673
|
+
}, null)]
|
|
1674
|
+
})];
|
|
1675
|
+
}
|
|
1676
|
+
}
|
|
1677
|
+
return [createVNode("span", {
|
|
1678
|
+
"innerHTML": obj
|
|
1679
|
+
}, null)];
|
|
1680
|
+
};
|
|
1681
|
+
const getPercentage = (row, item) => {
|
|
1682
|
+
let value = row[item.columnName];
|
|
1683
|
+
if (!value && value !== 0)
|
|
1684
|
+
return;
|
|
1685
|
+
let percentValue = value;
|
|
1686
|
+
let SPANTAG_REGEXP = /<\/?span.*?>/g;
|
|
1687
|
+
if (SPANTAG_REGEXP.test(value)) {
|
|
1688
|
+
let d = document.createElement("span");
|
|
1689
|
+
d.innerHTML = value;
|
|
1690
|
+
value = d.textContent;
|
|
1691
|
+
percentValue = value;
|
|
1692
|
+
}
|
|
1693
|
+
if (value && vexutils.isString(value) && value.includes("%")) {
|
|
1694
|
+
percentValue = Number(value.replace("%", ""));
|
|
1695
|
+
}
|
|
1696
|
+
let strokeColor = "#52c41a";
|
|
1697
|
+
if (percentValue < 15) {
|
|
1698
|
+
strokeColor = "#ff5500";
|
|
1699
|
+
} else if (percentValue < 50) {
|
|
1700
|
+
strokeColor = "#ff8b01";
|
|
1701
|
+
} else if (percentValue < 90) {
|
|
1702
|
+
strokeColor = "#1890ff";
|
|
1703
|
+
}
|
|
1704
|
+
if (percentValue > 100) {
|
|
1705
|
+
percentValue = 100;
|
|
1706
|
+
} else if (percentValue < 0) {
|
|
1707
|
+
percentValue = 0;
|
|
1708
|
+
}
|
|
1709
|
+
return [createVNode("div", {
|
|
1710
|
+
"class": "percent-wrap"
|
|
1711
|
+
}, [createVNode("span", {
|
|
1712
|
+
"class": "percent-value"
|
|
1713
|
+
}, [percentValue, createTextVNode("%")]), createVNode(NProgress, {
|
|
1714
|
+
"percentage": percentValue,
|
|
1715
|
+
"showIndicator": false,
|
|
1716
|
+
"color": strokeColor
|
|
1717
|
+
}, null)])];
|
|
1718
|
+
};
|
|
1719
|
+
const getvideoList = (row, item) => {
|
|
1720
|
+
let res = row[item.columnName];
|
|
1721
|
+
if (Array.isArray(res)) {
|
|
1722
|
+
res = JSON.stringify(res);
|
|
1723
|
+
}
|
|
1724
|
+
return null;
|
|
1725
|
+
};
|
|
1726
|
+
const getOrCode = (row, item, type) => {
|
|
1727
|
+
let src = qr;
|
|
1728
|
+
return [createVNode("span", {
|
|
1729
|
+
"class": "bigTable-qr-span",
|
|
1730
|
+
"onClick": (e) => qrCodeEvent(e, row, item)
|
|
1731
|
+
}, [createVNode("img", {
|
|
1732
|
+
"class": "bigTable-qr-img",
|
|
1733
|
+
"src": src
|
|
1734
|
+
}, null), createVNode("span", null, [createVNode(SvgIcon, {
|
|
1735
|
+
"iconClass": "fangda"
|
|
1736
|
+
}, null)])])];
|
|
1737
|
+
};
|
|
1738
|
+
const qrCodeEvent = (e, row, item) => {
|
|
1739
|
+
e.preventDefault();
|
|
1740
|
+
e.stopPropagation();
|
|
1741
|
+
let data = handleQrCodeContent(row, item);
|
|
1742
|
+
emit("qrCodeEvent", data);
|
|
1743
|
+
};
|
|
1744
|
+
const generateInlineBtnList = (row, index) => {
|
|
1745
|
+
if (props.isNestTable)
|
|
1746
|
+
return;
|
|
1747
|
+
let inlineEditBtnList = [];
|
|
1748
|
+
inlineEditBtnList.push(...getInlineEditBtn(row, "tileBtnList"));
|
|
1749
|
+
inlineEditBtnList.push(...getInlineEditBtn(row, "foldBtnList"));
|
|
1750
|
+
if (!(inlineEditBtnList == null ? void 0 : inlineEditBtnList.length))
|
|
1751
|
+
return;
|
|
1752
|
+
return [createVNode("span", null, [createVNode(NButton, {
|
|
1753
|
+
"style": {
|
|
1754
|
+
display: row.__isInlineEditing ? "inline-block" : "none"
|
|
1755
|
+
},
|
|
1756
|
+
"onClick": (e) => {
|
|
1757
|
+
e.stopPropagation();
|
|
1758
|
+
emit("SET_SAVE_ROW_STATUS", true);
|
|
1759
|
+
},
|
|
1760
|
+
"class": "btn-custom-class row-btn",
|
|
1761
|
+
"size": "small",
|
|
1762
|
+
"text": true
|
|
1763
|
+
}, {
|
|
1764
|
+
default: () => "\u4FDD\u5B58"
|
|
1765
|
+
}), createVNode(NButton, {
|
|
1766
|
+
"style": {
|
|
1767
|
+
display: row.__isInlineEditing ? "inline-block" : "none"
|
|
1768
|
+
},
|
|
1769
|
+
"onClick": (e) => {
|
|
1770
|
+
e.stopPropagation();
|
|
1771
|
+
emit("SET_CANCEL_ROW_STATUS", true);
|
|
1772
|
+
},
|
|
1773
|
+
"class": "btn-custom-class row-btn",
|
|
1774
|
+
"size": "small",
|
|
1775
|
+
"text": true
|
|
1776
|
+
}, {
|
|
1777
|
+
default: () => "\u53D6\u6D88"
|
|
1778
|
+
})])];
|
|
1779
|
+
};
|
|
1780
|
+
const getTileBtnList = (row, index) => {
|
|
1781
|
+
var _a;
|
|
1782
|
+
return [((_a = row.tileBtnList) == null ? void 0 : _a.length) && row.tileBtnList.map((btn, j) => {
|
|
1783
|
+
return btn.isShow == "1" && btn.type != "LINK" && createVNode(NButton, {
|
|
1784
|
+
"key": btn.sid,
|
|
1785
|
+
"onClick": (e) => clickBtn(row, btn, index, e),
|
|
1786
|
+
"class": "btn-custom-class row-btn",
|
|
1787
|
+
"style": {
|
|
1788
|
+
...getBtnStyle(btn),
|
|
1789
|
+
...{
|
|
1790
|
+
display: !row.__isInlineEditing ? "inline-block" : "none"
|
|
1791
|
+
}
|
|
1792
|
+
},
|
|
1793
|
+
"disabled": row.__isDisableInlineEdit,
|
|
1794
|
+
"ghost": btn.showStyle == "white_bg",
|
|
1795
|
+
"size": "small"
|
|
1796
|
+
}, {
|
|
1797
|
+
default: () => [getBtnIcon(btn), btn.showStyle === "only_icon" ? "" : handleName(btn)]
|
|
1798
|
+
});
|
|
1799
|
+
}) || ""];
|
|
1800
|
+
};
|
|
1801
|
+
const clickBtn = (row, btn, index, e, j) => {
|
|
1802
|
+
e.preventDefault();
|
|
1803
|
+
e.stopPropagation();
|
|
1804
|
+
recordClickBtnInfo(row, index);
|
|
1805
|
+
emit("setNestTableClick", props.isNestTable);
|
|
1806
|
+
emit("setCurRowIndex", index);
|
|
1807
|
+
emit("clickBtn", row, btn, row[handlePrimaryKey.value], index);
|
|
1808
|
+
};
|
|
1809
|
+
const getBtnIcon = (btn, mr = "8px") => {
|
|
1810
|
+
let icon;
|
|
1811
|
+
if (btn.icon) {
|
|
1812
|
+
if (state.btnIcons[btn.icon]) {
|
|
1813
|
+
icon = createVNode(resolveComponent("a-icon"), {
|
|
1814
|
+
"type": state.btnIcons[btn.icon]
|
|
1815
|
+
}, null);
|
|
1816
|
+
} else {
|
|
1817
|
+
icon = createVNode(NTooltip, null, {
|
|
1818
|
+
trigger: () => createVNode(SvgIcon, {
|
|
1819
|
+
"iconClass": btn.icon,
|
|
1820
|
+
"style": {
|
|
1821
|
+
marginRight: mr
|
|
1822
|
+
}
|
|
1823
|
+
}, null),
|
|
1824
|
+
default: () => handleName(btn)
|
|
1825
|
+
});
|
|
1826
|
+
}
|
|
1827
|
+
} else if (btn.iconSetting) {
|
|
1828
|
+
icon = createVNode(SvgIcon, {
|
|
1829
|
+
"iconClass": JSON.parse(btn.iconSetting).icon,
|
|
1830
|
+
"style": {
|
|
1831
|
+
marginRight: mr
|
|
1832
|
+
}
|
|
1833
|
+
}, null);
|
|
1834
|
+
}
|
|
1835
|
+
return [icon];
|
|
1836
|
+
};
|
|
1837
|
+
const getFoldBtnList = (row, index) => {
|
|
1838
|
+
var _a;
|
|
1839
|
+
const getOptions = () => {
|
|
1840
|
+
return row.foldBtnList.map((b, j) => {
|
|
1841
|
+
return {
|
|
1842
|
+
label: `${handleName(b)}${getBtnIcon(b, "0")}`,
|
|
1843
|
+
key: b.sid,
|
|
1844
|
+
props: {
|
|
1845
|
+
onClick: (e) => {
|
|
1846
|
+
clickBtn(row, b, index, e.domEvent);
|
|
1847
|
+
}
|
|
1848
|
+
}
|
|
1849
|
+
};
|
|
1850
|
+
});
|
|
1851
|
+
};
|
|
1852
|
+
return [((_a = row.foldBtnList) == null ? void 0 : _a.length) && createVNode(NDropdown, {
|
|
1853
|
+
"style": {
|
|
1854
|
+
display: !row.__isInlineEditing ? "inline-block" : "none"
|
|
1855
|
+
},
|
|
1856
|
+
"disabled": props.isInlineOperating,
|
|
1857
|
+
"options": getOptions()
|
|
1858
|
+
}, {
|
|
1859
|
+
default: () => [createVNode(NButton, {
|
|
1860
|
+
"size": "small",
|
|
1861
|
+
"style": "margin-left: 8px"
|
|
1862
|
+
}, {
|
|
1863
|
+
default: () => "\u66F4\u591A ..."
|
|
1864
|
+
})]
|
|
1865
|
+
}) || ""];
|
|
1866
|
+
};
|
|
1867
|
+
const switchBtnOnChange = (e, r, i, index) => {
|
|
1868
|
+
emit("switchBtnOnChange", e, r, i, index);
|
|
1869
|
+
};
|
|
1870
|
+
const getBtnLinkSwitch = (row, item, disabled, index) => {
|
|
1871
|
+
let cur = state.isTree !== 0 ? row : props.oldtableData[index];
|
|
1872
|
+
let key = cur[item.columnName];
|
|
1873
|
+
if (typeof key === "string") {
|
|
1874
|
+
if (key && key.startsWith("###{")) {
|
|
1875
|
+
let temp = JSON.parse(key.replace("###", ""));
|
|
1876
|
+
key = temp.tooltip || temp.value;
|
|
1877
|
+
}
|
|
1878
|
+
}
|
|
1879
|
+
return [createVNode(NSwitch, {
|
|
1880
|
+
"value": key == item.btnLinkSwitchDefVal,
|
|
1881
|
+
"disabled": disabled,
|
|
1882
|
+
"onUpdateValue": (e) => switchBtnOnChange(e, row, item, index)
|
|
1883
|
+
}, null)];
|
|
1884
|
+
};
|
|
1885
|
+
const getField = (row, item, index, isLink2) => {
|
|
1886
|
+
const html = formatFieldText(row, item, props.columnConfig.fieldList, props.fieldListOriginal);
|
|
1887
|
+
const content = [isLink2 && html ? createVNode("a", {
|
|
1888
|
+
"onClick": (e) => linkDetail(row, item, index, e),
|
|
1889
|
+
"innerHTML": html
|
|
1890
|
+
}, null) : createVNode("span", {
|
|
1891
|
+
"class": "domPropsInnerHTML-span",
|
|
1892
|
+
"innerHTML": html
|
|
1893
|
+
}, null)];
|
|
1894
|
+
if (isCopy(item, row)) {
|
|
1895
|
+
return [createVNode(NPopover, {
|
|
1896
|
+
"placement": "right",
|
|
1897
|
+
"trigger": "hover",
|
|
1898
|
+
"arrowPointToCenter": true
|
|
1899
|
+
}, {
|
|
1900
|
+
default: () => [{
|
|
1901
|
+
trigger: () => content
|
|
1902
|
+
}, createVNode(NIcon, {
|
|
1903
|
+
"component": CopyOutline,
|
|
1904
|
+
"onClick": (e) => hanldeCopyContent(e, row[item.columnName])
|
|
1905
|
+
}, null)]
|
|
1906
|
+
})];
|
|
1907
|
+
} else {
|
|
1908
|
+
return [content];
|
|
1909
|
+
}
|
|
1910
|
+
};
|
|
1911
|
+
const linkDetail = (row, col, index, e) => {
|
|
1912
|
+
if (props.isInlineOperating)
|
|
1913
|
+
return false;
|
|
1914
|
+
let vxeTable = xGrid.value;
|
|
1915
|
+
e.preventDefault();
|
|
1916
|
+
let isCheckedByCheckboxRow = vxeTable.isCheckedByCheckboxRow(row);
|
|
1917
|
+
if (isCheckedByCheckboxRow) {
|
|
1918
|
+
e.stopPropagation();
|
|
1919
|
+
}
|
|
1920
|
+
vxeTable.setCurrentRow(row);
|
|
1921
|
+
emit("setNestTableClick", props.isNestTable);
|
|
1922
|
+
emit("setCurRowIndex", index);
|
|
1923
|
+
emit("linkDetail", row, col, row[handlePrimaryKey.value], null, false, index);
|
|
1924
|
+
};
|
|
1925
|
+
const hanldeCopyContent = (e, value) => {
|
|
1926
|
+
e.preventDefault();
|
|
1927
|
+
e.stopPropagation();
|
|
1928
|
+
emit("hanldeCopyContent", e, value);
|
|
1929
|
+
};
|
|
1930
|
+
const setAllCheckedRows = (rows) => {
|
|
1931
|
+
if (props.isNestTable)
|
|
1932
|
+
return;
|
|
1933
|
+
if (rows && rows.length) {
|
|
1934
|
+
const copy = vexutils.handleBigArrayCopy(rows);
|
|
1935
|
+
state.checkedRows = Object.freeze(copy);
|
|
1936
|
+
let table = xGrid.value;
|
|
1937
|
+
table.setAllCheckboxRow(true);
|
|
1938
|
+
}
|
|
1939
|
+
};
|
|
1940
|
+
const setTalbeScrollTo = () => {
|
|
1941
|
+
let table = xGrid.value;
|
|
1942
|
+
if (!table)
|
|
1943
|
+
return;
|
|
1944
|
+
table.scrollTo(table.getScroll().scrollLeft, 0);
|
|
1945
|
+
};
|
|
1946
|
+
const submitInlineForm = () => {
|
|
1947
|
+
let error = props.inlineError;
|
|
1948
|
+
if (error) {
|
|
1949
|
+
props.resetEditRowStatus();
|
|
1950
|
+
emit("triggerSpinning", false);
|
|
1951
|
+
return false;
|
|
1952
|
+
}
|
|
1953
|
+
let {
|
|
1954
|
+
formId
|
|
1955
|
+
} = props.listFormUnionSetting;
|
|
1956
|
+
let {
|
|
1957
|
+
id
|
|
1958
|
+
} = props.inlineOriginalTableRow;
|
|
1959
|
+
if (!formId) {
|
|
1960
|
+
console.log("\u7F3A\u5C11formId");
|
|
1961
|
+
emit("triggerSpinning", false);
|
|
1962
|
+
return;
|
|
1963
|
+
}
|
|
1964
|
+
if (state.isSaveForm)
|
|
1965
|
+
return false;
|
|
1966
|
+
state.isSaveForm = true;
|
|
1967
|
+
let params = Object.assign({}, props.inlineFormData, {
|
|
1968
|
+
formId,
|
|
1969
|
+
id,
|
|
1970
|
+
editMode: "row"
|
|
1971
|
+
});
|
|
1972
|
+
params = JSON.parse(JSON.stringify(params));
|
|
1973
|
+
let noChangePrimaryKey = params[handleRowId.value] === addInlineEditPrimaryKey;
|
|
1974
|
+
if (props.isInlineAdding && noChangePrimaryKey) {
|
|
1975
|
+
delete params[handleRowId.value];
|
|
1976
|
+
}
|
|
1977
|
+
props.submitForm(params).then(async ({
|
|
1978
|
+
data
|
|
1979
|
+
}) => {
|
|
1980
|
+
emit("triggerSpinning", false);
|
|
1981
|
+
if (data.result !== "SUCCESS") {
|
|
1982
|
+
state.isSaveForm = false;
|
|
1983
|
+
$message.error(data.resultMsg);
|
|
1984
|
+
props.resetEditRowStatus();
|
|
1985
|
+
return false;
|
|
1986
|
+
}
|
|
1987
|
+
await props.resetInlineEdit();
|
|
1988
|
+
resetOperationRowStatus();
|
|
1989
|
+
emit("pubTableReload");
|
|
1990
|
+
}).finally(() => {
|
|
1991
|
+
state.isSaveForm = false;
|
|
1992
|
+
emit("triggerSpinning", false);
|
|
1993
|
+
props.resetEditRowStatus();
|
|
1994
|
+
});
|
|
1995
|
+
};
|
|
1996
|
+
const handleClickAddBtnByInline = async () => {
|
|
1997
|
+
if (!checkListFormUnionSettingParamsList()) {
|
|
1998
|
+
handleClickCancelBtnByInline();
|
|
1999
|
+
return false;
|
|
2000
|
+
}
|
|
2001
|
+
await props.resetInlineEdit();
|
|
2002
|
+
emit("handleClickBtnByInline", {
|
|
2003
|
+
type: "ADD",
|
|
2004
|
+
listFormUnionSetting: props.listFormUnionSetting,
|
|
2005
|
+
inlineEditFormConfig: props.inlineEditFormConfig
|
|
2006
|
+
});
|
|
2007
|
+
addInlineEditPrimaryKey = Date.now();
|
|
2008
|
+
let formData = {
|
|
2009
|
+
[handleRowId.value]: addInlineEditPrimaryKey,
|
|
2010
|
+
__isInsertRow: true
|
|
2011
|
+
};
|
|
2012
|
+
let {
|
|
2013
|
+
paramsList
|
|
2014
|
+
} = props.listFormUnionSetting;
|
|
2015
|
+
paramsList.forEach((item) => {
|
|
2016
|
+
formData[item.tableField] = void 0;
|
|
2017
|
+
});
|
|
2018
|
+
let vxeTable = xGrid.value;
|
|
2019
|
+
await vxeTable.insert(formData);
|
|
2020
|
+
await vxeTable.loadData([formData]);
|
|
2021
|
+
setAllRowInlineStatus(true);
|
|
2022
|
+
setRowStatus(vxeTable.$el, 0, "66");
|
|
2023
|
+
};
|
|
2024
|
+
const handleClickSaveBtnByInline = () => {
|
|
2025
|
+
if (props.spinning)
|
|
2026
|
+
return false;
|
|
2027
|
+
emit("handleClickBtnByInline", {
|
|
2028
|
+
type: "SAVE"
|
|
2029
|
+
});
|
|
2030
|
+
let formDom = document.querySelectorAll(".js-inlineEditForm");
|
|
2031
|
+
let sliceLen = handleEditFormLength();
|
|
2032
|
+
formDom = [...formDom].slice(0, sliceLen);
|
|
2033
|
+
formDom.forEach((item) => {
|
|
2034
|
+
item.__vue__.handleSubmitForm();
|
|
2035
|
+
});
|
|
2036
|
+
};
|
|
2037
|
+
const removeInlineAddRow = () => {
|
|
2038
|
+
if (!props.isInlineAdding)
|
|
2039
|
+
return false;
|
|
2040
|
+
const vxeTable = xGrid.value;
|
|
2041
|
+
let {
|
|
2042
|
+
tableData
|
|
2043
|
+
} = vxeTable.getTableData();
|
|
2044
|
+
vxeTable.remove(tableData[0]);
|
|
2045
|
+
};
|
|
2046
|
+
watch(() => props.columnConfig, (config) => {
|
|
2047
|
+
nextTick(() => {
|
|
2048
|
+
if (!config || !Object.keys(config).length)
|
|
2049
|
+
return;
|
|
2050
|
+
loadColumn(config);
|
|
2051
|
+
});
|
|
2052
|
+
}, {
|
|
2053
|
+
immediate: true
|
|
2054
|
+
});
|
|
2055
|
+
watch(() => props.data, (value) => {
|
|
2056
|
+
nextTick(() => {
|
|
2057
|
+
loadData(value);
|
|
2058
|
+
});
|
|
2059
|
+
}, {
|
|
2060
|
+
immediate: true,
|
|
2061
|
+
deep: true
|
|
2062
|
+
});
|
|
2063
|
+
watch(() => currentCheckedKeys, (val) => {
|
|
2064
|
+
setVisibleCheckAllWrap(state, props, currentCheckedKeys.value);
|
|
2065
|
+
});
|
|
2066
|
+
watch(() => props.quickSearchConfig, (val) => {
|
|
2067
|
+
setFilterStatus(state, props);
|
|
2068
|
+
}, {
|
|
2069
|
+
deep: true
|
|
2070
|
+
});
|
|
2071
|
+
watch(() => props.tableDataCache, (val) => {
|
|
2072
|
+
setAllCheckedRows(val);
|
|
2073
|
+
}, {
|
|
2074
|
+
deep: true
|
|
2075
|
+
});
|
|
2076
|
+
watch(() => props.pageVO.pageSize, (val) => {
|
|
2077
|
+
if (props.isNestTable)
|
|
2078
|
+
return;
|
|
2079
|
+
setVisibleCheckAllWrap(state, props, currentCheckedKeys.value);
|
|
2080
|
+
resetTableInlineEditStatus();
|
|
2081
|
+
});
|
|
2082
|
+
watch(() => props.pageVO.pageIndex, (val) => {
|
|
2083
|
+
if (props.isNestTable)
|
|
2084
|
+
return;
|
|
2085
|
+
setTalbeScrollTo();
|
|
2086
|
+
resetTableInlineEditStatus();
|
|
2087
|
+
});
|
|
2088
|
+
watch(() => props.styleSetting.tableHeight, (val) => {
|
|
2089
|
+
if (props.isNestTable)
|
|
2090
|
+
return;
|
|
2091
|
+
if (Object.keys(props.columnConfig).length > 0) {
|
|
2092
|
+
loadColumn(props.columnConfig);
|
|
2093
|
+
loadData(props.data);
|
|
2094
|
+
setTalbeScrollTo();
|
|
2095
|
+
}
|
|
2096
|
+
});
|
|
2097
|
+
watch(() => props.sysImageSize, (val) => {
|
|
2098
|
+
var _a;
|
|
2099
|
+
const v = ((_a = props.styleSetting) == null ? void 0 : _a.tableHeight) === "table-simple" ? "26" : "22";
|
|
2100
|
+
nextTick(() => {
|
|
2101
|
+
handleTableImageSize(val, "LIST_FIELD_SMALL", v + "px");
|
|
2102
|
+
});
|
|
2103
|
+
}, {
|
|
2104
|
+
deep: true,
|
|
2105
|
+
immediate: true
|
|
2106
|
+
});
|
|
2107
|
+
watch(() => props.inlineEditFormSubmitDone, (val) => {
|
|
2108
|
+
if (!val || props.isNestTable)
|
|
2109
|
+
return;
|
|
2110
|
+
if (state.isTree != 0 || !props.isMatchComponent)
|
|
2111
|
+
return false;
|
|
2112
|
+
if (!checkOperateCurrentTable())
|
|
2113
|
+
return false;
|
|
2114
|
+
submitInlineForm();
|
|
2115
|
+
});
|
|
2116
|
+
watch(() => props.isInlineEditing, (val) => {
|
|
2117
|
+
if (!val || props.isNestTable)
|
|
2118
|
+
return;
|
|
2119
|
+
if (state.isTree != 0 || !props.isMatchComponent)
|
|
2120
|
+
return false;
|
|
2121
|
+
if (!checkOperateCurrentTable())
|
|
2122
|
+
return false;
|
|
2123
|
+
submitInlineForm();
|
|
2124
|
+
});
|
|
2125
|
+
watch(() => props.isInlineAdding, (val) => {
|
|
2126
|
+
if (!val || props.isNestTable)
|
|
2127
|
+
return false;
|
|
2128
|
+
if (state.isTree != 0 || !props.isMatchComponent)
|
|
2129
|
+
return false;
|
|
2130
|
+
if (!checkOperateCurrentTable()) {
|
|
2131
|
+
resetOperationRowStatus();
|
|
2132
|
+
return false;
|
|
2133
|
+
}
|
|
2134
|
+
hideSelectCloumns();
|
|
2135
|
+
handleClickAddBtnByInline();
|
|
2136
|
+
});
|
|
2137
|
+
watch(() => props.isInlineSave, (val) => {
|
|
2138
|
+
if (!val || props.isNestTable)
|
|
2139
|
+
return false;
|
|
2140
|
+
if (state.isTree != 0 || !props.isMatchComponent)
|
|
2141
|
+
return false;
|
|
2142
|
+
if (!checkOperateCurrentTable())
|
|
2143
|
+
return false;
|
|
2144
|
+
handleClickSaveBtnByInline();
|
|
2145
|
+
});
|
|
2146
|
+
watch(() => props.isInlineCancel, (val) => {
|
|
2147
|
+
if (!val || props.isNestTable)
|
|
2148
|
+
return false;
|
|
2149
|
+
if (state.isTree != 0 || !props.isMatchComponent)
|
|
2150
|
+
return false;
|
|
2151
|
+
if (!checkOperateCurrentTable())
|
|
2152
|
+
return false;
|
|
2153
|
+
removeInlineAddRow();
|
|
2154
|
+
handleClickCancelBtnByInline();
|
|
2155
|
+
});
|
|
2156
|
+
watch(() => props.tableRefreshCache, (val, oldVal) => {
|
|
2157
|
+
var _a, _b;
|
|
2158
|
+
if (props.isNestTable)
|
|
2159
|
+
return;
|
|
2160
|
+
const {
|
|
2161
|
+
orgId
|
|
2162
|
+
} = ((_b = (_a = props == null ? void 0 : props.userInfo) == null ? void 0 : _a.map) == null ? void 0 : _b.sysParams) || {};
|
|
2163
|
+
if (val != oldVal && props.tableParams && val[props.tableParams.tableId] && orgId == val[props.tableParams.tableId]) {
|
|
2164
|
+
state.hasRefresh = true;
|
|
2165
|
+
}
|
|
2166
|
+
}, {
|
|
2167
|
+
immediate: true,
|
|
2168
|
+
deep: true
|
|
2169
|
+
});
|
|
2170
|
+
watch(() => props.tableParams.tableId, (val) => {
|
|
2171
|
+
nextTick(() => {
|
|
2172
|
+
if (val && props.tableRefreshCache[val]) {
|
|
2173
|
+
state.hasRefresh = true;
|
|
2174
|
+
}
|
|
2175
|
+
});
|
|
2176
|
+
});
|
|
2177
|
+
expose({
|
|
2178
|
+
formatData,
|
|
2179
|
+
xGrid
|
|
2180
|
+
});
|
|
2181
|
+
return (_ctx, _cache) => {
|
|
2182
|
+
return openBlock(), createElementBlock("div", {
|
|
2183
|
+
class: normalizeClass(["big-table custom-big-table", {
|
|
2184
|
+
mt: unref(state).visibleCheckAllWrap || unref(state).visibleTreeCheck || unref(state).hasRefresh,
|
|
2185
|
+
"expand-padding": !props.isNestTable
|
|
2186
|
+
}]),
|
|
2187
|
+
style: normalizeStyle({
|
|
2188
|
+
height: unref(state).tableHeight
|
|
2189
|
+
})
|
|
2190
|
+
}, [unref(state).hasRefresh && !props.isNestTable ? (openBlock(), createElementBlock("div", _hoisted_1, [createElementVNode("p", {
|
|
2191
|
+
class: "check-wrap-title"
|
|
2192
|
+
}, [_hoisted_2, createElementVNode("span", {
|
|
2193
|
+
class: "check-wrap-btn",
|
|
2194
|
+
onClick: refreshTable
|
|
2195
|
+
}, "\u70B9\u51FB\u67E5\u770B")])])) : createCommentVNode("v-if", true), createCommentVNode(" \u5168\u9009 \u9009\u62E9\u6846 "), withDirectives(createElementVNode("div", _hoisted_3, [createElementVNode("p", _hoisted_4, [createElementVNode("span", null, "\u5DF2\u52FE\u9009\u6570\u636E\u5171" + toDisplayString(unref(allSelectedLength)) + "\u6761", 1), withDirectives(createElementVNode("span", null, " \uFF08\u5F53\u524D\u9875" + toDisplayString(unref(state).currentPageSelectedLength) + "\u6761\uFF09 ", 513), [[vShow, unref(state).visibleCheckAllWrapMore]])]), unref(state).visibleCheckAllWrapMore && !props.asyncCount ? (openBlock(), createElementBlock(Fragment, {
|
|
2196
|
+
key: 0
|
|
2197
|
+
}, [!unref(visibleCancelCheckAllBtn) ? (openBlock(), createElementBlock("p", {
|
|
2198
|
+
key: 0,
|
|
2199
|
+
class: "check-wrap-btn",
|
|
2200
|
+
onClick: handleCheckAll
|
|
2201
|
+
}, [_ctx.pageVO.total > _ctx.maxCheckSize ? (openBlock(), createElementBlock("span", _hoisted_5, [createCommentVNode(" {{ `\u6700\u5927\u52FE\u9009\u201C${tableName}\u201D ${maxCheckSize}\u6761\u6570\u636E` }} "), createTextVNode(toDisplayString(`\u52FE\u9009\u5168\u90E8\u9875 ${_ctx.maxCheckSize}\u6761\u6570\u636E`), 1)])) : (openBlock(), createElementBlock("span", _hoisted_6, [createCommentVNode(' {{ $t("1.9.598", { name: tableName, total }) }} '), createTextVNode(toDisplayString(`\u52FE\u9009\u5168\u90E8\u9875 ${_ctx.pageVO.total}\u6761\u6570\u636E`), 1)]))])) : (openBlock(), createElementBlock("p", {
|
|
2202
|
+
key: 1,
|
|
2203
|
+
class: "check-wrap-btn",
|
|
2204
|
+
onClick: handleCancelAllCheck
|
|
2205
|
+
}, "\u53D6\u6D88\u5168\u90E8\u52FE\u9009"))], 2112)) : createCommentVNode("v-if", true)], 512), [[vShow, unref(state).visibleCheckAllWrap && !props.isInlineOperating && !props.isNestTable]]), createCommentVNode(" \u6811\u72B6\u8868\u683C\u5DF2\u9009 "), withDirectives(createElementVNode("div", _hoisted_7, [createElementVNode("p", _hoisted_8, [createElementVNode("span", null, "\u5DF2\u52FE\u9009\u6570\u636E\u5171" + toDisplayString(unref(state).treeTableLength) + "\u6761", 1)])], 512), [[vShow, unref(state).visibleTreeCheck && !props.isInlineOperating && !props.isNestTable]]), createVNode(unref(CGrid), mergeProps({
|
|
2206
|
+
ref_key: "xGrid",
|
|
2207
|
+
ref: xGrid,
|
|
2208
|
+
border: "",
|
|
2209
|
+
"show-overflow": "",
|
|
2210
|
+
"show-header-overflow": "",
|
|
2211
|
+
"highlight-hover-row": "",
|
|
2212
|
+
"highlight-current-row": "",
|
|
2213
|
+
"show-footer-overflow": "title",
|
|
2214
|
+
"keep-source": "",
|
|
2215
|
+
resizable: "",
|
|
2216
|
+
"auto-resize": ""
|
|
2217
|
+
}, props.height ? {
|
|
2218
|
+
height: "auto"
|
|
2219
|
+
} : {}, {
|
|
2220
|
+
"seq-config": unref(handleSeqConfig),
|
|
2221
|
+
"tree-config": unref(treeConfig),
|
|
2222
|
+
"row-id": unref(handleRowId),
|
|
2223
|
+
"row-class-name": getRowClassName,
|
|
2224
|
+
"row-config": unref(state).rowConfig,
|
|
2225
|
+
"show-footer": _ctx.showFooter && !props.isInlineOperating,
|
|
2226
|
+
"footer-method": footerMethod,
|
|
2227
|
+
"sort-config": {
|
|
2228
|
+
trigger: "cell",
|
|
2229
|
+
remote: true
|
|
2230
|
+
},
|
|
2231
|
+
"span-method": colspanMethod,
|
|
2232
|
+
"footer-span-method": footerRowspanMethod,
|
|
2233
|
+
"tooltip-config": {
|
|
2234
|
+
enterable: false
|
|
2235
|
+
},
|
|
2236
|
+
"checkbox-config": {
|
|
2237
|
+
checkField: "checked",
|
|
2238
|
+
labelField: "checked",
|
|
2239
|
+
checkMethod: unref(checkMethod),
|
|
2240
|
+
trigger: "cell",
|
|
2241
|
+
reserve: true,
|
|
2242
|
+
highlight: true
|
|
2243
|
+
},
|
|
2244
|
+
"radio-config": {
|
|
2245
|
+
checkField: "checked",
|
|
2246
|
+
trigger: "cell",
|
|
2247
|
+
reserve: true,
|
|
2248
|
+
highlight: true
|
|
2249
|
+
},
|
|
2250
|
+
"scroll-x": {
|
|
2251
|
+
enabled: false
|
|
2252
|
+
},
|
|
2253
|
+
"scroll-y": {
|
|
2254
|
+
gt: 50
|
|
2255
|
+
},
|
|
2256
|
+
"row-style": unref(getRowStyle),
|
|
2257
|
+
"edit-config": unref(state).editConfig,
|
|
2258
|
+
"expand-config": {
|
|
2259
|
+
lazy: true,
|
|
2260
|
+
accordion: _ctx.columnConfig && _ctx.columnConfig.accordion,
|
|
2261
|
+
loadMethod: unref(loadExpandMethod),
|
|
2262
|
+
toggleMethod: unref(toggleExpandMethod),
|
|
2263
|
+
iconOpen: "iconfont icon-a-xitongtubiaozhediejian",
|
|
2264
|
+
iconClose: "iconfont icon-a-xitongtubiaotianjia"
|
|
2265
|
+
},
|
|
2266
|
+
"keyboard-config": _ctx.columnConfig.keyboardConfig || {},
|
|
2267
|
+
"edit-rules": _ctx.columnConfig.editRules || {},
|
|
2268
|
+
onCellDblclick: rowdblclick,
|
|
2269
|
+
onCellClick: handlerClickRow,
|
|
2270
|
+
onCheckboxChange: selectionChange,
|
|
2271
|
+
onCheckboxAll: selectionChangeAll,
|
|
2272
|
+
onRadioChange: radioOnChange,
|
|
2273
|
+
onSortChange: sortChange,
|
|
2274
|
+
onScroll: unref(scroll),
|
|
2275
|
+
onCellMouseenter: handleCellMouseenter,
|
|
2276
|
+
onKeydown: unref(keyDown)
|
|
2277
|
+
}), {
|
|
2278
|
+
empty: withCtx(() => [unref(state).isShowEmpty ? (openBlock(), createElementBlock("div", _hoisted_9, [createVNode(script$1, {
|
|
2279
|
+
"no-data-img": props.emptyItems.noDataImg,
|
|
2280
|
+
"no-data-tip": props.emptyItems.noDataTip,
|
|
2281
|
+
"show-img": !props.isNestTable
|
|
2282
|
+
}, null, 8, ["no-data-img", "no-data-tip", "show-img"])])) : createCommentVNode("v-if", true)]),
|
|
2283
|
+
tooltip_checkbox: withCtx(({
|
|
2284
|
+
row,
|
|
2285
|
+
checked
|
|
2286
|
+
}) => [row.forbiddenBatchSelect ? (openBlock(), createBlock(unref(NTooltip), {
|
|
2287
|
+
key: 0,
|
|
2288
|
+
trigger: "hover",
|
|
2289
|
+
placement: "right"
|
|
2290
|
+
}, {
|
|
2291
|
+
trigger: withCtx(() => [_hoisted_10]),
|
|
2292
|
+
default: withCtx(() => [createTextVNode(" " + toDisplayString(row.forbiddenBatchSelectReason), 1)]),
|
|
2293
|
+
_: 2
|
|
2294
|
+
}, 1024)) : (openBlock(), createBlock(unref(NCheckbox), {
|
|
2295
|
+
key: 1,
|
|
2296
|
+
class: "tooltip-checkbox-item",
|
|
2297
|
+
checked
|
|
2298
|
+
}, null, 8, ["checked"]))]),
|
|
2299
|
+
tooltip_footer: withCtx(({
|
|
2300
|
+
column
|
|
2301
|
+
}) => [createCommentVNode(" \u5206\u7EC4\u7EDF\u8BA1 "), _ctx.groupCountFields && _ctx.groupCountFields.length ? (openBlock(), createElementBlock("span", {
|
|
2302
|
+
key: 0,
|
|
2303
|
+
innerHTML: unref(state).groupText
|
|
2304
|
+
}, null, 8, _hoisted_11)) : (openBlock(), createElementBlock(Fragment, {
|
|
2305
|
+
key: 1
|
|
2306
|
+
}, [createCommentVNode(" \u4E00\u822C\u7EDF\u8BA1 "), createVNode(unref(NTooltip), {
|
|
2307
|
+
trigger: "hover"
|
|
2308
|
+
}, {
|
|
2309
|
+
trigger: withCtx(() => [createTextVNode(toDisplayString(getFooterTitle(column)), 1)]),
|
|
2310
|
+
default: withCtx(() => [createElementVNode("div", {
|
|
2311
|
+
innerHTML: getFooterTooltipTitle(column)
|
|
2312
|
+
}, null, 8, _hoisted_12)]),
|
|
2313
|
+
_: 2
|
|
2314
|
+
}, 1024)], 2112))]),
|
|
2315
|
+
nest_table_content: withCtx(({
|
|
2316
|
+
row,
|
|
2317
|
+
rowIndex,
|
|
2318
|
+
$rowIndex,
|
|
2319
|
+
column
|
|
2320
|
+
}) => [renderSlot(_ctx.$slots, "content", {
|
|
2321
|
+
data: {
|
|
2322
|
+
row,
|
|
2323
|
+
rowIndex,
|
|
2324
|
+
$rowIndex,
|
|
2325
|
+
column
|
|
2326
|
+
}
|
|
2327
|
+
})]),
|
|
2328
|
+
_: 3
|
|
2329
|
+
}, 16, ["seq-config", "tree-config", "row-id", "row-config", "show-footer", "checkbox-config", "row-style", "edit-config", "expand-config", "keyboard-config", "edit-rules", "onScroll", "onKeydown"]), createCommentVNode(" `${refreshRow}\u6761\u66F4\u65B0` "), withDirectives(createElementVNode("div", {
|
|
2330
|
+
class: "refresh",
|
|
2331
|
+
onClick: hanldeClickRefresh
|
|
2332
|
+
}, [createVNode(unref(NIcon), {
|
|
2333
|
+
size: "14",
|
|
2334
|
+
component: unref(SyncOutline)
|
|
2335
|
+
}, null, 8, ["component"]), createElementVNode("p", _hoisted_13, toDisplayString(_ctx.refreshRow) + "\u6761\u66F4\u65B0", 1)], 512), [[vShow, props.refreshRow > 0 && !props.isNestTable]])], 6);
|
|
2336
|
+
};
|
|
2337
|
+
}
|
|
2338
|
+
});
|
|
2339
|
+
|
|
2340
|
+
export { script as default };
|