cnhis-design-vue 3.1.46-beta.3 → 3.1.46-beta.30
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/es/components/button-print/index.d.ts +1 -1
- package/es/components/button-print/src/ButtonPrint.vue.d.ts +1 -1
- package/es/components/button-print/src/ButtonPrint.vue2.js +1 -1
- package/es/components/button-print/src/utils/print.js +1 -1
- package/es/components/classification/index.d.ts +1 -1
- package/es/components/classification/src/index.vue.d.ts +1 -1
- package/es/components/classification/src/index.vue2.js +1 -1
- package/es/components/date-picker/src/DatePicker.vue2.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-config/index.d.ts +23 -1
- package/es/components/form-config/src/FormConfig.vue.d.ts +23 -1
- package/es/components/form-config/src/FormConfig.vue2.js +1 -1
- package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +11 -0
- package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +11 -0
- package/es/components/form-config/src/hooks/useDataNormalize.d.ts +1 -1
- package/es/components/form-config/src/hooks/useDataNormalize.js +1 -1
- package/es/components/form-config/src/types/index.d.ts +1 -1
- package/es/components/form-render/index.d.ts +11 -0
- package/es/components/form-render/src/FormRender.vue.d.ts +12 -1
- package/es/components/form-render/src/FormRender.vue2.js +1 -1
- package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +11 -0
- package/es/components/form-render/src/components/renderer/levelSearchCascader.js +1 -1
- package/es/components/form-render/src/hooks/useOperationalForm.d.ts +7 -0
- package/es/components/form-render/src/hooks/useOperationalForm.js +1 -0
- package/es/components/form-render/src/types/index.d.ts +2 -1
- package/es/components/iho-table/index.d.ts +14 -0
- package/es/components/iho-table/src/IhoTable.vue.d.ts +14 -0
- package/es/components/iho-table/src/hooks/tapHooks/useConfigHooks.d.ts +1 -0
- package/es/components/iho-table/src/hooks/tapHooks/useEventHooks.d.ts +2 -0
- package/es/components/iho-table/src/hooks/tapHooks/useEventHooks.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/iho-table/src/plugins/defaultConfigPlugin/index.js +1 -1
- package/es/components/iho-table/src/plugins/filterDaterangeRenderPlugin/filter.vue.d.ts +2 -2
- package/es/components/iho-table/src/plugins/filterRenderPlugin/filter.vue.d.ts +1 -1
- package/es/components/iho-table/src/plugins/filterRenderPlugin/filter.vue2.js +1 -1
- package/es/components/iho-table/src/plugins/index.js +1 -1
- package/es/components/iho-table/src/plugins/lowCodeFieldAdaptorPlugin/index.js +1 -1
- package/es/components/iho-table/src/plugins/operationalFormPlugin/index.d.ts +1 -0
- package/es/components/iho-table/src/plugins/operationalFormPlugin/index.js +1 -0
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/checkRendererPlugin.js +1 -1
- package/es/components/iho-table/src/plugins/varialbleHeightPlugin/index.js +1 -1
- package/es/components/iho-table/src/types/index.d.ts +3 -1
- package/es/components/iho-table/src/types/pluginType.d.ts +2 -0
- package/es/components/iho-table/style/index.css +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/info-header/index.d.ts +26 -0
- package/es/components/info-header/src/InfoHeader.vue.d.ts +26 -0
- package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +11 -0
- package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +11 -0
- package/es/components/quick-search/src/index.vue2.js +1 -1
- package/es/components/scale-view/index.d.ts +8 -8
- package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
- package/es/components/scale-view/src/components/formitem/r-checkbox.d.ts +4 -4
- package/es/components/scale-view/src/components/formitem/r-checkbox.js +1 -1
- package/es/components/scale-view/src/components/formitem/r-radio.d.ts +4 -4
- package/es/components/scale-view/src/components/formitem/r-radio.js +1 -1
- package/es/components/scale-view/src/hooks/use-component.d.ts +16 -16
- package/es/components/scale-view/style/index.css +1 -1
- package/es/components/search-cascader/src/SearchCascader.vue2.js +1 -1
- package/es/components/select-person/index.d.ts +123 -0
- package/es/components/select-person/src/SearchOrgAndStaff.vue.d.ts +88 -0
- package/es/components/select-person/src/SearchOrgAndStaff.vue.js +1 -0
- package/es/components/select-person/src/SearchOrgAndStaff.vue2.js +1 -0
- package/es/components/select-person/src/SelectPerson.vue.d.ts +123 -0
- package/es/components/select-person/src/SelectPerson.vue2.js +1 -1
- package/es/components/select-person/src/types/enums.d.ts +4 -0
- package/es/components/select-person/src/types/enums.js +1 -0
- package/es/components/select-person/src/utils/index.d.ts +1 -1
- package/es/components/select-person/src/utils/index.js +1 -1
- package/es/components/select-person/style/index.css +1 -1
- package/es/components/shortcut-setter/index.d.ts +11 -0
- package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +11 -0
- package/es/components/table-export-field/index.d.ts +1057 -0
- package/es/components/table-export-field/index.js +1 -0
- package/es/components/table-export-field/src/components/ExportModal.vue.d.ts +270 -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 +700 -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 +1058 -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/tool.d.ts +1 -0
- package/es/components/table-export-field/src/tool.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/classify-filter/components/SelectDynamic.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/hooks/useAdvanced.d.ts +1 -1
- package/es/components/table-filter/src/hooks/useAdvanced.js +1 -1
- package/es/shared/hooks/useDateTime.d.ts +1 -1
- package/es/shared/hooks/useDateTime.js +1 -1
- package/es/shared/package.json.js +1 -1
- package/es/shared/types/business.d.ts +6 -0
- package/es/shared/types/index.d.ts +1 -0
- package/es/shared/utils/business.d.ts +6 -1
- package/es/shared/utils/business.js +1 -1
- package/es/shared/utils/fabricjs/index.js +1 -1
- package/es/shared/utils/index.js +1 -1
- package/es/shared/utils/tapableLess.d.ts +28 -0
- package/es/shared/utils/tapableLess.js +1 -0
- package/package.json +2 -2
- 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
|
@@ -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,watch as l,openBlock as a,createElementBlock as o,createVNode as n,withCtx as s,unref as r,createTextVNode as d}from"vue";import{useMessage as u,NButton as c}from"naive-ui";import m from"./components/ExportModal.vue.js";import v from"./components/SaveProjectModal.vue.js";import f from"./hooks/useAsyncData.js";import{InjectionExportApiConfig as p}from"./constants/index.js";import{cloneDeep as b}from"lodash-es";const L={class:"table-export-field"};var g=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:g}){const h=e,y="default",I=u(),{getTableListExportScheme:w}=f(),x={schemeId:y,schemeName:"列表显示字段",fieldKeys:[]},j=i(!1),A=i({schemeId:"",schemeName:"",fieldKeys:[]}),O=i([b(x)]),C=i([]),F=i([]),S=i([]);function M(e){F.value=e}function N(){j.value=!j.value}function P(){g("cancelModal")}function K(e){const i=O.value.find((i=>i.schemeId===e));i&&(A.value=b(i))}function U(e){A.value.fieldKeys=b(e)}function _(e){return e.map((e=>(e.schemeId===y&&(e.fieldKeys=S.value||[]),e)))}async function k(){!function(){var e;C.value=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))})),F.value=b(C.value);let i=C.value.filter((e=>"1"==e.isShow||e.fixedExport));S.value=(null==(e=null==i?void 0:i.map)?void 0:e.call(i,(e=>e.columnName)))||[]}(),await async function(){if(!h.tableListId)return I.warning("请传入列表id");try{let e=await w({id:h.tableListId},h.exportApiConfig);if(e){const{schemes:i=[],lastUsedSchemeName:t=""}=e.obj;if(i&&i.length>0){O.value=_([b(x),...i]);const e=i.find((e=>e.schemeName===t));if(e)return void(A.value=b(e))}O.value=_(b(O.value)),A.value=b(O.value[0])}}catch(e){I.error(`获取导出方案数据请求失败:${e}`)}}()}return t(p,h.exportApiConfig),l((()=>h.visible),(async e=>{e&&await k()}),{immediate:!0}),(i,t)=>(a(),o("div",L,[n(m,{visible:e.visible,tableListId:e.tableListId,curProgram:A.value,programOptions:O.value,downLoadFieldList:C.value,showAllFieldList:F.value,onCancelModal:P,onUpdateCurProgram:K,onUpdateFieldCheckList:U,onUpdateShowAllFieldList:M},{add:s((()=>[n(r(c),{type:"info",onClick:N},{default:s((()=>[d("导出并存为方案")])),_:1})])),_:1},8,["visible","tableListId","curProgram","programOptions","downLoadFieldList","showAllFieldList"]),n(v,{visible:j.value,tableListId:e.tableListId,showAllFieldList:F.value,programOptions:O.value,curProgram:A.value,onCancelSaveModal:N},null,8,["visible","tableListId","showAllFieldList","programOptions","curProgram"])]))}});export{g as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const dragFieldCheckList: (baseList: any[], targetList: string[]) => string[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const c=(c,n)=>{const o=[];return c.map((c=>c.columnName)).forEach((c=>{n.includes(c)&&o.push(c)})),o};export{c as dragFieldCheckList};
|
|
@@ -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{display:flex;flex-direction:column;overflow-y:auto}.table-export-field-modal .n-card__content .tip{margin-bottom:12px}.table-export-field-modal .n-card__content .flex_between{display:flex;justify-content:space-between;margin-bottom:10px}.table-export-field-modal .n-card__content .n-checkbox-group{flex:1;overflow-y:auto}.table-export-field-modal .n-card__content .n-checkbox-group .draggable-checkbox-list{display:flex;flex-wrap:wrap;width:100%}.table-export-field-modal .n-card__content .n-checkbox-group .draggable-checkbox-list .n-checkbox{box-sizing:border-box;display:flex;flex-wrap:nowrap;padding:12px 0;width:20%}.table-export-field-modal .n-card__content .n-checkbox-group .draggable-checkbox-list .n-checkbox .n-checkbox__label{cursor:move;flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.table-export-field-modal .n-card__content .n-checkbox-group .draggable-checkbox-list .n-checkbox.checkbox-disabled .n-checkbox__label{color:rgba(46,46,46,.4)}.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/classify-filter/components/SelectDynamic.vue2.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{defineComponent as e,ref as a,inject as l,computed as t,openBlock as
|
|
1
|
+
import{defineComponent as e,ref as a,inject as l,computed as t,openBlock as n,createBlock as u,unref as o,isRef as i,withModifiers as r,withCtx as s,createVNode as c,h as d}from"vue";import{useMessage as v,NSelect as p,NTag as m}from"naive-ui";import{WidgetOptionEnums as f,WidgetValEnums as y}from"../../../types/enums.js";import{useDebounceFn as g}from"@vueuse/core";import h from"../../../hooks/useAsyncData.js";import{InjectionFilterApiConfig as V,InjectionClassifyFilterList as w}from"../../../constants/index.js";import{judgmentVariable as b}from"../../render-widget/helpers/setDefaultValue.js";import O from"../../render-widget/components/SelectDynamicOption/index.vue.js";import{isEqual as S}from"lodash-es";var k=e({__name:"SelectDynamic",props:{paramCfg:{type:Object,default:null},modelValue:{type:[Array,String,Number],default:null}},emits:["update:modelValue"],setup(e,{emit:k}){const L=e,P=v(),{getDynamicSelectData:j}=h(),C=a(!1),A=l(V),x=l(w),D=a(0),I={class:"select-dynamic-popover"},K=a(1),T=a(),E=a([]),U=a(),_=t((()=>{var e;return null==(e=L.paramCfg)?void 0:e.optionSetting})),M=t((()=>_.value===f.MULTIPLE)),N=t((()=>{const{dynamicOptionInfo:e={}}=L.paramCfg.optionInfo;return e})),$=t((()=>D.value>0&&K.value>=D.value)),F=t((()=>{var e;if(Array.isArray(L.modelValue)&&L.modelValue.length>0){const e=L.modelValue;if(H(e),!M.value&&1==e.length){const a=E.value.find((a=>a.value===e[0]));return JSON.stringify(a)}return E.value.filter((a=>e.includes(a.value)))}return H([]),null!=(e=L.modelValue)?e:null})),J=t((()=>{if(Object.keys(N.value).length>0){const{defaultParams:e=[]}=N.value;return!b(e)}return!0}));function H(e){E.value.forEach((a=>{a.actived=!1,Array.isArray(e)&&e.includes(a.value)&&(a.actived=!0)}))}function W(e){var a;const{defaultValue:l}=L.paramCfg._rawData;(null==(a=null==l?void 0:l.linkageFieldKeys)?void 0:a.length)>0&&l.linkageFieldKeys.forEach((e=>{const a=x.value.find((a=>a.key===e));a&&a.value&&(a.value=a.presetVal=null)})),S(L.modelValue,e)||k("update:modelValue",e)}async function q(e){K.value=e,await z(U.value,K.value)}async function z(e,a){try{if(Object.keys(N.value).length>0){const{autograph:l,dataSourceId:t,dataSourceType:n,filterKeys:u,defaultParams:o=[],showKeys:i,valueKey:r}=N.value;let s={wordbookId:t,autograph:l,wordbookType:n,fieldKeys:u,page:a};u.length>0&&(s[u[0]]=e),C.value=!0;if(b(o)){const e=o.map((e=>e.value)).filter((e=>e.includes("${")));e.map((e=>e.match(/\$\{(.+?)\}/)[1])).forEach((e=>{const a=x.value.find((a=>a.key===e));a&&a.value&&a.value!==y.WHOLE&&(s[e]=a.value)}))}let c=await j(s,A);if(c){const{fieldList:e=[],rows:a=[],total:l=0}=c.map,t=a.map((e=>({...e,label:e[i[0]],value:e[r]})));return T.value=null!=e?e:[],E.value=null!=t?t:[],D.value=l,t}}}catch(e){P.error(`异步数据源下拉框数据请求失败:${e}`),console.log(e)}finally{C.value=!1}}const B=g((async e=>{await async function(e){U.value=e.trim(),K.value=1,await z(U.value,K.value)}(e)}),300);async function G(){Object.keys(N.value).length>0&&A&&await z("",K.value)}async function Q(){k("update:modelValue",null),await G()}function R(e){e&&G()}function X({option:e,handleClose:a}){if(M.value){const l=e.value;return d(m,{style:{padding:"0 8px"},closable:!0,onClose:e=>{if(e.stopPropagation(),a(),Array.isArray(L.modelValue)&&L.modelValue.length>0){const e=L.modelValue,a=e.indexOf(l.value);if(a>-1){const l=e.splice(0,a);k("update:modelValue",l.length>0?l:null)}}}},{default:()=>d("div",l.label)})}const l=e.value?JSON.parse(e.value):{label:""};return d("div",l.label)}return J.value&&G(),(e,a)=>(n(),u(o(p),{id:"select-dynamic-popover",style:{width:"200px"},value:o(F),"onUpdate:value":a[0]||(a[0]=e=>i(F)?F.value=e:null),remote:"",clearable:"",filterable:"",maxTagCount:"responsive",loading:C.value,multiple:o(M),menuProps:I,"render-tag":X,onSearch:o(B),onClear:Q,"onUpdate:show":R,onClick:a[1]||(a[1]=r((()=>{}),["stop"]))},{empty:s((()=>[c(O,{dynamicOptionInfo:o(N),fieldTitleList:T.value,optionList:E.value,isMultiple:o(M),curPage:K.value,isLastPage:o($),onUpdateSelect:W,onUpdatePage:q},null,8,["dynamicOptionInfo","fieldTitleList","optionList","isMultiple","curPage","isLastPage"])])),_:1},8,["value","loading","multiple","onSearch"]))}});export{k 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};
|
|
@@ -36,6 +36,6 @@ export default function useAdvanced(): {
|
|
|
36
36
|
advanceColWidth: number | null | undefined;
|
|
37
37
|
}[];
|
|
38
38
|
getCacheDef: (item: ISearchType, cacheList: string[]) => string | string[];
|
|
39
|
-
transformClassifyChild: (conObjList: any) => {};
|
|
39
|
+
transformClassifyChild: (conObjList: any, searchFieldList: any[]) => {};
|
|
40
40
|
transformParams: (paramsList: any[]) => {};
|
|
41
41
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{WidgetOptionEnums as e,WidgetTypeEnums as i,WidgetValEnums as t}from"../types/enums.js";import{presetValToTimestamp as
|
|
1
|
+
import{WidgetOptionEnums as e,WidgetTypeEnums as i,WidgetValEnums as t}from"../types/enums.js";import{formatDateRangeInfo as n,presetValToTimestamp as l}from"../components/render-widget/helpers/presetValToTimestamp.js";import{DatePresetValEnums as o}from"../components/render-widget/enums.js";const a={[e.RADIO]:"0",[e.MULTIPLE]:"1",[e.ALL]:"0",[e.SELECT_TIME]:"1",[e.PAST_TIME]:"2",[e.FUTURE_TIME]:"3"};function u(){return{transformData:function(t,n){return t.map((t=>{var l,o,u;const{optionInfo:r={list:[],manualMapping:!0,dynamicOptionInfo:{},showWholeOption:!1},type:E,defaultValue:s,optionType:T,filterExplicit:p,rangeFilter:d}=t,c={},m={title:(f=t).title,alias:f.customTitle,isShowSearch:f.isShowSearch?1:0,filterExplicit:f.filterExplicit?1:0,explicitRequired:f.explicitRequired?1:0,advanceOptionSetting:f.optionType?a[f.optionType]:"",placeholder:f.remark,advanceColWidth:f.width};var f;let g,v,y=E;p?(g=E===i.SELECT&&T===e.MULTIPLE?null==s?void 0:s.valueList:null==(l=null==s?void 0:s.valueList)?void 0:l[0],v=null==s?void 0:s.unit,E===i.LABEL&&(y="SELECTLABEL",g=null==s?void 0:s.valueList),E===i.DATE&&(y="DATE_OUT"),E===i.DATE_TIME&&(y="DATETIME_OUT")):E===i.SELECT&&(null==r?void 0:r.list)&&(null==r?void 0:r.list.length)<10&&(y="CHECKBOX_GROUP"),d&&(E===i.INPUT_NUMBER&&(y="INPUTNUMBER_RANGE"),E===i.DATE&&(y=p?"DATE_RANGE_OUT":"DATE_RANGE_INNER"),E===i.DATE_TIME&&(y=p?"DATETIME_RANGE_OUT":"DATETIME_RANGE_INNER")),E===i.SELECT&&!1===(null==r?void 0:r.manualMapping)&&(y=i.SELECTDYNAMIC);const L={isRender:!0,widgetType:y,originType:E,valueList:null==(o=null==r?void 0:r.list)?void 0:o.map((({name:e,value:i})=>({value:i,label:e}))),defaultValue:g,defValueUnit:v,optionSetting:T,multiple:T===e.MULTIPLE||y===i.SELECTLABEL,manualMapping:null==r?void 0:r.manualMapping,showWholeOption:null==r?void 0:r.showWholeOption,dynamicOptionInfo:null==r?void 0:r.dynamicOptionInfo,classifyStr:null==s?void 0:s.classifyStr,linkageFieldKeys:null!=(u=null==s?void 0:s.linkageFieldKeys)?u:[]};return{...m,fieldType:t.dataType,columnName:t.name,settingObj:c,setting:JSON.stringify(c),widgetCfg:L,rangeFilter:d,unit:null!=v?v:"",_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,t){const a={};return e&&e.length>0&&e.forEach((e=>{const u=e.field_key;a[u]="";const r=t.find((e=>e.name===u));if(r){const t=Array.isArray(e.value)&&r.type===i.SELECT?e.value:e.value.toString();if(a[u]=t,e.unit&&e.unit!==o.CUSTOM){let t="";r.type===i.DATE&&(t=r.rangeFilter?n(e.unit,"YYYY-MM-DD",r.optionType):l(e.unit,"YYYY-MM-DD")),r.type===i.DATE_TIME&&(t=r.rangeFilter?n(e.unit,"YYYY-MM-DD HH:mm:ss",r.optionType):l(e.unit,"YYYY-MM-DD HH:mm:ss")),a[u]=t}}})),a},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{u as default};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Ref, ComputedRef } from 'vue';
|
|
2
2
|
import { AnyObject } from '../../../es/shared/types';
|
|
3
|
-
export declare function useDateTime(datePickerRef: Ref<AnyObject | null>, formatRef: ComputedRef<string | [string, string]>, attrs: AnyObject): {
|
|
3
|
+
export declare function useDateTime(datePickerRef: Ref<AnyObject | null>, formatRef: ComputedRef<string | [string, string]>, attrs: AnyObject, isPanel?: boolean): {
|
|
4
4
|
focus: () => any;
|
|
5
5
|
blur: () => any;
|
|
6
6
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{computed as e,unref as t}from"vue";import{useDebounceFn as n,useEventListener as l}from"@vueuse/core";import{isValid as i}from"date-fns";function o(o,s,u){const
|
|
1
|
+
import{computed as e,unref as t}from"vue";import{useDebounceFn as n,useEventListener as l}from"@vueuse/core";import{isValid as i}from"date-fns";function o(o,s,u,r){const c=n((e=>{!function(e){const t=e.target;if(["INPUT"].includes(t.tagName)){const{selectionStart:e=0,selectionEnd:n=0}=t;e===n&&t.select()}}(e)}),200),a=e((()=>{var e;return null==(e=o.value)?void 0:e.$el})),d=e((()=>{const e={};return["date","time","hour","minute","second"].forEach((t=>function(e,t){const n=`is-${t}-disabled`;u[n]&&(e[n.replace(/-(\w)/g,((e,t)=>t.toUpperCase()))]=u[n])}(e,t))),e}));function f(e,t=""){e.value=t,e.dispatchEvent(new InputEvent("input"))}function v(e,n,l){const i=e.value;if(!i)return;const o=e.selectionEnd||0,u=i.length;let r=0,c=0,a=0,d="",v=0;for(;r<u;){const e=i[r++];if(/\d/.test(e)&&(d+=e),r===o){a=d.length;const e=i.slice(r).match(/^\d+/);v=e?e[0].length:0}}const g=t(s),m=Array.isArray(g)?function(e){var t,n;let l=!1,i=e.parentNode||null;for(;i;){if(null==(n=null==(t=i.classList)?void 0:t.contains)?void 0:n.call(t,"n-time-picker")){l=!0;break}i=i.parentNode||null}return l}(e)?g[1]:g[0]:g;let h="",p=0,b=0;for(r=0;r<m.length&&(l||!(c>=d.length));){const e=m[r++];if(/[yMdHms]/.test(e)?h+=d[c++]||"0":h+=e,n&&c===a){a=-1,p=h.length,b=p;let e=m.slice(r).match(/^[yMdHms]+/);e?(v=Math.min(v,e[0].length),v&&(h+=d.slice(c,c+v),c+=v),r+=e[0].length):(e=m.slice(r).match(/^([^yMdHms]+)([yMdHms]*)/),e&&(p+=e[1].length,b=p+e[2].length))}}const D=h!==i;return D&&f(e,h),n&&(p=p||h.length+1,b=b||h.length+1,e.setSelectionRange(p,b)),D}return l(a,"input",(function(e){const t=e.target;if(!t.value||!Reflect.get(t,"_f_"))return;Reflect.set(t,"_f_",0),v(t,!0)&&(e.preventDefault(),e.stopPropagation())}),!0),l(a,"keydown",(function(e){const{key:t}=e,n=e.target;if(/\d/.test(t)&&n)Reflect.set(n,"_f_",1);else if("Enter"===t){v(n,!1,!0);const e=null==n?void 0:n.value,t=Reflect.get(u,"type")||"";e&&!t.includes("range")&&i(new Date(e))&&!function(e){const{isTimeDisabled:t,isDateDisabled:n,isHourDisabled:l,isMinuteDisabled:i,isSecondDisabled:o}=d.value;if(null==n?void 0:n(e.getTime()))return;const s=(null==t?void 0:t(e.getTime()).isHourDisabled)||l,u=(null==t?void 0:t(e.getTime()).isMinuteDisabled)||i,r=(null==t?void 0:t(e.getTime()).isSecondDisabled)||o;if(null==s?void 0:s(e.getHours()))return;if(null==u?void 0:u(e.getMinutes()))return;if(null==r?void 0:r(e.getMinutes()))return;return!0}(new Date(e))&&f(n)}else if("Backspace"===t&&!r){const e=null==n?void 0:n.value;1===(null==e?void 0:e.length)&&(f(n),n.blur(),n.focus())}}),!0),l(a,"click",c,!0),{focus:()=>{var e,t;return null==(t=null==(e=o.value)?void 0:e.focus)?void 0:t.call(e)},blur:()=>{var e,t;return null==(t=null==(e=o.value)?void 0:e.blur)?void 0:t.call(e)}}}export{o as useDateTime};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e="@cnhis-design-vue/shared",i="3.1.46-beta.
|
|
1
|
+
var e="@cnhis-design-vue/shared",i="3.1.46-beta.30",s="index.ts",n={"naive-ui":"^2.30.0",vue:"^3.2.0"},a={"@vicons/ionicons5":"^0.12.0","lodash-es":"^4.17.21",moment:"^2.29.1","video.js":"^7.19.2","videojs-contrib-hls":"^5.15.0",viewerjs:"^1.10.5","xe-utils":"^3.5.4"},d={name:e,version:"3.1.46-beta.30",private:!0,main:"index.ts",peerDependencies:n,dependencies:a};export{d as default,a as dependencies,s as main,e as name,n as peerDependencies,i as version};
|
|
@@ -14,3 +14,9 @@ export declare type BindEventSettingItem = {
|
|
|
14
14
|
}[];
|
|
15
15
|
[K: string]: unknown;
|
|
16
16
|
};
|
|
17
|
+
export declare type FormOperationalConfig = {
|
|
18
|
+
operationFormParam: string[];
|
|
19
|
+
operationalRule: string;
|
|
20
|
+
operationalPrecision: string;
|
|
21
|
+
operationalResult: string;
|
|
22
|
+
};
|
|
@@ -20,3 +20,4 @@ export declare type TupleToUnion<T extends readonly unknown[]> = T[number];
|
|
|
20
20
|
declare type UnionToIntersection<T> = (T extends T ? (params: T) => any : never) extends (P: infer R) => any ? R : never;
|
|
21
21
|
export declare type UnionToTuple<T, Result extends unknown[] = []> = UnionToIntersection<T extends any ? () => T : never> extends () => infer Return ? UnionToTuple<Exclude<T, Return>, [Return, ...Result]> : Result;
|
|
22
22
|
export declare type MaybeString<T extends string | number> = T | `${T}`;
|
|
23
|
+
export declare type GetFn<T> = T extends (...args: any[]) => any ? T : never;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { BindEventSettingItem, LOW_CODE_EVENT_TYPE, LOW_CODE_VALUE_RELATION } from '../../../es/shared/types';
|
|
1
|
+
import { BindEventSettingItem, FormOperationalConfig, LOW_CODE_EVENT_TYPE, LOW_CODE_VALUE_RELATION } from '../../../es/shared/types';
|
|
2
|
+
import { MaybeRef } from '@vueuse/core';
|
|
2
3
|
export declare function isMatchLowCodeCondition(value: unknown, condition: {
|
|
3
4
|
con: LOW_CODE_VALUE_RELATION;
|
|
4
5
|
value: unknown;
|
|
@@ -8,4 +9,8 @@ declare function handleFieldTriggerSetValue(bindEventSetting: BindEventSettingIt
|
|
|
8
9
|
getter: (key: string) => unknown;
|
|
9
10
|
}): void;
|
|
10
11
|
export declare function getBindEventSettingTrigger(key: LOW_CODE_EVENT_TYPE): typeof handleFieldTriggerSetValue;
|
|
12
|
+
export declare function getOperationalFormHandler(operationalForm: MaybeRef<FormOperationalConfig[] | undefined>, getter: (field: string) => unknown, setter: (field: string, value: unknown) => void): {
|
|
13
|
+
operationalFormHandler: (field: string) => void;
|
|
14
|
+
triggerAllOperationalFormHandler: () => void;
|
|
15
|
+
};
|
|
11
16
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{isArray as e,isString as
|
|
1
|
+
import{isArray as e,isString as n,includes as r,isEmpty as t,negate as o,gt as a,gte as l,lt as i,lte as u,noop as c,isObject as p,isNumber as f}from"lodash-es";import{unref as s}from"vue";const E={EQ:(e,n)=>`${e}`===n,NEQ:(e,n)=>`${e}`!==n,CL:(t,o)=>!(!e(t)&&!n(t))&&r(t,o),NC:(t,o)=>!e(t)&&!n(t)||!r(t,o),NULL:t,NOT_NULL:o(t),BIG:a,BIGEQ:l,LESS:i,LESSEQ:u};function m(e,n){return(E[n.con]||(()=>!1))(e,`${n.value}`)}const L=Object.freeze({SET_VALUE:function(e,{getter:n,setter:r}){if(!p(e))return;const{results:t=[],params:o=[]}=e;if(!t.length)return;o.every((e=>e&&e.p_name&&m(n(e.p_name),{con:e.p_select,value:e.p_value})))&&t.forEach((e=>r(e.p_name,e.p_value)))},REPEAT_VALIDATE:c,IS_SHOW_FIELD:c,SQLSAVE:c,API:c});function _(e){return L[e]||c}function S(r,t,o){function a(n){return e(n)&&!!n.length}function l(e,r=!0){e.forEach((e=>{const a=e.operationFormParam.reduce(((e,n)=>(e[n=n.replace(/^table\./,"")]=+t(n),e)),{}),l=e.operationalRule.replace(/\${(.+?)}/g,"$1");let i=new Function("table",`return ${l}`)(a);n(i)&&(i=+i),i=f(i)?isNaN(i)?"":i.toFixed(+e.operationalPrecision):"",(r||null==t(e.operationalResult))&&o(e.operationalResult,i)}))}return{operationalFormHandler:function(e){if(!a(s(r)))return;const n=s(r).filter((n=>n.operationFormParam.includes(`table.${e}`)));n.length&&l(n)},triggerAllOperationalFormHandler:function(){a(s(r))&&l(s(r),!1)}}}export{_ as getBindEventSettingTrigger,S as getOperationalFormHandler,m as isMatchLowCodeCondition};
|