vxe-pc-ui 4.15.22 → 4.15.24
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/all.esm.js +369 -207
- package/dist/style.css +1 -1
- package/dist/style.min.css +1 -1
- package/es/cascader/src/cascader.js +1 -0
- package/es/date-panel/src/date-panel.js +35 -17
- package/es/date-panel/src/util.js +28 -1
- package/es/date-picker/src/date-picker.js +3 -1
- package/es/date-range-picker/src/date-range-picker.js +232 -131
- package/es/form/src/form.js +1 -0
- package/es/icon/style.css +1 -1
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/tooltip/src/tooltip.js +30 -18
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/cascader/src/cascader.js +1 -0
- package/lib/cascader/src/cascader.min.js +1 -1
- package/lib/date-panel/src/date-panel.js +48 -20
- package/lib/date-panel/src/date-panel.min.js +1 -1
- package/lib/date-panel/src/util.js +30 -2
- package/lib/date-panel/src/util.min.js +1 -1
- package/lib/date-picker/src/date-picker.js +3 -1
- package/lib/date-picker/src/date-picker.min.js +1 -1
- package/lib/date-range-picker/src/date-range-picker.js +254 -144
- package/lib/date-range-picker/src/date-range-picker.min.js +1 -1
- package/lib/form/src/form.js +1 -0
- package/lib/form/src/form.min.js +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/index.umd.js +370 -191
- package/lib/index.umd.min.js +1 -1
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/tooltip/src/tooltip.js +29 -17
- package/lib/tooltip/src/tooltip.min.js +1 -1
- package/lib/ui/index.js +1 -1
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/package.json +1 -1
- package/packages/cascader/src/cascader.ts +1 -0
- package/packages/date-panel/src/date-panel.ts +38 -18
- package/packages/date-panel/src/util.ts +30 -3
- package/packages/date-picker/src/date-picker.ts +4 -2
- package/packages/date-range-picker/src/date-range-picker.ts +231 -131
- package/packages/form/src/form.ts +1 -0
- package/packages/tooltip/src/tooltip.ts +33 -19
- package/types/components/date-panel.d.ts +14 -1
- package/types/components/date-range-picker.d.ts +5 -3
- package/types/components/tooltip.d.ts +1 -1
- package/types/ui/commands.d.ts +3 -3
- /package/es/icon/{iconfont.1783065896433.ttf → iconfont.1783233742355.ttf} +0 -0
- /package/es/icon/{iconfont.1783065896433.woff → iconfont.1783233742355.woff} +0 -0
- /package/es/icon/{iconfont.1783065896433.woff2 → iconfont.1783233742355.woff2} +0 -0
- /package/es/{iconfont.1783065896433.ttf → iconfont.1783233742355.ttf} +0 -0
- /package/es/{iconfont.1783065896433.woff → iconfont.1783233742355.woff} +0 -0
- /package/es/{iconfont.1783065896433.woff2 → iconfont.1783233742355.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1783065896433.ttf → iconfont.1783233742355.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1783065896433.woff → iconfont.1783233742355.woff} +0 -0
- /package/lib/icon/style/{iconfont.1783065896433.woff2 → iconfont.1783233742355.woff2} +0 -0
- /package/lib/{iconfont.1783065896433.ttf → iconfont.1783233742355.ttf} +0 -0
- /package/lib/{iconfont.1783065896433.woff → iconfont.1783233742355.woff} +0 -0
- /package/lib/{iconfont.1783065896433.woff2 → iconfont.1783233742355.woff2} +0 -0
package/dist/all.esm.js
CHANGED
|
@@ -81,7 +81,7 @@ function checkDynamic() {
|
|
|
81
81
|
}
|
|
82
82
|
|
|
83
83
|
const { log } = VxeUI;
|
|
84
|
-
const uiVersion = `ui v${"4.15.
|
|
84
|
+
const uiVersion = `ui v${"4.15.24"}`;
|
|
85
85
|
function createComponentLog(name) {
|
|
86
86
|
const tableVersion = VxeUI.tableVersion ? `table v${VxeUI.tableVersion}` : '';
|
|
87
87
|
const ganttVersion = VxeUI.ganttVersion ? `gantt v${VxeUI.ganttVersion}` : '';
|
|
@@ -95,7 +95,7 @@ function createComponentLog(name) {
|
|
|
95
95
|
const warnLog$g = log.create('warn', uiVersion);
|
|
96
96
|
log.create('error', uiVersion);
|
|
97
97
|
|
|
98
|
-
const version = "4.15.
|
|
98
|
+
const version = "4.15.24";
|
|
99
99
|
VxeUI.uiVersion = version;
|
|
100
100
|
VxeUI.dynamicApp = dynamicApp;
|
|
101
101
|
function config(options) {
|
|
@@ -2545,6 +2545,28 @@ function deModelValue(nodeid) {
|
|
|
2545
2545
|
return nodeid ? decodeURIComponent(`${nodeid}`) : nodeid;
|
|
2546
2546
|
}
|
|
2547
2547
|
|
|
2548
|
+
function createReactData$l() {
|
|
2549
|
+
return {
|
|
2550
|
+
target: null,
|
|
2551
|
+
isUpdate: false,
|
|
2552
|
+
visible: false,
|
|
2553
|
+
tipPos: null,
|
|
2554
|
+
tipContent: '',
|
|
2555
|
+
tipActive: false,
|
|
2556
|
+
tipTarget: null,
|
|
2557
|
+
tipZindex: 0,
|
|
2558
|
+
tipStore: {
|
|
2559
|
+
style: {},
|
|
2560
|
+
placement: '',
|
|
2561
|
+
arrowStyle: {}
|
|
2562
|
+
}
|
|
2563
|
+
};
|
|
2564
|
+
}
|
|
2565
|
+
function createInternalData$k() {
|
|
2566
|
+
return {
|
|
2567
|
+
// showDelayTip: undefined
|
|
2568
|
+
};
|
|
2569
|
+
}
|
|
2548
2570
|
var VxeTooltipComponent = defineVxeComponent({
|
|
2549
2571
|
name: 'VxeTooltip',
|
|
2550
2572
|
props: {
|
|
@@ -2633,22 +2655,8 @@ var VxeTooltipComponent = defineVxeComponent({
|
|
|
2633
2655
|
const { slots, emit } = context;
|
|
2634
2656
|
const xID = XEUtils.uniqueId();
|
|
2635
2657
|
const { computeSize } = useSize(props);
|
|
2636
|
-
const reactData = reactive(
|
|
2637
|
-
|
|
2638
|
-
isUpdate: false,
|
|
2639
|
-
visible: false,
|
|
2640
|
-
tipPos: null,
|
|
2641
|
-
tipContent: '',
|
|
2642
|
-
tipActive: false,
|
|
2643
|
-
tipTarget: null,
|
|
2644
|
-
tipZindex: 0,
|
|
2645
|
-
tipStore: {
|
|
2646
|
-
style: {},
|
|
2647
|
-
placement: '',
|
|
2648
|
-
arrowStyle: {}
|
|
2649
|
-
}
|
|
2650
|
-
});
|
|
2651
|
-
const internalData = {};
|
|
2658
|
+
const reactData = reactive(createReactData$l());
|
|
2659
|
+
const internalData = createInternalData$k();
|
|
2652
2660
|
const refElem = ref();
|
|
2653
2661
|
const contentWrapperfElem = ref();
|
|
2654
2662
|
const computeWrapperStyle = computed(() => {
|
|
@@ -3032,6 +3040,7 @@ var VxeTooltipComponent = defineVxeComponent({
|
|
|
3032
3040
|
}
|
|
3033
3041
|
reactData.isUpdate = false;
|
|
3034
3042
|
});
|
|
3043
|
+
handleDelayFn();
|
|
3035
3044
|
onMounted(() => {
|
|
3036
3045
|
const contentWrapperfEl = contentWrapperfElem.value;
|
|
3037
3046
|
if (contentWrapperfEl) {
|
|
@@ -3090,7 +3099,10 @@ var VxeTooltipComponent = defineVxeComponent({
|
|
|
3090
3099
|
}
|
|
3091
3100
|
}
|
|
3092
3101
|
});
|
|
3093
|
-
|
|
3102
|
+
onUnmounted(() => {
|
|
3103
|
+
XEUtils.assign(reactData, createReactData$l());
|
|
3104
|
+
XEUtils.assign(internalData, createInternalData$k());
|
|
3105
|
+
});
|
|
3094
3106
|
$xeTooltip.renderVN = renderVN;
|
|
3095
3107
|
return $xeTooltip;
|
|
3096
3108
|
},
|
|
@@ -3855,12 +3867,12 @@ VxeUI.component(VxeButtonComponent);
|
|
|
3855
3867
|
const Button = VxeButton;
|
|
3856
3868
|
|
|
3857
3869
|
const { errLog: errLog$h } = createComponentLog('backtop');
|
|
3858
|
-
function createInternalData$
|
|
3870
|
+
function createInternalData$j() {
|
|
3859
3871
|
return {
|
|
3860
3872
|
targetEl: null
|
|
3861
3873
|
};
|
|
3862
3874
|
}
|
|
3863
|
-
function createReactData$
|
|
3875
|
+
function createReactData$k() {
|
|
3864
3876
|
return {
|
|
3865
3877
|
showBtn: false,
|
|
3866
3878
|
backtopZindex: 0
|
|
@@ -3939,8 +3951,8 @@ var VxeBacktopComponent = defineVxeComponent({
|
|
|
3939
3951
|
const xID = XEUtils.uniqueId();
|
|
3940
3952
|
const refElem = ref();
|
|
3941
3953
|
const { computeSize } = useSize(props);
|
|
3942
|
-
const internalData = createInternalData$
|
|
3943
|
-
const reactData = reactive(createReactData$
|
|
3954
|
+
const internalData = createInternalData$j();
|
|
3955
|
+
const reactData = reactive(createReactData$k());
|
|
3944
3956
|
const refMaps = {
|
|
3945
3957
|
refElem
|
|
3946
3958
|
};
|
|
@@ -4117,8 +4129,8 @@ var VxeBacktopComponent = defineVxeComponent({
|
|
|
4117
4129
|
});
|
|
4118
4130
|
onBeforeUnmount(() => {
|
|
4119
4131
|
removeScrollEvent();
|
|
4120
|
-
XEUtils.assign(reactData, createReactData$
|
|
4121
|
-
XEUtils.assign(internalData, createInternalData$
|
|
4132
|
+
XEUtils.assign(reactData, createReactData$k());
|
|
4133
|
+
XEUtils.assign(internalData, createInternalData$j());
|
|
4122
4134
|
});
|
|
4123
4135
|
$xeBacktop.renderVN = renderVN;
|
|
4124
4136
|
return $xeBacktop;
|
|
@@ -4560,7 +4572,7 @@ function parseDateValue(val, type, options) {
|
|
|
4560
4572
|
const { valueFormat } = options;
|
|
4561
4573
|
if (val) {
|
|
4562
4574
|
if (type === 'time') {
|
|
4563
|
-
return toStringTimeDate(val);
|
|
4575
|
+
return toStringTimeDate(XEUtils.isArray(val) ? val : XEUtils.last(val));
|
|
4564
4576
|
}
|
|
4565
4577
|
if (XEUtils.isNumber(val) || /^[0-9]{10,15}$/.test(`${val}`)) {
|
|
4566
4578
|
return new Date(Number(val));
|
|
@@ -4568,6 +4580,9 @@ function parseDateValue(val, type, options) {
|
|
|
4568
4580
|
if (XEUtils.isString(val)) {
|
|
4569
4581
|
return XEUtils.toStringDate(XEUtils.last(val.split(',')), valueFormat);
|
|
4570
4582
|
}
|
|
4583
|
+
if (XEUtils.isArray(val)) {
|
|
4584
|
+
return XEUtils.toStringDate(XEUtils.last(val), valueFormat);
|
|
4585
|
+
}
|
|
4571
4586
|
return XEUtils.toStringDate(val, valueFormat);
|
|
4572
4587
|
}
|
|
4573
4588
|
return null;
|
|
@@ -4738,6 +4753,30 @@ function checkDateInputFormat(numStr, formatKey) {
|
|
|
4738
4753
|
}
|
|
4739
4754
|
return numVal;
|
|
4740
4755
|
}
|
|
4756
|
+
const getPrevMonth = (date) => {
|
|
4757
|
+
const currtYear = date.getFullYear();
|
|
4758
|
+
const currMonth = date.getMonth();
|
|
4759
|
+
if (currMonth) {
|
|
4760
|
+
date.setMonth(currMonth - 1);
|
|
4761
|
+
}
|
|
4762
|
+
else {
|
|
4763
|
+
date.setFullYear(currtYear - 1);
|
|
4764
|
+
date.setMonth(11);
|
|
4765
|
+
}
|
|
4766
|
+
return date;
|
|
4767
|
+
};
|
|
4768
|
+
const getNextMonth = (date) => {
|
|
4769
|
+
const currtYear = date.getFullYear();
|
|
4770
|
+
const currMonth = date.getMonth();
|
|
4771
|
+
if (currMonth < 11) {
|
|
4772
|
+
date.setMonth(currMonth + 1);
|
|
4773
|
+
}
|
|
4774
|
+
else {
|
|
4775
|
+
date.setFullYear(currtYear + 1);
|
|
4776
|
+
date.setMonth(0);
|
|
4777
|
+
}
|
|
4778
|
+
return date;
|
|
4779
|
+
};
|
|
4741
4780
|
|
|
4742
4781
|
const { errLog: errLog$g } = createComponentLog('calendar');
|
|
4743
4782
|
const { menus: menus$2, getConfig: getConfig$2, getI18n: getI18n$1 } = VxeUI;
|
|
@@ -6831,7 +6870,7 @@ function getRowIdByField(row, keyField) {
|
|
|
6831
6870
|
const rowKey = getRowKeyByField(row, keyField);
|
|
6832
6871
|
return enModelValue(rowKey);
|
|
6833
6872
|
}
|
|
6834
|
-
function createReactData$
|
|
6873
|
+
function createReactData$j() {
|
|
6835
6874
|
return {
|
|
6836
6875
|
scrollYLoad: false,
|
|
6837
6876
|
bodyHeight: 0,
|
|
@@ -6851,7 +6890,7 @@ function createReactData$i() {
|
|
|
6851
6890
|
dragTipText: ''
|
|
6852
6891
|
};
|
|
6853
6892
|
}
|
|
6854
|
-
function createInternalData$
|
|
6893
|
+
function createInternalData$i() {
|
|
6855
6894
|
return {
|
|
6856
6895
|
resizeObserver: undefined,
|
|
6857
6896
|
fullData: [],
|
|
@@ -6924,8 +6963,8 @@ var VxeListComponent = defineVxeComponent({
|
|
|
6924
6963
|
const xID = XEUtils.uniqueId();
|
|
6925
6964
|
const browseObj = XEUtils.browse();
|
|
6926
6965
|
const { computeSize } = useSize(props);
|
|
6927
|
-
const reactData = reactive(createReactData$
|
|
6928
|
-
const internalData = createInternalData$
|
|
6966
|
+
const reactData = reactive(createReactData$j());
|
|
6967
|
+
const internalData = createInternalData$i();
|
|
6929
6968
|
const crossListDragRowInfo = getCrossListDragRowInfo();
|
|
6930
6969
|
const refElem = ref();
|
|
6931
6970
|
const refHeaderElem = ref();
|
|
@@ -8347,8 +8386,8 @@ var VxeListComponent = defineVxeComponent({
|
|
|
8347
8386
|
resizeObserver.disconnect();
|
|
8348
8387
|
}
|
|
8349
8388
|
globalEvents.off($xeList, 'resize');
|
|
8350
|
-
XEUtils.assign(reactData, createReactData$
|
|
8351
|
-
XEUtils.assign(internalData, createInternalData$
|
|
8389
|
+
XEUtils.assign(reactData, createReactData$j());
|
|
8390
|
+
XEUtils.assign(internalData, createInternalData$i());
|
|
8352
8391
|
});
|
|
8353
8392
|
$xeList.renderVN = renderVN;
|
|
8354
8393
|
return $xeList;
|
|
@@ -11079,7 +11118,7 @@ const Input = VxeInput;
|
|
|
11079
11118
|
function getNodeUniqueId$1() {
|
|
11080
11119
|
return XEUtils.uniqueId('node_');
|
|
11081
11120
|
}
|
|
11082
|
-
function createReactData$
|
|
11121
|
+
function createReactData$i() {
|
|
11083
11122
|
return {
|
|
11084
11123
|
initialized: false,
|
|
11085
11124
|
searchValue: '',
|
|
@@ -11102,7 +11141,7 @@ function createReactData$h() {
|
|
|
11102
11141
|
lazyOptFlag: 1
|
|
11103
11142
|
};
|
|
11104
11143
|
}
|
|
11105
|
-
function createInternalData$
|
|
11144
|
+
function createInternalData$h() {
|
|
11106
11145
|
return {
|
|
11107
11146
|
// hpTimeout: undefined,
|
|
11108
11147
|
listVirtualYOpts: {
|
|
@@ -11229,8 +11268,8 @@ var VxeCascaderComponent = defineVxeComponent({
|
|
|
11229
11268
|
const refInpSearch = ref();
|
|
11230
11269
|
const refChunkWrapper = ref();
|
|
11231
11270
|
const refOptionPanel = ref();
|
|
11232
|
-
const reactData = reactive(createReactData$
|
|
11233
|
-
const internalData = createInternalData$
|
|
11271
|
+
const reactData = reactive(createReactData$i());
|
|
11272
|
+
const internalData = createInternalData$h();
|
|
11234
11273
|
const refMaps = {
|
|
11235
11274
|
refElem
|
|
11236
11275
|
};
|
|
@@ -12802,7 +12841,8 @@ var VxeCascaderComponent = defineVxeComponent({
|
|
|
12802
12841
|
globalEvents.off($xeCascader, 'mousedown');
|
|
12803
12842
|
globalEvents.off($xeCascader, 'blur');
|
|
12804
12843
|
globalEvents.off($xeCascader, 'resize');
|
|
12805
|
-
XEUtils.assign(
|
|
12844
|
+
XEUtils.assign(reactData, createReactData$i());
|
|
12845
|
+
XEUtils.assign(internalData, createInternalData$h());
|
|
12806
12846
|
});
|
|
12807
12847
|
provide('$xeCascader', $xeCascader);
|
|
12808
12848
|
$xeCascader.renderVN = renderVN;
|
|
@@ -13206,10 +13246,10 @@ dynamicApp.use(VxeCheckboxButton);
|
|
|
13206
13246
|
VxeUI.component(VxeCheckboxButtonComponent);
|
|
13207
13247
|
const CheckboxButton = VxeCheckboxButton;
|
|
13208
13248
|
|
|
13209
|
-
function createReactData$
|
|
13249
|
+
function createReactData$h() {
|
|
13210
13250
|
return {};
|
|
13211
13251
|
}
|
|
13212
|
-
function createInternalData$
|
|
13252
|
+
function createInternalData$g() {
|
|
13213
13253
|
return {
|
|
13214
13254
|
// isLoaded: false
|
|
13215
13255
|
};
|
|
@@ -13252,8 +13292,8 @@ var VxeCheckboxGroupComponent = defineVxeComponent({
|
|
|
13252
13292
|
const $xeForm = inject('$xeForm', null);
|
|
13253
13293
|
const formItemInfo = inject('xeFormItemInfo', null);
|
|
13254
13294
|
const xID = XEUtils.uniqueId();
|
|
13255
|
-
const reactData = reactive(createReactData$
|
|
13256
|
-
const internalData = createInternalData$
|
|
13295
|
+
const reactData = reactive(createReactData$h());
|
|
13296
|
+
const internalData = createInternalData$g();
|
|
13257
13297
|
const computeIsReadonly = computed(() => {
|
|
13258
13298
|
const { readonly } = props;
|
|
13259
13299
|
if (readonly === null) {
|
|
@@ -13425,8 +13465,8 @@ var VxeCheckboxGroupComponent = defineVxeComponent({
|
|
|
13425
13465
|
});
|
|
13426
13466
|
});
|
|
13427
13467
|
onUnmounted(() => {
|
|
13428
|
-
XEUtils.assign(reactData, createReactData$
|
|
13429
|
-
XEUtils.assign(internalData, createInternalData$
|
|
13468
|
+
XEUtils.assign(reactData, createReactData$h());
|
|
13469
|
+
XEUtils.assign(internalData, createInternalData$g());
|
|
13430
13470
|
});
|
|
13431
13471
|
provide('$xeCheckboxGroup', $xeCheckboxGroup);
|
|
13432
13472
|
$xeCheckboxGroup.renderVN = renderVN;
|
|
@@ -13559,7 +13599,7 @@ dynamicApp.use(VxeCol);
|
|
|
13559
13599
|
VxeUI.component(VxeColComponent);
|
|
13560
13600
|
const Col = VxeCol;
|
|
13561
13601
|
|
|
13562
|
-
function createReactData$
|
|
13602
|
+
function createReactData$g() {
|
|
13563
13603
|
return {
|
|
13564
13604
|
staticPanes: [],
|
|
13565
13605
|
cachePaneMaps: {},
|
|
@@ -13567,7 +13607,7 @@ function createReactData$f() {
|
|
|
13567
13607
|
openKeyFlag: 0
|
|
13568
13608
|
};
|
|
13569
13609
|
}
|
|
13570
|
-
function createInternalData$
|
|
13610
|
+
function createInternalData$f() {
|
|
13571
13611
|
return {
|
|
13572
13612
|
// esTime: null,
|
|
13573
13613
|
activeKeyMaps: {},
|
|
@@ -13604,8 +13644,8 @@ var VxeCollapseComponent = defineVxeComponent({
|
|
|
13604
13644
|
const xID = XEUtils.uniqueId();
|
|
13605
13645
|
const { computeSize } = useSize(props);
|
|
13606
13646
|
const refElem = ref();
|
|
13607
|
-
const reactData = reactive(createReactData$
|
|
13608
|
-
const internalData = createInternalData$
|
|
13647
|
+
const reactData = reactive(createReactData$g());
|
|
13648
|
+
const internalData = createInternalData$f();
|
|
13609
13649
|
const refMaps = {
|
|
13610
13650
|
refElem
|
|
13611
13651
|
};
|
|
@@ -13884,8 +13924,8 @@ var VxeCollapseComponent = defineVxeComponent({
|
|
|
13884
13924
|
if (esTime) {
|
|
13885
13925
|
clearTimeout(esTime);
|
|
13886
13926
|
}
|
|
13887
|
-
XEUtils.assign(reactData, createReactData$
|
|
13888
|
-
XEUtils.assign(internalData, createInternalData$
|
|
13927
|
+
XEUtils.assign(reactData, createReactData$g());
|
|
13928
|
+
XEUtils.assign(internalData, createInternalData$f());
|
|
13889
13929
|
});
|
|
13890
13930
|
provide('$xeCollapse', $xeCollapse);
|
|
13891
13931
|
$xeCollapse.renderVN = renderVN;
|
|
@@ -16270,12 +16310,12 @@ dynamicApp.use(VxeColorPicker);
|
|
|
16270
16310
|
VxeUI.component(VxeColorPickerComponent);
|
|
16271
16311
|
const ColorPicker = VxeColorPicker;
|
|
16272
16312
|
|
|
16273
|
-
function createInternalData$
|
|
16313
|
+
function createInternalData$e() {
|
|
16274
16314
|
return {
|
|
16275
16315
|
// leaveTime: null
|
|
16276
16316
|
};
|
|
16277
16317
|
}
|
|
16278
|
-
function createReactData$
|
|
16318
|
+
function createReactData$f() {
|
|
16279
16319
|
return {
|
|
16280
16320
|
visible: false,
|
|
16281
16321
|
activeOption: null,
|
|
@@ -16330,8 +16370,8 @@ var VxeContextMenuComponent = defineVxeComponent({
|
|
|
16330
16370
|
const xID = XEUtils.uniqueId();
|
|
16331
16371
|
const refElem = ref();
|
|
16332
16372
|
const { computeSize } = useSize(props);
|
|
16333
|
-
const internalData = createInternalData$
|
|
16334
|
-
const reactData = reactive(createReactData$
|
|
16373
|
+
const internalData = createInternalData$e();
|
|
16374
|
+
const reactData = reactive(createReactData$f());
|
|
16335
16375
|
const refMaps = {
|
|
16336
16376
|
refElem
|
|
16337
16377
|
};
|
|
@@ -16886,8 +16926,8 @@ var VxeContextMenuComponent = defineVxeComponent({
|
|
|
16886
16926
|
globalEvents.off($xeContextMenu, 'keydown');
|
|
16887
16927
|
globalEvents.off($xeContextMenu, 'mousedown');
|
|
16888
16928
|
globalEvents.off($xeContextMenu, 'blur');
|
|
16889
|
-
XEUtils.assign(reactData, createReactData$
|
|
16890
|
-
XEUtils.assign(internalData, createInternalData$
|
|
16929
|
+
XEUtils.assign(reactData, createReactData$f());
|
|
16930
|
+
XEUtils.assign(internalData, createInternalData$e());
|
|
16891
16931
|
});
|
|
16892
16932
|
$xeContextMenu.renderVN = renderVN;
|
|
16893
16933
|
return $xeContextMenu;
|
|
@@ -17393,7 +17433,7 @@ const Countdown = VxeCountdown;
|
|
|
17393
17433
|
var VxeDatePanelComponent = defineVxeComponent({
|
|
17394
17434
|
name: 'VxeDatePanel',
|
|
17395
17435
|
props: {
|
|
17396
|
-
modelValue: [String, Number, Date],
|
|
17436
|
+
modelValue: [String, Number, Date, Array],
|
|
17397
17437
|
type: {
|
|
17398
17438
|
type: String,
|
|
17399
17439
|
default: 'date'
|
|
@@ -17418,6 +17458,7 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
17418
17458
|
type: [String, Number, Date],
|
|
17419
17459
|
default: () => getConfig$3().datePanel.endDate
|
|
17420
17460
|
},
|
|
17461
|
+
defaultMode: String,
|
|
17421
17462
|
defaultDate: [String, Number, Date],
|
|
17422
17463
|
defaultTime: [String, Number, Date],
|
|
17423
17464
|
minDate: [String, Number, Date],
|
|
@@ -17429,6 +17470,7 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
17429
17470
|
labelFormat: String,
|
|
17430
17471
|
valueFormat: String,
|
|
17431
17472
|
timeFormat: String,
|
|
17473
|
+
valueSort: Boolean,
|
|
17432
17474
|
festivalMethod: {
|
|
17433
17475
|
type: Function,
|
|
17434
17476
|
default: () => getConfig$3().datePanel.festivalMethod
|
|
@@ -17507,10 +17549,10 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
17507
17549
|
return props.endDate ? XEUtils.toStringDate(props.endDate) : null;
|
|
17508
17550
|
});
|
|
17509
17551
|
const computeDateListValue = computed(() => {
|
|
17510
|
-
const { modelValue
|
|
17552
|
+
const { modelValue } = props;
|
|
17511
17553
|
const isDatePanelType = computeIsDatePanelType.value;
|
|
17512
17554
|
const dateValueFormat = computeDateValueFormat.value;
|
|
17513
|
-
if (
|
|
17555
|
+
if (modelValue && isDatePanelType) {
|
|
17514
17556
|
return XEUtils.toValueString(modelValue).split(',').map(item => {
|
|
17515
17557
|
const date = parseDate(item, dateValueFormat);
|
|
17516
17558
|
if (XEUtils.isValidDate(date)) {
|
|
@@ -17551,12 +17593,14 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
17551
17593
|
return handleValueFormat(type, valueFormat);
|
|
17552
17594
|
});
|
|
17553
17595
|
const computeDateValue = computed(() => {
|
|
17554
|
-
const { modelValue } = props;
|
|
17596
|
+
const { modelValue, defaultMode } = props;
|
|
17555
17597
|
const isDatePanelType = computeIsDatePanelType.value;
|
|
17556
17598
|
const dateValueFormat = computeDateValueFormat.value;
|
|
17557
17599
|
let val = null;
|
|
17558
17600
|
if (modelValue && isDatePanelType) {
|
|
17559
|
-
const
|
|
17601
|
+
const vals = XEUtils.isString(modelValue) ? modelValue.split(',') : modelValue;
|
|
17602
|
+
const currVal = defaultMode === 'last' ? XEUtils.last(vals) : XEUtils.first(vals);
|
|
17603
|
+
const date = parseDate(currVal, dateValueFormat);
|
|
17560
17604
|
if (XEUtils.isValidDate(date)) {
|
|
17561
17605
|
val = date;
|
|
17562
17606
|
}
|
|
@@ -17950,10 +17994,10 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
17950
17994
|
const parseDate = (value, format) => {
|
|
17951
17995
|
const { type, multiple } = props;
|
|
17952
17996
|
if (type === 'time') {
|
|
17953
|
-
return toStringTimeDate(value);
|
|
17997
|
+
return toStringTimeDate(XEUtils.isArray(value) ? value : XEUtils.last(value));
|
|
17954
17998
|
}
|
|
17955
17999
|
if (XEUtils.isArray(value)) {
|
|
17956
|
-
return XEUtils.toStringDate(value
|
|
18000
|
+
return XEUtils.toStringDate(XEUtils.last(value), format);
|
|
17957
18001
|
}
|
|
17958
18002
|
if (XEUtils.isString(value)) {
|
|
17959
18003
|
return XEUtils.toStringDate(multiple ? XEUtils.last(value.split(',')) : value, format);
|
|
@@ -18022,7 +18066,7 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18022
18066
|
reactData.inputValue = value;
|
|
18023
18067
|
emit('update:modelValue', value);
|
|
18024
18068
|
};
|
|
18025
|
-
const handleChange = (value, evnt) => {
|
|
18069
|
+
const handleChange = (value, evnt, params) => {
|
|
18026
18070
|
const { type, modelValue, valueFormat } = props;
|
|
18027
18071
|
const dateValueFormat = computeDateValueFormat.value;
|
|
18028
18072
|
reactData.inputLabel = value;
|
|
@@ -18031,20 +18075,20 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18031
18075
|
const timeNum = dateVal ? dateVal.getTime() : null;
|
|
18032
18076
|
emitModel(timeNum);
|
|
18033
18077
|
if (modelValue !== timeNum) {
|
|
18034
|
-
dispatchEvent('change', { value: timeNum }, evnt);
|
|
18078
|
+
dispatchEvent('change', { value: timeNum, currValue: params ? params.currValue : '' }, evnt);
|
|
18035
18079
|
}
|
|
18036
18080
|
}
|
|
18037
18081
|
else if (hasDateValueType(valueFormat)) {
|
|
18038
18082
|
const dateVal = parseDateValue(value, type, { valueFormat: dateValueFormat });
|
|
18039
18083
|
emitModel(dateVal);
|
|
18040
18084
|
if (modelValue && dateVal ? XEUtils.toStringDate(modelValue).getTime() !== dateVal.getTime() : modelValue !== dateVal) {
|
|
18041
|
-
dispatchEvent('change', { value: dateVal }, evnt);
|
|
18085
|
+
dispatchEvent('change', { value: dateVal, currValue: params ? params.currValue : '' }, evnt);
|
|
18042
18086
|
}
|
|
18043
18087
|
}
|
|
18044
18088
|
else {
|
|
18045
18089
|
emitModel(value);
|
|
18046
18090
|
if (XEUtils.toValueString(modelValue) !== value) {
|
|
18047
|
-
dispatchEvent('change', { value }, evnt);
|
|
18091
|
+
dispatchEvent('change', { value, currValue: params ? params.currValue : '' }, evnt);
|
|
18048
18092
|
}
|
|
18049
18093
|
}
|
|
18050
18094
|
};
|
|
@@ -18102,7 +18146,7 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18102
18146
|
}
|
|
18103
18147
|
};
|
|
18104
18148
|
const dateChange = (date, isReload) => {
|
|
18105
|
-
const { modelValue, multiple } = props;
|
|
18149
|
+
const { modelValue, multiple, valueSort } = props;
|
|
18106
18150
|
const { datetimePanelValue } = reactData;
|
|
18107
18151
|
const isDateTimeType = computeIsDateTimeType.value;
|
|
18108
18152
|
const dateValueFormat = computeDateValueFormat.value;
|
|
@@ -18126,7 +18170,7 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18126
18170
|
if (isDateTimeType) {
|
|
18127
18171
|
// 如果是datetime特殊类型
|
|
18128
18172
|
const dateListValue = isReload ? [] : [...computeDateListValue.value];
|
|
18129
|
-
|
|
18173
|
+
let datetimeRest = [];
|
|
18130
18174
|
const eqIndex = XEUtils.findIndexOf(dateListValue, val => XEUtils.isDateSame(date, val, 'yyyyMMdd'));
|
|
18131
18175
|
if (eqIndex === -1) {
|
|
18132
18176
|
if (overCount) {
|
|
@@ -18148,27 +18192,37 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18148
18192
|
datetimeRest.push(item);
|
|
18149
18193
|
}
|
|
18150
18194
|
});
|
|
18151
|
-
|
|
18195
|
+
// 排序
|
|
18196
|
+
if (valueSort) {
|
|
18197
|
+
datetimeRest = datetimeRest.sort((a, b) => a.getTime() - b.getTime());
|
|
18198
|
+
}
|
|
18199
|
+
handleChange(datetimeRest.map(date => XEUtils.toDateString(date, dateValueFormat)).join(','), { type: 'update' }, { currValue: inpVal });
|
|
18152
18200
|
}
|
|
18153
18201
|
else {
|
|
18154
18202
|
const dateMultipleValue = isReload ? [] : computeDateMultipleValue.value;
|
|
18203
|
+
let dateRest = [];
|
|
18155
18204
|
// 如果是日期类型
|
|
18156
18205
|
if (dateMultipleValue.some(val => XEUtils.isEqual(val, inpVal))) {
|
|
18157
|
-
|
|
18206
|
+
dateRest = dateMultipleValue.filter(val => !XEUtils.isEqual(val, inpVal));
|
|
18158
18207
|
}
|
|
18159
18208
|
else {
|
|
18160
18209
|
if (overCount) {
|
|
18161
18210
|
// 如果超出最大多选数量
|
|
18162
18211
|
return;
|
|
18163
18212
|
}
|
|
18164
|
-
|
|
18213
|
+
dateRest = dateMultipleValue.concat([inpVal]);
|
|
18165
18214
|
}
|
|
18215
|
+
// 排序
|
|
18216
|
+
if (valueSort) {
|
|
18217
|
+
dateRest = dateRest.sort();
|
|
18218
|
+
}
|
|
18219
|
+
handleChange(dateRest.join(','), { type: 'update' }, { currValue: inpVal });
|
|
18166
18220
|
}
|
|
18167
18221
|
}
|
|
18168
18222
|
else {
|
|
18169
18223
|
// 如果为单选
|
|
18170
18224
|
if (!XEUtils.isEqual(modelValue, inpVal)) {
|
|
18171
|
-
handleChange(inpVal, { type: 'update' });
|
|
18225
|
+
handleChange(inpVal, { type: 'update' }, { currValue: inpVal });
|
|
18172
18226
|
}
|
|
18173
18227
|
}
|
|
18174
18228
|
};
|
|
@@ -18563,6 +18617,10 @@ var VxeDatePanelComponent = defineVxeComponent({
|
|
|
18563
18617
|
getModelValue() {
|
|
18564
18618
|
return reactData.inputValue;
|
|
18565
18619
|
},
|
|
18620
|
+
getViewType() {
|
|
18621
|
+
const { datePanelType } = reactData;
|
|
18622
|
+
return datePanelType;
|
|
18623
|
+
},
|
|
18566
18624
|
setPanelDate(date) {
|
|
18567
18625
|
if (date) {
|
|
18568
18626
|
dateCheckMonth(date);
|
|
@@ -19161,7 +19219,7 @@ const parseInputKayMaps = {};
|
|
|
19161
19219
|
inputMaskedKeys.forEach(key => {
|
|
19162
19220
|
parseInputKayMaps[key] = true;
|
|
19163
19221
|
});
|
|
19164
|
-
function createReactData$
|
|
19222
|
+
function createReactData$e() {
|
|
19165
19223
|
return {
|
|
19166
19224
|
initialized: false,
|
|
19167
19225
|
panelIndex: 0,
|
|
@@ -19174,7 +19232,7 @@ function createReactData$d() {
|
|
|
19174
19232
|
labelFlag: 0
|
|
19175
19233
|
};
|
|
19176
19234
|
}
|
|
19177
|
-
function createInternalData$
|
|
19235
|
+
function createInternalData$d() {
|
|
19178
19236
|
return {
|
|
19179
19237
|
// hpTimeout: undefined,
|
|
19180
19238
|
// fsTimeout: undefined,
|
|
@@ -19314,8 +19372,8 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
19314
19372
|
const formItemInfo = inject('xeFormItemInfo', null);
|
|
19315
19373
|
const xID = XEUtils.uniqueId();
|
|
19316
19374
|
const { computeSize } = useSize(props);
|
|
19317
|
-
const reactData = reactive(createReactData$
|
|
19318
|
-
const internalData = createInternalData$
|
|
19375
|
+
const reactData = reactive(createReactData$e());
|
|
19376
|
+
const internalData = createInternalData$d();
|
|
19319
19377
|
const refElem = ref();
|
|
19320
19378
|
const refInputTarget = ref();
|
|
19321
19379
|
const refInputPanel = ref();
|
|
@@ -20717,6 +20775,7 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
20717
20775
|
watch(() => props.modelValue, () => {
|
|
20718
20776
|
updateModelValue();
|
|
20719
20777
|
});
|
|
20778
|
+
updateModelValue();
|
|
20720
20779
|
nextTick(() => {
|
|
20721
20780
|
globalEvents.on($xeDatePicker, 'mousewheel', handleGlobalMousewheelEvent);
|
|
20722
20781
|
globalEvents.on($xeDatePicker, 'mousedown', handleGlobalMousedownEvent);
|
|
@@ -20741,8 +20800,9 @@ var VxeDatePickerComponent = defineVxeComponent({
|
|
|
20741
20800
|
globalEvents.off($xeDatePicker, 'keydown');
|
|
20742
20801
|
globalEvents.off($xeDatePicker, 'blur');
|
|
20743
20802
|
globalEvents.off($xeDatePicker, 'resize');
|
|
20803
|
+
XEUtils.assign(reactData, createReactData$e());
|
|
20804
|
+
XEUtils.assign(internalData, createInternalData$d());
|
|
20744
20805
|
});
|
|
20745
|
-
updateModelValue();
|
|
20746
20806
|
provide('$xeDatePicker', $xeDatePicker);
|
|
20747
20807
|
$xeDatePicker.renderVN = renderVN;
|
|
20748
20808
|
return $xeDatePicker;
|
|
@@ -20762,6 +20822,27 @@ VxeUI.component(VxeDatePickerComponent);
|
|
|
20762
20822
|
const DatePicker = VxeDatePicker;
|
|
20763
20823
|
|
|
20764
20824
|
const { errLog: errLog$d } = createComponentLog('date-range-picker');
|
|
20825
|
+
function createReactData$d() {
|
|
20826
|
+
return {
|
|
20827
|
+
initialized: false,
|
|
20828
|
+
panelIndex: 0,
|
|
20829
|
+
visiblePanel: false,
|
|
20830
|
+
isAniVisible: false,
|
|
20831
|
+
panelStyle: {},
|
|
20832
|
+
panelPlacement: '',
|
|
20833
|
+
isActivated: false,
|
|
20834
|
+
selectStValue: '',
|
|
20835
|
+
selectEdValue: '',
|
|
20836
|
+
paneStartVal: '',
|
|
20837
|
+
paneEndVal: ''
|
|
20838
|
+
};
|
|
20839
|
+
}
|
|
20840
|
+
function createInternalData$c() {
|
|
20841
|
+
return {
|
|
20842
|
+
// selectStatus: false
|
|
20843
|
+
// hpTimeout: undefined
|
|
20844
|
+
};
|
|
20845
|
+
}
|
|
20765
20846
|
var VxeDateRangePickerComponent = defineVxeComponent({
|
|
20766
20847
|
name: 'VxeDateRangePicker',
|
|
20767
20848
|
props: {
|
|
@@ -20898,21 +20979,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
20898
20979
|
const formItemInfo = inject('xeFormItemInfo', null);
|
|
20899
20980
|
const xID = XEUtils.uniqueId();
|
|
20900
20981
|
const { computeSize } = useSize(props);
|
|
20901
|
-
const reactData = reactive(
|
|
20902
|
-
|
|
20903
|
-
panelIndex: 0,
|
|
20904
|
-
visiblePanel: false,
|
|
20905
|
-
isAniVisible: false,
|
|
20906
|
-
panelStyle: {},
|
|
20907
|
-
panelPlacement: '',
|
|
20908
|
-
isActivated: false,
|
|
20909
|
-
startValue: '',
|
|
20910
|
-
endValue: ''
|
|
20911
|
-
});
|
|
20912
|
-
const internalData = {
|
|
20913
|
-
// selectStatus: false
|
|
20914
|
-
// hpTimeout: undefined
|
|
20915
|
-
};
|
|
20982
|
+
const reactData = reactive(createReactData$d());
|
|
20983
|
+
const internalData = createInternalData$c();
|
|
20916
20984
|
const refElem = ref();
|
|
20917
20985
|
const refInputTarget = ref();
|
|
20918
20986
|
const refInputPanel = ref();
|
|
@@ -21058,8 +21126,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21058
21126
|
return XEUtils.toNumber(startDay);
|
|
21059
21127
|
});
|
|
21060
21128
|
const computePanelLabelObj = computed(() => {
|
|
21061
|
-
const {
|
|
21062
|
-
const vals =
|
|
21129
|
+
const { selectStValue, selectEdValue } = reactData;
|
|
21130
|
+
const vals = selectStValue || selectEdValue ? [selectStValue || '', selectEdValue || ''] : [];
|
|
21063
21131
|
return formatRangeLabel(vals);
|
|
21064
21132
|
});
|
|
21065
21133
|
const computeInputLabel = computed(() => {
|
|
@@ -21094,8 +21162,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21094
21162
|
};
|
|
21095
21163
|
};
|
|
21096
21164
|
const getRangeValue = (sValue, eValue) => {
|
|
21097
|
-
const { modelValue, valueType } = props;
|
|
21098
|
-
let isArr = XEUtils.isArray(modelValue);
|
|
21165
|
+
const { modelValue, valueType, valueFormat } = props;
|
|
21166
|
+
let isArr = valueFormat === 'date' || XEUtils.isArray(modelValue);
|
|
21099
21167
|
if (valueType) {
|
|
21100
21168
|
switch (valueType) {
|
|
21101
21169
|
case 'array':
|
|
@@ -21107,7 +21175,7 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21107
21175
|
}
|
|
21108
21176
|
}
|
|
21109
21177
|
if (sValue || eValue) {
|
|
21110
|
-
const rest = [sValue ||
|
|
21178
|
+
const rest = [sValue || null, eValue || null];
|
|
21111
21179
|
if (isArr) {
|
|
21112
21180
|
return rest;
|
|
21113
21181
|
}
|
|
@@ -21174,25 +21242,46 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21174
21242
|
restObj = paraeUpdateModel();
|
|
21175
21243
|
}
|
|
21176
21244
|
}
|
|
21177
|
-
reactData.
|
|
21178
|
-
reactData.
|
|
21245
|
+
reactData.selectStValue = restObj.sValue;
|
|
21246
|
+
reactData.selectEdValue = restObj.eValue;
|
|
21179
21247
|
};
|
|
21180
21248
|
const triggerEvent = (evnt) => {
|
|
21181
|
-
const {
|
|
21182
|
-
const value = getRangeValue(
|
|
21183
|
-
dispatchEvent(evnt.type, { value, startValue, endValue }, evnt);
|
|
21249
|
+
const { selectStValue, selectEdValue } = reactData;
|
|
21250
|
+
const value = getRangeValue(selectStValue, selectEdValue);
|
|
21251
|
+
dispatchEvent(evnt.type, { value, startValue: selectStValue, endValue: selectEdValue }, evnt);
|
|
21184
21252
|
};
|
|
21185
21253
|
const handleChange = (sValue, eValue, evnt) => {
|
|
21186
|
-
const { modelValue } = props;
|
|
21187
|
-
|
|
21188
|
-
|
|
21189
|
-
|
|
21190
|
-
|
|
21254
|
+
const { type, modelValue, valueFormat } = props;
|
|
21255
|
+
const dateValueFormat = computeDateValueFormat.value;
|
|
21256
|
+
let startRest = sValue;
|
|
21257
|
+
let endRest = eValue;
|
|
21258
|
+
if (hasTimestampValueType(valueFormat)) {
|
|
21259
|
+
if (startRest) {
|
|
21260
|
+
const dateVal = parseDateValue(startRest, type, { valueFormat: dateValueFormat });
|
|
21261
|
+
startRest = dateVal ? dateVal.getTime() : null;
|
|
21262
|
+
}
|
|
21263
|
+
if (endRest) {
|
|
21264
|
+
const dateVal = parseDateValue(endRest, type, { valueFormat: dateValueFormat });
|
|
21265
|
+
endRest = dateVal ? dateVal.getTime() : null;
|
|
21266
|
+
}
|
|
21267
|
+
}
|
|
21268
|
+
else if (hasDateValueType(valueFormat)) {
|
|
21269
|
+
if (startRest) {
|
|
21270
|
+
startRest = parseDateValue(startRest, type, { valueFormat: dateValueFormat });
|
|
21271
|
+
}
|
|
21272
|
+
if (endRest) {
|
|
21273
|
+
endRest = parseDateValue(endRest, type, { valueFormat: dateValueFormat });
|
|
21274
|
+
}
|
|
21275
|
+
}
|
|
21276
|
+
reactData.selectStValue = startRest;
|
|
21277
|
+
reactData.selectEdValue = endRest;
|
|
21278
|
+
const value = getRangeValue(startRest, endRest);
|
|
21279
|
+
const isFinish = (startRest && endRest) || (!startRest && !endRest);
|
|
21191
21280
|
emit('update:modelValue', value);
|
|
21192
|
-
emit('update:startValue',
|
|
21193
|
-
emit('update:endValue',
|
|
21281
|
+
emit('update:startValue', startRest || '');
|
|
21282
|
+
emit('update:endValue', endRest || '');
|
|
21194
21283
|
if (XEUtils.toValueString(modelValue) !== value) {
|
|
21195
|
-
dispatchEvent('change', { value, startValue:
|
|
21284
|
+
dispatchEvent('change', { value, startValue: startRest, endValue: endRest, isFinish }, evnt);
|
|
21196
21285
|
// 自动更新校验状态
|
|
21197
21286
|
if ($xeForm && formItemInfo) {
|
|
21198
21287
|
$xeForm.triggerItemEvent(evnt, formItemInfo.itemConfig.field, value);
|
|
@@ -21220,9 +21309,9 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21220
21309
|
const clickPrefixEvent = (evnt) => {
|
|
21221
21310
|
const isDisabled = computeIsDisabled.value;
|
|
21222
21311
|
if (!isDisabled) {
|
|
21223
|
-
const {
|
|
21224
|
-
const value = getRangeValue(
|
|
21225
|
-
dispatchEvent('prefix-click', { value, startValue, endValue }, evnt);
|
|
21312
|
+
const { selectStValue, selectEdValue } = reactData;
|
|
21313
|
+
const value = getRangeValue(selectStValue, selectEdValue);
|
|
21314
|
+
dispatchEvent('prefix-click', { value, startValue: selectStValue, endValue: selectEdValue }, evnt);
|
|
21226
21315
|
}
|
|
21227
21316
|
};
|
|
21228
21317
|
const hidePanel = () => {
|
|
@@ -21256,8 +21345,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21256
21345
|
}
|
|
21257
21346
|
};
|
|
21258
21347
|
const panelCellClassName = ({ date }) => {
|
|
21259
|
-
const startValue = reactData.
|
|
21260
|
-
const endValue = reactData.
|
|
21348
|
+
const startValue = reactData.selectStValue;
|
|
21349
|
+
const endValue = reactData.selectEdValue;
|
|
21261
21350
|
if (startValue && endValue) {
|
|
21262
21351
|
const currTime = date.getTime();
|
|
21263
21352
|
const startTime = XEUtils.toStringDate(startValue).getTime();
|
|
@@ -21270,18 +21359,18 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21270
21359
|
};
|
|
21271
21360
|
const handleSelectClose = () => {
|
|
21272
21361
|
const { autoClose } = props;
|
|
21273
|
-
const {
|
|
21362
|
+
const { selectStValue, selectEdValue } = reactData;
|
|
21274
21363
|
const { selectStatus } = internalData;
|
|
21275
21364
|
const isDatePickerType = computeIsDatePickerType.value;
|
|
21276
21365
|
if (autoClose) {
|
|
21277
21366
|
if (selectStatus && isDatePickerType) {
|
|
21278
|
-
if (
|
|
21367
|
+
if (selectStValue && selectEdValue) {
|
|
21279
21368
|
hidePanel();
|
|
21280
21369
|
}
|
|
21281
21370
|
}
|
|
21282
21371
|
}
|
|
21283
21372
|
else {
|
|
21284
|
-
if (
|
|
21373
|
+
if (selectStValue && selectEdValue) {
|
|
21285
21374
|
internalData.selectStatus = false;
|
|
21286
21375
|
}
|
|
21287
21376
|
}
|
|
@@ -21289,23 +21378,23 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21289
21378
|
const clickSuffixEvent = (evnt) => {
|
|
21290
21379
|
const isDisabled = computeIsDisabled.value;
|
|
21291
21380
|
if (!isDisabled) {
|
|
21292
|
-
const {
|
|
21293
|
-
const value = getRangeValue(
|
|
21294
|
-
dispatchEvent('suffix-click', { value, startValue, endValue }, evnt);
|
|
21381
|
+
const { selectStValue, selectEdValue } = reactData;
|
|
21382
|
+
const value = getRangeValue(selectStValue, selectEdValue);
|
|
21383
|
+
dispatchEvent('suffix-click', { value, startValue: selectStValue, endValue: selectEdValue }, evnt);
|
|
21295
21384
|
}
|
|
21296
21385
|
};
|
|
21297
21386
|
const blurEvent = (evnt) => {
|
|
21298
|
-
const {
|
|
21387
|
+
const { selectStValue, selectEdValue } = reactData;
|
|
21299
21388
|
const inpImmediate = computeInpImmediate.value;
|
|
21300
21389
|
const value = '';
|
|
21301
21390
|
if (!inpImmediate) {
|
|
21302
|
-
handleChange(
|
|
21391
|
+
handleChange(selectStValue, selectEdValue, evnt);
|
|
21303
21392
|
}
|
|
21304
21393
|
if (!reactData.visiblePanel) {
|
|
21305
21394
|
reactData.isActivated = false;
|
|
21306
21395
|
checkValue();
|
|
21307
21396
|
}
|
|
21308
|
-
dispatchEvent('blur', { value, startValue, endValue }, evnt);
|
|
21397
|
+
dispatchEvent('blur', { value, startValue: selectStValue, endValue: selectEdValue }, evnt);
|
|
21309
21398
|
// 自动更新校验状态
|
|
21310
21399
|
if ($xeForm && formItemInfo) {
|
|
21311
21400
|
$xeForm.triggerItemEvent(evnt, formItemInfo.itemConfig.field, value);
|
|
@@ -21337,107 +21426,170 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21337
21426
|
};
|
|
21338
21427
|
const startPanelChangeEvent = (params) => {
|
|
21339
21428
|
const { selectStatus } = internalData;
|
|
21340
|
-
const { value, $event } = params;
|
|
21341
|
-
const
|
|
21342
|
-
|
|
21429
|
+
const { value, currValue, $event } = params;
|
|
21430
|
+
const paneVals = value ? (XEUtils.isString(value) ? value.split(',') : [value]) : [];
|
|
21431
|
+
let startValue = '';
|
|
21432
|
+
let endValue = '';
|
|
21433
|
+
if (selectStatus) {
|
|
21434
|
+
startValue = paneVals[0];
|
|
21435
|
+
if (paneVals[1]) {
|
|
21436
|
+
endValue = paneVals[1];
|
|
21437
|
+
}
|
|
21438
|
+
else {
|
|
21439
|
+
endValue = reactData.selectEdValue;
|
|
21440
|
+
}
|
|
21441
|
+
}
|
|
21442
|
+
else {
|
|
21443
|
+
startValue = currValue || XEUtils.last(paneVals);
|
|
21444
|
+
}
|
|
21445
|
+
reactData.paneEndVal = [startValue, endValue].join(',');
|
|
21446
|
+
reactData.paneStartVal = [startValue, endValue].join(',');
|
|
21447
|
+
handleChange(startValue, endValue, $event);
|
|
21343
21448
|
handleSelectClose();
|
|
21344
21449
|
if (!selectStatus) {
|
|
21345
21450
|
internalData.selectStatus = true;
|
|
21346
21451
|
}
|
|
21347
21452
|
nextTick(() => {
|
|
21348
|
-
|
|
21349
|
-
const $endDatePanel = refEndDatePanel.value;
|
|
21350
|
-
if ($startDatePanel && $endDatePanel) {
|
|
21351
|
-
const startValue = $startDatePanel.getModelValue();
|
|
21352
|
-
if (!endValue && startValue) {
|
|
21353
|
-
$endDatePanel.setPanelDate(XEUtils.toStringDate(startValue));
|
|
21354
|
-
}
|
|
21355
|
-
}
|
|
21453
|
+
handleUpdateStartPanelDate();
|
|
21356
21454
|
});
|
|
21357
21455
|
};
|
|
21358
21456
|
const endPanelChangeEvent = (params) => {
|
|
21359
21457
|
const { selectStatus } = internalData;
|
|
21360
|
-
const { value, $event } = params;
|
|
21361
|
-
const
|
|
21362
|
-
|
|
21458
|
+
const { value, currValue, $event } = params;
|
|
21459
|
+
const paneVals = value ? (XEUtils.isString(value) ? value.split(',') : [value]) : [];
|
|
21460
|
+
let startValue = '';
|
|
21461
|
+
let endValue = '';
|
|
21462
|
+
if (selectStatus) {
|
|
21463
|
+
endValue = paneVals[0];
|
|
21464
|
+
if (paneVals[1]) {
|
|
21465
|
+
startValue = paneVals[0];
|
|
21466
|
+
endValue = paneVals[1];
|
|
21467
|
+
}
|
|
21468
|
+
else {
|
|
21469
|
+
startValue = reactData.selectStValue;
|
|
21470
|
+
}
|
|
21471
|
+
}
|
|
21472
|
+
else {
|
|
21473
|
+
endValue = currValue || XEUtils.last(paneVals);
|
|
21474
|
+
}
|
|
21475
|
+
reactData.paneEndVal = [startValue, endValue].join(',');
|
|
21476
|
+
reactData.paneStartVal = [startValue, endValue].join(',');
|
|
21477
|
+
handleChange(startValue, endValue, $event);
|
|
21363
21478
|
handleSelectClose();
|
|
21364
21479
|
if (!selectStatus) {
|
|
21365
21480
|
internalData.selectStatus = true;
|
|
21366
21481
|
}
|
|
21367
21482
|
nextTick(() => {
|
|
21368
|
-
|
|
21369
|
-
|
|
21370
|
-
|
|
21371
|
-
|
|
21372
|
-
|
|
21373
|
-
|
|
21483
|
+
handleUpdateEndPanelDate();
|
|
21484
|
+
});
|
|
21485
|
+
};
|
|
21486
|
+
const handleUpdateStartPanelDate = () => {
|
|
21487
|
+
const $startDatePanel = refStartDatePanel.value;
|
|
21488
|
+
const $endDatePanel = refEndDatePanel.value;
|
|
21489
|
+
if (!$startDatePanel || !$endDatePanel) {
|
|
21490
|
+
return;
|
|
21491
|
+
}
|
|
21492
|
+
const startPanelDate = $startDatePanel.getPanelDate();
|
|
21493
|
+
const endPanelDate = $endDatePanel.getPanelDate();
|
|
21494
|
+
if (!startPanelDate || !endPanelDate) {
|
|
21495
|
+
return;
|
|
21496
|
+
}
|
|
21497
|
+
const viewType = $startDatePanel.getViewType();
|
|
21498
|
+
const startYear = startPanelDate.getFullYear();
|
|
21499
|
+
const startMonth = startPanelDate.getMonth();
|
|
21500
|
+
const endYear = endPanelDate.getFullYear();
|
|
21501
|
+
const endMonth = endPanelDate.getMonth();
|
|
21502
|
+
switch (viewType) {
|
|
21503
|
+
case 'day':
|
|
21504
|
+
case 'date':
|
|
21505
|
+
case 'week': {
|
|
21506
|
+
if (endYear <= startYear && endMonth <= startMonth) {
|
|
21507
|
+
$endDatePanel.setPanelDate(getNextMonth(startPanelDate));
|
|
21374
21508
|
}
|
|
21509
|
+
break;
|
|
21375
21510
|
}
|
|
21376
|
-
}
|
|
21511
|
+
}
|
|
21377
21512
|
};
|
|
21378
|
-
const startPanelDateBtnChangeEvent = (
|
|
21513
|
+
const startPanelDateBtnChangeEvent = () => {
|
|
21379
21514
|
const { linkedPanels } = props;
|
|
21515
|
+
const $startDatePanel = refStartDatePanel.value;
|
|
21516
|
+
const $endDatePanel = refEndDatePanel.value;
|
|
21517
|
+
if (!$startDatePanel || !$endDatePanel) {
|
|
21518
|
+
return;
|
|
21519
|
+
}
|
|
21520
|
+
const startPanelDate = $startDatePanel.getPanelDate();
|
|
21521
|
+
const endPanelDate = $endDatePanel.getPanelDate();
|
|
21522
|
+
if (!startPanelDate || !endPanelDate) {
|
|
21523
|
+
return;
|
|
21524
|
+
}
|
|
21525
|
+
const viewType = $startDatePanel.getViewType();
|
|
21380
21526
|
if (linkedPanels) {
|
|
21381
|
-
const { viewType } = params;
|
|
21382
|
-
const $startDatePanel = refStartDatePanel.value;
|
|
21383
|
-
const $endDatePanel = refEndDatePanel.value;
|
|
21384
|
-
if (!$startDatePanel || !$endDatePanel) {
|
|
21385
|
-
return;
|
|
21386
|
-
}
|
|
21387
|
-
const startPanelDate = $startDatePanel.getPanelDate();
|
|
21388
|
-
if (!startPanelDate) {
|
|
21389
|
-
return;
|
|
21390
|
-
}
|
|
21391
|
-
const endYear = startPanelDate.getFullYear();
|
|
21392
|
-
const endMonth = startPanelDate.getMonth();
|
|
21393
21527
|
switch (viewType) {
|
|
21394
21528
|
case 'day':
|
|
21395
21529
|
case 'date':
|
|
21396
21530
|
case 'week': {
|
|
21397
|
-
|
|
21398
|
-
startPanelDate.setMonth(endMonth + 1);
|
|
21399
|
-
}
|
|
21400
|
-
else {
|
|
21401
|
-
startPanelDate.setFullYear(endYear + 1);
|
|
21402
|
-
startPanelDate.setMonth(0);
|
|
21403
|
-
}
|
|
21404
|
-
$endDatePanel.setPanelDate(startPanelDate);
|
|
21531
|
+
$endDatePanel.setPanelDate(getNextMonth(startPanelDate));
|
|
21405
21532
|
break;
|
|
21406
21533
|
}
|
|
21407
21534
|
}
|
|
21408
21535
|
}
|
|
21536
|
+
else {
|
|
21537
|
+
handleUpdateStartPanelDate();
|
|
21538
|
+
}
|
|
21409
21539
|
};
|
|
21410
|
-
const
|
|
21540
|
+
const handleUpdateEndPanelDate = () => {
|
|
21541
|
+
const $startDatePanel = refStartDatePanel.value;
|
|
21542
|
+
const $endDatePanel = refEndDatePanel.value;
|
|
21543
|
+
if (!$startDatePanel || !$endDatePanel) {
|
|
21544
|
+
return;
|
|
21545
|
+
}
|
|
21546
|
+
const startPanelDate = $startDatePanel.getPanelDate();
|
|
21547
|
+
const endPanelDate = $endDatePanel.getPanelDate();
|
|
21548
|
+
if (!startPanelDate || !endPanelDate) {
|
|
21549
|
+
return;
|
|
21550
|
+
}
|
|
21551
|
+
const viewType = $endDatePanel.getViewType();
|
|
21552
|
+
const startYear = startPanelDate.getFullYear();
|
|
21553
|
+
const startMonth = startPanelDate.getMonth();
|
|
21554
|
+
const endYear = endPanelDate.getFullYear();
|
|
21555
|
+
const endMonth = endPanelDate.getMonth();
|
|
21556
|
+
switch (viewType) {
|
|
21557
|
+
case 'day':
|
|
21558
|
+
case 'date':
|
|
21559
|
+
case 'week': {
|
|
21560
|
+
if (startYear >= endYear && startMonth >= endMonth) {
|
|
21561
|
+
$startDatePanel.setPanelDate(getPrevMonth(endPanelDate));
|
|
21562
|
+
}
|
|
21563
|
+
break;
|
|
21564
|
+
}
|
|
21565
|
+
}
|
|
21566
|
+
};
|
|
21567
|
+
const endPanelDateBtnChangeEvent = () => {
|
|
21411
21568
|
const { linkedPanels } = props;
|
|
21569
|
+
const $startDatePanel = refStartDatePanel.value;
|
|
21570
|
+
const $endDatePanel = refEndDatePanel.value;
|
|
21571
|
+
if (!$startDatePanel || !$endDatePanel) {
|
|
21572
|
+
return;
|
|
21573
|
+
}
|
|
21574
|
+
const startPanelDate = $startDatePanel.getPanelDate();
|
|
21575
|
+
const endPanelDate = $endDatePanel.getPanelDate();
|
|
21576
|
+
if (!startPanelDate || !endPanelDate) {
|
|
21577
|
+
return;
|
|
21578
|
+
}
|
|
21579
|
+
const viewType = $endDatePanel.getViewType();
|
|
21412
21580
|
if (linkedPanels) {
|
|
21413
|
-
const { viewType } = params;
|
|
21414
|
-
const $startDatePanel = refStartDatePanel.value;
|
|
21415
|
-
const $endDatePanel = refEndDatePanel.value;
|
|
21416
|
-
if (!$startDatePanel || !$endDatePanel) {
|
|
21417
|
-
return;
|
|
21418
|
-
}
|
|
21419
|
-
const endPanelDate = $endDatePanel.getPanelDate();
|
|
21420
|
-
if (!endPanelDate) {
|
|
21421
|
-
return;
|
|
21422
|
-
}
|
|
21423
|
-
const endYear = endPanelDate.getFullYear();
|
|
21424
|
-
const endMonth = endPanelDate.getMonth();
|
|
21425
21581
|
switch (viewType) {
|
|
21426
21582
|
case 'day':
|
|
21427
21583
|
case 'date':
|
|
21428
21584
|
case 'week': {
|
|
21429
|
-
|
|
21430
|
-
endPanelDate.setMonth(endMonth - 1);
|
|
21431
|
-
}
|
|
21432
|
-
else {
|
|
21433
|
-
endPanelDate.setFullYear(endYear - 1);
|
|
21434
|
-
endPanelDate.setMonth(11);
|
|
21435
|
-
}
|
|
21436
|
-
$startDatePanel.setPanelDate(endPanelDate);
|
|
21585
|
+
$startDatePanel.setPanelDate(getPrevMonth(endPanelDate));
|
|
21437
21586
|
break;
|
|
21438
21587
|
}
|
|
21439
21588
|
}
|
|
21440
21589
|
}
|
|
21590
|
+
else {
|
|
21591
|
+
handleUpdateEndPanelDate();
|
|
21592
|
+
}
|
|
21441
21593
|
};
|
|
21442
21594
|
// 全局事件
|
|
21443
21595
|
const handleGlobalMousedownEvent = (evnt) => {
|
|
@@ -21562,6 +21714,7 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21562
21714
|
reactData.isAniVisible = true;
|
|
21563
21715
|
setTimeout(() => {
|
|
21564
21716
|
reactData.visiblePanel = true;
|
|
21717
|
+
handleUpdateStartPanelDate();
|
|
21565
21718
|
updatePlacement();
|
|
21566
21719
|
}, 10);
|
|
21567
21720
|
updateZindex();
|
|
@@ -21597,8 +21750,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21597
21750
|
const shortcutOpts = computeShortcutOpts.value;
|
|
21598
21751
|
const { autoClose } = shortcutOpts;
|
|
21599
21752
|
const { code, clickMethod } = option;
|
|
21600
|
-
let startValue = reactData.
|
|
21601
|
-
let endValue = reactData.
|
|
21753
|
+
let startValue = reactData.selectStValue;
|
|
21754
|
+
let endValue = reactData.selectEdValue;
|
|
21602
21755
|
let value = getRangeValue(startValue, endValue);
|
|
21603
21756
|
const shortcutParams = {
|
|
21604
21757
|
$dateRangePicker: $xeDateRangePicker,
|
|
@@ -21661,8 +21814,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21661
21814
|
dateRangePickerMethods = {
|
|
21662
21815
|
dispatchEvent,
|
|
21663
21816
|
setModelValue(startValue, endValue) {
|
|
21664
|
-
reactData.
|
|
21665
|
-
reactData.
|
|
21817
|
+
reactData.selectStValue = startValue || '';
|
|
21818
|
+
reactData.selectEdValue = endValue || '';
|
|
21666
21819
|
const value = getRangeValue(startValue, endValue);
|
|
21667
21820
|
emit('update:modelValue', value);
|
|
21668
21821
|
},
|
|
@@ -21716,8 +21869,8 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21716
21869
|
if (popupOpts.enabled === false) {
|
|
21717
21870
|
return renderEmptyElement($xeDateRangePicker);
|
|
21718
21871
|
}
|
|
21719
|
-
const { type, separator, autoClose, showConfirmButton, showClearButton } = props;
|
|
21720
|
-
const { initialized, isAniVisible, visiblePanel, panelPlacement, panelStyle,
|
|
21872
|
+
const { type, separator, autoClose, valueFormat, showConfirmButton, showClearButton } = props;
|
|
21873
|
+
const { initialized, isAniVisible, visiblePanel, panelPlacement, panelStyle, selectStValue, selectEdValue, paneStartVal, paneEndVal } = reactData;
|
|
21721
21874
|
const vSize = computeSize.value;
|
|
21722
21875
|
const btnTransfer = computeBtnTransfer.value;
|
|
21723
21876
|
const shortcutOpts = computeShortcutOpts.value;
|
|
@@ -21794,15 +21947,18 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21794
21947
|
}, [
|
|
21795
21948
|
h(VxeDatePanel, {
|
|
21796
21949
|
ref: refStartDatePanel,
|
|
21797
|
-
modelValue:
|
|
21950
|
+
modelValue: paneStartVal,
|
|
21951
|
+
multiple: true,
|
|
21952
|
+
valueSort: true,
|
|
21953
|
+
limitCount: 3,
|
|
21954
|
+
defaultMode: 'first',
|
|
21798
21955
|
type: props.type,
|
|
21799
21956
|
className: props.className,
|
|
21800
21957
|
minDate: props.minDate,
|
|
21801
21958
|
maxDate: props.maxDate,
|
|
21802
|
-
endDate: endValue,
|
|
21803
21959
|
startDay: props.startDay,
|
|
21804
21960
|
labelFormat: props.labelFormat,
|
|
21805
|
-
valueFormat:
|
|
21961
|
+
valueFormat: valueFormat === 'date' || valueFormat === 'timestamp' ? '' : valueFormat,
|
|
21806
21962
|
timeFormat: props.timeFormat,
|
|
21807
21963
|
defaultDate: sdDate,
|
|
21808
21964
|
defaultTime: sdTime,
|
|
@@ -21818,15 +21974,18 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21818
21974
|
}),
|
|
21819
21975
|
h(VxeDatePanel, {
|
|
21820
21976
|
ref: refEndDatePanel,
|
|
21821
|
-
modelValue:
|
|
21977
|
+
modelValue: paneEndVal,
|
|
21978
|
+
multiple: true,
|
|
21979
|
+
valueSort: true,
|
|
21980
|
+
limitCount: 3,
|
|
21981
|
+
defaultMode: 'last',
|
|
21822
21982
|
type: props.type,
|
|
21823
21983
|
className: props.className,
|
|
21824
21984
|
minDate: props.minDate,
|
|
21825
21985
|
maxDate: props.maxDate,
|
|
21826
|
-
startDate: startValue,
|
|
21827
21986
|
startDay: props.startDay,
|
|
21828
21987
|
labelFormat: props.labelFormat,
|
|
21829
|
-
valueFormat:
|
|
21988
|
+
valueFormat: valueFormat === 'date' || valueFormat === 'timestamp' ? '' : valueFormat,
|
|
21830
21989
|
timeFormat: props.timeFormat,
|
|
21831
21990
|
defaultDate: edDate,
|
|
21832
21991
|
defaultTime: edTime,
|
|
@@ -21862,7 +22021,7 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21862
22021
|
showClearBtn
|
|
21863
22022
|
? h(VxeButton, {
|
|
21864
22023
|
size: 'mini',
|
|
21865
|
-
disabled: !(
|
|
22024
|
+
disabled: !(selectStValue || selectEdValue),
|
|
21866
22025
|
content: getI18n$2('vxe.button.clear'),
|
|
21867
22026
|
onClick: clearValueEvent
|
|
21868
22027
|
})
|
|
@@ -21916,13 +22075,13 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21916
22075
|
};
|
|
21917
22076
|
const renderSuffixIcon = () => {
|
|
21918
22077
|
const { suffixIcon } = props;
|
|
21919
|
-
const {
|
|
22078
|
+
const { selectStValue, selectEdValue } = reactData;
|
|
21920
22079
|
const suffixSlot = slots.suffix;
|
|
21921
22080
|
const isDisabled = computeIsDisabled.value;
|
|
21922
22081
|
const isClearable = computeIsClearable.value;
|
|
21923
22082
|
return h('div', {
|
|
21924
22083
|
class: ['vxe-date-range-picker--suffix', {
|
|
21925
|
-
'is--clear': isClearable && !isDisabled && (
|
|
22084
|
+
'is--clear': isClearable && !isDisabled && (selectStValue || selectEdValue)
|
|
21926
22085
|
}]
|
|
21927
22086
|
}, [
|
|
21928
22087
|
isClearable
|
|
@@ -21962,7 +22121,7 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21962
22121
|
};
|
|
21963
22122
|
const renderVN = () => {
|
|
21964
22123
|
const { className, type, name, autoComplete } = props;
|
|
21965
|
-
const {
|
|
22124
|
+
const { selectStValue, selectEdValue, visiblePanel, isActivated } = reactData;
|
|
21966
22125
|
const vSize = computeSize.value;
|
|
21967
22126
|
const isDisabled = computeIsDisabled.value;
|
|
21968
22127
|
const formReadonly = computeFormReadonly.value;
|
|
@@ -21986,7 +22145,7 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
21986
22145
|
'is--visible': visiblePanel,
|
|
21987
22146
|
'is--disabled': isDisabled,
|
|
21988
22147
|
'is--active': isActivated,
|
|
21989
|
-
'show--clear': isClearable && !isDisabled && (
|
|
22148
|
+
'show--clear': isClearable && !isDisabled && (selectStValue || selectEdValue)
|
|
21990
22149
|
}],
|
|
21991
22150
|
spellcheck: false
|
|
21992
22151
|
}, [
|
|
@@ -22034,14 +22193,16 @@ var VxeDateRangePickerComponent = defineVxeComponent({
|
|
|
22034
22193
|
onDeactivated(() => {
|
|
22035
22194
|
checkValue();
|
|
22036
22195
|
});
|
|
22196
|
+
onBeforeUnmount(() => {
|
|
22197
|
+
checkValue();
|
|
22198
|
+
});
|
|
22037
22199
|
onUnmounted(() => {
|
|
22038
22200
|
globalEvents.off($xeDateRangePicker, 'mousewheel');
|
|
22039
22201
|
globalEvents.off($xeDateRangePicker, 'mousedown');
|
|
22040
22202
|
globalEvents.off($xeDateRangePicker, 'blur');
|
|
22041
22203
|
globalEvents.off($xeDateRangePicker, 'resize');
|
|
22042
|
-
|
|
22043
|
-
|
|
22044
|
-
checkValue();
|
|
22204
|
+
XEUtils.assign(reactData, createReactData$d());
|
|
22205
|
+
XEUtils.assign(internalData, createInternalData$c());
|
|
22045
22206
|
});
|
|
22046
22207
|
provide('$xeDateRangePicker', $xeDateRangePicker);
|
|
22047
22208
|
$xeDateRangePicker.renderVN = renderVN;
|
|
@@ -25047,6 +25208,7 @@ var VxeFormComponent = defineVxeComponent({
|
|
|
25047
25208
|
});
|
|
25048
25209
|
onUnmounted(() => {
|
|
25049
25210
|
globalEvents.off($xeForm, 'resize');
|
|
25211
|
+
XEUtils.assign(reactData, createReactData$c());
|
|
25050
25212
|
XEUtils.assign(internalData, createInternalData$b());
|
|
25051
25213
|
});
|
|
25052
25214
|
reactData.collapseAll = !!props.collapseStatus;
|