cnhis-design-vue 3.3.3-beta.7 → 3.3.3-beta.72
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/audio-sdk/index.d.ts +18 -16
- package/es/components/audio-sdk/src/Index.vue.d.ts +18 -16
- package/es/components/audio-sdk/src/Index.vue2.js +40 -5
- package/es/components/audio-sdk/src/components/recording-modal.vue.d.ts +6 -6
- package/es/components/audio-sdk/src/components/recording.vue.d.ts +6 -6
- package/es/components/audio-sdk/src/components/recording.vue2.js +17 -3
- package/es/components/base-search/index.d.ts +3 -0
- package/es/components/base-search/src/index.vue.d.ts +3 -0
- package/es/components/big-table/src/components/NoData.vue2.js +8 -1
- package/es/components/big-table/src/hooks/useTableParse.js +8 -1
- package/es/components/button-print/index.d.ts +67 -2
- package/es/components/button-print/src/ButtonPrint.vue.d.ts +67 -2
- package/es/components/button-print/src/ButtonPrint.vue2.js +6 -0
- package/es/components/button-print/src/components/NewPrintComponent.vue.d.ts +28 -3
- package/es/components/button-print/src/components/NewPrintComponent.vue2.js +138 -15
- package/es/components/button-print/src/components/OldPrintComponent.vue.d.ts +18 -0
- package/es/components/button-print/src/components/OldPrintComponent.vue2.js +35 -6
- package/es/components/button-print/src/utils/print.d.ts +7 -5
- package/es/components/button-print/src/utils/print.js +183 -7
- package/es/components/button-print/style/index.css +1 -1
- package/es/components/calendar/src/Calendar.vue2.js +15 -5
- package/es/components/callback/src/components/render/popupMaps.d.ts +18 -0
- package/es/components/card-reader-sdk-cn/src/henan/index.js +8 -1
- package/es/components/classification/index.d.ts +555 -10
- package/es/components/classification/src/components/search-filter/index.vue.d.ts +555 -10
- package/es/components/classification/src/components/set-classification/index.vue.d.ts +555 -10
- package/es/components/classification/src/components/table-modal/index.vue.d.ts +0 -3
- package/es/components/classification/src/index.vue.d.ts +555 -10
- package/es/components/date-picker/src/DatePicker.vue2.js +8 -1
- package/es/components/expand-field/index.d.ts +792 -1
- package/es/components/expand-field/src/components/FormItemPerson.vue.d.ts +792 -1
- package/es/components/expand-field/src/components/PersonModal.vue.d.ts +792 -1
- package/es/components/expand-field/src/components/form.vue.d.ts +792 -1
- package/es/components/expand-field/src/components/form.vue2.js +8 -1
- package/es/components/expand-field/src/index.vue.d.ts +792 -1
- package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcess.js +3 -1
- package/es/components/fabric-chart/src/hooks/temperature/useLeft.js +3 -2
- package/es/components/fabric-chart/src/hooks/temperature/useOther.d.ts +1 -1
- package/es/components/fabric-chart/src/hooks/temperature/useOther.js +58 -15
- package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.js +4 -3
- package/es/components/field-editor/index.d.ts +18 -0
- package/es/components/field-editor/src/FieldEditor.vue.d.ts +18 -0
- package/es/components/field-editor/src/FieldEditor.vue2.js +2 -1
- package/es/components/field-editor/src/fields.d.ts +1 -0
- package/es/components/field-editor/src/fields.js +6 -0
- package/es/components/field-set/src/FieldColor.vue.d.ts +10 -5
- package/es/components/field-set/src/FieldFilter.vue.d.ts +10 -5
- package/es/components/field-set/src/FieldSet.vue.d.ts +43 -6
- package/es/components/field-set/src/FieldSet.vue2.js +118 -69
- package/es/components/field-set/src/Index.vue2.js +8 -3
- package/es/components/field-set/src/TableStyle.vue2.js +2 -2
- package/es/components/field-set/src/components/table-row.vue.d.ts +6 -5
- package/es/components/field-set/src/components/table-row.vue2.js +21 -6
- package/es/components/field-set/src/constants/index.d.ts +1 -1
- package/es/components/field-set/src/types/index.d.ts +3 -1
- package/es/components/field-set/style/index.css +1 -1
- package/es/components/form-config/index.d.ts +102 -0
- package/es/components/form-config/src/FormConfig.vue.d.ts +102 -0
- package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +18 -0
- package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +63 -0
- package/es/components/form-config/src/components/FormConfigEdit.vue2.js +4 -4
- package/es/components/form-config/src/components/FormConfigEventSetting.vue.d.ts +18 -0
- package/es/components/form-config/src/components/FormConfigEventSetting.vue2.js +9 -2
- package/es/components/form-config/src/constants/index.d.ts +31 -1
- package/es/components/form-config/src/constants/index.js +150 -1
- package/es/components/form-config/src/hooks/useConfigurationField.d.ts +2 -2
- package/es/components/form-config/src/hooks/useConfigurationField.js +53 -6
- package/es/components/form-config/src/hooks/useLocale.d.ts +6 -0
- package/es/components/form-config/src/hooks/useLocale.js +34 -0
- package/es/components/form-config/src/types/index.d.ts +12 -0
- package/es/components/form-render/index.d.ts +18 -0
- package/es/components/form-render/src/FormRender.vue.d.ts +18 -0
- package/es/components/form-render/src/FormRender.vue2.js +5 -0
- package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +18 -0
- package/es/components/form-render/src/components/renderer/date.d.ts +3 -1
- package/es/components/form-render/src/components/renderer/date.js +12 -10
- package/es/components/form-render/src/components/renderer/formItem.d.ts +2 -0
- package/es/components/form-render/src/components/renderer/formItem.js +17 -3
- package/es/components/form-render/src/components/renderer/levelSearchCascader/index.js +4 -2
- package/es/components/form-render/src/components/renderer/lineBar/FormCollapse.vue.d.ts +1 -0
- package/es/components/form-render/src/components/renderer/lineBar/index.d.ts +1 -0
- package/es/components/form-render/src/components/renderer/radio_checkbox.js +9 -3
- package/es/components/form-render/src/components/renderer/searchCascade.js +3 -0
- package/es/components/form-render/src/hooks/useBusinessBinding.d.ts +12 -3
- package/es/components/form-render/src/hooks/useBusinessBinding.js +7 -7
- package/es/components/form-render/src/hooks/useFieldListAdaptor.js +5 -2
- package/es/components/form-render/src/hooks/useFieldNormalize.d.ts +2 -0
- package/es/components/form-render/src/hooks/useFieldNormalize.js +15 -0
- package/es/components/form-render/src/hooks/useFormContext.js +1 -1
- package/es/components/form-render/src/hooks/useFormValidator.js +8 -1
- package/es/components/form-render/src/hooks/useLowCodeReactions.js +2 -1
- package/es/components/form-render/src/types/index.d.ts +1 -0
- package/es/components/form-render/src/utils/business.d.ts +3 -1
- package/es/components/form-render/src/utils/business.js +7 -1
- package/es/components/form-render/style/index.css +1 -1
- package/es/components/iho-chat/index.d.ts +902 -99
- package/es/components/iho-chat/src/Index.vue.d.ts +902 -99
- package/es/components/iho-chat/src/components/ChatAdd.vue.d.ts +24 -1
- package/es/components/iho-chat/src/components/ChatFile.vue.d.ts +181 -8
- package/es/components/iho-chat/src/components/ChatFile.vue2.js +51 -41
- package/es/components/iho-chat/src/components/ChatFooter.vue.d.ts +66 -6
- package/es/components/iho-chat/src/components/ChatFooter.vue2.js +158 -57
- package/es/components/iho-chat/src/components/ChatHeader.vue.d.ts +329 -15
- package/es/components/iho-chat/src/components/ChatHeader.vue2.js +21 -19
- package/es/components/iho-chat/src/components/ChatMain.vue.d.ts +235 -20
- package/es/components/iho-chat/src/components/ChatMain.vue2.js +298 -279
- package/es/components/iho-chat/src/components/ChatRecord.vue.d.ts +51 -5
- package/es/components/iho-chat/src/components/ChatRecord.vue2.js +3 -3
- package/es/components/iho-chat/src/components/ChatSearch.vue.d.ts +24 -1
- package/es/components/iho-chat/src/components/ChatSet.vue.d.ts +48 -2
- package/es/components/iho-chat/src/components/ContextMenu.js +34 -27
- package/es/components/iho-chat/src/components/ImageLightbox.vue.d.ts +104 -0
- package/es/components/iho-chat/src/components/ImageLightbox.vue.js +6 -0
- package/es/components/iho-chat/src/components/ImageLightbox.vue2.js +307 -0
- package/es/components/iho-chat/src/components/MessageEvent.vue.d.ts +24 -1
- package/es/components/iho-chat/src/components/MessageMergeForward.vue.d.ts +53 -6
- package/es/components/iho-chat/src/components/MessageMergeForward.vue2.js +3 -3
- package/es/components/iho-chat/src/components/MultipleVideo.vue.d.ts +93 -30
- package/es/components/iho-chat/src/components/MultipleVideo.vue2.js +348 -144
- package/es/components/iho-chat/src/components/PersonProfile.vue.d.ts +24 -1
- package/es/components/iho-chat/src/components/PersonProfile.vue2.js +1 -1
- package/es/components/iho-chat/src/components/SelectLabel.vue.d.ts +1 -1
- package/es/components/iho-chat/src/components/SiderList.vue.d.ts +24 -1
- package/es/components/iho-chat/src/components/Video.vue.d.ts +38 -25
- package/es/components/iho-chat/src/components/Video.vue2.js +35 -40
- package/es/components/iho-chat/src/hooks/index.d.ts +1 -0
- package/es/components/iho-chat/src/hooks/index.js +1 -0
- package/es/components/iho-chat/src/hooks/useData.d.ts +51 -4
- package/es/components/iho-chat/src/hooks/useData.js +2 -7
- package/es/components/iho-chat/src/hooks/useDraggable.d.ts +25 -0
- package/es/components/iho-chat/src/hooks/useDraggable.js +160 -0
- package/es/components/iho-chat/src/hooks/useVideo.d.ts +78 -11
- package/es/components/iho-chat/src/hooks/useVideo.js +420 -44
- package/es/components/iho-chat/src/types/index.d.ts +37 -1
- package/es/components/iho-chat/src/utils/emoji.d.ts +1 -1
- package/es/components/iho-chat/src/utils/emoji.js +1 -1
- package/es/components/iho-chat/src/utils/index.d.ts +4 -3
- package/es/components/iho-chat/src/utils/index.js +33 -39
- package/es/components/iho-chat/style/index.css +1 -1
- package/es/components/iho-table/src/plugins/filterRenderPlugin/filter.vue2.js +8 -1
- package/es/components/iho-table/src/plugins/headerPlugin/index.js +5 -2
- package/es/components/iho-table/src/plugins/highLightSetPlugin.js +2 -1
- package/es/components/index.css +1 -1
- package/es/components/index.d.ts +2 -0
- package/es/components/index.js +2 -1
- package/es/components/info-header/index.d.ts +41 -0
- package/es/components/info-header/src/InfoHeader.vue.d.ts +41 -0
- package/es/components/info-header/src/components/infoDescription/DescriptionItem.vue.d.ts +1 -0
- package/es/components/info-header/src/components/infoDescription/DescriptionItem.vue2.js +56 -22
- package/es/components/info-header/src/components/infoDescription/DescriptionList.vue.d.ts +1 -0
- package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +19 -0
- package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +18 -0
- package/es/components/info-header/src/components/patientInfo/index.vue2.js +16 -2
- package/es/components/keyboard/index.d.ts +9 -0
- package/es/components/keyboard/src/Keyboard.vue.d.ts +9 -0
- package/es/components/keyboard/src/Keyboard.vue2.js +33 -9
- package/es/components/keyboard/src/components/NumberPanel.vue.d.ts +4 -0
- package/es/components/keyboard/src/components/NumberPanel.vue2.js +50 -17
- package/es/components/keyboard/src/types.d.ts +17 -0
- package/es/components/keyboard/src/types.js +1 -0
- package/es/components/quick-search/index.d.ts +2 -0
- package/es/components/quick-search/src/index.vue.d.ts +2 -0
- package/es/components/scale-view/index.d.ts +66 -3
- package/es/components/scale-view/src/ScaleView.vue.d.ts +69 -5
- package/es/components/scale-view/src/ScaleView.vue2.js +79 -4
- package/es/components/scale-view/src/components/AnswerParse.vue.d.ts +5 -0
- package/es/components/scale-view/src/components/AnswerParse.vue2.js +74 -8
- package/es/components/scale-view/src/components/EvaluateCountdown.vue.d.ts +3 -0
- package/es/components/scale-view/src/components/EvaluateCountdown.vue2.js +26 -2
- package/es/components/scale-view/src/components/EvaluatePage.vue.d.ts +3 -0
- package/es/components/scale-view/src/components/EvaluatePage.vue2.js +27 -6
- package/es/components/scale-view/src/components/NoData.vue2.js +9 -3
- package/es/components/scale-view/src/components/ScaleScore.d.ts +1 -1
- package/es/components/scale-view/src/components/ScaleScore.js +45 -3
- package/es/components/scale-view/src/components/formitem/r-checkbox.js +16 -2
- package/es/components/scale-view/src/components/formitem/r-sign.js +32 -4
- package/es/components/scale-view/src/components/formitem/r-upload.js +65 -7
- package/es/components/scale-view/src/components/formitem/sign-com.js +8 -1
- package/es/components/scale-view/src/hooks/scaleview-computed.js +20 -4
- package/es/components/scale-view/src/hooks/scaleview-init.js +24 -3
- package/es/components/scale-view/src/hooks/scaleview-methods.js +40 -5
- package/es/components/scale-view/src/hooks/scaleview-props.d.ts +12 -0
- package/es/components/scale-view/src/hooks/scaleview-props.js +12 -0
- package/es/components/scale-view/src/hooks/scaleview-submit.d.ts +2 -1
- package/es/components/scale-view/src/hooks/scaleview-submit.js +64 -8
- package/es/components/scale-view/src/hooks/scaleview-validate.d.ts +1 -1
- package/es/components/scale-view/src/hooks/scaleview-validate.js +157 -24
- package/es/components/scale-view/src/hooks/use-evaluate.js +16 -2
- package/es/components/scale-view/src/hooks/use-noData.js +33 -5
- package/es/components/scale-view/src/utils/judge-types.d.ts +2 -1
- package/es/components/scale-view/src/utils/judge-types.js +10 -10
- package/es/components/scale-view/src/utils/watch-form-change.d.ts +13 -0
- package/es/components/scale-view/src/utils/watch-form-change.js +71 -0
- package/es/components/select-person/index.d.ts +792 -1
- package/es/components/select-person/src/SelectPerson.vue.d.ts +433 -273
- package/es/components/select-person/src/SelectPerson.vue.js +6 -0
- package/es/components/select-person/src/SelectPerson.vue2.js +795 -0
- package/es/components/select-person/src/SelectPersonRole.vue.js +2 -2
- package/es/components/select-person/src/components/GroupItem.vue.d.ts +19 -0
- package/es/components/select-person/src/components/GroupItem.vue.js +6 -0
- package/es/components/select-person/src/components/GroupItem.vue2.js +37 -0
- package/es/components/select-person/src/components/SearchGroupList.vue.d.ts +214 -0
- package/es/components/select-person/src/components/SearchGroupList.vue.js +6 -0
- package/es/components/select-person/src/components/SearchGroupList.vue2.js +145 -0
- package/es/components/select-person/src/components/SearchMultiple.vue2.js +1 -1
- package/es/components/select-person/src/components/SearchOrgAndStaff.vue2.js +21 -12
- package/es/components/select-person/src/components/TagItem.vue.d.ts +43 -0
- package/es/components/select-person/src/components/TagItem.vue.js +6 -0
- package/es/components/select-person/src/components/TagItem.vue2.js +40 -0
- package/es/components/select-person/src/index.vue.d.ts +793 -1
- package/es/components/select-person/src/index.vue2.js +21 -4
- package/es/components/select-person/src/types/index.d.ts +35 -0
- package/es/components/select-person/src/types/index.js +1 -0
- package/es/components/select-person/src/utils/index.d.ts +3 -0
- package/es/components/select-person/src/utils/index.js +25 -2
- package/es/components/select-person/style/index.css +1 -1
- package/es/components/shortcut-setter/index.d.ts +18 -0
- package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +18 -0
- package/es/components/table-filter/index.js +1 -1
- package/es/components/table-filter/src/components/bi-filter/ValueCfg.vue.d.ts +1 -0
- package/es/components/table-filter/src/components/bi-filter/components/SelectFilter.vue.d.ts +1 -0
- package/es/components/table-filter/src/components/bi-filter/components/index.d.ts +1 -0
- package/es/components/table-filter/src/components/bi-filter/index.vue.d.ts +1 -0
- package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.d.ts +543 -6
- package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue2.js +32 -10
- package/es/components/table-filter/src/components/classify-filter/components/Base/DateOption.vue.d.ts +226 -0
- package/es/components/table-filter/src/components/classify-filter/components/Base/DateOption.vue.js +6 -0
- package/es/components/table-filter/src/components/classify-filter/components/Base/DateOption.vue2.js +156 -0
- package/es/components/table-filter/src/components/classify-filter/components/Date.vue.d.ts +255 -2
- package/es/components/table-filter/src/components/classify-filter/components/Date.vue2.js +79 -5
- package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue.d.ts +256 -2
- package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue2.js +92 -6
- package/es/components/table-filter/src/components/classify-filter/components/SelectFilter.vue.d.ts +1 -0
- package/es/components/table-filter/src/components/classify-filter/components/index.d.ts +512 -4
- package/es/components/table-filter/src/components/classify-filter/helpers/options.d.ts +5 -1
- package/es/components/table-filter/src/components/classify-filter/helpers/options.js +49 -2
- package/es/components/table-filter/src/components/classify-filter/hooks/useFilterConditions.js +2 -1
- package/es/components/table-filter/src/components/classify-filter/index.vue.d.ts +554 -10
- package/es/components/table-filter/src/components/classify-filter/index.vue2.js +17 -7
- package/es/components/table-filter/src/components/render-widget/components/DateInner.vue.d.ts +2 -2
- package/es/components/table-filter/src/components/render-widget/components/DateOut.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/render-widget/components/DateOut.vue2.js +12 -1
- package/es/components/table-filter/src/components/render-widget/components/DateQuickBtn/index.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/render-widget/components/DateQuickBtn/index.vue2.js +25 -6
- package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue.d.ts +2 -2
- package/es/components/table-filter/src/components/render-widget/components/DateRangeOut.vue2.js +12 -1
- package/es/components/table-filter/src/components/render-widget/components/index.d.ts +5 -5
- package/es/components/table-filter/src/components/render-widget/helpers/dateExtraMap.js +32 -4
- package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.d.ts +1 -0
- package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.js +23 -2
- package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +5 -5
- package/es/components/table-filter/src/hooks/useAdvanced.d.ts +2 -0
- package/es/components/table-filter/src/hooks/useAdvanced.js +25 -7
- package/es/components/table-filter/src/hooks/useRenderWidget.js +4 -0
- package/es/components/table-filter/src/tool/baseOptions.js +8 -1
- package/es/components/table-filter/src/tool/date.d.ts +3 -0
- package/es/components/table-filter/src/tool/date.js +139 -0
- package/es/components/table-filter/src/tool/transformData.d.ts +1 -0
- package/es/components/table-filter/src/tool/transformData.js +11 -8
- package/es/components/table-filter/src/types/enums.d.ts +5 -0
- package/es/components/table-filter/src/types/enums.js +7 -2
- package/es/components/table-filter/src/types/index.d.ts +12 -0
- package/es/components/vertify/index.d.ts +1 -0
- package/es/components/vertify/index.js +1 -0
- package/es/components/vertify/src/components/IdentityVerification.vue.d.ts +89 -0
- package/es/components/vertify/src/components/IdentityVerification.vue.js +6 -0
- package/es/components/vertify/src/components/IdentityVerification.vue2.js +256 -0
- package/es/components/vertify/src/utils/dialog.d.ts +7 -0
- package/es/components/vertify/src/utils/dialog.js +73 -0
- package/es/components/vertify/src/utils/index.d.ts +11 -0
- package/es/components/vertify/src/utils/index.js +24 -0
- package/es/components/vod-chunk-upload/index.d.ts +16 -0
- package/es/components/vod-chunk-upload/src/chunk-upload-new.vue.d.ts +20 -31
- package/es/components/vod-chunk-upload/src/chunk-upload-new.vue2.js +205 -78
- package/es/components/vod-chunk-upload/src/hooks/upload-computed.d.ts +1 -0
- package/es/components/vod-chunk-upload/src/hooks/upload-computed.js +35 -4
- package/es/components/vod-chunk-upload/src/hooks/upload-data.d.ts +4 -0
- package/es/components/vod-chunk-upload/src/hooks/upload-data.js +78 -11
- package/es/components/vod-chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue.d.ts +16 -0
- package/es/components/vod-chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue2.js +81 -10
- package/es/components/vod-chunk-upload/style/index.css +1 -1
- package/es/env.d.ts +25 -25
- package/es/shared/assets/img/defaultCover/10review_successful.png.js +1 -1
- package/es/shared/assets/img/defaultCover/11review_fail.png.js +1 -1
- package/es/shared/assets/img/defaultCover/12no_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/13no_menu_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/14no_call_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/15no_use_tag.png.js +1 -1
- package/es/shared/assets/img/defaultCover/16no_table_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/1location.png.js +1 -1
- package/es/shared/assets/img/defaultCover/2notfound.png.js +1 -1
- package/es/shared/assets/img/defaultCover/3loading.png.js +1 -1
- package/es/shared/assets/img/defaultCover/4no_permission.png.js +1 -1
- package/es/shared/assets/img/defaultCover/5no_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/6no_network.png.js +1 -1
- package/es/shared/assets/img/defaultCover/7no_doctor.png.js +1 -1
- package/es/shared/assets/img/defaultCover/8system_error.png.js +1 -1
- package/es/shared/assets/img/defaultCover/9system_upgrade.png.js +1 -1
- package/es/shared/components/InputNumberSlash/InputNumberSlash.js +1 -1
- package/es/shared/hooks/selectHooks/useSearchContent.js +1 -1
- package/es/shared/hooks/useDateTime.js +1 -1
- package/es/shared/hooks/useLevelSearchCascader.js +3 -3
- package/es/shared/package.json.js +2 -2
- package/es/shared/utils/fabricjs/index.js +1 -1
- package/package.json +6 -5
@@ -0,0 +1,139 @@
|
|
1
|
+
import moment from 'moment';
|
2
|
+
|
3
|
+
function parseExpressions(expressions, format) {
|
4
|
+
if (!expressions || !Array.isArray(expressions)) {
|
5
|
+
console.warn("parseExpressions: \u8F93\u5165\u4E0D\u662F\u6570\u7EC4\uFF0C\u8FD4\u56DE\u7A7A\u503C");
|
6
|
+
return null;
|
7
|
+
}
|
8
|
+
return expressions.map((expr, index) => {
|
9
|
+
try {
|
10
|
+
if (expr === null || expr === void 0 || expr === "") {
|
11
|
+
console.warn(`parseExpressions: \u7D22\u5F15 ${index} \u7684\u8868\u8FBE\u5F0F\u4E3A\u7A7A\uFF0C\u8DF3\u8FC7`);
|
12
|
+
return null;
|
13
|
+
}
|
14
|
+
const exprStr = String(expr).trim();
|
15
|
+
const dateTimestamp = parseDateString(exprStr);
|
16
|
+
if (dateTimestamp !== null) {
|
17
|
+
return moment(Math.floor(dateTimestamp)).format(format);
|
18
|
+
}
|
19
|
+
const result = safeEval(exprStr);
|
20
|
+
if (!result)
|
21
|
+
return null;
|
22
|
+
if (typeof result === "number" && !isNaN(result)) {
|
23
|
+
return moment(Math.floor(result)).format(format);
|
24
|
+
} else {
|
25
|
+
console.warn(`parseExpressions: \u7D22\u5F15 ${index} \u7684\u8868\u8FBE\u5F0F "${exprStr}" \u6267\u884C\u7ED3\u679C\u4E0D\u662F\u6709\u6548\u6570\u5B57`);
|
26
|
+
return null;
|
27
|
+
}
|
28
|
+
} catch (error) {
|
29
|
+
console.error(`parseExpressions: \u89E3\u6790\u7D22\u5F15 ${index} \u7684\u8868\u8FBE\u5F0F\u65F6\u51FA\u9519:`, error == null ? void 0 : error.message);
|
30
|
+
return null;
|
31
|
+
}
|
32
|
+
}).filter(Boolean);
|
33
|
+
}
|
34
|
+
function isEffectiveTime(timestamp) {
|
35
|
+
return timestamp >= -22089888e5 && timestamp < 41024448e5;
|
36
|
+
}
|
37
|
+
function parseDateString(dateStr) {
|
38
|
+
if (/^\d+$/.test(dateStr)) {
|
39
|
+
const timestamp = parseInt(dateStr, 10);
|
40
|
+
return isEffectiveTime(timestamp) ? timestamp : null;
|
41
|
+
}
|
42
|
+
const datePatterns = [
|
43
|
+
/^(\d{4})-(\d{1,2})-(\d{1,2})\s+(\d{1,2}):(\d{1,2}):(\d{1,2})$/,
|
44
|
+
/^(\d{4})-(\d{1,2})-(\d{1,2})\s+(\d{1,2}):(\d{1,2})$/,
|
45
|
+
/^(\d{4})-(\d{1,2})-(\d{1,2})$/,
|
46
|
+
/^(\d{4})-(\d{1,2})$/,
|
47
|
+
/^(\d{4})$/,
|
48
|
+
/^(\d{1,2}):(\d{1,2}):(\d{1,2})$/,
|
49
|
+
/^(\d{1,2}):(\d{1,2})$/
|
50
|
+
];
|
51
|
+
for (let i = 0; i < datePatterns.length; i++) {
|
52
|
+
const pattern = datePatterns[i];
|
53
|
+
const match = dateStr.match(pattern);
|
54
|
+
if (match) {
|
55
|
+
let year, month, day, hour, minute, second;
|
56
|
+
if (i <= 4) {
|
57
|
+
year = parseInt(match[1], 10);
|
58
|
+
month = match[2] ? parseInt(match[2], 10) : 1;
|
59
|
+
day = match[3] ? parseInt(match[3], 10) : 1;
|
60
|
+
hour = match[4] ? parseInt(match[4], 10) : 0;
|
61
|
+
minute = match[5] ? parseInt(match[5], 10) : 0;
|
62
|
+
second = match[6] ? parseInt(match[6], 10) : 0;
|
63
|
+
} else {
|
64
|
+
const now = new Date();
|
65
|
+
year = now.getFullYear();
|
66
|
+
month = now.getMonth() + 1;
|
67
|
+
day = now.getDate();
|
68
|
+
hour = parseInt(match[1], 10);
|
69
|
+
minute = parseInt(match[2], 10);
|
70
|
+
second = match[3] ? parseInt(match[3], 10) : 0;
|
71
|
+
}
|
72
|
+
if (year < 1900 || year > 2100 || month < 1 || month > 12 || day < 1 || day > 31 || hour < 0 || hour > 23 || minute < 0 || minute > 59 || second < 0 || second > 59) {
|
73
|
+
return null;
|
74
|
+
}
|
75
|
+
try {
|
76
|
+
const date = new Date(year, month - 1, day, hour, minute, second);
|
77
|
+
if (date.getFullYear() === year && date.getMonth() === month - 1 && date.getDate() === day) {
|
78
|
+
return date.getTime();
|
79
|
+
}
|
80
|
+
} catch (error) {
|
81
|
+
return null;
|
82
|
+
}
|
83
|
+
}
|
84
|
+
}
|
85
|
+
return null;
|
86
|
+
}
|
87
|
+
function safeEval(expression) {
|
88
|
+
try {
|
89
|
+
const result = new Function("return " + expression)();
|
90
|
+
if (typeof result === "number" && !isNaN(result) && isFinite(result)) {
|
91
|
+
return isEffectiveTime(result) ? result : null;
|
92
|
+
} else {
|
93
|
+
console.warn(`safeEval: \u8868\u8FBE\u5F0F "${expression}" \u6267\u884C\u7ED3\u679C\u4E0D\u662F\u6709\u6548\u6570\u5B57`);
|
94
|
+
return null;
|
95
|
+
}
|
96
|
+
} catch (error) {
|
97
|
+
console.error(`safeEval: \u8868\u8FBE\u5F0F "${expression}" \u6267\u884C\u5931\u8D25:`, error == null ? void 0 : error.message);
|
98
|
+
return null;
|
99
|
+
}
|
100
|
+
}
|
101
|
+
function getTimestamp(list) {
|
102
|
+
if (!(list == null ? void 0 : list.length))
|
103
|
+
return [];
|
104
|
+
return list.map((v) => v === null ? null : new Date(v).getTime());
|
105
|
+
}
|
106
|
+
const parseDateShortcuts = (row) => {
|
107
|
+
const {
|
108
|
+
dateShortcuts,
|
109
|
+
optionSetting,
|
110
|
+
format = "YYYY-MM-DD HH:mm:ss"
|
111
|
+
} = row;
|
112
|
+
if (!(dateShortcuts == null ? void 0 : dateShortcuts.length))
|
113
|
+
return [];
|
114
|
+
return dateShortcuts == null ? void 0 : dateShortcuts.map((v) => {
|
115
|
+
const {
|
116
|
+
name,
|
117
|
+
expressions
|
118
|
+
} = v;
|
119
|
+
if (!name || !(expressions == null ? void 0 : expressions.length))
|
120
|
+
return null;
|
121
|
+
const resultExp = parseExpressions(expressions, format);
|
122
|
+
if (!(resultExp == null ? void 0 : resultExp.length)) {
|
123
|
+
return null;
|
124
|
+
}
|
125
|
+
if (expressions.length !== resultExp.length) {
|
126
|
+
console.warn("expressions\u4E2D\u5B58\u5728\u65E0\u6548\u503C");
|
127
|
+
return null;
|
128
|
+
}
|
129
|
+
return {
|
130
|
+
name,
|
131
|
+
value: JSON.stringify(expressions),
|
132
|
+
parseValue: resultExp,
|
133
|
+
unit: optionSetting,
|
134
|
+
timestamp: getTimestamp(resultExp)
|
135
|
+
};
|
136
|
+
}).filter(Boolean);
|
137
|
+
};
|
138
|
+
|
139
|
+
export { parseDateShortcuts };
|
@@ -1,9 +1,9 @@
|
|
1
|
-
import { DataTypeEnums, WidgetTypeEnums, WidgetOptionEnums } from '../types/enums.js';
|
1
|
+
import { DataTypeEnums, WidgetTypeEnums, WidgetOptionEnums, WidgetValEnums } from '../types/enums.js';
|
2
2
|
|
3
3
|
const transformDataToFront = (dataType, rawData = []) => {
|
4
4
|
if (dataType === DataTypeEnums.API) {
|
5
5
|
return rawData.map((data) => {
|
6
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o;
|
6
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
|
7
7
|
const optionList = (_b = (_a = data.optionInfo) == null ? void 0 : _a.list) != null ? _b : [];
|
8
8
|
let customType = data.type;
|
9
9
|
if (data.type === WidgetTypeEnums.LABEL) {
|
@@ -32,12 +32,13 @@ const transformDataToFront = (dataType, rawData = []) => {
|
|
32
32
|
type: customType,
|
33
33
|
optionSetting: data.optionType,
|
34
34
|
openAdvancedFilter: data.isShowSearch,
|
35
|
+
dateShortcuts: (_g = data.dateShortcuts) != null ? _g : [],
|
35
36
|
filterOutDisplay: data.filterExplicit,
|
36
37
|
filterOutRequired: data.explicitRequired,
|
37
38
|
width: data.width,
|
38
39
|
defValCfg: {
|
39
|
-
value: data.type === WidgetTypeEnums.SELECT && data.optionType === WidgetOptionEnums.MULTIPLE ? (
|
40
|
-
presetVal: data.type === WidgetTypeEnums.SELECT && data.optionType === WidgetOptionEnums.MULTIPLE ? ((
|
40
|
+
value: data.type === WidgetTypeEnums.SELECT && data.optionType === WidgetOptionEnums.MULTIPLE ? (_i = (_h = data.defaultValue) == null ? void 0 : _h.valueList) != null ? _i : [] : (_l = (_k = (_j = data.defaultValue) == null ? void 0 : _j.valueList) == null ? void 0 : _k[0]) != null ? _l : null,
|
41
|
+
presetVal: data.type === WidgetTypeEnums.SELECT && data.optionType === WidgetOptionEnums.MULTIPLE ? ((_m = data.defaultValue) == null ? void 0 : _m.unit) ? [(_n = data.defaultValue) == null ? void 0 : _n.unit] : [] : (_p = (_o = data.defaultValue) == null ? void 0 : _o.unit) != null ? _p : null
|
41
42
|
},
|
42
43
|
mappingConfig: {
|
43
44
|
mappingMethod: null,
|
@@ -124,7 +125,7 @@ const getParamCfg = (p_name, params) => {
|
|
124
125
|
};
|
125
126
|
const transformConditions = (rawConditions, params) => {
|
126
127
|
return rawConditions.map((item) => {
|
127
|
-
var _a, _b, _c;
|
128
|
+
var _a, _b, _c, _d;
|
128
129
|
const cfg = getParamCfg(item.field_key, params);
|
129
130
|
let val = item.value;
|
130
131
|
if (val && !Array.isArray(val)) {
|
@@ -139,7 +140,8 @@ const transformConditions = (rawConditions, params) => {
|
|
139
140
|
condition: item.con,
|
140
141
|
value,
|
141
142
|
presetVal: (_b = item.unit) != null ? _b : null,
|
142
|
-
|
143
|
+
customDate: (_c = item == null ? void 0 : item.customDate) != null ? _c : null,
|
144
|
+
dynamicBaseList: (_d = item == null ? void 0 : item.dynamicBaseList) != null ? _d : []
|
143
145
|
};
|
144
146
|
if (Object.keys(item).includes("isAccurateSearch")) {
|
145
147
|
obj.isAccurateSearch = item.isAccurateSearch;
|
@@ -154,8 +156,9 @@ const transformRawConditions = (conditions) => {
|
|
154
156
|
field_key: item.key,
|
155
157
|
con: item.condition,
|
156
158
|
value: Array.isArray(item.value) ? item.value : item.value ? [item.value] : [],
|
157
|
-
unit: item.presetVal,
|
158
|
-
dynamicBaseList: item.dynamicBaseList || []
|
159
|
+
unit: (item == null ? void 0 : item.customDate) ? WidgetValEnums.CUSTOM : item.presetVal,
|
160
|
+
dynamicBaseList: item.dynamicBaseList || [],
|
161
|
+
customDate: item == null ? void 0 : item.customDate
|
159
162
|
};
|
160
163
|
if (Object.keys(item).includes("isAccurateSearch")) {
|
161
164
|
obj.isAccurateSearch = item.isAccurateSearch;
|
@@ -45,6 +45,7 @@ export declare const WidgetOptionEnums: {
|
|
45
45
|
SELECT_TIME: string;
|
46
46
|
PAST_TIME: string;
|
47
47
|
FUTURE_TIME: string;
|
48
|
+
CUSTOM_TIME: string;
|
48
49
|
};
|
49
50
|
export declare const WidgetValEnums: {
|
50
51
|
CUSTOM: string;
|
@@ -80,4 +81,8 @@ export declare const WidgetValEnums: {
|
|
80
81
|
export declare const ConditionEnums: {
|
81
82
|
NULL: string;
|
82
83
|
EQUAL: string;
|
84
|
+
IN_THE_PAST: string;
|
85
|
+
IN_THE_FUTURE: string;
|
86
|
+
IN_THE_PAST_DI: string;
|
87
|
+
IN_THE_FUTURE_DI: string;
|
83
88
|
};
|
@@ -44,7 +44,8 @@ const WidgetOptionEnums = {
|
|
44
44
|
ALL: "DATETIME_WHOLE",
|
45
45
|
SELECT_TIME: "DATETIME_SELECT",
|
46
46
|
PAST_TIME: "DATETIME_PAST",
|
47
|
-
FUTURE_TIME: "DATETIME_FUTURE"
|
47
|
+
FUTURE_TIME: "DATETIME_FUTURE",
|
48
|
+
CUSTOM_TIME: "DATETIME_CUSTOM"
|
48
49
|
};
|
49
50
|
const WidgetValEnums = {
|
50
51
|
CUSTOM: "CUSTOM",
|
@@ -79,7 +80,11 @@ const WidgetValEnums = {
|
|
79
80
|
};
|
80
81
|
const ConditionEnums = {
|
81
82
|
NULL: "NULL",
|
82
|
-
EQUAL: "EQ"
|
83
|
+
EQUAL: "EQ",
|
84
|
+
IN_THE_PAST: "IN_THE_PAST",
|
85
|
+
IN_THE_FUTURE: "IN_THE_FUTURE",
|
86
|
+
IN_THE_PAST_DI: "IN_THE_PAST_DI",
|
87
|
+
IN_THE_FUTURE_DI: "IN_THE_FUTURE_DI"
|
83
88
|
};
|
84
89
|
|
85
90
|
export { ConditionEnums, DataTypeEnums, FieldTypeEnums, MappingMethodEnums, WidgetOptionEnums, WidgetTypeEnums, WidgetValEnums, selectModeEnums };
|
@@ -93,6 +93,7 @@ export type ISearchConfigType = {
|
|
93
93
|
isAccurateSearch?: boolean;
|
94
94
|
accurateSearchKey?: string;
|
95
95
|
dynamicBaseList?: any[];
|
96
|
+
customDate?: string;
|
96
97
|
};
|
97
98
|
export type ITreeDataType = {
|
98
99
|
name: string;
|
@@ -148,6 +149,7 @@ export type IApiServerType = {
|
|
148
149
|
componentProps?: any;
|
149
150
|
extendKey?: string;
|
150
151
|
extendType?: string;
|
152
|
+
dateShortcuts?: any[];
|
151
153
|
};
|
152
154
|
export type dynamicOptionInfoType = {
|
153
155
|
filterKeys: string[];
|
@@ -212,6 +214,7 @@ export type IfilterConditionsType = {
|
|
212
214
|
value: string;
|
213
215
|
isAccurateSearch?: boolean;
|
214
216
|
accurateSearchKey?: string;
|
217
|
+
customDate?: string;
|
215
218
|
};
|
216
219
|
export type ISearchParamsType = {
|
217
220
|
field_key: string;
|
@@ -220,6 +223,7 @@ export type ISearchParamsType = {
|
|
220
223
|
unit: 'custom' | null;
|
221
224
|
widgetType?: string;
|
222
225
|
dynamicBaseList?: any[];
|
226
|
+
dateShortcuts?: any[];
|
223
227
|
isAccurateSearch?: boolean;
|
224
228
|
accurateSearchKey?: string;
|
225
229
|
};
|
@@ -243,3 +247,11 @@ export type IExtendConfigurationType = {
|
|
243
247
|
_filterApiConfig: any;
|
244
248
|
_selectCriticalNum?: number;
|
245
249
|
};
|
250
|
+
export type ICustomDateType = {
|
251
|
+
name: string;
|
252
|
+
label: string;
|
253
|
+
unit: string;
|
254
|
+
value: string;
|
255
|
+
parseValue: any[];
|
256
|
+
timestamp: number[];
|
257
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
export * from './src/utils';
|
@@ -0,0 +1 @@
|
|
1
|
+
export { vertify } from './src/utils/index.js';
|
@@ -0,0 +1,89 @@
|
|
1
|
+
import { FormRules } from 'naive-ui';
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
3
|
+
verifyUser: {
|
4
|
+
type: FunctionConstructor;
|
5
|
+
required: false;
|
6
|
+
default: () => Promise<void>;
|
7
|
+
};
|
8
|
+
identityVerificationTitle: {
|
9
|
+
type: StringConstructor;
|
10
|
+
required: false;
|
11
|
+
default: string;
|
12
|
+
};
|
13
|
+
token: {
|
14
|
+
type: StringConstructor;
|
15
|
+
required: true;
|
16
|
+
default: string;
|
17
|
+
};
|
18
|
+
modelValue: {
|
19
|
+
type: BooleanConstructor;
|
20
|
+
required: true;
|
21
|
+
};
|
22
|
+
}, {
|
23
|
+
loginCheckUrl: string;
|
24
|
+
DEFAULT_FORM: {
|
25
|
+
account: string;
|
26
|
+
password: string;
|
27
|
+
};
|
28
|
+
message: import("naive-ui").MessageApi;
|
29
|
+
props: {
|
30
|
+
verifyUser: Function;
|
31
|
+
identityVerificationTitle: string;
|
32
|
+
token: string;
|
33
|
+
modelValue: boolean;
|
34
|
+
};
|
35
|
+
emit: (event: "close" | "success" | "update:modelValue" | "afterLeaveComponent", ...args: any[]) => void;
|
36
|
+
form: {
|
37
|
+
account: string;
|
38
|
+
password: string;
|
39
|
+
};
|
40
|
+
rules: FormRules;
|
41
|
+
style: {
|
42
|
+
width: string;
|
43
|
+
};
|
44
|
+
formRef: import("vue").Ref<{
|
45
|
+
validate: import("naive-ui/es/form/src/interface").FormValidate;
|
46
|
+
restoreValidation: () => void;
|
47
|
+
} | null>;
|
48
|
+
loading: import("vue").Ref<boolean>;
|
49
|
+
handleClickClose: () => void;
|
50
|
+
handleAfterLeave: () => void;
|
51
|
+
submitLoginData: () => Promise<false | undefined>;
|
52
|
+
handleValidate: () => void;
|
53
|
+
NSpace: any;
|
54
|
+
NButton: any;
|
55
|
+
NModal: any;
|
56
|
+
NForm: any;
|
57
|
+
NFormItem: any;
|
58
|
+
NInput: any;
|
59
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("close" | "success" | "update:modelValue" | "afterLeaveComponent")[], "close" | "success" | "update:modelValue" | "afterLeaveComponent", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
60
|
+
verifyUser: {
|
61
|
+
type: FunctionConstructor;
|
62
|
+
required: false;
|
63
|
+
default: () => Promise<void>;
|
64
|
+
};
|
65
|
+
identityVerificationTitle: {
|
66
|
+
type: StringConstructor;
|
67
|
+
required: false;
|
68
|
+
default: string;
|
69
|
+
};
|
70
|
+
token: {
|
71
|
+
type: StringConstructor;
|
72
|
+
required: true;
|
73
|
+
default: string;
|
74
|
+
};
|
75
|
+
modelValue: {
|
76
|
+
type: BooleanConstructor;
|
77
|
+
required: true;
|
78
|
+
};
|
79
|
+
}>> & {
|
80
|
+
onSuccess?: ((...args: any[]) => any) | undefined;
|
81
|
+
onClose?: ((...args: any[]) => any) | undefined;
|
82
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
83
|
+
onAfterLeaveComponent?: ((...args: any[]) => any) | undefined;
|
84
|
+
}, {
|
85
|
+
token: string;
|
86
|
+
verifyUser: Function;
|
87
|
+
identityVerificationTitle: string;
|
88
|
+
}>;
|
89
|
+
export default _default;
|
@@ -0,0 +1,6 @@
|
|
1
|
+
import _sfc_main from './IdentityVerification.vue2.js';
|
2
|
+
import _export_sfc from '../../../../_virtual/_plugin-vue_export-helper.js';
|
3
|
+
|
4
|
+
var IdentityVerification = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "IdentityVerification.vue"]]);
|
5
|
+
|
6
|
+
export { IdentityVerification as default };
|
@@ -0,0 +1,256 @@
|
|
1
|
+
import { defineComponent, reactive, ref, watch, openBlock, createBlock, unref, normalizeStyle, withCtx, createElementVNode, createVNode, withKeys, createTextVNode, toRaw } from 'vue';
|
2
|
+
import axios from 'axios';
|
3
|
+
import { createDiscreteApi, NModal, NForm, NFormItem, NInput, NSpace, NButton } from 'naive-ui';
|
4
|
+
|
5
|
+
const _hoisted_1 = {
|
6
|
+
class: "content",
|
7
|
+
style: {
|
8
|
+
"margin-top": "20px"
|
9
|
+
}
|
10
|
+
};
|
11
|
+
var _sfc_main = /* @__PURE__ */ defineComponent({
|
12
|
+
__name: "IdentityVerification",
|
13
|
+
props: {
|
14
|
+
verifyUser: {
|
15
|
+
type: Function,
|
16
|
+
default: () => Promise.resolve()
|
17
|
+
},
|
18
|
+
identityVerificationTitle: {
|
19
|
+
default: function() {
|
20
|
+
var _a, _b, _c;
|
21
|
+
try {
|
22
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.669")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.669")) || "\u8DE8\u8D26\u53F7\u64CD\u4F5C";
|
23
|
+
} catch (e) {
|
24
|
+
return "\u8DE8\u8D26\u53F7\u64CD\u4F5C";
|
25
|
+
}
|
26
|
+
}()
|
27
|
+
},
|
28
|
+
token: {
|
29
|
+
default: ""
|
30
|
+
},
|
31
|
+
modelValue: {
|
32
|
+
type: Boolean
|
33
|
+
}
|
34
|
+
},
|
35
|
+
emits: ["update:modelValue", "success", "close", "afterLeaveComponent"],
|
36
|
+
setup(__props, {
|
37
|
+
emit
|
38
|
+
}) {
|
39
|
+
const props = __props;
|
40
|
+
const loginCheckUrl = "/user-center/user/manage/checkBusPasswordByAuthEmp";
|
41
|
+
const DEFAULT_FORM = {
|
42
|
+
account: "",
|
43
|
+
password: ""
|
44
|
+
};
|
45
|
+
const {
|
46
|
+
message
|
47
|
+
} = createDiscreteApi(["message"]);
|
48
|
+
let form = reactive({
|
49
|
+
...DEFAULT_FORM
|
50
|
+
});
|
51
|
+
const rules = {
|
52
|
+
account: {
|
53
|
+
required: true,
|
54
|
+
message: function() {
|
55
|
+
var _a, _b, _c;
|
56
|
+
try {
|
57
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.668")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.668")) || "\u8BF7\u8F93\u5165\u5DE5\u53F7";
|
58
|
+
} catch (e) {
|
59
|
+
return "\u8BF7\u8F93\u5165\u5DE5\u53F7";
|
60
|
+
}
|
61
|
+
}()
|
62
|
+
},
|
63
|
+
password: {
|
64
|
+
required: true,
|
65
|
+
message: function() {
|
66
|
+
var _a, _b, _c;
|
67
|
+
try {
|
68
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.469")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.469")) || "\u8BF7\u8F93\u5165\u5BC6\u7801";
|
69
|
+
} catch (e) {
|
70
|
+
return "\u8BF7\u8F93\u5165\u5BC6\u7801";
|
71
|
+
}
|
72
|
+
}()
|
73
|
+
}
|
74
|
+
};
|
75
|
+
const style = {
|
76
|
+
width: "416px"
|
77
|
+
};
|
78
|
+
const formRef = ref(null);
|
79
|
+
const loading = ref(false);
|
80
|
+
const handleClickClose = () => {
|
81
|
+
emit("update:modelValue", false);
|
82
|
+
emit("close");
|
83
|
+
};
|
84
|
+
const handleAfterLeave = () => {
|
85
|
+
emit("afterLeaveComponent");
|
86
|
+
};
|
87
|
+
const submitLoginData = async () => {
|
88
|
+
try {
|
89
|
+
loading.value = true;
|
90
|
+
const {
|
91
|
+
data = {}
|
92
|
+
} = await axios({
|
93
|
+
method: "get",
|
94
|
+
url: loginCheckUrl,
|
95
|
+
headers: {
|
96
|
+
Authorization: "bearer " + props.token
|
97
|
+
},
|
98
|
+
params: {
|
99
|
+
empNo: form.account,
|
100
|
+
busPassword: form.password
|
101
|
+
}
|
102
|
+
}) || {};
|
103
|
+
if (!data.success) {
|
104
|
+
message.error((data == null ? void 0 : data.msg) || (data == null ? void 0 : data.message));
|
105
|
+
return false;
|
106
|
+
}
|
107
|
+
message.success((data == null ? void 0 : data.msg) || (data == null ? void 0 : data.message));
|
108
|
+
emit("success", {
|
109
|
+
empNo: toRaw(form.account),
|
110
|
+
busPassword: toRaw(form.password),
|
111
|
+
token: (data == null ? void 0 : data.data) || ""
|
112
|
+
});
|
113
|
+
} catch (error) {
|
114
|
+
message.error(error == null ? void 0 : error.message);
|
115
|
+
} finally {
|
116
|
+
loading.value = false;
|
117
|
+
}
|
118
|
+
};
|
119
|
+
const handleValidate = () => {
|
120
|
+
var _a;
|
121
|
+
(_a = formRef.value) == null ? void 0 : _a.validate((errors) => {
|
122
|
+
if (!errors) {
|
123
|
+
submitLoginData();
|
124
|
+
} else {
|
125
|
+
console.log(errors);
|
126
|
+
return false;
|
127
|
+
}
|
128
|
+
});
|
129
|
+
};
|
130
|
+
watch(() => props.modelValue, (val) => {
|
131
|
+
if (val)
|
132
|
+
return;
|
133
|
+
Object.assign(form, DEFAULT_FORM);
|
134
|
+
});
|
135
|
+
return (_ctx, _cache) => {
|
136
|
+
return openBlock(), createBlock(unref(NModal), {
|
137
|
+
class: "c-identity-verification-modal",
|
138
|
+
preset: "dialog",
|
139
|
+
title: __props.identityVerificationTitle,
|
140
|
+
show: __props.modelValue,
|
141
|
+
"close-on-esc": false,
|
142
|
+
"show-icon": false,
|
143
|
+
style: normalizeStyle({
|
144
|
+
width: style.width,
|
145
|
+
overflowY: "auto"
|
146
|
+
}),
|
147
|
+
onClose: handleClickClose,
|
148
|
+
onNegativeClick: handleClickClose,
|
149
|
+
onPositiveClick: handleValidate,
|
150
|
+
onAfterLeave: handleAfterLeave
|
151
|
+
}, {
|
152
|
+
default: withCtx(() => [createElementVNode("div", _hoisted_1, [createVNode(unref(NForm), {
|
153
|
+
ref_key: "formRef",
|
154
|
+
ref: formRef,
|
155
|
+
model: unref(form),
|
156
|
+
rules,
|
157
|
+
"label-placement": "left",
|
158
|
+
"label-width": "auto",
|
159
|
+
"require-mark-placement": "right-hanging"
|
160
|
+
}, {
|
161
|
+
default: withCtx(() => [createVNode(unref(NFormItem), {
|
162
|
+
label: function() {
|
163
|
+
var _a, _b, _c;
|
164
|
+
try {
|
165
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.121")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.121")) || "\u5DE5\u53F7";
|
166
|
+
} catch (e) {
|
167
|
+
return "\u5DE5\u53F7";
|
168
|
+
}
|
169
|
+
}(),
|
170
|
+
path: "account"
|
171
|
+
}, {
|
172
|
+
default: withCtx(() => [createVNode(unref(NInput), {
|
173
|
+
value: unref(form).account,
|
174
|
+
"onUpdate:value": _cache[0] || (_cache[0] = ($event) => unref(form).account = $event),
|
175
|
+
placeholder: function() {
|
176
|
+
var _a, _b, _c;
|
177
|
+
try {
|
178
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.668")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.668")) || "\u8BF7\u8F93\u5165\u5DE5\u53F7";
|
179
|
+
} catch (e) {
|
180
|
+
return "\u8BF7\u8F93\u5165\u5DE5\u53F7";
|
181
|
+
}
|
182
|
+
}(),
|
183
|
+
onKeyup: withKeys(handleValidate, ["enter"])
|
184
|
+
}, null, 8, ["value", "onKeyup"])]),
|
185
|
+
_: 1
|
186
|
+
}), createVNode(unref(NFormItem), {
|
187
|
+
label: function() {
|
188
|
+
var _a, _b, _c;
|
189
|
+
try {
|
190
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.670")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.670")) || "\u4E1A\u52A1\u5BC6\u7801";
|
191
|
+
} catch (e) {
|
192
|
+
return "\u4E1A\u52A1\u5BC6\u7801";
|
193
|
+
}
|
194
|
+
}(),
|
195
|
+
path: "password"
|
196
|
+
}, {
|
197
|
+
default: withCtx(() => [createVNode(unref(NInput), {
|
198
|
+
type: "password",
|
199
|
+
"input-props": {
|
200
|
+
autocomplete: "on",
|
201
|
+
name: "password"
|
202
|
+
},
|
203
|
+
value: unref(form).password,
|
204
|
+
"onUpdate:value": _cache[1] || (_cache[1] = ($event) => unref(form).password = $event),
|
205
|
+
placeholder: function() {
|
206
|
+
var _a, _b, _c;
|
207
|
+
try {
|
208
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.469")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.469")) || "\u8BF7\u8F93\u5165\u5BC6\u7801";
|
209
|
+
} catch (e) {
|
210
|
+
return "\u8BF7\u8F93\u5165\u5BC6\u7801";
|
211
|
+
}
|
212
|
+
}(),
|
213
|
+
onKeyup: withKeys(handleValidate, ["enter"])
|
214
|
+
}, null, 8, ["value", "onKeyup"])]),
|
215
|
+
_: 1
|
216
|
+
})]),
|
217
|
+
_: 1
|
218
|
+
}, 8, ["model"]), createVNode(unref(NSpace), {
|
219
|
+
reverse: ""
|
220
|
+
}, {
|
221
|
+
default: withCtx(() => [createVNode(unref(NButton), {
|
222
|
+
loading: loading.value,
|
223
|
+
type: "info",
|
224
|
+
onClick: handleValidate
|
225
|
+
}, {
|
226
|
+
default: withCtx(() => [createTextVNode(function() {
|
227
|
+
var _a, _b, _c;
|
228
|
+
try {
|
229
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.671")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.671")) || "\u9A8C\u8BC1";
|
230
|
+
} catch (e) {
|
231
|
+
return "\u9A8C\u8BC1";
|
232
|
+
}
|
233
|
+
}())]),
|
234
|
+
_: 1
|
235
|
+
}, 8, ["loading"]), createVNode(unref(NButton), {
|
236
|
+
onClick: handleClickClose
|
237
|
+
}, {
|
238
|
+
default: withCtx(() => [createTextVNode(function() {
|
239
|
+
var _a, _b, _c;
|
240
|
+
try {
|
241
|
+
return ((_a = window.getLanguageByCode) == null ? void 0 : _a.call(window, "10010.1.28")) || ((_c = (_b = window.top) == null ? void 0 : _b.getLanguageByCode) == null ? void 0 : _c.call(_b, "10010.1.28")) || "\u53D6\u6D88";
|
242
|
+
} catch (e) {
|
243
|
+
return "\u53D6\u6D88";
|
244
|
+
}
|
245
|
+
}())]),
|
246
|
+
_: 1
|
247
|
+
})]),
|
248
|
+
_: 1
|
249
|
+
})])]),
|
250
|
+
_: 1
|
251
|
+
}, 8, ["title", "show", "style"]);
|
252
|
+
};
|
253
|
+
}
|
254
|
+
});
|
255
|
+
|
256
|
+
export { _sfc_main as default };
|
@@ -0,0 +1,7 @@
|
|
1
|
+
import { AnyObject } from '../../../../shared/types';
|
2
|
+
import { ComponentInternalInstance } from 'vue';
|
3
|
+
export declare class RoleDialog {
|
4
|
+
rendered: boolean;
|
5
|
+
static createMsg(message: string): string;
|
6
|
+
show(instance: ComponentInternalInstance, data: AnyObject): Promise<AnyObject>;
|
7
|
+
}
|