vft 0.0.509 → 0.0.511
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +1 -1
- package/es/components/affix/affix.vue2.js +2 -2
- package/es/components/alert/alert.vue2.js +1 -1
- package/es/components/autocomplete/autocomplete.vue2.js +1 -1
- package/es/components/avatar/avatar.vue2.js +2 -2
- package/es/components/avatar-stack/avatar-stack.vue2.js +7 -7
- package/es/components/backtop/backtop.vue2.js +1 -1
- package/es/components/breadcrumb/breadcrumb-item.vue2.js +3 -3
- package/es/components/breadcrumb/breadcrumb.vue2.js +2 -2
- package/es/components/button/button-group.vue2.js +2 -2
- package/es/components/button/button.vue2.js +7 -7
- package/es/components/button/use-button.js +3 -3
- package/es/components/card/card.vue2.js +6 -6
- package/es/components/carousel/carousel-item.vue2.js +3 -3
- package/es/components/carousel/carousel.vue2.js +1 -1
- package/es/components/cascader/cascader.vue2.js +2 -2
- package/es/components/cascader-panel/index.vue2.js +1 -1
- package/es/components/cascader-panel/menu.vue2.js +6 -6
- package/es/components/cascader-panel/node.vue2.js +8 -8
- package/es/components/check-tag/check-tag.vue2.js +2 -2
- package/es/components/checkbox/checkbox-button.vue2.js +13 -13
- package/es/components/checkbox/checkbox-group.vue2.js +3 -3
- package/es/components/checkbox/checkbox.vue2.js +1 -1
- package/es/components/clamp/clamp.vue2.js +2 -2
- package/es/components/clamp-toggle/clamp-toggle.vue2.js +4 -4
- package/es/components/clamp-tooltip/clamp-tooltip.vue2.js +6 -6
- package/es/components/col/col.vue2.js +2 -2
- package/es/components/collapse/collapse-item.vue2.js +2 -2
- package/es/components/collapse/collapse.vue2.js +2 -2
- package/es/components/collapse-transition/collapse-transition.vue2.js +2 -2
- package/es/components/color-picker/color-picker.vue2.js +2 -2
- package/es/components/color-picker/components/alpha-slider.vue2.js +2 -2
- package/es/components/color-picker/components/hue-slider.vue.js +2 -2
- package/es/components/color-picker/components/predefine.vue.js +3 -3
- package/es/components/color-picker/components/sv-panel.vue.js +2 -2
- package/es/components/config-provider/config-provider.vue2.js +2 -2
- package/es/components/config-provider/hooks/use-global-config.js +3 -3
- package/es/components/container/aside.vue2.js +2 -2
- package/es/components/container/container.vue2.js +2 -2
- package/es/components/container/footer.vue2.js +2 -2
- package/es/components/container/header.vue2.js +2 -2
- package/es/components/container/main.vue2.js +2 -2
- package/es/components/context-menu/context-menu.vue2.js +1 -1
- package/es/components/countdown/countdown.vue2.js +2 -2
- package/es/components/date-picker/composables/use-basic-date-table.d.ts +1 -1
- package/es/components/date-picker/composables/use-basic-date-table.js +115 -115
- package/es/components/date-picker/composables/use-month-range-header.js +1 -1
- package/es/components/date-picker/composables/use-panel-date-range.js +1 -1
- package/es/components/date-picker/date-picker-com/basic-date-table.vue2.js +6 -6
- package/es/components/date-picker/date-picker-com/basic-month-table.vue2.js +5 -5
- package/es/components/date-picker/date-picker-com/basic-year-table.vue2.js +5 -5
- package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +12 -12
- package/es/components/date-picker/date-picker-com/panel-date-range.vue2.js +3 -3
- package/es/components/date-picker/date-picker-com/panel-month-range.vue2.js +12 -12
- package/es/components/date-picker/date-picker-com/panel-year-range.vue2.js +12 -12
- package/es/components/date-picker/props/basic-date-table.js +3 -3
- package/es/components/date-picker/props/basic-month-table.js +3 -3
- package/es/components/date-picker/props/basic-year-table.js +3 -3
- package/es/components/date-time-select/date-time-select.vue2.js +1 -1
- package/es/components/descriptions/description.vue2.js +1 -1
- package/es/components/descriptions/descriptions-row.vue2.js +10 -10
- package/es/components/dialog/dialog-content.vue2.js +3 -3
- package/es/components/dialog/dialog.vue2.js +5 -5
- package/es/components/divider/divider.vue2.js +5 -5
- package/es/components/drawer/drawer.vue2.js +4 -4
- package/es/components/dropdown/dropdown-item-impl.vue.d.ts +1 -1
- package/es/components/dropdown/dropdown-item-impl.vue2.js +3 -3
- package/es/components/dropdown/dropdown-item.vue.d.ts +1 -1
- package/es/components/dropdown/dropdown-item.vue2.js +2 -2
- package/es/components/dropdown/dropdown-menu.vue2.js +2 -2
- package/es/components/dropdown/dropdown.vue.d.ts +1 -1
- package/es/components/dropdown/dropdown.vue2.js +5 -5
- package/es/components/dropdown/index.d.ts +33 -33
- package/es/components/empty/empty.vue2.js +6 -6
- package/es/components/footer-layout/footer-layout.vue2.js +2 -2
- package/es/components/form/form-item.vue2.js +16 -16
- package/es/components/form/form.vue2.js +2 -2
- package/es/components/full-screen/full-screen.vue2.js +3 -3
- package/es/components/header-layout/header-layout.vue2.js +1 -1
- package/es/components/horizontal-menu/horizontal-menu.vue2.js +3 -3
- package/es/components/icon/icon.vue2.js +3 -3
- package/es/components/icon-text/icon-text.vue2.js +1 -1
- package/es/components/iframe-layout/iframe-layout.vue2.js +4 -4
- package/es/components/iframe-layout/iframe-page.vue2.js +2 -2
- package/es/components/image/image.vue2.js +2 -2
- package/es/components/image-viewer/image-viewer.vue2.js +7 -7
- package/es/components/index.d.ts +1 -0
- package/es/components/index.js +206 -203
- package/es/components/input/input.vue2.js +6 -6
- package/es/components/input-number/input-number.vue2.js +4 -4
- package/es/components/input-tag/input-tag.vue2.js +7 -7
- package/es/components/link/link.vue2.js +1 -1
- package/es/components/list-cell/list-cell.vue2.js +1 -1
- package/es/components/logo/logo.vue2.js +10 -10
- package/es/components/md-comment/md-comment.vue2.js +2 -2
- package/es/components/md-container/md-container.vue2.js +2 -2
- package/es/components/md-container/toc.js +1 -1
- package/es/components/menu/menu-collapse-transition.vue.js +2 -2
- package/es/components/menu/menu-item-group.vue2.js +7 -7
- package/es/components/menu/menu-item.vue2.js +1 -1
- package/es/components/message/message.vue2.js +3 -3
- package/es/components/message-box/index.d.ts +4 -0
- package/es/components/message-box/index.js +14 -0
- package/es/components/message-box/message-box.vue.d.ts +103 -0
- package/es/components/message-box/message-box.vue.js +4 -0
- package/es/components/message-box/message-box.vue2.js +358 -0
- package/es/components/message-box/method.d.ts +3 -0
- package/es/components/message-box/method.js +101 -0
- package/es/components/message-box/style/css.d.ts +2 -0
- package/es/components/message-box/style/css.js +3 -0
- package/es/components/message-box/style/index.d.ts +2 -0
- package/es/components/message-box/style/index.js +3 -0
- package/es/components/message-box/types.d.ts +202 -0
- package/es/components/message-box/types.js +1 -0
- package/es/components/modal/index.d.ts +1 -0
- package/es/components/modal/modal-footer-action.vue2.js +11 -11
- package/es/components/modal/modal.vue.d.ts +1 -0
- package/es/components/modal/modal.vue2.js +30 -28
- package/es/components/multiple-tabs/multiple-tabs.vue2.js +1 -1
- package/es/components/multiple-tabs/tab-content.vue2.js +2 -2
- package/es/components/multiple-tabs/use/use-tab-dropdown.js +1 -1
- package/es/components/notification/notification.vue2.js +1 -1
- package/es/components/overlay/overlay.vue2.js +1 -1
- package/es/components/page-wrapper/page-wrapper.vue2.js +2 -2
- package/es/components/pagination/components/jumper.vue2.js +28 -29
- package/es/components/pagination/components/next.vue2.js +4 -4
- package/es/components/pagination/components/pager.vue2.js +1 -1
- package/es/components/pagination/components/prev.vue2.js +4 -4
- package/es/components/pagination/components/sizes.vue2.js +20 -21
- package/es/components/pagination/components/total.vue2.js +10 -11
- package/es/components/popconfirm/popconfirm.vue2.js +4 -4
- package/es/components/popover/popover.vue2.js +1 -1
- package/es/components/popper/arrow.vue2.js +2 -2
- package/es/components/popper/content.vue2.js +2 -2
- package/es/components/popper/trigger.vue2.js +4 -4
- package/es/components/progress/progress.vue2.js +1 -1
- package/es/components/progress-i/progress-i.vue2.js +2 -2
- package/es/components/qrcode/qrcode.vue2.js +1 -1
- package/es/components/radio/radio-button.vue2.js +2 -2
- package/es/components/radio/radio-group.vue2.js +3 -3
- package/es/components/radio/radio.vue2.js +2 -2
- package/es/components/rate/rate.vue2.js +6 -6
- package/es/components/router-view-content/router-view-content.vue2.js +7 -7
- package/es/components/roving-focus-group/roving-focus-group.vue2.js +2 -2
- package/es/components/roving-focus-group/roving-focus-item.vue2.js +2 -2
- package/es/components/row/row.vue2.js +2 -2
- package/es/components/scrollbar/bar.vue2.js +2 -2
- package/es/components/scrollbar/scrollbar.vue2.js +7 -7
- package/es/components/scrollbar/thumb.vue2.js +2 -2
- package/es/components/search/search.vue2.js +8 -8
- package/es/components/segmented/segmented.vue2.js +7 -7
- package/es/components/select/group-item.vue.js +2 -2
- package/es/components/select/option-item.vue.js +2 -2
- package/es/components/select/select.vue.js +1 -1
- package/es/components/select/useSelect.js +1 -1
- package/es/components/skeleton/skeleton-item.vue2.js +2 -2
- package/es/components/skeleton/skeleton.vue2.js +8 -8
- package/es/components/slider/button.vue2.js +2 -2
- package/es/components/slider/slider.vue2.js +1 -1
- package/es/components/space/space.js +1 -1
- package/es/components/statistic/statistic.vue2.js +17 -17
- package/es/components/steps/item.vue2.js +11 -11
- package/es/components/steps/steps.vue2.js +2 -2
- package/es/components/super-form/super-form-action.vue2.js +47 -48
- package/es/components/super-form/super-form-item.vue2.js +204 -206
- package/es/components/super-form/super-form.vue2.js +7 -7
- package/es/components/super-form/use/helper.d.ts +1 -1
- package/es/components/super-form/use/helper.js +63 -63
- package/es/components/super-form/use/use-form.js +8 -8
- package/es/components/switch/switch.vue2.js +1 -1
- package/es/components/table/field.js +111 -130
- package/es/components/table/table.vue2.js +128 -133
- package/es/components/table/use/use-columns.js +26 -29
- package/es/components/table/use/use-data-source.js +59 -60
- package/es/components/tabs/tab-bar.vue2.js +2 -2
- package/es/components/tabs/tab-pane.vue2.js +6 -6
- package/es/components/teleport/teleport.vue2.js +2 -2
- package/es/components/time-picker/common/picker-range-trigger.vue2.js +2 -2
- package/es/components/time-picker/common/picker.vue2.js +8 -8
- package/es/components/time-picker/time-picker-com/basic-time-spinner.vue2.js +1 -1
- package/es/components/time-picker/time-picker-com/panel-time-pick.vue2.js +4 -4
- package/es/components/time-picker/time-picker-com/panel-time-range.vue2.js +4 -4
- package/es/components/time-select/time-select.vue2.js +3 -3
- package/es/components/timeline/timeline-item.vue2.js +1 -1
- package/es/components/tooltip/content.vue2.js +6 -6
- package/es/components/tooltip/tooltip.vue2.js +1 -1
- package/es/components/tooltip/trigger.vue2.js +2 -2
- package/es/components/transfer/transfer-panel.vue2.js +8 -8
- package/es/components/transfer/transfer.vue2.js +5 -5
- package/es/components/tree/tree-node.vue.js +1 -1
- package/es/components/tree/tree.vue2.js +7 -7
- package/es/components/upload/upload-content.vue2.js +8 -8
- package/es/components/upload/upload-dragger.vue2.js +2 -2
- package/es/components/upload/upload-list.vue2.js +2 -2
- package/es/components/upload/upload.vue2.js +20 -20
- package/es/components/verify-code/verify-code.vue2.js +2 -2
- package/es/components/watermark/watermark.vue2.js +2 -2
- package/es/hooks/use-id/index.js +2 -2
- package/es/index.js +40 -39
- package/es/locale/index.js +6 -6
- package/es/package.json.d.ts +1 -1
- package/es/package.json.js +1 -1
- package/es/plugin.js +5 -3
- package/es/utils/helper.js +2 -2
- package/es/utils/ns-cover.js +1 -1
- package/es/utils/vue/vnode.js +3 -3
- package/lib/components/button/use-button.cjs +1 -1
- package/lib/components/cascader/cascader.vue2.cjs +1 -1
- package/lib/components/cascader-panel/menu.vue2.cjs +2 -2
- package/lib/components/clamp-toggle/clamp-toggle.vue2.cjs +1 -1
- package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
- package/lib/components/date-picker/composables/use-basic-date-table.cjs +1 -1
- package/lib/components/date-picker/composables/use-basic-date-table.d.ts +1 -1
- package/lib/components/date-picker/composables/use-month-range-header.cjs +1 -1
- package/lib/components/date-picker/composables/use-panel-date-range.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-month-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/basic-year-table.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
- package/lib/components/date-picker/date-picker-com/panel-date-range.vue2.cjs +1 -1
- package/lib/components/date-time-select/date-time-select.vue2.cjs +1 -1
- package/lib/components/dropdown/dropdown-item-impl.vue.d.ts +1 -1
- package/lib/components/dropdown/dropdown-item.vue.d.ts +1 -1
- package/lib/components/dropdown/dropdown.vue.d.ts +1 -1
- package/lib/components/dropdown/dropdown.vue2.cjs +1 -1
- package/lib/components/dropdown/index.d.ts +33 -33
- package/lib/components/empty/empty.vue2.cjs +1 -1
- package/lib/components/full-screen/full-screen.vue2.cjs +1 -1
- package/lib/components/image/image.vue2.cjs +1 -1
- package/lib/components/image-viewer/image-viewer.vue2.cjs +1 -1
- package/lib/components/index.cjs +1 -1
- package/lib/components/index.d.ts +1 -0
- package/lib/components/input/input.vue2.cjs +1 -1
- package/lib/components/md-container/md-container.vue2.cjs +1 -1
- package/lib/components/md-container/toc.cjs +1 -1
- package/lib/components/message-box/index.cjs +1 -0
- package/lib/components/message-box/index.d.ts +4 -0
- package/lib/components/message-box/message-box.vue.cjs +1 -0
- package/lib/components/message-box/message-box.vue.d.ts +103 -0
- package/lib/components/message-box/message-box.vue2.cjs +1 -0
- package/lib/components/message-box/method.cjs +1 -0
- package/lib/components/message-box/method.d.ts +3 -0
- package/lib/components/message-box/style/css.cjs +1 -0
- package/lib/components/message-box/style/css.d.ts +2 -0
- package/lib/components/message-box/style/index.cjs +1 -0
- package/lib/components/message-box/style/index.d.ts +2 -0
- package/lib/components/message-box/types.cjs +1 -0
- package/lib/components/message-box/types.d.ts +202 -0
- package/lib/components/modal/index.d.ts +1 -0
- package/lib/components/modal/modal-footer-action.vue2.cjs +1 -1
- package/lib/components/modal/modal.vue.d.ts +1 -0
- package/lib/components/modal/modal.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/use/use-tab-dropdown.cjs +1 -1
- package/lib/components/pagination/components/jumper.vue2.cjs +1 -1
- package/lib/components/pagination/components/sizes.vue2.cjs +1 -1
- package/lib/components/pagination/components/total.vue2.cjs +1 -1
- package/lib/components/popconfirm/popconfirm.vue2.cjs +1 -1
- package/lib/components/search/search.vue2.cjs +1 -1
- package/lib/components/select/useSelect.cjs +1 -1
- package/lib/components/super-form/super-form-action.vue2.cjs +1 -1
- package/lib/components/super-form/super-form-item.vue2.cjs +1 -1
- package/lib/components/super-form/use/helper.cjs +1 -1
- package/lib/components/super-form/use/helper.d.ts +1 -1
- package/lib/components/super-form/use/use-form.cjs +1 -1
- package/lib/components/table/field.cjs +1 -1
- package/lib/components/table/table.vue2.cjs +1 -1
- package/lib/components/table/use/use-columns.cjs +1 -1
- package/lib/components/table/use/use-data-source.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-pick.vue2.cjs +1 -1
- package/lib/components/time-picker/time-picker-com/panel-time-range.vue2.cjs +1 -1
- package/lib/components/transfer/transfer-panel.vue2.cjs +1 -1
- package/lib/components/transfer/transfer.vue2.cjs +1 -1
- package/lib/components/tree/tree.vue2.cjs +1 -1
- package/lib/components/upload/upload-content.vue2.cjs +1 -1
- package/lib/components/upload/upload-list.vue2.cjs +1 -1
- package/lib/components/upload/upload.vue2.cjs +1 -1
- package/lib/index.cjs +1 -1
- package/lib/locale/index.cjs +1 -1
- package/lib/package.json.cjs +1 -1
- package/lib/package.json.d.ts +1 -1
- package/lib/plugin.cjs +1 -1
- package/package.json +2 -2
- package/theme-style/index.css +1 -1
- package/theme-style/src/table.scss +4 -0
- package/theme-style/vft-table.css +1 -1
- package/web-types.json +1 -1
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as K, computed as m, createVNode as i, createTextVNode as he, useAttrs as Ce, ref as g, getCurrentInstance as be, unref as a, watch as ye, nextTick as L, toRaw as we, openBlock as S, createElementBlock as ve, normalizeClass as ke, withCtx as n, mergeProps as M, withDirectives as xe, createElementVNode as Se, vShow as Be, renderSlot as s, normalizeProps as p, guardReactiveProps as h, createCommentVNode as B, createBlock as q, createSlots as Re } from "vue";
|
|
2
2
|
import { VftClientOnly as ze } from "../client-only/index.js";
|
|
3
3
|
import { VftEmpty as Pe } from "../empty/index.js";
|
|
4
|
-
import { vLoading as
|
|
5
|
-
import { deepMerge as
|
|
6
|
-
import { FormCompEnum as
|
|
4
|
+
import { vLoading as De } from "../loading/directive.js";
|
|
5
|
+
import { deepMerge as G, isClient as He, omit as Oe, isFunction as R } from "@vft/utils";
|
|
6
|
+
import { FormCompEnum as C } from "../../utils/form-register.js";
|
|
7
7
|
import "@vueuse/core";
|
|
8
8
|
import "../config-provider/hooks/use-global-config.js";
|
|
9
9
|
import "lodash-es";
|
|
10
|
-
import { useForm as
|
|
11
|
-
import { useNamespace as
|
|
10
|
+
import { useForm as Fe } from "../super-form/use/use-form.js";
|
|
11
|
+
import { useNamespace as Te } from "../../hooks/use-namespace/index.js";
|
|
12
12
|
import "../../hooks/use-model-toggle/index.js";
|
|
13
13
|
import "@popperjs/core";
|
|
14
14
|
import "../../hooks/use-z-index/index.js";
|
|
@@ -16,26 +16,25 @@ import "../icon/index.js";
|
|
|
16
16
|
import { VftPagination as Ae } from "../pagination/index.js";
|
|
17
17
|
import { VftSkeleton as Ee } from "../skeleton/index.js";
|
|
18
18
|
import { VftSuperForm as Ne } from "../super-form/index.js";
|
|
19
|
-
import { useLocale as $e } from "../../locale/use-locale.js";
|
|
20
19
|
import { VxeGrid as Ve } from "vxe-table";
|
|
21
|
-
import
|
|
22
|
-
import { PageSize as
|
|
20
|
+
import $e from "xe-utils";
|
|
21
|
+
import { PageSize as I } from "./constants.js";
|
|
23
22
|
import { useColumns as _e } from "./use/use-columns.js";
|
|
24
|
-
import { useDataSource as
|
|
23
|
+
import { useDataSource as Le } from "./use/use-data-source.js";
|
|
25
24
|
import { useLoading as Me } from "./use/use-loading.js";
|
|
26
25
|
import { usePagination as qe } from "./use/use-pagination.js";
|
|
27
|
-
import { EmptyEnum as
|
|
28
|
-
const
|
|
26
|
+
import { EmptyEnum as Ge } from "../empty/constants.js";
|
|
27
|
+
const Ie = K({
|
|
29
28
|
name: "vft-table"
|
|
30
|
-
}),
|
|
31
|
-
...
|
|
29
|
+
}), Ca = /* @__PURE__ */ K({
|
|
30
|
+
...Ie,
|
|
32
31
|
props: {
|
|
33
32
|
sticky: {
|
|
34
33
|
type: [Boolean, Object]
|
|
35
34
|
},
|
|
36
35
|
api: {},
|
|
37
36
|
pageSize: {
|
|
38
|
-
default:
|
|
37
|
+
default: I
|
|
39
38
|
},
|
|
40
39
|
total: {},
|
|
41
40
|
rowkey: {
|
|
@@ -80,7 +79,7 @@ const Ke = X({
|
|
|
80
79
|
onChange: {},
|
|
81
80
|
emptyCfg: {
|
|
82
81
|
default: () => ({
|
|
83
|
-
type:
|
|
82
|
+
type: Ge.NoData
|
|
84
83
|
})
|
|
85
84
|
},
|
|
86
85
|
loadingCfg: {},
|
|
@@ -393,75 +392,73 @@ const Ke = X({
|
|
|
393
392
|
"toolbar-tool-click",
|
|
394
393
|
"zoom"
|
|
395
394
|
],
|
|
396
|
-
setup(
|
|
397
|
-
expose:
|
|
398
|
-
emit:
|
|
395
|
+
setup(X, {
|
|
396
|
+
expose: j,
|
|
397
|
+
emit: Y
|
|
399
398
|
}) {
|
|
400
|
-
const
|
|
399
|
+
const W = m(() => ({
|
|
401
400
|
customClass: "vft-card-loading",
|
|
402
|
-
text: i("div", null, [i("span", null, [
|
|
401
|
+
text: i("div", null, [i("span", null, [he("加载中")]), i("span", {
|
|
403
402
|
class: "dot"
|
|
404
403
|
}, null)])
|
|
405
|
-
})),
|
|
406
|
-
|
|
407
|
-
} = $e(), Q = Ce(), f = g(), P = g(), Z = g([]), y = g(), w = g(), ee = be(), a = p(() => I(ee.props, o(y))), {
|
|
408
|
-
getLoading: oe,
|
|
404
|
+
})), U = m(() => X.loadingCfg || W.value), c = Y, d = Te("table"), J = Ce(), b = g(), z = g(), Q = g([]), y = g(), w = g(), Z = be(), o = m(() => G(Z.props, a(y))), {
|
|
405
|
+
getLoading: ee,
|
|
409
406
|
setLoading: ae
|
|
410
|
-
} = Me(
|
|
411
|
-
getPaginationInfo:
|
|
407
|
+
} = Me(o), {
|
|
408
|
+
getPaginationInfo: f,
|
|
412
409
|
setPagination: v,
|
|
413
|
-
getCurrentPage:
|
|
414
|
-
} = qe(
|
|
415
|
-
getViewColumns:
|
|
416
|
-
setColumns:
|
|
417
|
-
} = _e(
|
|
418
|
-
ye(() =>
|
|
419
|
-
|
|
420
|
-
|
|
410
|
+
getCurrentPage: oe
|
|
411
|
+
} = qe(o), {
|
|
412
|
+
getViewColumns: te,
|
|
413
|
+
setColumns: le
|
|
414
|
+
} = _e(o);
|
|
415
|
+
ye(() => oe(), (e) => {
|
|
416
|
+
L(() => {
|
|
417
|
+
P({
|
|
421
418
|
seqConfig: {
|
|
422
|
-
startIndex: (e - 1) * (
|
|
419
|
+
startIndex: (e - 1) * (f.value?.pageSize || a(o).pageSize || I)
|
|
423
420
|
}
|
|
424
421
|
});
|
|
425
422
|
});
|
|
426
423
|
}, {
|
|
427
424
|
immediate: !0
|
|
428
425
|
});
|
|
429
|
-
function
|
|
426
|
+
function P(e) {
|
|
430
427
|
y.value = {
|
|
431
|
-
...
|
|
428
|
+
...a(y),
|
|
432
429
|
...e
|
|
433
430
|
};
|
|
434
431
|
}
|
|
435
432
|
const {
|
|
436
433
|
getDataSourceRef: D,
|
|
437
|
-
handleTableChange:
|
|
434
|
+
handleTableChange: re,
|
|
438
435
|
reload: k,
|
|
439
|
-
deleteTableDataRecord:
|
|
440
|
-
insertTableDataRecord:
|
|
441
|
-
updateTableData:
|
|
442
|
-
updateTableDataRecord:
|
|
443
|
-
setTableData:
|
|
444
|
-
getDataSource:
|
|
445
|
-
getRawDataSource:
|
|
436
|
+
deleteTableDataRecord: ne,
|
|
437
|
+
insertTableDataRecord: ce,
|
|
438
|
+
updateTableData: ie,
|
|
439
|
+
updateTableDataRecord: se,
|
|
440
|
+
setTableData: H,
|
|
441
|
+
getDataSource: ge,
|
|
442
|
+
getRawDataSource: O,
|
|
446
443
|
tableSearch: F,
|
|
447
|
-
expandTreeLevel:
|
|
448
|
-
} =
|
|
449
|
-
tableData:
|
|
444
|
+
expandTreeLevel: de
|
|
445
|
+
} = Le(o, {
|
|
446
|
+
tableData: Q,
|
|
450
447
|
setLoading: ae,
|
|
451
|
-
getPaginationInfo:
|
|
448
|
+
getPaginationInfo: f,
|
|
452
449
|
setPagination: v,
|
|
453
|
-
getGridRef: () =>
|
|
450
|
+
getGridRef: () => b.value
|
|
454
451
|
}, c);
|
|
455
|
-
function
|
|
452
|
+
function T(e) {
|
|
456
453
|
e?.pageSize && v({
|
|
457
454
|
currentPage: 1
|
|
458
|
-
}),
|
|
455
|
+
}), re(e), c("change", e);
|
|
459
456
|
const {
|
|
460
457
|
onChange: t
|
|
461
|
-
} = o
|
|
458
|
+
} = a(o);
|
|
462
459
|
t && R(t) && t(e);
|
|
463
460
|
}
|
|
464
|
-
const
|
|
461
|
+
const A = {};
|
|
465
462
|
[
|
|
466
463
|
"update:data",
|
|
467
464
|
"keydown-start",
|
|
@@ -583,68 +580,68 @@ const Ke = X({
|
|
|
583
580
|
"toolbar-tool-click",
|
|
584
581
|
"zoom"
|
|
585
582
|
].forEach((e) => {
|
|
586
|
-
const t =
|
|
587
|
-
|
|
583
|
+
const t = $e.camelCase(`on-${e}`);
|
|
584
|
+
A[t] = (...l) => c(e, ...l);
|
|
588
585
|
});
|
|
589
|
-
const r =
|
|
590
|
-
const e =
|
|
591
|
-
...
|
|
592
|
-
...o
|
|
593
|
-
columns: we(
|
|
594
|
-
loading:
|
|
586
|
+
const r = m(() => {
|
|
587
|
+
const e = a(D), t = {
|
|
588
|
+
...J,
|
|
589
|
+
...a(o),
|
|
590
|
+
columns: we(a(te)),
|
|
591
|
+
loading: a(ee),
|
|
595
592
|
data: e,
|
|
596
|
-
loadingCfg:
|
|
597
|
-
...
|
|
593
|
+
loadingCfg: a(U),
|
|
594
|
+
...A
|
|
598
595
|
};
|
|
599
|
-
if (
|
|
600
|
-
(o
|
|
601
|
-
const l = o
|
|
602
|
-
t.minHeight = l || (l !== 0 && o
|
|
596
|
+
if (He) {
|
|
597
|
+
(a(o)?.addMaxHeight || a(o)?.maxHeight) && (t.maxHeight = a(o)?.maxHeight ? a(o)?.maxHeight : `${window.innerHeight - a(o)?.extraSysHeight - (o.value?.showPager ? o.value?.pageHeight || 40 : 0)}px`);
|
|
598
|
+
const l = a(o)?.minHeight;
|
|
599
|
+
t.minHeight = l || (l !== 0 && a(o)?.toolbarConfig?.custom ? 300 : void 0);
|
|
603
600
|
}
|
|
604
|
-
return o
|
|
601
|
+
return a(o)?.toolbarConfig?.refresh && (t.proxyConfig = a(o)?.proxyConfig || {
|
|
605
602
|
response: {
|
|
606
|
-
result: o
|
|
607
|
-
total: o
|
|
603
|
+
result: a(o)?.fetchSetting?.listField,
|
|
604
|
+
total: a(o)?.fetchSetting?.totalField
|
|
608
605
|
},
|
|
609
606
|
autoLoad: !1,
|
|
610
607
|
ajax: {
|
|
611
608
|
query: async () => await k()
|
|
612
609
|
}
|
|
613
610
|
}), t;
|
|
614
|
-
}),
|
|
611
|
+
}), E = {
|
|
615
612
|
setPagination: v,
|
|
616
613
|
emit: c,
|
|
617
|
-
setProps:
|
|
614
|
+
setProps: P,
|
|
618
615
|
reload: k,
|
|
619
|
-
deleteTableDataRecord:
|
|
620
|
-
insertTableDataRecord:
|
|
621
|
-
updateTableDataRecord:
|
|
622
|
-
updateTableData:
|
|
623
|
-
setTableData:
|
|
624
|
-
getDataSource:
|
|
616
|
+
deleteTableDataRecord: ne,
|
|
617
|
+
insertTableDataRecord: ce,
|
|
618
|
+
updateTableDataRecord: se,
|
|
619
|
+
updateTableData: ie,
|
|
620
|
+
setTableData: H,
|
|
621
|
+
getDataSource: ge,
|
|
625
622
|
getDataSourceRef: D,
|
|
626
|
-
setColumns:
|
|
627
|
-
getRawDataSource:
|
|
623
|
+
setColumns: le,
|
|
624
|
+
getRawDataSource: O,
|
|
628
625
|
tableSearch: F,
|
|
629
|
-
expandTreeLevel:
|
|
626
|
+
expandTreeLevel: de
|
|
630
627
|
};
|
|
631
|
-
c("register",
|
|
632
|
-
const
|
|
628
|
+
c("register", E);
|
|
629
|
+
const fe = {
|
|
633
630
|
field: "_filterTableData",
|
|
634
631
|
label: "",
|
|
635
|
-
type:
|
|
632
|
+
type: C.Search,
|
|
636
633
|
itemProps: {
|
|
637
634
|
class: "search-all-form-item"
|
|
638
635
|
},
|
|
639
636
|
componentProps: () => ({
|
|
640
637
|
onChange: (e) => {
|
|
641
|
-
|
|
638
|
+
$({
|
|
642
639
|
_filterTableData: e
|
|
643
640
|
});
|
|
644
641
|
}
|
|
645
642
|
})
|
|
646
|
-
},
|
|
647
|
-
schemas: [r.value?.formOptions?.addSearchAllSchema ?
|
|
643
|
+
}, N = G({
|
|
644
|
+
schemas: [r.value?.formOptions?.addSearchAllSchema ? fe : {}],
|
|
648
645
|
rowProps: {
|
|
649
646
|
justify: "start"
|
|
650
647
|
},
|
|
@@ -655,39 +652,39 @@ const Ke = X({
|
|
|
655
652
|
showSubmitButton: !0,
|
|
656
653
|
size: "small",
|
|
657
654
|
submitButtonOptions: {
|
|
658
|
-
btnText:
|
|
655
|
+
btnText: "搜索"
|
|
659
656
|
},
|
|
660
657
|
actionInline: !0
|
|
661
658
|
}, Oe(r.value?.formOptions, ["showActionForm", "addSearchAllSchema"]), "replace"), V = (e) => (...t) => {
|
|
662
|
-
e && R(e) && e(...t),
|
|
659
|
+
e && R(e) && e(...t), L(() => {
|
|
663
660
|
k();
|
|
664
661
|
});
|
|
665
|
-
}, [
|
|
666
|
-
|
|
667
|
-
schemas: (
|
|
668
|
-
if (!
|
|
662
|
+
}, [ue] = Fe({
|
|
663
|
+
...N,
|
|
664
|
+
schemas: (a(N)?.schemas || []).map((e) => {
|
|
665
|
+
if (!a(r)?.formOptions?.autoReloadOnClear)
|
|
669
666
|
return e;
|
|
670
|
-
if (!e.type || e.type ===
|
|
667
|
+
if (!e.type || e.type === C.Input || e.type === C.Search || e.type === C.Textarea) {
|
|
671
668
|
const {
|
|
672
|
-
componentProps:
|
|
669
|
+
componentProps: u
|
|
673
670
|
} = e;
|
|
674
|
-
if (R(
|
|
671
|
+
if (R(u))
|
|
675
672
|
return {
|
|
676
673
|
...e,
|
|
677
674
|
componentProps: async (x) => {
|
|
678
|
-
const _ = await
|
|
675
|
+
const _ = await u(x), pe = _?.onClear;
|
|
679
676
|
return {
|
|
680
677
|
..._,
|
|
681
|
-
onClear: V(
|
|
678
|
+
onClear: V(pe)
|
|
682
679
|
};
|
|
683
680
|
}
|
|
684
681
|
};
|
|
685
682
|
{
|
|
686
|
-
const x =
|
|
683
|
+
const x = u?.onClear;
|
|
687
684
|
return {
|
|
688
685
|
...e,
|
|
689
686
|
componentProps: {
|
|
690
|
-
...
|
|
687
|
+
...u,
|
|
691
688
|
onClear: V(x)
|
|
692
689
|
}
|
|
693
690
|
};
|
|
@@ -695,65 +692,63 @@ const Ke = X({
|
|
|
695
692
|
}
|
|
696
693
|
return e;
|
|
697
694
|
})
|
|
698
|
-
}),
|
|
695
|
+
}), $ = (e) => {
|
|
699
696
|
Reflect.has(e, "_filterTableData") && F(e._filterTableData), c("form-submit", e);
|
|
700
|
-
},
|
|
701
|
-
O(
|
|
697
|
+
}, me = () => {
|
|
698
|
+
H(O()), c("form-reset");
|
|
702
699
|
};
|
|
703
|
-
return
|
|
704
|
-
|
|
705
|
-
}, 1500), Y({
|
|
706
|
-
table: f,
|
|
700
|
+
return j({
|
|
701
|
+
table: b,
|
|
707
702
|
formRef: w,
|
|
708
|
-
pageRef:
|
|
709
|
-
...
|
|
703
|
+
pageRef: z,
|
|
704
|
+
...E
|
|
710
705
|
}), (e, t) => (S(), ve("div", {
|
|
711
|
-
class: ke([
|
|
712
|
-
[
|
|
706
|
+
class: ke([a(d).b(), {
|
|
707
|
+
[a(d).is("form-exceed-one-rows")]: w.value?.willExceedOneRow
|
|
713
708
|
}])
|
|
714
|
-
}, [i(
|
|
715
|
-
fallback: n(() => [i(
|
|
716
|
-
default: n(() => [i(
|
|
709
|
+
}, [i(a(ze), null, {
|
|
710
|
+
fallback: n(() => [i(a(Ee))]),
|
|
711
|
+
default: n(() => [i(a(Ve), M({
|
|
717
712
|
ref_key: "xGrid",
|
|
718
|
-
ref:
|
|
713
|
+
ref: b
|
|
719
714
|
}, r.value), {
|
|
720
|
-
toolbarButtons: n(() => [s(e.$slots, "toolbar-left"), r.value?.formOptions?.showActionForm ? (S(),
|
|
715
|
+
toolbarButtons: n(() => [s(e.$slots, "toolbar-left"), r.value?.formOptions?.showActionForm ? (S(), q(a(Ne), {
|
|
721
716
|
key: 0,
|
|
722
717
|
ref_key: "formRef",
|
|
723
718
|
ref: w,
|
|
724
|
-
onRegister:
|
|
725
|
-
onSubmit:
|
|
726
|
-
onReset:
|
|
719
|
+
onRegister: a(ue),
|
|
720
|
+
onSubmit: $,
|
|
721
|
+
onReset: me
|
|
727
722
|
}, Re({
|
|
728
723
|
_: 2
|
|
729
724
|
}, [e.$slots.resetBefore ? {
|
|
730
725
|
name: "resetBefore",
|
|
731
|
-
fn: n((l) => [s(e.$slots, "resetBefore", h(
|
|
726
|
+
fn: n((l) => [s(e.$slots, "resetBefore", p(h(l)))]),
|
|
732
727
|
key: "0"
|
|
733
728
|
} : void 0, e.$slots.submitBefore ? {
|
|
734
729
|
name: "submitBefore",
|
|
735
|
-
fn: n((l) => [s(e.$slots, "submitBefore", h(
|
|
730
|
+
fn: n((l) => [s(e.$slots, "submitBefore", p(h(l)))]),
|
|
736
731
|
key: "1"
|
|
737
732
|
} : void 0, e.$slots.submitAfter ? {
|
|
738
733
|
name: "submitAfter",
|
|
739
|
-
fn: n((l) => [s(e.$slots, "submitAfter", h(
|
|
734
|
+
fn: n((l) => [s(e.$slots, "submitAfter", p(h(l)))]),
|
|
740
735
|
key: "2"
|
|
741
736
|
} : void 0]), 1032, ["onRegister"])) : B("", !0), s(e.$slots, "toolbar-right")]),
|
|
742
737
|
empty: n(() => [r.value.loading ? B("", !0) : s(e.$slots, "empty", {
|
|
743
738
|
key: 0
|
|
744
|
-
}, () => [i(
|
|
745
|
-
loading: n(() => [xe(Se("div", null, null, 512), [[Be, r.value.loading], [
|
|
739
|
+
}, () => [i(a(Pe), p(h(r.value.emptyCfg)), null, 16)])]),
|
|
740
|
+
loading: n(() => [xe(Se("div", null, null, 512), [[Be, r.value.loading], [a(De), r.value.loadingCfg]])]),
|
|
746
741
|
_: 3
|
|
747
|
-
}, 16), r.value.showPager ? (S(),
|
|
742
|
+
}, 16), r.value.showPager ? (S(), q(a(Ae), M({
|
|
748
743
|
key: 0,
|
|
749
744
|
ref_key: "pageRef",
|
|
750
|
-
ref:
|
|
751
|
-
},
|
|
752
|
-
class: [
|
|
753
|
-
onCurrentChange: t[0] || (t[0] = (l) =>
|
|
745
|
+
ref: z
|
|
746
|
+
}, a(f), {
|
|
747
|
+
class: [a(d).e("pager"), a(d).m(`pager-${a(f)?.pagePlacement}`)],
|
|
748
|
+
onCurrentChange: t[0] || (t[0] = (l) => T({
|
|
754
749
|
currentPage: l
|
|
755
750
|
})),
|
|
756
|
-
onSizeChange: t[1] || (t[1] = (l) =>
|
|
751
|
+
onSizeChange: t[1] || (t[1] = (l) => T({
|
|
757
752
|
pageSize: l
|
|
758
753
|
}))
|
|
759
754
|
}), null, 16, ["class"])) : B("", !0)]),
|
|
@@ -762,5 +757,5 @@ const Ke = X({
|
|
|
762
757
|
}
|
|
763
758
|
});
|
|
764
759
|
export {
|
|
765
|
-
|
|
760
|
+
Ca as default
|
|
766
761
|
};
|
|
@@ -1,43 +1,40 @@
|
|
|
1
|
-
import { isNullOrUndefined as
|
|
2
|
-
import { cloneDeep as
|
|
3
|
-
import { ref as
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
} = y(), r = v(o(u).columns), m = o(u).columns, e = c(() => {
|
|
9
|
-
const n = l(o(r));
|
|
10
|
-
return n ? n.map((t) => (!t.formatter && !t.slots && !t.cellRender && (t.formatter = ({
|
|
1
|
+
import { isNullOrUndefined as g, isArray as d } from "@vft/utils";
|
|
2
|
+
import { cloneDeep as c } from "lodash-es";
|
|
3
|
+
import { ref as h, unref as o, computed as m, watch as v, toRaw as p } from "vue";
|
|
4
|
+
function y(u) {
|
|
5
|
+
const t = h(o(u).columns), l = o(u).columns, e = m(() => {
|
|
6
|
+
const r = c(o(t));
|
|
7
|
+
return r ? r.map((n) => (!n.formatter && !n.slots && !n.cellRender && (n.formatter = ({
|
|
11
8
|
cellValue: s
|
|
12
|
-
}) =>
|
|
13
|
-
}),
|
|
14
|
-
function
|
|
15
|
-
const
|
|
16
|
-
if (
|
|
17
|
-
if (
|
|
18
|
-
|
|
9
|
+
}) => g(s) || s === "" ? "-" : s), n)) : [];
|
|
10
|
+
}), f = m(() => o(e));
|
|
11
|
+
function i(r) {
|
|
12
|
+
const n = c(r);
|
|
13
|
+
if (d(n)) {
|
|
14
|
+
if (n.length <= 0) {
|
|
15
|
+
t.value = [];
|
|
19
16
|
return;
|
|
20
17
|
}
|
|
21
|
-
|
|
18
|
+
t.value = n;
|
|
22
19
|
}
|
|
23
20
|
}
|
|
24
|
-
|
|
25
|
-
|
|
21
|
+
v(() => o(u).columns, (r) => {
|
|
22
|
+
t.value = r || t.value;
|
|
26
23
|
}, {});
|
|
27
|
-
function
|
|
28
|
-
return
|
|
24
|
+
function a() {
|
|
25
|
+
return p(o(e));
|
|
29
26
|
}
|
|
30
|
-
function
|
|
31
|
-
return
|
|
27
|
+
function C() {
|
|
28
|
+
return l;
|
|
32
29
|
}
|
|
33
30
|
return {
|
|
34
31
|
getColumnsRef: e,
|
|
35
|
-
getCacheColumns:
|
|
36
|
-
getViewColumns:
|
|
37
|
-
getColumns:
|
|
38
|
-
setColumns:
|
|
32
|
+
getCacheColumns: C,
|
|
33
|
+
getViewColumns: f,
|
|
34
|
+
getColumns: a,
|
|
35
|
+
setColumns: i
|
|
39
36
|
};
|
|
40
37
|
}
|
|
41
38
|
export {
|
|
42
|
-
|
|
39
|
+
y as useColumns
|
|
43
40
|
};
|