@ecan-bi/datav 1.1.13 → 1.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +70 -20
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +70 -20
- package/dist/index.umd.js.map +1 -1
- package/dist/style.css +11 -11
- package/package.json +1 -1
- package/types/control/date-picker/DatePicker.vue.d.ts +18 -0
- package/types/control/date-picker/index.d.ts +18 -0
- package/types/control/date-picker/props.d.ts +10 -0
- package/types/control/range-picker/RangePicker.vue.d.ts +54 -0
- package/types/control/range-picker/index.d.ts +54 -0
- package/types/control/range-picker/props.d.ts +31 -0
- package/types/graph/bar/props.d.ts +1 -5
- package/types/graph/pie/props.d.ts +1 -5
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @ecan-bi/datav@1.1.
|
|
1
|
+
/*! @ecan-bi/datav@1.1.14 */
|
|
2
2
|
var _a, _b, _c, _d;
|
|
3
3
|
import { watch, inject, computed, unref, watchEffect, defineComponent, shallowRef, toRefs, onMounted, onUnmounted, h, nextTick, createVNode, resolveComponent, openBlock, createElementBlock, createBlock, renderSlot, withCtx, ref, normalizeStyle, createCommentVNode, provide, onBeforeUnmount, toDisplayString, Fragment, renderList, createElementVNode, normalizeClass, pushScopeId, popScopeId, createSlots, resolveDynamicComponent, mergeProps, withModifiers, reactive, createTextVNode, withDirectives, vShow } from "vue";
|
|
4
4
|
import { throttle, init, use, registerMap } from "echarts/core";
|
|
@@ -3562,10 +3562,11 @@ const datePickerProps = {
|
|
|
3562
3562
|
keyName: "\u65E5\u671F\u9009\u62E9\u5668",
|
|
3563
3563
|
rotate: "",
|
|
3564
3564
|
type: "ecanDatePicker",
|
|
3565
|
-
value:
|
|
3565
|
+
value: "",
|
|
3566
3566
|
picker: "date",
|
|
3567
3567
|
format: "YYYY-MM-DD",
|
|
3568
|
-
showTime: false
|
|
3568
|
+
showTime: false,
|
|
3569
|
+
useCurrentTime: true
|
|
3569
3570
|
};
|
|
3570
3571
|
const datePickerComponentProps = transformToComponentProps(datePickerProps);
|
|
3571
3572
|
const datePickerEvents = ["dateChange"];
|
|
@@ -3581,8 +3582,14 @@ const _sfc_main$h = defineComponent({
|
|
|
3581
3582
|
const style2 = usePickComponentStyle(props2);
|
|
3582
3583
|
const getPopupContainer = () => document.getElementById("ProviderConfig") || document.body;
|
|
3583
3584
|
const myValue = ref(null);
|
|
3584
|
-
watch(() => props2.value, () => {
|
|
3585
|
-
|
|
3585
|
+
watch(() => [props2.value, props2.useCurrentTime], ([value, useCurrentTime]) => {
|
|
3586
|
+
let _value = null;
|
|
3587
|
+
if (value) {
|
|
3588
|
+
_value = dayjs(value);
|
|
3589
|
+
} else if (useCurrentTime) {
|
|
3590
|
+
_value = dayjs();
|
|
3591
|
+
}
|
|
3592
|
+
myValue.value = _value;
|
|
3586
3593
|
}, {
|
|
3587
3594
|
immediate: true
|
|
3588
3595
|
});
|
|
@@ -3773,7 +3780,10 @@ const rangePickerProps = {
|
|
|
3773
3780
|
picker: "date",
|
|
3774
3781
|
format: "YYYY-MM-DD",
|
|
3775
3782
|
startTime: "",
|
|
3776
|
-
endTime: ""
|
|
3783
|
+
endTime: "",
|
|
3784
|
+
useCurrentTime: true,
|
|
3785
|
+
interval: 1,
|
|
3786
|
+
intervalUnit: "year"
|
|
3777
3787
|
};
|
|
3778
3788
|
const rangePickerComponentProps = transformToComponentProps(rangePickerProps);
|
|
3779
3789
|
const rangePickerEvents = ["dateChange"];
|
|
@@ -3789,9 +3799,19 @@ const _sfc_main$f = defineComponent({
|
|
|
3789
3799
|
const style2 = usePickComponentStyle(props2);
|
|
3790
3800
|
const getPopupContainer = () => document.getElementById("ProviderConfig") || document.body;
|
|
3791
3801
|
const myValue = ref([null, null]);
|
|
3792
|
-
watch(() => [props2.startTime, props2.endTime], ([startTime, endTime]) => {
|
|
3793
|
-
|
|
3794
|
-
|
|
3802
|
+
watch(() => [props2.startTime, props2.endTime, props2.useCurrentTime, props2.interval, props2.intervalUnit], ([startTime, endTime, useCurrentTime, interval, intervalUnit]) => {
|
|
3803
|
+
let _startTime = null;
|
|
3804
|
+
let _endTime = null;
|
|
3805
|
+
if (useCurrentTime) {
|
|
3806
|
+
_startTime = dayjs();
|
|
3807
|
+
_endTime = dayjs().subtract(interval, intervalUnit);
|
|
3808
|
+
}
|
|
3809
|
+
if (startTime) {
|
|
3810
|
+
_startTime = dayjs(startTime);
|
|
3811
|
+
}
|
|
3812
|
+
if (endTime) {
|
|
3813
|
+
_endTime = dayjs(endTime);
|
|
3814
|
+
}
|
|
3795
3815
|
myValue.value = [_startTime, _endTime];
|
|
3796
3816
|
}, {
|
|
3797
3817
|
immediate: true
|
|
@@ -3822,7 +3842,7 @@ const _sfc_main$f = defineComponent({
|
|
|
3822
3842
|
};
|
|
3823
3843
|
}
|
|
3824
3844
|
});
|
|
3825
|
-
const
|
|
3845
|
+
const RangePicker_vue_vue_type_style_index_0_scoped_2fc9988b_lang = "";
|
|
3826
3846
|
const RangePicker_vue_vue_type_style_index_1_lang = "";
|
|
3827
3847
|
function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
3828
3848
|
const _component_a_range_picker = resolveComponent("a-range-picker");
|
|
@@ -3843,7 +3863,7 @@ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
3843
3863
|
}, null, 8, ["value", "format", "picker", "locale", "getPopupContainer", "onChange"])
|
|
3844
3864
|
], 4);
|
|
3845
3865
|
}
|
|
3846
|
-
const RangePicker = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["render", _sfc_render$f], ["__scopeId", "data-v-
|
|
3866
|
+
const RangePicker = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["render", _sfc_render$f], ["__scopeId", "data-v-2fc9988b"]]);
|
|
3847
3867
|
const EcanRangePicker = withInstall(RangePicker);
|
|
3848
3868
|
const buttonProps = {
|
|
3849
3869
|
...props,
|
|
@@ -3875,7 +3895,7 @@ const _sfc_main$e = defineComponent({
|
|
|
3875
3895
|
const emitEvent = useEmitEvent(props2);
|
|
3876
3896
|
const click = emitEvent("click", () => {
|
|
3877
3897
|
const url = unref(myHref);
|
|
3878
|
-
if (props2.target === "event") {
|
|
3898
|
+
if (url && props2.target === "event") {
|
|
3879
3899
|
window.parent.postMessage({
|
|
3880
3900
|
type: "openPage",
|
|
3881
3901
|
url
|
|
@@ -4110,7 +4130,7 @@ const pieProps = {
|
|
|
4110
4130
|
toolboxInfoText: "\u5F53\u524D\u65E0\u8BF4\u660E\u4FE1\u606F"
|
|
4111
4131
|
};
|
|
4112
4132
|
const pieComponentProps = transformToComponentProps(pieProps);
|
|
4113
|
-
const pieEvents = ["click", "refreshData"];
|
|
4133
|
+
const pieEvents = ["click", "refreshData", "resetRecord"];
|
|
4114
4134
|
const useDownloadFile = async (downloadFileUrl) => {
|
|
4115
4135
|
var _a2;
|
|
4116
4136
|
const res = await request.post(downloadFileUrl, {}, {
|
|
@@ -4363,7 +4383,13 @@ const _sfc_main$c = defineComponent({
|
|
|
4363
4383
|
const refreshData = () => {
|
|
4364
4384
|
chooseRequestOrDiagram();
|
|
4365
4385
|
};
|
|
4386
|
+
const resetRecord = () => {
|
|
4387
|
+
const id = props2.id;
|
|
4388
|
+
const modal = getGlobalModel(id);
|
|
4389
|
+
setGlobalModel(id, { ...modal, RECORD: "" });
|
|
4390
|
+
};
|
|
4366
4391
|
useOnEvent(props2, {
|
|
4392
|
+
resetRecord,
|
|
4367
4393
|
refreshData,
|
|
4368
4394
|
click
|
|
4369
4395
|
});
|
|
@@ -4490,7 +4516,7 @@ const lineProps = {
|
|
|
4490
4516
|
areaStyleOpacity: 0
|
|
4491
4517
|
};
|
|
4492
4518
|
const lineComponentProps = transformToComponentProps(lineProps);
|
|
4493
|
-
const lineEvents = ["click", "refreshData"];
|
|
4519
|
+
const lineEvents = ["click", "refreshData", "resetRecord"];
|
|
4494
4520
|
use([
|
|
4495
4521
|
CanvasRenderer,
|
|
4496
4522
|
LineChart,
|
|
@@ -4777,8 +4803,14 @@ const _sfc_main$b = defineComponent({
|
|
|
4777
4803
|
const refreshData = () => {
|
|
4778
4804
|
chooseRequestOrDiagram();
|
|
4779
4805
|
};
|
|
4806
|
+
const resetRecord = () => {
|
|
4807
|
+
const id = props2.id;
|
|
4808
|
+
const modal = getGlobalModel(id);
|
|
4809
|
+
setGlobalModel(id, { ...modal, RECORD: "" });
|
|
4810
|
+
};
|
|
4780
4811
|
useOnEvent(props2, {
|
|
4781
4812
|
refreshData,
|
|
4813
|
+
resetRecord,
|
|
4782
4814
|
click
|
|
4783
4815
|
});
|
|
4784
4816
|
const { setRequest } = inject(REQUEST_MODEL, {
|
|
@@ -4932,7 +4964,7 @@ const barProps = {
|
|
|
4932
4964
|
labelColor: ""
|
|
4933
4965
|
};
|
|
4934
4966
|
const barComponentProps = transformToComponentProps(barProps);
|
|
4935
|
-
const barEvents = ["refreshData", "click"];
|
|
4967
|
+
const barEvents = ["refreshData", "click", "resetRecord"];
|
|
4936
4968
|
use([
|
|
4937
4969
|
CanvasRenderer,
|
|
4938
4970
|
BarChart,
|
|
@@ -5242,9 +5274,15 @@ const _sfc_main$a = defineComponent({
|
|
|
5242
5274
|
requestFn: refreshData,
|
|
5243
5275
|
sortNum: props2.requestSort
|
|
5244
5276
|
});
|
|
5277
|
+
const resetRecord = () => {
|
|
5278
|
+
const id = props2.id;
|
|
5279
|
+
const modal = getGlobalModel(id);
|
|
5280
|
+
setGlobalModel(id, { ...modal, RECORD: "" });
|
|
5281
|
+
};
|
|
5245
5282
|
useOnEvent(props2, {
|
|
5246
5283
|
refreshData,
|
|
5247
|
-
click
|
|
5284
|
+
click,
|
|
5285
|
+
resetRecord
|
|
5248
5286
|
});
|
|
5249
5287
|
return {
|
|
5250
5288
|
option,
|
|
@@ -5781,7 +5819,7 @@ const comboGraphProps = {
|
|
|
5781
5819
|
barWidth: "40%"
|
|
5782
5820
|
};
|
|
5783
5821
|
const comboGraphComponentProps = transformToComponentProps(comboGraphProps);
|
|
5784
|
-
const comboGraphEvents = ["refreshData", "click"];
|
|
5822
|
+
const comboGraphEvents = ["refreshData", "click", "resetRecord"];
|
|
5785
5823
|
use([
|
|
5786
5824
|
CanvasRenderer,
|
|
5787
5825
|
BarChart,
|
|
@@ -6101,7 +6139,13 @@ const _sfc_main$7 = defineComponent({
|
|
|
6101
6139
|
requestFn: chooseRequestOrDiagram,
|
|
6102
6140
|
sortNum: props2.requestSort
|
|
6103
6141
|
});
|
|
6142
|
+
const resetRecord = () => {
|
|
6143
|
+
const id = props2.id;
|
|
6144
|
+
const modal = getGlobalModel(id);
|
|
6145
|
+
setGlobalModel(id, { ...modal, RECORD: "" });
|
|
6146
|
+
};
|
|
6104
6147
|
useOnEvent(props2, {
|
|
6148
|
+
resetRecord,
|
|
6105
6149
|
refreshData,
|
|
6106
6150
|
click
|
|
6107
6151
|
});
|
|
@@ -6791,7 +6835,7 @@ const tableProps = {
|
|
|
6791
6835
|
}
|
|
6792
6836
|
};
|
|
6793
6837
|
const tableComponentProps = transformToComponentProps(tableProps);
|
|
6794
|
-
const tableEvents = ["click", "refreshData"];
|
|
6838
|
+
const tableEvents = ["click", "refreshData", "resetRecord"];
|
|
6795
6839
|
const _sfc_main$1 = defineComponent({
|
|
6796
6840
|
name: "EcanTable",
|
|
6797
6841
|
components: {
|
|
@@ -7160,7 +7204,13 @@ const _sfc_main$1 = defineComponent({
|
|
|
7160
7204
|
break;
|
|
7161
7205
|
}
|
|
7162
7206
|
};
|
|
7207
|
+
const resetRecord = () => {
|
|
7208
|
+
const id = props2.id;
|
|
7209
|
+
const modal = getGlobalModel(id);
|
|
7210
|
+
setGlobalModel(id, { ...modal, RECORD: "" });
|
|
7211
|
+
};
|
|
7163
7212
|
useOnEvent(props2, {
|
|
7213
|
+
resetRecord,
|
|
7164
7214
|
refreshData
|
|
7165
7215
|
});
|
|
7166
7216
|
const summaryList = computed(() => {
|
|
@@ -7295,7 +7345,7 @@ const _sfc_main$1 = defineComponent({
|
|
|
7295
7345
|
};
|
|
7296
7346
|
}
|
|
7297
7347
|
});
|
|
7298
|
-
const
|
|
7348
|
+
const Table_vue_vue_type_style_index_0_scoped_3f25d4f8_lang = "";
|
|
7299
7349
|
const Table_vue_vue_type_style_index_1_lang = "";
|
|
7300
7350
|
const _hoisted_1$1 = /* @__PURE__ */ createTextVNode(" \u641C\u7D22 ");
|
|
7301
7351
|
const _hoisted_2 = /* @__PURE__ */ createTextVNode(" \u91CD\u7F6E ");
|
|
@@ -7451,7 +7501,7 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
7451
7501
|
}, 8, ["loading"])
|
|
7452
7502
|
], 4);
|
|
7453
7503
|
}
|
|
7454
|
-
const Table = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-
|
|
7504
|
+
const Table = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-3f25d4f8"]]);
|
|
7455
7505
|
const EcanTable = withInstall(Table);
|
|
7456
7506
|
const mapProps = {
|
|
7457
7507
|
...props,
|