cnhis-design-vue 3.1.46-beta.1 → 3.1.46-beta.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +87 -87
- package/es/components/base-search/index.d.ts +7 -2
- package/es/components/base-search/src/index.vue.d.ts +7 -2
- package/es/components/button-print/src/utils/print.js +1 -1
- package/es/components/fabric-chart/src/FabricChart.vue2.js +1 -1
- package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcess.js +1 -1
- package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcessChart.js +1 -1
- package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useSurgicalAnesthesiaChart.js +1 -1
- package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useTop.js +1 -1
- package/es/components/fabric-chart/src/hooks/temperature/useCenter.js +1 -1
- package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.js +1 -1
- package/es/components/fabric-chart/src/hooks/useCumputedPoint.js +1 -1
- package/es/components/fabric-chart/src/utils/index.d.ts +1 -0
- package/es/components/fabric-chart/src/utils/index.js +1 -1
- package/es/components/form-render/src/components/renderer/radio_checkbox.js +1 -1
- package/es/components/iho-table/src/hooks/tapHooks/useSetupHooks.d.ts +1 -1
- package/es/components/iho-table/src/hooks/tapHooks/useSetupHooks.js +1 -1
- package/es/components/index.css +1 -1
- package/es/components/index.d.ts +2 -1
- package/es/components/index.js +1 -1
- package/es/components/quick-search/index.d.ts +8 -2
- package/es/components/quick-search/src/index.vue.d.ts +8 -2
- package/es/components/quick-search/src/index.vue2.js +1 -1
- package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
- package/es/components/select-label/src/LabelFormContent.vue2.js +1 -1
- package/es/components/select-person/src/SearchMultiple.vue.d.ts +6 -0
- package/es/components/table-export-field/index.d.ts +967 -0
- package/es/components/table-export-field/index.js +1 -0
- package/es/components/table-export-field/src/components/ExportModal.vue.d.ts +192 -0
- package/es/components/table-export-field/src/components/ExportModal.vue.js +1 -0
- package/es/components/table-export-field/src/components/ExportModal.vue2.js +1 -0
- package/es/components/table-export-field/src/components/SaveProjectModal.vue.d.ts +687 -0
- package/es/components/table-export-field/src/components/SaveProjectModal.vue.js +1 -0
- package/es/components/table-export-field/src/components/SaveProjectModal.vue2.js +1 -0
- package/es/components/table-export-field/src/constants/index.d.ts +3 -0
- package/es/components/table-export-field/src/constants/index.js +1 -0
- package/es/components/table-export-field/src/hooks/useAsyncData.d.ts +6 -0
- package/es/components/table-export-field/src/hooks/useAsyncData.js +1 -0
- package/es/components/table-export-field/src/index.vue.d.ts +968 -0
- package/es/components/table-export-field/src/index.vue.js +1 -0
- package/es/components/table-export-field/src/index.vue2.js +1 -0
- package/es/components/table-export-field/src/types/index.d.ts +6 -0
- package/es/components/table-export-field/src/types/index.js +1 -0
- package/es/components/table-export-field/style/index.css +1 -0
- package/es/components/table-filter/src/components/render-widget/components/DateInner.vue.d.ts +18 -5
- package/es/components/table-filter/src/components/render-widget/components/DateInner.vue2.js +1 -1
- package/es/components/table-filter/src/components/render-widget/components/DateQuickBtn/index.vue2.js +1 -1
- package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue.d.ts +18 -3
- package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue2.js +1 -1
- package/es/components/table-filter/src/components/render-widget/components/Select.vue2.js +1 -1
- package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue2.js +1 -1
- package/es/components/table-filter/src/components/render-widget/components/index.d.ts +37 -9
- package/es/components/table-filter/src/components/render-widget/index.vue.d.ts +4 -1
- package/es/components/table-filter/src/components/render-widget/index.vue.js +1 -1
- package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +37 -9
- package/es/components/table-filter/src/hooks/useAdvanced.d.ts +1 -0
- package/es/components/table-filter/src/hooks/useAdvanced.js +1 -1
- package/es/components/table-filter/src/hooks/useRenderWidget.d.ts +1 -1
- package/es/components/table-filter/src/hooks/useRenderWidget.js +1 -1
- package/es/components/table-filter/src/types/index.d.ts +1 -0
- package/es/env.d.ts +25 -25
- package/es/shared/assets/img/failure.png.js +1 -1
- package/es/shared/assets/img/no-permission.png.js +1 -1
- package/es/shared/assets/img/nodata.png.js +1 -1
- package/es/shared/assets/img/notfound.png.js +1 -1
- package/es/shared/assets/img/qr.png.js +1 -1
- package/es/shared/assets/img/success.png.js +1 -1
- package/es/shared/assets/img/video.png.js +1 -1
- package/es/shared/assets/img/video_default_cover.png.js +1 -1
- package/es/shared/assets/img/xb_big.png.js +1 -1
- package/es/shared/assets/img/xb_small.png.js +1 -1
- package/es/shared/package.json.js +1 -1
- package/es/shared/utils/fabricjs/index.js +1 -1
- package/package.json +2 -2
- package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
- package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +0 -1
- package/es/components/bpmn-workflow/types/ModelingModule.d.ts +0 -1
- package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +0 -1
- package/es/components/form-render/src/components/renderer/dist/levelSearchCascader.d.ts +0 -77
- package/es/components/form-render/src/components/renderer/dist/searchCascade.d.ts +0 -93
- package/es/components/iho-table/src/plugins/dist/highLightSetPlugin.d.ts +0 -3
- package/es/components/iho-table/src/plugins/filterRenderPlugin/dist/index.d.ts +0 -3
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/dist/index.d.ts +0 -3
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/dist/defaultRendererPlugin.d.ts +0 -3
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/dist/seqRendererPlugin.d.ts +0 -3
- package/es/components/iho-table/src/plugins/varialbleHeightPlugin/dist/index.d.ts +0 -3
- package/es/components/iho-table/src/utils/dist/index.d.ts +0 -44
- package/es/components/scale-view/src/components/formitem/dist/r-address.d.ts +0 -36
- package/es/components/scale-view/src/components/formitem/dist/r-sign.d.ts +0 -36
- package/es/components/scale-view/src/components/formitem/dist/standard-modal.d.ts +0 -82
- package/es/components/search-cascader/src/components/dist/SearchMenu.d.ts +0 -57
- package/es/components/search-cascader/src/components/dist/SearchMenu1.d.ts +0 -57
- package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +0 -86
- package/es/shared/utils/fabricjs/index.d.ts +0 -6823
- package/es/shared/utils/tapable/index.d.ts +0 -139
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import e from"./index.vue2.js";import r from"../../../_virtual/_plugin-vue_export-helper.js";var i=r(e,[["__file","index.vue"]]);export{i as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{defineComponent as e,ref as i,provide as t,computed as a,watch as l,openBlock as o,createElementBlock as n,createVNode as r,unref as s,withCtx as d,createTextVNode as u}from"vue";import{useMessage as c,NButton as m}from"naive-ui";import f from"./components/ExportModal.vue.js";import p from"./components/SaveProjectModal.vue.js";import v from"./hooks/useAsyncData.js";import{InjectionExportApiConfig as g}from"./constants/index.js";const b={class:"table-export-field"};var L=e({__name:"index",props:{visible:{type:Boolean,default:!1},tableListId:{type:String,default:""},fieldOriginList:{type:Array,default:()=>[]},exportApiConfig:{type:Object}},emits:["cancelModal"],setup(e,{emit:L}){const h=e,y="default",O=c(),{getTableListExportScheme:I,deleteTableListExportScheme:S,exportTableListScheme:x}=v(),j={schemeId:y,schemeName:"列表显示字段",fieldKeys:[]},N=i(!1),C=i({schemeId:"",schemeName:"",fieldKeys:[]}),w=i([JSON.parse(JSON.stringify(j))]);t(g,h.exportApiConfig);const M=a((()=>h.fieldOriginList.filter((e=>{var i;return"operatorColumn"!=e.columnName&&(!e.settingObj||(!(null==e?void 0:e.settingObj)||"0"===(null==(i=null==e?void 0:e.settingObj)?void 0:i.isHide)))})))),P=a((()=>{var e;let i=M.value.filter((e=>"1"==e.isShow));return(null==(e=null==i?void 0:i.map)?void 0:e.call(i,(e=>e.columnName)))||[]}));function A(){N.value=!N.value}function E(){L("cancelModal")}function J(e){const i=w.value.find((i=>i.schemeId===e));i&&(C.value=i)}function K(e){C.value.fieldKeys=e}async function _(){await async function(){if(!h.tableListId)return O.warning("请传入列表id");try{let e=await I({id:h.tableListId},h.exportApiConfig);if(e){const{schemes:i=[],lastUsedSchemeName:t=""}=e.obj;if(i&&i.length>0){w.value=[JSON.parse(JSON.stringify(j)),...i];const e=i.find((e=>e.schemeName===t));if(e)return void(C.value=e)}C.value=w.value[0]}}catch(e){O.error(`获取导出方案数据请求失败:${e}`)}}(),w.value.forEach((e=>{e.schemeId===y&&(e.fieldKeys=P.value||[])}))}return l((()=>h.visible),(async e=>{e&&await _()}),{immediate:!0}),(i,t)=>(o(),n("div",b,[r(f,{visible:e.visible,tableListId:e.tableListId,fieldOriginList:e.fieldOriginList,curProgram:C.value,programOptions:w.value,downLoadFieldList:s(M),onCancelModal:E,onUpdateCurProgram:J,onUpdateFieldCheckList:K},{add:d((()=>[r(s(m),{type:"info",onClick:A},{default:d((()=>[u("导出并存为方案")])),_:1})])),_:1},8,["visible","tableListId","fieldOriginList","curProgram","programOptions","downLoadFieldList"]),r(p,{visible:N.value,tableListId:e.tableListId,programOptions:w.value,curProgram:C.value,onCancelSaveModal:A},null,8,["visible","tableListId","programOptions","curProgram"])]))}});export{L as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.table-export-field-modal .n-card-header .svg-wrap i{cursor:pointer;font-size:18px}.table-export-field-modal .n-card-header .svg-wrap i:last-child{margin-left:16px}.table-export-field-modal .n-card-header .svg-wrap .n-icon{cursor:pointer}.table-export-field-modal .n-card__content{overflow-y:auto}.table-export-field-modal .n-card__content .export-field-con{display:flex;flex-direction:column}.table-export-field-modal .n-card__content .export-field-con .flex_between{display:flex;justify-content:space-between;margin-bottom:10px}.table-export-field-modal .n-card__content .export-field-con .select-fields{overflow-y:auto}.table-export-field-modal .n-card__content .export-field-con .select-fields .n-checkbox-group{display:flex;flex-wrap:wrap}.table-export-field-modal .n-card__content .export-field-con .select-fields .n-checkbox-group .n-checkbox{box-sizing:border-box;display:flex;flex-wrap:nowrap;padding:8px 0;width:16.6%}.table-export-field-modal .n-card__content .export-field-con .select-fields .n-checkbox-group .n-checkbox .n-checkbox__label{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.table-export-field-modal .flex_right{display:flex;justify-content:flex-end}.table-export-field-modal .flex_right .n-button{margin-left:8px}.table-export-field-modal .save-project-content .n-radio-group{margin-bottom:20px}.table-export-field-modal .select-export-popover .n-base-select-option{padding-left:12px}.table-export-field-modal .select-export-popover .n-base-select-option.n-base-select-option--show-checkmark{padding-right:12px}.table-export-field-modal .select-export-popover .n-base-select-option .n-base-select-option__content{width:100%}.table-export-field-modal .select-export-popover .n-base-select-option .n-base-select-option__content .flex-between{align-items:center;cursor:pointer;display:flex;justify-content:space-between}.table-export-field-modal .select-export-popover .n-base-select-option .n-base-select-option__content .flex-between .content{flex:1;overflow:hidden;padding-right:5px;text-overflow:ellipsis;white-space:nowrap}.table-export-field-modal .select-export-popover .n-base-select-option .n-base-select-option__content .n-base-select-option__check{display:none!important}
|
package/es/components/table-filter/src/components/render-widget/components/DateInner.vue.d.ts
CHANGED
|
@@ -25,6 +25,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
25
25
|
type: StringConstructor;
|
|
26
26
|
default: string;
|
|
27
27
|
};
|
|
28
|
+
unit: {
|
|
29
|
+
type: StringConstructor;
|
|
30
|
+
default: string;
|
|
31
|
+
};
|
|
28
32
|
}, {
|
|
29
33
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
30
34
|
componentCfg: {
|
|
@@ -50,18 +54,21 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
50
54
|
type: StringConstructor;
|
|
51
55
|
default: string;
|
|
52
56
|
};
|
|
57
|
+
unit: {
|
|
58
|
+
type: StringConstructor;
|
|
59
|
+
default: string;
|
|
60
|
+
};
|
|
53
61
|
}>> & {
|
|
54
62
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
63
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
55
64
|
}>>;
|
|
56
|
-
emit: (event: "update:value", ...args: any[]) => void;
|
|
65
|
+
emit: (event: "update:unit" | "update:value", ...args: any[]) => void;
|
|
57
66
|
valueCp: import("vue").Ref<any>;
|
|
58
67
|
isShowDateRange: import("vue").Ref<boolean>;
|
|
59
|
-
radioValue: import("vue").Ref<string>;
|
|
60
68
|
dateFormat: import("vue").ComputedRef<string>;
|
|
61
69
|
showTabStr: import("vue").ComputedRef<string>;
|
|
70
|
+
radioValue: import("vue").ComputedRef<string>;
|
|
62
71
|
optionSetting: import("vue").ComputedRef<any>;
|
|
63
|
-
isPastTime: import("vue").ComputedRef<boolean>;
|
|
64
|
-
isFutureTime: import("vue").ComputedRef<boolean>;
|
|
65
72
|
onlyRadio: import("vue").ComputedRef<boolean>;
|
|
66
73
|
defaultTime: import("vue").ComputedRef<string>;
|
|
67
74
|
changeDateShowType: () => void;
|
|
@@ -182,7 +189,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
182
189
|
dateFormat: string;
|
|
183
190
|
radioValue: string;
|
|
184
191
|
}>;
|
|
185
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
192
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:unit" | "update:value")[], "update:unit" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
186
193
|
componentCfg: {
|
|
187
194
|
type: PropType<AnyObject>;
|
|
188
195
|
};
|
|
@@ -206,12 +213,18 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
206
213
|
type: StringConstructor;
|
|
207
214
|
default: string;
|
|
208
215
|
};
|
|
216
|
+
unit: {
|
|
217
|
+
type: StringConstructor;
|
|
218
|
+
default: string;
|
|
219
|
+
};
|
|
209
220
|
}>> & {
|
|
210
221
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
222
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
211
223
|
}, {
|
|
212
224
|
type: ITypeDate;
|
|
213
225
|
value: string;
|
|
214
226
|
placeholder: string;
|
|
227
|
+
unit: string;
|
|
215
228
|
clearable: boolean;
|
|
216
229
|
valueFormat: string;
|
|
217
230
|
}>;
|
package/es/components/table-filter/src/components/render-widget/components/DateInner.vue2.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,ref as t,computed as a,watch as l,openBlock as u,createElementBlock as
|
|
1
|
+
import{defineComponent as e,ref as t,computed as a,watch as l,openBlock as u,createElementBlock as n,unref as o,createBlock as r,createCommentVNode as i,normalizeClass as d,withCtx as p,createTextVNode as m,toDisplayString as c}from"vue";import{NButton as v}from"naive-ui";import s from"../../../../../date-picker/index.js";import f from"moment";import{isString as y}from"lodash-es";import{WidgetOptionEnums as g}from"../../../types/enums.js";import{dateDisabledCollect as b,setDateDisabled as h,setTimeDisabled as k}from"../helpers/dateDisabled.js";import C from"./DateQuickBtn/index.vue.js";const Y={class:"render-widget-date-range"};var D=e({__name:"DateInner",props:{componentCfg:{type:Object},type:{type:String,default:"date"},clearable:{type:Boolean,default:!1},valueFormat:{type:String,default:"yyyy-MM-dd"},placeholder:{type:String,default:"请输入"},value:{type:String,default:""},unit:{type:String,default:""}},emits:["update:value","update:unit"],setup(e,{emit:D}){const M=e,S=t(),F=t(!1),j=a((()=>{let e="";switch(M.type){case"date":e="YYYY-MM-DD";break;case"datetime":e="YYYY-MM-DD HH:mm:ss"}return e})),T=a((()=>{let e="";switch(M.type){case"date":e="选择日期";break;case"datetime":e="选择时间"}return e})),w=a((()=>M.unit)),_=a((()=>{var e;return null==(e=M.componentCfg)?void 0:e.widgetCfg.optionSetting})),x=a((()=>_.value!==g.SELECT_TIME)),B=a((()=>b.curTime));function E(){x.value&&(F.value=!F.value)}function V(e){D("update:value",e)}function H(e){D("update:unit",e)}function I(e){S.value=e;const t=e?f(e).format(j.value):e;D("update:value",t)}function O(e){return h(e,_.value)}function Q(e){return k(e,_.value)}return l((()=>M.value),(e=>{e&&y(e)?S.value=f(e).valueOf():S.value=null}),{immediate:!0}),x.value||(F.value=!0),(t,a)=>(u(),n("div",Y,[o(x)&&!F.value?(u(),r(C,{key:0,componentCfg:e.componentCfg,type:e.type,dateFormat:o(j),radioValue:o(w),onClickQuickBtn:V,onChangeRadioValue:H},null,8,["componentCfg","type","dateFormat","radioValue"])):i("v-if",!0),o(x)?(u(),r(o(v),{key:1,secondary:"",class:d(F.value?"select-date-right":"select-date-left"),onClick:E},{default:p((()=>[m(c(o(T)),1)])),_:1},8,["class"])):i("v-if",!0),!o(x)||F.value?(u(),r(o(s),{key:2,to:"body",type:e.type,clearable:e.clearable,valueFormat:e.valueFormat,placeholder:e.placeholder,value:S.value,defaultTime:o(B),"is-date-disabled":O,"is-time-disabled":Q,"onUpdate:value":I},null,8,["type","clearable","valueFormat","placeholder","value","defaultTime"])):i("v-if",!0)]))}});export{D as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,ref as t,computed as a,openBlock as o,createElementBlock as n,Fragment as i,renderList as r,normalizeClass as l,toDisplayString as u}from"vue";import{WidgetDateOptionEnums as p}from"../../helpers/enums.js";import{widgetDateValOptions as c}from"../../helpers/dateExtraMap.js";import{formatDateRangeInfo as d,presetValToTimestamp as m}from"../../helpers/presetValToTimestamp.js";import{WidgetOptionEnums as s}from"../../../../types/enums.js";const f={class:"radio-date-group"},g=["onClick"];var v=e({__name:"index",props:{componentCfg:{type:Object},type:{type:String,default:"date"},dateFormat:{type:String,default:"YYYY-MM-DD"},radioValue:{type:String,default:""}},emits:["clickQuickBtn","changeRadioValue"],setup(e,{emit:v}){const y=e,C=t([]),k=a((()=>{var e;return null==(e=y.componentCfg)?void 0:e.widgetCfg.optionSetting})),V=a((()=>{var e;return null==(e=y.componentCfg)?void 0:e.rangeFilter}));return function(){var e,t;const{originType:a}=null==(e=y.componentCfg)?void 0:e.widgetCfg,o=`${a}_${k.value||s.ALL}${V.value?"_RANGE":""}`,n=p[o];C.value=null!=(t=c[n])?t:[]}(),(t,a)=>(o(),n("div",f,[(o(!0),n(i,null,r(C.value,(t=>(o(),n("span",{key:t.con,class:l(["radio-date-item",e.radioValue===t.con?"radio-date-item-active":""]),onClick:e=>function(e){
|
|
1
|
+
import{defineComponent as e,ref as t,computed as a,openBlock as o,createElementBlock as n,Fragment as i,renderList as r,normalizeClass as l,toDisplayString as u}from"vue";import{WidgetDateOptionEnums as p}from"../../helpers/enums.js";import{widgetDateValOptions as c}from"../../helpers/dateExtraMap.js";import{formatDateRangeInfo as d,presetValToTimestamp as m}from"../../helpers/presetValToTimestamp.js";import{WidgetOptionEnums as s}from"../../../../types/enums.js";const f={class:"radio-date-group"},g=["onClick"];var v=e({__name:"index",props:{componentCfg:{type:Object},type:{type:String,default:"date"},dateFormat:{type:String,default:"YYYY-MM-DD"},radioValue:{type:String,default:""}},emits:["clickQuickBtn","changeRadioValue"],setup(e,{emit:v}){const y=e,C=t([]),k=a((()=>{var e;return null==(e=y.componentCfg)?void 0:e.widgetCfg.optionSetting})),V=a((()=>{var e;return null==(e=y.componentCfg)?void 0:e.rangeFilter}));return function(){var e,t;const{originType:a}=null==(e=y.componentCfg)?void 0:e.widgetCfg,o=`${a}_${k.value||s.ALL}${V.value?"_RANGE":""}`,n=p[o];C.value=null!=(t=c[n])?t:[]}(),(t,a)=>(o(),n("div",f,[(o(!0),n(i,null,r(C.value,(t=>(o(),n("span",{key:t.con,class:l(["radio-date-item",e.radioValue===t.con?"radio-date-item-active":""]),onClick:e=>function(e){let t=null;const a=y.radioValue===e?"":e;a&&(t=V.value?d(a,y.dateFormat,k.value):m(a,y.dateFormat)),v("clickQuickBtn",t),v("changeRadioValue",a)}(t.con)},u(t.title),11,g)))),128))]))}});export{v as default};
|
package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue.d.ts
CHANGED
|
@@ -29,6 +29,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
29
29
|
type: StringConstructor;
|
|
30
30
|
default: string;
|
|
31
31
|
};
|
|
32
|
+
unit: {
|
|
33
|
+
type: StringConstructor;
|
|
34
|
+
default: string;
|
|
35
|
+
};
|
|
32
36
|
}, {
|
|
33
37
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
34
38
|
componentCfg: {
|
|
@@ -58,14 +62,19 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
58
62
|
type: StringConstructor;
|
|
59
63
|
default: string;
|
|
60
64
|
};
|
|
65
|
+
unit: {
|
|
66
|
+
type: StringConstructor;
|
|
67
|
+
default: string;
|
|
68
|
+
};
|
|
61
69
|
}>> & {
|
|
62
70
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
71
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
63
72
|
}>>;
|
|
64
|
-
emit: (event: "update:value", ...args: any[]) => void;
|
|
73
|
+
emit: (event: "update:unit" | "update:value", ...args: any[]) => void;
|
|
65
74
|
isShowDateRange: import("vue").Ref<boolean>;
|
|
66
|
-
radioValue: import("vue").Ref<string>;
|
|
67
75
|
startDate: import("vue").Ref<any>;
|
|
68
76
|
endDate: import("vue").Ref<any>;
|
|
77
|
+
radioValue: import("vue").ComputedRef<string>;
|
|
69
78
|
optionSetting: import("vue").ComputedRef<any>;
|
|
70
79
|
onlyRadio: import("vue").ComputedRef<boolean>;
|
|
71
80
|
isPastTime: import("vue").ComputedRef<boolean>;
|
|
@@ -198,7 +207,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
198
207
|
dateFormat: string;
|
|
199
208
|
radioValue: string;
|
|
200
209
|
}>;
|
|
201
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
210
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:unit" | "update:value")[], "update:unit" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
202
211
|
componentCfg: {
|
|
203
212
|
type: PropType<AnyObject>;
|
|
204
213
|
};
|
|
@@ -226,11 +235,17 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
226
235
|
type: StringConstructor;
|
|
227
236
|
default: string;
|
|
228
237
|
};
|
|
238
|
+
unit: {
|
|
239
|
+
type: StringConstructor;
|
|
240
|
+
default: string;
|
|
241
|
+
};
|
|
229
242
|
}>> & {
|
|
230
243
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
244
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
231
245
|
}, {
|
|
232
246
|
type: ITypeDate;
|
|
233
247
|
value: string;
|
|
248
|
+
unit: string;
|
|
234
249
|
clearable: boolean;
|
|
235
250
|
startPlaceholder: string;
|
|
236
251
|
endPlaceholder: string;
|
package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue2.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,ref as a,computed as t,watch as l,openBlock as u,createElementBlock as r,unref as n,createBlock as i,createCommentVNode as
|
|
1
|
+
import{defineComponent as e,ref as a,computed as t,watch as l,openBlock as u,createElementBlock as r,unref as n,createBlock as i,createCommentVNode as d,normalizeClass as o,withCtx as v,createTextVNode as c,toDisplayString as m,createVNode as s,createElementVNode as p}from"vue";import{NButton as f}from"naive-ui";import y from"../../../../../date-picker/index.js";import g from"moment";import{isString as b}from"lodash-es";import{WidgetOptionEnums as h}from"../../../types/enums.js";import{dateDisabledCollect as k,isStartDateRangeDisabled as C,isTimeStartRangeDisabled as F,isEndDateRangeDisabled as M,isTimeEndRangeDisabled as S}from"../helpers/dateDisabled.js";import T from"./DateQuickBtn/index.vue.js";const Y={class:"render-widget-date-range"},D={key:2,class:"date-detail-range"},E=p("span",{class:"divider"},null,-1);var _=e({__name:"DateRangeInner",props:{componentCfg:{type:Object},type:{type:String,default:"date"},clearable:{type:Boolean,default:!1},valueFormat:{type:String,default:"yyyy-MM-dd"},startPlaceholder:{type:String,default:"起始"},endPlaceholder:{type:String,default:"截止"},value:{type:String,default:""},unit:{type:String,default:""}},emits:["update:value","update:unit"],setup(e,{emit:p}){const _=e,j=a(!1),w=a(),P=a(),I=t((()=>_.unit)),U=t((()=>{var e;return null==(e=_.componentCfg)?void 0:e.widgetCfg.optionSetting})),x=t((()=>U.value!==h.SELECT_TIME)),B=t((()=>U.value===h.PAST_TIME)),O=t((()=>U.value===h.FUTURE_TIME)),R=t((()=>{let e="";switch(_.type){case"date":e="YYYY-MM-DD";break;case"datetime":e="YYYY-MM-DD HH:mm:ss"}return e})),V=t((()=>{let e="";switch(_.type){case"date":e="选择日期";break;case"datetime":e="选择时间"}return e})),H=t((()=>O.value?k.curTime:"00:00:00")),Q=t((()=>B.value?k.curTime:"23:59:59"));function $(e){p("update:value",e)}function A(e){p("update:unit",e)}function L(){x.value&&(j.value=!j.value)}function q(e,a){switch(a){case"start":w.value=e;break;case"end":P.value=e}const t=w.value?g(w.value).format(R.value):null,l=P.value?g(P.value).format(R.value):null;p("update:value",t||l?`${null!=t?t:""} ~ ${null!=l?l:""}`:"")}function z(e){return C(e,U.value,P.value)}function G(e){return F(e,U.value,P.value)}function J(e){return M(e,U.value,w.value)}function K(e){return S(e,U.value,w.value)}return l((()=>_.value),(e=>{if(e&&b(e)&&e.includes("~")){const[a,t]=e.split("~");return a.trim()&&(w.value=g(a.trim()).valueOf()),void(t.trim()&&(P.value=g(t.trim()).valueOf()))}w.value=P.value=null,p("update:unit","")}),{immediate:!0}),x.value||(j.value=!0),(a,t)=>(u(),r("div",Y,[n(x)&&!j.value?(u(),i(T,{key:0,componentCfg:e.componentCfg,type:e.type,dateFormat:n(R),radioValue:n(I),onClickQuickBtn:$,onChangeRadioValue:A},null,8,["componentCfg","type","dateFormat","radioValue"])):d("v-if",!0),n(x)?(u(),i(n(f),{key:1,secondary:"",class:o(j.value?"select-date-right":"select-date-left"),onClick:L},{default:v((()=>[c(m(n(V)),1)])),_:1},8,["class"])):d("v-if",!0),d(' default-time="23:59:59" '),!n(x)||j.value?(u(),r("div",D,[s(n(y),{type:e.type,to:"body","default-time":n(H),clearable:e.clearable,valueFormat:e.valueFormat,placeholder:e.startPlaceholder,value:w.value,"is-date-disabled":z,"is-time-disabled":G,"onUpdate:value":t[0]||(t[0]=e=>q(e,"start"))},null,8,["type","default-time","clearable","valueFormat","placeholder","value"]),E,s(n(y),{type:e.type,to:"body","default-time":n(Q),clearable:e.clearable,valueFormat:e.valueFormat,placeholder:e.endPlaceholder,value:P.value,"is-date-disabled":J,"is-time-disabled":K,"onUpdate:value":t[1]||(t[1]=e=>q(e,"end"))},null,8,["type","default-time","clearable","valueFormat","placeholder","value"])])):d("v-if",!0)]))}});export{_ as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,useAttrs as t,computed as
|
|
1
|
+
import{defineComponent as e,useAttrs as t,computed as r,openBlock as u,createBlock as o,unref as n,mergeProps as a}from"vue";import{NSelect as i}from"naive-ui";import{WholeSelectObj as l}from"../helpers/selectExtraMap.js";import{WidgetValEnums as p}from"../../../types/enums.js";var s=e({__name:"Select",props:{value:{type:[Array,String,Number]},componentCfg:{type:Object}},emits:["update:value"],setup(e,{emit:s}){const m=e,v=t(),f=r((()=>m.value)),c=r((()=>v.multiple)),d=r((()=>{const{widgetCfg:e}=m.componentCfg,{showWholeOption:t=!1}=e;return t})),g=r((()=>{const{widgetCfg:e}=m.componentCfg,{valueList:t=[]}=e;if(d.value){return[JSON.parse(JSON.stringify(l)),...t]}return t}));function y(e){if(d.value&&c.value&&Array.isArray(e)&&e.includes(p.WHOLE)){const t=e.slice(-1);if(t.includes(p.WHOLE))return void s("update:value",t);const r=e.filter((e=>e!==p.WHOLE));s("update:value",r)}else s("update:value",e)}return(e,t)=>(u(),o(n(i),a(n(v),{options:n(g),value:n(f),"onUpdate:value":y}),null,16,["options","value"]))}});export{s as default};
|
package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue.d.ts
CHANGED
|
@@ -39,7 +39,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
39
39
|
isShowWhole: import("vue").ComputedRef<any>;
|
|
40
40
|
isLastPage: import("vue").ComputedRef<boolean>;
|
|
41
41
|
valueCp: import("vue").ComputedRef<string | number | any[] | null>;
|
|
42
|
-
|
|
42
|
+
isForbidRequest: import("vue").ComputedRef<boolean>;
|
|
43
43
|
setOptionActive: (selectIds: string[]) => void;
|
|
44
44
|
handleUpdateSelect: (value: string[] | null) => void;
|
|
45
45
|
handleUpdatePage: (page: number) => Promise<void>;
|
package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue2.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,useAttrs as a,ref as l,inject as t,computed as n,
|
|
1
|
+
import{defineComponent as e,useAttrs as a,ref as l,inject as t,computed as n,nextTick as u,openBlock as o,createBlock as i,unref as r,mergeProps as s,isRef as v,withCtx as c,createVNode as p,h as f}from"vue";import{useMessage as m,NSelect as d,NTag as y}from"naive-ui";import{useDebounceFn as g}from"@vueuse/core";import h from"../../../hooks/useAsyncData.js";import{judgmentVariable as w}from"../helpers/setDefaultValue.js";import{WholeSelectObj as O}from"../helpers/selectExtraMap.js";import{WidgetValEnums as S}from"../../../types/enums.js";import{InjectionFilterApiConfig as b,InjectionFilterSearchConfig as j}from"../../../constants/index.js";import C from"./SelectDynamicOption/index.vue.js";import{isEqual as N,cloneDeep as A}from"lodash-es";var L=e({__name:"SelectDynamic",props:{value:{type:[Array,String,Number]},componentCfg:{type:Object}},emits:["update:value"],setup(e,{emit:L}){const P=e,k=m(),{getDynamicSelectData:x}=h(),D=a(),J=l(!1),E=t(b),I=t(j),K=l(1),T=l(),U=l([JSON.parse(JSON.stringify(O))]),W=l([]),M=l(),$=l(0),_={class:"select-dynamic-popover"},F=n((()=>D.multiple)),H=n((()=>{const{widgetCfg:e}=P.componentCfg,{dynamicOptionInfo:a={}}=e;return a})),V=n((()=>{const{widgetCfg:e}=P.componentCfg,{showWholeOption:a=!1}=e;return a&&1===K.value})),q=n((()=>$.value>0&&K.value>=$.value)),z=n((()=>{var e;if(Array.isArray(P.value)&&P.value.length>0){const e=P.value;if(G(e),!F.value&&1==e.length){const a=U.value.find((a=>a.value===e[0]));return JSON.stringify(a)}return U.value.filter((a=>e.includes(a.value)))}return G([]),null!=(e=P.value)?e:null})),B=n((()=>{if(Object.keys(H.value).length>0){const{defaultParams:e=[]}=H.value;return w(e)&&!P.value}return!1}));function G(e){U.value.forEach((a=>{a.actived=!1,Array.isArray(e)&&e.includes(a.value)&&(a.actived=!0)}))}function Q(e){const{widgetCfg:a}=P.componentCfg,{linkageFieldKeys:l=[]}=a;N(P.value,e)||(l.forEach((e=>{const a=I.value.find((a=>a.columnName===e));a&&a.value&&(a.value=null)})),L("update:value",e))}async function R(e){K.value=e,await X(M.value,K.value)}async function X(e,a){try{if(Object.keys(H.value).length>0){const{autograph:l,dataSourceId:t,dataSourceType:n,filterKeys:u,defaultParams:o=[],showKeys:i,valueKey:r}=H.value;let s={wordbookId:t,autograph:l,wordbookType:n,fieldKeys:u,page:a};u.length>0&&(s[u[0]]=e),J.value=!0;if(w(o)){const e=o.map((e=>e.value)).filter((e=>e.includes("${")));e.map((e=>e.match(/\$\{(.+?)\}/)[1])).forEach((e=>{const a=I.value.find((a=>a.columnName===e));a&&a.value&&a.value!==S.WHOLE&&(s[e]=a.value)}))}let v=await x(s,E);if(v){const{fieldList:e=[],rows:a=[],total:l=0}=v.map,t=a.map((e=>({...e,label:e[i[0]],value:e[r]}))),n=A(t);V.value&&t.unshift(JSON.parse(JSON.stringify(O))),T.value=null!=e?e:[],U.value=null!=t?t:[],W.value=n,$.value=l}}}catch(e){k.error(`异步数据源下拉框数据请求失败:${e}`),console.log(e)}finally{J.value=!1}}const Y=g((async e=>{await async function(e){M.value=e.trim(),K.value=1,await X(M.value,K.value)}(e)}),300);async function Z(){Object.keys(H.value).length>0&&E&&await X("",K.value)}async function ee(){L("update:value",null),await Z()}function ae(e){e&&Z()}function le({option:e,handleClose:a}){if(F.value){const l=e.value;return f(y,{style:{padding:"0 8px"},closable:!0,onClose:e=>{if(e.stopPropagation(),a(),Array.isArray(P.value)&&P.value.length>0){const e=P.value,a=e.indexOf(l.value);if(a>-1){const l=e.splice(0,a);L("update:value",l.length>0?l:null)}}}},{default:()=>f("div",l.label)})}const l=e.value?JSON.parse(e.value):{label:""};return f("div",l.label)}return u((()=>{B.value||Z()})),(e,a)=>(o(),i(r(d),s(r(D),{value:r(z),"onUpdate:value":a[0]||(a[0]=e=>v(z)?z.value=e:null),remote:"",loading:J.value,"render-tag":le,"menu-props":_,onSearch:r(Y),onClear:ee,"onUpdate:show":ae}),{empty:c((()=>[p(C,s(r(D),{dynamicOptionInfo:r(H),fieldTitleList:T.value,optionList:U.value,isMultiple:r(F),curPage:K.value,isLastPage:r(q),isShowWhole:r(V),onUpdateSelect:Q,onUpdatePage:R}),null,16,["dynamicOptionInfo","fieldTitleList","optionList","isMultiple","curPage","isLastPage","isShowWhole"])])),_:1},16,["value","loading","onSearch"]))}});export{L as default};
|
|
@@ -189,6 +189,10 @@ declare const DateInner: import("vue").DefineComponent<{
|
|
|
189
189
|
type: StringConstructor;
|
|
190
190
|
default: string;
|
|
191
191
|
};
|
|
192
|
+
unit: {
|
|
193
|
+
type: StringConstructor;
|
|
194
|
+
default: string;
|
|
195
|
+
};
|
|
192
196
|
}, {
|
|
193
197
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
194
198
|
componentCfg: {
|
|
@@ -214,18 +218,21 @@ declare const DateInner: import("vue").DefineComponent<{
|
|
|
214
218
|
type: StringConstructor;
|
|
215
219
|
default: string;
|
|
216
220
|
};
|
|
221
|
+
unit: {
|
|
222
|
+
type: StringConstructor;
|
|
223
|
+
default: string;
|
|
224
|
+
};
|
|
217
225
|
}>> & {
|
|
218
226
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
227
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
219
228
|
}>>;
|
|
220
|
-
emit: (event: "update:value", ...args: any[]) => void;
|
|
229
|
+
emit: (event: "update:unit" | "update:value", ...args: any[]) => void;
|
|
221
230
|
valueCp: import("vue").Ref<any>;
|
|
222
231
|
isShowDateRange: import("vue").Ref<boolean>;
|
|
223
|
-
radioValue: import("vue").Ref<string>;
|
|
224
232
|
dateFormat: import("vue").ComputedRef<string>;
|
|
225
233
|
showTabStr: import("vue").ComputedRef<string>;
|
|
234
|
+
radioValue: import("vue").ComputedRef<string>;
|
|
226
235
|
optionSetting: import("vue").ComputedRef<any>;
|
|
227
|
-
isPastTime: import("vue").ComputedRef<boolean>;
|
|
228
|
-
isFutureTime: import("vue").ComputedRef<boolean>;
|
|
229
236
|
onlyRadio: import("vue").ComputedRef<boolean>;
|
|
230
237
|
defaultTime: import("vue").ComputedRef<string>;
|
|
231
238
|
changeDateShowType: () => void;
|
|
@@ -346,7 +353,7 @@ declare const DateInner: import("vue").DefineComponent<{
|
|
|
346
353
|
dateFormat: string;
|
|
347
354
|
radioValue: string;
|
|
348
355
|
}>;
|
|
349
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
356
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:unit" | "update:value")[], "update:unit" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
350
357
|
componentCfg: {
|
|
351
358
|
type: import("vue").PropType<import("../../../../..").AnyObject>;
|
|
352
359
|
};
|
|
@@ -370,12 +377,18 @@ declare const DateInner: import("vue").DefineComponent<{
|
|
|
370
377
|
type: StringConstructor;
|
|
371
378
|
default: string;
|
|
372
379
|
};
|
|
380
|
+
unit: {
|
|
381
|
+
type: StringConstructor;
|
|
382
|
+
default: string;
|
|
383
|
+
};
|
|
373
384
|
}>> & {
|
|
374
385
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
386
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
375
387
|
}, {
|
|
376
388
|
type: "date" | "datetime";
|
|
377
389
|
value: string;
|
|
378
390
|
placeholder: string;
|
|
391
|
+
unit: string;
|
|
379
392
|
clearable: boolean;
|
|
380
393
|
valueFormat: string;
|
|
381
394
|
}>;
|
|
@@ -544,6 +557,10 @@ declare const DateRangeInner: import("vue").DefineComponent<{
|
|
|
544
557
|
type: StringConstructor;
|
|
545
558
|
default: string;
|
|
546
559
|
};
|
|
560
|
+
unit: {
|
|
561
|
+
type: StringConstructor;
|
|
562
|
+
default: string;
|
|
563
|
+
};
|
|
547
564
|
}, {
|
|
548
565
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
549
566
|
componentCfg: {
|
|
@@ -573,14 +590,19 @@ declare const DateRangeInner: import("vue").DefineComponent<{
|
|
|
573
590
|
type: StringConstructor;
|
|
574
591
|
default: string;
|
|
575
592
|
};
|
|
593
|
+
unit: {
|
|
594
|
+
type: StringConstructor;
|
|
595
|
+
default: string;
|
|
596
|
+
};
|
|
576
597
|
}>> & {
|
|
577
598
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
599
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
578
600
|
}>>;
|
|
579
|
-
emit: (event: "update:value", ...args: any[]) => void;
|
|
601
|
+
emit: (event: "update:unit" | "update:value", ...args: any[]) => void;
|
|
580
602
|
isShowDateRange: import("vue").Ref<boolean>;
|
|
581
|
-
radioValue: import("vue").Ref<string>;
|
|
582
603
|
startDate: import("vue").Ref<any>;
|
|
583
604
|
endDate: import("vue").Ref<any>;
|
|
605
|
+
radioValue: import("vue").ComputedRef<string>;
|
|
584
606
|
optionSetting: import("vue").ComputedRef<any>;
|
|
585
607
|
onlyRadio: import("vue").ComputedRef<boolean>;
|
|
586
608
|
isPastTime: import("vue").ComputedRef<boolean>;
|
|
@@ -713,7 +735,7 @@ declare const DateRangeInner: import("vue").DefineComponent<{
|
|
|
713
735
|
dateFormat: string;
|
|
714
736
|
radioValue: string;
|
|
715
737
|
}>;
|
|
716
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
738
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:unit" | "update:value")[], "update:unit" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
717
739
|
componentCfg: {
|
|
718
740
|
type: import("vue").PropType<import("../../../../..").AnyObject>;
|
|
719
741
|
};
|
|
@@ -741,11 +763,17 @@ declare const DateRangeInner: import("vue").DefineComponent<{
|
|
|
741
763
|
type: StringConstructor;
|
|
742
764
|
default: string;
|
|
743
765
|
};
|
|
766
|
+
unit: {
|
|
767
|
+
type: StringConstructor;
|
|
768
|
+
default: string;
|
|
769
|
+
};
|
|
744
770
|
}>> & {
|
|
745
771
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
772
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
746
773
|
}, {
|
|
747
774
|
type: "date" | "datetime";
|
|
748
775
|
value: string;
|
|
776
|
+
unit: string;
|
|
749
777
|
clearable: boolean;
|
|
750
778
|
startPlaceholder: string;
|
|
751
779
|
endPlaceholder: string;
|
|
@@ -1076,7 +1104,7 @@ declare const SelectDynamic: import("vue").DefineComponent<{
|
|
|
1076
1104
|
isShowWhole: import("vue").ComputedRef<any>;
|
|
1077
1105
|
isLastPage: import("vue").ComputedRef<boolean>;
|
|
1078
1106
|
valueCp: import("vue").ComputedRef<string | number | any[] | null>;
|
|
1079
|
-
|
|
1107
|
+
isForbidRequest: import("vue").ComputedRef<boolean>;
|
|
1080
1108
|
setOptionActive: (selectIds: string[]) => void;
|
|
1081
1109
|
handleUpdateSelect: (value: string[] | null) => void;
|
|
1082
1110
|
handleUpdatePage: (page: number) => Promise<void>;
|
|
@@ -10,6 +10,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
10
10
|
initialProps: {};
|
|
11
11
|
}, {
|
|
12
12
|
valueCp(): any;
|
|
13
|
+
unit(): any;
|
|
13
14
|
}, {
|
|
14
15
|
search(): void;
|
|
15
16
|
getEleWidth(cfg: any): {
|
|
@@ -20,7 +21,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
20
21
|
[key: string]: any;
|
|
21
22
|
}> | null;
|
|
22
23
|
handleUpdate(val: any): void;
|
|
23
|
-
|
|
24
|
+
handleUpdateUnit(val: any): void;
|
|
25
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:unit" | "outFilterChange")[], "update:modelValue" | "update:unit" | "outFilterChange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
24
26
|
cfg: {
|
|
25
27
|
type: ObjectConstructor;
|
|
26
28
|
required: true;
|
|
@@ -30,6 +32,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
30
32
|
};
|
|
31
33
|
}>> & {
|
|
32
34
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
35
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
33
36
|
onOutFilterChange?: ((...args: any[]) => any) | undefined;
|
|
34
37
|
}, {}>;
|
|
35
38
|
export default _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,h as t}from"vue";import{WidgetTypeEnums as i}from"../../types/enums.js";import{WidgetCfgMaps as
|
|
1
|
+
import{defineComponent as e,h as t}from"vue";import{WidgetTypeEnums as i}from"../../types/enums.js";import{WidgetCfgMaps as n}from"./widgetCfgMaps.js";import r from"../../../../../_virtual/_plugin-vue_export-helper.js";const a=[i.DATE,i.DATE_TIME,i.CHECKBOX_GROUP];var l=r(e({props:{cfg:{type:Object,required:!0},modelValue:{type:[Array,String,Number]}},emits:["update:modelValue","update:unit","outFilterChange"],computed:{valueCp(){return this.cfg.value},unit(){return this.cfg.unit}},data:()=>({initialProps:{}}),methods:{search(){this.$emit("outFilterChange")},getEleWidth(e){const{widgetType:t,widgetCfg:n,filterExplicit:r}=e;if(a.includes(t))return;const l=i.SELECT!==t&&i.SELECTLABEL!==t&&i.SELECTDYNAMIC!==t||!n.multiple?"100%":"200px";return{width:0===r?"100%":e.advanceColWidth?`${e.advanceColWidth}px`:l}},initComponentProps(e){const{widgetType:t,alias:i,title:r,placeholder:a,widgetCfg:l}=e,{props:s,handlerProps:p}=n.get(t);let u={...s};p&&(u=p(u,{...l,title:i||r})),a&&(u.placeholder=a),this.initialProps=u,u.value&&(this.valueCp=u.value)},generateWidget(e){const{widgetType:i}=e;if(!n.has(i))return null;const{value:r}=e,{component:a,style:l,eventsBySearch:s=[]}=n.get(i),p={...this.initialProps,value:r,componentCfg:e},u=s.reduce(((e,t)=>{const{name:i,handler:n}=t;let r=this.search;return n&&(r=e=>{n(e,this.search,p)}),{...e,[`on${i}`]:r}}),{});return t(a,{...l,...p,style:this.getEleWidth(e),value:this.valueCp,unit:this.unit,"onUpdate:value":e=>this.handleUpdate(e),"onUpdate:unit":e=>this.handleUpdateUnit(e),...u})},handleUpdate(e){this.$emit("update:modelValue",e)},handleUpdateUnit(e){this.$emit("update:unit",e)}},created(){this.initComponentProps(this.cfg)},render(){return this.generateWidget(this.cfg)}}),[["__file","index.vue"]]);export{l as default};
|
|
@@ -112,7 +112,7 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
112
112
|
isShowWhole: import("vue").ComputedRef<any>;
|
|
113
113
|
isLastPage: import("vue").ComputedRef<boolean>;
|
|
114
114
|
valueCp: import("vue").ComputedRef<string | number | any[] | null>;
|
|
115
|
-
|
|
115
|
+
isForbidRequest: import("vue").ComputedRef<boolean>;
|
|
116
116
|
setOptionActive: (selectIds: string[]) => void;
|
|
117
117
|
handleUpdateSelect: (value: string[] | null) => void;
|
|
118
118
|
handleUpdatePage: (page: number) => Promise<void>;
|
|
@@ -333,6 +333,10 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
333
333
|
type: StringConstructor;
|
|
334
334
|
default: string;
|
|
335
335
|
};
|
|
336
|
+
unit: {
|
|
337
|
+
type: StringConstructor;
|
|
338
|
+
default: string;
|
|
339
|
+
};
|
|
336
340
|
}, {
|
|
337
341
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
338
342
|
componentCfg: {
|
|
@@ -358,18 +362,21 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
358
362
|
type: StringConstructor;
|
|
359
363
|
default: string;
|
|
360
364
|
};
|
|
365
|
+
unit: {
|
|
366
|
+
type: StringConstructor;
|
|
367
|
+
default: string;
|
|
368
|
+
};
|
|
361
369
|
}>> & {
|
|
362
370
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
371
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
363
372
|
}>>;
|
|
364
|
-
emit: (event: "update:value", ...args: any[]) => void;
|
|
373
|
+
emit: (event: "update:unit" | "update:value", ...args: any[]) => void;
|
|
365
374
|
valueCp: import("vue").Ref<any>;
|
|
366
375
|
isShowDateRange: import("vue").Ref<boolean>;
|
|
367
|
-
radioValue: import("vue").Ref<string>;
|
|
368
376
|
dateFormat: import("vue").ComputedRef<string>;
|
|
369
377
|
showTabStr: import("vue").ComputedRef<string>;
|
|
378
|
+
radioValue: import("vue").ComputedRef<string>;
|
|
370
379
|
optionSetting: import("vue").ComputedRef<any>;
|
|
371
|
-
isPastTime: import("vue").ComputedRef<boolean>;
|
|
372
|
-
isFutureTime: import("vue").ComputedRef<boolean>;
|
|
373
380
|
onlyRadio: import("vue").ComputedRef<boolean>;
|
|
374
381
|
defaultTime: import("vue").ComputedRef<string>;
|
|
375
382
|
changeDateShowType: () => void;
|
|
@@ -490,7 +497,7 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
490
497
|
dateFormat: string;
|
|
491
498
|
radioValue: string;
|
|
492
499
|
}>;
|
|
493
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
500
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:unit" | "update:value")[], "update:unit" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
494
501
|
componentCfg: {
|
|
495
502
|
type: import("vue").PropType<import("../../../..").AnyObject>;
|
|
496
503
|
};
|
|
@@ -514,12 +521,18 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
514
521
|
type: StringConstructor;
|
|
515
522
|
default: string;
|
|
516
523
|
};
|
|
524
|
+
unit: {
|
|
525
|
+
type: StringConstructor;
|
|
526
|
+
default: string;
|
|
527
|
+
};
|
|
517
528
|
}>> & {
|
|
518
529
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
530
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
519
531
|
}, {
|
|
520
532
|
type: "date" | "datetime";
|
|
521
533
|
value: string;
|
|
522
534
|
placeholder: string;
|
|
535
|
+
unit: string;
|
|
523
536
|
clearable: boolean;
|
|
524
537
|
valueFormat: string;
|
|
525
538
|
}>;
|
|
@@ -714,6 +727,10 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
714
727
|
type: StringConstructor;
|
|
715
728
|
default: string;
|
|
716
729
|
};
|
|
730
|
+
unit: {
|
|
731
|
+
type: StringConstructor;
|
|
732
|
+
default: string;
|
|
733
|
+
};
|
|
717
734
|
}, {
|
|
718
735
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
719
736
|
componentCfg: {
|
|
@@ -743,14 +760,19 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
743
760
|
type: StringConstructor;
|
|
744
761
|
default: string;
|
|
745
762
|
};
|
|
763
|
+
unit: {
|
|
764
|
+
type: StringConstructor;
|
|
765
|
+
default: string;
|
|
766
|
+
};
|
|
746
767
|
}>> & {
|
|
747
768
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
769
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
748
770
|
}>>;
|
|
749
|
-
emit: (event: "update:value", ...args: any[]) => void;
|
|
771
|
+
emit: (event: "update:unit" | "update:value", ...args: any[]) => void;
|
|
750
772
|
isShowDateRange: import("vue").Ref<boolean>;
|
|
751
|
-
radioValue: import("vue").Ref<string>;
|
|
752
773
|
startDate: import("vue").Ref<any>;
|
|
753
774
|
endDate: import("vue").Ref<any>;
|
|
775
|
+
radioValue: import("vue").ComputedRef<string>;
|
|
754
776
|
optionSetting: import("vue").ComputedRef<any>;
|
|
755
777
|
onlyRadio: import("vue").ComputedRef<boolean>;
|
|
756
778
|
isPastTime: import("vue").ComputedRef<boolean>;
|
|
@@ -883,7 +905,7 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
883
905
|
dateFormat: string;
|
|
884
906
|
radioValue: string;
|
|
885
907
|
}>;
|
|
886
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
908
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:unit" | "update:value")[], "update:unit" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
887
909
|
componentCfg: {
|
|
888
910
|
type: import("vue").PropType<import("../../../..").AnyObject>;
|
|
889
911
|
};
|
|
@@ -911,11 +933,17 @@ export declare const WidgetCfgMaps: Map<string, {
|
|
|
911
933
|
type: StringConstructor;
|
|
912
934
|
default: string;
|
|
913
935
|
};
|
|
936
|
+
unit: {
|
|
937
|
+
type: StringConstructor;
|
|
938
|
+
default: string;
|
|
939
|
+
};
|
|
914
940
|
}>> & {
|
|
915
941
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
942
|
+
"onUpdate:unit"?: ((...args: any[]) => any) | undefined;
|
|
916
943
|
}, {
|
|
917
944
|
type: "date" | "datetime";
|
|
918
945
|
value: string;
|
|
946
|
+
unit: string;
|
|
919
947
|
clearable: boolean;
|
|
920
948
|
startPlaceholder: string;
|
|
921
949
|
endPlaceholder: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{WidgetOptionEnums as e,WidgetTypeEnums as i,WidgetValEnums as t}from"../types/enums.js";import{presetValToTimestamp as n}from"../components/render-widget/helpers/presetValToTimestamp.js";import{DatePresetValEnums as l}from"../components/render-widget/enums.js";const o={[e.RADIO]:"0",[e.MULTIPLE]:"1",[e.ALL]:"0",[e.SELECT_TIME]:"1",[e.PAST_TIME]:"2",[e.FUTURE_TIME]:"3"};function a(){return{transformData:function(t,n){return t.map((t=>{var l,a,u;const{optionInfo:E={list:[],manualMapping:!0,dynamicOptionInfo:{},showWholeOption:!1},type:r,defaultValue:s,optionType:T,filterExplicit:d,rangeFilter:p}=t,c={},f={title:(m=t).title,alias:m.customTitle,isShowSearch:m.isShowSearch?1:0,filterExplicit:m.filterExplicit?1:0,explicitRequired:m.explicitRequired?1:0,advanceOptionSetting:m.optionType?o[m.optionType]:"",placeholder:m.remark,advanceColWidth:m.width};var m;let v,g,L=r;d?(v=r===i.SELECT&&T===e.MULTIPLE?null==s?void 0:s.valueList:null==(l=null==s?void 0:s.valueList)?void 0:l[0],g=null==s?void 0:s.unit,r===i.LABEL&&(L="SELECTLABEL",v=null==s?void 0:s.valueList),r===i.DATE&&(L="DATE_OUT"),r===i.DATE_TIME&&(L="DATETIME_OUT")):r===i.SELECT&&(null==E?void 0:E.list)&&(null==E?void 0:E.list.length)<10&&(L="CHECKBOX_GROUP"),p&&(r===i.INPUT_NUMBER&&(L="INPUTNUMBER_RANGE"),r===i.DATE&&(L=d?"DATE_RANGE_OUT":"DATE_RANGE_INNER"),r===i.DATE_TIME&&(L=d?"DATETIME_RANGE_OUT":"DATETIME_RANGE_INNER")),r===i.SELECT&&!1===(null==E?void 0:E.manualMapping)&&(L=i.SELECTDYNAMIC);const A={isRender:!0,widgetType:L,originType:r,valueList:null==(a=null==E?void 0:E.list)?void 0:a.map((({name:e,value:i})=>({value:i,label:e}))),defaultValue:v,defValueUnit:g,optionSetting:T,multiple:T===e.MULTIPLE||L===i.SELECTLABEL,manualMapping:null==E?void 0:E.manualMapping,showWholeOption:null==E?void 0:E.showWholeOption,dynamicOptionInfo:null==E?void 0:E.dynamicOptionInfo,classifyStr:null==s?void 0:s.classifyStr,linkageFieldKeys:null!=(u=null==s?void 0:s.linkageFieldKeys)?u:[]};return{...f,fieldType:t.dataType,columnName:t.name,settingObj:c,setting:JSON.stringify(c),widgetCfg:A,rangeFilter:p,_extendData:null!=n?n:{}}}))},getCacheDef:function(e,t){const{widgetType:n,widgetCfg:l}=e;return[i.SELECT,i.CHECKBOX_GROUP,i.SELECTDYNAMIC].includes(n)&&l.multiple?t:t[0]},transformClassifyChild:function(e){const i={};return e&&e.length>0&&e.forEach((e=>{const t=e.field_key,o=e.value&&e.value.length>1?e.value:e.value.toString();if(i[t]=o,e.unit&&e.unit!==l.CUSTOM){const l=n(e.unit,"YYYY-MM-DD HH:mm:ss");i[t]=l}})),i},transformParams:function(e){const n={},l=[i.SELECT,i.SELECTDYNAMIC];return e&&e.length>0&&e.forEach((e=>{const i=e.field_key,o=l.includes(e.widgetType)||e.value&&e.value.length>1?e.value:e.value.toString();Array.isArray(o)&&o.length>0&&o.includes(t.WHOLE)||(n[i]=o)})),n}}}export{a as default};
|
|
1
|
+
import{WidgetOptionEnums as e,WidgetTypeEnums as i,WidgetValEnums as t}from"../types/enums.js";import{presetValToTimestamp as n}from"../components/render-widget/helpers/presetValToTimestamp.js";import{DatePresetValEnums as l}from"../components/render-widget/enums.js";const o={[e.RADIO]:"0",[e.MULTIPLE]:"1",[e.ALL]:"0",[e.SELECT_TIME]:"1",[e.PAST_TIME]:"2",[e.FUTURE_TIME]:"3"};function a(){return{transformData:function(t,n){return t.map((t=>{var l,a,u;const{optionInfo:E={list:[],manualMapping:!0,dynamicOptionInfo:{},showWholeOption:!1},type:r,defaultValue:s,optionType:T,filterExplicit:d,rangeFilter:p}=t,c={},f={title:(m=t).title,alias:m.customTitle,isShowSearch:m.isShowSearch?1:0,filterExplicit:m.filterExplicit?1:0,explicitRequired:m.explicitRequired?1:0,advanceOptionSetting:m.optionType?o[m.optionType]:"",placeholder:m.remark,advanceColWidth:m.width};var m;let v,g,L=r;d?(v=r===i.SELECT&&T===e.MULTIPLE?null==s?void 0:s.valueList:null==(l=null==s?void 0:s.valueList)?void 0:l[0],g=null==s?void 0:s.unit,r===i.LABEL&&(L="SELECTLABEL",v=null==s?void 0:s.valueList),r===i.DATE&&(L="DATE_OUT"),r===i.DATE_TIME&&(L="DATETIME_OUT")):r===i.SELECT&&(null==E?void 0:E.list)&&(null==E?void 0:E.list.length)<10&&(L="CHECKBOX_GROUP"),p&&(r===i.INPUT_NUMBER&&(L="INPUTNUMBER_RANGE"),r===i.DATE&&(L=d?"DATE_RANGE_OUT":"DATE_RANGE_INNER"),r===i.DATE_TIME&&(L=d?"DATETIME_RANGE_OUT":"DATETIME_RANGE_INNER")),r===i.SELECT&&!1===(null==E?void 0:E.manualMapping)&&(L=i.SELECTDYNAMIC);const A={isRender:!0,widgetType:L,originType:r,valueList:null==(a=null==E?void 0:E.list)?void 0:a.map((({name:e,value:i})=>({value:i,label:e}))),defaultValue:v,defValueUnit:g,optionSetting:T,multiple:T===e.MULTIPLE||L===i.SELECTLABEL,manualMapping:null==E?void 0:E.manualMapping,showWholeOption:null==E?void 0:E.showWholeOption,dynamicOptionInfo:null==E?void 0:E.dynamicOptionInfo,classifyStr:null==s?void 0:s.classifyStr,linkageFieldKeys:null!=(u=null==s?void 0:s.linkageFieldKeys)?u:[]};return{...f,fieldType:t.dataType,columnName:t.name,settingObj:c,setting:JSON.stringify(c),widgetCfg:A,rangeFilter:p,unit:null!=g?g:"",_extendData:null!=n?n:{}}}))},getCacheDef:function(e,t){const{widgetType:n,widgetCfg:l}=e;return[i.SELECT,i.CHECKBOX_GROUP,i.SELECTDYNAMIC].includes(n)&&l.multiple?t:t[0]},transformClassifyChild:function(e){const i={};return e&&e.length>0&&e.forEach((e=>{const t=e.field_key,o=e.value&&e.value.length>1?e.value:e.value.toString();if(i[t]=o,e.unit&&e.unit!==l.CUSTOM){const l=n(e.unit,"YYYY-MM-DD HH:mm:ss");i[t]=l}})),i},transformParams:function(e){const n={},l=[i.SELECT,i.SELECTDYNAMIC];return e&&e.length>0&&e.forEach((e=>{const i=e.field_key,o=l.includes(e.widgetType)||e.value&&e.value.length>1?e.value:e.value.toString();Array.isArray(o)&&o.length>0&&o.includes(t.WHOLE)||(n[i]=o)})),n}}}export{a as default};
|
|
@@ -8,7 +8,7 @@ export default function (): {
|
|
|
8
8
|
field_key: string;
|
|
9
9
|
con: string | undefined;
|
|
10
10
|
value: any[] | null;
|
|
11
|
-
unit:
|
|
11
|
+
unit: string;
|
|
12
12
|
} | null;
|
|
13
13
|
getDefValByRenderConObj: (conObj: ISearchConfigType, cfg: ISearchType) => any;
|
|
14
14
|
isExistDefValByRenderWidget: (cfg: ISearchType) => boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{WidgetCfgMaps as e}from"../components/render-widget/widgetCfgMaps.js";import{
|
|
1
|
+
import{WidgetCfgMaps as e}from"../components/render-widget/widgetCfgMaps.js";import{WidgetTypeEnums as t,WidgetOptionEnums as n}from"../types/enums.js";const i=[t.CHECKBOX_GROUP,t.DATE,t.DATE_TIME,t.DATE_RANGE_INNER,t.DATETIME_RANGE_INNER,t.LABEL];function r(){function r(e){var t;return null==(t=e.widgetCfg)?void 0:t.isRender}async function u(t){const{widgetType:i,defaultValue:r,defValueUnit:u,optionSetting:l,multiple:o}=t.widgetCfg||{},a=e.get(i);let d;if(a){const{setDefaultValue:e}=a;e&&(d=await e(r,u,{optSetting:null!=l?l:n.ALL,multiple:o,_cfg:t}))}return d}return{isRender:r,getDefValByRenderWidget:u,initRenderWidgetCfg:async function(e){const t=r(e);if(!t)return t;const{widgetType:n}=e.widgetCfg||{};return e._frontId||(e._frontId="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(e=>{const t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))),e.isRender=t,e.widgetType=n,e.con="EQ",i.includes(n)&&(e._isBlock=!0),1==e.filterExplicit&&(e.value=await u(e)),t},getRenderSearchConObj:function(e){if(!r(e))return null;const{columnName:t,con:n,value:i,widgetType:u,unit:l=""}=e,o=Array.isArray(i)?i:i?[i]:[];return{widgetType:u,field_key:t,con:n,value:o.length>0?o:null,unit:l}},getDefValByRenderConObj:function(e,n){if(!r(n))return null;const{widgetType:i,multiple:u}=n.widgetCfg||{},{value:l}=e;return i!==t.SELECT&&i!==t.CHECKBOX_GROUP||!u?Array.isArray(l)?l[0]:l:Array.isArray(l)?l:l?[l]:[]},isExistDefValByRenderWidget:function(e){const{defaultValue:t,defValueUnit:n}=e.widgetCfg||{};return!(!t&&!n)},resetRenderWidgetValue:function(e){const t=r(e);return t?(e.value=null,t):t}}}export{r as default};
|