cnhis-design-vue 3.1.46-beta.0 → 3.1.46-beta.2

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 (121) hide show
  1. package/README.md +87 -87
  2. package/es/components/base-search/index.d.ts +17 -8
  3. package/es/components/base-search/src/index.vue.d.ts +17 -8
  4. package/es/components/base-search/src/index.vue2.js +1 -1
  5. package/es/components/base-search/style/index.css +1 -1
  6. package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
  7. package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
  8. package/es/components/bpmn-workflow/types/ModelingModule.d.ts +1 -0
  9. package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
  10. package/es/components/classification/index.d.ts +219 -18
  11. package/es/components/classification/src/components/search-filter/index.vue.d.ts +219 -18
  12. package/es/components/classification/src/components/search-filter/index.vue2.js +1 -1
  13. package/es/components/classification/src/components/set-classification/index.vue.d.ts +219 -18
  14. package/es/components/classification/src/index.vue.d.ts +219 -18
  15. package/es/components/form-render/src/components/renderer/radio_checkbox.js +1 -1
  16. package/es/components/index.css +1 -1
  17. package/es/components/quick-search/index.d.ts +21 -7
  18. package/es/components/quick-search/src/index.vue.d.ts +21 -7
  19. package/es/components/quick-search/src/index.vue2.js +1 -1
  20. package/es/components/quick-search/style/index.css +1 -1
  21. package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
  22. package/es/components/select-label/src/LabelFormContent.vue2.js +1 -1
  23. package/es/components/select-person/src/SearchMultiple.vue.d.ts +0 -6
  24. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.d.ts +219 -17
  25. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue2.js +1 -1
  26. package/es/components/table-filter/src/components/classify-filter/components/Date.vue.d.ts +17 -1
  27. package/es/components/table-filter/src/components/classify-filter/components/Date.vue2.js +1 -1
  28. package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue.d.ts +19 -0
  29. package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue2.js +1 -1
  30. package/es/components/table-filter/src/components/classify-filter/components/SelectDynamic.vue.d.ts +178 -11
  31. package/es/components/table-filter/src/components/classify-filter/components/SelectDynamic.vue2.js +1 -1
  32. package/es/components/table-filter/src/components/classify-filter/components/SelectFilter.vue.d.ts +1 -5
  33. package/es/components/table-filter/src/components/classify-filter/components/SelectFilter.vue2.js +1 -1
  34. package/es/components/table-filter/src/components/classify-filter/components/SelectLabel.vue.d.ts +2 -1
  35. package/es/components/table-filter/src/components/classify-filter/components/SelectLabel.vue2.js +1 -1
  36. package/es/components/table-filter/src/components/classify-filter/components/index.d.ts +217 -17
  37. package/es/components/table-filter/src/components/classify-filter/hooks/useFilterConditions.js +1 -1
  38. package/es/components/table-filter/src/components/classify-filter/index.vue.d.ts +219 -17
  39. package/es/components/table-filter/src/components/classify-filter/index.vue2.js +1 -1
  40. package/es/components/table-filter/src/components/render-widget/components/DateInner.vue.d.ts +231 -0
  41. package/es/components/table-filter/src/components/render-widget/components/DateInner.vue.js +1 -0
  42. package/es/components/table-filter/src/components/render-widget/components/DateInner.vue2.js +1 -0
  43. package/es/components/table-filter/src/components/render-widget/components/{Date.vue.d.ts → DateOut.vue.d.ts} +21 -2
  44. package/es/components/table-filter/src/components/render-widget/components/DateOut.vue.js +1 -0
  45. package/es/components/table-filter/src/components/render-widget/components/DateOut.vue2.js +1 -0
  46. package/es/components/table-filter/src/components/render-widget/components/DateQuickBtn/index.vue.d.ts +71 -0
  47. package/es/components/table-filter/src/components/render-widget/components/DateQuickBtn/index.vue.js +1 -0
  48. package/es/components/table-filter/src/components/render-widget/components/DateQuickBtn/index.vue2.js +1 -0
  49. package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue.d.ts +117 -8
  50. package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue2.js +1 -1
  51. package/es/components/table-filter/src/components/render-widget/components/DateRangeOut.vue.d.ts +13 -9
  52. package/es/components/table-filter/src/components/render-widget/components/DateRangeOut.vue2.js +1 -1
  53. package/es/components/table-filter/src/components/render-widget/components/LabelInner.vue.d.ts +8 -6
  54. package/es/components/table-filter/src/components/render-widget/components/LabelInner.vue2.js +1 -1
  55. package/es/components/table-filter/src/components/render-widget/components/LabelOut.vue.d.ts +7 -6
  56. package/es/components/table-filter/src/components/render-widget/components/LabelOut.vue2.js +1 -1
  57. package/es/components/table-filter/src/components/render-widget/components/Select.vue.d.ts +19 -25
  58. package/es/components/table-filter/src/components/render-widget/components/Select.vue2.js +1 -1
  59. package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue.d.ts +223 -0
  60. package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue.js +1 -0
  61. package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue2.js +1 -0
  62. package/es/components/table-filter/src/components/render-widget/components/SelectDynamicOption/index.vue.d.ts +158 -0
  63. package/es/components/table-filter/src/components/render-widget/components/SelectDynamicOption/index.vue.js +1 -0
  64. package/es/components/table-filter/src/components/render-widget/components/SelectDynamicOption/index.vue2.js +1 -0
  65. package/es/components/table-filter/src/components/render-widget/components/index.d.ts +611 -36
  66. package/es/components/table-filter/src/components/render-widget/components/index.js +1 -1
  67. package/es/components/table-filter/src/components/render-widget/enums.d.ts +10 -3
  68. package/es/components/table-filter/src/components/render-widget/enums.js +1 -1
  69. package/es/components/table-filter/src/components/render-widget/helpers/dateDisabled.d.ts +27 -0
  70. package/es/components/table-filter/src/components/render-widget/helpers/dateDisabled.js +1 -0
  71. package/es/components/table-filter/src/components/render-widget/helpers/dateExtraMap.d.ts +55 -0
  72. package/es/components/table-filter/src/components/render-widget/helpers/dateExtraMap.js +1 -0
  73. package/es/components/table-filter/src/components/render-widget/helpers/enums.d.ts +56 -0
  74. package/es/components/table-filter/src/components/render-widget/helpers/enums.js +1 -0
  75. package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.d.ts +2 -6
  76. package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.js +1 -1
  77. package/es/components/table-filter/src/components/render-widget/helpers/selectExtraMap.d.ts +4 -0
  78. package/es/components/table-filter/src/components/render-widget/helpers/selectExtraMap.js +1 -0
  79. package/es/components/table-filter/src/components/render-widget/helpers/setDefaultValue.d.ts +4 -0
  80. package/es/components/table-filter/src/components/render-widget/helpers/setDefaultValue.js +1 -0
  81. package/es/components/table-filter/src/components/render-widget/index.vue.d.ts +4 -3
  82. package/es/components/table-filter/src/components/render-widget/index.vue.js +1 -1
  83. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +639 -35
  84. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.js +1 -1
  85. package/es/components/table-filter/src/constants/index.d.ts +3 -1
  86. package/es/components/table-filter/src/constants/index.js +1 -1
  87. package/es/components/table-filter/src/hooks/useAdvanced.d.ts +9 -4
  88. package/es/components/table-filter/src/hooks/useAdvanced.js +1 -1
  89. package/es/components/table-filter/src/hooks/useAsyncData.d.ts +4 -0
  90. package/es/components/table-filter/src/hooks/useAsyncData.js +1 -0
  91. package/es/components/table-filter/src/hooks/useRenderWidget.d.ts +3 -3
  92. package/es/components/table-filter/src/hooks/useRenderWidget.js +1 -1
  93. package/es/components/table-filter/src/tool/baseOptions.d.ts +0 -8
  94. package/es/components/table-filter/src/tool/baseOptions.js +1 -1
  95. package/es/components/table-filter/src/tool/transformData.d.ts +0 -1
  96. package/es/components/table-filter/src/tool/transformData.js +1 -1
  97. package/es/components/table-filter/src/types/enums.d.ts +3 -0
  98. package/es/components/table-filter/src/types/enums.js +1 -1
  99. package/es/components/table-filter/src/types/index.d.ts +7 -0
  100. package/es/env.d.ts +25 -25
  101. package/es/shared/assets/img/failure.png.js +1 -1
  102. package/es/shared/assets/img/no-permission.png.js +1 -1
  103. package/es/shared/assets/img/nodata.png.js +1 -1
  104. package/es/shared/assets/img/notfound.png.js +1 -1
  105. package/es/shared/assets/img/qr.png.js +1 -1
  106. package/es/shared/assets/img/success.png.js +1 -1
  107. package/es/shared/assets/img/video.png.js +1 -1
  108. package/es/shared/assets/img/video_default_cover.png.js +1 -1
  109. package/es/shared/assets/img/xb_big.png.js +1 -1
  110. package/es/shared/assets/img/xb_small.png.js +1 -1
  111. package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +86 -0
  112. package/es/shared/package.json.js +1 -1
  113. package/es/shared/utils/fabricjs/index.d.ts +6823 -0
  114. package/es/shared/utils/tapable/index.d.ts +139 -0
  115. package/package.json +2 -2
  116. package/es/components/table-filter/src/components/render-widget/basicData.d.ts +0 -4
  117. package/es/components/table-filter/src/components/render-widget/basicData.js +0 -1
  118. package/es/components/table-filter/src/components/render-widget/components/Date.vue.js +0 -1
  119. package/es/components/table-filter/src/components/render-widget/components/Date.vue2.js +0 -1
  120. package/es/components/table-filter/src/tool/generateDefOptions.d.ts +0 -7
  121. package/es/components/table-filter/src/tool/generateDefOptions.js +0 -1
@@ -154,6 +154,9 @@ declare const _default: import("vue").DefineComponent<{
154
154
  presetValCp: import("vue").WritableComputedRef<string>;
155
155
  widgetType: import("vue").ComputedRef<any>;
156
156
  Date: import("vue").DefineComponent<{
157
+ componentCfg: {
158
+ type: ObjectConstructor;
159
+ };
157
160
  paramCfg: {
158
161
  type: ObjectConstructor;
159
162
  default: null;
@@ -168,6 +171,9 @@ declare const _default: import("vue").DefineComponent<{
168
171
  };
169
172
  }, {
170
173
  props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
174
+ componentCfg: {
175
+ type: ObjectConstructor;
176
+ };
171
177
  paramCfg: {
172
178
  type: ObjectConstructor;
173
179
  default: null;
@@ -190,11 +196,17 @@ declare const _default: import("vue").DefineComponent<{
190
196
  dateType: any;
191
197
  valueFormat: import("vue").ComputedRef<string>;
192
198
  compType: import("vue").ComputedRef<any>;
193
- mappingConfig: import("vue").ComputedRef<any>;
199
+ optionSetting: import("vue").ComputedRef<any>;
194
200
  widgetOptions: import("vue").ComputedRef<{
195
201
  label: string;
196
202
  value: string;
197
203
  }[]>;
204
+ isDateDisabled: (ts: number) => boolean;
205
+ timeDisabled: (ts: number) => {
206
+ isHourDisabled(hour: number): boolean | undefined;
207
+ isMinuteDisabled(minute: number, hour: number | null): boolean | undefined;
208
+ isSecondDisabled(second: number, minute: number | null, hour: number | null): boolean | undefined;
209
+ };
198
210
  CDatePicker: import("../../../..").SFCWithInstall<import("vue").DefineComponent<{
199
211
  updateUnchangedValue: {
200
212
  type: BooleanConstructor;
@@ -238,6 +250,7 @@ declare const _default: import("vue").DefineComponent<{
238
250
  WidgetValEnums: {
239
251
  CUSTOM: string;
240
252
  FIRST_VAL: string;
253
+ WHOLE: string;
241
254
  NOW: string;
242
255
  TODAY: string;
243
256
  TODAY_START: string;
@@ -266,6 +279,9 @@ declare const _default: import("vue").DefineComponent<{
266
279
  LAST_YEAR: string;
267
280
  };
268
281
  }, 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<{
282
+ componentCfg: {
283
+ type: ObjectConstructor;
284
+ };
269
285
  paramCfg: {
270
286
  type: ObjectConstructor;
271
287
  default: null;
@@ -373,11 +389,7 @@ declare const _default: import("vue").DefineComponent<{
373
389
  emit: (event: "update:modelValue", ...args: any[]) => void;
374
390
  valueCp: import("vue").WritableComputedRef<any>;
375
391
  optionSetting: import("vue").ComputedRef<any>;
376
- mappingConfig: import("vue").ComputedRef<any>;
377
- widgetOptions: import("vue").ComputedRef<{
378
- label: string;
379
- value: string;
380
- }[]>;
392
+ widgetOptions: import("vue").ComputedRef<any>;
381
393
  NSelect: any;
382
394
  WidgetOptionEnums: {
383
395
  RADIO: string;
@@ -417,6 +429,7 @@ declare const _default: import("vue").DefineComponent<{
417
429
  default: null;
418
430
  };
419
431
  }, {
432
+ message: import("naive-ui").MessageApi;
420
433
  props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
421
434
  paramCfg: {
422
435
  type: ObjectConstructor;
@@ -429,28 +442,195 @@ declare const _default: import("vue").DefineComponent<{
429
442
  }>> & {
430
443
  "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
431
444
  }>>;
432
- handleGetConfigApi: (params: any, key: string, config: {} | undefined, filterApiConfigVal: any) => Promise<any>;
433
- $attrs: {
434
- [x: string]: unknown;
435
- };
445
+ getDynamicSelectData: (params: any, filterApiConfig: any) => Promise<any>;
436
446
  emit: (event: "update:modelValue", ...args: any[]) => void;
437
- selectOptions: import("vue").Ref<any[]>;
438
447
  isLoading: import("vue").Ref<boolean>;
439
448
  filterApiConfig: import("../../../..").AnyObject;
440
- valueCp: import("vue").WritableComputedRef<any>;
449
+ classifyFilterList: import("vue").Ref<import("../../../..").AnyObject[]>;
450
+ totalPage: import("vue").Ref<number>;
451
+ menuProps: {
452
+ class: string;
453
+ };
454
+ curPage: import("vue").Ref<number>;
455
+ fieldTitleList: import("vue").Ref<any>;
456
+ selectOptions: import("vue").Ref<any[]>;
457
+ keywordVal: import("vue").Ref<any>;
441
458
  optionSetting: import("vue").ComputedRef<any>;
442
459
  isMultiple: import("vue").ComputedRef<boolean>;
443
- searchOptions: (keyword: string) => Promise<any>;
460
+ dynamicOptionInfos: import("vue").ComputedRef<any>;
461
+ isLastPage: import("vue").ComputedRef<boolean>;
462
+ valueCp: import("vue").ComputedRef<string | number | any[]>;
463
+ isInitRequest: import("vue").ComputedRef<boolean>;
464
+ setOptionActive: (selectIds: string[]) => void;
465
+ handleUpdateSelect: (value: string[] | null) => void;
466
+ handleUpdatePage: (page: number) => Promise<void>;
467
+ getOptionsData: (keyword: string, curPage: number) => Promise<any>;
468
+ isWhole: (value: string) => boolean;
444
469
  _handleSearch: (query: string) => Promise<void>;
445
470
  handleSearch: (query: string) => Promise<void>;
446
471
  handleInitData: () => Promise<void>;
447
- renderLabel: (option: import("naive-ui").SelectOption) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
448
- [key: string]: any;
449
- }>;
472
+ handleClear: () => Promise<void>;
473
+ handleUpdateShow: (show: boolean) => void;
450
474
  renderTag: ({ option, handleClose }: any) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
451
475
  [key: string]: any;
452
476
  }>;
477
+ init: () => void;
453
478
  NSelect: any;
479
+ SelectDynamicOption: import("vue").DefineComponent<{
480
+ dynamicOptionInfo: {
481
+ type: PropType<import("../../../..").AnyObject>;
482
+ default: () => {};
483
+ };
484
+ fieldTitleList: {
485
+ type: PropType<import("../../../..").AnyObject[]>;
486
+ default: () => never[];
487
+ };
488
+ optionList: {
489
+ type: PropType<import("../../../..").AnyObject[]>;
490
+ default: () => never[];
491
+ };
492
+ isMultiple: {
493
+ type: BooleanConstructor;
494
+ default: boolean;
495
+ };
496
+ curPage: {
497
+ type: NumberConstructor;
498
+ default: number;
499
+ };
500
+ isLastPage: {
501
+ type: BooleanConstructor;
502
+ default: boolean;
503
+ };
504
+ isShowWhole: {
505
+ type: BooleanConstructor;
506
+ default: boolean;
507
+ };
508
+ }, {
509
+ selectMinWidth: number;
510
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
511
+ dynamicOptionInfo: {
512
+ type: PropType<import("../../../..").AnyObject>;
513
+ default: () => {};
514
+ };
515
+ fieldTitleList: {
516
+ type: PropType<import("../../../..").AnyObject[]>;
517
+ default: () => never[];
518
+ };
519
+ optionList: {
520
+ type: PropType<import("../../../..").AnyObject[]>;
521
+ default: () => never[];
522
+ };
523
+ isMultiple: {
524
+ type: BooleanConstructor;
525
+ default: boolean;
526
+ };
527
+ curPage: {
528
+ type: NumberConstructor;
529
+ default: number;
530
+ };
531
+ isLastPage: {
532
+ type: BooleanConstructor;
533
+ default: boolean;
534
+ };
535
+ isShowWhole: {
536
+ type: BooleanConstructor;
537
+ default: boolean;
538
+ };
539
+ }>> & {
540
+ onUpdateSelect?: ((...args: any[]) => any) | undefined;
541
+ onUpdatePage?: ((...args: any[]) => any) | undefined;
542
+ }>>;
543
+ emit: (event: "updateSelect" | "updatePage", ...args: any[]) => void;
544
+ dragEndWidth: import("vue").Ref<number>;
545
+ showKeys: import("vue").ComputedRef<any>;
546
+ titleList: import("vue").ComputedRef<string[]>;
547
+ handleSelect: (option: any) => void;
548
+ searchByPage: (onePage: number) => void;
549
+ changeWidth: ({ distance }: any) => void;
550
+ saveWidth: () => void;
551
+ NEmpty: any;
552
+ NButtonGroup: any;
553
+ NButton: any;
554
+ NIcon: any;
555
+ NPopover: any;
556
+ vFlexibleResize: {
557
+ mounted(el: any, { value }: any): void;
558
+ beforeUnmount(el: any): void;
559
+ };
560
+ WidgetValEnums: {
561
+ CUSTOM: string;
562
+ FIRST_VAL: string;
563
+ WHOLE: string;
564
+ NOW: string;
565
+ TODAY: string;
566
+ TODAY_START: string;
567
+ TODAY_END: string;
568
+ TOMORROW: string;
569
+ TOMORROW_START: string;
570
+ TOMORROW_END: string;
571
+ YESTERDAY: string;
572
+ YESTERDAY_START: string;
573
+ YESTERDAY_END: string;
574
+ THIS_WEEK: string;
575
+ WEEK_START: string;
576
+ WEEK_END: string;
577
+ NEXT_WEEK: string;
578
+ LAST_WEEK: string;
579
+ THIS_MONTH: string;
580
+ MONTH_START: string;
581
+ MONTH_END: string;
582
+ NEXT_MONTH: string;
583
+ LAST_MONTH: string;
584
+ THIS_QUARTER: string;
585
+ NEXT_QUARTER: string;
586
+ LAST_QUARTER: string;
587
+ THIS_YEAR: string;
588
+ NEXT_YEAR: string;
589
+ LAST_YEAR: string;
590
+ };
591
+ ArrowBack: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
592
+ ArrowForward: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
593
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("updateSelect" | "updatePage")[], "updateSelect" | "updatePage", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
594
+ dynamicOptionInfo: {
595
+ type: PropType<import("../../../..").AnyObject>;
596
+ default: () => {};
597
+ };
598
+ fieldTitleList: {
599
+ type: PropType<import("../../../..").AnyObject[]>;
600
+ default: () => never[];
601
+ };
602
+ optionList: {
603
+ type: PropType<import("../../../..").AnyObject[]>;
604
+ default: () => never[];
605
+ };
606
+ isMultiple: {
607
+ type: BooleanConstructor;
608
+ default: boolean;
609
+ };
610
+ curPage: {
611
+ type: NumberConstructor;
612
+ default: number;
613
+ };
614
+ isLastPage: {
615
+ type: BooleanConstructor;
616
+ default: boolean;
617
+ };
618
+ isShowWhole: {
619
+ type: BooleanConstructor;
620
+ default: boolean;
621
+ };
622
+ }>> & {
623
+ onUpdateSelect?: ((...args: any[]) => any) | undefined;
624
+ onUpdatePage?: ((...args: any[]) => any) | undefined;
625
+ }, {
626
+ dynamicOptionInfo: import("../../../..").AnyObject;
627
+ fieldTitleList: import("../../../..").AnyObject[];
628
+ optionList: import("../../../..").AnyObject[];
629
+ isMultiple: boolean;
630
+ curPage: number;
631
+ isLastPage: boolean;
632
+ isShowWhole: boolean;
633
+ }>;
454
634
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
455
635
  paramCfg: {
456
636
  type: ObjectConstructor;
@@ -556,8 +736,15 @@ declare const _default: import("vue").DefineComponent<{
556
736
  valueFormat: import("vue").ComputedRef<string>;
557
737
  dateFormat: import("vue").ComputedRef<string>;
558
738
  compType: import("vue").ComputedRef<any>;
739
+ optionSetting: import("vue").ComputedRef<any>;
740
+ isPastTime: import("vue").ComputedRef<boolean>;
741
+ isFutureTime: import("vue").ComputedRef<boolean>;
559
742
  startPlaceholder: import("vue").ComputedRef<"初始日期" | "初始时间">;
560
743
  endPlaceholder: import("vue").ComputedRef<"截止日期" | "截止时间">;
744
+ startDefault: import("vue").ComputedRef<string>;
745
+ endDefault: import("vue").ComputedRef<string>;
746
+ startDateFormat: import("vue").ComputedRef<string | null>;
747
+ endDateFormat: import("vue").ComputedRef<string | null>;
561
748
  dateType: any;
562
749
  widgetOptions: import("vue").ComputedRef<{
563
750
  label: string;
@@ -566,8 +753,19 @@ declare const _default: import("vue").DefineComponent<{
566
753
  presetValCp: import("vue").WritableComputedRef<string>;
567
754
  handleChange: (val: any, type: "end" | "start") => void;
568
755
  isStartDateDisabled: (ts: number) => boolean;
756
+ timeStartDisabled: (ts: number) => {
757
+ isHourDisabled(hour: number): boolean | 0;
758
+ isMinuteDisabled(minute: number, hour: number | null): boolean | 0;
759
+ isSecondDisabled(second: number, minute: number | null, hour: number | null): boolean | 0;
760
+ };
569
761
  isEndDateDisabled: (ts: number) => boolean;
762
+ timeEndDisabled: (ts: number) => {
763
+ isHourDisabled(hour: number): boolean | 0;
764
+ isMinuteDisabled(minute: number, hour: number | null): boolean | 0;
765
+ isSecondDisabled(second: number, minute: number | null, hour: number | null): boolean | 0;
766
+ };
570
767
  NSelect: any;
768
+ NPopover: any;
571
769
  CDatePicker: import("../../../..").SFCWithInstall<import("vue").DefineComponent<{
572
770
  updateUnchangedValue: {
573
771
  type: BooleanConstructor;
@@ -610,6 +808,7 @@ declare const _default: import("vue").DefineComponent<{
610
808
  WidgetValEnums: {
611
809
  CUSTOM: string;
612
810
  FIRST_VAL: string;
811
+ WHOLE: string;
613
812
  NOW: string;
614
813
  TODAY: string;
615
814
  TODAY_START: string;
@@ -668,7 +867,8 @@ declare const _default: import("vue").DefineComponent<{
668
867
  default: null;
669
868
  };
670
869
  }, {
671
- handleGetConfigApi: (params: any, key: string, config: {} | undefined, filterApiConfigVal: any) => Promise<any>;
870
+ getDynamicLabelData: (params: any, filterApiConfig: any) => Promise<any>;
871
+ message: import("naive-ui").MessageApi;
672
872
  props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
673
873
  paramCfg: {
674
874
  type: ObjectConstructor;
@@ -708,7 +908,9 @@ declare const _default: import("vue").DefineComponent<{
708
908
  INPUT: string;
709
909
  SELECT: string;
710
910
  DATE: string;
911
+ DATE_OUT: string;
711
912
  DATE_TIME: string;
913
+ DATETIME_OUT: string;
712
914
  CHECKBOX_GROUP: string;
713
915
  INPUTNUMBER_RANGE: string;
714
916
  DATE_RANGE_OUT: string;
@@ -1 +1 @@
1
- import{defineComponent as e,useAttrs as a,reactive as t,ref as l,toRef as i,openBlock as n,createElementBlock as o,createVNode as s,unref as d,withCtx as r,createElementVNode as c,createCommentVNode as p,Fragment as u,renderList as y,normalizeClass as m,toDisplayString as v,createBlock as f,withDirectives as g,createTextVNode as C,vShow as h}from"vue";import{useMessage as k,NSpin as b,NInput as A,NIcon as L,NButton as w,NSelect as _,NTooltip as U}from"naive-ui";import{CloseOutline as N,AddOutline as V,AddCircleSharp as D}from"@vicons/ionicons5";import x from"./ValueCfg.vue.js";import{DataTypeEnums as B,ConditionEnums as I}from"../../types/enums.js";import{useDisplayCategory as S}from"./hooks/useDisplayCategory.js";import{useFilterConditions as j}from"./hooks/useFilterConditions.js";import{conditionOptions as F}from"./helpers/options.js";const z={class:"searchConditionByApi_wrapper"},O={class:"class-filter-content"},P={key:0,class:"item-name"},q=c("span",{class:"label"},"筛选分类名称:",-1),E={key:1,class:"quickSearch-content"},R=c("span",{class:"label"},"父类名称:",-1),J=["onDblclick","onClick"],K={key:0,class:"s-content"},M={key:2,class:"item-name"},Q=c("span",{class:"label"}," 过滤条件: ",-1),G=c("span",null,"添加",-1),H={class:"select-item-list"},T={class:"index-span"},W=["onClick"];var X=e({__name:"index",props:{actionList_prop:{type:Object,default:()=>({})},conditionList:{type:Array,default:()=>[]},tableId:{type:String,default:""},searchFieldList:{type:Array,default:()=>[]},showItemName:{type:Boolean,default:!0},hideAddBtn:{type:Boolean,default:!1}},emits:["saveAdd","cancelSaveAdd"],setup(e,{expose:X,emit:Y}){const Z=e,$=k(),ee=a(),ae=t({className:"",displayCategory:"",filterConditions:[]}),te=l(!1),{State:le,isEnableAddDisplayCategory:ie,editDisplayCategory:ne,handleDisplayCategorySelect:oe,handleDisplayCategoryRemove:se,handleDisplayCategoryAdd:de,handlerBlur:re,initDisplayCategories:ce}=S(i(ae,"displayCategory"),{conditionList:Z.conditionList},$),{State:pe,paramOptions:ue,addFilterCondition:ye,delFilterCondition:me,updateKey:ve,updateCondition:fe,getParamCfg:ge,initFilterConditions:Ce,getRawFilterConditions:he}=j(i(ae,"filterConditions"),Z.searchFieldList,B.API);function ke(){ae.className="",ae.displayCategory="",ae.filterConditions=[]}async function be(){var e;try{if(ke(),te.value=!0,ce(ee.displayCategoryList,Z.actionList_prop.displayCategory||void 0),Z.actionList_prop){ae.className=Z.actionList_prop.name,await Ce(Z.tableId,null!=(e=Z.actionList_prop.conObj)?e:[]);ae.filterConditions.length<1&&ue.value&&ue.value.length>0&&ye()}}finally{te.value=!1}}return be(),X({handleInitConditions:be,saveAdd:function(){new Promise((e=>{ae.className||!Z.showItemName?0!==ae.filterConditions.length?ae.filterConditions.some((({key:e,condition:a,value:t,presetVal:l})=>!e||!a||a===I.EQUAL&&!t&&!l))?$.warning("请补充完整条件内容"):e(!0):$.warning("请至少添加一个条件"):$.warning("请输入分类名称")})).then((()=>{let e;var a;"edit"===Z.actionList_prop.from&&(a=Z.actionList_prop.displayCategory,e=null==Z?void 0:Z.conditionList.find((e=>e.displayCategory===a)));const t={displayCategory:ae.displayCategory,name:ae.className||"",conObj:he()},l={id:e?e.sid:"",tableId:Z.tableId,setting:JSON.stringify(t)};Y("saveAdd",l,!1)}))},cancelSaveAdd:function(){ke(),Y("cancelSaveAdd")},addAction:ye,checkActionList:function(){return ae.filterConditions.every((e=>!e.field_key))}}),(a,t)=>(n(),o("div",z,[s(d(b),{show:te.value},{default:r((()=>[c("div",O,[e.showItemName?(n(),o("div",P,[q,s(d(A),{value:ae.className,"onUpdate:value":t[0]||(t[0]=e=>ae.className=e),placeholder:"请输入分类名称",style:{width:"250px"},maxlength:"10"},null,8,["value"])])):p("v-if",!0),e.showItemName?(n(),o("div",E,[R,(n(!0),o(u,null,y(d(le).displayCategories,((e,a)=>(n(),o("div",{class:m(["edit-tag",{"edit-tag-select":e.value===ae.displayCategory&&e.disabled}]),key:a,onDblclick:a=>d(ne)(a,e),onClick:a=>function(e){oe(e)}(e)},[e.disabled?(n(),o("div",K,[c("span",null,v(e.value),1)])):(n(),f(d(A),{key:1,style:{width:"100px"},disabled:e.disabled,onBlur:()=>e.disabled=!0,value:e.value,"onUpdate:value":a=>e.value=a,maxlength:10},null,8,["disabled","onBlur","value","onUpdate:value"])),s(d(L),{component:d(N),class:"anticon-close",size:"20",onClick:t=>d(se)(a,e)},null,8,["component","onClick"])],42,J)))),128)),d(ie)?(n(),o(u,{key:0},[g(s(d(w),{class:"ant-btn",icon:"plus",dashed:"",onClick:d(de)},{default:r((()=>[s(d(L),{component:d(V),size:"20"},null,8,["component"]),C(" "+v("添加父类"))])),_:1},8,["onClick"]),[[h,!d(le).showAdd]]),g(s(d(A),{class:"edit-tag",value:d(le).addDisplayCategory,"onUpdate:value":t[1]||(t[1]=e=>d(le).addDisplayCategory=e),valueModifiers:{trim:!0},style:{width:"100px"},onBlur:d(re),maxLength:10},null,8,["value","onBlur"]),[[h,d(le).showAdd]])],64)):p("v-if",!0)])):p("v-if",!0),e.hideAddBtn?p("v-if",!0):(n(),o("div",M,[Q,c("span",{class:"addAction",onClick:t[2]||(t[2]=(...e)=>d(ye)&&d(ye)(...e)),style:{cursor:"pointer"}},[s(d(L),{component:d(D),class:"blue",size:"18"},null,8,["component"]),G])])),c("ul",H,[(n(!0),o(u,null,y(ae.filterConditions,((e,a)=>(n(),o("li",{key:a},[c("span",T,v(a+1)+"   ",1),p(" 选择 field_key "),s(d(_),{class:"form-item",placeholder:"请选择",value:e.key,to:"body",filterable:"",options:d(ue),"onUpdate:value":e=>d(ve)(a,e)},null,8,["value","options","onUpdate:value"]),p(" 选择 关系 "),e.key?(n(),f(d(_),{key:0,class:"form-item",placeholder:"请选择",value:e.condition,to:"body",filterable:"",options:d(F),"onUpdate:value":e=>d(fe)(a,e)},null,8,["value","options","onUpdate:value"])):p("v-if",!0),p(" 自定义 "),e.key&&e.condition&&e.condition!==d(I).NULL?(n(),f(x,{key:1,modelValue:e.value,"onUpdate:modelValue":a=>e.value=a,presetVal:e.presetVal,"onUpdate:presetVal":a=>e.presetVal=a,"param-cfg":d(ge)(e.key)},null,8,["modelValue","onUpdate:modelValue","presetVal","onUpdate:presetVal","param-cfg"])):p("v-if",!0),s(d(U),{title:"删除",trigger:"hover"},{trigger:r((()=>[c("i",{onClick:e=>d(me)(a),class:"iconfont-table-filter delete-item-icon icon-table-filter-menzhenyishengzhananniuqingchu"},null,8,W)])),default:r((()=>[C(" 删除 ")])),_:2},1024)])))),128))])])])),_:1},8,["show"])]))}});export{X as default};
1
+ import{defineComponent as e,useAttrs as a,reactive as t,ref as i,provide as l,toRef as n,openBlock as o,createElementBlock as s,createVNode as d,unref as r,withCtx as c,createElementVNode as p,createCommentVNode as u,Fragment as y,renderList as m,normalizeClass as v,toDisplayString as f,createBlock as C,withDirectives as g,createTextVNode as h,vShow as k}from"vue";import{useMessage as b,NSpin as A,NInput as L,NIcon as w,NButton as _,NSelect as U,NTooltip as N}from"naive-ui";import{CloseOutline as V,AddOutline as x,AddCircleSharp as D}from"@vicons/ionicons5";import B from"./ValueCfg.vue.js";import{DataTypeEnums as I,ConditionEnums as j}from"../../types/enums.js";import{useDisplayCategory as S}from"./hooks/useDisplayCategory.js";import{useFilterConditions as F}from"./hooks/useFilterConditions.js";import{conditionOptions as z}from"./helpers/options.js";import{InjectionClassifyFilterList as O}from"../../constants/index.js";const P={class:"searchConditionByApi_wrapper"},q={class:"class-filter-content"},E={key:0,class:"item-name"},R=p("span",{class:"label"},"筛选分类名称:",-1),J={key:1,class:"quickSearch-content"},K=p("span",{class:"label"},"父类名称:",-1),M=["onDblclick","onClick"],Q={key:0,class:"s-content"},G={key:2,class:"item-name"},H=p("span",{class:"label"}," 过滤条件: ",-1),T=p("span",null,"添加",-1),W={class:"select-item-list"},X={class:"index-span"},Y=["onClick"];var Z=e({__name:"index",props:{actionList_prop:{type:Object,default:()=>({})},conditionList:{type:Array,default:()=>[]},tableId:{type:String,default:""},searchFieldList:{type:Array,default:()=>[]},showItemName:{type:Boolean,default:!0},hideAddBtn:{type:Boolean,default:!1}},emits:["saveAdd","cancelSaveAdd"],setup(e,{expose:Z,emit:$}){const ee=e,ae=b(),te=a(),ie=t({className:"",displayCategory:"",filterConditions:[]}),le=i(!1);l(O,n(ie,"filterConditions"));const{State:ne,isEnableAddDisplayCategory:oe,editDisplayCategory:se,handleDisplayCategorySelect:de,handleDisplayCategoryRemove:re,handleDisplayCategoryAdd:ce,handlerBlur:pe,initDisplayCategories:ue}=S(n(ie,"displayCategory"),{conditionList:ee.conditionList},ae),{State:ye,paramOptions:me,addFilterCondition:ve,delFilterCondition:fe,updateKey:Ce,updateCondition:ge,getParamCfg:he,initFilterConditions:ke,getRawFilterConditions:be}=F(n(ie,"filterConditions"),ee.searchFieldList,I.API);function Ae(){ie.className="",ie.displayCategory="",ie.filterConditions=[]}async function Le(){var e;try{if(Ae(),le.value=!0,ue(te.displayCategoryList,ee.actionList_prop.displayCategory||void 0),ee.actionList_prop){ie.className=ee.actionList_prop.name,await ke(ee.tableId,null!=(e=ee.actionList_prop.conObj)?e:[]);ie.filterConditions.length<1&&me.value&&me.value.length>0&&ve()}}finally{le.value=!1}}return Le(),Z({handleInitConditions:Le,saveAdd:function(){new Promise((e=>{ie.className||!ee.showItemName?0!==ie.filterConditions.length?ie.filterConditions.some((({key:e,condition:a,value:t,presetVal:i})=>!e||!a||a===j.EQUAL&&!t&&!i))?ae.warning("请补充完整条件内容"):e(!0):ae.warning("请至少添加一个条件"):ae.warning("请输入分类名称")})).then((()=>{let e;var a;"edit"===ee.actionList_prop.from&&(a=ee.actionList_prop.displayCategory,e=null==ee?void 0:ee.conditionList.find((e=>e.displayCategory===a)));const t={displayCategory:ie.displayCategory,name:ie.className||"",conObj:be()},i={id:e?e.sid:"",tableId:ee.tableId,setting:JSON.stringify(t)};$("saveAdd",i,!1)}))},cancelSaveAdd:function(){Ae(),$("cancelSaveAdd")},addAction:ve,checkActionList:function(){return ie.filterConditions.every((e=>!e.field_key))}}),(a,t)=>(o(),s("div",P,[d(r(A),{show:le.value},{default:c((()=>[p("div",q,[e.showItemName?(o(),s("div",E,[R,d(r(L),{value:ie.className,"onUpdate:value":t[0]||(t[0]=e=>ie.className=e),placeholder:"请输入分类名称",style:{width:"250px"},maxlength:"10"},null,8,["value"])])):u("v-if",!0),e.showItemName?(o(),s("div",J,[K,(o(!0),s(y,null,m(r(ne).displayCategories,((e,a)=>(o(),s("div",{class:v(["edit-tag",{"edit-tag-select":e.value===ie.displayCategory&&e.disabled}]),key:a,onDblclick:a=>r(se)(a,e),onClick:a=>function(e){de(e)}(e)},[e.disabled?(o(),s("div",Q,[p("span",null,f(e.value),1)])):(o(),C(r(L),{key:1,style:{width:"100px"},disabled:e.disabled,onBlur:()=>e.disabled=!0,value:e.value,"onUpdate:value":a=>e.value=a,maxlength:10},null,8,["disabled","onBlur","value","onUpdate:value"])),d(r(w),{component:r(V),class:"anticon-close",size:"20",onClick:t=>r(re)(a,e)},null,8,["component","onClick"])],42,M)))),128)),r(oe)?(o(),s(y,{key:0},[g(d(r(_),{class:"ant-btn",icon:"plus",dashed:"",onClick:r(ce)},{default:c((()=>[d(r(w),{component:r(x),size:"20"},null,8,["component"]),h(" "+f("添加父类"))])),_:1},8,["onClick"]),[[k,!r(ne).showAdd]]),g(d(r(L),{class:"edit-tag",value:r(ne).addDisplayCategory,"onUpdate:value":t[1]||(t[1]=e=>r(ne).addDisplayCategory=e),valueModifiers:{trim:!0},style:{width:"100px"},onBlur:r(pe),maxLength:10},null,8,["value","onBlur"]),[[k,r(ne).showAdd]])],64)):u("v-if",!0)])):u("v-if",!0),e.hideAddBtn?u("v-if",!0):(o(),s("div",G,[H,p("span",{class:"addAction",onClick:t[2]||(t[2]=(...e)=>r(ve)&&r(ve)(...e)),style:{cursor:"pointer"}},[d(r(w),{component:r(D),class:"blue",size:"18"},null,8,["component"]),T])])),p("ul",W,[(o(!0),s(y,null,m(ie.filterConditions,((e,a)=>(o(),s("li",{key:a},[p("span",X,f(a+1)+"   ",1),u(" 选择 field_key "),d(r(U),{class:"form-item",placeholder:"请选择",value:e.key,to:"body",filterable:"",options:r(me),"onUpdate:value":e=>r(Ce)(a,e)},null,8,["value","options","onUpdate:value"]),u(" 选择 关系 "),e.key?(o(),C(r(U),{key:0,class:"form-item",placeholder:"请选择",value:e.condition,to:"body",filterable:"",options:r(z),"onUpdate:value":e=>r(ge)(a,e)},null,8,["value","options","onUpdate:value"])):u("v-if",!0),u(" 自定义 "),e.key&&e.condition&&e.condition!==r(j).NULL?(o(),C(B,{key:1,modelValue:e.value,"onUpdate:modelValue":a=>e.value=a,presetVal:e.presetVal,"onUpdate:presetVal":a=>e.presetVal=a,"param-cfg":r(he)(e.key)},null,8,["modelValue","onUpdate:modelValue","presetVal","onUpdate:presetVal","param-cfg"])):u("v-if",!0),d(r(N),{title:"删除",trigger:"hover"},{trigger:c((()=>[p("i",{onClick:e=>r(fe)(a),class:"iconfont-table-filter delete-item-icon icon-table-filter-menzhenyishengzhananniuqingchu"},null,8,Y)])),default:c((()=>[h(" 删除 ")])),_:2},1024)])))),128))])])])),_:1},8,["show"])]))}});export{Z as default};
@@ -0,0 +1,231 @@
1
+ import { PropType } from 'vue';
2
+ import { AnyObject } from '../../../../../../../es/shared/types';
3
+ declare type ITypeDate = 'date' | 'datetime';
4
+ declare const _default: import("vue").DefineComponent<{
5
+ componentCfg: {
6
+ type: PropType<AnyObject>;
7
+ };
8
+ type: {
9
+ type: PropType<ITypeDate>;
10
+ default: string;
11
+ };
12
+ clearable: {
13
+ type: BooleanConstructor;
14
+ default: boolean;
15
+ };
16
+ valueFormat: {
17
+ type: StringConstructor;
18
+ default: string;
19
+ };
20
+ placeholder: {
21
+ type: StringConstructor;
22
+ default: string;
23
+ };
24
+ value: {
25
+ type: StringConstructor;
26
+ default: string;
27
+ };
28
+ unit: {
29
+ type: StringConstructor;
30
+ default: string;
31
+ };
32
+ }, {
33
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
34
+ componentCfg: {
35
+ type: PropType<AnyObject>;
36
+ };
37
+ type: {
38
+ type: PropType<ITypeDate>;
39
+ default: string;
40
+ };
41
+ clearable: {
42
+ type: BooleanConstructor;
43
+ default: boolean;
44
+ };
45
+ valueFormat: {
46
+ type: StringConstructor;
47
+ default: string;
48
+ };
49
+ placeholder: {
50
+ type: StringConstructor;
51
+ default: string;
52
+ };
53
+ value: {
54
+ type: StringConstructor;
55
+ default: string;
56
+ };
57
+ unit: {
58
+ type: StringConstructor;
59
+ default: string;
60
+ };
61
+ }>> & {
62
+ "onUpdate:value"?: ((...args: any[]) => any) | undefined;
63
+ "onUpdate:unit"?: ((...args: any[]) => any) | undefined;
64
+ }>>;
65
+ emit: (event: "update:unit" | "update:value", ...args: any[]) => void;
66
+ valueCp: import("vue").Ref<any>;
67
+ isShowDateRange: import("vue").Ref<boolean>;
68
+ dateFormat: import("vue").ComputedRef<string>;
69
+ showTabStr: import("vue").ComputedRef<string>;
70
+ radioValue: import("vue").ComputedRef<string>;
71
+ optionSetting: import("vue").ComputedRef<any>;
72
+ onlyRadio: import("vue").ComputedRef<boolean>;
73
+ defaultTime: import("vue").ComputedRef<string>;
74
+ changeDateShowType: () => void;
75
+ handleClickQuickBtn: (result: string) => void;
76
+ changeRadioValue: (value: string) => void;
77
+ handleChange: (val: any) => void;
78
+ isDateDisabled: (ts: number) => boolean;
79
+ timeDisabled: (ts: number) => {
80
+ isHourDisabled(hour: number): boolean | undefined;
81
+ isMinuteDisabled(minute: number, hour: number | null): boolean | undefined;
82
+ isSecondDisabled(second: number, minute: number | null, hour: number | null): boolean | undefined;
83
+ };
84
+ init: () => void;
85
+ NButton: any;
86
+ CDatePicker: import("../../../../../../../es/shared/types").SFCWithInstall<import("vue").DefineComponent<{
87
+ updateUnchangedValue: {
88
+ type: BooleanConstructor;
89
+ };
90
+ onConfirm: {
91
+ type: FunctionConstructor;
92
+ };
93
+ }, {
94
+ attrs: {
95
+ [x: string]: unknown;
96
+ };
97
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
98
+ updateUnchangedValue: {
99
+ type: BooleanConstructor;
100
+ };
101
+ onConfirm: {
102
+ type: FunctionConstructor;
103
+ };
104
+ }>> & {}>>;
105
+ datePickerRef: import("vue").Ref<AnyObject | null>;
106
+ panelInstRef: import("vue").Ref<null>;
107
+ isDateTime: import("vue").ComputedRef<boolean>;
108
+ formatRef: import("vue").ComputedRef<string>;
109
+ panelFormatRef: import("vue").ComputedRef<string | [string, string]>;
110
+ focus: () => any;
111
+ blur: () => any;
112
+ onUpdateShow: (show: boolean) => void;
113
+ onConfirm: (...args: any[]) => void;
114
+ NDatePicker: any;
115
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
116
+ updateUnchangedValue: {
117
+ type: BooleanConstructor;
118
+ };
119
+ onConfirm: {
120
+ type: FunctionConstructor;
121
+ };
122
+ }>>, {
123
+ updateUnchangedValue: boolean;
124
+ }>>;
125
+ DateQuickBtn: import("vue").DefineComponent<{
126
+ componentCfg: {
127
+ type: PropType<AnyObject>;
128
+ };
129
+ type: {
130
+ type: PropType<"date" | "datetime">;
131
+ default: string;
132
+ };
133
+ dateFormat: {
134
+ type: StringConstructor;
135
+ default: string;
136
+ };
137
+ radioValue: {
138
+ type: StringConstructor;
139
+ default: string;
140
+ };
141
+ }, {
142
+ props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
143
+ componentCfg: {
144
+ type: PropType<AnyObject>;
145
+ };
146
+ type: {
147
+ type: PropType<"date" | "datetime">;
148
+ default: string;
149
+ };
150
+ dateFormat: {
151
+ type: StringConstructor;
152
+ default: string;
153
+ };
154
+ radioValue: {
155
+ type: StringConstructor;
156
+ default: string;
157
+ };
158
+ }>> & {
159
+ onClickQuickBtn?: ((...args: any[]) => any) | undefined;
160
+ onChangeRadioValue?: ((...args: any[]) => any) | undefined;
161
+ }>>;
162
+ emit: (event: "clickQuickBtn" | "changeRadioValue", ...args: any[]) => void;
163
+ dateList: import("vue").Ref<any[]>;
164
+ optionSetting: import("vue").ComputedRef<any>;
165
+ isRange: import("vue").ComputedRef<any>;
166
+ initData: () => void;
167
+ handleRadioClick: (value: string) => void;
168
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("clickQuickBtn" | "changeRadioValue")[], "clickQuickBtn" | "changeRadioValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
169
+ componentCfg: {
170
+ type: PropType<AnyObject>;
171
+ };
172
+ type: {
173
+ type: PropType<"date" | "datetime">;
174
+ default: string;
175
+ };
176
+ dateFormat: {
177
+ type: StringConstructor;
178
+ default: string;
179
+ };
180
+ radioValue: {
181
+ type: StringConstructor;
182
+ default: string;
183
+ };
184
+ }>> & {
185
+ onClickQuickBtn?: ((...args: any[]) => any) | undefined;
186
+ onChangeRadioValue?: ((...args: any[]) => any) | undefined;
187
+ }, {
188
+ type: "date" | "datetime";
189
+ dateFormat: string;
190
+ radioValue: string;
191
+ }>;
192
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:unit" | "update:value")[], "update:unit" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
193
+ componentCfg: {
194
+ type: PropType<AnyObject>;
195
+ };
196
+ type: {
197
+ type: PropType<ITypeDate>;
198
+ default: string;
199
+ };
200
+ clearable: {
201
+ type: BooleanConstructor;
202
+ default: boolean;
203
+ };
204
+ valueFormat: {
205
+ type: StringConstructor;
206
+ default: string;
207
+ };
208
+ placeholder: {
209
+ type: StringConstructor;
210
+ default: string;
211
+ };
212
+ value: {
213
+ type: StringConstructor;
214
+ default: string;
215
+ };
216
+ unit: {
217
+ type: StringConstructor;
218
+ default: string;
219
+ };
220
+ }>> & {
221
+ "onUpdate:value"?: ((...args: any[]) => any) | undefined;
222
+ "onUpdate:unit"?: ((...args: any[]) => any) | undefined;
223
+ }, {
224
+ type: ITypeDate;
225
+ value: string;
226
+ placeholder: string;
227
+ unit: string;
228
+ clearable: boolean;
229
+ valueFormat: string;
230
+ }>;
231
+ export default _default;
@@ -0,0 +1 @@
1
+ import e from"./DateInner.vue2.js";import r from"../../../../../../_virtual/_plugin-vue_export-helper.js";var t=r(e,[["__file","DateInner.vue"]]);export{t as default};
@@ -0,0 +1 @@
1
+ import{defineComponent as e,ref as t,computed as a,watch as l,openBlock as u,createElementBlock as n,unref as o,createBlock as r,createCommentVNode as i,normalizeClass as d,withCtx as p,createTextVNode as m,toDisplayString as c}from"vue";import{NButton as v}from"naive-ui";import s from"../../../../../date-picker/index.js";import f from"moment";import{isString as y}from"lodash-es";import{WidgetOptionEnums as g}from"../../../types/enums.js";import{dateDisabledCollect as b,setDateDisabled as h,setTimeDisabled as k}from"../helpers/dateDisabled.js";import C from"./DateQuickBtn/index.vue.js";const Y={class:"render-widget-date-range"};var D=e({__name:"DateInner",props:{componentCfg:{type:Object},type:{type:String,default:"date"},clearable:{type:Boolean,default:!1},valueFormat:{type:String,default:"yyyy-MM-dd"},placeholder:{type:String,default:"请输入"},value:{type:String,default:""},unit:{type:String,default:""}},emits:["update:value","update:unit"],setup(e,{emit:D}){const M=e,S=t(),F=t(!1),j=a((()=>{let e="";switch(M.type){case"date":e="YYYY-MM-DD";break;case"datetime":e="YYYY-MM-DD HH:mm:ss"}return e})),T=a((()=>{let e="";switch(M.type){case"date":e="选择日期";break;case"datetime":e="选择时间"}return e})),w=a((()=>M.unit)),_=a((()=>{var e;return null==(e=M.componentCfg)?void 0:e.widgetCfg.optionSetting})),x=a((()=>_.value!==g.SELECT_TIME)),B=a((()=>b.curTime));function E(){x.value&&(F.value=!F.value)}function V(e){D("update:value",e)}function H(e){D("update:unit",e)}function I(e){S.value=e;const t=e?f(e).format(j.value):e;D("update:value",t)}function O(e){return h(e,_.value)}function Q(e){return k(e,_.value)}return l((()=>M.value),(e=>{e&&y(e)?S.value=f(e).valueOf():S.value=null}),{immediate:!0}),x.value||(F.value=!0),(t,a)=>(u(),n("div",Y,[o(x)&&!F.value?(u(),r(C,{key:0,componentCfg:e.componentCfg,type:e.type,dateFormat:o(j),radioValue:o(w),onClickQuickBtn:V,onChangeRadioValue:H},null,8,["componentCfg","type","dateFormat","radioValue"])):i("v-if",!0),o(x)?(u(),r(o(v),{key:1,secondary:"",class:d(F.value?"select-date-right":"select-date-left"),onClick:E},{default:p((()=>[m(c(o(T)),1)])),_:1},8,["class"])):i("v-if",!0),!o(x)||F.value?(u(),r(o(s),{key:2,to:"body",type:e.type,clearable:e.clearable,valueFormat:e.valueFormat,placeholder:e.placeholder,value:S.value,defaultTime:o(B),"is-date-disabled":O,"is-time-disabled":Q,"onUpdate:value":I},null,8,["type","clearable","valueFormat","placeholder","value","defaultTime"])):i("v-if",!0)]))}});export{D as default};