@newview/ui 1.1.13 → 1.1.15
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/README.md +17 -5
- package/dist/newview-ui.js +290 -62
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/types/ComForm.d.ts +10 -1
- package/types/Grid.d.ts +38 -0
- package/dist/newview-ui.umd.cjs +0 -1
package/dist/newview-ui.js
CHANGED
|
@@ -5,8 +5,8 @@ var __publicField2 = (obj, key2, value) => {
|
|
|
5
5
|
return value;
|
|
6
6
|
};
|
|
7
7
|
import { BaseInstance } from "@newview/base-vue";
|
|
8
|
-
import { openBlock, createElementBlock, normalizeStyle, defineComponent, ref, resolveComponent, createVNode, reactive, watch, onMounted, onUnmounted, createBlock, withCtx, createElementVNode, Fragment, renderList, normalizeClass, withDirectives, createTextVNode, toDisplayString, renderSlot, createCommentVNode, createSlots, vShow, h, computed, nextTick, mergeProps, toHandlers, pushScopeId, popScopeId, withModifiers, createApp, getCurrentInstance } from "vue";
|
|
9
|
-
import { VxeColumn, VxeColgroup, VxeGrid, VxeTable } from "vxe-table";
|
|
8
|
+
import { openBlock, createElementBlock, normalizeStyle, defineComponent, ref, resolveComponent, createVNode, reactive, watch, onMounted, onUnmounted, createBlock, withCtx, createElementVNode, Fragment, renderList, normalizeClass, withDirectives, createTextVNode, toDisplayString, renderSlot, createCommentVNode, createSlots, vShow, h, toRaw, computed, nextTick, mergeProps, toHandlers, pushScopeId, popScopeId, withModifiers, createApp, getCurrentInstance } from "vue";
|
|
9
|
+
import { VxeColumn, VxeColgroup, VXETable, VxeGrid, VxeTable } from "vxe-table";
|
|
10
10
|
import { utilities } from "@newview/tools";
|
|
11
11
|
import { Space, Icon, Drawer, Button } from "view-ui-plus";
|
|
12
12
|
import dayjs from "dayjs";
|
|
@@ -17805,7 +17805,7 @@ const _export_sfc = (sfc, props) => {
|
|
|
17805
17805
|
}
|
|
17806
17806
|
return target;
|
|
17807
17807
|
};
|
|
17808
|
-
const _sfc_main$
|
|
17808
|
+
const _sfc_main$j = {
|
|
17809
17809
|
name: "BAceEditor",
|
|
17810
17810
|
props: {
|
|
17811
17811
|
modelValue: String,
|
|
@@ -17944,13 +17944,13 @@ const _sfc_main$i = {
|
|
|
17944
17944
|
}
|
|
17945
17945
|
}
|
|
17946
17946
|
};
|
|
17947
|
-
function _sfc_render$
|
|
17947
|
+
function _sfc_render$j(_ctx, _cache, $props, $setup, $data, $options) {
|
|
17948
17948
|
return openBlock(), createElementBlock("div", {
|
|
17949
17949
|
class: "bin-editor-next",
|
|
17950
17950
|
style: normalizeStyle($options.wrapStyles)
|
|
17951
17951
|
}, null, 4);
|
|
17952
17952
|
}
|
|
17953
|
-
const BinEditor = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
17953
|
+
const BinEditor = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["render", _sfc_render$j]]);
|
|
17954
17954
|
var ace$1 = { exports: {} };
|
|
17955
17955
|
(function(module, exports) {
|
|
17956
17956
|
(function() {
|
|
@@ -30033,7 +30033,7 @@ const propDefine$r = {
|
|
|
30033
30033
|
default: {}
|
|
30034
30034
|
}
|
|
30035
30035
|
};
|
|
30036
|
-
const _sfc_main$
|
|
30036
|
+
const _sfc_main$i = defineComponent({
|
|
30037
30037
|
name: "NvEditor",
|
|
30038
30038
|
components: { BinEditor },
|
|
30039
30039
|
emits: [""],
|
|
@@ -30080,10 +30080,10 @@ let EditorInstance$1 = class EditorInstance2 extends BaseInstance {
|
|
|
30080
30080
|
//#endregion BinEditor 编辑器 END
|
|
30081
30081
|
};
|
|
30082
30082
|
const Editor_vue_vue_type_style_index_0_scoped_cf6872cf_lang = "";
|
|
30083
|
-
const _hoisted_1$
|
|
30084
|
-
function _sfc_render$
|
|
30083
|
+
const _hoisted_1$d = { class: "monacoEditor" };
|
|
30084
|
+
function _sfc_render$i(_ctx, _cache, $props, $setup, $data, $options) {
|
|
30085
30085
|
const _component_BinEditor = resolveComponent("BinEditor");
|
|
30086
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
30086
|
+
return openBlock(), createElementBlock("div", _hoisted_1$d, [
|
|
30087
30087
|
createVNode(_component_BinEditor, {
|
|
30088
30088
|
modelValue: _ctx.editorValue,
|
|
30089
30089
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.editorValue = $event),
|
|
@@ -30099,7 +30099,7 @@ function _sfc_render$h(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
30099
30099
|
}, null, 8, ["modelValue", "lang", "readonly", "font-size", "wrap", "snippets", "options", "styles"])
|
|
30100
30100
|
]);
|
|
30101
30101
|
}
|
|
30102
|
-
const Editor = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
30102
|
+
const Editor = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["render", _sfc_render$i], ["__scopeId", "data-v-cf6872cf"]]);
|
|
30103
30103
|
const propDefine$q = {
|
|
30104
30104
|
placeholder: {
|
|
30105
30105
|
// 占位文本
|
|
@@ -30127,7 +30127,7 @@ const propDefine$q = {
|
|
|
30127
30127
|
default: false
|
|
30128
30128
|
}
|
|
30129
30129
|
};
|
|
30130
|
-
const _sfc_main$
|
|
30130
|
+
const _sfc_main$h = defineComponent({
|
|
30131
30131
|
name: "NvIconSelect",
|
|
30132
30132
|
components: {},
|
|
30133
30133
|
emits: ["update:modelValue", "change"],
|
|
@@ -31052,15 +31052,15 @@ class IconSelectInstance extends BaseInstance {
|
|
|
31052
31052
|
//#endregion Icon 选择 END
|
|
31053
31053
|
}
|
|
31054
31054
|
const IconSelect_vue_vue_type_style_index_0_lang = "";
|
|
31055
|
-
const _hoisted_1$
|
|
31056
|
-
const _hoisted_2$
|
|
31057
|
-
const _hoisted_3$
|
|
31055
|
+
const _hoisted_1$c = { class: "icon-select" };
|
|
31056
|
+
const _hoisted_2$a = { class: "icon-select-search" };
|
|
31057
|
+
const _hoisted_3$8 = { class: "icon-select-list" };
|
|
31058
31058
|
const _hoisted_4$6 = ["onClick", "title"];
|
|
31059
|
-
function _sfc_render$
|
|
31059
|
+
function _sfc_render$h(_ctx, _cache, $props, $setup, $data, $options) {
|
|
31060
31060
|
const _component_Icon = resolveComponent("Icon");
|
|
31061
31061
|
const _component_Input = resolveComponent("Input");
|
|
31062
31062
|
const _component_Poptip = resolveComponent("Poptip");
|
|
31063
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
31063
|
+
return openBlock(), createElementBlock("div", _hoisted_1$c, [
|
|
31064
31064
|
_ctx.readonly ? (openBlock(), createBlock(_component_Icon, {
|
|
31065
31065
|
key: 0,
|
|
31066
31066
|
type: "iconValue"
|
|
@@ -31076,7 +31076,7 @@ function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31076
31076
|
createElementVNode("div", {
|
|
31077
31077
|
style: normalizeStyle({ width: _ctx.poptipWidth + "px" })
|
|
31078
31078
|
}, [
|
|
31079
|
-
createElementVNode("div", _hoisted_2$
|
|
31079
|
+
createElementVNode("div", _hoisted_2$a, [
|
|
31080
31080
|
createVNode(_component_Input, {
|
|
31081
31081
|
modelValue: _ctx.iconSearch,
|
|
31082
31082
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.iconSearch = $event),
|
|
@@ -31085,7 +31085,7 @@ function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31085
31085
|
onOnChange: _ctx.doSearchIcon
|
|
31086
31086
|
}, null, 8, ["modelValue", "onOnChange"])
|
|
31087
31087
|
]),
|
|
31088
|
-
createElementVNode("div", _hoisted_3$
|
|
31088
|
+
createElementVNode("div", _hoisted_3$8, [
|
|
31089
31089
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.icons, (item2) => {
|
|
31090
31090
|
return openBlock(), createElementBlock("div", {
|
|
31091
31091
|
class: "icon-select-item",
|
|
@@ -31121,7 +31121,7 @@ function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31121
31121
|
}, 8, ["modelValue"]))
|
|
31122
31122
|
]);
|
|
31123
31123
|
}
|
|
31124
|
-
const NvIconSelect = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
31124
|
+
const NvIconSelect = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["render", _sfc_render$h]]);
|
|
31125
31125
|
const propDefine$p = {
|
|
31126
31126
|
onlyView: {
|
|
31127
31127
|
// 是否只读
|
|
@@ -31140,7 +31140,7 @@ const propDefine$p = {
|
|
|
31140
31140
|
}
|
|
31141
31141
|
}
|
|
31142
31142
|
};
|
|
31143
|
-
const _sfc_main$
|
|
31143
|
+
const _sfc_main$g = defineComponent({
|
|
31144
31144
|
name: "NvComForm",
|
|
31145
31145
|
components: { NvIconSelect },
|
|
31146
31146
|
emits: [""],
|
|
@@ -31278,10 +31278,10 @@ let ComFormInstance$1 = class ComFormInstance2 extends BaseInstance {
|
|
|
31278
31278
|
}
|
|
31279
31279
|
//#endregion 公开Api End
|
|
31280
31280
|
};
|
|
31281
|
-
const
|
|
31282
|
-
const _hoisted_1$
|
|
31283
|
-
const _hoisted_2$
|
|
31284
|
-
function _sfc_render$
|
|
31281
|
+
const ComForm_vue_vue_type_style_index_0_scoped_eba0d593_lang = "";
|
|
31282
|
+
const _hoisted_1$b = { class: "comForm" };
|
|
31283
|
+
const _hoisted_2$9 = { key: 1 };
|
|
31284
|
+
function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
|
|
31285
31285
|
const _component_com_form = resolveComponent("com-form", true);
|
|
31286
31286
|
const _component_Card = resolveComponent("Card");
|
|
31287
31287
|
const _component_Switch = resolveComponent("Switch");
|
|
@@ -31309,7 +31309,7 @@ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31309
31309
|
const _component_FormItem = resolveComponent("FormItem");
|
|
31310
31310
|
const _component_Col = resolveComponent("Col");
|
|
31311
31311
|
const _component_Row = resolveComponent("Row");
|
|
31312
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
31312
|
+
return openBlock(), createElementBlock("div", _hoisted_1$b, [
|
|
31313
31313
|
createElementVNode("div", {
|
|
31314
31314
|
class: normalizeClass({ onlyViewForm: _ctx.onlyView })
|
|
31315
31315
|
}, [
|
|
@@ -31369,7 +31369,7 @@ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31369
31369
|
loading: _ctx.getPropValue(item2.switchProp, "loading"),
|
|
31370
31370
|
onOnChange: ($event) => _ctx.getPropEvent(item2.switchProp, "onChange")($event, item2)
|
|
31371
31371
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "size", "disabled", "true-value", "false-value", "true-color", "false-color", "before-change", "loading", "onOnChange"])) : createCommentVNode("", true),
|
|
31372
|
-
item2.type == "Label" ? (openBlock(), createElementBlock("span", _hoisted_2$
|
|
31372
|
+
item2.type == "Label" ? (openBlock(), createElementBlock("span", _hoisted_2$9, toDisplayString(_ctx.formModel[item2.model]), 1)) : createCommentVNode("", true),
|
|
31373
31373
|
item2.type == "Button" ? (openBlock(), createBlock(_component_Button, {
|
|
31374
31374
|
key: 2,
|
|
31375
31375
|
type: _ctx.getPropValue(item2.buttonProp, "type"),
|
|
@@ -31527,13 +31527,14 @@ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31527
31527
|
default: withCtx(() => [
|
|
31528
31528
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.getPropValue(item2.radioProp, "datas"), (option) => {
|
|
31529
31529
|
return openBlock(), createBlock(_component_Radio, {
|
|
31530
|
-
label: option.value
|
|
31530
|
+
label: option.value,
|
|
31531
|
+
disabled: _ctx.getPropValue(item2.radioProp, "disabled") || _ctx.onlyView
|
|
31531
31532
|
}, {
|
|
31532
31533
|
default: withCtx(() => [
|
|
31533
31534
|
createTextVNode(toDisplayString(option.text), 1)
|
|
31534
31535
|
]),
|
|
31535
31536
|
_: 2
|
|
31536
|
-
}, 1032, ["label"]);
|
|
31537
|
+
}, 1032, ["label", "disabled"]);
|
|
31537
31538
|
}), 256))
|
|
31538
31539
|
]),
|
|
31539
31540
|
_: 2
|
|
@@ -31659,7 +31660,10 @@ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31659
31660
|
"events-enabled": _ctx.getPropValue(item2.datePickerProp, "events-enabled"),
|
|
31660
31661
|
shortcuts: _ctx.getPropValue(item2.datePickerProp, "shortcuts"),
|
|
31661
31662
|
disabledDate: _ctx.getPropValue(item2.datePickerProp, "disabledDate"),
|
|
31662
|
-
onOnChange: ($event) =>
|
|
31663
|
+
onOnChange: ($event) => {
|
|
31664
|
+
_ctx.formModel[item2.model] = $event;
|
|
31665
|
+
_ctx.getPropEvent(item2.datePickerProp, "onChange")($event, item2);
|
|
31666
|
+
},
|
|
31663
31667
|
onOnOpenChange: ($event) => _ctx.getPropEvent(item2.datePickerProp, "onOpenChange")($event, item2),
|
|
31664
31668
|
onOnOk: ($event) => _ctx.getPropEvent(item2.datePickerProp, "onOk")($event, item2),
|
|
31665
31669
|
onOnClear: ($event) => _ctx.getPropEvent(item2.datePickerProp, "onClear")($event, item2),
|
|
@@ -31798,7 +31802,7 @@ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
31798
31802
|
], 2)
|
|
31799
31803
|
]);
|
|
31800
31804
|
}
|
|
31801
|
-
const ComForm = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
31805
|
+
const ComForm = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["render", _sfc_render$g], ["__scopeId", "data-v-eba0d593"]]);
|
|
31802
31806
|
const style = "";
|
|
31803
31807
|
const propDefine$o = {
|
|
31804
31808
|
options: {
|
|
@@ -31817,7 +31821,7 @@ const propDefine$o = {
|
|
|
31817
31821
|
default: () => 80
|
|
31818
31822
|
}
|
|
31819
31823
|
};
|
|
31820
|
-
const _sfc_main$
|
|
31824
|
+
const _sfc_main$f = defineComponent({
|
|
31821
31825
|
name: "NvSearchCom",
|
|
31822
31826
|
components: {},
|
|
31823
31827
|
emits: ["search"],
|
|
@@ -31937,7 +31941,7 @@ let SearchComInstance$1 = class SearchComInstance2 extends BaseInstance {
|
|
|
31937
31941
|
//#endregion AutoComplete END
|
|
31938
31942
|
};
|
|
31939
31943
|
const SearchCom_vue_vue_type_style_index_0_scoped_cda08489_lang = "";
|
|
31940
|
-
function _sfc_render$
|
|
31944
|
+
function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
31941
31945
|
const _component_Input = resolveComponent("Input");
|
|
31942
31946
|
const _component_Radio = resolveComponent("Radio");
|
|
31943
31947
|
const _component_RadioGroup = resolveComponent("RadioGroup");
|
|
@@ -32124,7 +32128,7 @@ function _sfc_render$e(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
32124
32128
|
_: 1
|
|
32125
32129
|
}, 8, ["model", "label-width"]);
|
|
32126
32130
|
}
|
|
32127
|
-
const SearchCom = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
32131
|
+
const SearchCom = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["render", _sfc_render$f], ["__scopeId", "data-v-cda08489"]]);
|
|
32128
32132
|
const propDefine$n = {
|
|
32129
32133
|
options: {
|
|
32130
32134
|
// 配置项
|
|
@@ -32147,7 +32151,7 @@ const propDefine$n = {
|
|
|
32147
32151
|
default: 3
|
|
32148
32152
|
}
|
|
32149
32153
|
};
|
|
32150
|
-
const _sfc_main$
|
|
32154
|
+
const _sfc_main$e = defineComponent({
|
|
32151
32155
|
name: "NvToolbar",
|
|
32152
32156
|
components: {},
|
|
32153
32157
|
emits: [""],
|
|
@@ -32282,10 +32286,10 @@ let ToolbarInstance$1 = class ToolbarInstance2 extends BaseInstance {
|
|
|
32282
32286
|
//#endregion 业务逻辑 END
|
|
32283
32287
|
};
|
|
32284
32288
|
const Toolbar_vue_vue_type_style_index_0_scoped_69337cbe_lang = "";
|
|
32285
|
-
const _hoisted_1$
|
|
32286
|
-
const _hoisted_2$
|
|
32287
|
-
const _hoisted_3$
|
|
32288
|
-
function _sfc_render$
|
|
32289
|
+
const _hoisted_1$a = { class: "toolbar" };
|
|
32290
|
+
const _hoisted_2$8 = { style: { "display": "none" } };
|
|
32291
|
+
const _hoisted_3$7 = { key: 0 };
|
|
32292
|
+
function _sfc_render$e(_ctx, _cache, $props, $setup, $data, $options) {
|
|
32289
32293
|
const _component_Button = resolveComponent("Button");
|
|
32290
32294
|
const _component_ButtonGroup = resolveComponent("ButtonGroup");
|
|
32291
32295
|
const _component_Divider = resolveComponent("Divider");
|
|
@@ -32294,10 +32298,10 @@ function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
32294
32298
|
const _component_DropdownMenu = resolveComponent("DropdownMenu");
|
|
32295
32299
|
const _component_Dropdown = resolveComponent("Dropdown");
|
|
32296
32300
|
const _component_Space = resolveComponent("Space");
|
|
32297
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
32301
|
+
return openBlock(), createElementBlock("div", _hoisted_1$a, [
|
|
32298
32302
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.mainOptions, (item2, index2) => {
|
|
32299
|
-
return openBlock(), createElementBlock("div", _hoisted_2$
|
|
32300
|
-
_ctx.getIsShow(item2) ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
32303
|
+
return openBlock(), createElementBlock("div", _hoisted_2$8, [
|
|
32304
|
+
_ctx.getIsShow(item2) ? (openBlock(), createElementBlock("span", _hoisted_3$7)) : createCommentVNode("", true)
|
|
32301
32305
|
]);
|
|
32302
32306
|
}), 256)),
|
|
32303
32307
|
_ctx.isButtonGroup ? (openBlock(), createBlock(_component_ButtonGroup, { key: 0 }, {
|
|
@@ -32405,7 +32409,7 @@ function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
32405
32409
|
}))
|
|
32406
32410
|
]);
|
|
32407
32411
|
}
|
|
32408
|
-
const Toolbar = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
32412
|
+
const Toolbar = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["render", _sfc_render$e], ["__scopeId", "data-v-69337cbe"]]);
|
|
32409
32413
|
const GridCellContent = defineComponent({
|
|
32410
32414
|
name: "GridCellContent",
|
|
32411
32415
|
props: {
|
|
@@ -32453,7 +32457,7 @@ const propDefine$m = {
|
|
|
32453
32457
|
}
|
|
32454
32458
|
}
|
|
32455
32459
|
};
|
|
32456
|
-
const _sfc_main$
|
|
32460
|
+
const _sfc_main$d = defineComponent({
|
|
32457
32461
|
name: "GridColumn",
|
|
32458
32462
|
components: { VxeColumn, VxeColgroup, GridCellContent, GridTitleContent },
|
|
32459
32463
|
emits: ["clearRadioRow", "change", "delete", "addchild"],
|
|
@@ -32691,6 +32695,69 @@ class GridColumnInstance extends BaseInstance {
|
|
|
32691
32695
|
btn.onclick(row, btn);
|
|
32692
32696
|
}
|
|
32693
32697
|
});
|
|
32698
|
+
//#endregion 事件 END
|
|
32699
|
+
//#region 表头筛选
|
|
32700
|
+
__publicField2(this, "getColumFilters", (filter3) => {
|
|
32701
|
+
if (filter3) {
|
|
32702
|
+
if (filter3.type == "select") {
|
|
32703
|
+
return filter3.options;
|
|
32704
|
+
} else if (filter3.type == "daterange") {
|
|
32705
|
+
return [{ data: ["", ""] }];
|
|
32706
|
+
} else {
|
|
32707
|
+
return [{ data: "" }];
|
|
32708
|
+
}
|
|
32709
|
+
} else {
|
|
32710
|
+
return void 0;
|
|
32711
|
+
}
|
|
32712
|
+
});
|
|
32713
|
+
__publicField2(this, "getColumFilterMultiple", (filter3) => {
|
|
32714
|
+
if (filter3) {
|
|
32715
|
+
if (filter3.type == "select") {
|
|
32716
|
+
return filter3.multiple;
|
|
32717
|
+
} else {
|
|
32718
|
+
return void 0;
|
|
32719
|
+
}
|
|
32720
|
+
} else {
|
|
32721
|
+
return void 0;
|
|
32722
|
+
}
|
|
32723
|
+
});
|
|
32724
|
+
__publicField2(this, "getColumFilterRender", (filter3) => {
|
|
32725
|
+
let FilterRender;
|
|
32726
|
+
if (filter3) {
|
|
32727
|
+
switch (filter3.type) {
|
|
32728
|
+
case "select":
|
|
32729
|
+
FilterRender = void 0;
|
|
32730
|
+
break;
|
|
32731
|
+
case "input":
|
|
32732
|
+
FilterRender = { name: "$input" };
|
|
32733
|
+
break;
|
|
32734
|
+
case "date":
|
|
32735
|
+
FilterRender = { name: "$input", props: { type: "date" } };
|
|
32736
|
+
break;
|
|
32737
|
+
case "month":
|
|
32738
|
+
FilterRender = { name: "$input", props: { type: "month", valueFormat: "yyyy-MM" } };
|
|
32739
|
+
break;
|
|
32740
|
+
case "year":
|
|
32741
|
+
FilterRender = { name: "$input", props: { type: "year", valueFormat: "yyyy" } };
|
|
32742
|
+
break;
|
|
32743
|
+
case "time":
|
|
32744
|
+
FilterRender = { name: "$input", props: { type: "time" } };
|
|
32745
|
+
break;
|
|
32746
|
+
case "datetime":
|
|
32747
|
+
FilterRender = { name: "$input", props: { type: "datetime" } };
|
|
32748
|
+
break;
|
|
32749
|
+
case "daterange":
|
|
32750
|
+
FilterRender = { name: "filterDaterange" };
|
|
32751
|
+
break;
|
|
32752
|
+
default:
|
|
32753
|
+
FilterRender = { name: "$input" };
|
|
32754
|
+
break;
|
|
32755
|
+
}
|
|
32756
|
+
} else {
|
|
32757
|
+
FilterRender = void 0;
|
|
32758
|
+
}
|
|
32759
|
+
return FilterRender;
|
|
32760
|
+
});
|
|
32694
32761
|
this.props = props;
|
|
32695
32762
|
this.ctx = ctx;
|
|
32696
32763
|
this.parseColumn();
|
|
@@ -32812,12 +32879,12 @@ class GridColumnInstance extends BaseInstance {
|
|
|
32812
32879
|
}
|
|
32813
32880
|
}
|
|
32814
32881
|
}
|
|
32815
|
-
//#endregion
|
|
32882
|
+
//#endregion
|
|
32816
32883
|
}
|
|
32817
32884
|
const GridColumn_vue_vue_type_style_index_0_lang = "";
|
|
32818
|
-
const
|
|
32819
|
-
const _hoisted_1$
|
|
32820
|
-
function _sfc_render$
|
|
32885
|
+
const GridColumn_vue_vue_type_style_index_1_scoped_067f3d07_lang = "";
|
|
32886
|
+
const _hoisted_1$9 = { class: "gridColumn" };
|
|
32887
|
+
function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
|
|
32821
32888
|
const _component_GridTitleContent = resolveComponent("GridTitleContent");
|
|
32822
32889
|
const _component_grid_column = resolveComponent("grid-column", true);
|
|
32823
32890
|
const _component_vxe_colgroup = resolveComponent("vxe-colgroup");
|
|
@@ -32835,7 +32902,7 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
32835
32902
|
const _component_Checkbox = resolveComponent("Checkbox");
|
|
32836
32903
|
const _component_Button = resolveComponent("Button");
|
|
32837
32904
|
const _component_Space = resolveComponent("Space");
|
|
32838
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
32905
|
+
return openBlock(), createElementBlock("div", _hoisted_1$9, [
|
|
32839
32906
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.columns, (column) => {
|
|
32840
32907
|
return openBlock(), createElementBlock(Fragment, null, [
|
|
32841
32908
|
_ctx.getHasColgroup(column) && _ctx.getVisible(column) ? (openBlock(), createBlock(_component_vxe_colgroup, {
|
|
@@ -32939,7 +33006,10 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
32939
33006
|
"sort-by": column.sortBy,
|
|
32940
33007
|
"sort-type": column.sortType,
|
|
32941
33008
|
"edit-render": {},
|
|
32942
|
-
"tree-node": column.treeNode
|
|
33009
|
+
"tree-node": column.treeNode,
|
|
33010
|
+
filters: _ctx.getColumFilters(column.filter),
|
|
33011
|
+
"filter-multiple": _ctx.getColumFilterMultiple(column.filter),
|
|
33012
|
+
"filter-render": _ctx.getColumFilterRender(column.filter)
|
|
32943
33013
|
}, {
|
|
32944
33014
|
edit: withCtx((scope) => [
|
|
32945
33015
|
column.colType == "ed" ? (openBlock(), createBlock(_component_Input, {
|
|
@@ -33047,7 +33117,7 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
33047
33117
|
createVNode(_component_GridTitleContent, { column }, null, 8, ["column"])
|
|
33048
33118
|
]),
|
|
33049
33119
|
_: 2
|
|
33050
|
-
}, 1032, ["field", "min-width", "width", "resizable", "visible", "fixed", "align", "header-align", "footer-align", "show-overflow", "show-header-overflow", "show-footer-overflow", "class-name", "header-class-name", "footer-class-name", "formatter", "sortable", "sort-by", "sort-type", "tree-node"])) : _ctx.getHasRowButton(column) ? (openBlock(), createBlock(_component_vxe_column, {
|
|
33120
|
+
}, 1032, ["field", "min-width", "width", "resizable", "visible", "fixed", "align", "header-align", "footer-align", "show-overflow", "show-header-overflow", "show-footer-overflow", "class-name", "header-class-name", "footer-class-name", "formatter", "sortable", "sort-by", "sort-type", "tree-node", "filters", "filter-multiple", "filter-render"])) : _ctx.getHasRowButton(column) ? (openBlock(), createBlock(_component_vxe_column, {
|
|
33051
33121
|
key: 5,
|
|
33052
33122
|
field: column.field,
|
|
33053
33123
|
"min-width": column.minWidth,
|
|
@@ -33101,7 +33171,10 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
33101
33171
|
sortable: column.sortable,
|
|
33102
33172
|
"sort-by": column.sortBy,
|
|
33103
33173
|
"sort-type": column.sortType,
|
|
33104
|
-
"tree-node": column.treeNode
|
|
33174
|
+
"tree-node": column.treeNode,
|
|
33175
|
+
filters: _ctx.getColumFilters(column.filter),
|
|
33176
|
+
"filter-multiple": _ctx.getColumFilterMultiple(column.filter),
|
|
33177
|
+
"filter-render": _ctx.getColumFilterRender(column.filter)
|
|
33105
33178
|
}, {
|
|
33106
33179
|
default: withCtx(({ row }) => [
|
|
33107
33180
|
createVNode(_component_GridCellContent, {
|
|
@@ -33113,13 +33186,110 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
33113
33186
|
createVNode(_component_GridTitleContent, { column }, null, 8, ["column"])
|
|
33114
33187
|
]),
|
|
33115
33188
|
_: 2
|
|
33116
|
-
}, 1032, ["field", "min-width", "width", "resizable", "visible", "fixed", "align", "header-align", "footer-align", "show-overflow", "show-header-overflow", "show-footer-overflow", "class-name", "header-class-name", "footer-class-name", "formatter", "sortable", "sort-by", "sort-type", "tree-node"]))
|
|
33189
|
+
}, 1032, ["field", "min-width", "width", "resizable", "visible", "fixed", "align", "header-align", "footer-align", "show-overflow", "show-header-overflow", "show-footer-overflow", "class-name", "header-class-name", "footer-class-name", "formatter", "sortable", "sort-by", "sort-type", "tree-node", "filters", "filter-multiple", "filter-render"]))
|
|
33117
33190
|
], 64)) : createCommentVNode("", true)
|
|
33118
33191
|
], 64);
|
|
33119
33192
|
}), 256))
|
|
33120
33193
|
]);
|
|
33121
33194
|
}
|
|
33122
|
-
const GridColumn = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
33195
|
+
const GridColumn = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["render", _sfc_render$d], ["__scopeId", "data-v-067f3d07"]]);
|
|
33196
|
+
const _sfc_main$c = defineComponent({
|
|
33197
|
+
name: "FilterDaterange",
|
|
33198
|
+
props: {
|
|
33199
|
+
params: Object
|
|
33200
|
+
},
|
|
33201
|
+
setup(props) {
|
|
33202
|
+
const filterDateRangeVal = reactive({
|
|
33203
|
+
option: null
|
|
33204
|
+
});
|
|
33205
|
+
const warningMsg = reactive({
|
|
33206
|
+
isShow: false
|
|
33207
|
+
});
|
|
33208
|
+
const load = () => {
|
|
33209
|
+
const { params } = props;
|
|
33210
|
+
if (params) {
|
|
33211
|
+
const { column } = params;
|
|
33212
|
+
const option = column.filters[0];
|
|
33213
|
+
filterDateRangeVal.option = option;
|
|
33214
|
+
}
|
|
33215
|
+
};
|
|
33216
|
+
const changeOptionEvent = () => {
|
|
33217
|
+
warningMsg.isShow = false;
|
|
33218
|
+
const { params } = props;
|
|
33219
|
+
const { option } = filterDateRangeVal;
|
|
33220
|
+
if (params && option) {
|
|
33221
|
+
const { $panel } = params;
|
|
33222
|
+
const checked = option.data[0] && option.data[1];
|
|
33223
|
+
if (checked && new Date(option.data[0]).getTime() > new Date(option.data[1]).getTime()) {
|
|
33224
|
+
warningMsg.isShow = true;
|
|
33225
|
+
return;
|
|
33226
|
+
}
|
|
33227
|
+
$panel.changeOption(null, checked, toRaw(option));
|
|
33228
|
+
}
|
|
33229
|
+
};
|
|
33230
|
+
load();
|
|
33231
|
+
return {
|
|
33232
|
+
filterDateRangeVal,
|
|
33233
|
+
changeOptionEvent,
|
|
33234
|
+
warningMsg
|
|
33235
|
+
};
|
|
33236
|
+
}
|
|
33237
|
+
});
|
|
33238
|
+
const _hoisted_1$8 = { class: "nv-flex" };
|
|
33239
|
+
const _hoisted_2$7 = /* @__PURE__ */ createElementVNode("span", null, "~", -1);
|
|
33240
|
+
const _hoisted_3$6 = {
|
|
33241
|
+
key: 0,
|
|
33242
|
+
style: { "font-size": "12px", "color": "#f00", "text-align": "center" }
|
|
33243
|
+
};
|
|
33244
|
+
function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
|
|
33245
|
+
const _component_vxe_input = resolveComponent("vxe-input");
|
|
33246
|
+
return openBlock(), createElementBlock("div", null, [
|
|
33247
|
+
createElementVNode("div", _hoisted_1$8, [
|
|
33248
|
+
_ctx.filterDateRangeVal.option.data && _ctx.filterDateRangeVal.option.data.length > 0 ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
33249
|
+
createVNode(_component_vxe_input, {
|
|
33250
|
+
modelValue: _ctx.filterDateRangeVal.option.data[0],
|
|
33251
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.filterDateRangeVal.option.data[0] = $event),
|
|
33252
|
+
placeholder: "开始日期",
|
|
33253
|
+
type: "date",
|
|
33254
|
+
style: { "width": "120px" },
|
|
33255
|
+
onChange: _ctx.changeOptionEvent
|
|
33256
|
+
}, null, 8, ["modelValue", "onChange"]),
|
|
33257
|
+
_hoisted_2$7,
|
|
33258
|
+
createVNode(_component_vxe_input, {
|
|
33259
|
+
modelValue: _ctx.filterDateRangeVal.option.data[1],
|
|
33260
|
+
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.filterDateRangeVal.option.data[1] = $event),
|
|
33261
|
+
placeholder: "结束日期",
|
|
33262
|
+
type: "date",
|
|
33263
|
+
style: { "width": "120px" },
|
|
33264
|
+
onChange: _ctx.changeOptionEvent
|
|
33265
|
+
}, null, 8, ["modelValue", "onChange"])
|
|
33266
|
+
], 64)) : createCommentVNode("", true)
|
|
33267
|
+
]),
|
|
33268
|
+
_ctx.warningMsg.isShow ? (openBlock(), createElementBlock("div", _hoisted_3$6, "起始时间不能大于结束时间")) : createCommentVNode("", true)
|
|
33269
|
+
]);
|
|
33270
|
+
}
|
|
33271
|
+
const FilterDaterange = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["render", _sfc_render$c]]);
|
|
33272
|
+
const CreatGridRenderer = () => {
|
|
33273
|
+
if (!VXETable.renderer.get("filterDaterange")) {
|
|
33274
|
+
VXETable.renderer.add("filterDaterange", {
|
|
33275
|
+
// 筛选模板
|
|
33276
|
+
renderFilter(renderOpts, params) {
|
|
33277
|
+
return h(FilterDaterange, { params });
|
|
33278
|
+
},
|
|
33279
|
+
// 重置数据方法
|
|
33280
|
+
filterResetMethod(params) {
|
|
33281
|
+
const { options: options2 } = params;
|
|
33282
|
+
options2.forEach((option) => {
|
|
33283
|
+
option.data = ["", ""];
|
|
33284
|
+
});
|
|
33285
|
+
},
|
|
33286
|
+
// 重置筛选复原方法(当未点击确认时,该选项将被恢复为默认值)
|
|
33287
|
+
filterRecoverMethod({ option }) {
|
|
33288
|
+
option.data = ["", ""];
|
|
33289
|
+
}
|
|
33290
|
+
});
|
|
33291
|
+
}
|
|
33292
|
+
};
|
|
33123
33293
|
const propDefine$l = {
|
|
33124
33294
|
option: {
|
|
33125
33295
|
// Gird 配置项
|
|
@@ -33146,6 +33316,10 @@ const propDefine$l = {
|
|
|
33146
33316
|
},
|
|
33147
33317
|
treeConfig: {
|
|
33148
33318
|
lazy: false
|
|
33319
|
+
},
|
|
33320
|
+
filterConfig: {
|
|
33321
|
+
remote: true
|
|
33322
|
+
//默认使用服务端筛选
|
|
33149
33323
|
}
|
|
33150
33324
|
}
|
|
33151
33325
|
})
|
|
@@ -33242,6 +33416,16 @@ let GridInstance$1 = class GridInstance2 extends BaseInstance {
|
|
|
33242
33416
|
this.props.option.event.event_search(searchData);
|
|
33243
33417
|
}
|
|
33244
33418
|
});
|
|
33419
|
+
/**
|
|
33420
|
+
* 合并行或列
|
|
33421
|
+
* @param param0
|
|
33422
|
+
* @returns
|
|
33423
|
+
*/
|
|
33424
|
+
__publicField2(this, "rowspanMethod", ({ row, _rowIndex, column, visibleData }) => {
|
|
33425
|
+
if (this.props.option.event && this.props.option.event.event_rowspanMethod) {
|
|
33426
|
+
return this.props.option.event.event_rowspanMethod({ row, _rowIndex, column, visibleData });
|
|
33427
|
+
}
|
|
33428
|
+
});
|
|
33245
33429
|
//#endregion 查询面板 End
|
|
33246
33430
|
/**
|
|
33247
33431
|
* 清除当前选中行
|
|
@@ -33463,8 +33647,12 @@ let GridInstance$1 = class GridInstance2 extends BaseInstance {
|
|
|
33463
33647
|
}
|
|
33464
33648
|
},
|
|
33465
33649
|
filterChange: (params) => {
|
|
33466
|
-
if (!this.utilities.isNull(this.props.option.event) && !this.utilities.isNull(this.props.option.event.
|
|
33467
|
-
|
|
33650
|
+
if (!this.utilities.isNull(this.props.option.event) && !this.utilities.isNull(this.props.option.event.event_filterChange)) {
|
|
33651
|
+
let filterData = {};
|
|
33652
|
+
params.filterList.map((e) => {
|
|
33653
|
+
filterData[e.field] = e.values && e.values[0] ? e.values.length == 1 ? e.values[0] : e.values : toRaw(e.datas[0]);
|
|
33654
|
+
});
|
|
33655
|
+
this.props.option.event.event_filterChange(filterData, params);
|
|
33468
33656
|
}
|
|
33469
33657
|
},
|
|
33470
33658
|
resizableChange: (params) => {
|
|
@@ -33588,6 +33776,15 @@ let GridInstance$1 = class GridInstance2 extends BaseInstance {
|
|
|
33588
33776
|
__publicField2(this, "getMenuConfig", () => {
|
|
33589
33777
|
return this.utilities.isNull(this.props.option.setting) ? {} : this.props.option.setting.menuConfig;
|
|
33590
33778
|
});
|
|
33779
|
+
/**
|
|
33780
|
+
* 获取表头筛选配置
|
|
33781
|
+
*/
|
|
33782
|
+
__publicField2(this, "getFilterConfig", () => {
|
|
33783
|
+
let defaultFilterConfig = { remote: true };
|
|
33784
|
+
let propFilterConfig = this.props.option.setting ? this.props.option.setting.filterConfig : {};
|
|
33785
|
+
propFilterConfig = propFilterConfig ? propFilterConfig : {};
|
|
33786
|
+
return this.utilities.isNull(this.props.option.setting) ? defaultFilterConfig : Object.assign(defaultFilterConfig, propFilterConfig);
|
|
33787
|
+
});
|
|
33591
33788
|
/**
|
|
33592
33789
|
* 校验规则配置项
|
|
33593
33790
|
* @returns
|
|
@@ -34159,6 +34356,7 @@ let GridInstance$1 = class GridInstance2 extends BaseInstance {
|
|
|
34159
34356
|
});
|
|
34160
34357
|
this.props = props;
|
|
34161
34358
|
this.ctx = ctx;
|
|
34359
|
+
CreatGridRenderer();
|
|
34162
34360
|
this.useSearchPanel();
|
|
34163
34361
|
this.useToolbar();
|
|
34164
34362
|
}
|
|
@@ -34278,8 +34476,8 @@ let GridInstance$1 = class GridInstance2 extends BaseInstance {
|
|
|
34278
34476
|
}
|
|
34279
34477
|
//#endregion 公开方法 END
|
|
34280
34478
|
};
|
|
34281
|
-
const
|
|
34282
|
-
const _withScopeId$1 = (n) => (pushScopeId("data-v-
|
|
34479
|
+
const Grid_vue_vue_type_style_index_0_scoped_18038d66_lang = "";
|
|
34480
|
+
const _withScopeId$1 = (n) => (pushScopeId("data-v-18038d66"), n = n(), popScopeId(), n);
|
|
34283
34481
|
const _hoisted_1$7 = { class: "nv-crud" };
|
|
34284
34482
|
const _hoisted_2$6 = { class: "nv-crud-body" };
|
|
34285
34483
|
const _hoisted_3$5 = { class: "nv-crud-body-search" };
|
|
@@ -34295,7 +34493,7 @@ const _hoisted_6$1 = {
|
|
|
34295
34493
|
class: "nv-crud-body-table",
|
|
34296
34494
|
ref: "crudTable"
|
|
34297
34495
|
};
|
|
34298
|
-
const _hoisted_7$1 = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("span", { class: "grid-msg" }, "
|
|
34496
|
+
const _hoisted_7$1 = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("span", { class: "grid-msg" }, "加载中去...", -1));
|
|
34299
34497
|
const _hoisted_8$1 = {
|
|
34300
34498
|
key: 0,
|
|
34301
34499
|
class: "nv-crud-footer"
|
|
@@ -34414,6 +34612,8 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
34414
34612
|
"tree-config": _ctx.getTreeConfig(),
|
|
34415
34613
|
"edit-rules": _ctx.getEditRules(),
|
|
34416
34614
|
"menu-config": _ctx.getMenuConfig(),
|
|
34615
|
+
"filter-config": _ctx.getFilterConfig(),
|
|
34616
|
+
"span-method": _ctx.rowspanMethod,
|
|
34417
34617
|
onKeydownStart: _ctx.gridEvents.keydownStart,
|
|
34418
34618
|
onKeydown: _ctx.gridEvents.keydown,
|
|
34419
34619
|
onKeydownEnd: _ctx.gridEvents.keydownEnd,
|
|
@@ -34461,7 +34661,7 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
34461
34661
|
}, null, 8, ["columns", "xTable", "onClearRadioRow", "onDelete", "onAddchild"])
|
|
34462
34662
|
]),
|
|
34463
34663
|
_: 1
|
|
34464
|
-
}, 16, ["data", "border", "show-header", "row-class-name", "cell-class-name", "row-config", "edit-config", "tree-config", "edit-rules", "menu-config", "onKeydownStart", "onKeydown", "onKeydownEnd", "onPaste", "onCopy", "onCut", "onCurrentChange", "onRadioChange", "onCheckboxChange", "onCheckboxAll", "onCheckboxRangeStart", "onCheckboxRangeChange", "onCheckboxRangeEnd", "onCellClick", "onCellDblclick", "onCellMenu", "onCellMouseenter", "onCellMouseleave", "onHeaderCellClick", "onHeaderCellDblclick", "onHeaderCellMenu", "onFooterCellClick", "onFooterCellDblclick", "onFooterCellMenu", "onSortChange", "onFilterChange", "onResizableChange", "onToggleRowExpand", "onToggleTreeExpand", "onMenuClick", "onEditClosed", "onEditActived", "onEditDisabled", "onValidError", "onScroll", "onCustom"]), [
|
|
34664
|
+
}, 16, ["data", "border", "show-header", "row-class-name", "cell-class-name", "row-config", "edit-config", "tree-config", "edit-rules", "menu-config", "filter-config", "span-method", "onKeydownStart", "onKeydown", "onKeydownEnd", "onPaste", "onCopy", "onCut", "onCurrentChange", "onRadioChange", "onCheckboxChange", "onCheckboxAll", "onCheckboxRangeStart", "onCheckboxRangeChange", "onCheckboxRangeEnd", "onCellClick", "onCellDblclick", "onCellMenu", "onCellMouseenter", "onCellMouseleave", "onHeaderCellClick", "onHeaderCellDblclick", "onHeaderCellMenu", "onFooterCellClick", "onFooterCellDblclick", "onFooterCellMenu", "onSortChange", "onFilterChange", "onResizableChange", "onToggleRowExpand", "onToggleTreeExpand", "onMenuClick", "onEditClosed", "onEditActived", "onEditDisabled", "onValidError", "onScroll", "onCustom"]), [
|
|
34465
34665
|
[vShow, _ctx.showTable]
|
|
34466
34666
|
])
|
|
34467
34667
|
], 512)
|
|
@@ -34479,7 +34679,7 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
34479
34679
|
])) : createCommentVNode("", true)
|
|
34480
34680
|
]);
|
|
34481
34681
|
}
|
|
34482
|
-
const Grid = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$b], ["__scopeId", "data-v-
|
|
34682
|
+
const Grid = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$b], ["__scopeId", "data-v-18038d66"]]);
|
|
34483
34683
|
const propDefine$k = {
|
|
34484
34684
|
width: {
|
|
34485
34685
|
// Box 宽度
|
|
@@ -211560,6 +211760,10 @@ const propDefine$7 = {
|
|
|
211560
211760
|
},
|
|
211561
211761
|
treeConfig: {
|
|
211562
211762
|
lazy: false
|
|
211763
|
+
},
|
|
211764
|
+
filterConfig: {
|
|
211765
|
+
remote: true
|
|
211766
|
+
//默认使用服务端筛选
|
|
211563
211767
|
}
|
|
211564
211768
|
}
|
|
211565
211769
|
})
|
|
@@ -211656,6 +211860,16 @@ class GridInstance extends BaseInstance {
|
|
|
211656
211860
|
this.props.option.event.event_search(searchData);
|
|
211657
211861
|
}
|
|
211658
211862
|
});
|
|
211863
|
+
/**
|
|
211864
|
+
* 合并行或列
|
|
211865
|
+
* @param param0
|
|
211866
|
+
* @returns
|
|
211867
|
+
*/
|
|
211868
|
+
__publicField2(this, "rowspanMethod", ({ row, _rowIndex, column, visibleData }) => {
|
|
211869
|
+
if (this.props.option.event && this.props.option.event.event_rowspanMethod) {
|
|
211870
|
+
return this.props.option.event.event_rowspanMethod({ row, _rowIndex, column, visibleData });
|
|
211871
|
+
}
|
|
211872
|
+
});
|
|
211659
211873
|
//#endregion 查询面板 End
|
|
211660
211874
|
/**
|
|
211661
211875
|
* 清除当前选中行
|
|
@@ -211877,8 +212091,12 @@ class GridInstance extends BaseInstance {
|
|
|
211877
212091
|
}
|
|
211878
212092
|
},
|
|
211879
212093
|
filterChange: (params) => {
|
|
211880
|
-
if (!this.utilities.isNull(this.props.option.event) && !this.utilities.isNull(this.props.option.event.
|
|
211881
|
-
|
|
212094
|
+
if (!this.utilities.isNull(this.props.option.event) && !this.utilities.isNull(this.props.option.event.event_filterChange)) {
|
|
212095
|
+
let filterData = {};
|
|
212096
|
+
params.filterList.map((e) => {
|
|
212097
|
+
filterData[e.field] = e.values && e.values[0] ? e.values.length == 1 ? e.values[0] : e.values : toRaw(e.datas[0]);
|
|
212098
|
+
});
|
|
212099
|
+
this.props.option.event.event_filterChange(filterData, params);
|
|
211882
212100
|
}
|
|
211883
212101
|
},
|
|
211884
212102
|
resizableChange: (params) => {
|
|
@@ -212002,6 +212220,15 @@ class GridInstance extends BaseInstance {
|
|
|
212002
212220
|
__publicField2(this, "getMenuConfig", () => {
|
|
212003
212221
|
return this.utilities.isNull(this.props.option.setting) ? {} : this.props.option.setting.menuConfig;
|
|
212004
212222
|
});
|
|
212223
|
+
/**
|
|
212224
|
+
* 获取表头筛选配置
|
|
212225
|
+
*/
|
|
212226
|
+
__publicField2(this, "getFilterConfig", () => {
|
|
212227
|
+
let defaultFilterConfig = { remote: true };
|
|
212228
|
+
let propFilterConfig = this.props.option.setting ? this.props.option.setting.filterConfig : {};
|
|
212229
|
+
propFilterConfig = propFilterConfig ? propFilterConfig : {};
|
|
212230
|
+
return this.utilities.isNull(this.props.option.setting) ? defaultFilterConfig : Object.assign(defaultFilterConfig, propFilterConfig);
|
|
212231
|
+
});
|
|
212005
212232
|
/**
|
|
212006
212233
|
* 校验规则配置项
|
|
212007
212234
|
* @returns
|
|
@@ -212573,6 +212800,7 @@ class GridInstance extends BaseInstance {
|
|
|
212573
212800
|
});
|
|
212574
212801
|
this.props = props;
|
|
212575
212802
|
this.ctx = ctx;
|
|
212803
|
+
CreatGridRenderer();
|
|
212576
212804
|
this.useSearchPanel();
|
|
212577
212805
|
this.useToolbar();
|
|
212578
212806
|
}
|