vxe-pc-ui 4.9.24 → 4.9.26

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 (37) hide show
  1. package/es/date-range-picker/src/date-range-picker.js +13 -2
  2. package/es/icon/style.css +1 -1
  3. package/es/style.css +1 -1
  4. package/es/style.min.css +1 -1
  5. package/es/table-select/src/table-select.js +28 -23
  6. package/es/ui/index.js +1 -1
  7. package/es/ui/src/log.js +1 -1
  8. package/lib/date-range-picker/src/date-range-picker.js +14 -2
  9. package/lib/date-range-picker/src/date-range-picker.min.js +1 -1
  10. package/lib/icon/style/style.css +1 -1
  11. package/lib/icon/style/style.min.css +1 -1
  12. package/lib/index.umd.js +50 -31
  13. package/lib/index.umd.min.js +1 -1
  14. package/lib/style.css +1 -1
  15. package/lib/style.min.css +1 -1
  16. package/lib/table-select/src/table-select.js +34 -27
  17. package/lib/table-select/src/table-select.min.js +1 -1
  18. package/lib/ui/index.js +1 -1
  19. package/lib/ui/index.min.js +1 -1
  20. package/lib/ui/src/log.js +1 -1
  21. package/lib/ui/src/log.min.js +1 -1
  22. package/package.json +1 -1
  23. package/packages/date-range-picker/src/date-range-picker.ts +13 -2
  24. package/packages/table-select/src/table-select.ts +29 -23
  25. package/types/components/date-range-picker.d.ts +5 -0
  26. /package/es/icon/{iconfont.1757578479445.ttf → iconfont.1757663302345.ttf} +0 -0
  27. /package/es/icon/{iconfont.1757578479445.woff → iconfont.1757663302345.woff} +0 -0
  28. /package/es/icon/{iconfont.1757578479445.woff2 → iconfont.1757663302345.woff2} +0 -0
  29. /package/es/{iconfont.1757578479445.ttf → iconfont.1757663302345.ttf} +0 -0
  30. /package/es/{iconfont.1757578479445.woff → iconfont.1757663302345.woff} +0 -0
  31. /package/es/{iconfont.1757578479445.woff2 → iconfont.1757663302345.woff2} +0 -0
  32. /package/lib/icon/style/{iconfont.1757578479445.ttf → iconfont.1757663302345.ttf} +0 -0
  33. /package/lib/icon/style/{iconfont.1757578479445.woff → iconfont.1757663302345.woff} +0 -0
  34. /package/lib/icon/style/{iconfont.1757578479445.woff2 → iconfont.1757663302345.woff2} +0 -0
  35. /package/lib/{iconfont.1757578479445.ttf → iconfont.1757663302345.ttf} +0 -0
  36. /package/lib/{iconfont.1757578479445.woff → iconfont.1757663302345.woff} +0 -0
  37. /package/lib/{iconfont.1757578479445.woff2 → iconfont.1757663302345.woff2} +0 -0
@@ -160,35 +160,45 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
160
160
  return Object.assign({}, (0, _ui.getConfig)().tableSelect.popupConfig, props.popupConfig);
161
161
  });
162
162
  const computeGridOpts = (0, _vue.computed)(() => {
163
- const opts = Object.assign({}, (0, _ui.getConfig)().tableSelect.gridConfig, props.gridConfig, {
163
+ return Object.assign({}, (0, _ui.getConfig)().tableSelect.gridConfig, props.gridConfig, {
164
164
  data: undefined,
165
165
  columns: undefined
166
166
  });
167
+ });
168
+ const computeSelectGridOpts = (0, _vue.computed)(() => {
169
+ const gridOpts = computeGridOpts.value;
167
170
  const {
168
171
  proxyConfig
169
- } = opts;
170
- const ajaxMethods = proxyConfig && proxyConfig.ajax ? proxyConfig.ajax.query : null;
171
- if (proxyConfig && ajaxMethods) {
172
- const resConfigs = proxyConfig.response || proxyConfig.props || {};
173
- opts.proxyConfig = _xeUtils.default.merge({}, proxyConfig, {
174
- ajax: {
175
- query(params, ...args) {
176
- return Promise.resolve(ajaxMethods(params, ...args)).then(rest => {
177
- const listProp = resConfigs.list;
178
- const tableData = (listProp ? _xeUtils.default.isFunction(listProp) ? listProp({
179
- data: rest,
180
- $table: null,
181
- $grid: null,
182
- $gantt: null
183
- }) : _xeUtils.default.get(rest, listProp) : rest) || [];
184
- cacheDataMap(tableData || []);
185
- return rest;
186
- });
187
- }
172
+ } = gridOpts;
173
+ if (proxyConfig) {
174
+ const proxyAjax = proxyConfig.ajax;
175
+ if (proxyAjax && proxyAjax.query) {
176
+ const newProxyConfig = _xeUtils.default.clone(proxyConfig, true);
177
+ const ajaxMethods = proxyAjax.query;
178
+ if (ajaxMethods) {
179
+ const resConfigs = proxyConfig.response || proxyConfig.props || {};
180
+ Object.assign(newProxyConfig.ajax, {
181
+ query(params, ...args) {
182
+ return Promise.resolve(ajaxMethods(params, ...args)).then(rest => {
183
+ const listProp = resConfigs.list;
184
+ const tableData = (listProp ? _xeUtils.default.isFunction(listProp) ? listProp({
185
+ data: rest,
186
+ $table: null,
187
+ $grid: null,
188
+ $gantt: null
189
+ }) : _xeUtils.default.get(rest, listProp) : rest) || [];
190
+ cacheDataMap(tableData || []);
191
+ return rest;
192
+ });
193
+ }
194
+ });
188
195
  }
189
- });
196
+ return Object.assign({}, gridOpts, {
197
+ proxyConfig: newProxyConfig
198
+ });
199
+ }
190
200
  }
191
- return opts;
201
+ return gridOpts;
192
202
  });
193
203
  const computeSelectLabel = (0, _vue.computed)(() => {
194
204
  const {
@@ -596,7 +606,7 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
596
606
  const {
597
607
  className: popupClassName
598
608
  } = popupOpts;
599
- const gridOpts = computeGridOpts.value;
609
+ const selectGridOpts = computeSelectGridOpts.value;
600
610
  const rowOpts = computeRowOpts.value;
601
611
  const popupWrapperStyle = computePopupWrapperStyle.value;
602
612
  const headerSlot = slots.header;
@@ -663,7 +673,7 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
663
673
  ref: refGridWrapper,
664
674
  class: 'vxe-table-select-grid--wrapper',
665
675
  style: popupWrapperStyle
666
- }, [VxeTableGridComponent ? (0, _vue.h)(VxeTableGridComponent, Object.assign(Object.assign(Object.assign({}, gridOpts), gridEvents), {
676
+ }, [VxeTableGridComponent ? (0, _vue.h)(VxeTableGridComponent, Object.assign(Object.assign(Object.assign({}, selectGridOpts), gridEvents), {
667
677
  class: 'vxe-table-select--grid',
668
678
  ref: refGrid,
669
679
  rowConfig: rowOpts,
@@ -701,9 +711,6 @@ var _default = exports.default = (0, _comp.defineVxeComponent)({
701
711
  if (gridConfig.proxyConfig.autoLoad !== false) {
702
712
  reactData.initialized = true;
703
713
  }
704
- if (gridConfig.pagerConfig && gridConfig.pagerConfig.enabled !== false) {
705
- (0, _log.warnLog)('vxe.error.notProp', ['proxy-config & grid-config.pagerConfig']);
706
- }
707
714
  }
708
715
  _ui.globalEvents.on($xeTableSelect, 'mousewheel', handleGlobalMousewheelEvent);
709
716
  _ui.globalEvents.on($xeTableSelect, 'mousedown', handleGlobalMousedownEvent);
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0,exports.getRowUniqueId=getRowUniqueId;var _vue=require("vue"),_comp=require("../../ui/src/comp"),_xeUtils=_interopRequireDefault(require("xe-utils")),_ui=require("../../ui"),_dom=require("../../ui/src/dom"),_vn=require("../../ui/src/vn"),_utils=require("../../ui/src/utils"),_log=require("../../ui/src/log"),_input=_interopRequireDefault(require("../../input/src/input"));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function getRowUniqueId(){return _xeUtils.default.uniqueId("row_")}var _default=exports.default=(0,_comp.defineVxeComponent)({name:"VxeTableSelect",props:{modelValue:[String,Number,Array],clearable:Boolean,placeholder:{type:String,default:()=>_xeUtils.default.eqNull((0,_ui.getConfig)().tableSelect.placeholder)?(0,_ui.getI18n)("vxe.base.pleaseSelect"):(0,_ui.getConfig)().tableSelect.placeholder},readonly:{type:Boolean,default:null},loading:Boolean,disabled:{type:Boolean,default:null},multiple:Boolean,className:[String,Function],prefixIcon:String,placement:String,columns:Array,options:Array,optionProps:Object,zIndex:Number,size:{type:String,default:()=>(0,_ui.getConfig)().tableSelect.size||(0,_ui.getConfig)().size},popupConfig:Object,gridConfig:Object,transfer:{type:Boolean,default:null}},emits:["update:modelValue","change","clear","blur","focus","click","form-submit","form-reset","form-collapse","page-change"],setup(h,e){const{emit:a,slots:C}=e,y=_ui.VxeUI.getComponent("vxe-grid"),l=(0,_vue.inject)("$xeModal",null),i=(0,_vue.inject)("$xeDrawer",null),x=(0,_vue.inject)("$xeTable",null),o=(0,_vue.inject)("$xeForm",null),n=(0,_vue.inject)("xeFormItemInfo",null);var t=_xeUtils.default.uniqueId();const L=(0,_ui.useSize)(h)["computeSize"],E=(0,_vue.ref)(),T=(0,_vue.ref)(),$=(0,_vue.ref)(),w=(0,_vue.ref)(),I=(0,_vue.ref)(),S=(0,_vue.reactive)({initialized:!1,tableColumns:[],fullOptionList:[],fullRowMaps:{},panelIndex:0,panelStyle:{},panelPlacement:null,triggerFocusPanel:!1,visiblePanel:!1,isAniVisible:!1,isActivated:!1}),u={},k={refElem:E},N=(0,_vue.computed)(()=>{var e=h["readonly"];return null===e?!!o&&o.props.readonly:e}),P=(0,_vue.computed)(()=>{var e=h["disabled"];return null===e?!!o&&o.props.disabled:e}),U=(0,_vue.computed)(()=>{var e=h["transfer"];if(null===e){var t=(0,_ui.getConfig)().select.transfer;if(_xeUtils.default.isBoolean(t))return t;if(x||l||i||o)return!0}return e}),r=(0,_vue.computed)(()=>h.optionProps||{}),q=(0,_vue.computed)(()=>{var e=A.value;return Object.assign({},e.rowConfig,{isCurrent:!0})}),s=(0,_vue.computed)(()=>{return q.value.keyField||"_X_ROW_KEY"}),F=(0,_vue.computed)(()=>{return r.value.label||"label"}),v=(0,_vue.computed)(()=>{return r.value.value||"value"}),j=(0,_vue.computed)(()=>Object.assign({},(0,_ui.getConfig)().tableSelect.popupConfig,h.popupConfig)),A=(0,_vue.computed)(()=>{var e=Object.assign({},(0,_ui.getConfig)().tableSelect.gridConfig,h.gridConfig,{data:void 0,columns:void 0}),t=e["proxyConfig"];const l=t&&t.ajax?t.ajax.query:null;if(t&&l){const i=t.response||t.props||{};e.proxyConfig=_xeUtils.default.merge({},t,{ajax:{query(e,...t){return Promise.resolve(l(e,...t)).then(e=>{var t=i.list,t=(t?_xeUtils.default.isFunction(t)?t({data:e,$table:null,$grid:null,$gantt:null}):_xeUtils.default.get(e,t):e)||[];return g(t||[]),e})}}})}return e}),B=(0,_vue.computed)(()=>{var e=h["modelValue"];const l=S["fullRowMaps"],i=F.value;return(_xeUtils.default.isArray(e)?e:[e]).map(e=>{var t=l[e];return t?t.item[i]:e}).join(", ")}),M=(0,_vue.computed)(()=>{var{height:e,width:t}=j.value,l={};return t&&(l.width=(0,_dom.toCssUnit)(t)),e&&(l.height=(0,_dom.toCssUnit)(e)),l}),D={},O={xID:t,props:h,context:e,reactData:S,getRefMaps:()=>k,getComputeMaps:()=>D};const R={},c=(["form-submit","form-reset","form-collapse","page-change"].forEach(t=>{R[(0,_vn.getOnName)(_xeUtils.default.camelCase(t))]=e=>{c(t,e,e.$event)}}),(e,t,l)=>{a(e,(0,_ui.createEvent)(l,{$tableSelect:O},t))});t={dispatchEvent:c};const K=e=>{const t=S["fullRowMaps"],l=[];return(_xeUtils.default.eqNull(e)?[]:_xeUtils.default.isArray(e)?e:[e]).forEach(e=>{e=t[e];e&&l.push(e.item)}),l},d=l=>{const i=h["multiple"];(0,_vue.nextTick)(()=>{var e,t=I.value;t&&(e=K(l)).length&&(i?t.setCheckboxRow(e,!0):t.setRadioRow(e[0]))})},p=e=>{var t=h["multiple"];const l=[];let i=!1,a=!1;e.forEach(e=>{i||"radio"!==e.type?a||"checkbox"!==e.type||(a=!0):i=!0,l.push(e)}),t?a||l.unshift({type:"checkbox",width:70}):i||l.unshift({type:"radio",width:70}),S.tableColumns=l},g=e=>{var t=h["options"];const o=s.value,n=v.value;var l=A.value["treeConfig"];const u={},r={};l||_xeUtils.default.arrayEach(e||t||[],(e,t,l)=>{let i=(e=>{e=e[s.value];return e?encodeURIComponent(e):""})(e);i=i||getRowUniqueId(),r[i]&&(0,_log.errLog)("vxe.error.repeatKey",[o,i]),r[i]=!0;var a=e[n];u[a]&&(0,_log.errLog)("vxe.error.repeatKey",[n,a]),u[a]={item:e,index:t,items:l,parent:null,nodes:[]}}),S.fullOptionList=e||t||[],S.fullRowMaps=u,d(h.modelValue)},_=()=>{const l=h["placement"],i=S["panelIndex"],a=E.value,o=w.value,n=U.value;var e=()=>{var e=(0,_dom.updatePanelPlacement)(a,o,{placement:l,teleportTo:n}),t=Object.assign(e.style,{zIndex:i});S.panelStyle=t,S.panelPlacement=e.placement};return e(),(0,_vue.nextTick)().then(e)},f=()=>{var e=h["loading"],t=P.value;e||t||(u.vpTimeout&&clearTimeout(u.vpTimeout),u.hpTimeout&&clearTimeout(u.hpTimeout),S.initialized||(S.initialized=!0),S.isActivated=!0,S.isAniVisible=!0,u.vpTimeout=setTimeout(()=>{S.visiblePanel=!0,d(h.modelValue),u.vpTimeout=void 0},10),(e=h.zIndex)?S.panelIndex=e:S.panelIndex<(0,_utils.getLastZIndex)()&&(S.panelIndex=(0,_utils.nextZIndex)()),_())},m=()=>{S.visiblePanel=!1,u.vpTimeout&&clearTimeout(u.vpTimeout),u.hpTimeout&&clearTimeout(u.hpTimeout),u.hpTimeout=setTimeout(()=>{S.isAniVisible=!1,u.hpTimeout=void 0},350)},b=(e,t,l)=>{var i;i=t,a("update:modelValue",i),t!==h.modelValue&&(c("change",{value:t,row:l,option:l},e),o)&&n&&o.triggerItemEvent(e,n.itemConfig.field,t)},Z=(e,t)=>{b(e,t,null),c("clear",{value:t},e)},W=(e,t)=>{Z(t,null),m()},X=e=>{var t=S["visiblePanel"];P.value||t&&(t=w.value,((0,_dom.getEventTargetNode)(e,t).flag?_:m)())},Y=e=>{var t,l,i=S["visiblePanel"];P.value||(t=E.value,l=w.value,S.isActivated=(0,_dom.getEventTargetNode)(e,t).flag||(0,_dom.getEventTargetNode)(e,l).flag,i&&!S.isActivated&&m())},G=()=>{var{visiblePanel:e,isActivated:t}=S;e&&m(),t&&(S.isActivated=!1),(e||t)&&(e=T.value)&&e.blur()},H=()=>{var e=S["visiblePanel"];e&&_()},J=e=>{P.value||S.visiblePanel||(S.triggerFocusPanel=!0,f(),setTimeout(()=>{S.triggerFocusPanel=!1},150)),c("focus",{},e)},Q=e=>{z(e),c("click",{},e)},ee=e=>{S.isActivated=!1,c("blur",{},e)},z=e=>{e=e.$event;e.preventDefault(),S.triggerFocusPanel?S.triggerFocusPanel=!1:(S.visiblePanel?m:f)()},te=e=>{var{$event:e,row:t}=e,l=t[v.value];b(e,l,t),m()},V=e=>{var{$grid:e,$event:t,row:l}=e;const i=v.value;e&&(e=e.getCheckboxRecords().map(e=>e[i]),b(t,e,l))},le=e=>{V(e)};Object.assign(O,t,{});return(0,_vue.watch)(()=>h.options,()=>{g()}),(0,_vue.watch)(()=>h.columns,e=>{p(e||[])}),(0,_vue.watch)(()=>h.modelValue,e=>{d(e)}),p(h.columns||[]),g(),(0,_vue.onMounted)(()=>{var e=h["gridConfig"];e&&e.proxyConfig&&(!1!==e.proxyConfig.autoLoad&&(S.initialized=!0),e.pagerConfig)&&!1!==e.pagerConfig.enabled&&(0,_log.warnLog)("vxe.error.notProp",["proxy-config & grid-config.pagerConfig"]),_ui.globalEvents.on(O,"mousewheel",X),_ui.globalEvents.on(O,"mousedown",Y),_ui.globalEvents.on(O,"blur",G),_ui.globalEvents.on(O,"resize",H)}),(0,_vue.onUnmounted)(()=>{_ui.globalEvents.off(O,"mousewheel"),_ui.globalEvents.off(O,"mousedown"),_ui.globalEvents.off(O,"blur"),_ui.globalEvents.off(O,"resize")}),(0,_vue.nextTick)(()=>{y||(0,_log.errLog)("vxe.error.reqComp",["vxe-grid"])}),(0,_vue.provide)("$xeTableSelect",O),O.renderVN=()=>{var{className:e,options:t,loading:l}=h,{initialized:i,isActivated:a,isAniVisible:o,visiblePanel:n,tableColumns:u}=S,r=L.value,s=P.value,v=B.value,c=U.value,d=N.value,p=j.value["className"],g=A.value,_=q.value,f=M.value,m=C.header,b=C.footer;const x=C.prefix;return d?(0,_vue.h)("div",{ref:E,class:["vxe-table-select--readonly",e]},[(0,_vue.h)("span",{class:"vxe-table-select-label"},v)]):(0,_vue.h)("div",{ref:E,class:["vxe-table-select",e?_xeUtils.default.isFunction(e)?e({$tableSelect:O}):e:"",{["size--"+r]:r,"is--visible":n,"is--disabled":s,"is--loading":l,"is--active":a}]},[(0,_vue.h)(_input.default,{ref:T,clearable:h.clearable,placeholder:l?(0,_ui.getI18n)("vxe.select.loadingText"):h.placeholder,readonly:!0,disabled:s,type:"text",prefixIcon:h.prefixIcon,suffixIcon:l?(0,_ui.getIcon)().TABLE_SELECT_LOADED:n?(0,_ui.getIcon)().TABLE_SELECT_OPEN:(0,_ui.getIcon)().TABLE_SELECT_CLOSE,modelValue:l?"":v,onClear:W,onClick:Q,onFocus:J,onBlur:ee,onSuffixClick:z},x?{prefix:()=>x({})}:{}),(0,_vue.h)(_vue.Teleport,{to:"body",disabled:!c||!i},[(0,_vue.h)("div",{ref:w,class:["vxe-table--ignore-clear vxe-table-select--panel",p?_xeUtils.default.isFunction(p)?p({$tableSelect:O}):p:"",{["size--"+r]:r,"is--transfer":c,"ani--leave":!l&&o,"ani--enter":!l&&n}],placement:S.panelPlacement,style:S.panelStyle},i?[(0,_vue.h)("div",{class:"vxe-table-select--panel-wrapper"},[m?(0,_vue.h)("div",{class:"vxe-table-select--panel-header"},m({})):(0,_ui.renderEmptyElement)(O),(0,_vue.h)("div",{class:"vxe-table-select--panel-body"},[(0,_vue.h)("div",{ref:$,class:"vxe-table-select-grid--wrapper",style:f},[y?(0,_vue.h)(y,Object.assign(Object.assign(Object.assign({},g),R),{class:"vxe-table-select--grid",ref:I,rowConfig:_,data:t,columns:u,height:"100%",autoResize:!0,onRadioChange:te,onCheckboxChange:V,onCheckboxAll:le}),Object.assign({},C,{header:void 0,footer:void 0,prefixSlot:void 0})):(0,_ui.renderEmptyElement)(O)])]),b?(0,_vue.h)("div",{class:"vxe-table-select--panel-footer"},b({})):(0,_ui.renderEmptyElement)(O)])]:[])])])},O},render(){return this.renderVN()}});
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0,exports.getRowUniqueId=getRowUniqueId;var _vue=require("vue"),_comp=require("../../ui/src/comp"),_xeUtils=_interopRequireDefault(require("xe-utils")),_ui=require("../../ui"),_dom=require("../../ui/src/dom"),_vn=require("../../ui/src/vn"),_utils=require("../../ui/src/utils"),_log=require("../../ui/src/log"),_input=_interopRequireDefault(require("../../input/src/input"));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function getRowUniqueId(){return _xeUtils.default.uniqueId("row_")}var _default=exports.default=(0,_comp.defineVxeComponent)({name:"VxeTableSelect",props:{modelValue:[String,Number,Array],clearable:Boolean,placeholder:{type:String,default:()=>_xeUtils.default.eqNull((0,_ui.getConfig)().tableSelect.placeholder)?(0,_ui.getI18n)("vxe.base.pleaseSelect"):(0,_ui.getConfig)().tableSelect.placeholder},readonly:{type:Boolean,default:null},loading:Boolean,disabled:{type:Boolean,default:null},multiple:Boolean,className:[String,Function],prefixIcon:String,placement:String,columns:Array,options:Array,optionProps:Object,zIndex:Number,size:{type:String,default:()=>(0,_ui.getConfig)().tableSelect.size||(0,_ui.getConfig)().size},popupConfig:Object,gridConfig:Object,transfer:{type:Boolean,default:null}},emits:["update:modelValue","change","clear","blur","focus","click","form-submit","form-reset","form-collapse","page-change"],setup(h,e){const{emit:a,slots:C}=e,y=_ui.VxeUI.getComponent("vxe-grid"),l=(0,_vue.inject)("$xeModal",null),i=(0,_vue.inject)("$xeDrawer",null),V=(0,_vue.inject)("$xeTable",null),u=(0,_vue.inject)("$xeForm",null),n=(0,_vue.inject)("xeFormItemInfo",null);var t=_xeUtils.default.uniqueId();const $=(0,_ui.useSize)(h)["computeSize"],E=(0,_vue.ref)(),T=(0,_vue.ref)(),L=(0,_vue.ref)(),I=(0,_vue.ref)(),w=(0,_vue.ref)(),S=(0,_vue.reactive)({initialized:!1,tableColumns:[],fullOptionList:[],fullRowMaps:{},panelIndex:0,panelStyle:{},panelPlacement:null,triggerFocusPanel:!1,visiblePanel:!1,isAniVisible:!1,isActivated:!1}),o={},k={refElem:E},N=(0,_vue.computed)(()=>{var e=h["readonly"];return null===e?!!u&&u.props.readonly:e}),P=(0,_vue.computed)(()=>{var e=h["disabled"];return null===e?!!u&&u.props.disabled:e}),q=(0,_vue.computed)(()=>{var e=h["transfer"];if(null===e){var t=(0,_ui.getConfig)().select.transfer;if(_xeUtils.default.isBoolean(t))return t;if(V||l||i||u)return!0}return e}),r=(0,_vue.computed)(()=>h.optionProps||{}),U=(0,_vue.computed)(()=>{var e=c.value;return Object.assign({},e.rowConfig,{isCurrent:!0})}),s=(0,_vue.computed)(()=>{return U.value.keyField||"_X_ROW_KEY"}),F=(0,_vue.computed)(()=>{return r.value.label||"label"}),v=(0,_vue.computed)(()=>{return r.value.value||"value"}),j=(0,_vue.computed)(()=>Object.assign({},(0,_ui.getConfig)().tableSelect.popupConfig,h.popupConfig)),c=(0,_vue.computed)(()=>Object.assign({},(0,_ui.getConfig)().tableSelect.gridConfig,h.gridConfig,{data:void 0,columns:void 0})),B=(0,_vue.computed)(()=>{var e=c.value,t=e["proxyConfig"];if(t){var l=t.ajax;if(l&&l.query){var i=_xeUtils.default.clone(t,!0);const a=l.query;if(a){const u=t.response||t.props||{};Object.assign(i.ajax,{query(e,...t){return Promise.resolve(a(e,...t)).then(e=>{var t=u.list,t=(t?_xeUtils.default.isFunction(t)?t({data:e,$table:null,$grid:null,$gantt:null}):_xeUtils.default.get(e,t):e)||[];return _(t||[]),e})}})}return Object.assign({},e,{proxyConfig:i})}}return e}),M=(0,_vue.computed)(()=>{var e=h["modelValue"];const l=S["fullRowMaps"],i=F.value;return(_xeUtils.default.isArray(e)?e:[e]).map(e=>{var t=l[e];return t?t.item[i]:e}).join(", ")}),D=(0,_vue.computed)(()=>{var{height:e,width:t}=j.value,l={};return t&&(l.width=(0,_dom.toCssUnit)(t)),e&&(l.height=(0,_dom.toCssUnit)(e)),l}),K={},A={xID:t,props:h,context:e,reactData:S,getRefMaps:()=>k,getComputeMaps:()=>K};const O={},d=(["form-submit","form-reset","form-collapse","page-change"].forEach(t=>{O[(0,_vn.getOnName)(_xeUtils.default.camelCase(t))]=e=>{d(t,e,e.$event)}}),(e,t,l)=>{a(e,(0,_ui.createEvent)(l,{$tableSelect:A},t))});t={dispatchEvent:d};const Z=e=>{const t=S["fullRowMaps"],l=[];return(_xeUtils.default.eqNull(e)?[]:_xeUtils.default.isArray(e)?e:[e]).forEach(e=>{e=t[e];e&&l.push(e.item)}),l},p=l=>{const i=h["multiple"];(0,_vue.nextTick)(()=>{var e,t=w.value;t&&(e=Z(l)).length&&(i?t.setCheckboxRow(e,!0):t.setRadioRow(e[0]))})},g=e=>{var t=h["multiple"];const l=[];let i=!1,a=!1;e.forEach(e=>{i||"radio"!==e.type?a||"checkbox"!==e.type||(a=!0):i=!0,l.push(e)}),t?a||l.unshift({type:"checkbox",width:70}):i||l.unshift({type:"radio",width:70}),S.tableColumns=l},_=e=>{var t=h["options"];const u=s.value,n=v.value;var l=c.value["treeConfig"];const o={},r={};l||_xeUtils.default.arrayEach(e||t||[],(e,t,l)=>{let i=(e=>{e=e[s.value];return e?encodeURIComponent(e):""})(e);i=i||getRowUniqueId(),r[i]&&(0,_log.errLog)("vxe.error.repeatKey",[u,i]),r[i]=!0;var a=e[n];o[a]&&(0,_log.errLog)("vxe.error.repeatKey",[n,a]),o[a]={item:e,index:t,items:l,parent:null,nodes:[]}}),S.fullOptionList=e||t||[],S.fullRowMaps=o,p(h.modelValue)},f=()=>{const l=h["placement"],i=S["panelIndex"],a=E.value,u=I.value,n=q.value;var e=()=>{var e=(0,_dom.updatePanelPlacement)(a,u,{placement:l,teleportTo:n}),t=Object.assign(e.style,{zIndex:i});S.panelStyle=t,S.panelPlacement=e.placement};return e(),(0,_vue.nextTick)().then(e)},m=()=>{var e=h["loading"],t=P.value;e||t||(o.vpTimeout&&clearTimeout(o.vpTimeout),o.hpTimeout&&clearTimeout(o.hpTimeout),S.initialized||(S.initialized=!0),S.isActivated=!0,S.isAniVisible=!0,o.vpTimeout=setTimeout(()=>{S.visiblePanel=!0,p(h.modelValue),o.vpTimeout=void 0},10),(e=h.zIndex)?S.panelIndex=e:S.panelIndex<(0,_utils.getLastZIndex)()&&(S.panelIndex=(0,_utils.nextZIndex)()),f())},b=()=>{S.visiblePanel=!1,o.vpTimeout&&clearTimeout(o.vpTimeout),o.hpTimeout&&clearTimeout(o.hpTimeout),o.hpTimeout=setTimeout(()=>{S.isAniVisible=!1,o.hpTimeout=void 0},350)},x=(e,t,l)=>{var i;i=t,a("update:modelValue",i),t!==h.modelValue&&(d("change",{value:t,row:l,option:l},e),u)&&n&&u.triggerItemEvent(e,n.itemConfig.field,t)},W=(e,t)=>{x(e,t,null),d("clear",{value:t},e)},X=(e,t)=>{W(t,null),b()},Y=e=>{var t=S["visiblePanel"];P.value||t&&(t=I.value,((0,_dom.getEventTargetNode)(e,t).flag?f:b)())},G=e=>{var t,l,i=S["visiblePanel"];P.value||(t=E.value,l=I.value,S.isActivated=(0,_dom.getEventTargetNode)(e,t).flag||(0,_dom.getEventTargetNode)(e,l).flag,i&&!S.isActivated&&b())},H=()=>{var{visiblePanel:e,isActivated:t}=S;e&&b(),t&&(S.isActivated=!1),(e||t)&&(e=T.value)&&e.blur()},J=()=>{var e=S["visiblePanel"];e&&f()},Q=e=>{P.value||S.visiblePanel||(S.triggerFocusPanel=!0,m(),setTimeout(()=>{S.triggerFocusPanel=!1},150)),d("focus",{},e)},ee=e=>{R(e),d("click",{},e)},te=e=>{S.isActivated=!1,d("blur",{},e)},R=e=>{e=e.$event;e.preventDefault(),S.triggerFocusPanel?S.triggerFocusPanel=!1:(S.visiblePanel?b:m)()},le=e=>{var{$event:e,row:t}=e,l=t[v.value];x(e,l,t),b()},z=e=>{var{$grid:e,$event:t,row:l}=e;const i=v.value;e&&(e=e.getCheckboxRecords().map(e=>e[i]),x(t,e,l))},ie=e=>{z(e)};Object.assign(A,t,{});return(0,_vue.watch)(()=>h.options,()=>{_()}),(0,_vue.watch)(()=>h.columns,e=>{g(e||[])}),(0,_vue.watch)(()=>h.modelValue,e=>{p(e)}),g(h.columns||[]),_(),(0,_vue.onMounted)(()=>{var e=h["gridConfig"];e&&e.proxyConfig&&!1!==e.proxyConfig.autoLoad&&(S.initialized=!0),_ui.globalEvents.on(A,"mousewheel",Y),_ui.globalEvents.on(A,"mousedown",G),_ui.globalEvents.on(A,"blur",H),_ui.globalEvents.on(A,"resize",J)}),(0,_vue.onUnmounted)(()=>{_ui.globalEvents.off(A,"mousewheel"),_ui.globalEvents.off(A,"mousedown"),_ui.globalEvents.off(A,"blur"),_ui.globalEvents.off(A,"resize")}),(0,_vue.nextTick)(()=>{y||(0,_log.errLog)("vxe.error.reqComp",["vxe-grid"])}),(0,_vue.provide)("$xeTableSelect",A),A.renderVN=()=>{var{className:e,options:t,loading:l}=h,{initialized:i,isActivated:a,isAniVisible:u,visiblePanel:n,tableColumns:o}=S,r=$.value,s=P.value,v=M.value,c=q.value,d=N.value,p=j.value["className"],g=B.value,_=U.value,f=D.value,m=C.header,b=C.footer;const x=C.prefix;return d?(0,_vue.h)("div",{ref:E,class:["vxe-table-select--readonly",e]},[(0,_vue.h)("span",{class:"vxe-table-select-label"},v)]):(0,_vue.h)("div",{ref:E,class:["vxe-table-select",e?_xeUtils.default.isFunction(e)?e({$tableSelect:A}):e:"",{["size--"+r]:r,"is--visible":n,"is--disabled":s,"is--loading":l,"is--active":a}]},[(0,_vue.h)(_input.default,{ref:T,clearable:h.clearable,placeholder:l?(0,_ui.getI18n)("vxe.select.loadingText"):h.placeholder,readonly:!0,disabled:s,type:"text",prefixIcon:h.prefixIcon,suffixIcon:l?(0,_ui.getIcon)().TABLE_SELECT_LOADED:n?(0,_ui.getIcon)().TABLE_SELECT_OPEN:(0,_ui.getIcon)().TABLE_SELECT_CLOSE,modelValue:l?"":v,onClear:X,onClick:ee,onFocus:Q,onBlur:te,onSuffixClick:R},x?{prefix:()=>x({})}:{}),(0,_vue.h)(_vue.Teleport,{to:"body",disabled:!c||!i},[(0,_vue.h)("div",{ref:I,class:["vxe-table--ignore-clear vxe-table-select--panel",p?_xeUtils.default.isFunction(p)?p({$tableSelect:A}):p:"",{["size--"+r]:r,"is--transfer":c,"ani--leave":!l&&u,"ani--enter":!l&&n}],placement:S.panelPlacement,style:S.panelStyle},i?[(0,_vue.h)("div",{class:"vxe-table-select--panel-wrapper"},[m?(0,_vue.h)("div",{class:"vxe-table-select--panel-header"},m({})):(0,_ui.renderEmptyElement)(A),(0,_vue.h)("div",{class:"vxe-table-select--panel-body"},[(0,_vue.h)("div",{ref:L,class:"vxe-table-select-grid--wrapper",style:f},[y?(0,_vue.h)(y,Object.assign(Object.assign(Object.assign({},g),O),{class:"vxe-table-select--grid",ref:w,rowConfig:_,data:t,columns:o,height:"100%",autoResize:!0,onRadioChange:le,onCheckboxChange:z,onCheckboxAll:ie}),Object.assign({},C,{header:void 0,footer:void 0,prefixSlot:void 0})):(0,_ui.renderEmptyElement)(A)])]),b?(0,_vue.h)("div",{class:"vxe-table-select--panel-footer"},b({})):(0,_ui.renderEmptyElement)(A)])]:[])])])},A},render(){return this.renderVN()}});
package/lib/ui/index.js CHANGED
@@ -26,7 +26,7 @@ Object.keys(_core).forEach(function (key) {
26
26
  });
27
27
  var _dynamics = require("../dynamics");
28
28
  var _log = require("./src/log");
29
- const version = exports.version = "4.9.24";
29
+ const version = exports.version = "4.9.26";
30
30
  _core.VxeUI.uiVersion = version;
31
31
  _core.VxeUI.dynamicApp = _dynamics.dynamicApp;
32
32
  function config(options) {
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _exportNames={version:!0,config:!0,setup:!0},_core=(exports.config=config,exports.default=void 0,exports.setup=setup,exports.version=void 0,require("@vxe-ui/core")),_dynamics=(Object.keys(_core).forEach(function(e){"default"===e||"__esModule"===e||Object.prototype.hasOwnProperty.call(_exportNames,e)||e in exports&&exports[e]===_core[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _core[e]}})}),require("../dynamics")),_log=require("./src/log");const version=exports.version="4.9.24";function config(e){return(0,_log.warnLog)("vxe.error.delFunc",["config","setConfig"]),(0,_core.setConfig)(e)}function setup(e){return(0,_log.warnLog)("vxe.error.delFunc",["setup","setConfig"]),(0,_core.setConfig)(e)}_core.VxeUI.uiVersion=version,_core.VxeUI.dynamicApp=_dynamics.dynamicApp,_core.VxeUI.config=config,_core.VxeUI.setup=setup,(0,_core.setConfig)({alert:{},anchor:{},anchorLink:{},avatar:{},badge:{},breadcrumb:{separator:"/"},breadcrumbItem:{},button:{trigger:"hover",prefixTooltip:{enterable:!0},suffixTooltip:{enterable:!0}},buttonGroup:{},calendar:{minDate:new Date(1900,0,1),maxDate:new Date(2100,0,1),startDay:1,selectDay:1},card:{border:!0,padding:!0},carousel:{height:200,loop:!0,interval:5e3},carouselItem:{},checkbox:{},checkboxButton:{},checkboxGroup:{},col:{},collapse:{padding:!0,expandConfig:{showIcon:!0}},collapsePane:{},countdown:{},colorPicker:{type:"rgb",clearable:!0,showAlpha:!0,clickToCopy:!0,showColorExtractor:!0,showQuick:!0},datePanel:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1},datePicker:{shortcutConfig:{align:"left",mode:"text",autoClose:!0},startDay:1,selectDay:1,autoClose:!0,showClearButton:null,showConfirmButton:null},dateRangePicker:{shortcutConfig:{align:"left",mode:"text",autoClose:!0},startDay:1,selectDay:1,separator:" ~ ",autoClose:!0,showClearButton:null,showConfirmButton:null},drawer:{position:"right",showHeader:!0,lockView:!0,mask:!0,showTitleOverflow:!0,showClose:!0,padding:!0,cancelClosable:!0,confirmClosable:!0},empty:{},form:{validConfig:{showMessage:!0,autoPos:!0,theme:"beautify"},tooltipConfig:{enterable:!0},titleAsterisk:!0,titleOverflow:!1,padding:!0},formDesign:{height:400,showHeader:!0,showPc:!0},formGather:{},formGroup:{},formItem:{},formView:{},icon:{},iconPicker:{icons:["home","company","comment","setting","send","envelope","envelope-open","bell","search","print","pc","goods","chart-line","edit","delete","save","folder","microphone","flag","link","location","sunny","rmb","usd","user","add-user","add-users","star","unlock","time","text","feedback","calendar","association-form","cloud-download","cloud-upload","file","subtable","chart-bar-x","chart-bar-y","chart-line","chart-pie","chart-radar"]},image:{showPreview:!0,showPrintButton:!0,maskClosable:!0},imageGroup:{showPreview:!0,showPrintButton:!0},imagePreview:{showPrintButton:!0},input:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1,digits:2,controls:!0},layoutAside:{},layoutBody:{},layoutContainer:{},layoutFooter:{},layoutHeader:{},link:{underline:!0},listDesign:{height:400,showPc:!0},listView:{},list:{virtualYConfig:{enabled:!0,gt:100}},loading:{showIcon:!0,showText:!0},menu:{},modal:{top:16,showHeader:!0,minWidth:340,minHeight:140,lockView:!0,mask:!0,duration:3e3,marginSize:0,dblclickZoom:!0,showTitleOverflow:!0,animat:!0,showClose:!0,padding:!0,draggable:!0,showConfirmButton:null,cancelClosable:!0,confirmClosable:!0,zoomConfig:{minimizeMaxSize:10,minimizeVerticalOffset:{top:-24,left:0},minimizeHorizontalOffset:{top:0,left:32}},storageKey:"VXE_MODAL_POSITION"},noticeBar:{},numberInput:{digits:2,autoFill:!0,controlConfig:{enabled:!0,layout:"right",showButton:!0,isWheel:!0,isArrow:!0}},optgroup:{},option:{},pager:{pageSizePlacement:"top"},print:{pageStyle:{}},passwordInput:{controls:!0},printPageBreak:{},pulldown:{destroyOnClose:!0},radio:{strict:!0},radioButton:{strict:!0},radioGroup:{strict:!0},rate:{},result:{},row:{},select:{multiCharOverflow:8,remoteConfig:{enabled:!0,autoLoad:!0},virtualYConfig:{enabled:!0,gt:50,oSize:2}},split:{resize:!0,itemConfig:{minWidth:40,minHeight:40},resizeConfig:{showTip:!0}},splitPane:{},slider:{max:100,min:0},steps:{},switch:{},tabPane:{},tableSelect:{gridConfig:{showOverflow:!0,showHeaderOverflow:!0,showFooterOverflow:!0,rowConfig:{isHover:!0},virtualXConfig:{enabled:!0,gt:0},virtualYConfig:{enabled:!0,gt:0}}},tabs:{},tag:{},textEllipsis:{underline:!0},text:{copyConfig:{showMessage:!0}},textarea:{resize:"none"},tip:{},tooltip:{trigger:"hover",theme:"dark",enterDelay:500,leaveDelay:300,isArrow:!0},tree:{indent:20,minHeight:60,radioConfig:{strict:!0},virtualYConfig:{enabled:!0,gt:50,oSize:2}},treeSelect:{autoClose:!0,virtualYConfig:{enabled:!0,gt:0,oSize:2},treeConfig:{maxHeight:300,radioConfig:{},checkboxConfig:{},filterConfig:{autoExpandAll:!0}}},upload:{mode:"all",imageTypes:["jpg","jpeg","png","gif"],showList:!0,showUploadButton:!0,showButtonText:!0,showRemoveButton:!0,showButtonIcon:!0,showPreview:!0,dragToUpload:!0,showLimitSize:!0,showLimitCount:!0,autoSubmit:!0,maxSimultaneousUploads:5},watermark:{rotate:-30,gap:[100,100]},table:{},colgroup:{},column:{},toolbar:{},grid:{},gantt:{}});const iconPrefix="vxe-icon-";(0,_core.setIcon)({LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",BUTTON_DROPDOWN:iconPrefix+"arrow-down",BUTTON_LOADING:iconPrefix+"spinner roll",BUTTON_TOOLTIP_ICON:iconPrefix+"question-circle-fill",MENU_ITEM_EXPAND_OPEN:iconPrefix+"arrow-down rotate180",MENU_ITEM_EXPAND_CLOSE:iconPrefix+"arrow-down",SELECT_LOADED:iconPrefix+"spinner roll",SELECT_OPEN:iconPrefix+"caret-down rotate180",SELECT_CLOSE:iconPrefix+"caret-down",SELECT_ADD_OPTION:iconPrefix+"add",ICON_PICKER_OPEN:iconPrefix+"caret-down rotate180",ICON_PICKER_CLOSE:iconPrefix+"caret-down",PAGER_HOME:iconPrefix+"home-page",PAGER_END:iconPrefix+"end-page",PAGER_JUMP_PREV:iconPrefix+"arrow-double-left",PAGER_JUMP_NEXT:iconPrefix+"arrow-double-right",PAGER_PREV_PAGE:iconPrefix+"arrow-left",PAGER_NEXT_PAGE:iconPrefix+"arrow-right",PAGER_JUMP_MORE:iconPrefix+"ellipsis-h",RADIO_CHECKED:iconPrefix+"radio-checked-fill",RADIO_UNCHECKED:iconPrefix+"radio-unchecked",RADIO_DISABLED_UNCHECKED:iconPrefix+"radio-unchecked-fill",CHECKBOX_INDETERMINATE:iconPrefix+"checkbox-indeterminate-fill",CHECKBOX_CHECKED:iconPrefix+"checkbox-checked-fill",CHECKBOX_UNCHECKED:iconPrefix+"checkbox-unchecked",CHECKBOX_DISABLED_UNCHECKED:iconPrefix+"checkbox-unchecked-fill",INPUT_CLEAR:iconPrefix+"error-circle-fill",INPUT_SEARCH:iconPrefix+"search",INPUT_PLUS_NUM:iconPrefix+"caret-up",INPUT_MINUS_NUM:iconPrefix+"caret-down",NUMBER_INPUT_MINUS_NUM:iconPrefix+"minus",NUMBER_INPUT_PLUS_NUM:iconPrefix+"add",DATE_PICKER_DATE:iconPrefix+"calendar",PASSWORD_INPUT_SHOW_PWD:iconPrefix+"eye-fill-close",PASSWORD_INPUT_HIDE_PWD:iconPrefix+"eye-fill",MODAL_ZOOM_MIN:iconPrefix+"minus",MODAL_ZOOM_REVERT:iconPrefix+"recover",MODAL_ZOOM_IN:iconPrefix+"square",MODAL_ZOOM_OUT:iconPrefix+"maximize",MODAL_CLOSE:iconPrefix+"close",MODAL_INFO:iconPrefix+"info-circle-fill",MODAL_SUCCESS:iconPrefix+"success-circle-fill",MODAL_WARNING:iconPrefix+"warning-circle-fill",MODAL_ERROR:iconPrefix+"error-circle-fill",MODAL_QUESTION:iconPrefix+"question-circle-fill",MODAL_LOADING:iconPrefix+"spinner roll",DRAWER_CLOSE:iconPrefix+"close",FORM_PREFIX:iconPrefix+"question-circle-fill",FORM_SUFFIX:iconPrefix+"question-circle-fill",FORM_FOLDING:iconPrefix+"arrow-up rotate180",FORM_UNFOLDING:iconPrefix+"arrow-up",FORM_DESIGN_STYLE_SETTING:iconPrefix+"layout",FORM_DESIGN_PROPS_PC:iconPrefix+"pc",FORM_DESIGN_PROPS_MOBILE:iconPrefix+"mobile",FORM_DESIGN_PROPS_ADD:iconPrefix+"add",FORM_DESIGN_PROPS_EDIT:iconPrefix+"edit",FORM_DESIGN_WIDGET_ADD:iconPrefix+"square-plus-fill",FORM_DESIGN_WIDGET_COPY:iconPrefix+"copy",FORM_DESIGN_WIDGET_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_SWAP_LR:iconPrefix+"swap",FORM_DESIGN_WIDGET_OPTION_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_OPTION_EXPAND_OPEN:iconPrefix+"square-plus",FORM_DESIGN_WIDGET_OPTION_EXPAND_CLOSE:iconPrefix+"square-minus",LIST_DESIGN_FIELD_SETTING:iconPrefix+"custom-column",LIST_DESIGN_LIST_SETTING:iconPrefix+"menu",LIST_DESIGN_LIST_SETTING_SEARCH_DELETE:iconPrefix+"delete",LIST_DESIGN_LIST_SETTING_ACTIVE_DELETE:iconPrefix+"delete",UPLOAD_FILE_ERROR:iconPrefix+"warning-circle-fill",UPLOAD_FILE_ADD:iconPrefix+"upload",UPLOAD_FILE_REMOVE:iconPrefix+"delete",UPLOAD_FILE_DOWNLOAD:iconPrefix+"download",UPLOAD_IMAGE_UPLOAD:iconPrefix+"upload",UPLOAD_IMAGE_RE_UPLOAD:iconPrefix+"repeat",UPLOAD_IMAGE_ADD:iconPrefix+"add",UPLOAD_IMAGE_REMOVE:iconPrefix+"close",UPLOAD_LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",UPLOAD_FILE_TYPE_DEFAULT:iconPrefix+"file",UPLOAD_FILE_TYPE_XLSX:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_XLS:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_PDF:iconPrefix+"file-pdf",UPLOAD_FILE_TYPE_PNG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_GIF:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPEG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_MD:iconPrefix+"file-markdown",UPLOAD_FILE_TYPE_PPD:iconPrefix+"file-ppt",UPLOAD_FILE_TYPE_DOCX:iconPrefix+"file-word",UPLOAD_FILE_TYPE_DOC:iconPrefix+"file-word",UPLOAD_FILE_TYPE_ZIP:iconPrefix+"file-zip",UPLOAD_FILE_TYPE_TXT:iconPrefix+"file-txt",IMAGE_PREVIEW_CLOSE:iconPrefix+"close",IMAGE_PREVIEW_PREVIOUS:iconPrefix+"arrow-left",IMAGE_PREVIEW_NEXT:iconPrefix+"arrow-right",IMAGE_PREVIEW_PCT_FULL:iconPrefix+"pct-full",IMAGE_PREVIEW_PCT_1_1:iconPrefix+"pct-1-1",IMAGE_PREVIEW_ZOOM_OUT:iconPrefix+"search-zoom-out",IMAGE_PREVIEW_ZOOM_IN:iconPrefix+"search-zoom-in",IMAGE_PREVIEW_ROTATE_LEFT:iconPrefix+"rotate-left",IMAGE_PREVIEW_ROTATE_RIGHT:iconPrefix+"rotate-right",IMAGE_PREVIEW_PRINT:iconPrefix+"print",IMAGE_PREVIEW_DOWNLOAD:iconPrefix+"download",ALERT_CLOSE:iconPrefix+"close",ALERT_INFO:iconPrefix+"info-circle-fill",ALERT_SUCCESS:iconPrefix+"success-circle-fill",ALERT_WARNING:iconPrefix+"warning-circle-fill",ALERT_ERROR:iconPrefix+"error-circle-fill",TREE_NODE_OPEN:iconPrefix+"caret-right rotate90",TREE_NODE_CLOSE:iconPrefix+"caret-right",TREE_NODE_LOADED:iconPrefix+"spinner roll",TREE_SELECT_LOADED:iconPrefix+"spinner roll",TREE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TREE_SELECT_CLOSE:iconPrefix+"caret-down",TABLE_SELECT_LOADED:iconPrefix+"spinner roll",TABLE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TABLE_SELECT_CLOSE:iconPrefix+"caret-down",TABS_TAB_BUTTON_TOP:iconPrefix+"arrow-up",TABS_TAB_BUTTON_BOTTOM:iconPrefix+"arrow-down",TABS_TAB_BUTTON_LEFT:iconPrefix+"arrow-left",TABS_TAB_BUTTON_RIGHT:iconPrefix+"arrow-right",TABS_TAB_CLOSE:iconPrefix+"close",TABS_TAB_REFRESH:iconPrefix+"refresh",TABS_TAB_REFRESH_LOADING:iconPrefix+"refresh roll",TEXT_COPY:iconPrefix+"copy",TEXT_LOADING:iconPrefix+"spinner roll",CAROUSEL_HORIZONTAL_PREVIOUS:iconPrefix+"arrow-left",CAROUSEL_HORIZONTAL_NEXT:iconPrefix+"arrow-right",CAROUSEL_VERTICAL_PREVIOUS:iconPrefix+"arrow-up",CAROUSEL_VERTICAL_NEXT:iconPrefix+"arrow-down",COLLAPSE_OPEN:iconPrefix+"arrow-right rotate90",COLLAPSE_CLOSE:iconPrefix+"arrow-right",EMPTY_DEFAULT:iconPrefix+"empty",RESULT_INFO:iconPrefix+"info-circle-fill",RESULT_SUCCESS:iconPrefix+"success-circle-fill",RESULT_WARNING:iconPrefix+"warning-circle-fill",RESULT_ERROR:iconPrefix+"error-circle-fill",RESULT_QUESTION:iconPrefix+"question-circle-fill",RESULT_LOADING:iconPrefix+"spinner roll",RATE_CHECKED:iconPrefix+"star-fill",RATE_UNCHECKED:iconPrefix+"star",COLOR_PICKER_COLOR_COPY:iconPrefix+"copy",COLOR_PICKER_EYE_DROPPER:iconPrefix+"dropper",COLOR_PICKER_TPTY_OPEN:iconPrefix+"arrow-down rotate180",COLOR_PICKER_TPTY_CLOSE:iconPrefix+"arrow-down",SPLIT_TOP_ACTION:iconPrefix+"arrow-up",SPLIT_BOTTOM_ACTION:iconPrefix+"arrow-down",SPLIT_LEFT_ACTION:iconPrefix+"arrow-left",SPLIT_RIGHT_ACTION:iconPrefix+"arrow-right"});var _default=exports.default=_core.VxeUI;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _exportNames={version:!0,config:!0,setup:!0},_core=(exports.config=config,exports.default=void 0,exports.setup=setup,exports.version=void 0,require("@vxe-ui/core")),_dynamics=(Object.keys(_core).forEach(function(e){"default"===e||"__esModule"===e||Object.prototype.hasOwnProperty.call(_exportNames,e)||e in exports&&exports[e]===_core[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _core[e]}})}),require("../dynamics")),_log=require("./src/log");const version=exports.version="4.9.26";function config(e){return(0,_log.warnLog)("vxe.error.delFunc",["config","setConfig"]),(0,_core.setConfig)(e)}function setup(e){return(0,_log.warnLog)("vxe.error.delFunc",["setup","setConfig"]),(0,_core.setConfig)(e)}_core.VxeUI.uiVersion=version,_core.VxeUI.dynamicApp=_dynamics.dynamicApp,_core.VxeUI.config=config,_core.VxeUI.setup=setup,(0,_core.setConfig)({alert:{},anchor:{},anchorLink:{},avatar:{},badge:{},breadcrumb:{separator:"/"},breadcrumbItem:{},button:{trigger:"hover",prefixTooltip:{enterable:!0},suffixTooltip:{enterable:!0}},buttonGroup:{},calendar:{minDate:new Date(1900,0,1),maxDate:new Date(2100,0,1),startDay:1,selectDay:1},card:{border:!0,padding:!0},carousel:{height:200,loop:!0,interval:5e3},carouselItem:{},checkbox:{},checkboxButton:{},checkboxGroup:{},col:{},collapse:{padding:!0,expandConfig:{showIcon:!0}},collapsePane:{},countdown:{},colorPicker:{type:"rgb",clearable:!0,showAlpha:!0,clickToCopy:!0,showColorExtractor:!0,showQuick:!0},datePanel:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1},datePicker:{shortcutConfig:{align:"left",mode:"text",autoClose:!0},startDay:1,selectDay:1,autoClose:!0,showClearButton:null,showConfirmButton:null},dateRangePicker:{shortcutConfig:{align:"left",mode:"text",autoClose:!0},startDay:1,selectDay:1,separator:" ~ ",autoClose:!0,showClearButton:null,showConfirmButton:null},drawer:{position:"right",showHeader:!0,lockView:!0,mask:!0,showTitleOverflow:!0,showClose:!0,padding:!0,cancelClosable:!0,confirmClosable:!0},empty:{},form:{validConfig:{showMessage:!0,autoPos:!0,theme:"beautify"},tooltipConfig:{enterable:!0},titleAsterisk:!0,titleOverflow:!1,padding:!0},formDesign:{height:400,showHeader:!0,showPc:!0},formGather:{},formGroup:{},formItem:{},formView:{},icon:{},iconPicker:{icons:["home","company","comment","setting","send","envelope","envelope-open","bell","search","print","pc","goods","chart-line","edit","delete","save","folder","microphone","flag","link","location","sunny","rmb","usd","user","add-user","add-users","star","unlock","time","text","feedback","calendar","association-form","cloud-download","cloud-upload","file","subtable","chart-bar-x","chart-bar-y","chart-line","chart-pie","chart-radar"]},image:{showPreview:!0,showPrintButton:!0,maskClosable:!0},imageGroup:{showPreview:!0,showPrintButton:!0},imagePreview:{showPrintButton:!0},input:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1,digits:2,controls:!0},layoutAside:{},layoutBody:{},layoutContainer:{},layoutFooter:{},layoutHeader:{},link:{underline:!0},listDesign:{height:400,showPc:!0},listView:{},list:{virtualYConfig:{enabled:!0,gt:100}},loading:{showIcon:!0,showText:!0},menu:{},modal:{top:16,showHeader:!0,minWidth:340,minHeight:140,lockView:!0,mask:!0,duration:3e3,marginSize:0,dblclickZoom:!0,showTitleOverflow:!0,animat:!0,showClose:!0,padding:!0,draggable:!0,showConfirmButton:null,cancelClosable:!0,confirmClosable:!0,zoomConfig:{minimizeMaxSize:10,minimizeVerticalOffset:{top:-24,left:0},minimizeHorizontalOffset:{top:0,left:32}},storageKey:"VXE_MODAL_POSITION"},noticeBar:{},numberInput:{digits:2,autoFill:!0,controlConfig:{enabled:!0,layout:"right",showButton:!0,isWheel:!0,isArrow:!0}},optgroup:{},option:{},pager:{pageSizePlacement:"top"},print:{pageStyle:{}},passwordInput:{controls:!0},printPageBreak:{},pulldown:{destroyOnClose:!0},radio:{strict:!0},radioButton:{strict:!0},radioGroup:{strict:!0},rate:{},result:{},row:{},select:{multiCharOverflow:8,remoteConfig:{enabled:!0,autoLoad:!0},virtualYConfig:{enabled:!0,gt:50,oSize:2}},split:{resize:!0,itemConfig:{minWidth:40,minHeight:40},resizeConfig:{showTip:!0}},splitPane:{},slider:{max:100,min:0},steps:{},switch:{},tabPane:{},tableSelect:{gridConfig:{showOverflow:!0,showHeaderOverflow:!0,showFooterOverflow:!0,rowConfig:{isHover:!0},virtualXConfig:{enabled:!0,gt:0},virtualYConfig:{enabled:!0,gt:0}}},tabs:{},tag:{},textEllipsis:{underline:!0},text:{copyConfig:{showMessage:!0}},textarea:{resize:"none"},tip:{},tooltip:{trigger:"hover",theme:"dark",enterDelay:500,leaveDelay:300,isArrow:!0},tree:{indent:20,minHeight:60,radioConfig:{strict:!0},virtualYConfig:{enabled:!0,gt:50,oSize:2}},treeSelect:{autoClose:!0,virtualYConfig:{enabled:!0,gt:0,oSize:2},treeConfig:{maxHeight:300,radioConfig:{},checkboxConfig:{},filterConfig:{autoExpandAll:!0}}},upload:{mode:"all",imageTypes:["jpg","jpeg","png","gif"],showList:!0,showUploadButton:!0,showButtonText:!0,showRemoveButton:!0,showButtonIcon:!0,showPreview:!0,dragToUpload:!0,showLimitSize:!0,showLimitCount:!0,autoSubmit:!0,maxSimultaneousUploads:5},watermark:{rotate:-30,gap:[100,100]},table:{},colgroup:{},column:{},toolbar:{},grid:{},gantt:{}});const iconPrefix="vxe-icon-";(0,_core.setIcon)({LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",BUTTON_DROPDOWN:iconPrefix+"arrow-down",BUTTON_LOADING:iconPrefix+"spinner roll",BUTTON_TOOLTIP_ICON:iconPrefix+"question-circle-fill",MENU_ITEM_EXPAND_OPEN:iconPrefix+"arrow-down rotate180",MENU_ITEM_EXPAND_CLOSE:iconPrefix+"arrow-down",SELECT_LOADED:iconPrefix+"spinner roll",SELECT_OPEN:iconPrefix+"caret-down rotate180",SELECT_CLOSE:iconPrefix+"caret-down",SELECT_ADD_OPTION:iconPrefix+"add",ICON_PICKER_OPEN:iconPrefix+"caret-down rotate180",ICON_PICKER_CLOSE:iconPrefix+"caret-down",PAGER_HOME:iconPrefix+"home-page",PAGER_END:iconPrefix+"end-page",PAGER_JUMP_PREV:iconPrefix+"arrow-double-left",PAGER_JUMP_NEXT:iconPrefix+"arrow-double-right",PAGER_PREV_PAGE:iconPrefix+"arrow-left",PAGER_NEXT_PAGE:iconPrefix+"arrow-right",PAGER_JUMP_MORE:iconPrefix+"ellipsis-h",RADIO_CHECKED:iconPrefix+"radio-checked-fill",RADIO_UNCHECKED:iconPrefix+"radio-unchecked",RADIO_DISABLED_UNCHECKED:iconPrefix+"radio-unchecked-fill",CHECKBOX_INDETERMINATE:iconPrefix+"checkbox-indeterminate-fill",CHECKBOX_CHECKED:iconPrefix+"checkbox-checked-fill",CHECKBOX_UNCHECKED:iconPrefix+"checkbox-unchecked",CHECKBOX_DISABLED_UNCHECKED:iconPrefix+"checkbox-unchecked-fill",INPUT_CLEAR:iconPrefix+"error-circle-fill",INPUT_SEARCH:iconPrefix+"search",INPUT_PLUS_NUM:iconPrefix+"caret-up",INPUT_MINUS_NUM:iconPrefix+"caret-down",NUMBER_INPUT_MINUS_NUM:iconPrefix+"minus",NUMBER_INPUT_PLUS_NUM:iconPrefix+"add",DATE_PICKER_DATE:iconPrefix+"calendar",PASSWORD_INPUT_SHOW_PWD:iconPrefix+"eye-fill-close",PASSWORD_INPUT_HIDE_PWD:iconPrefix+"eye-fill",MODAL_ZOOM_MIN:iconPrefix+"minus",MODAL_ZOOM_REVERT:iconPrefix+"recover",MODAL_ZOOM_IN:iconPrefix+"square",MODAL_ZOOM_OUT:iconPrefix+"maximize",MODAL_CLOSE:iconPrefix+"close",MODAL_INFO:iconPrefix+"info-circle-fill",MODAL_SUCCESS:iconPrefix+"success-circle-fill",MODAL_WARNING:iconPrefix+"warning-circle-fill",MODAL_ERROR:iconPrefix+"error-circle-fill",MODAL_QUESTION:iconPrefix+"question-circle-fill",MODAL_LOADING:iconPrefix+"spinner roll",DRAWER_CLOSE:iconPrefix+"close",FORM_PREFIX:iconPrefix+"question-circle-fill",FORM_SUFFIX:iconPrefix+"question-circle-fill",FORM_FOLDING:iconPrefix+"arrow-up rotate180",FORM_UNFOLDING:iconPrefix+"arrow-up",FORM_DESIGN_STYLE_SETTING:iconPrefix+"layout",FORM_DESIGN_PROPS_PC:iconPrefix+"pc",FORM_DESIGN_PROPS_MOBILE:iconPrefix+"mobile",FORM_DESIGN_PROPS_ADD:iconPrefix+"add",FORM_DESIGN_PROPS_EDIT:iconPrefix+"edit",FORM_DESIGN_WIDGET_ADD:iconPrefix+"square-plus-fill",FORM_DESIGN_WIDGET_COPY:iconPrefix+"copy",FORM_DESIGN_WIDGET_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_SWAP_LR:iconPrefix+"swap",FORM_DESIGN_WIDGET_OPTION_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_OPTION_EXPAND_OPEN:iconPrefix+"square-plus",FORM_DESIGN_WIDGET_OPTION_EXPAND_CLOSE:iconPrefix+"square-minus",LIST_DESIGN_FIELD_SETTING:iconPrefix+"custom-column",LIST_DESIGN_LIST_SETTING:iconPrefix+"menu",LIST_DESIGN_LIST_SETTING_SEARCH_DELETE:iconPrefix+"delete",LIST_DESIGN_LIST_SETTING_ACTIVE_DELETE:iconPrefix+"delete",UPLOAD_FILE_ERROR:iconPrefix+"warning-circle-fill",UPLOAD_FILE_ADD:iconPrefix+"upload",UPLOAD_FILE_REMOVE:iconPrefix+"delete",UPLOAD_FILE_DOWNLOAD:iconPrefix+"download",UPLOAD_IMAGE_UPLOAD:iconPrefix+"upload",UPLOAD_IMAGE_RE_UPLOAD:iconPrefix+"repeat",UPLOAD_IMAGE_ADD:iconPrefix+"add",UPLOAD_IMAGE_REMOVE:iconPrefix+"close",UPLOAD_LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",UPLOAD_FILE_TYPE_DEFAULT:iconPrefix+"file",UPLOAD_FILE_TYPE_XLSX:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_XLS:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_PDF:iconPrefix+"file-pdf",UPLOAD_FILE_TYPE_PNG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_GIF:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPEG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_MD:iconPrefix+"file-markdown",UPLOAD_FILE_TYPE_PPD:iconPrefix+"file-ppt",UPLOAD_FILE_TYPE_DOCX:iconPrefix+"file-word",UPLOAD_FILE_TYPE_DOC:iconPrefix+"file-word",UPLOAD_FILE_TYPE_ZIP:iconPrefix+"file-zip",UPLOAD_FILE_TYPE_TXT:iconPrefix+"file-txt",IMAGE_PREVIEW_CLOSE:iconPrefix+"close",IMAGE_PREVIEW_PREVIOUS:iconPrefix+"arrow-left",IMAGE_PREVIEW_NEXT:iconPrefix+"arrow-right",IMAGE_PREVIEW_PCT_FULL:iconPrefix+"pct-full",IMAGE_PREVIEW_PCT_1_1:iconPrefix+"pct-1-1",IMAGE_PREVIEW_ZOOM_OUT:iconPrefix+"search-zoom-out",IMAGE_PREVIEW_ZOOM_IN:iconPrefix+"search-zoom-in",IMAGE_PREVIEW_ROTATE_LEFT:iconPrefix+"rotate-left",IMAGE_PREVIEW_ROTATE_RIGHT:iconPrefix+"rotate-right",IMAGE_PREVIEW_PRINT:iconPrefix+"print",IMAGE_PREVIEW_DOWNLOAD:iconPrefix+"download",ALERT_CLOSE:iconPrefix+"close",ALERT_INFO:iconPrefix+"info-circle-fill",ALERT_SUCCESS:iconPrefix+"success-circle-fill",ALERT_WARNING:iconPrefix+"warning-circle-fill",ALERT_ERROR:iconPrefix+"error-circle-fill",TREE_NODE_OPEN:iconPrefix+"caret-right rotate90",TREE_NODE_CLOSE:iconPrefix+"caret-right",TREE_NODE_LOADED:iconPrefix+"spinner roll",TREE_SELECT_LOADED:iconPrefix+"spinner roll",TREE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TREE_SELECT_CLOSE:iconPrefix+"caret-down",TABLE_SELECT_LOADED:iconPrefix+"spinner roll",TABLE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TABLE_SELECT_CLOSE:iconPrefix+"caret-down",TABS_TAB_BUTTON_TOP:iconPrefix+"arrow-up",TABS_TAB_BUTTON_BOTTOM:iconPrefix+"arrow-down",TABS_TAB_BUTTON_LEFT:iconPrefix+"arrow-left",TABS_TAB_BUTTON_RIGHT:iconPrefix+"arrow-right",TABS_TAB_CLOSE:iconPrefix+"close",TABS_TAB_REFRESH:iconPrefix+"refresh",TABS_TAB_REFRESH_LOADING:iconPrefix+"refresh roll",TEXT_COPY:iconPrefix+"copy",TEXT_LOADING:iconPrefix+"spinner roll",CAROUSEL_HORIZONTAL_PREVIOUS:iconPrefix+"arrow-left",CAROUSEL_HORIZONTAL_NEXT:iconPrefix+"arrow-right",CAROUSEL_VERTICAL_PREVIOUS:iconPrefix+"arrow-up",CAROUSEL_VERTICAL_NEXT:iconPrefix+"arrow-down",COLLAPSE_OPEN:iconPrefix+"arrow-right rotate90",COLLAPSE_CLOSE:iconPrefix+"arrow-right",EMPTY_DEFAULT:iconPrefix+"empty",RESULT_INFO:iconPrefix+"info-circle-fill",RESULT_SUCCESS:iconPrefix+"success-circle-fill",RESULT_WARNING:iconPrefix+"warning-circle-fill",RESULT_ERROR:iconPrefix+"error-circle-fill",RESULT_QUESTION:iconPrefix+"question-circle-fill",RESULT_LOADING:iconPrefix+"spinner roll",RATE_CHECKED:iconPrefix+"star-fill",RATE_UNCHECKED:iconPrefix+"star",COLOR_PICKER_COLOR_COPY:iconPrefix+"copy",COLOR_PICKER_EYE_DROPPER:iconPrefix+"dropper",COLOR_PICKER_TPTY_OPEN:iconPrefix+"arrow-down rotate180",COLOR_PICKER_TPTY_CLOSE:iconPrefix+"arrow-down",SPLIT_TOP_ACTION:iconPrefix+"arrow-up",SPLIT_BOTTOM_ACTION:iconPrefix+"arrow-down",SPLIT_LEFT_ACTION:iconPrefix+"arrow-left",SPLIT_RIGHT_ACTION:iconPrefix+"arrow-right"});var _default=exports.default=_core.VxeUI;
package/lib/ui/src/log.js CHANGED
@@ -5,6 +5,6 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.warnLog = exports.errLog = void 0;
7
7
  var _core = require("@vxe-ui/core");
8
- const version = `ui v${"4.9.24"}`;
8
+ const version = `ui v${"4.9.26"}`;
9
9
  const warnLog = exports.warnLog = _core.log.create('warn', version);
10
10
  const errLog = exports.errLog = _core.log.create('error', version);
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");const version="ui v4.9.24",warnLog=exports.warnLog=_core.log.create("warn",version),errLog=exports.errLog=_core.log.create("error",version);
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");const version="ui v4.9.26",warnLog=exports.warnLog=_core.log.create("warn",version),errLog=exports.errLog=_core.log.create("error",version);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vxe-pc-ui",
3
- "version": "4.9.24",
3
+ "version": "4.9.26",
4
4
  "description": "A vue based PC component library",
5
5
  "scripts": {
6
6
  "update": "npm install --legacy-peer-deps",
@@ -72,6 +72,7 @@ export default defineVxeComponent({
72
72
  labelFormat: String as PropType<VxeDateRangePickerPropTypes.LabelFormat>,
73
73
  valueFormat: String as PropType<VxeDateRangePickerPropTypes.ValueFormat>,
74
74
  timeFormat: String as PropType<VxeDateRangePickerPropTypes.TimeFormat>,
75
+ valueType: String as PropType<VxeDateRangePickerPropTypes.ValueType>,
75
76
  editable: {
76
77
  type: Boolean as PropType<VxeDateRangePickerPropTypes.Editable>,
77
78
  default: true
@@ -333,8 +334,18 @@ export default defineVxeComponent({
333
334
  }
334
335
 
335
336
  const getRangeValue = (sValue: string, eValue: string) => {
336
- const { modelValue } = props
337
- const isArr = XEUtils.isArray(modelValue)
337
+ const { modelValue, valueType } = props
338
+ let isArr = XEUtils.isArray(modelValue)
339
+ if (valueType) {
340
+ switch (valueType) {
341
+ case 'array':
342
+ isArr = true
343
+ break
344
+ case 'string':
345
+ isArr = false
346
+ break
347
+ }
348
+ }
338
349
  if (sValue || eValue) {
339
350
  const rest = [sValue || '', eValue || '']
340
351
  if (isArr) {
@@ -5,7 +5,7 @@ import { VxeUI, getConfig, getIcon, globalEvents, getI18n, createEvent, useSize,
5
5
  import { getEventTargetNode, updatePanelPlacement, toCssUnit } from '../../ui/src/dom'
6
6
  import { getOnName } from '../../ui/src/vn'
7
7
  import { getLastZIndex, nextZIndex } from '../../ui/src/utils'
8
- import { warnLog, errLog } from '../../ui/src/log'
8
+ import { errLog } from '../../ui/src/log'
9
9
  import VxeInputComponent from '../../input/src/input'
10
10
 
11
11
  import type { TableSelectReactData, VxeTableSelectEmits, VxeInputConstructor, TableSelectInternalData, VxeTableSelectPropTypes, VxeFormDefines, VxeModalConstructor, VxeModalMethods, VxeDrawerConstructor, VxeDrawerMethods, TableSelectMethods, TableSelectPrivateMethods, ValueOf, TableSelectPrivateRef, VxeTableSelectPrivateComputed, VxeTableSelectConstructor, VxeTableSelectPrivateMethods, VxeFormConstructor, VxeFormPrivateMethods, VxeComponentStyleType } from '../../../types'
@@ -177,28 +177,37 @@ export default defineVxeComponent({
177
177
  })
178
178
 
179
179
  const computeGridOpts = computed(() => {
180
- const opts = Object.assign({}, getConfig().tableSelect.gridConfig, props.gridConfig, {
180
+ return Object.assign({}, getConfig().tableSelect.gridConfig, props.gridConfig, {
181
181
  data: undefined,
182
182
  columns: undefined
183
183
  })
184
- const { proxyConfig } = opts
185
- const ajaxMethods = proxyConfig && proxyConfig.ajax ? proxyConfig.ajax.query : null
186
- if (proxyConfig && ajaxMethods) {
187
- const resConfigs = proxyConfig.response || proxyConfig.props || {}
188
- opts.proxyConfig = XEUtils.merge({}, proxyConfig, {
189
- ajax: {
190
- query (params: VxeGridPropTypes.ProxyAjaxQueryParams, ...args: any[]) {
191
- return Promise.resolve(ajaxMethods(params, ...args)).then(rest => {
192
- const listProp = resConfigs.list
193
- const tableData = (listProp ? (XEUtils.isFunction(listProp) ? listProp({ data: rest, $table: null as any, $grid: null, $gantt: null }) : XEUtils.get(rest, listProp)) : rest) || []
194
- cacheDataMap(tableData || [])
195
- return rest
196
- })
197
- }
184
+ })
185
+
186
+ const computeSelectGridOpts = computed(() => {
187
+ const gridOpts = computeGridOpts.value
188
+ const { proxyConfig } = gridOpts
189
+ if (proxyConfig) {
190
+ const proxyAjax = proxyConfig.ajax
191
+ if (proxyAjax && proxyAjax.query) {
192
+ const newProxyConfig = XEUtils.clone(proxyConfig, true) as Required<VxeGridPropTypes.ProxyConfig>
193
+ const ajaxMethods = proxyAjax.query
194
+ if (ajaxMethods) {
195
+ const resConfigs = proxyConfig.response || proxyConfig.props || {}
196
+ Object.assign(newProxyConfig.ajax, {
197
+ query (params: VxeGridPropTypes.ProxyAjaxQueryParams, ...args: any[]) {
198
+ return Promise.resolve(ajaxMethods(params, ...args)).then(rest => {
199
+ const listProp = resConfigs.list
200
+ const tableData = (listProp ? (XEUtils.isFunction(listProp) ? listProp({ data: rest, $table: null as any, $grid: null, $gantt: null }) : XEUtils.get(rest, listProp)) : rest) || []
201
+ cacheDataMap(tableData || [])
202
+ return rest
203
+ })
204
+ }
205
+ })
198
206
  }
199
- })
207
+ return Object.assign({}, gridOpts, { proxyConfig: newProxyConfig })
208
+ }
200
209
  }
201
- return opts
210
+ return gridOpts
202
211
  })
203
212
 
204
213
  const computeSelectLabel = computed(() => {
@@ -585,7 +594,7 @@ export default defineVxeComponent({
585
594
  const formReadonly = computeFormReadonly.value
586
595
  const popupOpts = computePopupOpts.value
587
596
  const { className: popupClassName } = popupOpts
588
- const gridOpts = computeGridOpts.value
597
+ const selectGridOpts = computeSelectGridOpts.value
589
598
  const rowOpts = computeRowOpts.value
590
599
  const popupWrapperStyle = computePopupWrapperStyle.value
591
600
  const headerSlot = slots.header
@@ -666,7 +675,7 @@ export default defineVxeComponent({
666
675
  }, [
667
676
  VxeTableGridComponent
668
677
  ? h(VxeTableGridComponent, {
669
- ...gridOpts,
678
+ ...selectGridOpts,
670
679
  ...gridEvents,
671
680
  class: 'vxe-table-select--grid',
672
681
  ref: refGrid,
@@ -719,9 +728,6 @@ export default defineVxeComponent({
719
728
  if (gridConfig.proxyConfig.autoLoad !== false) {
720
729
  reactData.initialized = true
721
730
  }
722
- if (gridConfig.pagerConfig && gridConfig.pagerConfig.enabled !== false) {
723
- warnLog('vxe.error.notProp', ['proxy-config & grid-config.pagerConfig'])
724
- }
725
731
  }
726
732
  globalEvents.on($xeTableSelect, 'mousewheel', handleGlobalMousewheelEvent)
727
733
  globalEvents.on($xeTableSelect, 'mousedown', handleGlobalMousedownEvent)
@@ -54,6 +54,7 @@ export namespace VxeDateRangePickerPropTypes {
54
54
  export type LabelFormat = string
55
55
  export type ValueFormat = string
56
56
  export type TimeFormat = string
57
+ export type ValueType = 'auto' | 'string' | 'array' | '' | null
57
58
  export type Editable = boolean
58
59
  export type FestivalMethod = VxeDatePanelPropTypes.FestivalMethod
59
60
  export type DisabledMethod = VxeDatePanelPropTypes.DisabledMethod
@@ -106,6 +107,10 @@ export interface VxeDateRangePickerProps {
106
107
  startDay?: VxeDateRangePickerPropTypes.StartDay
107
108
  labelFormat?: VxeDateRangePickerPropTypes.LabelFormat
108
109
  valueFormat?: VxeDateRangePickerPropTypes.ValueFormat
110
+ /**
111
+ * 绑定值类型,支持字符串和数组,默认自动识别
112
+ */
113
+ valueType?: VxeDateRangePickerPropTypes.ValueType
109
114
  timeFormat?: VxeDateRangePickerPropTypes.TimeFormat
110
115
  editable?: VxeDateRangePickerPropTypes.Editable
111
116
  festivalMethod?: VxeDateRangePickerPropTypes.FestivalMethod