cnhis-design-vue 3.1.42-beta.0 → 3.1.42-release.0

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 (219) hide show
  1. package/es/components/annotation-edit/src/AnnotationEdit.js +1 -1
  2. package/es/components/annotation-edit/style/index.css +1 -1
  3. package/es/components/big-table/index.d.ts +3 -4
  4. package/es/components/big-table/src/BigTable.vue.d.ts +3 -4
  5. package/es/components/big-table/src/BigTable.vue2.js +1 -1
  6. package/es/components/big-table/style/index.css +1 -1
  7. package/es/components/button-print/index.d.ts +6 -7
  8. package/es/components/button-print/src/ButtonPrint.vue.d.ts +6 -7
  9. package/es/components/button-print/src/ButtonPrint.vue2.js +1 -1
  10. package/es/components/button-print/src/components/EditFormat.vue.d.ts +4 -4
  11. package/es/components/button-print/src/components/IdentityVerification.vue.d.ts +4 -4
  12. package/es/components/button-print/src/utils/print.js +1 -1
  13. package/es/components/fabric-chart/index.d.ts +2 -2
  14. package/es/components/fabric-chart/src/FabricChart.vue.d.ts +2 -2
  15. package/es/components/fabric-chart/src/hooks/useBirthProcess.js +1 -1
  16. package/es/components/fabric-chart/src/hooks/useBirthProcessChart.js +1 -1
  17. package/es/components/fabric-chart/src/hooks/useLeft.js +1 -1
  18. package/es/components/field-set/index.d.ts +2 -2
  19. package/es/components/field-set/src/FieldSet.vue.d.ts +2 -2
  20. package/es/components/form-config/index.d.ts +37 -46
  21. package/es/components/form-config/src/FormConfig.vue.d.ts +37 -46
  22. package/es/components/form-config/src/FormConfig.vue.js +1 -1
  23. package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +16 -16
  24. package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +19 -19
  25. package/es/components/form-config/src/components/FormConfigMaterialItem.d.ts +1 -9
  26. package/es/components/form-config/src/components/FormConfigMaterialItem.js +1 -1
  27. package/es/components/form-config/src/components/renderer/DefaultNode.vue.d.ts +6 -33
  28. package/es/components/form-config/src/components/renderer/DefaultNode.vue.js +1 -1
  29. package/es/components/form-config/style/index.css +1 -1
  30. package/es/components/form-render/index.d.ts +16 -16
  31. package/es/components/form-render/src/FormRender.vue.d.ts +16 -16
  32. package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +16 -16
  33. package/es/components/form-render/src/FormRenderWrapper.vue.js +1 -1
  34. package/es/components/form-render/src/components/renderer/complex.d.ts +1 -1
  35. package/es/components/form-render/src/components/renderer/lineBar/FormCollapse.vue.d.ts +1 -1
  36. package/es/components/form-render/src/components/renderer/lineBar/index.d.ts +1 -1
  37. package/es/components/form-render/src/components/renderer/radio&checkbox.d.ts +2 -2
  38. package/es/components/form-render/src/components/renderer/radio_checkbox.js +1 -1
  39. package/es/components/form-render/src/components/renderer/select.js +1 -1
  40. package/es/components/form-render/src/hooks/useFieldListAdaptor.d.ts +1 -1
  41. package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -1
  42. package/es/components/form-render/src/hooks/useFormRenderOptions.d.ts +2 -4
  43. package/es/components/form-render/src/hooks/useFormRenderOptions.js +1 -1
  44. package/es/components/form-render/style/index.css +1 -1
  45. package/es/components/iho-table/index.d.ts +0 -3
  46. package/es/components/iho-table/src/IhoTable.vue.d.ts +0 -3
  47. package/es/components/iho-table/src/IhoTable.vue.js +1 -1
  48. package/es/components/iho-table/src/constants/index.d.ts +4 -4
  49. package/es/components/iho-table/src/constants/index.js +1 -1
  50. package/es/components/iho-table/src/plugins/defaultConfigPlugin/index.js +1 -1
  51. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.d.ts +7 -20
  52. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.js +1 -1
  53. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin/editTime.vue.d.ts +1 -18
  54. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin/editTime.vue.js +1 -1
  55. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin/timeUtils.d.ts +2 -0
  56. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin/timeUtils.js +1 -0
  57. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/labelRendererPlugin.js +1 -1
  58. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/pictureRendererPlugin.js +1 -1
  59. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/seqRendererPlugin.js +1 -1
  60. package/es/components/iho-table/src/plugins/virtualTreePlugin/index.js +1 -1
  61. package/es/components/iho-table/src/types/index.d.ts +0 -1
  62. package/es/components/iho-table/src/utils/index.d.ts +0 -1
  63. package/es/components/iho-table/src/utils/index.js +1 -1
  64. package/es/components/iho-table/style/index.css +1 -1
  65. package/es/components/index.css +1 -1
  66. package/es/components/index.d.ts +2 -8
  67. package/es/components/index.js +1 -1
  68. package/es/components/info-header/index.d.ts +156 -3799
  69. package/es/components/info-header/src/InfoHeader.vue.d.ts +156 -3800
  70. package/es/components/info-header/src/InfoHeader.vue.js +1 -1
  71. package/es/components/info-header/src/components/infoDescription/HiddenContent.vue.d.ts +2 -2
  72. package/es/components/info-header/src/components/infoDescription/InfoEllipsis.vue.d.ts +1 -1
  73. package/es/components/info-header/src/components/infoDescription/InfoEllipsis.vue.js +1 -1
  74. package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +139 -2669
  75. package/es/components/info-header/src/components/infoDescription/index.vue.js +1 -1
  76. package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +0 -745
  77. package/es/components/info-header/src/components/patientInfo/index.vue.js +1 -1
  78. package/es/components/info-header/src/types/index.d.ts +3 -17
  79. package/es/components/info-header/style/index.css +1 -1
  80. package/es/components/keyboard/index.d.ts +2 -4
  81. package/es/components/keyboard/src/Keyboard.vue.d.ts +2 -4
  82. package/es/components/keyboard/src/Keyboard.vue.js +1 -1
  83. package/es/components/keyboard/style/index.css +1 -1
  84. package/es/components/recommend-search/index.d.ts +2 -2
  85. package/es/components/recommend-search/src/RecommendSearch.vue.d.ts +2 -2
  86. package/es/components/recommend-search/src/components/RecommendSelect.vue.d.ts +1 -1
  87. package/es/components/scale-view/src/components/formitem/sign-com.d.ts +1 -1
  88. package/es/components/scale-view/src/components/formitem/standard-modal.d.ts +1 -1
  89. package/es/components/scale-view/src/hooks/use-component.d.ts +116 -69
  90. package/es/components/search-cascader/index.d.ts +2 -2
  91. package/es/components/search-cascader/src/SearchCascader.vue.d.ts +2 -2
  92. package/es/components/search-cascader/src/components/SearchMenu.d.ts +1 -1
  93. package/es/components/select-label/index.d.ts +169 -70
  94. package/es/components/select-label/src/LabelFormContent.vue.d.ts +53 -1
  95. package/es/components/select-label/src/LabelFormContent.vue.js +1 -1
  96. package/es/components/select-label/src/SelectLabel.vue.d.ts +116 -70
  97. package/es/components/select-label/src/SelectLabel.vue2.js +1 -1
  98. package/es/components/select-label/src/components/label-classify.vue.js +1 -1
  99. package/es/components/select-label/style/index.css +1 -1
  100. package/es/components/select-person/index.d.ts +1 -1
  101. package/es/components/select-person/src/SelectPerson.vue.d.ts +1 -1
  102. package/es/components/shortcut-setter/index.d.ts +17 -17
  103. package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +17 -17
  104. package/es/components/steps-wheel/index.d.ts +0 -1
  105. package/es/components/steps-wheel/src/StepsWheel.vue.d.ts +0 -1
  106. package/es/components/steps-wheel/src/StepsWheel.vue.js +1 -1
  107. package/es/components/steps-wheel/style/index.css +1 -1
  108. package/es/components/table-filter/index.d.ts +2385 -0
  109. package/es/components/table-filter/index.js +1 -1
  110. package/es/components/{base-search/src/index.vue.d.ts → table-filter/src/base-search-com/BaseSearch.vue.d.ts} +91 -26
  111. package/es/components/table-filter/src/base-search-com/BaseSearch.vue.js +1 -0
  112. package/es/components/{classification/src/index.vue.d.ts → table-filter/src/classification/Classification-com.vue.d.ts} +291 -57
  113. package/es/components/table-filter/src/classification/Classification-com.vue.js +1 -0
  114. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.d.ts +0 -1
  115. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.js +1 -1
  116. package/es/components/table-filter/src/components/classify-filter/index.vue.d.ts +42 -1
  117. package/es/components/table-filter/src/components/classify-filter/index.vue.js +1 -1
  118. package/es/components/table-filter/src/components/render-widget/components/CheckboxGroup.vue.d.ts +1 -1
  119. package/es/components/table-filter/src/components/render-widget/enums.d.ts +8 -0
  120. package/es/components/table-filter/src/components/render-widget/enums.js +1 -1
  121. package/es/components/table-filter/src/components/render-widget/index.vue.d.ts +1 -2
  122. package/es/components/table-filter/src/components/render-widget/index.vue.js +1 -1
  123. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +1 -1
  124. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.js +1 -1
  125. package/es/components/{classification → table-filter}/src/components/search-filter/index.vue.d.ts +93 -10
  126. package/es/components/table-filter/src/components/search-filter/index.vue.js +1 -0
  127. package/es/components/{classification → table-filter}/src/components/set-classification/index.vue.d.ts +130 -5
  128. package/es/components/table-filter/src/components/set-classification/index.vue.js +1 -0
  129. package/es/components/{classification → table-filter}/src/components/table-modal/index.vue.d.ts +42 -0
  130. package/es/components/table-filter/src/components/table-modal/index.vue.js +1 -0
  131. package/es/components/table-filter/src/const/index.d.ts +5 -0
  132. package/es/components/table-filter/src/const/index.js +1 -0
  133. package/es/components/table-filter/src/hooks/useAdvanced.d.ts +1 -4
  134. package/es/components/table-filter/src/hooks/useAdvanced.js +1 -1
  135. package/es/components/table-filter/src/hooks/useMixins.d.ts +54 -1
  136. package/es/components/table-filter/src/hooks/useMixins.js +1 -1
  137. package/es/components/table-filter/src/hooks/useRenderWidget.js +1 -1
  138. package/es/components/table-filter/src/hooks/useTableSearchCon.d.ts +8 -0
  139. package/es/components/table-filter/src/hooks/useTableSearchCon.js +1 -0
  140. package/es/components/table-filter/src/hooks/useWordBookutils.d.ts +12 -0
  141. package/es/components/table-filter/src/hooks/useWordBookutils.js +1 -0
  142. package/es/components/{quick-search/src/index.vue.d.ts → table-filter/src/quick-search/QuickSearch.vue.d.ts} +120 -31
  143. package/es/components/table-filter/src/quick-search/QuickSearch.vue.js +1 -0
  144. package/es/components/table-filter/src/tool/generateDefOptions.js +1 -1
  145. package/es/components/table-filter/src/tool/time-domain.d.ts +39 -0
  146. package/es/components/table-filter/src/tool/time-domain.js +1 -0
  147. package/es/components/table-filter/src/tool/transformData.d.ts +37 -1
  148. package/es/components/table-filter/src/tool/transformData.js +1 -1
  149. package/es/components/table-filter/src/tool/utils.d.ts +4 -0
  150. package/es/components/table-filter/src/tool/utils.js +1 -0
  151. package/es/components/table-filter/src/types/enums.d.ts +0 -1
  152. package/es/components/table-filter/src/types/enums.js +1 -1
  153. package/es/components/table-filter/src/types/index.d.ts +169 -13
  154. package/es/components/table-filter/style/index.css +1 -0
  155. package/es/shared/utils/index.d.ts +0 -1
  156. package/es/shared/utils/index.js +1 -1
  157. package/package.json +2 -2
  158. package/es/components/base-search/index.d.ts +0 -293
  159. package/es/components/base-search/index.js +0 -1
  160. package/es/components/base-search/src/index.vue.js +0 -1
  161. package/es/components/base-search/style/iconfont.ttf +0 -0
  162. package/es/components/base-search/style/index.css +0 -1
  163. package/es/components/button-print/src/api.d.ts +0 -3
  164. package/es/components/button-print/src/api.js +0 -1
  165. package/es/components/classification/index.d.ts +0 -995
  166. package/es/components/classification/index.js +0 -1
  167. package/es/components/classification/src/components/search-filter/index.vue.js +0 -1
  168. package/es/components/classification/src/components/set-classification/index.vue.js +0 -1
  169. package/es/components/classification/src/components/table-modal/index.vue.js +0 -1
  170. package/es/components/classification/src/const/index.d.ts +0 -2
  171. package/es/components/classification/src/const/index.js +0 -1
  172. package/es/components/classification/src/index.vue.js +0 -1
  173. package/es/components/classification/style/iconfont.ttf +0 -0
  174. package/es/components/classification/style/index.css +0 -1
  175. package/es/components/config-provider/index.d.ts +0 -14
  176. package/es/components/config-provider/index.js +0 -1
  177. package/es/components/config-provider/src/ConfigProvider.d.ts +0 -14
  178. package/es/components/config-provider/src/ConfigProvider.js +0 -1
  179. package/es/components/config-provider/src/interface.d.ts +0 -19
  180. package/es/components/config-provider/src/interface.js +0 -1
  181. package/es/components/config-provider/src/utils/index.d.ts +0 -2
  182. package/es/components/config-provider/src/utils/index.js +0 -1
  183. package/es/components/date-picker/index.d.ts +0 -20
  184. package/es/components/date-picker/index.js +0 -1
  185. package/es/components/date-picker/src/DatePicker.vue.d.ts +0 -20
  186. package/es/components/date-picker/src/DatePicker.vue.js +0 -1
  187. package/es/components/info-header/src/components/infoDescription/DescriptionItem.vue.d.ts +0 -1842
  188. package/es/components/info-header/src/components/infoDescription/DescriptionItem.vue.js +0 -1
  189. package/es/components/info-header/src/components/infoDescription/DescriptionList.vue.d.ts +0 -1972
  190. package/es/components/info-header/src/components/infoDescription/DescriptionList.vue.js +0 -1
  191. package/es/components/info-header/src/constants/index.d.ts +0 -4
  192. package/es/components/info-header/src/constants/index.js +0 -1
  193. package/es/components/info-header/src/hooks/useThemeOverrides.d.ts +0 -4
  194. package/es/components/info-header/src/hooks/useThemeOverrides.js +0 -1
  195. package/es/components/keyboard/src/constants/index.d.ts +0 -2
  196. package/es/components/keyboard/src/constants/index.js +0 -1
  197. package/es/components/quick-search/index.d.ts +0 -713
  198. package/es/components/quick-search/index.js +0 -1
  199. package/es/components/quick-search/src/index.vue.js +0 -1
  200. package/es/components/quick-search/style/index.css +0 -1
  201. package/es/components/select-label/style/iconfont.ttf +0 -0
  202. package/es/components/steps-wheel/src/constants/index.d.ts +0 -2
  203. package/es/components/steps-wheel/src/constants/index.js +0 -1
  204. package/es/components/time-picker/index.d.ts +0 -18
  205. package/es/components/time-picker/index.js +0 -1
  206. package/es/components/time-picker/src/TimePicker.vue.d.ts +0 -18
  207. package/es/components/time-picker/src/TimePicker.vue.js +0 -1
  208. package/es/shared/mixins/index.d.ts +0 -1
  209. package/es/shared/mixins/index.js +0 -1
  210. package/es/shared/mixins/useTheme.d.ts +0 -3
  211. package/es/shared/mixins/useTheme.js +0 -1
  212. /package/es/components/{classification → table-filter}/src/directive/flexibleResize.d.ts +0 -0
  213. /package/es/components/{classification → table-filter}/src/directive/flexibleResize.js +0 -0
  214. /package/es/components/{base-search → table-filter}/src/directive/resize.d.ts +0 -0
  215. /package/es/components/{base-search → table-filter}/src/directive/resize.js +0 -0
  216. /package/es/components/table-filter/src/tool/{baseOptions.d.ts → options.d.ts} +0 -0
  217. /package/es/components/table-filter/src/tool/{baseOptions.js → options.js} +0 -0
  218. /package/es/components/{base-search → table-filter}/src/tool/resizeSensor.d.ts +0 -0
  219. /package/es/components/{base-search → table-filter}/src/tool/resizeSensor.js +0 -0
@@ -1 +1 @@
1
- import{defineComponent as e,provide as t,computed as o,ref as a,watch as l,resolveComponent as s,openBlock as i,createElementBlock as n,unref as r,normalizeStyle as u,createBlock as f,resolveDynamicComponent as c,createVNode as d,mergeProps as p,createSlots as m,renderList as v,withCtx as b,createCommentVNode as h,renderSlot as g}from"vue";import{useTheme as x}from"../../../shared/mixins/useTheme.js";import{uuidGenerator as k}from"../../../shared/utils/index.js";import{useDebounceFn as y}from"@vueuse/core";import{promiseTimeout as j}from"@vueuse/shared";import{isFunction as C}from"lodash-es";import{VxeTableEventNameList as D,InjectionIhoTableEmits as _,InjectionIhoTableAnnotation as $,InjectionIhoTableUUID as H,InjectionIhoTableInstance as T,InjectionIhoTableConfig as A,InjectionIhoTableFieldList as L,InjectionIhoTableHandler as w}from"./constants/index.js";import{createTableHooks as R,applyTableConfigHooks as E,applyTableFieldHooks as F,createTableEventHandlers as I,createDomInsertComponent as O,createDataTransfer as S}from"./hooks/tapHooks/index.js";import{provideIhoTableEventListener as q}from"./hooks/tapHooks/useEventHooks.js";import{eventName2EventListener as z}from"./utils/index.js";import B from"../../../_virtual/plugin-vue_export-helper.js";const G=["id"];var J=B(e({__name:"IhoTable",props:{tableConfig:{type:Object,default:()=>({})},fieldList:{type:Array,default:()=>[]},tableData:{type:Array,default:()=>[]},annotation:{type:Object}},emits:["formChange","settingClick","formClick","keyboard",...D],setup(e,{expose:D,emit:B}){var J,K;const M=e,N=x({"--c-border-color":"#e2e2e2","--c-head-bg-color":"#f2f2f2","--c-hover-color":"#f7f7f7"}),P=q(),Q=function(e,...t){B(e,...t);const o=r(X)[z(e)];C(o)&&o(...t),P.trigger(e,...t)};t(_,Q);const U=R();t($,o((()=>M.annotation)));const V=k();t(H,V);const W=a();t(T,W);const X=a({uuid:null!=(K=null==(J=M.tableConfig)?void 0:J.uuid)?K:V});t(A,X);const Y=y(Z,10);function Z(){X.value=E(U,M.tableConfig),X.value.uuid=V}const ee=a([]);t(L,ee);const te=y(oe,10);function oe(){ee.value=F(U,M.fieldList,X.value,{$table:W,emits:Q})}const ae=S(U,X,W),le=a([]),se=y(ie,10);async function ie(){var e;le.value=await ae(M.tableData),null==(e=W.value)||e.recalculate(!0)}const ne={updateTableDataRef:se,updateConfigRef:Y,updateFieldListRef:te};t(w,ne);const re=I({hooks:U,config:X,$table:W,context:ne,emits:Q}),ue=o((()=>({...X.value,...re})));l((()=>M.tableConfig),(()=>{Y(),te(),se()}),{deep:!0}),l((()=>M.fieldList),(()=>{te(),se()}),{deep:!0}),l([()=>M.tableData,()=>{var e;return null==(e=M.tableData)?void 0:e.length}],(async()=>{var e,t;(null==(e=X.value.treeConfig)?void 0:e.expandAll)&&(await j(11),null==(t=W.value)||t.setAllTreeExpand(!0))})),l((()=>[...M.tableData]),se),Z(),oe(),ie();const{header:fe,footer:ce}=O(U);return D({$table:W,async loadData(e){var t;null==(t=W.value)||t.loadData(await ae(e))},setSort:(e,t)=>({field:e,value:t}),setFilter:(e,t)=>({field:e,value:t}),...U.exposeHooks.expose.call({},X,{$table:W,emits:Q})}),U.setupHooks.setup.call(X,ee),(e,t)=>{const o=s("vxe-grid");return i(),n("section",{class:"iho-table",id:r(V),style:u(r(N))},[(i(),f(c(r(fe)))),d(o,p({ref_key:"$table",ref:W},r(ue),{columns:ee.value,data:le.value}),m({_:2},[v(e.$slots,((t,o)=>({name:o,fn:b((()=>[h(" 实际上所有的vxe-grid插槽都支持 "),g(e.$slots,o)]))})))]),1040,["columns","data"]),(i(),f(c(r(ce))))],12,G)}}}),[["__file","IhoTable.vue"]]);export{J as default};
1
+ import{defineComponent as e,provide as t,computed as a,ref as o,watch as l,resolveComponent as s,openBlock as n,createElementBlock as i,unref as r,createBlock as u,resolveDynamicComponent as d,createVNode as f,mergeProps as c,createSlots as p,renderList as v,withCtx as m,createCommentVNode as b,renderSlot as g}from"vue";import{uuidGenerator as x}from"../../../shared/utils/index.js";import{useDebounceFn as h}from"@vueuse/core";import{promiseTimeout as k}from"@vueuse/shared";import{isFunction as y}from"lodash-es";import{VxeTableEventNameList as C,InjectionIhoTableEmits as j,InjectionIhoTableAnnotation as D,InjectionIhoTableUUID as _,InjectionIhoTableInstance as $,InjectionIhoTableConfig as H,InjectionIhoTableFieldList as A,InjectionIhoTableHandler as L}from"./constants/index.js";import{createTableHooks as T,applyTableConfigHooks as w,applyTableFieldHooks as R,createTableEventHandlers as E,createDomInsertComponent as F,createDataTransfer as I}from"./hooks/tapHooks/index.js";import{provideIhoTableEventListener as O}from"./hooks/tapHooks/useEventHooks.js";import{eventName2EventListener as S}from"./utils/index.js";import q from"../../../_virtual/plugin-vue_export-helper.js";const z=["id"];var B=q(e({__name:"IhoTable",props:{tableConfig:{type:Object,default:()=>({})},fieldList:{type:Array,default:()=>[]},tableData:{type:Array,default:()=>[]},annotation:{type:Object}},emits:["formChange","settingClick","formClick","keyboard",...C],setup(e,{expose:C,emit:q}){var B,G;const J=e,K=O(),M=function(e,...t){q(e,...t);const a=r(U)[S(e)];y(a)&&a(...t),K.trigger(e,...t)};t(j,M);const N=T();t(D,a((()=>J.annotation)));const P=x();t(_,P);const Q=o();t($,Q);const U=o({uuid:null!=(G=null==(B=J.tableConfig)?void 0:B.uuid)?G:P});t(H,U);const V=h(W,10);function W(){U.value=w(N,J.tableConfig),U.value.uuid=P}const X=o([]);t(A,X);const Y=h(Z,10);function Z(){X.value=R(N,J.fieldList,U.value,{$table:Q,emits:M})}const ee=I(N,U,Q),te=o([]),ae=h(oe,10);async function oe(){var e;te.value=await ee(J.tableData),null==(e=Q.value)||e.recalculate(!0)}const le={updateTableDataRef:ae,updateConfigRef:V,updateFieldListRef:Y};t(L,le);const se=E({hooks:N,config:U,$table:Q,context:le,emits:M}),ne=a((()=>({...U.value,...se})));l((()=>J.tableConfig),(()=>{V(),Y(),ae()}),{deep:!0}),l((()=>J.fieldList),(()=>{Y(),ae()}),{deep:!0}),l([()=>J.tableData,()=>{var e;return null==(e=J.tableData)?void 0:e.length}],(async()=>{var e,t;(null==(e=U.value.treeConfig)?void 0:e.expandAll)&&(await k(11),null==(t=Q.value)||t.setAllTreeExpand(!0))})),l((()=>[...J.tableData]),ae),W(),Z(),oe();const{header:ie,footer:re}=F(N);return C({$table:Q,async loadData(e){var t;null==(t=Q.value)||t.loadData(await ee(e))},setSort:(e,t)=>({field:e,value:t}),setFilter:(e,t)=>({field:e,value:t}),...N.exposeHooks.expose.call({},U,{$table:Q,emits:M})}),N.setupHooks.setup.call(U,X),(e,t)=>{const a=s("vxe-grid");return n(),i("section",{class:"iho-table",id:r(P)},[(n(),u(d(r(ie)))),f(a,c({ref_key:"$table",ref:Q},r(ne),{columns:X.value,data:te.value}),p({_:2},[v(e.$slots,((t,a)=>({name:a,fn:m((()=>[b(" 实际上所有的vxe-grid插槽都支持 "),g(e.$slots,a)]))})))]),1040,["columns","data"]),(n(),u(d(r(re))))],8,z)}}}),[["__file","IhoTable.vue"]]);export{B as default};
@@ -59,10 +59,10 @@ export declare enum IHO_TABLE_STRING_STATUS {
59
59
  POSITIVE = "1"
60
60
  }
61
61
  export declare enum IHO_TABLE_TREE_TYPE {
62
- NOT_TREE = "0",
63
- UNKNOWN = "1",
64
- TRANSFORM_TREE_TYPE = "2",
65
- TRANSFORM_WITH_SPAN_METHOD = "3"
62
+ NOT_TREE = 0,
63
+ UNKNOWN = 1,
64
+ UNKNOWN2 = 2,
65
+ TRANSFORM_TREE_TYPE = 3
66
66
  }
67
67
  export declare enum IHO_TABLE_FIXED_STATUS {
68
68
  left = 1,
@@ -1 +1 @@
1
- import{eventListener2EventName as e}from"../utils/index.js";var o=(e=>(e.DEFAULT="DEFAULT",e.PICTURE="PICTURE",e.FILE="FILE",e.MONEY="MONEY",e.HEADPORTRAIT="HEADPORTRAIT",e.LABEL="LABEL",e.TELEPHONE="TELEPHONE",e.BIRTHDAY="BIRTHDAY",e.MULTISELECT="MULTISELECT",e.CASCADE="CASCADE",e.SEARCH_TREE="SEARCH_TREE",e.COLOR="COLOR",e.EVALUATE="EVALUATE",e.MAP="MAP",e.VIDEO="VIDEO",e.SYSTEMFIELDS="SYSTEMFIELDS",e.PERCENTAGE="PERCENTAGE",e.CANDIDATE_COMPONENTS="CANDIDATE_COMPONENTS",e.TASKDATE="TASKDATE",e.AGE="AGE",e.STATUS="STATUS",e.WEBSITE="WEBSITE",e.IDCARD="IDCARD",e.COUNTDOWN="COUNTDOWN",e.DURATION="DURATION",e.COMBINATION="COMBINATION",e.PASSWORD="PASSWORD",e.QR_CODE="QR_CODE",e.CUSTOMER_NAME="CUSTOMER_NAME",e.BANK_CARD="BANK_CARD",e.SEQUENCE="SEQUENCE",e))(o||{});const n=Object.freeze(["onKeydownStart","onKeydown","onKeydownEnd","onPaste","onCopy","onCut","onCurrentChange","onRadioChange","onCheckboxChange","onCheckboxAll","onCheckboxRangeStart","onCheckboxRangeChange","onCheckboxRangeEnd","onCellClick","onCellDblclick","onCellMenu","onCellMouseenter","onCellMouseleave","onHeaderCellClick","onHeaderCellDblclick","onHeaderCellMenu","onFooterCellClick","onFooterCellDblclick","onFooterCellMenu","onSortChange","onFilterChange","onFilterVisible","onResizableChange","onToggleRowExpand","onToggleTreeExpand","onMenuClick","onEditClosed","onEditActived","onEditDisabled","onValidError","onScroll","onCustom","onOpenFnr","onFnrChange","onFnrFind","onFnrFindAll","onFnrReplace","onFnrReplaceAll","onCellAreaCopy","onCellAreaCut","onCellAreaPaste","onCellAreaMerge","onClearCellAreaMerge","onHeaderCellAreaSelection","onCellAreaSelectionStart","onCellAreaSelectionDrag","onCellAreaSelectionEnd","onCellAreaExtensionStart","onCellAreaExtensionDrag","onCellAreaExtensionEnd","onCellAreaArrowsStart","onCellAreaArrowsEnd","onActiveCellChangeStart","onActiveCellChangeEnd"]),E=n.map(e),l=Object.freeze(["firstRowGroup","secondRowGroup","thirdRowGroup","fourthRowGroup","fifthRowGroup","sixthRowGroup","seventhRowGroup","eighthRowGroup","ninthRowGroup","tenthRowGroup"]),C=-1/0,A=1/0;var T=(e=>(e.INPUT="INPUT",e.SEPARATE="SEPARATE",e.SELECT="SELECT",e.DATE="DATE",e.TIME="TIME",e.NUMBER="NUMBER",e))(T||{}),r=(e=>(e[e.NEGATIVE=0]="NEGATIVE",e[e.POSITIVE=1]="POSITIVE",e))(r||{}),t=(e=>(e.NEGATIVE="0",e.POSITIVE="1",e))(t||{}),a=(e=>(e.NOT_TREE="0",e.UNKNOWN="1",e.TRANSFORM_TREE_TYPE="2",e.TRANSFORM_WITH_SPAN_METHOD="3",e))(a||{}),i=(e=>(e[e.left=1]="left",e[e.right=2]="right",e))(i||{});const S=["formChange","settingClick","formClick","keyboard"],I=[...S,...E],R=Symbol("injectionIhoTableConfig"),O=Symbol("injectionIhoTableFieldList"),D=Symbol("InjectionIhoTableEmits"),N=Symbol("InjectionIhoTableAnnotation"),c=Symbol("InjectionIhoTableUUID"),h=Symbol("InjectionIhoTableInstance"),d=Symbol("InjectionIhoTableHandler"),M=Symbol("InjectionIhoTableEventListener");export{T as EDITABLE_WIDGET_TYPE,C as HIGHEST_PRIORITY,i as IHO_TABLE_FIXED_STATUS,r as IHO_TABLE_NUMBER_STATUS,t as IHO_TABLE_STRING_STATUS,a as IHO_TABLE_TREE_TYPE,S as IhoTableCustomEventNameTuple,I as IhoTableEventNameTuple,l as IhoTableRowGroupSequence,N as InjectionIhoTableAnnotation,R as InjectionIhoTableConfig,D as InjectionIhoTableEmits,M as InjectionIhoTableEventListener,O as InjectionIhoTableFieldList,d as InjectionIhoTableHandler,h as InjectionIhoTableInstance,c as InjectionIhoTableUUID,A as LOWEST_PRIORITY,n as VxeEventListenerNameList,E as VxeTableEventNameList,o as WIDGET_TYPE};
1
+ import{eventListener2EventName as e}from"../utils/index.js";var o=(e=>(e.DEFAULT="DEFAULT",e.PICTURE="PICTURE",e.FILE="FILE",e.MONEY="MONEY",e.HEADPORTRAIT="HEADPORTRAIT",e.LABEL="LABEL",e.TELEPHONE="TELEPHONE",e.BIRTHDAY="BIRTHDAY",e.MULTISELECT="MULTISELECT",e.CASCADE="CASCADE",e.SEARCH_TREE="SEARCH_TREE",e.COLOR="COLOR",e.EVALUATE="EVALUATE",e.MAP="MAP",e.VIDEO="VIDEO",e.SYSTEMFIELDS="SYSTEMFIELDS",e.PERCENTAGE="PERCENTAGE",e.CANDIDATE_COMPONENTS="CANDIDATE_COMPONENTS",e.TASKDATE="TASKDATE",e.AGE="AGE",e.STATUS="STATUS",e.WEBSITE="WEBSITE",e.IDCARD="IDCARD",e.COUNTDOWN="COUNTDOWN",e.DURATION="DURATION",e.COMBINATION="COMBINATION",e.PASSWORD="PASSWORD",e.QR_CODE="QR_CODE",e.CUSTOMER_NAME="CUSTOMER_NAME",e.BANK_CARD="BANK_CARD",e.SEQUENCE="SEQUENCE",e))(o||{});const n=Object.freeze(["onKeydownStart","onKeydown","onKeydownEnd","onPaste","onCopy","onCut","onCurrentChange","onRadioChange","onCheckboxChange","onCheckboxAll","onCheckboxRangeStart","onCheckboxRangeChange","onCheckboxRangeEnd","onCellClick","onCellDblclick","onCellMenu","onCellMouseenter","onCellMouseleave","onHeaderCellClick","onHeaderCellDblclick","onHeaderCellMenu","onFooterCellClick","onFooterCellDblclick","onFooterCellMenu","onSortChange","onFilterChange","onFilterVisible","onResizableChange","onToggleRowExpand","onToggleTreeExpand","onMenuClick","onEditClosed","onEditActived","onEditDisabled","onValidError","onScroll","onCustom","onOpenFnr","onFnrChange","onFnrFind","onFnrFindAll","onFnrReplace","onFnrReplaceAll","onCellAreaCopy","onCellAreaCut","onCellAreaPaste","onCellAreaMerge","onClearCellAreaMerge","onHeaderCellAreaSelection","onCellAreaSelectionStart","onCellAreaSelectionDrag","onCellAreaSelectionEnd","onCellAreaExtensionStart","onCellAreaExtensionDrag","onCellAreaExtensionEnd","onCellAreaArrowsStart","onCellAreaArrowsEnd","onActiveCellChangeStart","onActiveCellChangeEnd"]),E=n.map(e),l=Object.freeze(["firstRowGroup","secondRowGroup","thirdRowGroup","fourthRowGroup","fifthRowGroup","sixthRowGroup","seventhRowGroup","eighthRowGroup","ninthRowGroup","tenthRowGroup"]),C=-1/0,A=1/0;var T=(e=>(e.INPUT="INPUT",e.SEPARATE="SEPARATE",e.SELECT="SELECT",e.DATE="DATE",e.TIME="TIME",e.NUMBER="NUMBER",e))(T||{}),r=(e=>(e[e.NEGATIVE=0]="NEGATIVE",e[e.POSITIVE=1]="POSITIVE",e))(r||{}),t=(e=>(e.NEGATIVE="0",e.POSITIVE="1",e))(t||{}),a=(e=>(e[e.NOT_TREE=0]="NOT_TREE",e[e.UNKNOWN=1]="UNKNOWN",e[e.UNKNOWN2=2]="UNKNOWN2",e[e.TRANSFORM_TREE_TYPE=3]="TRANSFORM_TREE_TYPE",e))(a||{}),i=(e=>(e[e.left=1]="left",e[e.right=2]="right",e))(i||{});const S=["formChange","settingClick","formClick","keyboard"],R=[...S,...E],I=Symbol("injectionIhoTableConfig"),N=Symbol("injectionIhoTableFieldList"),O=Symbol("InjectionIhoTableEmits"),c=Symbol("InjectionIhoTableAnnotation"),D=Symbol("InjectionIhoTableUUID"),h=Symbol("InjectionIhoTableInstance"),d=Symbol("InjectionIhoTableHandler"),b=Symbol("InjectionIhoTableEventListener");export{T as EDITABLE_WIDGET_TYPE,C as HIGHEST_PRIORITY,i as IHO_TABLE_FIXED_STATUS,r as IHO_TABLE_NUMBER_STATUS,t as IHO_TABLE_STRING_STATUS,a as IHO_TABLE_TREE_TYPE,S as IhoTableCustomEventNameTuple,R as IhoTableEventNameTuple,l as IhoTableRowGroupSequence,c as InjectionIhoTableAnnotation,I as InjectionIhoTableConfig,O as InjectionIhoTableEmits,b as InjectionIhoTableEventListener,N as InjectionIhoTableFieldList,d as InjectionIhoTableHandler,h as InjectionIhoTableInstance,D as InjectionIhoTableUUID,A as LOWEST_PRIORITY,n as VxeEventListenerNameList,E as VxeTableEventNameList,o as WIDGET_TYPE};
@@ -1 +1 @@
1
- import{mergeWith as e,isObject as o}from"lodash-es";import{HIGHEST_PRIORITY as i}from"../../constants/index.js";import{defineTablePlugin as t}from"../../hooks/useTablePlugin.js";import{IhoTableStatusHelper as s}from"../../utils/index.js";function n(){const n="defaultTablePlugin";return t({name:n,apply(t){t.configHooks.config.tap({name:n,stage:i},(o=>{const i=e({height:"100%",border:!0,showSeq:!0,columnConfig:{resizable:!0},rowConfig:{height:36,isHover:!0,isCurrent:!0,keyField:"theUniqueKey"},showOverflow:"tooltip",editConfig:{trigger:"click",mode:"cell"}},o);return(s.isPositive(o.isBatchSelect)||o.selectType)&&(i.selectType=o.selectType||"checkbox"),i})),t.configHooks.mouseConfig.tap({name:n,stage:i},((e,i)=>o(i.keyboardConfig)?Object.assign({selected:!!i.keyboardConfig.isEdit},e):e))}})}export{n as defaultConfigPlugin};
1
+ import{mergeWith as e,isObject as o}from"lodash-es";import{HIGHEST_PRIORITY as i,IHO_TABLE_TREE_TYPE as t}from"../../constants/index.js";import{defineTablePlugin as s}from"../../hooks/useTablePlugin.js";import{IhoTableStatusHelper as n}from"../../utils/index.js";function r(){const r="defaultTablePlugin";return s({name:r,apply(s){s.configHooks.config.tap({name:r,stage:i},(o=>{const i=e({height:"100%",border:!0,showSeq:!0,columnConfig:{resizable:!0},rowConfig:{height:36,isHover:!0,isCurrent:!0,keyField:"theUniqueKey"},showOverflow:"tooltip",editConfig:{trigger:"click",mode:"cell"}},o);return(n.isPositive(o.isBatchSelect)||o.selectType)&&(i.selectType=o.selectType||"checkbox"),i})),s.configHooks.treeConfig.tap({name:r,stage:i},((e,o)=>o.isTree===t.TRANSFORM_TREE_TYPE?Object.assign({transform:!0,expandAll:!0,lazy:!0,reserve:!0},e):e)),s.configHooks.mouseConfig.tap({name:r,stage:i},((e,i)=>o(i.keyboardConfig)?Object.assign({selected:!!i.keyboardConfig.isEdit},e):e))}})}export{r as defaultConfigPlugin};
@@ -45,8 +45,8 @@ declare const _default: import("vue").DefineComponent<{
45
45
  emit: (event: "update:value", ...args: any[]) => void;
46
46
  formRef: import("vue").Ref<HTMLElement | null>;
47
47
  isShow: import("vue").Ref<boolean>;
48
- formattedValue: any;
49
- onConfirm: (value: any) => void;
48
+ formattedValue: import("vue").Ref<string | undefined>;
49
+ onConfirm: (value: string | null | undefined) => void;
50
50
  isStartDate: any;
51
51
  isEndDate: any;
52
52
  connectField: string;
@@ -58,6 +58,8 @@ declare const _default: import("vue").DefineComponent<{
58
58
  isSecondDisabled: (second: number) => boolean;
59
59
  };
60
60
  customDateDisabledDecorator: (customDateDisabled?: Func) => ((ts: number) => any) | null;
61
+ getFormatDate: (str: string) => string;
62
+ onBlur: () => void;
61
63
  formatConfig: import("vue").ComputedRef<{
62
64
  valueFormat: string;
63
65
  format: string;
@@ -66,24 +68,9 @@ declare const _default: import("vue").DefineComponent<{
66
68
  };
67
69
  }>;
68
70
  dateConfig: AnyObject;
69
- DatePicker: import("../../../../../../../../es/shared/types").SFCWithInstall<import("vue").DefineComponent<{}, {
70
- attrs: {
71
- [x: string]: unknown;
72
- };
73
- emits: (event: "update:formattedValue", ...args: any[]) => void;
74
- datePickerRef: import("vue").Ref<null>;
75
- __formattedValue: import("vue").Ref<any>;
76
- keyupValue: import("vue").Ref<string>;
77
- inputIndex: number;
78
- placeholder: string;
79
- formatRef: import("vue").ComputedRef<unknown>;
80
- updateFormattedValue: (value: any) => void;
81
- onBlur: () => void;
82
- onKeyUp: (event: AnyObject) => any;
83
- NDatePicker: any;
84
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:formattedValue"[], "update:formattedValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>> & {
85
- "onUpdate:formattedValue"?: ((...args: any[]) => any) | undefined;
86
- }, {}>>;
71
+ NDatePicker: any;
72
+ NInput: any;
73
+ NPopover: any;
87
74
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
88
75
  value: {
89
76
  type: StringConstructor;
@@ -1 +1 @@
1
- import{defineComponent as e,useAttrs as t,ref as r,computed as o,watch as i,openBlock as a,createBlock as s,unref as u,mergeProps as l,isRef as n}from"vue";import{generateTimeFormat as m}from"../../../../../../../shared/utils/index.js";import{isFunction as d}from"lodash-es";import{useIhoTableFormEvent as p}from"../../../../utils/index.js";import{useAutoFocus as c}from"../hooks/useAutoFocus.js";import f from"../../../../../../date-picker/index.js";import w from"../../../../../../../_virtual/plugin-vue_export-helper.js";var v=w(e({__name:"editDate",props:{value:{type:String,default:void 0},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0}},emits:["update:value"],setup(e,{emit:w}){const v=e,D=t(),{emitFormChangeWithParams:g}=p(v),{formRef:h,isShow:y}=c(),b=r(v.value),j=e=>{b.value=e;const t=v.value;w("update:value",e),g({oldValue:t})},{isStartDate:S=!1,isEndDate:T=!1}=D,$=D.connectField||"",_=(e,t)=>S&&$?e>t:!(!T||!$)&&e<t,x=e=>{const t=new Date(v.row[$]),r=new Date(e),o=t.getHours(),i=t.getMinutes(),a=t.getSeconds(),s=(e,t,r,o)=>!(T&&r>o)&&(!(S&&r<o)&&_(e,t));return{isHourDisabled:t=>{if(!v.row[$])return!1;const i=new Date(`${v.row[$].split(" ")[0]} 00:00:00`).getTime(),a=r.getMinutes(),u=r.getSeconds();return s(t,o,e-60*t*60*1e3-60*a*1e3-1e3*u,i)},isMinuteDisabled:t=>{if(!v.row[$])return!1;const a=new Date(`${v.row[$].split(" ")[0]} ${o}:00:00`).getTime(),u=r.getSeconds();return s(t,i,e-60*t*1e3-1e3*u,a)},isSecondDisabled:t=>{if(!v.row[$])return!1;const r=new Date(`${v.row[$].split(" ")[0]} ${o}:${i}:00`).getTime();return s(t,a,e-1e3*t,r)}}};function F(e){return d(e)?t=>e(t,v.row):null}const M=o((()=>{const e=D.valueFormat||"yyyy-MM-dd HH:mm:ss";return{valueFormat:e,format:e,timePickerProps:{format:m(e)}}})),k={type:D.type||"datetime",clearable:!0,placeholder:D.placeholder||"请选择",...D,...M.value,isDateDisabled:F(D.isDateDisabled)||(e=>!!v.row[$]&&_(e,T?new Date(`${v.row[$].split(" ")[0]} 00:00:00`).getTime():new Date(v.row[$]).getTime()))};return k.type.includes("time")&&(k.isTimeDisabled=F(D.isTimeDisabled)||x),i((()=>v.value),(e=>{b.value=e})),(e,t)=>(a(),s(u(f),l({ref_key:"formRef",ref:h,show:u(y),"onUpdate:show":t[0]||(t[0]=e=>n(y)?y.value=e:null),"formatted-value":b.value},u(k),{"onUpdate:formattedValue":j}),null,16,["show","formatted-value"]))}}),[["__file","editDate.vue"]]);export{v as default};
1
+ import{defineComponent as e,useAttrs as t,ref as r,computed as a,watch as o,openBlock as l,createBlock as i,unref as u,mergeProps as s,withCtx as n,createVNode as d,isRef as m}from"vue";import{generateTimeFormat as c}from"../../../../../../../shared/utils/index.js";import{isFunction as v,isNaN as p}from"lodash-es";import{NPopover as f,NInput as w,NDatePicker as g}from"naive-ui";import{useIhoTableFormEvent as D}from"../../../../utils/index.js";import{useAutoFocus as $}from"../hooks/useAutoFocus.js";import h from"../../../../../../../_virtual/plugin-vue_export-helper.js";var y=h(e({__name:"editDate",props:{value:{type:String,default:void 0},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0}},emits:["update:value"],setup(e,{emit:h}){const y=e,b=t(),{emitFormChangeWithParams:T}=D(y),{formRef:k,isShow:_}=$(),F=r(),S=e=>{const t=y.value;h("update:value",e),T({oldValue:t})},{isStartDate:j=!1,isEndDate:M=!1}=b,U=b.connectField||"",x=(e,t)=>j&&U?e>t:!(!M||!U)&&e<t,H=e=>{const t=new Date(y.row[U]),r=new Date(e),a=t.getHours(),o=t.getMinutes(),l=t.getSeconds(),i=(e,t,r,a)=>!(M&&r>a)&&(!(j&&r<a)&&x(e,t));return{isHourDisabled:t=>{if(!y.row[U])return!1;const o=new Date(`${y.row[U].split(" ")[0]} 00:00:00`).getTime(),l=r.getMinutes(),u=r.getSeconds();return i(t,a,e-60*t*60*1e3-60*l*1e3-1e3*u,o)},isMinuteDisabled:t=>{if(!y.row[U])return!1;const l=new Date(`${y.row[U].split(" ")[0]} ${a}:00:00`).getTime(),u=r.getSeconds();return i(t,o,e-60*t*1e3-1e3*u,l)},isSecondDisabled:t=>{if(!y.row[U])return!1;const r=new Date(`${y.row[U].split(" ")[0]} ${a}:${o}:00`).getTime();return i(t,l,e-1e3*t,r)}}};function P(e){return v(e)?t=>e(t,y.row):null}function q(e){if(!e)return"";const t=new Date(e),r=`00${t.getMonth()+1}`.slice(-2),a=`00${t.getDate()}`.slice(-2),o=R.value.valueFormat,l=o.includes("/")?"/":o.includes(".")?".":"-";let i=`${t.getFullYear()}${l}${r}${l}${a}`;const u=t.getTime(),s=new Date(y.row[U]).getTime();return y.row[U]&&(j&&u>s||M&&u<s)&&(i=""),i}function C(){let e=F.value;if(p(new Date(e).getTime()))if(/^\d{8}$/.test(e)){const t=`${e.slice(0,4)} ${e.slice(4,6)} ${e.slice(6)}`;e="",p(new Date(t).getTime())||(e=q(t))}else e="";else e=q(e);F.value=e||void 0,S(F.value)}const R=a((()=>{const e=b.valueFormat||"yyyy-MM-dd HH:mm:ss";return{valueFormat:e,format:e,timePickerProps:{format:c(e)}}})),A={type:b.type||"datetime",clearable:!0,placeholder:b.placeholder||"请选择",...b,...R.value,isDateDisabled:P(b.isDateDisabled)||(e=>!!y.row[U]&&x(e,M?new Date(`${y.row[U].split(" ")[0]} 00:00:00`).getTime():new Date(y.row[U]).getTime())),onUpdateFormattedValue:S};return A.type.includes("time")&&(A.isTimeDisabled=P(b.isTimeDisabled)||H),o((()=>y.value),(e=>{F.value=e})),(e,t)=>e.$attrs.isPopover?(l(),i(u(f),s({key:0,show:u(_),trigger:"click",showArrow:!1,placement:"bottom-start",style:{padding:"0"}},e.$attrs,{onClickoutside:t[4]||(t[4]=()=>_.value=!1)}),{trigger:n((()=>[d(u(w),{ref_key:"formRef",ref:k,clearable:"",value:F.value,"onUpdate:value":t[0]||(t[0]=e=>F.value=e),onBlur:C,onClick:t[1]||(t[1]=()=>_.value=!0)},null,8,["value"])])),default:n((()=>[d(u(g),s({panel:"",show:u(_),"onUpdate:show":t[2]||(t[2]=e=>m(_)?_.value=e:null),"formatted-value":F.value,"onUpdate:formatted-value":t[3]||(t[3]=e=>F.value=e)},u(A)),null,16,["show","formatted-value"])])),_:1},16,["show"])):(l(),i(u(g),s({key:1,ref_key:"formRef",ref:k,show:u(_),"onUpdate:show":t[5]||(t[5]=e=>m(_)?_.value=e:null),"formatted-value":F.value,"onUpdate:formatted-value":t[6]||(t[6]=e=>F.value=e)},u(A)),null,16,["show","formatted-value"]))}}),[["__file","editDate.vue"]]);export{y as default};
@@ -52,30 +52,13 @@ declare const _default: import("vue").DefineComponent<{
52
52
  shortcutOptions: any;
53
53
  timeConfig: AnyObject;
54
54
  clickShortcutOption: (item: string) => void;
55
- onUpdateFormattedValue: (value: string) => void;
56
55
  onBlur: () => void;
57
- onKeyUp: (event: AnyObject) => void;
56
+ NTimePicker: any;
58
57
  NInput: any;
59
58
  NPopover: any;
60
59
  NSpace: any;
61
60
  NButton: any;
62
61
  NScrollbar: any;
63
- TimePicker: import("../../../../../../../../es/shared/types").SFCWithInstall<import("vue").DefineComponent<{}, {
64
- attrs: {
65
- [x: string]: unknown;
66
- };
67
- emits: (event: "update:formattedValue", ...args: any[]) => void;
68
- timePickerRef: import("vue").Ref<null>;
69
- __formattedValue: import("vue").Ref<any>;
70
- keyupValue: import("vue").Ref<string>;
71
- formatRef: import("vue").ComputedRef<string>;
72
- updateFormattedValue: (value: any) => void;
73
- onBlur: () => void;
74
- onKeyUp: (event: AnyObject) => any;
75
- NTimePicker: any;
76
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:formattedValue"[], "update:formattedValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>> & {
77
- "onUpdate:formattedValue"?: ((...args: any[]) => any) | undefined;
78
- }, {}>>;
79
62
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("click" | "update:formattedValue")[], "click" | "update:formattedValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
80
63
  formattedValue: {
81
64
  type: StringConstructor;
@@ -1 +1 @@
1
- import{defineComponent as e,useAttrs as t,ref as a,openBlock as o,createBlock as l,unref as r,mergeProps as u,withCtx as i,createVNode as m,isRef as n,createElementBlock as d,Fragment as f,renderList as s,createTextVNode as c,toDisplayString as p,createCommentVNode as v}from"vue";import{NPopover as _,NInput as h,NSpace as y,NScrollbar as k,NButton as V}from"naive-ui";import{useIhoTableFormEvent as w}from"../../../../utils/index.js";import{useAutoFocus as b}from"../hooks/useAutoFocus.js";import g from"../../../../../../time-picker/index.js";import{parse as C,isValid as j,format as F}from"date-fns";import x from"../../../../../../../_virtual/plugin-vue_export-helper.js";var H=x(e({__name:"editTime",props:{formattedValue:{type:String,default:void 0},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0}},emits:["update:formattedValue","click"],setup(e,{emit:x}){const H=e,q=t(),{emitFormChangeWithParams:O}=w(H),{formRef:A,isShow:M}=b(),R=a(H.formattedValue);let S=H.formattedValue;const{placeholder:T="请选择",valueFormat:U="HH:mm",shortcutOptions:z=[]}=q,B={placeholder:T,valueFormat:U,format:U||"yyyy-MM-dd HH:mm:ss"};function D(e){R.value=e,S!==e&&(x("update:formattedValue",e),O({oldValue:S}),S=e)}function I(){const e=C(H.formattedValue||"",B.valueFormat.replace(/:/,""),new Date);if(j(e)){D(F(e,B.valueFormat))}}function K(e){var t;const{keyCode:a=0}=e;13==a&&(null==(t=A.value)||t.blur(),M.value=!1)}return(t,a)=>(o(),l(r(_),u({show:r(M),trigger:"click",showArrow:!1,placement:"bottom-start",style:{padding:"0"}},t.$attrs,{onClickoutside:a[3]||(a[3]=()=>M.value=!1)}),{trigger:i((()=>[m(r(h),{ref_key:"formRef",ref:A,clearable:"",value:e.formattedValue,"onUpdate:value":a[0]||(a[0]=e=>n(formattedValue)?formattedValue.value=e:null),onClick:a[1]||(a[1]=()=>M.value=!0),onBlur:I,onKeyup:K},null,8,["value"])])),default:i((()=>[m(r(y),null,{default:i((()=>[m(r(g),u({show:"","formatted-value":R.value},r(B),{class:"iho-table__time-picker",to:!1,"onUpdate:formattedValue":D,onConfirm:a[2]||(a[2]=()=>M.value=!1)}),null,16,["formatted-value"]),m(r(k),{class:"iho-table__scrollbar"},{default:i((()=>[r(z).length?(o(),l(r(y),{key:0,vertical:"",wrap:!1},{default:i((()=>[(o(!0),d(f,null,s(r(z),(e=>(o(),l(r(V),{size:"tiny",key:e,onClick:t=>function(e){D(e),M.value=!1}(e)},{default:i((()=>[c(p(e),1)])),_:2},1032,["onClick"])))),128))])),_:1})):v("v-if",!0)])),_:1})])),_:1})])),_:1},16,["show"]))}}),[["__file","editTime.vue"]]);export{H as default};
1
+ import{defineComponent as e,useAttrs as t,ref as a,openBlock as l,createBlock as o,unref as r,mergeProps as u,withCtx as i,createVNode as m,isRef as d,createElementBlock as s,Fragment as f,renderList as n,createTextVNode as p,toDisplayString as c,createCommentVNode as v}from"vue";import{NPopover as _,NInput as h,NSpace as y,NTimePicker as V,NScrollbar as k,NButton as g}from"naive-ui";import{useIhoTableFormEvent as w}from"../../../../utils/index.js";import{useAutoFocus as b}from"../hooks/useAutoFocus.js";import{isValidTime as F,getFormatTime as j}from"./timeUtils.js";import C from"../../../../../../../_virtual/plugin-vue_export-helper.js";var U=C(e({__name:"editTime",props:{formattedValue:{type:String,default:void 0},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0}},emits:["update:formattedValue","click"],setup(e,{emit:C}){const U=e,x=t(),{emitFormChangeWithParams:H}=w(U),{formRef:q,isShow:N}=b(),O=a(U.formattedValue);let $=U.formattedValue;const{placeholder:A="请选择",valueFormat:M="HH:mm",shortcutOptions:R=[]}=x,S={placeholder:A,valueFormat:M,format:M||"yyyy-MM-dd HH:mm:ss",onUpdateFormattedValue:e=>{$!==e&&(C("update:formattedValue",e),H({oldValue:$}),$=e)},onConfirm:()=>N.value=!1};function T(){let e=U.formattedValue;if(!F(e,M))if(isNaN(e)||!/^\d{4}$/.test(e)&&!/^\d{6}$/.test(e))e="";else{const t=j(e,M);e=F(t,M)?t:""}e=e||void 0,S.onUpdateFormattedValue(e),O.value=e}return(t,a)=>(l(),o(r(_),u({show:r(N),trigger:"click",showArrow:!1,placement:"bottom-start",style:{padding:"0"}},t.$attrs,{onClickoutside:a[3]||(a[3]=()=>N.value=!1)}),{trigger:i((()=>[m(r(h),{ref_key:"formRef",ref:q,clearable:"",value:e.formattedValue,"onUpdate:value":a[0]||(a[0]=e=>d(formattedValue)?formattedValue.value=e:null),onClick:a[1]||(a[1]=()=>N.value=!0),onBlur:T},null,8,["value"])])),default:i((()=>[m(r(y),null,{default:i((()=>[m(r(V),u({show:"","formatted-value":O.value,"onUpdate:formatted-value":a[2]||(a[2]=e=>O.value=e)},r(S),{class:"iho-table__time-picker",to:!1}),null,16,["formatted-value"]),m(r(k),{class:"iho-table__scrollbar"},{default:i((()=>[r(R).length?(l(),o(r(y),{key:0,vertical:"",wrap:!1},{default:i((()=>[(l(!0),s(f,null,n(r(R),(e=>(l(),o(r(g),{size:"tiny",key:e,onClick:t=>function(e){O.value=e,S.onUpdateFormattedValue(e),N.value=!1}(e)},{default:i((()=>[p(c(e),1)])),_:2},1032,["onClick"])))),128))])),_:1})):v("v-if",!0)])),_:1})])),_:1})])),_:1},16,["show"]))}}),[["__file","editTime.vue"]]);export{U as default};
@@ -0,0 +1,2 @@
1
+ export declare function getFormatTime(time: string, valueFormat: string): string | undefined;
2
+ export declare function isValidTime(time: string, valueFormat: string): boolean;
@@ -0,0 +1 @@
1
+ function t(t,d){if(!t)return"";return d.includes(":")?((t,d)=>{const n=new RegExp("\\w{1,"+d+"}","g"),e=t.match(n);return null==e?void 0:e.join(":")})(t,2):t}function d(t,d){if(/^(0\d{1}|1\d{1}|2[0-3]):([0-5]\d{1})$/.test(t)&&"HH:mm"===d||/^(0\d{1}|1\d{1}):([0-5]\d{1})$/.test(t)&&"hh:mm"===d||/^(0\d{1}|1\d{1}|2[0-3]):[0-5]\d{1}:([0-5]\d{1})$/.test(t)&&"HH:mm:ss"===d||/^(0\d{1}|1\d{1}):[0-5]\d{1}:([0-5]\d{1})$/.test(t)&&"hh:mm:ss"===d){const d=t.split(":");return 60*+d[0]*60+60*+d[1]+(d[3]?+d[3]:0)<86400}return!1}export{t as getFormatTime,d as isValidTime};
@@ -1 +1 @@
1
- import{createVNode as e}from"vue";import{jsonParse as r}from"../../../../../../shared/utils/index.js";import{isArray as l,isString as o}from"lodash-es";import"../../../../index.js";import{WIDGET_TYPE as t}from"../../../constants/index.js";import{defineTablePlugin as n}from"../../../hooks/useTablePlugin.js";function i(){return n({name:"labelRendererPlugin",vxe(n){n.renderer.add(t.LABEL,{renderCell(t,{row:n,column:i}){try{if(!n[i.field])return[];const t=r(n[i.field]),s=l(t.labels)?t.labels:(a=t.labelStr,o(a)?a.split(",").map((e=>({labelName:e}))):[]);return e("section",{style:{display:"flex"}},[s.map((function(r){return e("div",{style:{backgroundColor:r.color||"#5585f5",color:"white",flex:"1"}},[r.labelName])}))])}catch(e){return[]}var a}})}})}export{i as labelRendererPlugin};
1
+ import{createVNode as e}from"vue";import{isArray as r,isString as l}from"lodash-es";import"../../../../index.js";import{WIDGET_TYPE as o}from"../../../constants/index.js";import{defineTablePlugin as t}from"../../../hooks/useTablePlugin.js";function n(){return t({name:"labelRendererPlugin",vxe(t){t.renderer.add(o.LABEL,{renderCell(o,{row:t,column:n}){try{if(!t[n.field])return[];const o=JSON.parse(t[n.field]),i=r(o.labels)?o.labels:(a=o.labelStr,l(a)?a.split(",").map((e=>({labelName:e}))):[]);return e("section",{style:{display:"flex"}},[i.map((function(r){return e("div",{style:{backgroundColor:r.color||"#5585f5",color:"white",flex:"1"}},[r.labelName])}))])}catch(e){return[]}var a}})}})}export{n as labelRendererPlugin};
@@ -1 +1 @@
1
- import{defineComponent as e,watch as r,onBeforeUnmount as t,createVNode as n}from"vue";import{jsonParse as i,arrayed as o}from"../../../../../../shared/utils/index.js";import"../../../../index.js";import{WIDGET_TYPE as s}from"../../../constants/index.js";import{getRowHeight as l,IhoTableWarn as u}from"../../../utils/index.js";import d from"viewerjs";import"viewerjs/dist/viewer.css";import{defineTablePlugin as m}from"../../../hooks/useTablePlugin.js";function a(){return m({name:"pictureRendererPlugin",vxe(e){function r(e){return{renderCell(r,{row:t,column:s}){try{if(!t[s.field])return[];const r=i(t[s.field]),u=l()-16;return[n("section",{style:"display:flex;justify-content:center"},[n(p,{style:{width:u+"px",height:u+"px",...e},images:o(r).map((e=>e.url))},null)])]}catch(e){return u(`invalid ${r.name} value of field(${s.field}): ${t[s.field]}`),[]}}}}e.renderer.add(s.PICTURE,r({})),e.renderer.add(s.HEADPORTRAIT,r({"border-radius":"50%"}))}})}const p=e({name:"ViewerImage",props:{images:{type:Array,default:()=>[]},options:{type:Object,default:()=>({})}},setup(e){let i=null;function o(){if(i)return i.show();const r=document.createElement("section");e.images.map((e=>r.appendChild(function(e){const r=new Image;return r.src=e,r}(e)))),i=new d(r,e.options).show()}return r([()=>e.images,()=>e.options],(()=>{null==i||i.destroy(),i=null}),{deep:!0}),t((()=>null==i?void 0:i.destroy())),()=>n("img",{style:"cursor:pointer",alt:"",src:e.images[0],onClick:o},null)}});export{a as pictureRendererPlugin};
1
+ import{defineComponent as e,watch as r,onBeforeUnmount as t,createVNode as n}from"vue";import{arrayed as i}from"../../../../../../shared/utils/index.js";import"../../../../index.js";import{WIDGET_TYPE as o}from"../../../constants/index.js";import{getRowHeight as s,IhoTableWarn as l}from"../../../utils/index.js";import u from"viewerjs";import"viewerjs/dist/viewer.css";import{defineTablePlugin as d}from"../../../hooks/useTablePlugin.js";function m(){return d({name:"pictureRendererPlugin",vxe(e){function r(e){return{renderCell(r,{row:t,column:o}){try{if(!t[o.field])return[];const r=JSON.parse(t[o.field]),l=s()-16;return[n("section",{style:"display:flex;justify-content:center"},[n(a,{style:{width:l+"px",height:l+"px",...e},images:i(r).map((e=>e.url))},null)])]}catch(e){return l(`invalid ${r.name} value of field(${o.field}): ${t[o.field]}`),[]}}}}e.renderer.add(o.PICTURE,r({})),e.renderer.add(o.HEADPORTRAIT,r({"border-radius":"50%"}))}})}const a=e({name:"ViewerImage",props:{images:{type:Array,default:()=>[]},options:{type:Object,default:()=>({})}},setup(e){let i=null;function o(){if(i)return i.show();const r=document.createElement("section");e.images.map((e=>r.appendChild(function(e){const r=new Image;return r.src=e,r}(e)))),i=new u(r,e.options).show()}return r([()=>e.images,()=>e.options],(()=>{null==i||i.destroy(),i=null}),{deep:!0}),t((()=>null==i?void 0:i.destroy())),()=>n("img",{style:"cursor:pointer",alt:"",src:e.images[0],onClick:o},null)}});export{m as pictureRendererPlugin};
@@ -1 +1 @@
1
- import{inject as o,createVNode as e}from"vue";import{SettingsSharp as n}from"@vicons/ionicons5";import{isFunction as i}from"lodash-es";import{NIcon as t}from"naive-ui";import"../../../../index.js";import{InjectionIhoTableEmits as r}from"../../../constants/index.js";import{IhoTableStatusHelper as s}from"../../../utils/index.js";import{defineTablePlugin as l}from"../../../hooks/useTablePlugin.js";function f(){const f="seqRendererPlugin";return l({name:f,apply(l){l.fieldHooks.field.tap({name:f,before:"checkRendererPlugin"},((l,{index:m,insertBefore:u},c)=>{var d;if(0===m&&c.showSeq){const l={align:"center",fixed:"left",width:50,type:"seq",field:f,annotation:!1,slots:{header(){if(s.isPositive(c.hideSettingBtn))return[];const i=o(r);return[e(t,{style:{cursor:"pointer"},size:"14",color:"#777",component:n,onClick:function(){i&&i("settingClick")}},null)]}}};i(null==(d=c.columnConfig)?void 0:d.seqSlotFn)&&(l.slots||(l.slots={}),l.slots.default=c.columnConfig.seqSlotFn),u(l)}return l}))}})}export{f as seqRendererPlugin};
1
+ import{inject as o,createVNode as e}from"vue";import{SettingsSharp as n}from"@vicons/ionicons5";import{isFunction as i}from"lodash-es";import{NIcon as t}from"naive-ui";import"../../../../index.js";import{InjectionIhoTableEmits as r}from"../../../constants/index.js";import{defineTablePlugin as s}from"../../../hooks/useTablePlugin.js";function l(){const l="seqRendererPlugin";return s({name:l,apply(s){s.fieldHooks.field.tap({name:l,before:"checkRendererPlugin"},((s,{index:f,insertBefore:c},m)=>{var u;if(0===f&&m.showSeq){const s={align:"center",fixed:"left",width:50,type:"seq",field:l,annotation:!1,slots:{header(){const i=o(r);return[e(t,{style:{cursor:"pointer"},size:"14",color:"#777",component:n,onClick:function(){i&&i("settingClick")}},null)]}}};i(null==(u=m.columnConfig)?void 0:u.seqSlotFn)&&(s.slots.default=m.columnConfig.seqSlotFn),c(s)}return s}))}})}export{l as seqRendererPlugin};
@@ -1 +1 @@
1
- import{traverse as e,uuidGenerator as t,DMZ as r}from"../../../../../shared/utils/index.js";import{isArray as n,isFunction as i}from"lodash-es";import{onBeforeUnmount as o}from"vue";import"../../../index.js";import{HIGHEST_PRIORITY as s,IHO_TABLE_TREE_TYPE as a}from"../../constants/index.js";import{isTransformTreeType as d}from"../../utils/index.js";import{defineTablePlugin as l}from"../../hooks/useTablePlugin.js";function f(){const f="virtualTreePlugin",u=new Map;return l({name:f,apply(l){l.configHooks.treeConfig.tap({name:f,stage:s},((e,t)=>d(t)?Object.assign({transform:!0,expandAll:!0,reserve:!0,children:"childrenList",rowField:"__id"},e):e)),l.dataHooks.data.tap(f,((r,i,o)=>{if(!i.treeConfig)return;const{transform:s,rowField:a="__id",parentField:l="parentId",children:f="childrenList"}=i.treeConfig;function u(e){e[a]=e[a]||e.theUniqueKey||t()}d(i)&&s&&(u(r),n(r[f])&&e(r[f],((e,t,r)=>{r&&(e[l]=r[a]),o.insertAfter(e),u(e)}),f,r))})),l.fieldHooks.fieldList.tap(f,((e,t)=>{if(!t.treeConfig)return e;const{transform:n}=t.treeConfig||r;if(!d(t)||!n||!t.uuid)return e;const i=e.filter((e=>!1!==e.visible));let o=i.findIndex((e=>e.treeNode));~o||i.some(((e,t)=>{if(!e.type)return o=t,e.treeNode=!0}));const s=i.length-o-i.filter((e=>"right"===e.fixed)).length;return u.set(t.uuid,{index:o,colspan:s}),e})),l.configHooks.treeConfig.tap(f,((e,t)=>{if(!e)return e;const{transform:r,parentField:n="parentId",hasChild:o="hasChild"}=e;if(i(t.spanMethod)||!r||`${t.isTree}`!==a.TRANSFORM_WITH_SPAN_METHOD)return e;const s=Object.freeze({rowspan:0,colspan:0}),d=Object.freeze({rowspan:1,colspan:1});return t.spanMethod=({row:e,column:r,$columnIndex:i})=>{const a=u.get(t.uuid);if(!a)return d;const l=Reflect.has(e,o)?!e[o]:e[n];return r.treeNode?l?d:{rowspan:1,colspan:a.colspan}:l||"right"===r.fixed||i<a.index?d:s},e})),l.setupHooks.setup.tap(f,(e=>{o((()=>{var t;(null==(t=e.value)?void 0:t.uuid)&&u.delete(e.value.uuid)}))}))}})}export{f as virtualTreePlugin};
1
+ import{traverse as e,uuidGenerator as t,DMZ as r}from"../../../../../shared/utils/index.js";import{isArray as n,isFunction as o}from"lodash-es";import{onBeforeUnmount as i}from"vue";import"../../../index.js";import{defineTablePlugin as s}from"../../hooks/useTablePlugin.js";function a(){const a="virtualTreePlugin",d=new Map;return s({name:a,apply(s){s.dataHooks.data.tap(a,((r,o,i)=>{if(!o.treeConfig)return;const{transform:s,rowField:a="__parentId",parentField:d="parentId",children:l="childrenList"}=o.treeConfig;function u(e){e[a]=e[a]||e.theUniqueKey||t()}s&&(u(r),n(r[l])&&e(r[l],((e,t,r)=>{r&&(e[d]=r[a]),i.insertAfter(e),u(e)}),l,r))})),s.fieldHooks.fieldList.tap(a,((e,t)=>{const{transform:n}=t.treeConfig||r;if(n&&t.uuid){const r=e.filter((e=>!1!==e.visible));let n=r.findIndex((e=>e.treeNode));~n||r.some(((e,t)=>{if(!e.type)return n=t,e.treeNode=!0}));const o=r.length-n-r.filter((e=>"right"===e.fixed)).length;d.set(t.uuid,{index:n,colspan:o})}return e})),s.configHooks.treeConfig.tap(a,((e,t)=>{if(!e)return e;const{transform:r,parentField:n="parentId",rowField:i="__parentId"}=e;if(!r)return e;if(Object.assign(e,{parentField:n,rowField:i}),r&&!o(t.spanMethod)){const e=Object.freeze({rowspan:0,colspan:0}),r=Object.freeze({rowspan:1,colspan:1});t.spanMethod=({row:o,column:i,$columnIndex:s})=>{const a=d.get(t.uuid);return a?i.treeNode?o[n]?r:{rowspan:1,colspan:a.colspan}:o[n]||"right"===i.fixed||s<a.index?r:e:r}}return e})),s.setupHooks.setup.tap(a,(e=>{i((()=>{var t;(null==(t=e.value)?void 0:t.uuid)&&d.delete(e.value.uuid)}))}))}})}export{a as virtualTreePlugin};
@@ -15,7 +15,6 @@ export declare type IhoTableConfig = VxeTableProps & Partial<{
15
15
  uuid: string;
16
16
  isTree: MaybeString<0 | 1 | 2 | 3>;
17
17
  isBatchSelect: MaybeString<0 | 1>;
18
- hideSettingBtn: MaybeString<0 | 1>;
19
18
  showSeq: boolean;
20
19
  selectType: Exclude<VxeTableDefines.ColumnInfo['type'], 'seq' | 'expand' | 'html'>;
21
20
  rowGroupSetting: Partial<Record<TupleToUnion<typeof IhoTableRowGroupSequence>, IhoTableRowGroupItem[]>>;
@@ -46,5 +46,4 @@ export declare const createIhoTableClearActivedInterceptor: (type: EDITABLE_WIDG
46
46
  $event: Event;
47
47
  column: VxeTableDefines.ColumnInfo;
48
48
  }) => boolean;
49
- export declare function isTransformTreeType(config: IhoTableConfig): boolean;
50
49
  export {};
@@ -1 +1 @@
1
- import{inject as e,unref as n,toRaw as t,createVNode as r}from"vue";import{jsonParse as o,findAncestor as i}from"../../../../shared/utils/index.js";import{promiseTimeout as u}from"@vueuse/shared";import{isNumber as l,cloneDeep as c,isString as a,isObject as d}from"lodash-es";import{InjectionIhoTableEmits as s,InjectionIhoTableConfig as f,IHO_TABLE_STRING_STATUS as m,IHO_TABLE_NUMBER_STATUS as v,IHO_TABLE_TREE_TYPE as p}from"../constants/index.js";function I(e){return console.warn(`[IhoTable]: ${e}`)}const E=Object.freeze({getCellType(e){var n;return((null==(n=e.settingObj)?void 0:n.attr)||e.formType||"DEFAULT").toUpperCase()}});function T(){var n,t,r;const o=e(f);return o||I("this function(getRowHeight) only can be used in setup environment"),null!=(r=null==(t=null==(n=null==o?void 0:o.value)?void 0:n.rowConfig)?void 0:t.height)?r:32}function h(e){const n=e.slice(2);return`${n[0].toLowerCase()}${n.slice(1)}`}function g(e){return`on${e[0].toUpperCase()}${e.slice(1)}`}async function C(e,t){return r()||await u(0),r()||function(){const n=+e.colWidth;return l(n)?n:64}();function r(){var r,o;return null==(o=null==(r=n(t))?void 0:r.getColumnByField(e.field))?void 0:o.renderWidth}}function w(n){const r=e(s);function o(){var e;return{value:n.row[n.column.field],row:n.row,column:{...n.column,...null==(e=n.column.editRender)?void 0:e.props},index:n.rowIndex>-1?n.rowIndex:n.$rowIndex}}function i(e={}){r("formChange",{...o(),...c(t(e))})}function u(e={}){r("formClick",{...o(),...c(t(e))})}return{emitFormChange:function(){i()},emitFormClick:function(){u()},emitFormChangeWithParams:i,emitFormClickWithParams:u}}const O=Object.freeze({createDefaultRenderCell:function(){return function(e,{row:n,column:t}){return[r("span",null,[n[t.field]])]}},createRenderEdit:function(e){return function({props:n},t){return e({...t,fieldItem:n||{},...w(t)})}},isEditableColumn(e,n){var t;return!1!==(null==(t=e.editConfig)?void 0:t.showIcon)&&n.editRender&&!1!==n.editRender.enabled},hasFilter(e){return a(e)&&(e=o(e||"")),d(e)&&((n=e).notParticipatingSearch!==m.POSITIVE&&"manual"===(null==(t=n.mapping)?void 0:t.type));var n,t}}),P=Object.freeze({isPositive:e=>e===v.POSITIVE||e===m.POSITIVE,isNegative:e=>e===v.NEGATIVE||e===m.NEGATIVE,notPositive:e=>e!==v.POSITIVE&&e!==m.POSITIVE,notNegative:e=>e!==v.NEGATIVE&&e!==m.NEGATIVE}),R=(e,n)=>({$event:t,column:r})=>{var o;if((null==(o=r.editRender)?void 0:o.name)!==e)return!0;const u=null==t?void 0:t.target;return!d(u)||!i(u,n)};function F(e){return[p.TRANSFORM_WITH_SPAN_METHOD,p.TRANSFORM_TREE_TYPE].includes(`${e.isTree}`)}export{O as IhoTableRenderHelper,P as IhoTableStatusHelper,E as IhoTableUtils,I as IhoTableWarn,R as createIhoTableClearActivedInterceptor,h as eventListener2EventName,g as eventName2EventListener,C as getColumnRenderWidth,T as getRowHeight,F as isTransformTreeType,w as useIhoTableFormEvent};
1
+ import{inject as e,unref as n,toRaw as t,createVNode as r}from"vue";import{jsonParse as o,findAncestor as i}from"../../../../shared/utils/index.js";import{promiseTimeout as u}from"@vueuse/shared";import{isNumber as l,cloneDeep as c,isString as a,isObject as d}from"lodash-es";import{InjectionIhoTableEmits as s,InjectionIhoTableConfig as f,IHO_TABLE_STRING_STATUS as m,IHO_TABLE_NUMBER_STATUS as v}from"../constants/index.js";function p(e){return console.warn(`[IhoTable]: ${e}`)}const I=Object.freeze({getCellType(e){var n;return((null==(n=e.settingObj)?void 0:n.attr)||e.formType||"DEFAULT").toUpperCase()}});function h(){var n,t,r;const o=e(f);return o||p("this function(getRowHeight) only can be used in setup environment"),null!=(r=null==(t=null==(n=null==o?void 0:o.value)?void 0:n.rowConfig)?void 0:t.height)?r:32}function g(e){const n=e.slice(2);return`${n[0].toLowerCase()}${n.slice(1)}`}function E(e){return`on${e[0].toUpperCase()}${e.slice(1)}`}async function C(e,t){return r()||await u(0),r()||function(){const n=+e.colWidth;return l(n)?n:64}();function r(){var r,o;return null==(o=null==(r=n(t))?void 0:r.getColumnByField(e.field))?void 0:o.renderWidth}}function w(n){const r=e(s);function o(){var e;return{value:n.row[n.column.field],row:n.row,column:{...n.column,...null==(e=n.column.editRender)?void 0:e.props},index:n.rowIndex>-1?n.rowIndex:n.$rowIndex}}function i(e={}){r("formChange",{...o(),...c(t(e))})}function u(e={}){r("formClick",{...o(),...c(t(e))})}return{emitFormChange:function(){i()},emitFormClick:function(){u()},emitFormChangeWithParams:i,emitFormClickWithParams:u}}const T=Object.freeze({createDefaultRenderCell:function(){return function(e,{row:n,column:t}){return[r("span",null,[n[t.field]])]}},createRenderEdit:function(e){return function({props:n},t){return e({...t,fieldItem:n||{},...w(t)})}},isEditableColumn(e,n){var t;return!1!==(null==(t=e.editConfig)?void 0:t.showIcon)&&n.editRender&&!1!==n.editRender.enabled},hasFilter(e){return a(e)&&(e=o(e||"")),d(e)&&((n=e).notParticipatingSearch!==m.POSITIVE&&"manual"===(null==(t=n.mapping)?void 0:t.type));var n,t}}),P=Object.freeze({isPositive:e=>e===v.POSITIVE||e===m.POSITIVE,isNegative:e=>e===v.NEGATIVE||e===m.NEGATIVE,notPositive:e=>e!==v.POSITIVE&&e!==m.POSITIVE,notNegative:e=>e!==v.NEGATIVE&&e!==m.NEGATIVE}),O=(e,n)=>({$event:t,column:r})=>{var o;if((null==(o=r.editRender)?void 0:o.name)!==e)return!0;const u=null==t?void 0:t.target;return!d(u)||!i(u,n)};export{T as IhoTableRenderHelper,P as IhoTableStatusHelper,I as IhoTableUtils,p as IhoTableWarn,O as createIhoTableClearActivedInterceptor,g as eventListener2EventName,E as eventName2EventListener,C as getColumnRenderWidth,h as getRowHeight,w as useIhoTableFormEvent};
@@ -1 +1 @@
1
- .iho-table__boldCell{font-weight:700}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar{background-color:transparent;height:10px;width:10px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#f2f2f2;border:3px dashed transparent;border-radius:5px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb:hover,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb:hover{background:#b2b2b2}.iho-table .vxe-table--empty-content{height:100%;width:100%}.iho-table .vxe-table--empty-content>div,.iho-table .vxe-tree-cell{height:100%}.iho-table .vxe-table--header{background-color:#f2f2f2}.iho-table .vxe-cell--title{color:#35393c}.iho-table .vxe-footer--row .vxe-footer--column>.vxe-cell .vxe-cell--item{height:30px;line-height:30px}.iho-table .vxe-table--render-default .vxe-body--row.row--hover,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--stripe{background-color:var(--c-hover-color)}.iho-table .vxe-table--render-default .vxe-body--row.row--checked,.iho-table .vxe-table--render-default .vxe-body--row.row--current,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--checked,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--current,.iho-table .vxe-table--render-default .vxe-body--row.row--hover.row--radio,.iho-table .vxe-table--render-default .vxe-body--row.row--radio{background-color:var(--c-primary-color-opacity2);font-weight:700}.iho-table .vxe-body--expanded-column,.iho-table .vxe-table--border-line{border-color:var(--c-border-color)!important}.iho-table .vxe-table--footer-wrapper{border-top-color:var(--c-border-color)!important}.iho-table .border--default .vxe-body--column,.iho-table .border--default .vxe-footer--column,.iho-table .border--default .vxe-header--column,.iho-table .border--inner .vxe-body--column,.iho-table .border--inner .vxe-footer--column,.iho-table .border--inner .vxe-header--column{background-image:linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .border--full .vxe-body--column,.iho-table .border--full .vxe-footer--column,.iho-table .border--full .vxe-header--column{background-image:linear-gradient(var(--c-border-color),var(--c-border-color)),linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .border--default .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--full .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--inner .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--outer .vxe-header--row:last-child .vxe-header--gutter{background-image:linear-gradient(var(--c-border-color),var(--c-border-color))!important}.iho-table .vxe-table--header-border-line{border-bottom-color:var(--c-border-color)!important}.iho-table .vxe-table--fixed-left-wrapper.scrolling--middle{box-shadow:7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .vxe-table--fixed-right-wrapper.scrolling--middle{box-shadow:-7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .icon-dot{background:var(--table-icon-color);box-shadow:0 2px 4px 0 var(--table-icon-shadow)}.iho-table .icon-dot,.iho-table .icon-dot-red{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-red{background:red;box-shadow:0 2px 4px 0 rgba(255,0,0,.5)}.iho-table .icon-dot-blue{background:blue;box-shadow:0 2px 4px 0 rgba(0,0,255,.5)}.iho-table .icon-dot-blue,.iho-table .icon-dot-green{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-green{background:green;box-shadow:0 2px 4px 0 rgba(0,128,0,.5)}.iho-table .icon-dot-gray{background:gray;box-shadow:0 2px 4px 0 hsla(0,0%,50%,.5)}.iho-table .icon-dot-gray,.iho-table .icon-dot-yellow{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-yellow{background:#ff0;box-shadow:0 2px 4px 0 rgba(255,255,0,.5)}.iho-table .icon-dot-resolved{background:#36be8c;box-shadow:0 2px 4px 0 rgba(54,190,140,.5)}.iho-table .icon-dot-huifu,.iho-table .icon-dot-resolved{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-huifu{background:#42d0f6;box-shadow:0 2px 4px 0 rgba(66,208,246,.5)}.iho-table .icon-dot-close{background:#718391;box-shadow:0 2px 4px 0 rgba(113,131,145,.5)}.iho-table .icon-dot-audit,.iho-table .icon-dot-close{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-audit{background:#f4ba32;box-shadow:0 2px 4px 0 rgba(244,186,50,.5)}.iho-table .icon-dot-design{background:#927ce1;box-shadow:0 2px 4px 0 rgba(146,124,225,.5)}.iho-table .icon-dot-design,.iho-table .icon-dot-develop{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-develop{background:#4eb0ef;box-shadow:0 2px 4px 0 rgba(78,176,239,.5)}.iho-table .icon-dot-develop-complete{background:#6381f9;border-radius:50%;box-shadow:0 2px 4px 0 rgba(99,129,249,.5);display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table__hideSortIcon .vxe-cell--sort{display:none!important}.iho-table__sortActiveIcon{margin-right:4px;width:14px}.iho-table__filterIcon{cursor:pointer;padding:0 4px}.iho-table__filterIcon:hover{opacity:.7}.iho-table__filterIcon.is-active{color:#5585f5}.iho-table__filterWrapper{display:flex;flex-direction:column;gap:8px;margin:8px 12px;width:240px}.iho-table__filterButton{align-items:center;border-radius:4px;cursor:pointer;display:flex;height:30px;padding:0 8px}.iho-table__filterButton--active{color:#5585f5}.iho-table__filterButton:hover{background:rgba(0,0,0,.05)}.iho-table__filterListWrapper{border:1px solid rgba(0,0,0,.05)}.iho-table__filterListItem{align-items:center;border-radius:4px;display:flex;height:32px;padding:0 8px}.iho-table__filterListItem:hover{background:rgba(0,0,0,.05)}.iho-table__filterListItem .n-checkbox{width:100%}.iho-table__filterFooter{display:flex;justify-content:space-between}.iho-table__time-picker{position:unset}.iho-table__time-picker .n-input{display:none}.iho-table__time-picker .v-binder-follower-container{height:auto;position:unset}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content{position:unset;transform:none!important}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content .n-time-picker-panel{box-shadow:none}.iho-table__scrollbar{margin:8px 8px 8px 0;max-height:255px}.iho-table{height:100%}.iho-table .vxe-header--column [annotation-hover-show=true]{visibility:hidden}.iho-table .vxe-header--column:hover [annotation-hover-show=true]{visibility:visible}.iho-table__headerWrapper{display:inline-flex}
1
+ .iho-table__boldCell{font-weight:700}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar{background-color:transparent;height:10px;width:10px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#f2f2f2;border:3px dashed transparent;border-radius:5px}.iho-table .vxe-table--body-wrapper::-webkit-scrollbar-thumb:hover,.iho-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar-thumb:hover{background:#b2b2b2}.iho-table .vxe-table--empty-content{height:100%;width:100%}.iho-table .vxe-table--empty-content>div,.iho-table .vxe-tree-cell{height:100%}.iho-table .vxe-table--header{background-color:#f2f2f2}.iho-table .vxe-cell--title{color:#35393c}.iho-table .vxe-footer--row .vxe-footer--column>.vxe-cell .vxe-cell--item{height:30px;line-height:30px}.iho-table .vxe-body--expanded-column,.iho-table .vxe-table--border-line{border-color:#d5d5d599!important}.iho-table .vxe-table--footer-wrapper{border-top-color:#d5d5d599!important}.iho-table .border--default .vxe-body--column,.iho-table .border--default .vxe-footer--column,.iho-table .border--default .vxe-header--column,.iho-table .border--inner .vxe-body--column,.iho-table .border--inner .vxe-footer--column,.iho-table .border--inner .vxe-header--column{background-image:linear-gradient(#d5d5d599,#d5d5d599)!important}.iho-table .border--full .vxe-body--column,.iho-table .border--full .vxe-footer--column,.iho-table .border--full .vxe-header--column{background-image:linear-gradient(#d5d5d599,#d5d5d599),linear-gradient(#d5d5d599,#d5d5d599)!important}.iho-table .border--default .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--full .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--inner .vxe-header--row:last-child .vxe-header--gutter,.iho-table .border--outer .vxe-header--row:last-child .vxe-header--gutter{background-image:linear-gradient(#d5d5d599,#d5d5d599)!important}.iho-table .vxe-table--header-border-line{border-bottom-color:#d5d5d599!important}.iho-table .vxe-table--fixed-left-wrapper.scrolling--middle{box-shadow:7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .vxe-table--fixed-right-wrapper.scrolling--middle{box-shadow:-7px 0 8px -3px rgba(0,0,0,.15)!important}.iho-table .icon-dot{background:var(--table-icon-color);box-shadow:0 2px 4px 0 var(--table-icon-shadow)}.iho-table .icon-dot,.iho-table .icon-dot-red{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-red{background:red;box-shadow:0 2px 4px 0 rgba(255,0,0,.5)}.iho-table .icon-dot-blue{background:blue;box-shadow:0 2px 4px 0 rgba(0,0,255,.5)}.iho-table .icon-dot-blue,.iho-table .icon-dot-green{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-green{background:green;box-shadow:0 2px 4px 0 rgba(0,128,0,.5)}.iho-table .icon-dot-gray{background:gray;box-shadow:0 2px 4px 0 hsla(0,0%,50%,.5)}.iho-table .icon-dot-gray,.iho-table .icon-dot-yellow{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-yellow{background:#ff0;box-shadow:0 2px 4px 0 rgba(255,255,0,.5)}.iho-table .icon-dot-resolved{background:#36be8c;box-shadow:0 2px 4px 0 rgba(54,190,140,.5)}.iho-table .icon-dot-huifu,.iho-table .icon-dot-resolved{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-huifu{background:#42d0f6;box-shadow:0 2px 4px 0 rgba(66,208,246,.5)}.iho-table .icon-dot-close{background:#718391;box-shadow:0 2px 4px 0 rgba(113,131,145,.5)}.iho-table .icon-dot-audit,.iho-table .icon-dot-close{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-audit{background:#f4ba32;box-shadow:0 2px 4px 0 rgba(244,186,50,.5)}.iho-table .icon-dot-design{background:#927ce1;box-shadow:0 2px 4px 0 rgba(146,124,225,.5)}.iho-table .icon-dot-design,.iho-table .icon-dot-develop{border-radius:50%;display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table .icon-dot-develop{background:#4eb0ef;box-shadow:0 2px 4px 0 rgba(78,176,239,.5)}.iho-table .icon-dot-develop-complete{background:#6381f9;border-radius:50%;box-shadow:0 2px 4px 0 rgba(99,129,249,.5);display:inline-block;height:8px;margin-right:6px;width:8px}.iho-table__hideSortIcon .vxe-cell--sort{display:none!important}.iho-table__sortActiveIcon{margin-right:4px;width:14px}.iho-table__filterIcon{cursor:pointer;padding:0 4px}.iho-table__filterIcon:hover{opacity:.7}.iho-table__filterIcon.is-active{color:#5585f5}.iho-table__filterWrapper{display:flex;flex-direction:column;gap:8px;margin:8px 12px;width:240px}.iho-table__filterButton{align-items:center;border-radius:4px;cursor:pointer;display:flex;height:30px;padding:0 8px}.iho-table__filterButton--active{color:#5585f5}.iho-table__filterButton:hover{background:rgba(0,0,0,.05)}.iho-table__filterListWrapper{border:1px solid rgba(0,0,0,.05)}.iho-table__filterListItem{align-items:center;border-radius:4px;display:flex;height:32px;padding:0 8px}.iho-table__filterListItem:hover{background:rgba(0,0,0,.05)}.iho-table__filterListItem .n-checkbox{width:100%}.iho-table__filterFooter{display:flex;justify-content:space-between}.iho-table__time-picker{position:unset}.iho-table__time-picker .n-input{display:none}.iho-table__time-picker .v-binder-follower-container{height:auto;position:unset}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content{position:unset;transform:none!important}.iho-table__time-picker .v-binder-follower-container .v-binder-follower-content .n-time-picker-panel{box-shadow:none}.iho-table__scrollbar{margin:8px 8px 8px 0;max-height:255px}.iho-table{height:100%}.iho-table .vxe-header--column [annotation-hover-show=true]{visibility:hidden}.iho-table .vxe-header--column:hover [annotation-hover-show=true]{visibility:visible}.iho-table__headerWrapper{display:inline-flex}