cnhis-design-vue 3.3.3-release.12 → 3.3.3-release.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.
Files changed (128) hide show
  1. package/README.md +87 -87
  2. package/es/components/button-print/index.d.ts +60 -0
  3. package/es/components/button-print/src/ButtonPrint.vue.d.ts +60 -0
  4. package/es/components/button-print/src/ButtonPrint.vue2.js +6 -0
  5. package/es/components/button-print/src/components/NewPrintComponent.vue.d.ts +18 -0
  6. package/es/components/button-print/src/components/NewPrintComponent.vue2.js +33 -4
  7. package/es/components/button-print/src/components/OldPrintComponent.vue.d.ts +18 -0
  8. package/es/components/button-print/src/components/OldPrintComponent.vue2.js +30 -4
  9. package/es/components/button-print/src/utils/print.d.ts +6 -4
  10. package/es/components/button-print/src/utils/print.js +176 -4
  11. package/es/components/calendar/src/Calendar.vue2.js +15 -5
  12. package/es/components/classification/index.d.ts +500 -5
  13. package/es/components/classification/src/components/search-filter/index.vue.d.ts +500 -5
  14. package/es/components/classification/src/components/set-classification/index.vue.d.ts +500 -5
  15. package/es/components/classification/src/components/table-modal/index.vue.d.ts +0 -3
  16. package/es/components/classification/src/index.vue.d.ts +500 -5
  17. package/es/components/fabric-chart/src/hooks/temperature/useLeft.js +3 -2
  18. package/es/components/fabric-chart/src/hooks/temperature/useOther.d.ts +1 -1
  19. package/es/components/fabric-chart/src/hooks/temperature/useOther.js +58 -15
  20. package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.js +4 -3
  21. package/es/components/field-set/src/FieldColor.vue.d.ts +4 -4
  22. package/es/components/field-set/src/FieldFilter.vue.d.ts +4 -4
  23. package/es/components/field-set/src/FieldSet.vue.d.ts +5 -5
  24. package/es/components/field-set/src/components/table-row.vue.d.ts +4 -4
  25. package/es/components/field-set/src/types/index.d.ts +1 -1
  26. package/es/components/form-render/src/components/renderer/date.d.ts +3 -1
  27. package/es/components/form-render/src/components/renderer/date.js +12 -10
  28. package/es/components/form-render/src/components/renderer/radio_checkbox.js +9 -3
  29. package/es/components/form-render/style/index.css +1 -1
  30. package/es/components/iho-chat/index.d.ts +41 -50
  31. package/es/components/iho-chat/src/Index.vue.d.ts +41 -50
  32. package/es/components/iho-chat/src/components/ChatFooter.vue2.js +6 -2
  33. package/es/components/iho-chat/src/components/ChatMain.vue2.js +1 -1
  34. package/es/components/iho-chat/src/components/ImageLightbox.vue2.js +1 -1
  35. package/es/components/iho-chat/src/components/MultipleVideo.vue.d.ts +29 -28
  36. package/es/components/iho-chat/src/components/MultipleVideo.vue2.js +239 -94
  37. package/es/components/iho-chat/src/components/PersonProfile.vue2.js +1 -1
  38. package/es/components/iho-chat/src/components/Video.vue.d.ts +14 -24
  39. package/es/components/iho-chat/src/components/Video.vue2.js +35 -40
  40. package/es/components/iho-chat/src/hooks/useVideo.d.ts +54 -10
  41. package/es/components/iho-chat/src/hooks/useVideo.js +420 -44
  42. package/es/components/iho-chat/src/utils/index.d.ts +1 -0
  43. package/es/components/iho-chat/src/utils/index.js +7 -1
  44. package/es/components/iho-chat/style/index.css +1 -1
  45. package/es/components/index.css +1 -1
  46. package/es/components/index.d.ts +2 -0
  47. package/es/components/index.js +2 -1
  48. package/es/components/keyboard/index.d.ts +9 -0
  49. package/es/components/keyboard/src/Keyboard.vue.d.ts +9 -0
  50. package/es/components/keyboard/src/Keyboard.vue2.js +33 -9
  51. package/es/components/keyboard/src/components/NumberPanel.vue.d.ts +4 -0
  52. package/es/components/keyboard/src/components/NumberPanel.vue2.js +50 -17
  53. package/es/components/keyboard/src/types.d.ts +17 -0
  54. package/es/components/keyboard/src/types.js +1 -0
  55. package/es/components/scale-view/index.d.ts +13 -0
  56. package/es/components/scale-view/src/ScaleView.vue.d.ts +13 -0
  57. package/es/components/scale-view/src/hooks/scaleview-computed.js +2 -1
  58. package/es/components/scale-view/src/hooks/scaleview-props.d.ts +4 -0
  59. package/es/components/scale-view/src/hooks/scaleview-props.js +4 -0
  60. package/es/components/select-person/src/SelectPerson.vue2.js +8 -1
  61. package/es/components/table-filter/index.js +1 -1
  62. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.d.ts +490 -1
  63. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue2.js +8 -2
  64. package/es/components/table-filter/src/components/classify-filter/components/Base/DateOption.vue.d.ts +226 -0
  65. package/es/components/table-filter/src/components/classify-filter/components/Base/DateOption.vue.js +6 -0
  66. package/es/components/table-filter/src/components/classify-filter/components/Base/DateOption.vue2.js +156 -0
  67. package/es/components/table-filter/src/components/classify-filter/components/Date.vue.d.ts +238 -0
  68. package/es/components/table-filter/src/components/classify-filter/components/Date.vue2.js +43 -4
  69. package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue.d.ts +239 -1
  70. package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue2.js +51 -8
  71. package/es/components/table-filter/src/components/classify-filter/components/index.d.ts +477 -1
  72. package/es/components/table-filter/src/components/classify-filter/helpers/options.d.ts +5 -1
  73. package/es/components/table-filter/src/components/classify-filter/helpers/options.js +49 -2
  74. package/es/components/table-filter/src/components/classify-filter/index.vue.d.ts +500 -5
  75. package/es/components/table-filter/src/components/classify-filter/index.vue2.js +13 -6
  76. package/es/components/table-filter/src/components/render-widget/components/DateInner.vue.d.ts +1 -1
  77. package/es/components/table-filter/src/components/render-widget/components/DateOut.vue.d.ts +1 -1
  78. package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue.d.ts +1 -1
  79. package/es/components/table-filter/src/components/render-widget/components/index.d.ts +3 -3
  80. package/es/components/table-filter/src/components/render-widget/helpers/dateExtraMap.js +32 -4
  81. package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.d.ts +1 -0
  82. package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.js +23 -2
  83. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +3 -3
  84. package/es/components/table-filter/src/hooks/useAdvanced.js +5 -4
  85. package/es/components/table-filter/src/tool/baseOptions.js +8 -1
  86. package/es/components/table-filter/src/types/enums.d.ts +4 -0
  87. package/es/components/table-filter/src/types/enums.js +5 -1
  88. package/es/components/vertify/index.d.ts +1 -0
  89. package/es/components/vertify/index.js +1 -0
  90. package/es/components/vertify/src/components/IdentityVerification.vue.d.ts +89 -0
  91. package/es/components/vertify/src/components/IdentityVerification.vue.js +6 -0
  92. package/es/components/vertify/src/components/IdentityVerification.vue2.js +256 -0
  93. package/es/components/vertify/src/utils/dialog.d.ts +7 -0
  94. package/es/components/vertify/src/utils/dialog.js +73 -0
  95. package/es/components/vertify/src/utils/index.d.ts +11 -0
  96. package/es/components/vertify/src/utils/index.js +24 -0
  97. package/es/components/vod-chunk-upload/index.d.ts +13 -0
  98. package/es/components/vod-chunk-upload/src/chunk-upload-new.vue.d.ts +19 -2
  99. package/es/components/vod-chunk-upload/src/chunk-upload-new.vue2.js +104 -75
  100. package/es/components/vod-chunk-upload/src/hooks/upload-computed.d.ts +1 -0
  101. package/es/components/vod-chunk-upload/src/hooks/upload-computed.js +20 -3
  102. package/es/components/vod-chunk-upload/src/hooks/upload-data.d.ts +4 -0
  103. package/es/components/vod-chunk-upload/src/hooks/upload-data.js +6 -2
  104. package/es/components/vod-chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue.d.ts +13 -0
  105. package/es/components/vod-chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue2.js +6 -1
  106. package/es/components/vod-chunk-upload/style/index.css +1 -1
  107. package/es/env.d.ts +25 -25
  108. package/es/shared/assets/img/defaultCover/10review_successful.png.js +1 -1
  109. package/es/shared/assets/img/defaultCover/11review_fail.png.js +1 -1
  110. package/es/shared/assets/img/defaultCover/12no_setting.png.js +1 -1
  111. package/es/shared/assets/img/defaultCover/13no_menu_setting.png.js +1 -1
  112. package/es/shared/assets/img/defaultCover/14no_call_setting.png.js +1 -1
  113. package/es/shared/assets/img/defaultCover/15no_use_tag.png.js +1 -1
  114. package/es/shared/assets/img/defaultCover/16no_table_data.png.js +1 -1
  115. package/es/shared/assets/img/defaultCover/1location.png.js +1 -1
  116. package/es/shared/assets/img/defaultCover/2notfound.png.js +1 -1
  117. package/es/shared/assets/img/defaultCover/3loading.png.js +1 -1
  118. package/es/shared/assets/img/defaultCover/4no_permission.png.js +1 -1
  119. package/es/shared/assets/img/defaultCover/5no_data.png.js +1 -1
  120. package/es/shared/assets/img/defaultCover/6no_network.png.js +1 -1
  121. package/es/shared/assets/img/defaultCover/7no_doctor.png.js +1 -1
  122. package/es/shared/assets/img/defaultCover/8system_error.png.js +1 -1
  123. package/es/shared/assets/img/defaultCover/9system_upgrade.png.js +1 -1
  124. package/es/shared/components/InputNumberSlash/InputNumberSlash.js +1 -1
  125. package/es/shared/hooks/useDateTime.js +1 -1
  126. package/es/shared/package.json.js +2 -2
  127. package/es/shared/utils/fabricjs/index.js +1 -1
  128. package/package.json +4 -4
@@ -1,7 +1,8 @@
1
- import { defineComponent, computed, openBlock, createElementBlock, createVNode, unref, isRef, createBlock, createCommentVNode } from 'vue';
1
+ import { defineComponent, computed, openBlock, createElementBlock, unref, Fragment, createVNode, isRef, createBlock, createCommentVNode } from 'vue';
2
2
  import DatePicker from '../../../../../date-picker/index.js';
3
3
  import { NSelect } from 'naive-ui';
4
- import { WidgetOptionEnums, WidgetTypeEnums, WidgetValEnums } from '../../../types/enums.js';
4
+ import DateOption from './Base/DateOption.vue.js';
5
+ import { ConditionEnums, WidgetOptionEnums, WidgetTypeEnums, WidgetValEnums } from '../../../types/enums.js';
5
6
  import { WidgetDateOptionEnums } from '../../render-widget/helpers/enums.js';
6
7
  import { widgetDateValOptions } from '../../render-widget/helpers/dateExtraMap.js';
7
8
  import { setDateDisabled, setTimeDisabled } from '../../render-widget/helpers/dateDisabled.js';
@@ -18,6 +19,10 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
18
19
  componentCfg: {
19
20
  type: Object
20
21
  },
22
+ item: {
23
+ type: Object,
24
+ required: true
25
+ },
21
26
  paramCfg: {
22
27
  type: Object,
23
28
  default: null
@@ -40,6 +45,27 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
40
45
  emit
41
46
  }) {
42
47
  const props = __props;
48
+ const filterType = computed(() => {
49
+ switch (props.item.condition) {
50
+ case ConditionEnums.EQUAL:
51
+ case ConditionEnums.NEQ:
52
+ return "1";
53
+ case ConditionEnums.BIG:
54
+ case ConditionEnums.LESS:
55
+ case ConditionEnums.BIGEQ:
56
+ case ConditionEnums.LESSEQ:
57
+ return "2";
58
+ case ConditionEnums.L_:
59
+ case ConditionEnums.N_:
60
+ case ConditionEnums.IN_THE_PAST:
61
+ case ConditionEnums.IN_THE_FUTURE:
62
+ case ConditionEnums.IN_THE_PAST_DI:
63
+ case ConditionEnums.IN_THE_FUTURE_DI:
64
+ return "3";
65
+ default:
66
+ return "1";
67
+ }
68
+ });
43
69
  const valueCp = computed({
44
70
  set(val) {
45
71
  emit("update:modelValue", val);
@@ -141,7 +167,9 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
141
167
  return setTimeDisabled(ts, optionSetting.value);
142
168
  }
143
169
  return (_ctx, _cache) => {
144
- return openBlock(), createElementBlock("div", _hoisted_1, [createVNode(unref(NSelect), {
170
+ return openBlock(), createElementBlock("div", _hoisted_1, [unref(filterType) === "1" ? (openBlock(), createElementBlock(Fragment, {
171
+ key: 0
172
+ }, [createVNode(unref(NSelect), {
145
173
  style: {
146
174
  "width": "120px"
147
175
  },
@@ -161,7 +189,18 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
161
189
  valueFormat: unref(valueFormat),
162
190
  "formatted-value": unref(valueCp),
163
191
  "onUpdate:formatted-value": _cache[1] || (_cache[1] = ($event) => isRef(valueCp) ? valueCp.value = $event : null)
164
- }, null, 8, ["type", "valueFormat", "formatted-value"])) : createCommentVNode("v-if", true)]);
192
+ }, null, 8, ["type", "valueFormat", "formatted-value"])) : createCommentVNode("v-if", true)], 64)) : (openBlock(), createBlock(DateOption, {
193
+ key: 1,
194
+ filterType: unref(filterType),
195
+ dateType: unref(dateType),
196
+ isDateDisabled,
197
+ timeDisabled,
198
+ valueFormat: unref(valueFormat),
199
+ modelValue: unref(valueCp),
200
+ "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => isRef(valueCp) ? valueCp.value = $event : null),
201
+ presetVal: unref(presetValCp),
202
+ "onUpdate:presetVal": _cache[3] || (_cache[3] = ($event) => isRef(presetValCp) ? presetValCp.value = $event : null)
203
+ }, null, 8, ["filterType", "dateType", "valueFormat", "modelValue", "presetVal"]))]);
165
204
  };
166
205
  }
167
206
  });
@@ -1,5 +1,9 @@
1
1
  import { PropType } from 'vue';
2
2
  declare const _default: import("vue").DefineComponent<{
3
+ item: {
4
+ type: ObjectConstructor;
5
+ required: true;
6
+ };
3
7
  paramCfg: {
4
8
  type: ObjectConstructor;
5
9
  default: null;
@@ -18,6 +22,10 @@ declare const _default: import("vue").DefineComponent<{
18
22
  };
19
23
  }, {
20
24
  props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
25
+ item: {
26
+ type: ObjectConstructor;
27
+ required: true;
28
+ };
21
29
  paramCfg: {
22
30
  type: ObjectConstructor;
23
31
  default: null;
@@ -42,6 +50,7 @@ declare const _default: import("vue").DefineComponent<{
42
50
  emit: (event: "update:modelValue" | "update:presetVal" | "update:customDate", ...args: any[]) => void;
43
51
  startDate: import("vue").Ref<any>;
44
52
  endDate: import("vue").Ref<any>;
53
+ filterType: import("vue").ComputedRef<"1" | "2" | "3">;
45
54
  valueFormat: import("vue").ComputedRef<string>;
46
55
  dateFormat: import("vue").ComputedRef<string>;
47
56
  compType: import("vue").ComputedRef<any>;
@@ -60,7 +69,7 @@ declare const _default: import("vue").DefineComponent<{
60
69
  value: string;
61
70
  }[]>;
62
71
  presetValCp: import("vue").WritableComputedRef<string>;
63
- customDateCp: import("vue").WritableComputedRef<string>;
72
+ valueDateCp: import("vue").WritableComputedRef<unknown>;
64
73
  handleChange: (val: any, type: 'start' | 'end') => void;
65
74
  isStartDateDisabled: (ts: number) => boolean;
66
75
  timeStartDisabled: (ts: number) => {
@@ -205,6 +214,231 @@ declare const _default: import("vue").DefineComponent<{
205
214
  to: string | false | HTMLElement;
206
215
  holidays: Date[];
207
216
  }>>;
217
+ DateOption: import("vue").DefineComponent<{
218
+ filterType: {
219
+ type: StringConstructor;
220
+ required: true;
221
+ };
222
+ modelValue: {
223
+ type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
224
+ default: null;
225
+ };
226
+ presetVal: {
227
+ type: StringConstructor;
228
+ default: null;
229
+ };
230
+ dateType: {
231
+ type: StringConstructor;
232
+ };
233
+ isDateDisabled: {
234
+ type: FunctionConstructor;
235
+ };
236
+ timeDisabled: {
237
+ type: FunctionConstructor;
238
+ };
239
+ valueFormat: {
240
+ type: StringConstructor;
241
+ };
242
+ }, {
243
+ widgetOptions: {
244
+ label: string;
245
+ value: string;
246
+ }[];
247
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
248
+ filterType: {
249
+ type: StringConstructor;
250
+ required: true;
251
+ };
252
+ modelValue: {
253
+ type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
254
+ default: null;
255
+ };
256
+ presetVal: {
257
+ type: StringConstructor;
258
+ default: null;
259
+ };
260
+ dateType: {
261
+ type: StringConstructor;
262
+ };
263
+ isDateDisabled: {
264
+ type: FunctionConstructor;
265
+ };
266
+ timeDisabled: {
267
+ type: FunctionConstructor;
268
+ };
269
+ valueFormat: {
270
+ type: StringConstructor;
271
+ };
272
+ }>> & {
273
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
274
+ "onUpdate:presetVal"?: ((...args: any[]) => any) | undefined;
275
+ }>>;
276
+ emit: (event: "update:modelValue" | "update:presetVal", ...args: any[]) => void;
277
+ valueCp: import("vue").WritableComputedRef<any>;
278
+ presetValCp: import("vue").WritableComputedRef<string>;
279
+ CDatePicker: import("../../../../../../shared/types").SFCWithInstall<import("vue").DefineComponent<{
280
+ updateUnchangedValue: {
281
+ type: BooleanConstructor;
282
+ };
283
+ onConfirm: {
284
+ type: FunctionConstructor;
285
+ };
286
+ formattedValue: {
287
+ type: PropType<(string | [string, string]) | null | undefined>;
288
+ };
289
+ placeholder: {
290
+ type: StringConstructor;
291
+ };
292
+ allowedInvalidValue: {
293
+ type: StringConstructor;
294
+ };
295
+ to: {
296
+ type: PropType<string | false | HTMLElement>;
297
+ default: string;
298
+ };
299
+ holidays: {
300
+ type: PropType<Date[]>;
301
+ default: () => never[];
302
+ };
303
+ type: {
304
+ type: StringConstructor;
305
+ default: string;
306
+ };
307
+ isDateDisabled: {
308
+ type: PropType<(current: number, ...arg: any[]) => boolean>;
309
+ };
310
+ }, {
311
+ attrs: {
312
+ [x: string]: unknown;
313
+ };
314
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
315
+ updateUnchangedValue: {
316
+ type: BooleanConstructor;
317
+ };
318
+ onConfirm: {
319
+ type: FunctionConstructor;
320
+ };
321
+ formattedValue: {
322
+ type: PropType<(string | [string, string]) | null | undefined>;
323
+ };
324
+ placeholder: {
325
+ type: StringConstructor;
326
+ };
327
+ allowedInvalidValue: {
328
+ type: StringConstructor;
329
+ };
330
+ to: {
331
+ type: PropType<string | false | HTMLElement>;
332
+ default: string;
333
+ };
334
+ holidays: {
335
+ type: PropType<Date[]>;
336
+ default: () => never[];
337
+ };
338
+ type: {
339
+ type: StringConstructor;
340
+ default: string;
341
+ };
342
+ isDateDisabled: {
343
+ type: PropType<(current: number, ...arg: any[]) => boolean>;
344
+ };
345
+ }>> & {
346
+ "onUpdate:formatted-value"?: ((...args: any[]) => any) | undefined;
347
+ }>>;
348
+ emit: (event: "update:formatted-value", ...args: any[]) => void;
349
+ datePickerRef: import("vue").Ref<import("../../../../../../shared/types").AnyObject | null>;
350
+ panelInstRef: import("vue").Ref<null>;
351
+ placeholderRef: import("vue").Ref<any>;
352
+ oldValue: string;
353
+ currentFormattedValue: import("vue").WritableComputedRef<(string | [string, string]) | null | undefined>;
354
+ isDateTime: import("vue").ComputedRef<boolean>;
355
+ formatRef: import("vue").ComputedRef<string>;
356
+ panelFormatRef: import("vue").ComputedRef<string | [string, string]>;
357
+ _isDateDisabled: import("vue").ComputedRef<(current: number, ...arg: any[]) => boolean>;
358
+ focus: () => any;
359
+ blur: () => any;
360
+ handleConfirm: (target: HTMLInputElement) => void;
361
+ onUpdateShow: (show: boolean) => Promise<void>;
362
+ watchers: import("../../../../../../shared/types").AnyFn[];
363
+ stopWatcher: () => void;
364
+ setHoliday: (show: boolean) => Promise<void>;
365
+ onConfirm: (...args: any[]) => Promise<void>;
366
+ isAllowedInvalidValue: (value: (string | [string, string]) | null | undefined) => boolean | "" | undefined;
367
+ setShortcutValue: (type: "month" | "week") => Promise<void>;
368
+ NDatePicker: any;
369
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:formatted-value"[], "update:formatted-value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
370
+ updateUnchangedValue: {
371
+ type: BooleanConstructor;
372
+ };
373
+ onConfirm: {
374
+ type: FunctionConstructor;
375
+ };
376
+ formattedValue: {
377
+ type: PropType<(string | [string, string]) | null | undefined>;
378
+ };
379
+ placeholder: {
380
+ type: StringConstructor;
381
+ };
382
+ allowedInvalidValue: {
383
+ type: StringConstructor;
384
+ };
385
+ to: {
386
+ type: PropType<string | false | HTMLElement>;
387
+ default: string;
388
+ };
389
+ holidays: {
390
+ type: PropType<Date[]>;
391
+ default: () => never[];
392
+ };
393
+ type: {
394
+ type: StringConstructor;
395
+ default: string;
396
+ };
397
+ isDateDisabled: {
398
+ type: PropType<(current: number, ...arg: any[]) => boolean>;
399
+ };
400
+ }>> & {
401
+ "onUpdate:formatted-value"?: ((...args: any[]) => any) | undefined;
402
+ }, {
403
+ type: string;
404
+ updateUnchangedValue: boolean;
405
+ to: string | false | HTMLElement;
406
+ holidays: Date[];
407
+ }>>;
408
+ NSelect: any;
409
+ NInputNumber: any;
410
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:presetVal")[], "update:modelValue" | "update:presetVal", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
411
+ filterType: {
412
+ type: StringConstructor;
413
+ required: true;
414
+ };
415
+ modelValue: {
416
+ type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
417
+ default: null;
418
+ };
419
+ presetVal: {
420
+ type: StringConstructor;
421
+ default: null;
422
+ };
423
+ dateType: {
424
+ type: StringConstructor;
425
+ };
426
+ isDateDisabled: {
427
+ type: FunctionConstructor;
428
+ };
429
+ timeDisabled: {
430
+ type: FunctionConstructor;
431
+ };
432
+ valueFormat: {
433
+ type: StringConstructor;
434
+ };
435
+ }>> & {
436
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
437
+ "onUpdate:presetVal"?: ((...args: any[]) => any) | undefined;
438
+ }, {
439
+ modelValue: string | number | unknown[];
440
+ presetVal: string;
441
+ }>;
208
442
  WidgetValEnums: {
209
443
  CUSTOM: string;
210
444
  FIRST_VAL: string;
@@ -237,6 +471,10 @@ declare const _default: import("vue").DefineComponent<{
237
471
  LAST_YEAR: string;
238
472
  };
239
473
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:presetVal" | "update:customDate")[], "update:modelValue" | "update:presetVal" | "update:customDate", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
474
+ item: {
475
+ type: ObjectConstructor;
476
+ required: true;
477
+ };
240
478
  paramCfg: {
241
479
  type: ObjectConstructor;
242
480
  default: null;
@@ -1,9 +1,10 @@
1
- import { defineComponent, ref, computed, watch, openBlock, createElementBlock, createVNode, unref, isRef, withCtx, toDisplayString, createCommentVNode } from 'vue';
1
+ import { defineComponent, ref, computed, watch, openBlock, createElementBlock, unref, Fragment, createVNode, isRef, withCtx, toDisplayString, createCommentVNode, createBlock } from 'vue';
2
2
  import { NSelect, NPopover } from 'naive-ui';
3
3
  import DatePicker from '../../../../../date-picker/index.js';
4
+ import DateOption from './Base/DateOption.vue.js';
4
5
  import moment from 'moment';
5
6
  import { isString } from 'lodash-es';
6
- import { WidgetOptionEnums, WidgetTypeEnums, WidgetValEnums } from '../../../types/enums.js';
7
+ import { ConditionEnums, WidgetOptionEnums, WidgetTypeEnums, WidgetValEnums } from '../../../types/enums.js';
7
8
  import { WidgetDateOptionEnums } from '../../render-widget/helpers/enums.js';
8
9
  import { widgetDateValOptions } from '../../render-widget/helpers/dateExtraMap.js';
9
10
  import { dateDisabledCollect, isStartDateRangeDisabled, isTimeStartRangeDisabled, isEndDateRangeDisabled, isTimeEndRangeDisabled } from '../../render-widget/helpers/dateDisabled.js';
@@ -29,6 +30,10 @@ const _hoisted_4 = {
29
30
  var _sfc_main = /* @__PURE__ */ defineComponent({
30
31
  __name: "DateRange",
31
32
  props: {
33
+ item: {
34
+ type: Object,
35
+ required: true
36
+ },
32
37
  paramCfg: {
33
38
  type: Object,
34
39
  default: null
@@ -53,6 +58,27 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
53
58
  const props = __props;
54
59
  const startDate = ref();
55
60
  const endDate = ref();
61
+ const filterType = computed(() => {
62
+ switch (props.item.condition) {
63
+ case ConditionEnums.EQUAL:
64
+ case ConditionEnums.NEQ:
65
+ return "1";
66
+ case ConditionEnums.BIG:
67
+ case ConditionEnums.LESS:
68
+ case ConditionEnums.BIGEQ:
69
+ case ConditionEnums.LESSEQ:
70
+ return "2";
71
+ case ConditionEnums.L_:
72
+ case ConditionEnums.N_:
73
+ case ConditionEnums.IN_THE_PAST:
74
+ case ConditionEnums.IN_THE_FUTURE:
75
+ case ConditionEnums.IN_THE_PAST_DI:
76
+ case ConditionEnums.IN_THE_FUTURE_DI:
77
+ return "3";
78
+ default:
79
+ return "1";
80
+ }
81
+ });
56
82
  const valueFormat = computed(() => {
57
83
  let formateStr = "";
58
84
  switch (compType.value) {
@@ -203,16 +229,22 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
203
229
  return props.presetVal;
204
230
  }
205
231
  });
206
- computed({
232
+ const valueDateCp = computed({
207
233
  set(val) {
208
- emit("update:customDate", val);
234
+ if (val && filterType.value !== "1") {
235
+ const v = typeof val === "number" ? String(val) : val;
236
+ emit("update:modelValue", v);
237
+ }
209
238
  },
210
239
  get() {
211
- return props.customDate;
240
+ if (props.modelValue && filterType.value !== "1") {
241
+ return props.modelValue;
242
+ }
243
+ return null;
212
244
  }
213
245
  });
214
246
  watch(() => props.modelValue, (val) => {
215
- if (val && isString(val) && val.includes("~")) {
247
+ if (val && filterType.value !== "1" && isString(val) && val.includes("~")) {
216
248
  const [start, end] = val.split("~");
217
249
  if (start.trim())
218
250
  startDate.value = moment(start.trim()).valueOf();
@@ -250,7 +282,9 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
250
282
  return isTimeEndRangeDisabled(ts, optionSetting.value, startDate.value);
251
283
  }
252
284
  return (_ctx, _cache) => {
253
- return openBlock(), createElementBlock("div", _hoisted_1, [createVNode(unref(NSelect), {
285
+ return openBlock(), createElementBlock("div", _hoisted_1, [unref(filterType) === "1" ? (openBlock(), createElementBlock(Fragment, {
286
+ key: 0
287
+ }, [createVNode(unref(NSelect), {
254
288
  style: {
255
289
  "width": "120px"
256
290
  },
@@ -298,7 +332,16 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
298
332
  }, null, 8, ["type", "default-time", "valueFormat", "placeholder", "value"])]),
299
333
  default: withCtx(() => [unref(endDateFormat) ? (openBlock(), createElementBlock("span", _hoisted_4, toDisplayString(unref(endDateFormat)), 1)) : createCommentVNode("v-if", true)]),
300
334
  _: 1
301
- }, 8, ["disabled"])])) : createCommentVNode("v-if", true)]);
335
+ }, 8, ["disabled"])])) : createCommentVNode("v-if", true)], 64)) : (openBlock(), createBlock(DateOption, {
336
+ key: 1,
337
+ filterType: unref(filterType),
338
+ dateType: unref(dateType),
339
+ valueFormat: unref(valueFormat),
340
+ modelValue: unref(valueDateCp),
341
+ "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => isRef(valueDateCp) ? valueDateCp.value = $event : null),
342
+ presetVal: unref(presetValCp),
343
+ "onUpdate:presetVal": _cache[4] || (_cache[4] = ($event) => isRef(presetValCp) ? presetValCp.value = $event : null)
344
+ }, null, 8, ["filterType", "dateType", "valueFormat", "modelValue", "presetVal"]))]);
302
345
  };
303
346
  }
304
347
  });