{"version":3,"sources":["core/components/MyForm/MyForm.tsx","helpers/Flows/Auth.js","core/components/Others/Tooltip/index.tsx","helpers/Observer.js","helpers/fnList.js","core/components/Others/Popover/index.tsx","libs/NumeralJs/numeral.js","libs/ReactAwesomeLightbox/index.js","core/components/MyModal/MyLightbox.tsx","core/helpers/regex.ts","core/components/MyForm/MyFormControlHelpers.ts","core/components/MyForm/MyFormControl.tsx","core/helpers/json.ts","core/helpers/query.tsx","core/helpers/link.ts","core/helpers/c.ts","core/helpers/serviceWorker.ts","core/helpers/config.ts","core/helpers/format.ts","core/helpers/index.ts","reducer/sidemenu/sidemenu.constants.js","helpers/V.js","modules/adminpanel/hooks/useForceUpdate.js","helpers/Flows/Client.js","helpers/Flows/TableFilter.js","helpers/Flows/Page.js","core/modules/setting2fa/helpers.ts","modules/adminpanel/MyBase/Types/select_check.js","assets/images/avatar.jpg","helpers/Flows/TableExpand.js","core/components/MyIcon/MyIcon.tsx","core/components/MyUI/UIContentsTypes/o.js","core/components/MyUI/UIContentsTypes/t.js","core/components/MyUI/UIContentsTypes/t_card.js","core/components/MyUI/UIContentsTypes/t_table.js","core/components/MyUI/UIContentsTypes/t_tooltip.js","core/components/MyUI/UIContentsTypes/t_input_ext.js","core/components/MyUI/UIContentsTypes/t_input_check.js","core/components/MyUI/UIContentsTypes/t_input_text.js","core/components/MyUI/UIContentsTypes/t_img.js","core/components/MyUI/UIContentsTypes/t_html.js","core/components/MyUI/MyUI.tsx","core/components/MyControl/Badge.js","core/components/MyControl/Alert.tsx","core/components/MyLoading/MyLoading.tsx","core/components/MyModal/MyDialog.tsx","core/components/Others/PopoverBoostrap/index.js","core/hook/useForceUpdate/index.ts","assets/images/sidebar/city1.jpg","reducer/ThemeOptions.js","modules/adminpanel/MyBase/Types/numeral.js","core/helpers/utils.ts","core/modules/dev_simulator/MyUI/index.ts","core/modules/dev_simulator/MyUI/Types/dev_menu.js","core/modules/dev_simulator/index.ts","core/components/MyUI/UIContentsTypes/_helpers.js","core/components/MyModal/MyModal.tsx","helpers/Flows/More.js","core/helpers/ui.tsx","core/helpers/auth.ts","helpers/Flow.js","helpers/FlowV3.js","App/App.constants.ts","helpers/Flows/Form.js","core/helpers/localStorage.ts","core/helpers/api.ts","guards/AuthenticatedGuard.tsx","pages/PageGeneric/PageGeneric.tsx","helpers/paths.ts","components/Loading/Loading.tsx","core/components/MyPage/MyPage.tsx","pages/Login/LoginSocialGoogleNew.tsx","pages/Login/LoginSocial.tsx","pages/Login/Login.styles.ts","pages/Login/Login.constants.ts","pages/Login/Login.actions.ts","pages/Login/Login.thunks.ts","pages/Login/LoginContainer.tsx","pages/Login/Login.tsx","pages/Login/Forgot.tsx","pages/Login/Reset.tsx","pages/Login/Register.tsx","components/Loading/ScreenLoading.tsx","routes/routes.tsx","App/App.tsx","core/modules/firstsetting.ts","core/components/MyIcon/MyIconHelpers.tsx","core/modules/iconHiOutline/MyIcon/index.ts","core/modules/iconHiOutline/index.ts","core/components/MyPage/MyPageHelpers.ts","core/modules/setting/MyPage/index.ts","core/modules/setting/index.ts","core/modules/setting2fa/MyUI/index.ts","core/modules/setting2fa/index.ts","core/modules/setting2fa/lang/i18n.ts","core/modules/redirectToken/MyPage/index.ts","core/modules/redirectToken/index.ts","core/modules/dev/MyPage/Types/Dev_MyLib_ReactMultiCarousel.js","core/modules/dev/MyPage/Types/Dev_MyLib_ReactRater.js","core/modules/dev/MyPage/Types/Dev_MyLib_All.js","core/modules/dev/MyPage/Types/Dev_MyLayout_grid.js","core/modules/dev/MyPage/Types/Dev_MyLayout_All.js","core/modules/dev/MyPage/Types/Dev_MyModal.js","core/modules/dev/MyPage/Types/Dev_MyLoading.js","core/modules/dev/MyPage/Types/Dev_MyForm_All.js","core/modules/dev/MyPage/Types/Dev_MyBase_All.js","core/modules/dev/MyPage/index.ts","core/modules/dev/index.ts","core/modules/core/MyUI/Types/html.tsx","core/modules/core/MyUI/Types/_helpers.js","core/modules/core/MyUI/Types/data_obj.js","core/modules/core/MyUI/Types/data_array.js","core/modules/core/MyUI/Types/data_tag.js","core/modules/core/MyUI/Types/data_span_autoresize.js","core/modules/core/MyUI/Types/state_loading.js","core/modules/core/MyUI/Types/state_error.js","core/modules/core/MyUI/Types/state_wrap.js","core/modules/core/MyUI/index.ts","core/modules/core/MyLayout/index.ts","core/modules/core/MyPage/index.js","core/modules/core/MyCard/Types/with_myui.js","core/modules/core/MyCard/index.js","core/modules/core/MyLoading/index.js","core/modules/core/index.ts","modules/reactga/index.js","modules/adminpanel/MyPage/index.js","modules/adminpanel/MyUI/Types/grid.js","modules/adminpanel/MyUI/index.js","modules/adminpanel/MyButton/index.js","modules/adminpanel/MyLayout/index.js","modules/adminpanel/MyTableCell/index.js","modules/adminpanel/MyTableHeader/index.js","modules/adminpanel/MyFormControl/index.js","modules/adminpanel/MyBase/Types/text.js","modules/adminpanel/MyBase/Types/textarea.js","modules/adminpanel/MyBase/Types/select.js","modules/adminpanel/MyBase/index.js","modules/adminpanel/MyTableFilterControl/index.js","modules/adminpanel/MyLib/index.js","modules/adminpanel/MyChart/index.js","modules/adminpanel/MyCard/index.js","modules/adminpanel/boot/categoryscreen.js","modules/adminpanel/boot/projectscreen.js","modules/adminpanel/index.js","modules/chrome_notification/index.js","modules/signalR/MyUI/index.js","modules/signalR/index.js","core/hook/useCountdown.js","modules/check_idle/MyUI/Types/checkidle_countdown.js","modules/check_idle/MyUI/index.js","modules/check_idle/index.js","modules/qlproject/MyPage/index.js","modules/qlproject/MyUI/index.js","modules/qlproject/index.js","modules/app_vfc/components/MyUI/index.ts","modules/app_vfc/components/MyPage/index.ts","modules/app_vfc/components/MyControl/index.ts","modules/app_vfc/components/MyFormControl/index.ts","modules/app_vfc/components/MyForm/index.ts","modules/app_vfc/components/MyLib/index.js","modules/app_vfc/index.js","App/App.reducer.ts","pages/Login/Login.reducer.ts","reducer/sidemenu/sidemenu.reducer.js","reducer/reducer.ts","reducer/reducerRegistry.js","store/store.ts","modules/app_demo/MyPage/index.js","modules/app_demo/indes.js","services/apiWebhookGGChat.js","App/AppConfig.ts","core/components/MyModal/MyModalWrap.js","modules/gtag/index.js","index.tsx","services/apiGeneric.js","modules/adminpanel/MyBase/Types/_helperMore.js","core/helpers/i18n.ts","core/helpers/constant.ts","helpers/Flows/FormControl.js","helpers/Flows/MNeedUpdateMLib.js","helpers/K.js","core/helpers/log.ts","helpers/Flows/Routes.js","helpers/Flows/Api.js","core/components/MyUI/MyUIHelpers.ts","helpers/Flows/TableCell.js","helpers/Flows/TableExtraData.js","modules/adminpanel/MyLayout/Types/architect/AppMain/index.js","libs/ReactErrorBoundary/index.tsx","assets/images/icon-error.png","modules/adminpanel/MyLayout/Types/architect/index.js","helpers/U.js","core/helpers/options.tsx","services/apiServices.js","helpers/Upload.js","App/App.actions.ts"],"names":["WrapForm","styled","div","MyForm","props","currentValues","toucheds","errorsValid","relativeControls","effectControls","controlsByFieldName","fieldsRequired","fieldsInvalid","controlsOptsByFieldName","fnListFromWrap","fnListFromExtControl","fnListFormControl","closeMyModal","inMyModal","hide","_initCurrentValuesByDefaultValue","configForm","defaultValues","Object","keys","k","_buildRelativeControls","controls","console","warn","i","length","_control","_fieldName","fieldName","_more","more","groups","j","_controlInGrp","_moreCtlInGrp","_fieldNameCtlInGrp","FlowUpdateRelativeControls","objRelatives","objEffectedBy","configFormControl","_getMoreOfForm","HIs","isJsonString","HJson","getObj","_getMoreWithKey","key","_moreOfForm","hasOwnProperty","_onTouch","newValue","indexOf","push","splice","FlowFnListFromExtControl","forceUpdate","updateValueEffect","_checkValidRequired","_valid","f","_onSubmit","event","fnList","me","preventDefault","onSubmitForm","setState","isLoading","result","myForm","then","rs","closeMyModalAfterSubmit","catch","err","showToastWarning","getDisabledForm","getCurrentValues","getSourceList","getConfigControlByFieldName","getConfigInMoreOfControl","configControl","_configControl","getRulesOfControl","checkValidAll","_result","_resultOfControl","checkValidOfField","_rules","_value","HValid","validAllRulesOfValue","_renderBtnSubmit","_configBtnSubmit","KMoreOfForm","btnSubmit","type","style","color","disabled","_getIsLoading","marginRight","className","title","i18next","t","_renderBtnReset","_configBtnReset","btnReset","onClick","fnListMyForm","kresetFormControl","state","_renderMoreButtons","_moreButtons","moreButtons","map","v","OneButton","configButton","onePage","getApiController","getQueryShared","renderMyButton","_renderFooter","hideFooter","renderFooter","positionButtonsBottom","_renderLoadingOverlay","renderLoadingOverlay","_renderFormControl","_fnList","getFnListOfFormControl","formErrorsValid","requestUpdateAfterChange","opts","configApiAfterChange","url","Array","isArray","fields","HApi","apiGeneric","method","data","DefaultValues","DataForm","res","Data","updateValue","initWrapControl","fnFromWrap","undefined","initExtControl","fnFromExtControl","addFnListFromControl","fnName","fn","getDefaultValues","getFieldsInvalid","getIsInvalid","updateRequired","onSubmitFormFromControl","onUpdateValue","HUtils","runFuntion","control","onJustUpdateValueMultiCurrentValuesForm","list","onUpdateControlWithNewValue","onUpdateValueMulti","_keys","registerControl","component","onTouch","fnGetTypeWrapControl","typeWrapControl","fnGetDefaultConfigWrapControl","defaultConfigWrapControl","fnRenderFormControl","fnGetDisabledForm","this","autoComplete","_moreProps","noValidateDefault","_usingI18n","usingI18n","_screenCode","onSubmit","screenCode","React","Component","KAuth","fnUpdateAuthInfo","eeUpdateAuthInfo","FlowParseAuthInfo","authInfo","configs","_configs","home_url","HCF","setCF","K","KConfigApp","HLocalStorage","saveString","KStorage","HomeURL","FlowUpdateAuthInfo","name","avatar","_authInfo","AuthInfo","avatar_url","saveObj","CF","HEE","emit","RcTooltip","ListObserver","sample","allTrigger","window_resize","HObserver","create","register","trigger","params","onResize","throttle","ev","window","innerWidth","innerHeight","addEventListener","log","kfnUpdatePageTitle","kfnGetApiPath","kfnGetScreenCode","kgetSourceList","kfnHandleSearchText","kfnLoadLocalFilter","kfnGetConfigPageScreenConfig","kfnGetConfigPageHeader","kfnGetConfigPageTable","kfnGetConfigPageDetail","kfnGetConfigPageFilter","kfnGetConfigPagePage","kfnGetConfigChart","kgetCurrentValues","kfnGetSourceData","kfnRenderBadge","kgetTabsIndexSelected","kgetTabLevel","konChangeTab","kfnReExpand","kgetDefaultValues","kfnForceUpdateTable","kgetDataList","kfnGetComponentTable","kfnGetOnePage","kfnGetOptions","kfnGetExtraDataTable","kfnGetDataTableFilterd","kfnGetDataTable","kaddFnListFromControl","kfnReloadList","kfnReloadOptionsAndList","kfnGetHeaderTitle","kfnGetConfigInMore","kfnGetIsInTableExpand","kfnGetConfigExpand","kfnGetIsInModal","kfnGetIsInPanel","kfnGetIsPanel","kfnGetColumnSelect","kfnGetConfigModal","kfnGetTypeWrapControl","kfnGetDefaultConfigWrapControl","kfnGetIsHide","kfnChangeSwitchView","kfnGetCurrentSwitchView","kfnGetButtonList","kfnRequestUpdateFromExpand","rf","args","fnListModal","showLoadingModal","hideLoadingModal","hideModal","fnListPopover","hidePopover","fnListFilesManager","onAfterAddFolderGGDrive","listFnMyForm","kfnRenderFormControl","fnListMyFormControl","getSourceData","fnListMyTableCell","fnGetSourceData","fnRenderBadge","fnGetHeaderTitle","fnGetConfigInMore","fnGetConfigModal","fnGetIsHide","kfnGetTitleControl","fnListMyTableFilterControl","fnGetTitleControl","kfnGetSharedRequestData","kfnGetDataTotal","kfnGetTableCols","fnListMyPage","fnGetSharedRequestData","fnReloadList","fnReloadOptionsAndList","fnReloadPage","location","reload","fnUpdatePageTitle","fnGetApiPath","fnGetScreenCode","fnHandleSearchText","fnLoadLocalFilter","fnGetConfigPageScreenConfig","fnGetConfigPageHeader","fnGetConfigPageTable","fnGetConfigPageDetail","fnGetConfigPageFilter","fnGetConfigPagePage","fnGetConfigChart","getTabsIndexSelected","onChangeTab","fnReExpand","getTabLevel","fnForceUpdateTable","getDataList","fnGetOnePage","fnGetOptions","fnGetExtraDataTable","fnGetDataTableFilterd","fnGetDataTable","fnGetComponentTable","fnGetDefaultScreenConfig","fnGetIsInTableExpand","fnGetConfigExpand","fnGetIsInModal","fnGetIsInPanel","fnGetIsPanel","fnChangeSwitchView","fnGetCurrentSwitchView","fnGetButtonList","fnGetDataTotal","fnGetTableCols","fnRequestUpdateFromExpand","fnListConfigApp","getHasLoginSocial","getHasLoginSocialGoogle","getHasLoginSocialFacebook","getCF","hasLoginSocialGoogle","hasLoginSocialFacebook","getHasForgotPassword","hasForgotPassword","getHasRegisterAccount","hasRegisterAccount","getGoogleClientID","GoogleClientId","getScreenWidth","document","body","offsetWidth","getIsMobileByWidth","_widthMobile","widthMobile","getDefaultTypeHubFilter","defaultTypeHubFilter","getDefaultPositionFilter","defaultPositionFilter","getIsDevMode","isDevMode","getHomeUrl","DefaultHomeURL","getAppLogo","appLogo_url","getAuthInfo","getAppTitle","getVerAdmin","verAdmin","fnGetConfigTable","_configAll","KConfigPageTableDefault","fnListUI","fnShowToast","msg","options","KUI","fnshowDialog","configDialog","fnshowConfirm","fnShowLoadingScreen","fnForceUpdateRoutes","_fnListUI","RcPopover","useState","visible","setVisible","children","overlay","placement","onVisibleChange","overlayClassName","onPopupAlign","node","align","autoScrollIntoViewWhenOutOfScreen","isOnScreen","offsetTop","scrollIntoView","behavior","define","numeral","_","VERSION","formats","locales","defaults","currentLocale","zeroFormat","nullFormat","defaultFormat","scalePercentBy100","Numeral","input","number","_input","value","kind","unformatFunction","regexp","isNumeral","isNaN","replace","regexps","unformat","match","stringToNumber","Number","version","obj","numberToFormat","format","roundingFunction","abbrForce","abs","int","precision","signed","thousands","output","locale","negP","optDec","leadingCount","abbr","trillion","billion","million","thousand","decimal","neg","Math","includes","RegExp","abbreviations","toString","split","toFixed","delimiters","slice","String","string","abbreviation","stringOriginal","currency","symbol","pow","min","search","insert","subString","start","reduce","array","callback","TypeError","len","arguments","multiplier","x","parts","correctionFactor","prototype","call","accum","next","mn","maxDecimals","optionals","boundedPrecision","optionalsRegExp","power","splitValue","minDecimals","max","toLowerCase","localeData","Error","reset","property","validate","val","culture","_decimalSep","_thousandSep","_currSymbol","_valArray","_abbrObj","_thousandRegEx","temp","trim","e","substr","clone","inputString","formatFunction","round","set","add","corrFactor","cback","curr","currI","O","subtract","multiply","divide","difference","ordinal","b","DEFAULT_ZOOM_STEP","getXY","y","touches","pageX","pageY","Cond","condition","Fragment","Lightbox","initX","initY","lastX","lastY","_cont","createRef","zoom","rotate","loading","moving","current","startIndex","multi","images","createTransform","stopSideEffect","stopPropagation","getCurrentImage","s","p","image","getCurrentTitle","resetZoom","shockZoom","zoomStep","allowZoom","doubleClickZoom","_z","ceil","_xy","_cbr","getBoundingClientRect","_ccx","width","_ccy","height","navigateImage","direction","startMove","xy","duringMove","endMove","applyZoom","newZoom","applyRotate","exit","onClose","error","shouldShowReset","canvasClick","clickOutsideToExit","keyboardNavigation","allowReset","classList","keyboardInteraction","remove","removeEventListener","allowRotate","buttonAlign","showTitle","_reset","justifyContent","display","order","textAlign","ref","draggable","transform","cursor","transition","onMouseDown","onTouchStart","onMouseMove","onTouchMove","onMouseUp","onMouseLeave","onTouchEnd","onDoubleClick","onWheel","deltaY","onLoad","src","alt","MyLightbox","isShow","show","Helpers","defaultConfigModal","toggle","_getConfig","objHasKey","_renderBody","_props","_renderHeaderContent","_getClassname","classnames","modalClassName","modalCentered","size","modalScrollInside","initComponent","backdrop","Modal","isOpen","fade","usingModalBody","types","lightbox","components","showWithOpts","RGSquareBracket","HRegex","MyFormControlHelpers","configV1","FlowGetConfigFormFromConfigServer","moreDefaultValues","MyFormControl","getString","json2Obj","obj2Json","parseResponseButtonApi","target","autoOpenLink","linkOpen","noCheckFullPath","FlowApiShowFullPath","response","configFullPath","initLink","info","usingHash","history","createHashHistory","createBrowserHistory","basename","process","HLink","openUrl","C","HConfig","initC","getAuthUserName","getAuthUserId","getConfig","getDefaultFormatDate","HConstant","ConfigAppExt","dateFormat","getDefaultFormatDateTime","datetimeFormat","ServiceWorker","init","isSupported","_arrSW","serviceWorkersRun","sw","enableNotification","navigator","registerSW","link","getSW","serviceWorker","getRegistration","linkSW","Notification","requestPermission","reg","installing","waiting","active","disableNotification","unregister","showNotification","tag","createdAt","Date","now","message","showNotificationWithoutServiceWorker","n","icon","lang","dir","getTime","onclick","onshow","onerror","onclose","Config","appInfo","appName","home","configApp","configAppExt","configI18n","configLink","configApi","baseUrl","timeout","configAuth","configModules","configRoutes","routesPublic","routesPrivate","configSidebar","extAfterLogin","extSettingParts","headerComponent","initConfigAppExt","setCFMultiObj","mergeObjIfExist","isLocalDev","dom_firstLoading","getElementById","visibility","zIndex","background","id","innerHTML","initConfigApp","startsWith","addPublicRoutes","initI18n","initLocalStorage","initApi","initAuth","afterLogin","isFunction","afterLogout","HModules","initModules","modules","ConfigApp","FnList","onAfterInit","HServiceWorker","UIAppConfig","getPublicRoutes","getPrivateRoutes","addArray2Array","addPrivateRoutes","addSidebarItems","registerAfterLogin","registerExtSettingParts","registerHeaderTitle","changeTitle","headerTitle","goToHome","getUserName","getUserID","getAppName","addBodyClass","removeBodyClass","getConfigFooter","_configFooter","footer","getValueOfFormat","configFormat","getValue","HFormat","Types","isDateValue","moment","HC","fromNow","_format","numeralFormat","NumeralJs","_num","_configCurrencyLocaleOptions","currencyLocaleOptions","_s","toLocaleString","numberLocale","minimumFractionDigits","maximumFractionDigits","suffix","prefix","isNumber","isObject","_objRes","default","windowWidth","Infinity","matchedBreakpoint","optBreakpoint","parseInt","defaultValue","_numberLocale","_configByValue","configByValue","_colorForDark","colorForDark","_colorForLight","colorForLight","fix","HColor","getLumina","needMultip","numDecimal","_x","_suffix","eval","_configHideCondition","configHideCondition","_values","_obj","_opr","opr","_valueCompare","getTextWithData","_isHide","_config","operator","valueCompare","_operator","_list","_c","_decimals","decimals","dm","floor","parseFloat","HUI","SIDEMENU_UPDATE_TEXT_SEARCH","SIDEMENU_UPDATE_MODE_SEARCH","V5","Table_BuildCols","extraData","_configTable","FlowBuildColTableFromExtraData","_dataExtraData","fieldId","KConfigPageTable","sourceList","_dataOptions","showID","excludeFieldName","columnClassName","defaultFormatColumn","customProps","customType","configTable","TableExpand_CheckExpandItem","FlowTableExpand","FlowCheckExpandItem","TableExpand_IsShowExpandItem","FlowIsShowExpandItem","TableExpand_ToggleExpandItem","FlowToggleExpandItem","TableCell_KMore","FlowTableCell","KMore","TableCell_RenderTitleOfLink","FlowRenderTitleOfLink","TableCell_GetLinkTarget","FlowGetLinkTarget","TableCell_GetLink","FlowGetLink","TableCell_ClickLink","FlowActionClickLink","TableCell_GetTitleOfColumn","FlowGetTitleOfColumn","TableCell_RenderStatus","FlowRenderStatus","Cell_GetStyleCell","FlowGetStyleCell","Cell_GetHeaderTitle","FlowGetHeaderTitle","Cell_GetConfigModal","FlowGetConfigModal","TableFilter_IsShowFilter","FlowTableFilter","FlowIsShowFilter","TableFilter_IsShowSearch","FlowIsShowSearch","Page_GetSharedQueryOfPage","FlowPage","FlowGetSharedQueryOfPage","Auth_ParseAuthInfo","FlowAuth","Api_Generic","FlowApi","FlowApiGeneric","Api_RefreshCache","FlowApiRefreshCache","M_addItemToArrayOrCreateNewArray","FlowMNeedUpdateMLib","addItemToArrayOrCreateNewArray","useForceUpdate","setVF","useCallback","FlowClientBuildOptions","buttonList","configHeader","moreSourceList","_screenConfig","Header","Table","ButtonList","ChartConfig","Configs","ScreenConfig","JSON","stringify","UITypeContents","FlowClientClearLocalCache","localStorage","removeItem","withoutReload","myui","isServer","queryType","isFrom","isTo","showRanges","moreDateRangePicker","select2","placeholder","configPagination","virtualized","showSelectedOnFirstRow","fValue","fText","KMoreTableFilter","_isShow","_oneScreenConfig","_filter","_filterList","showSearch","FlowGetPlaceHolder","oneFilterControl","rest","FlowGetMore","_placeHolder","configOne","FlowGetOptionKey","optionKey","FlowGetConfigOfMore","_defaultValue","FlowGetSourceData","_sourceList","_optionKey","FlowGetShowFilterAsPopover","configFilter","_rs","_rsInGlobalConfig","dfShowFilterAsPopover","KConfigPageFilter","showFilterAsPopover","configPage","defaultQuery","fnListOfParent","moreQuery","queryFilter","querySort","from","withoutQueryFilter","withoutQuerySort","_query","QuerySearch","getAllParamOnUrl","_queryFromParent","RequestData","Id","ScreenGUID","FlowGetMoreQueryFilterOfTable","FlowGetMoreQuerySortOfTable","FlowGetConfigInLocalStorageOfPage","_keyLocal","ScreenCode","FlowUpdateConfigInLocalStorageOfPageWithKey","FlowUpdateSizeOfPageFromLocal","_configPagination","_pageSize","_configPageInLocal","_configPage","_configPageServer","sizePerPage","FlowParseOptions","_UITypeContents","get","FlowParseUITypeContent","_configI18n","forEach","loadExtLng","lng","ns","resources","listObj","MyUIHelpers","addTypes","configObj","FlowInitPageId","KOnePageMore","_pageUUID","getUUID","FlowRenderUIWithConfig","config","_type","_style","_className","_morePropsFromExtraData","morePropsFromExtraData","_extraData","FlowRenderUIFromConfigPage","FlowParseConfigInConfigPage","configInConfigPage","df","isRootLevel","hideSideMenu","t_bottom_2fa_setup","t_bottom_2fa_verify","Setting2FAHelpers","Auth2FAEnabled","UniqueId","fnUpdateSetting2FAPart","FA2Methods","seletedMethod","updateSettingByResponse","forceUpdateSetting2FAPart","updateSettingOneMethodByResponse","_method","updateFnUpdateSetting2FAPart","fnUpdate","getCurrentMethod","getCurrentMethodId","getCurrentOtpRecipientRequired","getCurrentOTPDescription","getCurrentFA2MethodName","Wrap","SvgTick","enableBackground","viewBox","d","BaseControl","withEmpty","Value","onChange","Text","FlowGetKeyOfExpandItem","configItemExpand","row","fnListOfMyTableCell","_onePage","_configExpandOfRow","FlowConfigExpandOfRow","_needUpdateConfigExpandOfRow","_firstCheck","_needForceUpdateDetail","item","_keyOfExpand","KMTC","defaultShowExpand","_prefix","_itemInList","_keyOfExpandInList","FlowGetAllExpandItemOfRow","_allExpand","_configExpand","forceUpdateCell","_itemList","MyIcon","MyUI_Object","renderArray","arr","getFnList","renderString","str","_str","_arr","parseFunction","evalInScope","_myData","runFnList","UIFnCore","myData","SquareBracket","emptyWhenNull","renderChildren","ch","ch_af","_fnName","_arg3","endsWith","_newArg3","parse","_item","parseMoreProp","_v","UIOnClick","m","_onCl","Obj","_myFnList","myChange","UIOnChange","updateField","UIFnPage","fnRequestUpdate","myBlur","UIOnBlur","parseStyle","st","stf","_styleField","assign","stfa","_styleAllField","isWrap","_wrapBy","wb","cn","MyUI_Tag","Tag","prop","MyUI_TagCard","h","hSt","fSt","hCn","fCn","MyUI_TagTable","renderTH","th","thSt","thStR","renderTD","td","tdSt","renderCell","renderTR","tr","trSt","fRB","colSpan","MyUI_Tooltip","renderOverlay","ov","pl","tg","MyUI_ExtControl","initState","debug","_controlled","getDefaultValueWhenEmpty","dfe","getDelimiter","delimiter","getValueInOptionItem","getTextInOptionItem","label","text","typeDataOnChange","_valueOnChange","typeData","MyUI_InputCheck","_onChange","currentTarget","checked","parseMore","innerRef","valid","invalid","custom","classes","MyUI_InputExt","propTypes","PropTypes","any","bool","defaultProps","MyUI_InputText","_onBlur","plaintext","onBlur","MyUI_TagImg","w","_src","MyUI_HTML","html","_data","_html","dangerouslySetInnerHTML","__html","ListNotLazy","o","T","t_div","t_card","TCard","t_table","TTable","t_tooltip","TTooltip","t_input_check","TInputCheck","t_input_text","TInputText","t_img","TImg","t_html","addTypesFromListWithoutLazy","MyUI","Badge","cssModule","pill","attributes","_objectWithoutPropertiesLoose","mapToCssModules","classNames","href","createElement","_extends","MyLoading","MyDialog","onClickOK","cModal","MyModal","showMyDialogWithConfigModal","showFooter","showFooterOK","showConfirm","showFooterClose","PopoverBoostrap","open","setOpen","targetId","styleWrap","Button","PopoverHeader","PopoverBody","setValueFU","valueFU","kEnableClosedSidebar","lastEnableClosedSidebar","SET_ENABLE_BACKGROUND_IMAGE","SET_ENABLE_MOBILE_MENU","SET_ENABLE_MOBILE_MENU_SMALL","SET_ENABLE_FIXED_HEADER","SET_ENABLE_HEADER_SHADOW","SET_ENABLE_SIDEBAR_SHADOW","SET_ENABLE_FIXED_SIDEBAR","SET_ENABLE_CLOSED_SIDEBAR","SET_ENABLE_FIXED_FOOTER","SET_ENABLE_PAGETITLE_ICON","SET_ENABLE_PAGETITLE_SUBHEADING","SET_ENABLE_PAGE_TABS_ALT","SET_BACKGROUND_IMAGE","SET_BACKGROUND_COLOR","SET_COLOR_SCHEME","SET_BACKGROUND_IMAGE_OPACITY","SET_HEADER_BACKGROUND_COLOR","setEnableClosedSidebar","enableClosedSidebar","setEnableMobileMenu","enableMobileMenu","setEnableMobileMenuSmall","enableMobileMenuSmall","reducer","backgroundColor","headerBackgroundColor","enableBackgroundImage","enableFixedHeader","enableHoverSidebar","enableHeaderShadow","enableSidebarShadow","enableFixedFooter","enableFixedSidebar","colorScheme","backgroundImage","sideBar6","backgroundImageOpacity","enablePageTitleIcon","enablePageTitleSubheading","enablePageTabsAlt","action","BaseText","HelperMore","getMoreFromProps","isFocus","setIsFocus","refValue","useRef","getTypeInput","valueDisplay","getPrefix","getSuffix","KMC","hideZero","hideNull","_valueShowWhenFocus","noDecimal","noNegative","checkReplace","onKeyPress","allowEnterToSubmit","_sValue","test","checkCanNotPress","onFocus","attrs","isString","srcObj","mergeObj","apply","logOne","safeInvoke","initMCore","moreArr","getItem","Dev","Key","_DEBUG_","onKeyDownEnter","delay","ms","Promise","resolve","setTimeout","debounce","time","LodashDebounce","LodashGet","checkConditionShow","conditionValue","_canShow","checkConditionShowWithOperator","_valueNeedCmp","cmpWith","getFullYear","element","curTop","heightOfWindow","offsetYOfWindow","scrollY","xorCrypt","fromCharCode","charCodeAt","isNotEmpty","isNotEmptyIncludeZero","squareBracket","extract","matcher","CSS_UNIT","PERMISSIVE_MATCH3","PERMISSIVE_MATCH4","rgb","rgba","hsl","hsla","hsv","hsva","hex3","hex6","hex4","hex8","extSquareBracket","_m","exec","index","lastIndex","newS","rg","getVideoCover","file","seekTo","reject","videoPlayer","setAttribute","URL","createObjectURL","load","ex","duration","currentTime","canvas","videoWidth","videoHeight","ctx","getContext","drawImage","toBlob","blob","MUI_dev_simulator","lazy","MUI_dev_jsonconverter","MyUIOne","CSuppense","DevMenu","showFromMyUI","PureComponent","renderIntoId","divId","ReactDOM","render","ModuleDevSimulator","usingLocalBaseUrlKey","localBaseUrlKey","localConfigKey","usingLocalBaseUrl","runAfterInit","localBaseUrl","getLocalBaseUrl","localConfigJson","getLocalConfig","isUsingLocalBaseUrl","getIsUsingLocalBaseUrl","_localConfig","showUIDevSimulator","setLocalBaseUrl","setIsUsingLocalBaseUrl","newBaseUrl","setLocalConfig","newConfigJsonString","_localBaseUrl","button","appendChild","divMenu","position","MHUtils","fnReloadTable","fnGetExpandList","fnHeaderChangeExpand","fnGetCanEditOfField","fnGetCanShowOfField","fnGetCurrentProject","fnGetCurrentProjectId","fnGetConfigFromScreenConfig","fnGetListExtraData","fnGetListData","fnGetListObj","WrapResize","showLoading","customData","_cDragable","getPropertyValue","paddingRight","hideLoading","keepDragablePosition","setCustomData","getCustomData","_renderContent","configMyUI","modalProps","fnListFromModal","mydialog","configFromModal","msgHtml","logW","mypage","configMyPage","cellinmodal","myform","classNameBody","styleBody","wrapComponentBody","TagBody","_renderHeader","showHeader","dragable","onClickClose","titleBtnClose","colorBtnOK","titleBtnOK","level","_renderOverlay","_renderResize","showChangeSize","fontSize","showMiniClose","WrapModal","Draggable","PropsWrapModal","handle","r","morePropsModal","globalloading","showWithType","nextLevel","_level","_listModal","querySelectorAll","configModal","showFromMyPage","showFromMyForm","showFromComponent","showMyDialogWithInput","placeHolder","wordBreak","whiteSpace","showMyDialog","showCellInModal","propsCell","showGlobalLoading","ComponentClass","modalTransition","baseClass","top","bottom","left","right","alignItems","hideGlobalLoading","hideModalComponent","hideModalMyUI","hideComponent","hideMyPage","renderHeader","styleModalHeader","hideClose","padding","paddingBottom","marginBottom","styleByValue","styleDisabled","configIcon","configCheckbox","linkTitle","fLinkTitle","canEditF","fCanEdit","newWindow","showPhoto","maxHeight","maxWidth","noScale","styleImg","fLink","fColor","fMin","fMax","styleInput","styleControl","classNameWithColField","classNameDisabled","modal","dateTextFormat","fBorderLeftColor","fSelectValue","query","querySelectValue","queryFromParent","queryWithQuerySharedPage","clickToSelect","cbNormal","cbPositive","cbNegative","configEditIcon","configFileIcon","configTextDisplay","typeAdmin","titleConfirm","titleExpand","confirmMsg","fConfirmMsg","styleByValueField","showDisplayWithMyUI","showClear","configClear","hideWhenEmpty","hideWhenNull","fHideWhenNull","fHideWhenEmpty","fHide","showDeleteRow","showPreviewHTML","showModalMultiLanguage","configModalMultiLanguage","showTestCanEdit","configDisplay","virtualizedMin","apiCheckShowModal","overideDefaultValues","rows","needReExpand","needReloadOptionsAndList","needReloadRow","needReload","needReloadList","needReloadTable","needReloadPage","needReloadListMain","needReloadOptionsAndListMain","needSendMsg","configProgress","configPopover","configTitleTooltip","canShow","fCanShow","hideOfIds","showBlockMobile","configWarning","alwayShow","isNegative","acceptType","typeInput","typeDisabled","fPhoto","usingText","usingIconFont","styleIcon","styleText","styleTextarea","updateUIRelative","keyControlDateTime","fDefaultValues","customDefaultValues","excludeDefaultValues","htmlEditorLib","htmlEditorConfig","moreProps","formConfig","fConfigForm","canDeselect","autoTextWB","styleInherit","editorAddFields","maxChar","maxCharUnicode","allowOver","pathDataInJsonString","useCacheForDOMMeasurements","needLoadingFullRow","noReplaceData","waitApi","animation","customRowBeforeRequest","needReloadAfterUpdateFields","KMB","apiUrlAfter","tooltip","fQuery","queryCheckList","source","apiCheckList","apiSubmit","pathData","needShowModalPage","driverjs","htmlBase64","KMF","configWrapControl","flatpickr","items","styleWrapControl","isText","isOnlyTime","conditionShow","relativeTo","relativeFrom","effectedBy","htmlWhenHide","hideCondition","conditionHide","colorType","apiMethod","apiUrl","mapFields","canAddNewRow","defaultObjNewRow","maxRow","titleAddNewRow","configClientTable","classControl","appendComponent","prependComponent","configAppend","configPrepend","hint","required","showRequiredMsg","requiredMsg","invalidMsg","step","sameChange","hideVisibility","maxData","styleBase","morePropsCK5","theme","submitOnChange","usingColorOptions","configApiSourceData","moreOfNumeral","FlowGetMoreForNumeral","FlowGetBoolOfMoreFromRow","_fKey","charAt","toUpperCase","FlowGetConfigOfMoreFromRow","parseConfig","_configKey","configToast","hideProgressBar","pauseOnHover","autoClose","ToastType","showToast","_options","toast","success","showToastWithCheckMsg","defaultType","showDialog","alert","showToastSuccess","showToastError","showToastLikeToast","POSITION","BOTTOM_CENTER","showApiMsg","hideInMyModalFromProps","showLoadingScreen","hideLoadingScreen","kAuthToken","kAuthType","kAuthInfo","kAuthInfoSocial","token","infoSocial","info2FA","checkBeforeLogout","listAfterLogout","AuthConfig","loadLastSaved","authCheckSavedAuthorized","authGetAuthorizationHeader","registerCheckBeforeLogout","registerAfterLogout","_fn","authLogin","V","getInfoFromData","_info","parse2FAfromData","fa2_needenable","fa2_needverify","fa2_token","user_uniqueid","user_id","fa2_method","authLoginWithRes","access_token","token_type","HI18","changeLanguage","authLoginSocialWithRes","Token","SocialInfo","authLogoutWithNothing","authLogout","authIsLogged","authCheckLoginAgain","getUserInfo","getInfo2FA","getUserEmail","user_name","getUserAvatar","ImgAvatar","getUserLogoApp","checkShow2FAFromTokenResponse","resToken","DefaultWidthID","DefaultWidthColExpand","DefaultWidthColDelete","FlowBuildColTable_BuildExtraColumns","_addExtraColumns","addExtraColumns","_configColumnSelect","_showDetails","showDetails","_showDetailsMulti","showDetailsMulti","_detailConfig","Type","Index","CanShow","CanEdit","CanSort","Width","_configColsActions","colsActions","showColRemoveRow","CanPrint","canDelete","_isHideColDelete","hideColDelete","hideColDeleteOnSmallWidth","_typeCell","_customDelete","customDelete","_width","FlowBuildColTable_BuildOneCol","colExtra","_col","_hidden","hidden","isKey","dataField","orderNo","OrderNo","header","colProps","dataFormat","MyTableCellHelpers","_auto","_empty","colConfig","dataSort","Cls","CCls","_HeaderObj","_headerObj","headerText","MyTableHeaderHelpers","componentHeader","headerObj","hideSort","caretRender","sort","canSort","canPrint","moreColProps","FlowBuildColTable_BuildOneCol_ParseHeader","MWAS","MWASD","_w","FlowBuildColTable_BuildOneCol_ParseColWidth","regex","FlowBuildColTable_BuildOneCol_ParseCustomProps","_formatExtraData","formatExtraData","_cols","_extraColumns","Columns","_arrColumns","_colExtra","unshift","usingOrderNo","FlowGetClassNameTable","_configPageTable","hasCustomHeader","hasWrapHeader","noBorder","noBorderCol","borderLight","hasBigBorderBottom","classNameTable","forceFullExpandDetail","fixHeightStickyFooter","LOGOUT","FETCH_FS_PENDING","FETCH_FS_SUCCESS","FETCH_FS_ERROR","SIDE_NAV_CLOSE","SIDE_NAV_UPDATE","HEADER_TITLE_UPDATE","_controls","More","Direction","_objDirection","_defaultValues","_configProps","Props","Label","FieldName","Hint","Required","Disabled","Source","SourceField","Title","FlowGetConfigControlFromServer","ApiMethod","ApiContentType","ApiConfig","fnLogout","firstloadID","ApiTemp","countErrorCheckServerMaintenance","random","checkServerMaintenance","count","interpolation","escapeValue","_msgError","toJSON","apiShareError","logApi","statusCode","_url","path","hideMsgError","_status","_title","AIPUrl","urlForLogException","_userId","_userName","LogBy","Url","_match","_encrypt","encodeURIComponent","_newData","axios","logException","status","apiShareSuccess","TotalMili","_timeWaitNeedLog","_sizeWaitLog","_contentLenth","headers","sendGGNotifyLog","_apiExcept","_urlAPI","_msg","_user","userAgent","webhookURL","logWaitLongTime","StatusCode","silent","hideMsgSuccess","Msg","code","apiBuildAxiosRequestHeader","Accept","customContentType","customHeader","_authorization","Authorization","apiBuildAxiosRequestUrl","buildRequestDataForPost","requestData","UI_FirstID","AppName","DocumentWidth","screen","UI_StartAt","UI_TimezoneOffset","getTimezoneOffset","UI_Language","getCurrentLng","buildRequestData","FormData","apiBuildAxiosRequestConfig","apiDefaultAxiosRequestConfig","apiGet","apiPost","apiUpload","_formData","_files","append","apiPostForm","join","apiWithConfigApi","connect","isAuthenticated","app","ComponentGuest","componentGuest","HAuth","to","MyPageLayoutHelpers","setDefaultMyPageLayout","TagMainLayout","MainLayout","PageGenericClass","PageGenericChild","ConfigPage","createFromConfigPageServer","getMyPage","PATH","Loading","MyPage","LoginSocial","useHistory","loginSocial","signIn","useGoogleLogin","scope","onSuccess","tokenResponse","email","picture","SocialId","SocialToken","SocialUsername","onError","LoginSocialProvider","clientId","WrapSep","hasLoginGoogle","hasLoginFacebook","h5","Form","form","LogoContainer","Logo","img","SubmitSpan","span","ErrorMessage","LoginContainer","FETCH_LOGIN_PENDING","FETCH_LOGIN_SUCCESS","FETCH_LOGIN_ERROR","fetchLoginPending","fetchLoginSuccess","fetchLoginError","login","payload","dispatch","actions","grant_type","username","password","app_name","loginSuccessWithResponse","Container","mapDispatchToProps","connector","countRefresh","_redirectFromLogin","redirectAfterLogin","setUsername","setPassword","showPassword","setShowPassword","setError","rInputPassword","submit","a","useEffect","dispatchLoginSuccess","marginTop","InputGroup","InputGroupText","Input","autoFocus","onKeyDown","focus","_inputPassword","onShowPassword","alignContent","flexDirection","flexWrap","setEmail","loadingRequest","setLoadingRequest","msgSuccess","setMsgSuccess","requestForgot","ApiGeneric","Email","fontWeight","useParams","pTokenKey","tokenkey","tokenKey","setTokenkey","cfpassword","setCFPassword","showCFPassword","setShowCFPassword","validToken","setValidToken","loadingRequestValid","setLoadingRequestValid","loadingRequestReset","setLoadingRequestReset","requestValidToken","IsValid","requestReset","submitValidToken","PasswordKey","checkConfirmPassword","Password","ConfirmPassword","phone","setPhone","setName","loadingRegister","setLoadingRegister","requestRegister","UserName","DisplayName","PhoneNumber","ScreenLoading","cx","cy","fill","PageNotFoundv2","Routes","getHistory","publicRoutes","privateRoutes","blockURLNeedChangePW","block","_IsNeedCheckChangePass","pathname","_Message_IsNeedChangePass","KLocalStorage","lastFirstSetting","KObserver","after_requestFirstSetting","exact","UIUrl","APIName","UIType","fallback","Forgot","Register","Reset","PageGeneric","App","ModuleFirstSetting","_key","fnRemoveUserCodeInLocalFirstSetting","_lastFirstSetting","getMyKey","parseFirstSetting","fromLocal","requestFirstSetting","_uiAppConfig","fromServer","_needClearLocalCacheBefore","_needClearLocalCacheBeforeServer","_needClearLocalCache","_needClear","_user_id","getCFMultiLevel","fileUploadSupport","checkLanguageFromServer","fromUserLanguageCode","fromDefaultLanguage","initLanguageList","listExtLng","_dataRoutes","FlowParseDataRoutes","MyIconHelpers","MyTableCellOne","IconHi","toLocaleLowerCase","ModuleIconHiOutline","MyIconOne","MyPageHelpers","PSetting_main","MyPageOne","ModuleUserSetting","MUIGeneration2FA","MUIVerify2FA","MUICheck2FA","MUISelectMethod2FA","Generation2FA","Disable2FA","Setting2FA","Verify2FA","ModuleSetting2FA","addResourceBundle","Lang_en","showGenerate2FA","fromOneMethod","IsEnable","showVerify2FA","requestSetting","PRedirectToken","ModuleRedirectToken","WrapItem","Item1","_bg","padStart","ML_RMC","initPageDev","addTypesFromListLazy","dev_mylib_reactmulticatousel","ML_RR","total","rating","dev_mylib_reactrater","MyLibsAll","RMC","RR","DevMyLibs","_lib","Demo","des","col","gap","border","borderTop","HFakeData","getHextColor","getLoremWithRandom","dev_mylayout_grid","MyLayoutAll","MLG","DevMyLayout","Dev_Demo","dev_mymodal","dev_myloading","Form_LocalStorage","Form_HideCondttion","dev_myform","dev_myform_localstorage","dev_mybase","PDev_ListMyControl","PDev_CategoryList","PDev_MyPage","PDev_MyForm","PDev_Notification","PDev_Other","PDev_Resize","PDev_UseScript","PDev_CustomHook","PDev_Common_Config","DevMyLayoutAll","Dev_MyModal","Dev_MyLoading","Dev_MyForm_All","Dev_MyBase_All","ModuleDev","dispatchFromStore","isDev","HUtils_getTextWithData","KConfigMyUI","getMoreProps","getData","_moreData","_configFormat","getStyle","getTypeMyLayout","getTypeMyUI","MyUI_Data_Obj","_configChild","configChild","MyUI_Data_Array","MyUI_Data_Tag","_childIsMyUI","_childIsText","_textDisplay","_fontSize","_fontSizeInStyle","_minFontSize","minFontSize","clientHeight","scrollHeight","clientWidth","scrollWidth","StateLoading","StateError","configError","msgError","WrapUI","onTryAgain","StateWrap","configLoading","ListNoLazy","MUI_html","data_obj","MUI_data_obj","data_array","MUI_data_array","data_tag","MUI_data_tag","data_span_autoresize","MUI_data_span_autoresize","state_error","MUI_state_error","state_loading","MUI_state_loading","state_wrap","MUI_grid_autofit","MUI_grid","List","title_content","grid","grid_autofit","flex","MyLayoutHelpers","simulator_sender_email","MC_with_myui","with_myui","MyCardOne","MyCardHelpers","ML_threedotsvertical","arc","threedotsvertical","lds_ellipsis","MyLoadingHelpers","ModuleCorePage","MyLayoutOne","MyLoadingOne","trackPageView","gtag","ModuleReactGA","isUniversal","ReactGA","send","hitType","page","ReactGA4","gaTrackCurrentPageView","initGAdone","isUsingDev","hash","gaTrackPageView","gaTrackEvent","category","GAIdDev","initDefault","GAId","initialize","initGA","runFunctionInModuleFnList","listen","MyPageWelcome","MP_iframe","MyPageAdminTab","MyPageAdminTable","MyPageAdminPanel","MyPageAdminPanelGrid","MyPageAdminTableClient","MyPageAdminPageNotFound","MyPageWithMyUI","MyPageAdminDashboard","MyPageAdminList","MyPageAdminListCard","MyPageAdminGridCard","MyPageMyProfile","MP_MyProfileSignatureEmail","MP_MyProfileSignaturePhoto","MyPageApiRequest","MP_redirect","MP_mobile_dashboard","MP_chart_chartjs","MP_chart","MP_grid","MP_wrap","MP_calendar","MP_dashboard_one","MP_flow","MP_html","MP_admin_tab_client","MP_report","MP_report_html","MP_report_array_html","MP_report_array_photo","MP_report_table","MP_report_chart","MP_report_signature","MP_report_layout","MP_report_multi_table","MP_report_title_browser","MP_widget","MP_multi_table","MP_survey","map_goong","survey","multi_table","widget","report","report_title_browser","report_html","report_table","report_array_html","report_array_photo","report_chart","report_signature","report_layout","report_multi_table","admin_tab_client","flow","dashboard_one","calendar","wrap","chart_chartjs","chart","admin_tab","admin_table","admin_panel","admin_pagenotfound","admin_table_client","admin_dashboard","admin_table_list","admin_table_list_card","admin_table_grid_card","welcome","panel","panel_grid","table","tab","table_list","table_list_card","table_grid_card","myprofile","myprofile_signature_email","myprofile_signature_photo","api_request","iframe","redirect","mobile_dashboard","MUIATHeader","MUIATChart","MUIATHeaderDetail","MUIATHeaderMini","MUIATHeaderButtons","MUIATFilter","MUIATFilterDetail","MUIATTable","MUIATTableDetails","module","MUIATTableList","MUIATTableListCard","MUIATTableGridCard","MUIATTableCalendar","MUISelectBox","MUISelectBoxSearch","MUI_select_box_search_paging","MUISelectBoxSearchV2","MUISelectCheckBoxSearch","MUIMsgBoxConfirm","MUIMsgBoxError","MUIAnimate","MUIFileManager","MUIFileManagerItem","MUIArrTags","MUIActionMenu","MUILayoutSquare","MUISearchBox","MUIATFilterPopover","MUIWrapCellOnModal","MUIWrapEditRowInCard","MUI_avatar","MUI_html_canedit","MUI_Api_Client","MUI_Select_Box_Search_Virtualized","MUI_Block_Mobile","MUI_Obj_Editor","MUI_Json_Viewer","MUI_timeline","MUI_list_check","MUI_list_check_api","MUI_table_check","MUI_diffview","MUI_modal_request_diffview","MUI_search_box_withdata","MUI_btn_take_photo","MUI_scanqrcode","MUI_admintable_flow","MUI_select_month","MUI_print_bill","MUI_map_goong","MUI_masu_addproduct","MUI_masu_cell_attribute","MUI_masu_cell_editproduct","_wrapEditRowInCard","_wrapCellOnModal","masu_addproduct","masu_cell_attribute","masu_cell_editproduct","print_bill","select_month","html_canedit","admintable_flow","scanqrcode","btn_take_photo","search_box_withdata","json_viewer","timeline","admintable_filter_popover","admintable_chart","search_box","layout_square","actions_menu","arr_tags","selectcheck_box_search","admintable_header","admintable_header_detail","admintable_header_mini","admintable_header_buttons","admintable_filter","admintable_filter_detail","admintable_table","admintable_table_details","admintable_table_list","admintable_table_list_card","admintable_table_grid_card","admintable_table_calendar","select_box","select_box_search","select_box_search_paging","select_box_search_v2","msgbox_confirm","msgbox_error","animate","file_manager","file_manager_item","api_client","select_box_search_virtualized","block_mobile","obj_editor","list_check","list_check_api","table_check","diffview","modal_request_diffview","typeItem","numCol","_templateColumns","_numCol","minmaxAutoFit","minmaxAutoFill","gridTemplateColumns","renderItem","allData","configItem","morePropsItem","MB_link","MB_api","MB_api_select","MB_form","MB_add_new","MB_upload","MB_print","MB_switch_view","MB_switch_request","MB_modal","MB_modal_page","MB_group","MB_linktaga","MB_action_fnList","MB_tutor","MB_modal_html","MB_info_from_api","MB_input_qr","MB_with_myui","MB_select_to_diffview","input_qr","info_from_api","modal_html","tutor","action_fnList","linktaga","api","api_select","add_new","upload","print","switch_view","switch_request","modal_page","group","select_to_diffview","MyButtonOne","MyButtonHelpers","MyLayoutArchitect","ML_wfc_inline","wfc_inline","MTCReadonly","MTCTextarea","MTC_textarea_with_count","MTCApi","MTCJsonEditor","MTCCheckbox","MTCCheckboxNull","MTCExpandMulti","MTCSelect2Modal","MTCSelect2ModalApi","MTCSelectModern","MTCDelete","MTCTextareafull","MTCLink","MTCNotexist","MTCFiles","MTCDate","MTCDateTime","MTCDateText","MTC_datetime_text","MTCArrayEditableModal","MTCActionsMenu","MTCActionsMenuMulti","MTCForm","MTCReadOnlyArray","MTCurrency","MTCNumberDecimal","MTCNumberNatural","MTCNumber","MTCListText","MTCWithMyUI","MTCActions","MTC_readonly_date","MTC_pickcolor","MTC_chromecolor","MTC_readonly_html","MTCJsonEditorValue","MTCSuperMan","MTCReadonlyWithTree","MTC_modal_table_extra","MTC_quality","MTC_readonly_status","MTC__barTopRight","MTCSelect2ModalTable","MTC__SelectOnModal","MTC_html_editor","MTCFormModalTable","MTCDevTest","MTCSelect2","MTC_cs_email_tp_action","MTC_readonly_datetime","MTC_readonly_percent","MTC_readonly_progress","MTC_percent","MTC_checkbox_disabled","MTCTestCanEdit","MTC_quantity","MTC_modal","MTC_select_icon","MTC_select_tag","MTC_text_select","MTC_array_editable","MTC_upload_one_photo","MTC_date_native","MTC_remove_row","MTC_suggest_address","MTC_pos_printbill","pos_printbill","suggest_address","actions_menu_multi","remove_row","date_native","textarea_with_count","upload_one_photo","array_editable","text_select","select_tag","_select_on_modal","_barTopRight","cs_email_tp_action","dev_test","form_modal_table","html_editor","select2_modal_table","readonly_status","quality","modal_table_extra","readonly_with_tree","superman","readonly_html","chromecolor","pickcolor","readonly_date","list_text","number_decimal","number_natural","input_format_numeral_money","readonly_array","array_editable_modal","date","datepicker","datetime","date_text","datetime_text","readonly","select","select2_modal","select2_modal_api","select_modern","textarea","textareafull","json_editor","json_editor_value","checkbox","checkbox_null","expand_multi","expand_api","delete","notexist","files","readonly_datetime","readonly_percent","readonly_progress","checkbox_disabled","test_canedit","quantity","percent","select_icon","cell","extra","_moreObj","TagCell","isHide","oneTableCell","_valueCell","MTHstyled","MTHhtml","MTHcheo","MTHtooltip","cheo","diagonal","MyTableHeaderOne","MFCText","MFCAlert","MFCTextarea","MFCSelect2","MFCDatePicker","MFCNumberDecimal","MFCNumberNatural","MFCNumber","MFCCurrency","MFCPassword","MFC_checkbox","MFC_readonly","MFC_layout_row","MFC_layout_grid","MFC_layout_group","MFC_timepicker","MFC_timepicker_text","MFC_datepicker_text","MFC_arrtext","MFC_select_tag","MFC_datetimepicker","MFC_select_table_api","MFC_custom","MFC_checkbox_yesno","MFC_checkbox_inbox","MFC_percent","MFC_range","MFC_files","MFC_textareafull","MFC_readonly_html","MFC_html_editor","MFC_selectlist","MFC_selectlist_check","MFC_suggest_address","MFC_table","MFC_group_checkbox","MFC_multi_input","MFC_signature","MFC_select2_api","MFC_selectlist_check_api","selectlist_check_api","select2_api","signature","multi_input","group_checkbox","selectlist_check","selectlist","layout_row","layout_grid","layout_group","timepicker","timepicker_text","datepicker_text","arrtext","datetimepicker","select_table_api","checkbox_yesno","checkbox_inbox","range","MFCW_ngang","ListWrapLayout","form_ngang","form_horizontal","form_row","getIsNumeral","BaseNumeral","getInputType","inputType","getPropsValues","defaultValueWhenNull","spellCheck","BaseSelect","getIsSelectCheck","SelectCheck","HOptions","getOptionByValue","MB_textareafull","MB_numeral","MB_select2","MB_select2_api","MB_switch","MB_checkbox","MB_checkbox_yesno","MB_checkbox_styled","MB_date_flatpickr","MB_date_flatpickr_selectmonth","MB_datefromto_flatpickr","MB_daterangepicker","MB_monacoeditor","MB_range","MB_select_tag","MB_select_tag_button","MB_selectlist","MB_selectlist_check","MB_date_native","MB_text","MB_textarea","MB_select","date_flatpickr_selectmonth","monacoeditor","daterangepicker","switch","checkbox_styled","date_flatpickr","datefromto_flatpickr","select_tag_button","MyBaseOne","MyBaseHelpers","MTFCSelect2","MTFCSelect2Content","MTFCSwitch","MTFCCheckbox","MTFCDateFromTo","MTFCDateFromToText","MTFCText","MTFC_select2_multi","MTFC_select2_modal","MTFC_select2_modal_api","MTFC_select_month","MTFC_month_year","month_year","datefromto","datefromto_text","select2_multi","select2content","MyTableFilterControlOne","MyTableFilterControlHelpers","ConfigByType","getFilterOut","oneFilter","_isServer","_valueDisplay","_valueFilterServer","_valueFilterClient","valueFilterServer","valueFilterClient","getCustomFilter","filterOut","callbackParameters","targetVal","itemP","_startMili","_endMili","endOf","Filter","itemOut","_testDisplay","_from","_to","end","MLSelect2","ML_select2_required","MLMonacoEditor","ML_chromepicker","ML_code_mirror","ML_diff_viewer","ML_draft_wysiwyg","ML_react_rte","ML_ckeditor5","ML_ckeditor5_min","ML_ckeditor5_email","ML_pdfexpress","ML_dearflip","big_calendar","dearflip","pdfexpress","ckeditor5","ckeditor5_min","ckeditor5_email","draft_wysiwyg","react_rte","diff_viewer","code_mirror","chromepicker","select2_required","MyLibOne","MyLibHelpers","gg_column","gg_line","gg_pie","gg_area","gg_bar","gg_bubble","gg_combo","gg_timeline","gg_orgchart","gg_material_bar","chartjs_line","chartjs_bar","chartjs_pie","MyChartOne","MyChartHelpers","card_row_email_template","kCategoryScreen","ConvertType","dashboard","ModuleCategoryScreen","updateRoutes","requestCategoryScreen","callAfterLogin","convertUIType","parseData","forceChange","_just404","FlowForceUpdateRoutes","_isDifference","kSideMenu","kAppMenu","kAppLogo","ModuleProjectScreen","initLastSaved","requestProjectScreens","sidemenu","appmenu","appLogo","side_menu","app_menu","_sideMenu","_app_menu","KEventsApp","ee_sidemenu_forceupdate","ModuleAdminPanel","MyFormControlOne","CategoryScreen","ProjectScreen","LazyLoading","kDivId","kLocalShowedChromeNotify","kPathSWNotify","WrapDiv","NotifyQuestion","animationIn","animationInDuration","animationOut","isVisible","querySelector","ModuleChromeNotification","cbSuccess","subscribe","checkExist","ready","serviceWorkerRegistration","pushManager","getSubscription","sub","getKey","encode","buffer","btoa","Uint8Array","swregister","userVisibleOnly","applicationServerKey","pushSubscription","endpoint","_currentLocalShowed","hasPushNotify","_divNotify","_contain","createPortal","notifySignalR","ModuleSignalR","getReturnValues","countDown","TextDisplay","days","hours","minutes","seconds","CheckIdleCountDown","countSeconds","isExpired","targetDate","forceStop","stopWhenFinish","countDownDate","needStopInterval","setCountDown","interval","setInterval","clearInterval","_countDown","useCountdown","totalSeconds","checkidle_countdown","MUI_checkidle_countdown","CheckIdleStatus","KCheckIdle","ModuleCheckIdle","resetTimerDebounce","updateTimeIdle","timer","timerIncrement","checkAfterSecond","onIdle","countdown","onTimeout","ee_onfocus_after_signout","updateRemainSecond","totalSecondCountdown","updateExpired","_current","_currentStatus","getCurrentStatus","onSignOut","onKeepSignIn","onBackToSignIn","visibilityState","toISOString","idleAfterSecond","resetTimer","_currentTime","_currentTimeIdle","LodashThrottle","_hasCheckIdle","_checkSecond","_checkCountdown","_checkIdleInterval","MP_prj_manager","MP_prj_info","MP_prj_api","MP_prj_task","MP_prj_dailytask","MP_prj_dailytask_detail","MP_prj_schedule","MP_prj_users","MP_prj_releases","MP_prj_infoenv","prj_flow","prj_info","prj_api","prj_task","prj_dailytask","prj_dailytask_detail","prjmanager","prj_users","prj_releases","prj_infoenv","prj_schedule","MUICard_Task","MUINewDailyTask","MUINewProject","MUITaskItem","MUINewTask","MUIUserSetting","MUIProjectItem","MUIAPITestCase","MUIAPISetting","card_task","prj_new_project","prj_task_item","prj_new_task","prj_new_release","prj_task_user_setting","prj_pj_item","prj_api_testcases","prj_api_setting","prj_set","ModuleQLProject","wcontent","unsupportedmedia","a_row_form","input_currency","input_percentage","input_text","input_number","group_controls","input_date","input_date_string","input_address","checkbox_custom","readonly_text","check_inbox","check_yes_no","check_option_radio","select2_icon_option","input_textarea","readonly_html2","input_textarea_autosize","mc_files","v1_mfc_select2","MyControlSMSFOne","MyControlHelpers","V1_mfc_mycontrol","ListControl","MyFormControlSMSFOne","typeControl","only_label","v1_mfc_group_row","array_form","MyControlForm","react_google_places_autocomplete","react_google_places_autocomplete_custom","ModuleAppCRMHF","MyControlOne","initialState","closeSideNav","sideNavItems","dataFirstSetting","textSearch","modeSearch","initialReducer","produce","draft","mode","ThemeOptions","combineReducers","reducerRegistry","_emitChange","_reducers","getReducers","listener","enhancer","composeEnhancers","compose","applyMiddleware","thunk","initReducer","setChangeListener","reducers","store","replaceReducer","combine","createStore","MP_Css_2React_Style","MP_API_Document","MP_Demo_ButtonList","MP_Demo_FormControl","MP_Demo_Form","MP_Demo_TableCell","MP_Demo_TableTotal","MP_Demo_TableFilter","MP_Demo_MyUI","MP_Demo_Libs","MP_Demo_Dashboard_one","MP_Demo_ChartJS","MP_Demo_GGChart","MP_Test_InputRange","MP_Test_Camera","MP_Demo_Table","MP_Demo_Table_Span","MPD_dt_multi_table","MPD_dt_table_footer","demo_docs","demo_table_footer","demo_multi_table","test_input_range","test_camera","css_2react_style","api_document","demo_buttonlist","demo_formcontrol","demo_form","demo_table","demo_table_span","demo_tablecell","demo_tabletotal","demo_tablefilter","demo_myui","demo_libs","demo_dashboard_one","demo_chartjs","demo_ggchart","ModuleAppDemo","sendWebhook","resp","fetch","force","_webHook","DFLanguage","AppConfig","GooglePlaceApiKey","autoRedirectLoginPageNotFound","defaultTagInputCell","charSplitArray","showClearLocalCache","Goong_APIKEY","autoRedirectHomePage","GGNotifyWebHook","logout","defaultNS","en","common","vn","Lang_vn","vi","HLog","updateHeaderTitle","fnGetRequestUIAppConfigFirstSetting","expandIconHideColor","defaultLanguage","ModuleCore","ModuleSetting","ModuleCheckIDLE","ModuleAppVFC","numeralFormatMoney","isCheckInvalidProjectId","ignoreNoProjectId","timeFormat","dateFPFormat","datetimeFPFormat","symbolDecimal","symbolThousand","expandBgColor","styleDefaultCell","hideEffectAddNew","hideEffectDelete","hasSettingPage","hasChangeLanguage","listLng","WrapDropzone","accept","HUpload","fnUpdateAccept","cb","onDrop","acceptedFiles","fileRejections","globalDropzone","getRootProps","getInputProps","MyModalWrap","ModuleGTag","GTMKey","GTMIdDev","ProviderGTAG","_gtagID","MLib","HCore","I18nextProvider","i18n","hasSignalR","getMore","getClassCol","classCol","getIsCheckListYesNo","isCheckListYesNo","isSelectCheck","getNoDecimal","getOptionNegative","negativeValue","negativeText","getOptionPositive","positiveValue","positiveText","getOptionAll","allValue","allText","keyValue","keyDefaultValue","_propsValues","KLocalLanguage","currentLng","currentLngLocalStorage","defaultLng","listPathLoadedExtLng","getCurrentLngFlagUrl","_code","hasLngInList","saveLocal","setItem","changeLanguageOnUI","needCallApi","cbLoading","cbError","Values","NewValue","_lngInLocalStorage","LanguageList","loadExtLngFromFile","getPathFromCodeInListLng","Path","isDefault","_path","_M","AppBuildVersion","Modules","Api","Name","UpdateFields","MyTableCell","Auth","ExtModulesName","sidenavitems","showProjectHeader","showAddNew","isCheckInvalidProject","tableProps","hasExpand","Detail","titleField","controller","KMoreOfFormControl","FlowGetConfigFormControlFromV1","_propsControl","_configFormControl","FlowMergeWithCustomProps","merge","FlowGetMoreOfKey","FlowGetDisabledOfControl","_disabledForm","FlowGetCanShow","_currentValues","_conditionHide","_willHideByCondition","_conditionShow","isCondition","conditionFormat","valueOfField","_valueExpected","_valueOfField","FlowGetSameChange","optionItem","concat","_fFrom","fieldRelative","_fieldParent","resetFormControl","isHasFn","FlowFCGetDefaultValueControlSelect","cfc","isReset","isMulti","sourceData","charSplit","_valueControl","valueControl","_splitValue","_option","AHOptions","FlowFCGetSelectedControlSelect","valueSelect","itemOption","FlowFCUpdateValueControlSelect","setValueControl","_valueSelect","_charSplit","_index","updateValueControl","currArr","newItem","mergeRecursive","obj1","obj2","constructor","getDataBySort","sortByField","sortType","sortDataType","_sortType","_sortDataType","_itemA","_itemB","_compare","FlowPrintHtml","htmlString","autoPrint","onbeforeprint","onafterprint","_idPrintfGloabl","_idPrintfGloablIframe","_eContain","el","_eIframe","contentDocument","write","frames","_height","contentWindow","execCommand","FlowConvertSelectedMultiToArrayOptions","valueSelected","arraySplitChar","_arrSelected","_valueSelected","filter","HOptionsGetArrayOptionFromArrayValue","arrValue","_arrOption","_arrValue","HOptionsGetItemOfValueFromOptions","HOptionsGetNextItemOfValueFromOptions","OneTableCell_getConfigForm","customMore","_configForm","getConfigForm","HLink_updateParamOnUrl","isReplace","_allPrams","_newUrl","HLink_updateUrlWithAllParams","allParams","updateUrlWithoutReload","_indexQuestionMark","lastIndexOf","_updateUrlWithoutReload","HLink_setNewUrlWithoutReload","replaceState","pushState","HUtils_getTextOrHTML","showLoadingWhenFilter","needRebuildColAfterGetList","buildColsAfterReloadList","hideSizePerPage","optionsTable","hasPagingRemote","deleteTitle","deleteContent","deleteContentHtml","deleteWithNote","fDelete","styleHeader","belowTable","needReloadChartAfterUpdateFields","hideTableWhenEmpty","configSelectRow","canSortByField","fixHeightScrollTable","fixHeightStickyNumColumn","showTotal","configTotal","needReloadAfterDelete","showLoadMore","autoLoadMore","autoLoadMoreMode","autoLoadMoreOffset","noWrap","hasAddNewAtBottom","btnAddNewAtBottom","defaultHeaderAlign","headerAlignByField","defaultHeaderStyle","headerStyleByField","headerColPropsByField","defaultOrderNo","showLoadingRowWhenRequestUpdateRow","isRenderFooterByField","loadMoreSelectorScroll","isAvoidBreakPrint","hideHeaderWhenNoData","maxWidthByColumnWidth","maxWidthPercent100","loadMoreAutoSwitchScrollWindow","customQueryFromSever","searchServer","needCheckLastItemQueryServer","KConfigPageDetail","needReloadMaster","needReloadMasterAfterDeleteItem","needReloadMasterAfterUpdateField","needReloadMasterAfterAddNew","needReloadMasterAfterSubmitModal","needReExpandAfterReloadMasterFromDetail","needReExpandAfterAddNewFromDetail","KConfigPageHeader","hideTitle","hideButtons","usingButtonTypeInMore","preButtons","sufButtons","onlyShowButtonInSmallWidth","KConfigPagePage","topTable","topHeader","belowHeader","belowFilter","topPage","footerPage","configFlow","configCard","hasSwitchView","listSwitchView","defaultSwitchView","prefixId","configChart","configMultiTable","listChart","headerChart","footerChart","KConfigPage","hideLoadingReport","hasEditMode","hasSetting2FA","showClassFieldOnCell","signalRHub","signalRKey","mtf_datefromto_showRange","defaultStyledTab","hasSwitchTheme","KConfigModal","fTitle","typeMyPage","KApiName","Options","_currentSearchText","_componentTable","_componentTableLoading","_forceUpdateTable","_waitingComponentTableForFilter","_configRowById","_isShowLoadMore","_configLoadMore","_noLocalFilter","_loadedList","_dataTotal","_isPanel","_isInPanel","_isLoadedDefaultScreenConfig","UI_LoadOptionError","KConfigTableHeader","KConfigInConfigPage","needWaitingOptions","configGrid","wrapLayout","wrapType","noLocalFilter","wrapStyle","classNameWrap","styleTab","styleTabActive","styleItem","hideTabOnlyOneTab","KTypeCellControl","KMyUITypeCommon","kRequestFromClient","UI_TextSearch","UI_Sorts","KRowMore","_UI_NeedUpdateUIByFields","UI_MergeRowByField","UI_Span","UI_StyleRow","UI_StyleRowByField","UI_ClassTableRow","UI_ClassTableCell","UI_ComponentAppendCell","UI_DefaultShowExpand","UI_ShowRemove","_fnForceUpdateDetail","kClientKeyUI","_UI_Missing","_RelativeByField","_usingLocalBaseUrl","KClassBody","appFullContainer","beforeSearchTable","beforeFilterTable","after_login","after_request_list","useTheme","themeSeason","fnGetConfigFilter","KConstant","_NullOrEmpty_","kMyUICore","logExistType","logNoAnyType","logParseJson","logTest","RoutesPublic","RoutesPrivate","RoutesTest","FlowConvertUIType","HRoutes","listIdNoSidebar","checkNoSidebar","_Routes","FlowApiPost","FlowApiGet","request","cbFinal","successCallBack","errorCallBack","FlowApiUpdateFields","apiController","apiName","multiObjUpdate","sharedRequestData","ProjectId","_target","_autoOpenLink","FullPathNewWindow","_isDownload","FullPathDownload","_linkOpen","FullPath","isIphone","FullPathTitle","wordWrap","FullPathInfo","download","FullPathName","FullPathList","FullPathListName","KMoreOfTableCell","KConfigInRow","_UI_Loading","_UI_Error","_UI_NeedUpdateUI","KTypeCellShared","FlowGetExtraDataFromExtra","FlowGetFieldNameFromExtra","FlowGetExtraOfFieldName","_extraCol","FlowTableExtraData","defaultCanShow","FlowActionClickApi","FlowGetFValue","FlowGetFText","FlowActionClickForm","_link","FlowParseResponseAndNeedReload","_configApi","getConfigApi","onReloadPage","onReloadList","onSendMsg","onReExpand","onUpdateRow","newRow","_fnReloadOptionsAndListOfMain","_fnReloadListOfMain","FlowCheckShowModal","_configModal","_canShowModal","canShowModal","fCanShowModal","FlowGetRequestFromConfigObj","_request","FlowGetRequestQueryFromConfigObj","queryByField","_queryFromConfigApi","FlowCheckApiShowModal","_configCheckShow","activeElement","blur","IsShow","_resultModel","configFormFromServer","ConfigForm","FlowCheckConfirmMsg","_confirmMsg","_confirmTitle","FlowGetConfigButton","_configButton","FlowGetMorePropsButton","forceValue","isBoolean","outline","colorByValue","fTitleTooltip","titleTooltip","fDisabled","FlowUpdateRelativeByField","fEdit","checkChange","FlowGetConfigMyUI","_configMyUI","FlowRenderIconFromMore","isActive","_isActive","_icon","hideWhenNoActive","styleInactive","FlowGetScreenCodeFromCell","FlowGetTextOrHTMLWithI18n","_ns","FlowGetTextDisplay","valueCell","isButton","_configTextDisplay","FlowGetConfigTextDisplayOfButton","getTextDisplay","FlowGetCustomDisplay","defaultConfigDisplay","dataIsRow","_configDisplay","showShortText","_countShort","countShort","iconByValue","hasIconAndText","canEdit","_ui","using","_maxHeight","_maxWidth","_styleImg","_linkPhoto","_uiIcon","FlowGetStyleInput","_styleInput","defaultStyle","FlowGetMoreAttrsInput","_attrs","defaultAttrs","notUseFieldName","customTitle","_extraOfColumn","_objHeader","FlowGetTitleTooltipOfColumn","_configTitleTooltip","FlowGetTableConfig","FlowGetFnList","fnGetTableConfig","FlowGetConfigTrueByAllLevel","_configInTableConfig","FlowGetBackgroundStyleCell","bgF","FlowGetStyleControlOfCell","overideStyle","_styleDefaultCell","_styleInRow","StyleRow","Style","getTextWB","colorF","_moreStyle","borderLeft","FlowGetClassCell","defaultClass","ClassName","FlowGetCanEdit","_canEdit","IsLocked","_arrcanEditF","lockF","fLock","_fLock","_arrLock","_fielsEffect","fielsEffect","fKey","FlowClickToSelectInput","FlowGetDateFormat","keyConfig","_formatFromKeyConfig","FlowGetDateTimeFormat","FlowGetColor","defaultColor","_color","FlowGetIsUpdatingCell","FlowAfterUpdateCell","forceNeedReload","_arrFieldNeedReload","_fieldNeedReload","FlowUpdateCell","alwaysUpdate","fnForceUpdateCell","fnSuccessCallBack","_canUpdate","fnUpdateUILoading","fnUpdateUIError","FlowGetQueryFromConfigQuery","configQuery","_newQuery","FlowRenderLoading","uiLoading","FlowRenderOverlay","FlowCheckUpdateValueAfterWillReceiveProps","nextProps","valueDefault","newCell","_UI_NeedUpdate","needUpdate","FlowAddNeedUpdateUIByFields","fieldNeedUpdate","FlowUpdateOtherFieldRelative","relativeOfField","FlowGetCustomDefaultValueFromRow","FlowGetDefaultValueFromRow","dataFromApi","_defaultValuesForm","_newDefaulValues","FlowGetNeedReloadForCell","_forceNeedReload","FlowUpdateQuery","currentQuery","_qureySharedMyPage","FlowShowLoadingFullRow","fnForceUpdateTableBody","FlowUpdateWaitingApi","FlowSetConfigCellInRow","FlowGetOnePageFromOneTableCell","FlowGetConfigRows","FlowGetConfigRowById","_configRows","FlowSetConfigInRow","_configInRow","FlowGetConfigInRow","FlowGetConfigCellInRow","FlowGetConfigWaitingCellInRow","FlowForceUpdateTable","FlowForceUpdateTableRow","FlowAddConfigJustNewInRow","needForceUpdate","FlowGetConfigJustNewInRow","FlowAddConfigJustDeleteInRow","FlowGetConfigJustDeleteInRow","FlowAddConfigLoadingInRow","FlowGetConfigLoadingInRow","FlowGetColumnFromExtraData","FlowGetMoreFilterOfCellFromExtraData","_moreFilterObj","FlowGetMoreOfCellFromExtraData","FlowGetMoreOfCellFromExtraColumn","Dashboards","AppMain","ErrorBoundary","resetErrorBoundary","onReset","prevProps","prevState","resetKeys","some","is","changedArray","onResetKeysChange","fallbackRender","FallbackComponent","WrapError","ErrorFallback","stack","_justReloadOne","_needReload","role","ImgIconError","Main","closedSmallerSidebar","handleWidth","withRouter","isStringDate","isHexColorString","platform","userAgentData","isEmpty","getOwnPropertyNames","isArguments","getDateWithString","isStringHourMinute","getDateWithHourMinute","_date","setHours","setMinutes","getStringHourMinuteFromDate","padString","getHours","getMinutes","getStringDateFromDate","removeObjectFromArrayByFieldValue","fieldValue","mergeDeepObjects","merged","isHasDoubleByte","addClassBody","cls","getParentNodeHasClass","classParent","deep","parentNode","contains","js","contextAsScope","Function","cloneObj","OptionsInfo","KEmptyOptionValue","getSourceDataWithEmptyItem","_source","getListSelectTagBySourceData","noAddAutoEmpty","_text","convertSourceDataToString","getTextByValue","convertSourceDataToArrayValue","getSourceDataFromSourceList","getSourceListFromFnList","isHasLevelOptionKey","convertOptionKeyLevelMissingField","fieldNames","_countDot","_add","getOptionsByLevel","_newOptionKey","_split","_prefixK","_k","_hasItem","isExistValueInSourceList","_isExist","openAndUpload","beforeUpload","afterUpload","dataURItoBlob","dataURI","byteString","atob","unescape","mimeString","ia","Blob","toggleSideNav","sideNavUpdate"],"mappings":";wSAeMA,EAAWC,IAAOC,IAAV,kpBAiCRC,E,kDAaJ,WAAYC,GAAQ,IAAD,8BACjB,cAAMA,IAbRC,cAAgB,GAYG,EAXnBC,SAAqB,GAWF,EAVnBC,YAAc,GAUK,EATnBC,iBAAwB,GASL,EARnBC,eAAsB,GAQH,EAPnBC,oBAAsB,GAOH,EANnBC,eAAsB,GAMH,EALnBC,cAAqB,GAKF,EAJnBC,wBAA+B,GAIZ,EAHnBC,eAAsB,GAGH,EAFnBC,qBAA4B,GAET,EADnBC,kBAAyB,GACN,EAQnBC,aAAe,WACb,IAAQC,EAAc,EAAKd,MAAnBc,UACJA,GACFA,EAAUC,QAXK,EAcnBC,iCAAmC,WACjC,IAAQC,EAAe,EAAKjB,MAApBiB,WACR,GAAIA,EAAWC,cACb,cAAcC,OAAOC,KAAKH,EAAWC,eAArC,eAAqD,CAAhD,IAAIG,EAAC,KACR,EAAKpB,cAAcoB,GAAKJ,EAAWC,cAAcG,KAlBpC,EAsBnBC,uBAAyB,WACvB,IAAQL,EAAe,EAAKjB,MAApBiB,WACR,GAAIA,GAAcA,EAAWM,SAAU,CACrCC,QAAQC,KAAK,0BAA2BR,EAAWM,UACnD,IAAK,IAAIG,EAAI,EAAGA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F,WAAW71C,GAEhC,OAAO,IAAIm2H,KAAK,CAACD,GAAK,CAAE1xH,KAAMyxH,MAInB9qB,O,gCCnEf,oJAEajC,EAAS,iBAAO,CAC3B1kG,KAAMyjB,MAGKmuG,EAAgB,iBAAO,CAClC5xH,KAAMyjB,MAGKouG,EAAgB,SAAA7uH,GAAI,MAAK,CACpChD,KAAMyjB,IACN8gC,MAAOvhD,IAuBIkiG,EAAoB,SAAA3kG,GAAK,MAAK,CACzCP,KAAMyjB,IACNljB,MAAOA,M","file":"static/js/main.a6481f16.chunk.js","sourcesContent":["import React from \"react\"\r\nimport { Button, Form } from \"reactstrap\"\r\nimport { HValid, HUtils, HIs, HJson, OneButton } from \"@macashipo/mlib\"\r\nimport { fnListMyForm, kresetFormControl } from \"src/helpers/fnList\"\r\nimport MyFormControl from \"./MyFormControl\"\r\nimport { KMoreOfForm } from \"src/helpers/Flows/Form\"\r\nimport i18next from \"i18next\"\r\nimport styled from \"styled-components\"\r\nimport {\r\n FlowFnListFromExtControl,\r\n FlowUpdateRelativeControls,\r\n} from \"src/helpers/Flows/FormControl\"\r\nimport { showToastWarning } from \"src/core/helpers/ui\"\r\nimport { HApi } from \"src/core/helpers\"\r\n\r\nconst WrapForm = styled.div`\r\n & form > .a-content {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n & form > .a-loading {\r\n position: absolute;\r\n left: 0;\r\n top: 0;\r\n width: 100%;\r\n height: 100%;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n background: #f1f1f133;\r\n }\r\n & .aa-footer {\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n & > * {\r\n margin-right: 0.5rem !important;\r\n }\r\n }\r\n & .a-footer-right {\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-end;\r\n & > * {\r\n margin-left: 0.5rem !important;\r\n }\r\n }\r\n`\r\nclass MyForm extends React.Component {\r\n currentValues = {}\r\n toucheds: string[] = [] //danh sach field da tac dong\r\n errorsValid = {} //danh sach loi, check valid\r\n relativeControls: any = {} //{a:[\"b\",\"c\"]}//field a -> anh huong toi b c\r\n effectControls: any = {}\r\n controlsByFieldName = {}\r\n fieldsRequired: any = []\r\n fieldsInvalid: any = []\r\n controlsOptsByFieldName: any = {}\r\n fnListFromWrap: any = {}\r\n fnListFromExtControl: any = {}\r\n fnListFormControl: any = {}\r\n constructor(props) {\r\n super(props)\r\n this.state = {\r\n isLoading: false,\r\n }\r\n this._buildRelativeControls()\r\n this._initCurrentValuesByDefaultValue()\r\n }\r\n closeMyModal = () => {\r\n const { inMyModal } = this.props\r\n if (inMyModal) {\r\n inMyModal.hide()\r\n }\r\n }\r\n _initCurrentValuesByDefaultValue = () => {\r\n const { configForm } = this.props\r\n if (configForm.defaultValues) {\r\n for (let k of Object.keys(configForm.defaultValues)) {\r\n this.currentValues[k] = configForm.defaultValues[k]\r\n }\r\n }\r\n }\r\n _buildRelativeControls = () => {\r\n const { configForm } = this.props\r\n if (configForm && configForm.controls) {\r\n console.warn(\"_buildRelativeControls:\", configForm.controls)\r\n for (let i = 0; i < configForm.controls.length; i++) {\r\n let _control = configForm.controls[i]\r\n let _fieldName = _control.fieldName || \"\"\r\n let _more = _control.more\r\n //bo sung tu type layout -> chuyen vao xu ly trong ham FlowUpdateRelativeControls\r\n // if (\r\n // _control.type &&\r\n // _control.type.startsWith(\"layout\") &&\r\n // _more &&\r\n // _more[\"items\"]\r\n // ) {\r\n // for (let j = 0; j < _more[\"items\"].length; j++) {\r\n // const _controlInLayout = _more[\"items\"][j]\r\n // FlowUpdateRelativeControls({\r\n // objRelatives: this.relativeControls,\r\n // objEffectedBy: this.effectControls,\r\n // configFormControl: _controlInLayout,\r\n // fieldName: _controlInLayout.fieldName,\r\n // more: _controlInLayout.more,\r\n // })\r\n // }\r\n // }\r\n //bo sung control tu groups\r\n if (_control.groups?.length && !_fieldName) {\r\n const groups = _control.groups\r\n for (let j = 0; j < groups.length; j++) {\r\n const _controlInGrp = groups[j]\r\n const _moreCtlInGrp = _controlInGrp.more\r\n const _fieldNameCtlInGrp = _controlInGrp.fieldName\r\n FlowUpdateRelativeControls({\r\n objRelatives: this.relativeControls,\r\n objEffectedBy: this.effectControls,\r\n configFormControl: _controlInGrp,\r\n fieldName: _fieldNameCtlInGrp,\r\n more: _moreCtlInGrp,\r\n })\r\n // if (\r\n // _moreCtlInGrp &&\r\n // _moreCtlInGrp.relativeTo &&\r\n // _moreCtlInGrp.relativeTo.length > 0\r\n // ) {\r\n // if (this.relativeControls[_fieldNameCtlInGrp] === undefined) {\r\n // this.relativeControls[_fieldNameCtlInGrp] = []\r\n // }\r\n // this.relativeControls[_fieldNameCtlInGrp] = this.relativeControls[\r\n // _fieldNameCtlInGrp\r\n // ].concat(_moreCtlInGrp.relativeTo)\r\n // }\r\n // if (_moreCtlInGrp && _moreCtlInGrp.conditionShow) {\r\n // let _keys = Object.keys(_moreCtlInGrp.conditionShow)\r\n // if (!_keys.includes(\"isCondition\")) {\r\n // for (let k of _keys) {\r\n // if (this.relativeControls[k] === undefined) {\r\n // this.relativeControls[k] = []\r\n // }\r\n // if (\r\n // this.relativeControls[k].indexOf(_fieldNameCtlInGrp) === -1\r\n // ) {\r\n // this.relativeControls[k].push(_fieldNameCtlInGrp)\r\n // }\r\n // }\r\n // } else {\r\n // // Khi dieu kien show của 1 control la 1 dieu kien khong phai 1 gia tri cu the\r\n // const conditionShow = _moreCtlInGrp.conditionShow\r\n // if (\r\n // this.relativeControls[conditionShow.fieldRelative] ===\r\n // undefined\r\n // ) {\r\n // this.relativeControls[conditionShow.fieldRelative] = []\r\n // }\r\n // if (\r\n // this.relativeControls[conditionShow.fieldRelative].indexOf(\r\n // _fieldNameCtlInGrp\r\n // ) === -1\r\n // ) {\r\n // this.relativeControls[conditionShow.fieldRelative].push(\r\n // _fieldNameCtlInGrp\r\n // )\r\n // }\r\n // }\r\n // }\r\n // if (_more && _more.effectedBy && _more.effectedBy.length > 0) {\r\n // for (let k of _more.effectedBy) {\r\n // if (this.effectControls[k] === undefined) {\r\n // this.effectControls[k] = []\r\n // }\r\n // if (this.effectControls[k].indexOf(_fieldNameCtlInGrp) === -1) {\r\n // this.effectControls[k].push(_fieldNameCtlInGrp)\r\n // }\r\n // }\r\n // }\r\n }\r\n } else {\r\n FlowUpdateRelativeControls({\r\n objRelatives: this.relativeControls,\r\n objEffectedBy: this.effectControls,\r\n configFormControl: _control,\r\n fieldName: _fieldName,\r\n more: _more,\r\n })\r\n // if (_more && _more.relativeTo && _more.relativeTo.length > 0) {\r\n // if (this.relativeControls[_fieldName] === undefined) {\r\n // this.relativeControls[_fieldName] = []\r\n // }\r\n // this.relativeControls[_fieldName] = this.relativeControls[\r\n // _fieldName\r\n // ].concat(_more.relativeTo)\r\n // }\r\n // if (_more && _more.conditionShow) {\r\n // let _keys = Object.keys(_more.conditionShow)\r\n // if (!_keys.includes(\"isCondition\")) {\r\n // for (let k of _keys) {\r\n // if (this.relativeControls[k] === undefined) {\r\n // this.relativeControls[k] = []\r\n // }\r\n // if (this.relativeControls[k].indexOf(_fieldName) === -1) {\r\n // this.relativeControls[k].push(_fieldName)\r\n // }\r\n // }\r\n // } else {\r\n // // Khi dieu kien show của 1 control la 1 dieu kien khong phai 1 gia tri cu the\r\n // const conditionShow = _more.conditionShow\r\n // const fieldRelative = conditionShow?.fieldRelative\r\n // // Danh cho truong hop phu thuoc 1 control trong 1 group\r\n // if (fieldRelative.indexOf(\".\") > -1) {\r\n // //Chi lay field cua cha vi ben trong thay doi thi se thay doi luon ca group va se update control phu thuoc\r\n // let _fieldParent = fieldRelative.split(\".\")?.[0]\r\n // if (this.relativeControls[_fieldParent] === undefined) {\r\n // this.relativeControls[_fieldParent] = []\r\n // }\r\n // if (\r\n // this.relativeControls[_fieldParent].indexOf(_fieldName) === -1\r\n // ) {\r\n // this.relativeControls[_fieldParent].push(_fieldName)\r\n // }\r\n // } else {\r\n // if (this.relativeControls[fieldRelative] === undefined) {\r\n // this.relativeControls[fieldRelative] = []\r\n // }\r\n // if (\r\n // this.relativeControls[fieldRelative].indexOf(_fieldName) ===\r\n // -1\r\n // ) {\r\n // this.relativeControls[fieldRelative].push(_fieldName)\r\n // }\r\n // }\r\n // }\r\n // }\r\n // if (_more && _more.effectedBy && _more.effectedBy.length > 0) {\r\n // for (let k of _more.effectedBy) {\r\n // if (this.effectControls[k] === undefined) {\r\n // this.effectControls[k] = []\r\n // }\r\n // if (this.effectControls[k].indexOf(_fieldName) === -1) {\r\n // this.effectControls[k].push(_fieldName)\r\n // }\r\n // }\r\n // }\r\n }\r\n }\r\n }\r\n console.warn(\"this.relativeControls\", this.relativeControls)\r\n }\r\n _getMoreOfForm = () => {\r\n const { configForm } = this.props\r\n let _more = {}\r\n if (configForm.more) {\r\n if (HIs.isJsonString(configForm.more)) {\r\n _more = HJson.getObj(configForm.more)\r\n } else {\r\n _more = configForm.more\r\n }\r\n }\r\n return _more\r\n }\r\n _getMoreWithKey = (key = \"\") => {\r\n let _moreOfForm = this._getMoreOfForm()\r\n if (key && _moreOfForm.hasOwnProperty(key)) {\r\n return _moreOfForm[key]\r\n }\r\n }\r\n _onTouch = (fieldName, newValue) => {\r\n console.warn(\"onTouch\", fieldName, newValue, this.relativeControls)\r\n if (this.toucheds.indexOf(fieldName) === -1) {\r\n this.toucheds.push(fieldName)\r\n }\r\n this.currentValues[fieldName] = newValue\r\n\r\n //reset invalid\r\n if (\r\n this.fieldsInvalid &&\r\n this.fieldsInvalid.length > 0 &&\r\n this.fieldsInvalid.indexOf(fieldName) > -1\r\n ) {\r\n if (newValue != null && newValue != \"\") {\r\n this.fieldsInvalid.splice(this.fieldsInvalid.indexOf(fieldName), 1)\r\n FlowFnListFromExtControl.forceUpdate({\r\n fnListFromExtControl: this.fnListFromExtControl,\r\n fieldName: fieldName,\r\n })\r\n }\r\n }\r\n\r\n if (this.relativeControls[fieldName]) {\r\n for (let k of this.relativeControls[fieldName]) {\r\n FlowFnListFromExtControl.forceUpdate({\r\n fnListFromExtControl: this.fnListFromExtControl,\r\n fieldName: k,\r\n })\r\n }\r\n }\r\n if (this.effectControls[fieldName]) {\r\n for (let k of this.effectControls[fieldName]) {\r\n FlowFnListFromExtControl.updateValueEffect({\r\n fnListFromExtControl: this.fnListFromExtControl,\r\n fieldName: k,\r\n })\r\n }\r\n }\r\n }\r\n _checkValidRequired = () => {\r\n let _valid = true\r\n this.fieldsInvalid = []\r\n if (\r\n this.currentValues &&\r\n this.fieldsRequired &&\r\n this.fieldsRequired.length > 0\r\n ) {\r\n for (let f of this.fieldsRequired) {\r\n if (this.currentValues[f] == null || this.currentValues[f] === \"\") {\r\n _valid = false\r\n this.fieldsInvalid.push(f)\r\n }\r\n }\r\n for (let f of this.fieldsInvalid) {\r\n FlowFnListFromExtControl.forceUpdate({\r\n fnListFromExtControl: this.fnListFromExtControl,\r\n fieldName: f,\r\n })\r\n }\r\n }\r\n return _valid\r\n }\r\n _onSubmit = (event?: React.FormEvent) => {\r\n const { fnList, configForm, inMyModal } = this.props\r\n const me = this\r\n if (event && event.preventDefault) {\r\n event.preventDefault()\r\n }\r\n console.warn(\"Submit\", this.currentValues)\r\n if (this._checkValidRequired() == false) {\r\n showToastWarning(\"Please fill out all required fields.\")\r\n return\r\n }\r\n if (fnList && fnList.onSubmitForm) {\r\n me.setState({\r\n isLoading: true,\r\n })\r\n const result = fnList.onSubmitForm(this.currentValues, {\r\n defaultValues: configForm.defaultValues,\r\n errorsValid: this.errorsValid,\r\n relativeControls: this.relativeControls,\r\n toucheds: this.toucheds,\r\n inMyModal,\r\n myForm: this,\r\n })\r\n if (result && result.then) {\r\n result\r\n .then((rs: any) => {\r\n console.warn(\"promise myform rs:\", rs)\r\n me.setState({\r\n isLoading: false,\r\n })\r\n if (configForm.closeMyModalAfterSubmit === true && inMyModal) {\r\n inMyModal.hide()\r\n }\r\n })\r\n .catch(err => {\r\n console.warn(\"err:\", err)\r\n me.setState({\r\n isLoading: false,\r\n })\r\n })\r\n }\r\n } else {\r\n console.warn(\"Missing fnList.onSubmitForm\")\r\n }\r\n }\r\n getDisabledForm = () => {\r\n return this.props[\"disabled\"] === true ? true : false\r\n }\r\n getCurrentValues = () => {\r\n return this.currentValues\r\n }\r\n getSourceList = () => {\r\n const { fnList } = this.props\r\n if (fnList && fnList.getSourceList) {\r\n return fnList.getSourceList()\r\n }\r\n return {}\r\n }\r\n getConfigControlByFieldName = (fieldName: string) => {\r\n const { configForm } = this.props\r\n if (this.controlsByFieldName[fieldName]) {\r\n return this.controlsByFieldName[fieldName]\r\n }\r\n if (configForm && configForm.controls && configForm.controls.length > 0) {\r\n for (let i = 0; i < configForm.controls.length; i++) {\r\n let _control = configForm.controls[i]\r\n if (_control.fieldName === fieldName) {\r\n this.controlsByFieldName[fieldName] = _control\r\n return _control\r\n }\r\n }\r\n }\r\n }\r\n getConfigInMoreOfControl = (\r\n fieldName: string,\r\n key: string,\r\n configControl?: any\r\n ) => {\r\n let _configControl: any =\r\n configControl || this.getConfigControlByFieldName(fieldName)\r\n if (_configControl && _configControl.more && _configControl.more[key]) {\r\n return _configControl.more[key]\r\n }\r\n }\r\n getRulesOfControl = (fieldName: string) => {\r\n return this.getConfigInMoreOfControl(fieldName, \"rules\")\r\n }\r\n checkValidAll = () => {\r\n const { configForm } = this.props\r\n let _result: any = true\r\n if (configForm && configForm.controls) {\r\n for (let i = 0; i < configForm.controls.length; i++) {\r\n let _control = configForm.controls[i]\r\n let _resultOfControl = this.checkValidOfField(\r\n _control.fieldName,\r\n _control\r\n )\r\n if (_resultOfControl !== true) {\r\n if (_result === true) {\r\n _result = {}\r\n }\r\n if (_control.fieldName) {\r\n _result[_control.fieldName] = _resultOfControl\r\n }\r\n }\r\n }\r\n }\r\n console.warn(\"checkValidAll:\", _result)\r\n if (_result !== true) {\r\n this.errorsValid = _result\r\n } else {\r\n this.errorsValid = {}\r\n }\r\n this.forceUpdate()\r\n return _result\r\n }\r\n checkValidOfField = (fieldName: string = \"\", configControl?: any) => {\r\n let _configControl: any =\r\n configControl || this.getConfigControlByFieldName(fieldName)\r\n let _result = true\r\n if (_configControl) {\r\n let _rules = this.getRulesOfControl(fieldName)\r\n let _value = this.currentValues[fieldName]\r\n if (_rules) {\r\n _result = HValid.validAllRulesOfValue(_rules, _value)\r\n console.warn(\"checkValidOfField:\", fieldName, _rules, _value, _result)\r\n }\r\n }\r\n return _result\r\n }\r\n _renderBtnSubmit = () => {\r\n let _configBtnSubmit = this._getMoreWithKey(KMoreOfForm.btnSubmit) || {}\r\n return (\r\n \r\n {this._getIsLoading() && (\r\n \r\n )}\r\n {_configBtnSubmit.title || i18next.t(\"Save\")}\r\n \r\n )\r\n }\r\n _renderBtnReset = () => {\r\n const { configForm } = this.props\r\n let _configBtnReset = this._getMoreWithKey(KMoreOfForm.btnReset) || {}\r\n if (_configBtnReset.hide == true) {\r\n return null\r\n }\r\n return (\r\n {\r\n this.currentValues = { ...configForm.defaultValues }\r\n if (configForm && configForm.controls) {\r\n for (let i = 0; i < configForm.controls.length; i++) {\r\n let _control = configForm.controls[i]\r\n let _fieldName = _control.fieldName || \"\"\r\n console.warn(\"fnListFromExtControl\", this.fnListFromExtControl)\r\n fnListMyForm[kresetFormControl](\r\n this.fnListFromExtControl[_fieldName],\r\n []\r\n )\r\n }\r\n }\r\n // this.forceUpdate()\r\n }}\r\n >\r\n {_configBtnReset.title || i18next.t(\"Reset\")}\r\n \r\n )\r\n }\r\n _getIsLoading = () => {\r\n return this.state.isLoading || false\r\n }\r\n _renderMoreButtons = () => {\r\n let _moreButtons = this._getMoreWithKey(KMoreOfForm.moreButtons)\r\n if (_moreButtons && _moreButtons.length > 0) {\r\n let _oneButtons = _moreButtons.map((v, i) => {\r\n return new OneButton({\r\n configButton: v,\r\n onePage: {\r\n //fn bat buoc\r\n getApiController: () => {\r\n return \"apicontroller\"\r\n },\r\n getQueryShared: () => {\r\n return {}\r\n },\r\n },\r\n })\r\n })\r\n return _oneButtons.map((v, i) => {\r\n return v.renderMyButton({\r\n key: i,\r\n fnList: {},\r\n })\r\n })\r\n }\r\n return null\r\n }\r\n _renderFooter = () => {\r\n const { configForm } = this.props\r\n let _hideFooter = this._getMoreWithKey(KMoreOfForm.hideFooter)\r\n if (_hideFooter === true) {\r\n return
\r\n }\r\n if (this.props.renderFooter) {\r\n return this.props.renderFooter(this)\r\n }\r\n if (this.getDisabledForm()) {\r\n return
\r\n }\r\n let _position =\r\n this._getMoreWithKey(KMoreOfForm.positionButtonsBottom) || \"left\"\r\n if (_position === \"right\") {\r\n return (\r\n
\r\n {this._renderMoreButtons()}\r\n {this._renderBtnReset()}\r\n {this._renderBtnSubmit()}\r\n
\r\n )\r\n }\r\n return (\r\n
\r\n {this._renderBtnSubmit()}\r\n {this._renderBtnReset()}\r\n {this._renderMoreButtons()}\r\n
\r\n )\r\n }\r\n _renderLoadingOverlay = () => {\r\n const { configForm } = this.props\r\n if (this.props.renderLoadingOverlay) {\r\n return this.props.renderLoadingOverlay(this)\r\n }\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n _renderFormControl = (configControl, i) => {\r\n const { configForm } = this.props\r\n const v = configControl || {}\r\n // console.warn(\"_renderFormControl\", configControl)\r\n let _fnList = this.getFnListOfFormControl()\r\n // console.warn(\"canshow:\", _canShow, configControl)\r\n return (\r\n \r\n )\r\n }\r\n requestUpdateAfterChange = (opts: any = {}) => {\r\n // console.warn(\"requestUpdateAfterChange:\", opts)\r\n const { configForm } = this.props\r\n const configApiAfterChange = this._getMoreWithKey(\r\n KMoreOfForm.configApiAfterChange\r\n )\r\n if (\r\n configApiAfterChange &&\r\n configApiAfterChange.url &&\r\n Array.isArray(configApiAfterChange.fields) &&\r\n opts.fieldName &&\r\n configApiAfterChange.fields.indexOf(opts.fieldName) > -1\r\n ) {\r\n HApi.apiGeneric({\r\n method: configApiAfterChange.method || \"POST\",\r\n url: configApiAfterChange.url, // || \"RentalService_SelfdriveCarRental_ListView_MoreInfo/UpdateCreateOrderForm\",\r\n data: {\r\n DefaultValues: configForm?.defaultValues,\r\n DataForm: this.currentValues,\r\n },\r\n }).then(res => {\r\n console.warn(\"requestUpdateAfterChange:\", res)\r\n if (res && res.Data) {\r\n for (let k of Object.keys(res.Data)) {\r\n // this.currentValues[k] = res.Data[k]\r\n this._onTouch(k, res.Data[k])\r\n FlowFnListFromExtControl.updateValue({\r\n fnListFromExtControl: this.fnListFromExtControl,\r\n fieldName: k,\r\n newValue: res.Data[k],\r\n })\r\n }\r\n // this.forceUpdate()\r\n }\r\n })\r\n }\r\n }\r\n getFnListOfFormControl = () => {\r\n const { fnList } = this.props\r\n if (\r\n this.fnListFormControl &&\r\n Object.keys(this.fnListFormControl).length > 0\r\n ) {\r\n return this.fnListFormControl\r\n }\r\n this.fnListFormControl = {\r\n ...fnList,\r\n initWrapControl: (fieldName: string, fnFromWrap: any) => {\r\n if (this.fnListFromWrap[fieldName] === undefined) {\r\n this.fnListFromWrap[fieldName] = fnFromWrap\r\n }\r\n },\r\n initExtControl: (fieldName: string, fnFromExtControl: any) => {\r\n if (this.fnListFromExtControl[fieldName] === undefined) {\r\n this.fnListFromExtControl[fieldName] = fnFromExtControl\r\n }\r\n },\r\n addFnListFromControl: (fnName, fn, fieldName) => {\r\n if (!this.fnListFromExtControl[fieldName]) {\r\n this.fnListFromExtControl[fieldName] = {}\r\n }\r\n if (this.fnListFromExtControl[fieldName]) {\r\n this.fnListFromExtControl[fieldName][fnName] = fn\r\n }\r\n },\r\n getSourceList: this.getSourceList,\r\n getCurrentValues: () => {\r\n return this.currentValues\r\n },\r\n getDefaultValues: () => {\r\n return this.props.configForm.defaultValues || {} //tranh truong hop defaultValues la null\r\n },\r\n getFieldsInvalid: () => {\r\n return this.fieldsInvalid\r\n },\r\n getIsInvalid: fieldName => {\r\n if (\r\n fieldName &&\r\n this.fieldsInvalid &&\r\n this.fieldsInvalid.indexOf(fieldName) > -1\r\n ) {\r\n return true\r\n }\r\n return false\r\n },\r\n updateRequired: fieldName => {\r\n if (fieldName && this.fieldsRequired.indexOf(fieldName) == -1) {\r\n this.fieldsRequired.push(fieldName)\r\n }\r\n console.warn(\"updateRequired:\", this.fieldsRequired)\r\n },\r\n onSubmitFormFromControl: () => {\r\n this._onSubmit()\r\n },\r\n onUpdateValue: ({ fieldName, newValue }) => {\r\n console.warn(\"onUpdateValue:\", fieldName, newValue)\r\n HUtils.runFuntion(this.props.fnList, \"afterUpdateValueControl\", [\r\n {\r\n fieldName,\r\n newValue,\r\n control: this.getConfigControlByFieldName(fieldName),\r\n },\r\n ])\r\n this._onTouch(fieldName, newValue)\r\n //update api\r\n this.requestUpdateAfterChange({ fieldName })\r\n },\r\n onJustUpdateValueMultiCurrentValuesForm: (list: any) => {\r\n let _keys = Object.keys(list)\r\n for (let k of _keys) {\r\n this.currentValues[k] = list[k]\r\n }\r\n },\r\n onUpdateControlWithNewValue: (fieldName, newValue) => {\r\n HUtils.runFuntion(this.props.fnList, \"afterUpdateValueControl\", [\r\n {\r\n fieldName,\r\n newValue,\r\n control: this.getConfigControlByFieldName(fieldName),\r\n },\r\n ])\r\n this._onTouch(fieldName, newValue)\r\n FlowFnListFromExtControl.updateValue({\r\n fnListFromExtControl: this.fnListFromExtControl,\r\n fieldName: fieldName,\r\n newValue: newValue,\r\n })\r\n },\r\n onUpdateValueMulti: (list: any) => {\r\n console.warn(\"onUpdateValueMulti:\", list)\r\n let _keys = Object.keys(list)\r\n if (_keys && _keys.length > 0) {\r\n for (let k of _keys) {\r\n HUtils.runFuntion(this.props.fnList, \"afterUpdateValueControl\", [\r\n {\r\n fieldName: k,\r\n newValue: list[k],\r\n control: this.getConfigControlByFieldName(k),\r\n },\r\n ])\r\n this._onTouch(k, list[k])\r\n }\r\n }\r\n },\r\n registerControl: (fieldName: string, opts: any = {}) => {\r\n this.controlsOptsByFieldName[fieldName] = {\r\n component: opts.component,\r\n forceUpdate: opts.forceUpdate,\r\n }\r\n },\r\n onTouch: ({ fieldName }: { fieldName: string }) => {\r\n console.warn(\"onTouch\", fieldName)\r\n if (this.toucheds.indexOf(fieldName) === -1) {\r\n this.toucheds.push(fieldName)\r\n }\r\n },\r\n fnGetTypeWrapControl: () => {\r\n return this._getMoreWithKey(KMoreOfForm.typeWrapControl)\r\n },\r\n fnGetDefaultConfigWrapControl: () => {\r\n return this._getMoreWithKey(KMoreOfForm.defaultConfigWrapControl)\r\n },\r\n fnRenderFormControl: this._renderFormControl,\r\n fnGetDisabledForm: this.getDisabledForm,\r\n }\r\n return this.fnListFormControl\r\n }\r\n render() {\r\n const { configForm, style, className, fnList, autoComplete } = this.props\r\n console.warn(\"render MyForm:\", configForm, this.props)\r\n let _moreProps = {}\r\n if (this._getMoreWithKey(KMoreOfForm.noValidateDefault) === true) {\r\n _moreProps[\"noValidate\"] = true\r\n }\r\n let _fnList = this.getFnListOfFormControl()\r\n let _usingI18n = this._getMoreWithKey(KMoreOfForm.usingI18n)\r\n let _screenCode = HUtils.runFuntion(_fnList, \"fnGetScreenCode\")\r\n return (\r\n \r\n \r\n
\r\n {configForm &&\r\n configForm.controls &&\r\n configForm.controls?.map((v, i) => {\r\n return (\r\n \r\n )\r\n })}\r\n
\r\n {this._renderFooter()}\r\n {this._getIsLoading() && this._renderLoadingOverlay()}\r\n \r\n
\r\n )\r\n }\r\n}\r\nexport default MyForm\r\n","import { HJson, HCF, HLocalStorage, HUtils, HEE } from \"@macashipo/mlib\"\r\nimport K, { KStorage } from \"src/helpers/K\"\r\n\r\nexport const KAuth = {\r\n fnUpdateAuthInfo: \"fnUpdateAuthInfo\",\r\n eeUpdateAuthInfo: \"eeUpdateAuthInfo\",\r\n}\r\nexport const FlowParseAuthInfo = authInfo => {\r\n console.warn(\"parse auth info\", authInfo)\r\n if (authInfo) {\r\n if (authInfo.configs) {\r\n let _configs = HJson.getObj(authInfo.configs, {})\r\n if (_configs && _configs.home_url) {\r\n HCF.setCF(K.KConfigApp.home_url, _configs.home_url)\r\n HLocalStorage.saveString(KStorage.HomeURL, _configs.home_url)\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport const FlowUpdateAuthInfo = ({ name, avatar } = {}) => {\r\n let _authInfo = HLocalStorage.getObj(KStorage.AuthInfo)\r\n if (_authInfo) {\r\n if (name && _authInfo.name != name) {\r\n _authInfo.name = name\r\n }\r\n if (avatar && _authInfo.avatar_url != avatar) {\r\n _authInfo.avatar_url = avatar\r\n }\r\n HLocalStorage.saveObj(KStorage.AuthInfo, _authInfo)\r\n HUtils.runFuntion(HCF.CF, KAuth.fnUpdateAuthInfo, [_authInfo])\r\n HEE.emit(KAuth.eeUpdateAuthInfo, _authInfo)\r\n }\r\n}\r\n","import RcTooltip from \"rc-tooltip\"\r\nimport \"rc-tooltip/assets/bootstrap.css\"\r\nimport \"./styles.css\"\r\n// export default class Tooltip extends RcTooltip {\r\n// static displayName = \"m-tooltip\"\r\n// static propTypes = {\r\n// ...RcTooltip.propTypes,\r\n// }\r\n// static defaultProps = {\r\n// ...RcTooltip.defaultProps,\r\n// prefixCls: \"m-tooltip\",\r\n// transitionName: \"tip-slide\",\r\n// }\r\n// }\r\n\r\nexport default RcTooltip\r\n","import { HUtils } from \"@macashipo/mlib\"\r\nimport throttle from \"lodash/throttle\"\r\n\r\nconst ListObserver = {\r\n sample: {\r\n allTrigger: {},\r\n },\r\n window_resize: {\r\n allTrigger: {},\r\n },\r\n}\r\nconst HObserver = {\r\n create(key) {\r\n if (ListObserver[key] == null) {\r\n ListObserver[key] = {\r\n allTrigger: {},\r\n }\r\n } else {\r\n console.warn(\"HObserver exist:\", key)\r\n }\r\n },\r\n register(key, type, fn) {\r\n if (ListObserver[key] == null) {\r\n HObserver.create(key)\r\n }\r\n if (type && ListObserver[key] != null && ListObserver[key].allTrigger) {\r\n ListObserver[key].allTrigger[type] = fn\r\n }\r\n },\r\n trigger(key, params = []) {\r\n // console.warn(\"trigger:\", key, params, ListObserver)\r\n if (ListObserver[key] != null && ListObserver[key].allTrigger) {\r\n for (let k of Object.keys(ListObserver[key].allTrigger)) {\r\n HUtils.runFuntion(ListObserver[key].allTrigger, k, [...params])\r\n }\r\n } else {\r\n console.warn(\"HObserver not exist:\", key)\r\n }\r\n },\r\n}\r\n\r\nconst onResize = throttle(ev => {\r\n // console.log(\"onResize\", ev)\r\n HObserver.trigger(\"window_resize\", [window.innerWidth, window.innerHeight])\r\n}, 300)\r\n\r\nwindow.addEventListener(\"resize\", onResize)\r\nconsole.log(\"HObserver init\")\r\nexport default HObserver\r\n","import { HCF, HLocalStorage, HUtils } from \"@macashipo/mlib\"\r\nimport {\r\n KConfigApp,\r\n KConfigPageTableDefault,\r\n KConfigPageFilter,\r\n KConfigPageTable,\r\n KConfigPagePage,\r\n KConfigPageHeader,\r\n KUI,\r\n KStorage,\r\n} from \"./K\"\r\nexport const kfnUpdatePageTitle = \"fnUpdatePageTitle\"\r\nexport const kfnGetApiPath = \"fnGetApiPath\"\r\nexport const kfnGetScreenCode = \"fnGetScreenCode\"\r\nexport const kgetSourceList = \"getSourceList\"\r\nexport const kfnHandleSearchText = \"fnHandleSearchText\"\r\nexport const kfnLoadLocalFilter = \"fnLoadLocalFilter\"\r\nexport const kfnGetConfigPageScreenConfig = \"fnGetConfigPageScreenConfig\"\r\nexport const kfnGetConfigPageHeader = \"fnGetConfigPageHeader\"\r\nexport const kfnGetConfigPageTable = \"fnGetConfigPageTable\"\r\nexport const kfnGetConfigPageDetail = \"fnGetConfigPageDetail\"\r\nexport const kfnGetConfigPageFilter = \"fnGetConfigPageFilter\"\r\nexport const kfnGetConfigPagePage = \"fnGetConfigPagePage\"\r\nexport const kfnGetConfigChart = \"kfnGetConfigChart\"\r\nexport const kgetCurrentValues = \"getCurrentValues\"\r\nexport const kfnGetSourceData = \"fnGetSourceData\"\r\nexport const kfnRenderBadge = \"fnRenderBadge\"\r\nexport const kgetTabsIndexSelected = \"getTabsIndexSelected\"\r\nexport const kgetTabLevel = \"getTabLevel\"\r\nexport const konChangeTab = \"onChangeTab\"\r\nexport const kfnReExpand = \"fnReExpand\"\r\nexport const kgetDefaultValues = \"getDefaultValues\"\r\nexport const kgetIsMobileByWidth = \"getIsMobileByWidth\"\r\nexport const kgetDefaultTypeHubFilter = \"getDefaultTypeHubFilter\"\r\nexport const kfnForceUpdateTable = \"fnForceUpdateTable\"\r\nexport const kgetDataList = \"getDataList\"\r\nexport const kfnGetComponentTable = \"fnGetComponentTable\"\r\nexport const kfnGetOnePage = \"fnGetOnePage\"\r\nexport const kfnGetOptions = \"fnGetOptions\"\r\nexport const kfnGetExtraDataTable = \"fnGetExtraDataTable\"\r\nexport const kfnGetDataTableFilterd = \"fnGetDataTableFilterd\"\r\nexport const kfnGetDataTable = \"fnGetDataTable\"\r\nexport const kaddFnListFromControl = \"addFnListFromControl\"\r\nexport const kresetFormControl = \"resetFormControl\"\r\nexport const kfnReloadList = \"fnReloadList\"\r\nexport const kfnReloadOptionsAndList = \"fnReloadOptionsAndList\"\r\nexport const kfnGetHeaderTitle = \"fnGetHeaderTitle\"\r\nexport const kfnGetConfigInMore = \"fnGetConfigInMore\"\r\nexport const kfnGetIsInTableExpand = \"fnGetIsInTableExpand\"\r\nexport const kfnGetConfigExpand = \"fnGetConfigExpand\"\r\nexport const kfnGetIsInModal = \"fnGetIsInModal\"\r\nexport const kfnGetIsInPanel = \"fnGetIsInPanel\"\r\nexport const kfnGetIsPanel = \"fnGetIsPanel\"\r\nexport const kfnGetColumnSelect = \"fnGetColumnSelect\"\r\nexport const kfnGetConfigModal = \"fnGetConfigModal\"\r\nexport const kfnGetTypeWrapControl = \"fnGetTypeWrapControl\"\r\nexport const kfnGetDefaultConfigWrapControl = \"fnGetDefaultConfigWrapControl\"\r\nexport const kfnGetIsHide = \"fnGetIsHide\"\r\nexport const kfnChangeSwitchView = \"fnChangeSwitchView\"\r\nexport const kfnGetCurrentSwitchView = \"fnGetCurrentSwitchView\"\r\nexport const kfnGetButtonList = \"fnGetButtonList\"\r\nexport const kfnRequestUpdateFromExpand = \"fnRequestUpdateFromExpand\"\r\nconst rf = (fnList, name, args) => {\r\n return HUtils.runFuntion(fnList, name, args)\r\n}\r\n\r\nconst fnListModal = {\r\n showLoadingModal(fnList = {}, args = []) {\r\n HUtils.runFuntion(fnList, \"showLoadingModal\", args)\r\n },\r\n hideLoadingModal(fnList = {}, args = []) {\r\n HUtils.runFuntion(fnList, \"hideLoadingModal\", args)\r\n },\r\n hideModal(fnList = {}, args = []) {\r\n HUtils.runFuntion(fnList, \"hideModal\", args)\r\n },\r\n}\r\n\r\nconst fnListPopover = {\r\n hidePopover(fnList = {}, args = []) {\r\n HUtils.runFuntion(fnList, \"hidePopover\", args)\r\n },\r\n}\r\nconst fnListFilesManager = {\r\n onAfterAddFolderGGDrive(fnList = {}, args = []) {\r\n HUtils.runFuntion(fnList, \"onAfterAddFolderGGDrive\", args)\r\n },\r\n}\r\n\r\n/** MyForm */\r\nconst listFnMyForm = []\r\n\r\nconst kfnRenderFormControl = \"fnRenderFormControl\"\r\nconst fnListMyForm = {\r\n getSourceList(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kgetSourceList, args)\r\n },\r\n getCurrentValues(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kgetCurrentValues, args)\r\n },\r\n getDefaultValues(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kgetDefaultValues, args)\r\n },\r\n addFnListFromControl(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kaddFnListFromControl, args)\r\n },\r\n [kresetFormControl](fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kresetFormControl, args)\r\n },\r\n fnGetTypeWrapControl(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetTypeWrapControl, args)\r\n },\r\n fnRenderFormControl(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnRenderFormControl, args)\r\n },\r\n}\r\nif (listFnMyForm && listFnMyForm.length > 0) {\r\n for (let k of listFnMyForm) {\r\n fnListMyForm[k] = (fnList = {}, args = []) => {\r\n return HUtils.runFuntion(fnList, k, args)\r\n }\r\n }\r\n}\r\n\r\n// const fnListMyFormKeys = [kgetSourceList]\r\n// for(let k of fnListMyFormKeys){\r\n// fnListMyForm[k] = (fnList, args)=>{\r\n// return rf(fnList,k,args)\r\n// }\r\n// }\r\n\r\nconst fnListMyFormControl = {\r\n getSourceData(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, \"getSourceData\", args)\r\n },\r\n fnGetTypeWrapControl(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetTypeWrapControl, args)\r\n },\r\n fnGetDefaultConfigWrapControl(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetDefaultConfigWrapControl, args)\r\n },\r\n}\r\n\r\nconst fnListMyTableCell = {\r\n fnGetSourceData(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetSourceData, args)\r\n },\r\n fnRenderBadge(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnRenderBadge, args)\r\n },\r\n fnGetHeaderTitle(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetHeaderTitle, args)\r\n },\r\n fnGetConfigInMore(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigInMore, args)\r\n },\r\n fnGetConfigModal(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetConfigModal, args)\r\n },\r\n fnGetIsHide(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetIsHide, args)\r\n },\r\n}\r\n\r\nexport const kfnGetTitleControl = \"fnGetTitleControl\"\r\nconst fnListMyTableFilterControl = {\r\n fnGetTitleControl(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetTitleControl, args)\r\n },\r\n}\r\n\r\nexport const kfnGetSharedRequestData = \"fnGetSharedRequestData\"\r\nexport const kfnGetDataTotal = \"fnGetDataTotal\"\r\nexport const kfnGetTableCols = \"fnGetTableCols\"\r\nconst fnListMyPage = {\r\n fnGetSharedRequestData(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetSharedRequestData, args) || {}\r\n },\r\n fnReloadList(fnList = {}, args = []) {\r\n console.warn(\"fnReloadList\")\r\n //for old\r\n if (fnList[\"reloadTable\"]) {\r\n return HUtils.runFuntion(fnList, \"reloadTable\", args)\r\n } else if (fnList[\"reloadList\"]) {\r\n return HUtils.runFuntion(fnList, \"reloadList\", args)\r\n }\r\n return HUtils.runFuntion(fnList, kfnReloadList, args)\r\n },\r\n fnReloadOptionsAndList(fnList = {}, args = []) {\r\n //for old\r\n if (fnList[\"reloadOptionsAndList\"]) {\r\n return HUtils.runFuntion(fnList, \"reloadOptionsAndList\", args)\r\n }\r\n return HUtils.runFuntion(fnList, kfnReloadOptionsAndList, args)\r\n },\r\n fnReloadPage(fnList = {}, args = []) {\r\n window.location.reload()\r\n },\r\n fnUpdatePageTitle(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnUpdatePageTitle, args)\r\n },\r\n fnGetApiPath(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetApiPath, args)\r\n },\r\n fnGetScreenCode(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetScreenCode, args)\r\n },\r\n getSourceList(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kgetSourceList, args)\r\n },\r\n fnHandleSearchText(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnHandleSearchText, args)\r\n },\r\n fnLoadLocalFilter(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnLoadLocalFilter, args)\r\n },\r\n fnGetConfigPageScreenConfig(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigPageScreenConfig, args)\r\n },\r\n fnGetConfigPageHeader(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigPageHeader, args)\r\n },\r\n fnGetConfigPageTable(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigPageTable, args)\r\n },\r\n fnGetConfigPageDetail(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigPageDetail, args)\r\n },\r\n fnGetConfigPageFilter(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigPageFilter, args)\r\n },\r\n fnGetConfigPagePage(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigPagePage, args)\r\n },\r\n fnGetConfigChart(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetConfigChart, args)\r\n },\r\n getTabsIndexSelected(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kgetTabsIndexSelected, args)\r\n },\r\n onChangeTab(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, konChangeTab, args)\r\n },\r\n fnReExpand(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnReExpand, args)\r\n },\r\n getTabLevel(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kgetTabLevel, args)\r\n },\r\n fnForceUpdateTable(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnForceUpdateTable, args)\r\n },\r\n getDataList(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kgetDataList, args)\r\n },\r\n fnGetOnePage(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetOnePage, args)\r\n },\r\n fnGetOptions(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetOptions, args)\r\n },\r\n fnGetExtraDataTable(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetExtraDataTable, args)\r\n },\r\n fnGetDataTableFilterd(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetDataTableFilterd, args)\r\n },\r\n fnGetDataTable(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetDataTable, args)\r\n },\r\n fnGetComponentTable(fnList = {}, args = []) {\r\n return HUtils.runFuntion(fnList, kfnGetComponentTable, args)\r\n },\r\n fnGetDefaultScreenConfig(fnList = {}, args = []) {\r\n return rf(fnList, \"fnGetDefaultScreenConfig\", args)\r\n },\r\n fnGetIsInTableExpand(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetIsInTableExpand, args)\r\n },\r\n fnGetConfigExpand(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetConfigExpand, args)\r\n },\r\n fnGetIsInModal(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetIsInModal, args)\r\n },\r\n fnGetIsInPanel(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetIsInPanel, args)\r\n },\r\n fnGetIsPanel(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetIsPanel, args)\r\n },\r\n fnChangeSwitchView(fnList = {}, args = []) {\r\n return rf(fnList, kfnChangeSwitchView, args)\r\n },\r\n fnGetCurrentSwitchView(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetCurrentSwitchView, args)\r\n },\r\n fnGetButtonList(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetButtonList, args)\r\n },\r\n fnGetDataTotal(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetDataTotal, args)\r\n },\r\n fnGetTableCols(fnList = {}, args = []) {\r\n return rf(fnList, kfnGetTableCols, args)\r\n },\r\n fnRequestUpdateFromExpand(fnList = {}, args = []) {\r\n return rf(fnList, kfnRequestUpdateFromExpand, args)\r\n },\r\n}\r\n\r\nexport const kgetHasLoginSocial = \"getHasLoginSocial\"\r\nconst fnListConfigApp = {\r\n getHasLoginSocial() {\r\n return (\r\n fnListConfigApp.getHasLoginSocialGoogle() ||\r\n fnListConfigApp.getHasLoginSocialFacebook()\r\n )\r\n },\r\n getHasLoginSocialGoogle() {\r\n return HCF.getCF(KConfigApp.hasLoginSocialGoogle) === true\r\n },\r\n getHasLoginSocialFacebook() {\r\n return HCF.getCF(KConfigApp.hasLoginSocialFacebook) === true\r\n },\r\n getHasForgotPassword() {\r\n return HCF.getCF(KConfigApp.hasForgotPassword) === true\r\n },\r\n getHasRegisterAccount() {\r\n return HCF.getCF(KConfigApp.hasRegisterAccount) === true\r\n },\r\n getGoogleClientID() {\r\n return HCF.getCF(KConfigApp.GoogleClientId)\r\n },\r\n getScreenWidth() {\r\n return window.document.body.offsetWidth\r\n },\r\n getIsMobileByWidth() {\r\n let _widthMobile = HCF.getCF(KConfigApp.widthMobile) || 567\r\n if (window.document.body.offsetWidth < _widthMobile) {\r\n return true\r\n }\r\n return false\r\n },\r\n getDefaultTypeHubFilter() {\r\n return HCF.getCF(KConfigApp.defaultTypeHubFilter)\r\n },\r\n getDefaultPositionFilter() {\r\n return HCF.getCF(KConfigApp.defaultPositionFilter)\r\n },\r\n getIsDevMode() {\r\n return HCF.getCF(KConfigApp.isDevMode)\r\n },\r\n getHomeUrl() {\r\n //home_url tu configApp, configAppExt, authInfo.configs. DefaultHomeURL tu FirstSetting\r\n // let _homePage1 = HCF.getCF(KConfigApp.home_url)\r\n // let _homePage2 = HCF.getCF(KConfigApp.DefaultHomeURL)\r\n // let _homePage3 = HLocalStorage.getString(KStorage.HomeURL)\r\n // console.log(\"getHomeUrl 1:\", _homePage1)\r\n // console.log(\"getHomeUrl 2:\", _homePage2)\r\n // console.log(\"getHomeUrl 3:\", _homePage3)\r\n return (\r\n HCF.getCF(KConfigApp.DefaultHomeURL) || //uu tien lay tu DefaultHomeURL neu co\r\n HCF.getCF(KConfigApp.home_url) || //parse tu login info, va firstsetting\r\n \"/\"\r\n )\r\n },\r\n getAppLogo() {\r\n return HCF.getCF(KConfigApp.appLogo_url) || \"/config/logo.png\"\r\n },\r\n getAuthInfo() {\r\n return HCF.getCF(KConfigApp.AuthInfo)\r\n },\r\n getAppTitle() {\r\n return HCF.getCF(KConfigApp.title)\r\n },\r\n getVerAdmin() {\r\n return HCF.getCF(KConfigApp.verAdmin)\r\n },\r\n}\r\n\r\nexport const fnGetConfigTable = (fnList, key) => {\r\n if (key) {\r\n let _configAll = fnListMyPage.fnGetConfigPageTable(fnList, [])\r\n if (_configAll && _configAll.hasOwnProperty(key)) {\r\n return _configAll[key]\r\n }\r\n if (KConfigPageTableDefault.hasOwnProperty(key)) {\r\n return KConfigPageTableDefault[key]\r\n }\r\n }\r\n}\r\n\r\nconst fnListUI = {\r\n fnShowToast(msg, options, opts) {\r\n rf(HCF.CF, KUI.fnShowToast, [msg, options, opts])\r\n },\r\n fnshowDialog(configDialog, opts) {\r\n rf(HCF.CF, KUI.fnshowDialog, [configDialog, opts])\r\n },\r\n fnshowConfirm(configDialog, opts) {\r\n rf(HCF.CF, KUI.fnshowConfirm, [configDialog, opts])\r\n },\r\n fnShowLoadingScreen(opts) {\r\n rf(HCF.CF, KUI.fnShowLoadingScreen, [opts])\r\n },\r\n fnForceUpdateRoutes(opts) {\r\n rf(HCF.CF, KUI.fnForceUpdateRoutes, [opts])\r\n },\r\n}\r\n\r\nexport {\r\n fnListModal,\r\n fnListPopover,\r\n fnListUI,\r\n fnListFilesManager,\r\n fnListMyForm,\r\n fnListMyFormControl,\r\n fnListMyPage,\r\n fnListMyTableCell,\r\n fnListConfigApp,\r\n fnListMyTableFilterControl,\r\n KConfigPageFilter,\r\n KConfigPageTable,\r\n KConfigPagePage,\r\n KConfigPageHeader,\r\n}\r\n\r\nwindow._fnListUI = fnListUI\r\n","import RcTooltip from \"rc-tooltip\"\r\nimport React from \"react\"\r\nimport \"rc-tooltip/assets/bootstrap.css\"\r\nimport \"./m-popover.css\"\r\nimport { isOnScreen } from \"src/core/helpers/utils\"\r\nfunction RcPopover(props) {\r\n const [visible, setVisible] = React.useState(false)\r\n const { disabled } = props\r\n if (disabled) {\r\n return props.children\r\n }\r\n if (props.overlay)\r\n return (\r\n {\r\n setVisible(v)\r\n }}\r\n overlayClassName=\"m-popover\"\r\n onPopupAlign={(node, align) => {\r\n if (props.autoScrollIntoViewWhenOutOfScreen) {\r\n if (!isOnScreen(node)) {\r\n console.warn(\"onPopupAlign:\", node, align, node.offsetTop)\r\n node.scrollIntoView({ behavior: \"smooth\" })\r\n }\r\n }\r\n }}\r\n {...props}\r\n overlay={() => {\r\n // console.warn(\"typeof \", typeof props.overlay)\r\n if (typeof props.overlay == \"function\") {\r\n return props.overlay({\r\n hide: () => {\r\n setVisible(false)\r\n },\r\n hidePopover: () => {\r\n setVisible(false)\r\n },\r\n })\r\n }\r\n return props.overlay\r\n }}\r\n >\r\n {props.children}\r\n \r\n )\r\n return props.children\r\n}\r\n\r\nexport default RcPopover\r\n","/* eslint-disable */\r\n/*! @preserve\r\n * numeral.js\r\n * version : 2.0.6\r\n * author : Adam Draper\r\n * license : MIT\r\n * http://adamwdraper.github.com/Numeral-js/\r\n */\r\n\r\n(function (global, factory) {\r\n // eslint-disable-next-line\r\n if (typeof define === 'function' && define.amd) {\r\n define(factory);\r\n } else if (typeof module === 'object' && module.exports) {\r\n module.exports = factory();\r\n } else {\r\n global.numeral = factory();\r\n }\r\n}(this, function () {\r\n /************************************\r\n Variables\r\n ************************************/\r\n\r\n var numeral,\r\n _,\r\n VERSION = '2.0.6',\r\n formats = {},\r\n locales = {},\r\n defaults = {\r\n currentLocale: 'en',\r\n zeroFormat: null,\r\n nullFormat: null,\r\n defaultFormat: '0,0',\r\n scalePercentBy100: true\r\n },\r\n options = {\r\n currentLocale: defaults.currentLocale,\r\n zeroFormat: defaults.zeroFormat,\r\n nullFormat: defaults.nullFormat,\r\n defaultFormat: defaults.defaultFormat,\r\n scalePercentBy100: defaults.scalePercentBy100\r\n };\r\n\r\n\r\n /************************************\r\n Constructors\r\n ************************************/\r\n\r\n // Numeral prototype object\r\n function Numeral(input, number) {\r\n this._input = input;\r\n\r\n this._value = number;\r\n }\r\n\r\n numeral = function(input) {\r\n var value,\r\n kind,\r\n unformatFunction,\r\n regexp;\r\n\r\n if (numeral.isNumeral(input)) {\r\n value = input.value();\r\n } else if (input === 0 || typeof input === 'undefined') {\r\n value = 0;\r\n } else if (input === null || _.isNaN(input)) {\r\n value = null;\r\n } else if (typeof input === 'string') {\r\n if (options.zeroFormat && input === options.zeroFormat) {\r\n value = 0;\r\n } else if (options.nullFormat && input === options.nullFormat || !input.replace(/[^0-9]+/g, '').length) {\r\n value = null;\r\n } else {\r\n for (kind in formats) {\r\n regexp = typeof formats[kind].regexps.unformat === 'function' ? formats[kind].regexps.unformat() : formats[kind].regexps.unformat;\r\n\r\n if (regexp && input.match(regexp)) {\r\n unformatFunction = formats[kind].unformat;\r\n\r\n break;\r\n }\r\n }\r\n\r\n unformatFunction = unformatFunction || numeral._.stringToNumber;\r\n\r\n value = unformatFunction(input);\r\n }\r\n } else {\r\n value = Number(input)|| null;\r\n }\r\n\r\n return new Numeral(input, value);\r\n };\r\n\r\n // version number\r\n numeral.version = VERSION;\r\n\r\n // compare numeral object\r\n numeral.isNumeral = function(obj) {\r\n return obj instanceof Numeral;\r\n };\r\n\r\n // helper functions\r\n numeral._ = _ = {\r\n // formats numbers separators, decimals places, signs, abbreviations\r\n numberToFormat: function(value, format, roundingFunction) {\r\n var locale = locales[numeral.options.currentLocale],\r\n negP = false,\r\n optDec = false,\r\n leadingCount = 0,\r\n abbr = '',\r\n trillion = 1000000000000,\r\n billion = 1000000000,\r\n million = 1000000,\r\n thousand = 1000,\r\n decimal = '',\r\n neg = false,\r\n abbrForce, // force abbreviation\r\n abs,\r\n min,\r\n max,\r\n power,\r\n int,\r\n precision,\r\n signed,\r\n thousands,\r\n output;\r\n\r\n // make sure we never format a null value\r\n value = value || 0;\r\n\r\n abs = Math.abs(value);\r\n\r\n // see if we should use parentheses for negative number or if we should prefix with a sign\r\n // if both are present we default to parentheses\r\n if (numeral._.includes(format, '(')) {\r\n negP = true;\r\n format = format.replace(/[\\(|\\)]/g, '');\r\n } else if (numeral._.includes(format, '+') || numeral._.includes(format, '-')) {\r\n signed = numeral._.includes(format, '+') ? format.indexOf('+') : value < 0 ? format.indexOf('-') : -1;\r\n format = format.replace(/[\\+|\\-]/g, '');\r\n }\r\n\r\n // see if abbreviation is wanted\r\n if (numeral._.includes(format, 'a')) {\r\n abbrForce = format.match(/a(k|m|b|t)?/);\r\n\r\n abbrForce = abbrForce ? abbrForce[1] : false;\r\n\r\n // check for space before abbreviation\r\n if (numeral._.includes(format, ' a')) {\r\n abbr = ' ';\r\n }\r\n\r\n format = format.replace(new RegExp(abbr + 'a[kmbt]?'), '');\r\n\r\n if (abs >= trillion && !abbrForce || abbrForce === 't') {\r\n // trillion\r\n abbr += locale.abbreviations.trillion;\r\n value = value / trillion;\r\n } else if (abs < trillion && abs >= billion && !abbrForce || abbrForce === 'b') {\r\n // billion\r\n abbr += locale.abbreviations.billion;\r\n value = value / billion;\r\n } else if (abs < billion && abs >= million && !abbrForce || abbrForce === 'm') {\r\n // million\r\n abbr += locale.abbreviations.million;\r\n value = value / million;\r\n } else if (abs < million && abs >= thousand && !abbrForce || abbrForce === 'k') {\r\n // thousand\r\n abbr += locale.abbreviations.thousand;\r\n value = value / thousand;\r\n }\r\n }\r\n\r\n // check for optional decimals\r\n if (numeral._.includes(format, '[.]')) {\r\n optDec = true;\r\n format = format.replace('[.]', '.');\r\n }\r\n\r\n // break number and format\r\n int = value.toString().split('.')[0];\r\n precision = format.split('.')[1];\r\n thousands = format.indexOf(',');\r\n leadingCount = (format.split('.')[0].split(',')[0].match(/0/g) || []).length;\r\n\r\n if (precision) {\r\n if (numeral._.includes(precision, '[')) {\r\n precision = precision.replace(']', '');\r\n precision = precision.split('[');\r\n decimal = numeral._.toFixed(value, (precision[0].length + precision[1].length), roundingFunction, precision[1].length);\r\n } else {\r\n decimal = numeral._.toFixed(value, precision.length, roundingFunction);\r\n }\r\n\r\n int = decimal.split('.')[0];\r\n\r\n if (numeral._.includes(decimal, '.')) {\r\n decimal = locale.delimiters.decimal + decimal.split('.')[1];\r\n } else {\r\n decimal = '';\r\n }\r\n\r\n if (optDec && Number(decimal.slice(1)) === 0) {\r\n decimal = '';\r\n }\r\n } else {\r\n int = numeral._.toFixed(value, 0, roundingFunction);\r\n }\r\n\r\n // check abbreviation again after rounding\r\n if (abbr && !abbrForce && Number(int) >= 1000 && abbr !== locale.abbreviations.trillion) {\r\n int = String(Number(int) / 1000);\r\n\r\n switch (abbr) {\r\n case locale.abbreviations.thousand:\r\n abbr = locale.abbreviations.million;\r\n break;\r\n case locale.abbreviations.million:\r\n abbr = locale.abbreviations.billion;\r\n break;\r\n case locale.abbreviations.billion:\r\n abbr = locale.abbreviations.trillion;\r\n break;\r\n }\r\n }\r\n\r\n\r\n // format number\r\n if (numeral._.includes(int, '-')) {\r\n int = int.slice(1);\r\n neg = true;\r\n }\r\n\r\n if (int.length < leadingCount) {\r\n for (var i = leadingCount - int.length; i > 0; i--) {\r\n int = '0' + int;\r\n }\r\n }\r\n\r\n if (thousands > -1) {\r\n int = int.toString().replace(/(\\d)(?=(\\d{3})+(?!\\d))/g, '$1' + locale.delimiters.thousands);\r\n }\r\n\r\n if (format.indexOf('.') === 0) {\r\n int = '';\r\n }\r\n\r\n output = int + decimal + (abbr ? abbr : '');\r\n\r\n if (negP) {\r\n output = (negP && neg ? '(' : '') + output + (negP && neg ? ')' : '');\r\n } else {\r\n if (signed >= 0) {\r\n output = signed === 0 ? (neg ? '-' : '+') + output : output + (neg ? '-' : '+');\r\n } else if (neg) {\r\n output = '-' + output;\r\n }\r\n }\r\n\r\n return output;\r\n },\r\n // unformats numbers separators, decimals places, signs, abbreviations\r\n stringToNumber: function(string) {\r\n var locale = locales[options.currentLocale],\r\n stringOriginal = string,\r\n abbreviations = {\r\n thousand: 3,\r\n million: 6,\r\n billion: 9,\r\n trillion: 12\r\n },\r\n abbreviation,\r\n value,\r\n i,\r\n regexp;\r\n\r\n if (options.zeroFormat && string === options.zeroFormat) {\r\n value = 0;\r\n } else if (options.nullFormat && string === options.nullFormat || !string.replace(/[^0-9]+/g, '').length) {\r\n value = null;\r\n } else {\r\n value = 1;\r\n\r\n if (locale.delimiters.decimal !== '.') {\r\n string = string.replace(/\\./g, '').replace(locale.delimiters.decimal, '.');\r\n }\r\n\r\n for (abbreviation in abbreviations) {\r\n regexp = new RegExp('[^a-zA-Z]' + locale.abbreviations[abbreviation] + '(?:\\\\)|(\\\\' + locale.currency.symbol + ')?(?:\\\\))?)?$');\r\n\r\n if (stringOriginal.match(regexp)) {\r\n value *= Math.pow(10, abbreviations[abbreviation]);\r\n break;\r\n }\r\n }\r\n\r\n // check for negative number\r\n value *= (string.split('-').length + Math.min(string.split('(').length - 1, string.split(')').length - 1)) % 2 ? 1 : -1;\r\n\r\n // remove non numbers\r\n string = string.replace(/[^0-9\\.]+/g, '');\r\n\r\n value *= Number(string);\r\n }\r\n\r\n return value;\r\n },\r\n isNaN: function(value) {\r\n return typeof value === 'number' && isNaN(value);\r\n },\r\n includes: function(string, search) {\r\n return string.indexOf(search) !== -1;\r\n },\r\n insert: function(string, subString, start) {\r\n return string.slice(0, start) + subString + string.slice(start);\r\n },\r\n reduce: function(array, callback /*, initialValue*/) {\r\n if (this === null) {\r\n throw new TypeError('Array.prototype.reduce called on null or undefined');\r\n }\r\n\r\n if (typeof callback !== 'function') {\r\n throw new TypeError(callback + ' is not a function');\r\n }\r\n\r\n var t = Object(array),\r\n len = t.length >>> 0,\r\n k = 0,\r\n value;\r\n\r\n if (arguments.length === 3) {\r\n value = arguments[2];\r\n } else {\r\n while (k < len && !(k in t)) {\r\n k++;\r\n }\r\n\r\n if (k >= len) {\r\n throw new TypeError('Reduce of empty array with no initial value');\r\n }\r\n\r\n value = t[k++];\r\n }\r\n for (; k < len; k++) {\r\n if (k in t) {\r\n value = callback(value, t[k], k, t);\r\n }\r\n }\r\n return value;\r\n },\r\n /**\r\n * Computes the multiplier necessary to make x >= 1,\r\n * effectively eliminating miscalculations caused by\r\n * finite precision.\r\n */\r\n multiplier: function (x) {\r\n var parts = x.toString().split('.');\r\n\r\n return parts.length < 2 ? 1 : Math.pow(10, parts[1].length);\r\n },\r\n /**\r\n * Given a variable number of arguments, returns the maximum\r\n * multiplier that must be used to normalize an operation involving\r\n * all of them.\r\n */\r\n correctionFactor: function () {\r\n var args = Array.prototype.slice.call(arguments);\r\n\r\n return args.reduce(function(accum, next) {\r\n var mn = _.multiplier(next);\r\n return accum > mn ? accum : mn;\r\n }, 1);\r\n },\r\n /**\r\n * Implementation of toFixed() that treats floats more like decimals\r\n *\r\n * Fixes binary rounding issues (eg. (0.615).toFixed(2) === '0.61') that present\r\n * problems for accounting- and finance-related software.\r\n */\r\n toFixed: function(value, maxDecimals, roundingFunction, optionals) {\r\n var splitValue = value.toString().split('.'),\r\n minDecimals = maxDecimals - (optionals || 0),\r\n boundedPrecision,\r\n optionalsRegExp,\r\n power,\r\n output;\r\n\r\n // Use the smallest precision value possible to avoid errors from floating point representation\r\n if (splitValue.length === 2) {\r\n boundedPrecision = Math.min(Math.max(splitValue[1].length, minDecimals), maxDecimals);\r\n } else {\r\n boundedPrecision = minDecimals;\r\n }\r\n\r\n power = Math.pow(10, boundedPrecision);\r\n\r\n // Multiply up by precision, round accurately, then divide and use native toFixed():\r\n output = (roundingFunction(value + 'e+' + boundedPrecision) / power).toFixed(boundedPrecision);\r\n\r\n if (optionals > maxDecimals - boundedPrecision) {\r\n optionalsRegExp = new RegExp('\\\\.?0{1,' + (optionals - (maxDecimals - boundedPrecision)) + '}$');\r\n output = output.replace(optionalsRegExp, '');\r\n }\r\n\r\n return output;\r\n }\r\n };\r\n\r\n // avaliable options\r\n numeral.options = options;\r\n\r\n // avaliable formats\r\n numeral.formats = formats;\r\n\r\n // avaliable formats\r\n numeral.locales = locales;\r\n\r\n // This function sets the current locale. If\r\n // no arguments are passed in, it will simply return the current global\r\n // locale key.\r\n numeral.locale = function(key) {\r\n if (key) {\r\n options.currentLocale = key.toLowerCase();\r\n }\r\n\r\n return options.currentLocale;\r\n };\r\n\r\n // This function provides access to the loaded locale data. If\r\n // no arguments are passed in, it will simply return the current\r\n // global locale object.\r\n numeral.localeData = function(key) {\r\n if (!key) {\r\n return locales[options.currentLocale];\r\n }\r\n\r\n key = key.toLowerCase();\r\n\r\n if (!locales[key]) {\r\n throw new Error('Unknown locale : ' + key);\r\n }\r\n\r\n return locales[key];\r\n };\r\n\r\n numeral.reset = function() {\r\n for (var property in defaults) {\r\n options[property] = defaults[property];\r\n }\r\n };\r\n\r\n numeral.zeroFormat = function(format) {\r\n options.zeroFormat = typeof(format) === 'string' ? format : null;\r\n };\r\n\r\n numeral.nullFormat = function (format) {\r\n options.nullFormat = typeof(format) === 'string' ? format : null;\r\n };\r\n\r\n numeral.defaultFormat = function(format) {\r\n options.defaultFormat = typeof(format) === 'string' ? format : '0.0';\r\n };\r\n\r\n numeral.register = function(type, name, format) {\r\n name = name.toLowerCase();\r\n\r\n if (this[type + 's'][name]) {\r\n throw new TypeError(name + ' ' + type + ' already registered.');\r\n }\r\n\r\n this[type + 's'][name] = format;\r\n\r\n return format;\r\n };\r\n\r\n\r\n numeral.validate = function(val, culture) {\r\n var _decimalSep,\r\n _thousandSep,\r\n _currSymbol,\r\n _valArray,\r\n _abbrObj,\r\n _thousandRegEx,\r\n localeData,\r\n temp;\r\n\r\n //coerce val to string\r\n if (typeof val !== 'string') {\r\n val += '';\r\n\r\n if (console.warn) {\r\n console.warn('Numeral.js: Value is not string. It has been co-erced to: ', val);\r\n }\r\n }\r\n\r\n //trim whitespaces from either sides\r\n val = val.trim();\r\n\r\n //if val is just digits return true\r\n if (!!val.match(/^\\d+$/)) {\r\n return true;\r\n }\r\n\r\n //if val is empty return false\r\n if (val === '') {\r\n return false;\r\n }\r\n\r\n //get the decimal and thousands separator from numeral.localeData\r\n try {\r\n //check if the culture is understood by numeral. if not, default it to current locale\r\n localeData = numeral.localeData(culture);\r\n } catch (e) {\r\n localeData = numeral.localeData(numeral.locale());\r\n }\r\n\r\n //setup the delimiters and currency symbol based on culture/locale\r\n _currSymbol = localeData.currency.symbol;\r\n _abbrObj = localeData.abbreviations;\r\n _decimalSep = localeData.delimiters.decimal;\r\n if (localeData.delimiters.thousands === '.') {\r\n _thousandSep = '\\\\.';\r\n } else {\r\n _thousandSep = localeData.delimiters.thousands;\r\n }\r\n\r\n // validating currency symbol\r\n temp = val.match(/^[^\\d]+/);\r\n if (temp !== null) {\r\n val = val.substr(1);\r\n if (temp[0] !== _currSymbol) {\r\n return false;\r\n }\r\n }\r\n\r\n //validating abbreviation symbol\r\n temp = val.match(/[^\\d]+$/);\r\n if (temp !== null) {\r\n val = val.slice(0, -1);\r\n if (temp[0] !== _abbrObj.thousand && temp[0] !== _abbrObj.million && temp[0] !== _abbrObj.billion && temp[0] !== _abbrObj.trillion) {\r\n return false;\r\n }\r\n }\r\n\r\n _thousandRegEx = new RegExp(_thousandSep + '{2}');\r\n\r\n if (!val.match(/[^\\d.,]/g)) {\r\n _valArray = val.split(_decimalSep);\r\n if (_valArray.length > 2) {\r\n return false;\r\n } else {\r\n if (_valArray.length < 2) {\r\n return ( !! _valArray[0].match(/^\\d+.*\\d$/) && !_valArray[0].match(_thousandRegEx));\r\n } else {\r\n if (_valArray[0].length === 1) {\r\n return ( !! _valArray[0].match(/^\\d+$/) && !_valArray[0].match(_thousandRegEx) && !! _valArray[1].match(/^\\d+$/));\r\n } else {\r\n return ( !! _valArray[0].match(/^\\d+.*\\d$/) && !_valArray[0].match(_thousandRegEx) && !! _valArray[1].match(/^\\d+$/));\r\n }\r\n }\r\n }\r\n }\r\n\r\n return false;\r\n };\r\n\r\n\r\n /************************************\r\n Numeral Prototype\r\n ************************************/\r\n\r\n numeral.fn = Numeral.prototype = {\r\n clone: function() {\r\n return numeral(this);\r\n },\r\n format: function(inputString, roundingFunction) {\r\n var value = this._value,\r\n format = inputString || options.defaultFormat,\r\n kind,\r\n output,\r\n formatFunction;\r\n\r\n // make sure we have a roundingFunction\r\n roundingFunction = roundingFunction || Math.round;\r\n\r\n // format based on value\r\n if (value === 0 && options.zeroFormat !== null) {\r\n output = options.zeroFormat;\r\n } else if (value === null && options.nullFormat !== null) {\r\n output = options.nullFormat;\r\n } else {\r\n for (kind in formats) {\r\n if (format.match(formats[kind].regexps.format)) {\r\n formatFunction = formats[kind].format;\r\n\r\n break;\r\n }\r\n }\r\n\r\n formatFunction = formatFunction || numeral._.numberToFormat;\r\n\r\n output = formatFunction(value, format, roundingFunction);\r\n }\r\n\r\n return output;\r\n },\r\n value: function() {\r\n return this._value;\r\n },\r\n input: function() {\r\n return this._input;\r\n },\r\n set: function(value) {\r\n this._value = Number(value);\r\n\r\n return this;\r\n },\r\n add: function(value) {\r\n var corrFactor = _.correctionFactor.call(null, this._value, value);\r\n\r\n function cback(accum, curr, currI, O) {\r\n return accum + Math.round(corrFactor * curr);\r\n }\r\n\r\n this._value = _.reduce([this._value, value], cback, 0) / corrFactor;\r\n\r\n return this;\r\n },\r\n subtract: function(value) {\r\n var corrFactor = _.correctionFactor.call(null, this._value, value);\r\n\r\n function cback(accum, curr, currI, O) {\r\n return accum - Math.round(corrFactor * curr);\r\n }\r\n\r\n this._value = _.reduce([value], cback, Math.round(this._value * corrFactor)) / corrFactor;\r\n\r\n return this;\r\n },\r\n multiply: function(value) {\r\n function cback(accum, curr, currI, O) {\r\n var corrFactor = _.correctionFactor(accum, curr);\r\n return Math.round(accum * corrFactor) * Math.round(curr * corrFactor) / Math.round(corrFactor * corrFactor);\r\n }\r\n\r\n this._value = _.reduce([this._value, value], cback, 1);\r\n\r\n return this;\r\n },\r\n divide: function(value) {\r\n function cback(accum, curr, currI, O) {\r\n var corrFactor = _.correctionFactor(accum, curr);\r\n return Math.round(accum * corrFactor) / Math.round(curr * corrFactor);\r\n }\r\n\r\n this._value = _.reduce([this._value, value], cback);\r\n\r\n return this;\r\n },\r\n difference: function(value) {\r\n return Math.abs(numeral(this._value).subtract(value).value());\r\n }\r\n };\r\n\r\n /************************************\r\n Default Locale && Format\r\n ************************************/\r\n\r\n numeral.register('locale', 'en', {\r\n delimiters: {\r\n thousands: ',',\r\n decimal: '.'\r\n },\r\n abbreviations: {\r\n thousand: 'k',\r\n million: 'm',\r\n billion: 'b',\r\n trillion: 't'\r\n },\r\n ordinal: function(number) {\r\n var b = number % 10;\r\n return (~~(number % 100 / 10) === 1) ? 'th' :\r\n (b === 1) ? 'st' :\r\n (b === 2) ? 'nd' :\r\n (b === 3) ? 'rd' : 'th';\r\n },\r\n currency: {\r\n symbol: '$'\r\n }\r\n });\r\n\r\n return numeral;\r\n}));\r\n","/* tslint:disable */\r\n/* eslint-disable */\r\n/* eslint default-case: \"off\"*/\r\n\r\nimport React from \"react\"\r\nimport \"./styles.css\"\r\nconst DEFAULT_ZOOM_STEP = 0.3\r\nconst DEFAULT_LARGE_ZOOM = 4\r\nfunction getXY(e) {\r\n let x = 0\r\n let y = 0\r\n if (e.touches && e.touches.length) {\r\n x = e.touches[0].pageX\r\n y = e.touches[0].pageY\r\n } else {\r\n x = e.pageX\r\n y = e.pageY\r\n }\r\n return { x, y }\r\n}\r\nfunction Cond(props) {\r\n if (!props.condition) return null\r\n return {props.children}\r\n}\r\nexport default class Lightbox extends React.Component {\r\n initX = 0\r\n initY = 0\r\n lastX = 0\r\n lastY = 0\r\n _cont = React.createRef()\r\n state = {\r\n x: 0,\r\n y: 0,\r\n zoom: 1,\r\n rotate: 0,\r\n loading: true,\r\n moving: false,\r\n current: this.props?.startIndex ?? 0,\r\n multi: this.props?.images?.length ? true : false,\r\n }\r\n createTransform = (x, y, zoom, rotate) =>\r\n `translate3d(${x}px,${y}px,0px) scale(${zoom}) rotate(${rotate}deg)`\r\n stopSideEffect = e => e.stopPropagation()\r\n getCurrentImage = (s, p) => {\r\n if (!s.multi) return p.image ?? \"\"\r\n if (p.images == null) return \"\"\r\n return p.images[s.current]?.url ?? p.images?.[s.current] ?? \"\"\r\n }\r\n getCurrentTitle = (s, p) => {\r\n if (!s.multi) return p.title ?? \"\"\r\n return p.images?.[s.current]?.title ?? \"\"\r\n }\r\n resetZoom = () => this.setState({ x: 0, y: 0, zoom: 1 })\r\n shockZoom = e => {\r\n let {\r\n zoomStep = DEFAULT_ZOOM_STEP,\r\n allowZoom = true,\r\n doubleClickZoom = DEFAULT_LARGE_ZOOM,\r\n } = this.props\r\n if (!allowZoom || !doubleClickZoom) return false\r\n this.stopSideEffect(e)\r\n if (this.state.zoom > 1) return this.resetZoom()\r\n const _z =\r\n (zoomStep < 1 ? Math.ceil(doubleClickZoom / zoomStep) : zoomStep) *\r\n zoomStep\r\n const _xy = getXY(e)\r\n const _cbr = this._cont.current?.getBoundingClientRect?.()\r\n const _ccx = _cbr.x + _cbr.width / 2\r\n const _ccy = _cbr.y + _cbr.height / 2\r\n const x = (_xy.x - _ccx) * -1 * _z\r\n const y = (_xy.y - _ccy) * -1 * _z\r\n this.setState({ x, y, zoom: _z })\r\n }\r\n navigateImage = (direction, e) => {\r\n this.stopSideEffect(e)\r\n let current = 0\r\n switch (direction) {\r\n case \"next\":\r\n current = this.state.current + 1\r\n break\r\n case \"prev\":\r\n current = this.state.current - 1\r\n break\r\n }\r\n if (current >= this.props.images.length) current = 0\r\n else if (current < 0) current = this.props.images.length - 1\r\n this.setState({ current, x: 0, y: 0, zoom: 1, rotate: 0, loading: true })\r\n }\r\n startMove = e => {\r\n if (this.state.zoom <= 1) return false\r\n this.setState({ moving: true })\r\n let xy = getXY(e)\r\n this.initX = xy.x - this.lastX\r\n this.initY = xy.y - this.lastY\r\n }\r\n duringMove = e => {\r\n if (!this.state.moving) return false\r\n let xy = getXY(e)\r\n this.lastX = xy.x - this.initX\r\n this.lastY = xy.y - this.initY\r\n this.setState({\r\n x: xy.x - this.initX,\r\n y: xy.y - this.initY,\r\n })\r\n }\r\n endMove = e => this.setState({ moving: false })\r\n applyZoom = type => {\r\n let { zoomStep = DEFAULT_ZOOM_STEP } = this.props\r\n switch (type) {\r\n case \"in\":\r\n this.setState({ zoom: this.state.zoom + zoomStep })\r\n break\r\n case \"out\":\r\n let newZoom = this.state.zoom - zoomStep\r\n if (newZoom < 1) break\r\n else if (newZoom === 1) this.setState({ x: 0, y: 0, zoom: 1 })\r\n else this.setState({ zoom: newZoom })\r\n break\r\n case \"reset\":\r\n this.resetZoom()\r\n break\r\n }\r\n }\r\n applyRotate = type => {\r\n switch (type) {\r\n case \"cw\":\r\n this.setState({ rotate: this.state.rotate + 90 })\r\n break\r\n case \"acw\":\r\n this.setState({ rotate: this.state.rotate - 90 })\r\n break\r\n }\r\n }\r\n reset = e => {\r\n this.stopSideEffect(e)\r\n this.setState({ x: 0, y: 0, zoom: 1, rotate: 0 })\r\n }\r\n exit = e => {\r\n if (typeof this.props.onClose === \"function\") return this.props.onClose(e)\r\n console.error(\r\n \"No Exit function passed on prop: onClose. Clicking the close button will do nothing\"\r\n )\r\n }\r\n shouldShowReset = () =>\r\n this.state.x ||\r\n this.state.y ||\r\n this.state.zoom !== 1 ||\r\n this.state.rotate !== 0\r\n canvasClick = e => {\r\n let { clickOutsideToExit = true } = this.props\r\n if (clickOutsideToExit && this.state.zoom <= 1) return this.exit(e)\r\n }\r\n keyboardNavigation = e => {\r\n let { allowZoom = true, allowReset = true } = this.props\r\n let { multi, x, y, zoom } = this.state\r\n switch (e.key) {\r\n case \"ArrowLeft\":\r\n if (multi && zoom === 1) this.navigateImage(\"prev\", e)\r\n else if (zoom > 1) this.setState({ x: x - 20 })\r\n break\r\n case \"ArrowRight\":\r\n if (multi && zoom === 1) this.navigateImage(\"next\", e)\r\n else if (zoom > 1) this.setState({ x: x + 20 })\r\n break\r\n case \"ArrowUp\":\r\n if (zoom > 1) this.setState({ y: y + 20 })\r\n break\r\n case \"ArrowDown\":\r\n if (zoom > 1) this.setState({ y: y - 20 })\r\n break\r\n case \"+\":\r\n if (allowZoom) this.applyZoom(\"in\")\r\n break\r\n case \"-\":\r\n if (allowZoom) this.applyZoom(\"out\")\r\n break\r\n case \"Escape\":\r\n if (allowReset && this.shouldShowReset()) this.reset(e)\r\n else this.exit(e)\r\n break\r\n }\r\n }\r\n componentDidMount() {\r\n document.body.classList.add(\"lb-open-lightbox\")\r\n let { keyboardInteraction = true } = this.props\r\n if (keyboardInteraction)\r\n document.addEventListener(\"keyup\", this.keyboardNavigation)\r\n }\r\n componentWillUnmount() {\r\n document.body.classList.remove(\"lb-open-lightbox\")\r\n let { keyboardInteraction = true } = this.props\r\n if (keyboardInteraction)\r\n document.removeEventListener(\"keyup\", this.keyboardNavigation)\r\n }\r\n render() {\r\n let image = this.getCurrentImage(this.state, this.props)\r\n let title = this.getCurrentTitle(this.state, this.props)\r\n if (!image) {\r\n console.warn(\"Not showing lightbox because no image(s) was supplied\")\r\n return null\r\n }\r\n let {\r\n allowZoom = true,\r\n allowRotate = true,\r\n buttonAlign = \"flex-end\",\r\n showTitle = true,\r\n allowReset = true,\r\n } = this.props\r\n let { x, y, zoom, rotate, multi, loading, moving } = this.state\r\n let _reset = allowReset && this.shouldShowReset()\r\n return (\r\n
\r\n
\r\n \r\n \r\n \r\n {title}\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n this.navigateImage(\"prev\", e)}\r\n >\r\n this.navigateImage(\"next\", e)}\r\n >\r\n \r\n \r\n this.applyZoom(\"in\")}\r\n >\r\n this.applyZoom(\"out\")}\r\n >\r\n \r\n \r\n this.applyRotate(\"acw\")}\r\n >\r\n this.applyRotate(\"cw\")}\r\n >\r\n \r\n this.exit(e)}\r\n >\r\n \r\n this.canvasClick(e)}\r\n >\r\n 1 ? \"grab\" : \"unset\",\r\n transition: moving ? \"none\" : \"all 0.1s\",\r\n }}\r\n onMouseDown={e => this.startMove(e)}\r\n onTouchStart={e => this.startMove(e)}\r\n onMouseMove={e => this.duringMove(e)}\r\n onTouchMove={e => this.duringMove(e)}\r\n onMouseUp={e => this.endMove(e)}\r\n onMouseLeave={e => this.endMove(e)}\r\n onTouchEnd={e => this.endMove(e)}\r\n onClick={e => this.stopSideEffect(e)}\r\n onDoubleClick={e => this.shockZoom(e)}\r\n onWheel={e=>{\r\n // console.log(\"onWhell\",e)\r\n if(e.deltaY<0){\r\n this.applyZoom(\"in\")\r\n }\r\n else{\r\n this.applyZoom(\"out\")\r\n }\r\n }}\r\n onLoad={e => this.setState({ loading: false })}\r\n className={`lb-img${loading ? \" lb-loading\" : \"\"}`}\r\n title={title}\r\n src={image}\r\n alt={title}\r\n />\r\n
\r\n {multi ? (\r\n this.navigateImage(\"prev\", e)}\r\n >
\r\n ) : null}\r\n {_reset ? (\r\n \r\n ) : null}\r\n {multi ? (\r\n this.navigateImage(\"next\", e)}\r\n >\r\n ) : null}\r\n \r\n \r\n \r\n )\r\n }\r\n}\r\n","import classnames from \"classnames\"\r\nimport React from \"react\"\r\nimport { Modal } from \"reactstrap\"\r\nimport { objHasKey } from \"src/core/helpers/utils\"\r\nimport ReactAwesomeLightbox from \"src/libs/ReactAwesomeLightbox\"\r\ninterface IProps {\r\n className?: any\r\n style?: any\r\n type: string\r\n}\r\n\r\ninterface IState {\r\n isShow?: boolean\r\n opts?: IConfigLightbox\r\n}\r\n\r\ninterface IConfigLightbox {\r\n component?: any\r\n showFooter?: boolean\r\n modalClassName?: string\r\n modalCentered?: boolean\r\n modalScrollInside?: boolean\r\n title?: string\r\n size?: string\r\n backdrop?: any\r\n fnList?: any\r\n image?: string\r\n images?: any[]\r\n startIndex?: any\r\n}\r\n\r\nclass MyLightbox extends React.Component {\r\n state: any = {\r\n isShow: false,\r\n opts: {},\r\n }\r\n componentDidMount() {\r\n const { type } = this.props\r\n MyLightbox.Helpers.initComponent(type, this)\r\n }\r\n show = (opts: any) => {\r\n this.setState({\r\n isShow: true,\r\n opts: { ...MyLightbox.Helpers.defaultConfigModal, ...opts },\r\n })\r\n }\r\n hide = () => {\r\n this.setState({\r\n isShow: false,\r\n opts: {},\r\n })\r\n }\r\n toggle = () => {\r\n this.setState({\r\n isShow: !this.state.isShow,\r\n })\r\n }\r\n _getConfig = key => {\r\n const { opts } = this.state\r\n if (objHasKey(opts, key)) {\r\n return opts[key]\r\n }\r\n }\r\n _renderBody = () => {\r\n const { opts } = this.state\r\n let _props: any = {}\r\n if (opts.image) {\r\n _props.image = opts.image\r\n } else if (opts.images) {\r\n _props.startIndex = opts.startIndex\r\n _props.images = opts.images\r\n }\r\n return (\r\n {\r\n this.hide()\r\n }}\r\n />\r\n )\r\n }\r\n _renderHeaderContent = () => {\r\n const { opts } = this.state\r\n return opts.title\r\n }\r\n _getClassname = () => {\r\n const { opts } = this.state\r\n return classnames(opts.modalClassName, {\r\n \"modal-dialog-centered\": opts.modalCentered,\r\n [`modal-${opts.size}`]: true, //sm,lg,xl\r\n \"modal-dialog-scrollable\": opts.modalScrollInside,\r\n })\r\n }\r\n render() {\r\n const { isShow, opts } = this.state\r\n const { backdrop } = opts\r\n return (\r\n \r\n {this._renderBody()}\r\n \r\n )\r\n }\r\n static Helpers = {\r\n defaultConfigModal: {\r\n usingModalBody: true,\r\n size: \"lightbox\",\r\n },\r\n types: {\r\n lightbox: \"lightbox\",\r\n },\r\n initComponent: (type, component) => {\r\n if (type && component) {\r\n MyLightbox.Helpers.components[type] = component\r\n }\r\n },\r\n components: {},\r\n }\r\n static showWithOpts = (opts: IConfigLightbox) => {\r\n if (MyLightbox.Helpers.components[MyLightbox.Helpers.types.lightbox]) {\r\n MyLightbox.Helpers.components[MyLightbox.Helpers.types.lightbox].show(\r\n opts\r\n )\r\n }\r\n }\r\n}\r\n\r\nexport default MyLightbox\r\n","import { HRegex } from \"@macashipo/mlib\"\r\nexport const RGSquareBracket = HRegex.RGSquareBracket\r\n","import { MyFormControlHelpers, HIs, HJson } from \"@macashipo/mlib\"\r\nimport { FlowGetConfigFormFromConfigServer } from \"src/helpers/Flows/Form\"\r\n\r\n// import MyComponentHelpers from \"../MyCore/MyComponentHelpers\"\r\n// import MyFormControlTypes from \"./MyFormControlTypes\"\r\n// const MyFormControlHelpers = {\r\n// getTypeFn(props: any) {\r\n// // console.warn(\"MyFormControlTypes:\", MyFormControlTypes.Types, props)\r\n// return MyComponentHelpers.getTypeFn(MyFormControlTypes.Types, props)\r\n// },\r\n// }\r\n/**\r\nDisabled: null\r\nFieldName: \"DisplayName\"\r\nHint: null\r\nLabel: \"Full Name\"\r\nProps: null\r\nRequired: null\r\nSource: null\r\nSourceField: null\r\nSourceList: null\r\nStyle: null\r\nSubmitAfterChange: null\r\nType: \"text\"\r\n */\r\nMyFormControlHelpers[\"getConfigFormFromConfigV1\"] = function (\r\n configV1: any,\r\n { defaultValues, fnList } = { defaultValues: {}, fnList: {} }\r\n) {\r\n return FlowGetConfigFormFromConfigServer(configV1, {\r\n defaultValues,\r\n fnList,\r\n moreDefaultValues: null,\r\n })\r\n}\r\nexport default MyFormControlHelpers\r\n","import { MyFormControl } from \"@macashipo/mlib\"\r\nexport default MyFormControl\r\n","import { HJson } from \"@macashipo/mlib\"\r\n\r\nexport const getObj = HJson.getObj\r\nexport const getString = HJson.getString\r\nexport const json2Obj = HJson.json2Obj\r\nexport const obj2Json = HJson.getString\r\n","import { FlowApiShowFullPath } from \"src/helpers/Flows/Api\"\r\n\r\nexport const parseResponseButtonApi = function (\r\n res: any,\r\n {\r\n target = \"_blank\",\r\n autoOpenLink = false,\r\n linkOpen = null,\r\n noCheckFullPath = false,\r\n } = {}\r\n) {\r\n if (res && res.Data && noCheckFullPath !== true) {\r\n FlowApiShowFullPath({\r\n response: res,\r\n configFullPath: res.Data,\r\n target,\r\n autoOpenLink,\r\n linkOpen,\r\n })\r\n }\r\n}\r\n","import { createBrowserHistory, createHashHistory } from \"history\"\r\nimport { HLink } from \"@macashipo/mlib\"\r\n// import { mergeObjIfExist } from \"./utils\"\r\n// export const getParameterByName = HLink.getParameterByName\r\n\r\n// const LinkInfo: any = {\r\n// usingHash: false,\r\n// history: null,\r\n// }\r\n\r\n// export const initLink = (info: any) => {\r\n// mergeObjIfExist(LinkInfo, info)\r\n// if (LinkInfo.usingHash) {\r\n// LinkInfo.history = createHashHistory()\r\n// } else {\r\n// LinkInfo.history = createBrowserHistory()\r\n// }\r\n// console.warn(\"initLink:\", LinkInfo)\r\n// }\r\n\r\n// export const getHistory = () => {\r\n// return LinkInfo.history\r\n// }\r\n\r\n// export const push = (link: string) => {\r\n// if (LinkInfo.history) {\r\n// LinkInfo.history.push(link)\r\n// } else {\r\n// window.location.href = link\r\n// }\r\n// }\r\n\r\n// export const openUrl = function (link: string, target: string = \"_blank\") {\r\n// if (link) {\r\n// if (link.startsWith(\"http\")) {\r\n// return window.open(link, target)\r\n// } else if (link.indexOf(\"://\") > -1) {\r\n// return window.open(link, target)\r\n// }\r\n// }\r\n// if (target === \"_blank\") {\r\n// window.open(link, target)\r\n// } else {\r\n// push(link)\r\n// }\r\n// }\r\n\r\nexport const initLink = (info: any) => {\r\n if (info.usingHash) {\r\n info.history = createHashHistory()\r\n } else {\r\n info.history = createBrowserHistory({\r\n basename: process.env.PUBLIC_URL,\r\n })\r\n }\r\n HLink.initLink(info)\r\n}\r\nexport const openUrl = HLink.openUrl\r\nexport const push = HLink.push\r\nexport default HLink\r\n","import HConstant from \"./constant\"\r\nconst C: {\r\n HConfig: IHConfig | null\r\n initC: (HConfig: IHConfig) => void\r\n getAuthUserName: () => any\r\n getAuthUserId: () => any\r\n getConfig: (key: string) => any\r\n getDefaultFormatDate: () => string\r\n getDefaultFormatDateTime: () => string\r\n} = {\r\n HConfig: null,\r\n initC(HConfig: IHConfig) {\r\n C.HConfig = HConfig\r\n },\r\n getAuthUserName() {\r\n return C.HConfig?.getAuthUserName()\r\n },\r\n getAuthUserId() {\r\n return C.HConfig?.getAuthUserId()\r\n },\r\n getConfig(key: string) {\r\n return C.HConfig?.getConfig(key)\r\n },\r\n getDefaultFormatDate() {\r\n return C.HConfig?.getConfig(HConstant.ConfigAppExt.dateFormat) || \"DD-MMMYY\"\r\n },\r\n getDefaultFormatDateTime() {\r\n return (\r\n C.HConfig?.getConfig(HConstant.ConfigAppExt.datetimeFormat) ||\r\n \"DD-MMMYY hh:mm\"\r\n )\r\n },\r\n}\r\n\r\nexport default C\r\n","import { HCF } from \"@macashipo/mlib\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nconst ServiceWorker = {\r\n init() {\r\n if (ServiceWorker.isSupported()) {\r\n let _arrSW = HCF.getCF(KConfigApp.serviceWorkersRun)\r\n if (_arrSW) {\r\n for (let sw of _arrSW) {\r\n ServiceWorker.enableNotification(sw)\r\n }\r\n }\r\n } else {\r\n console.warn(\"Service worker not supported\")\r\n }\r\n },\r\n isSupported() {\r\n if (!(\"serviceWorker\" in navigator)) {\r\n // Service Worker isn't supported on this browser, disable or hide UI.\r\n return false\r\n }\r\n if (!(\"PushManager\" in window)) {\r\n // Push isn't supported on this browser, disable or hide UI.\r\n return false\r\n }\r\n return true\r\n },\r\n registerSW(link) {\r\n //check exist\r\n console.warn(\"check exist before registrer\")\r\n ServiceWorker.getSW(link).then(sw => {\r\n console.warn(\"sw\", sw)\r\n })\r\n return navigator.serviceWorker.register(link)\r\n },\r\n getSW(link) {\r\n return navigator.serviceWorker.getRegistration(link)\r\n },\r\n enableNotification(linkSW) {\r\n Notification.requestPermission().then(result => {\r\n if (result === \"granted\") {\r\n return ServiceWorker.registerSW(linkSW)\r\n .then(reg => {\r\n console.warn(\"Registered service worker\")\r\n var serviceWorker\r\n if (reg.installing) {\r\n serviceWorker = reg.installing\r\n } else if (reg.waiting) {\r\n serviceWorker = reg.waiting\r\n } else if (reg.active) {\r\n serviceWorker = reg.active\r\n }\r\n\r\n if (serviceWorker) {\r\n console.log(\"ServiceWorker phase:\", serviceWorker.state)\r\n\r\n serviceWorker.addEventListener(\"statechange\", function (e) {\r\n console.log(\"ServiceWorker phase:\", e.target.state)\r\n })\r\n }\r\n })\r\n .catch(err => {\r\n console.warn(\"Register service worker failed\", err)\r\n })\r\n }\r\n })\r\n },\r\n disableNotification(linkSW) {\r\n ServiceWorker.getSW(linkSW).then(sw => {\r\n if (sw) {\r\n sw.unregister()\r\n }\r\n })\r\n },\r\n showNotification(linkSW, body, tag, data) {\r\n ServiceWorker.getSW(linkSW).then(sw => {\r\n if (sw) {\r\n const title = \"Notification with Data\"\r\n const options = {\r\n body:\r\n body ||\r\n \"This notification has data attached to it that is printed \" +\r\n \"to the console when it's clicked.\",\r\n tag: tag || \"data-notification\",\r\n data: data || {\r\n createdAt: new Date(Date.now()).toString(),\r\n message: \"Hello, World!\",\r\n },\r\n }\r\n sw.showNotification(title, options)\r\n } else {\r\n console.warn(\"Missing service worker\", sw)\r\n }\r\n })\r\n },\r\n showNotificationWithoutServiceWorker({\r\n title,\r\n body,\r\n tag,\r\n icon,\r\n lang,\r\n dir,\r\n }: any = {}) {\r\n var n = new Notification(title || \"Notification\", {\r\n body: body || \"Message\\nPretty cool, huh?\",\r\n tag: new Date().getTime().toString(),\r\n // icon: \"images/Sexy_Ben.jpeg\",\r\n lang: \"\",\r\n dir: \"auto\",\r\n })\r\n n.onclick = function () {\r\n console.log(\"clicked\")\r\n }\r\n n.onshow = function () {\r\n console.log(\"showed\")\r\n }\r\n n.onerror = function () {\r\n console.log(\"errored\")\r\n }\r\n n.onclose = function () {\r\n console.log(\"closed\")\r\n }\r\n },\r\n}\r\nwindow[\"HServiceWorker\"] = ServiceWorker\r\nexport default ServiceWorker\r\n","import HConstant from \"./constant\"\r\nimport { initApi } from \"./api\"\r\nimport { initAuth, getUserID, getUserName } from \"./auth\"\r\nimport { initLink, push } from \"./link\"\r\nimport { initI18n } from \"./i18n\"\r\nimport C from \"./c\"\r\nimport { fnListConfigApp, fnListUI } from \"src/helpers/fnList\"\r\nimport { initLocalStorage } from \"./localStorage\"\r\nimport HServiceWorker from \"./serviceWorker\"\r\nimport {\r\n addArray2Array,\r\n // isArray,\r\n isFunction,\r\n mergeObjIfExist,\r\n runFuntion,\r\n} from \"./utils\"\r\nimport { HModules, HCF, HLink } from \"@macashipo/mlib\"\r\nimport { HUtils } from \".\"\r\nconst configApi: IConfigApi = {\r\n baseUrl: \"\",\r\n timeout: 120000,\r\n}\r\n\r\nconst configRoutes: IRouteConfig = {\r\n routesPublic: [],\r\n routesPrivate: [],\r\n}\r\n\r\nconst configLink: IConfigLink = {\r\n usingHash: false,\r\n}\r\n\r\nconst configSidebar = {\r\n list: [],\r\n}\r\nconst Config: IHConfig = {\r\n appInfo: {\r\n title: \"AllianceITSC\",\r\n appName: \"allianceitsc\",\r\n home: \"/home\",\r\n },\r\n configApp: null,\r\n configAppExt: null,\r\n configI18n: {},\r\n configLink: configLink,\r\n configApi: configApi,\r\n configAuth: {},\r\n configModules: {},\r\n configRoutes: configRoutes,\r\n configSidebar: configSidebar,\r\n extAfterLogin: [],\r\n extSettingParts: [],\r\n headerComponent: null,\r\n initConfigAppExt() {\r\n if (window[\"_ConfigApp\"]) {\r\n Config.configAppExt = window[\"_ConfigApp\"]\r\n HCF.setCFMultiObj(Config.configAppExt)\r\n mergeObjIfExist(Config.appInfo, window[\"_ConfigApp\"])\r\n //\r\n if (\r\n Config.configAppExt &&\r\n Config.configAppExt.baseUrl &&\r\n Config.configApi\r\n ) {\r\n Config.configApi.baseUrl = Config.configAppExt.baseUrl\r\n }\r\n } else {\r\n //\r\n console.error(\"Missing _config.js\")\r\n if (HUtils.isLocalDev()) {\r\n console.error(\"Missing _config.js in dev mode\")\r\n } else {\r\n var dom_firstLoading = document.getElementById(\"first_loading\")\r\n if (dom_firstLoading) {\r\n dom_firstLoading.style.visibility = \"visible\"\r\n dom_firstLoading.style.zIndex = \"100\"\r\n dom_firstLoading.style.background = \"white\"\r\n dom_firstLoading.id = \"first_loading_missing_config\"\r\n dom_firstLoading.innerHTML = `

Missing config

`\r\n }\r\n window[\"_MissingConfig\"] = true\r\n //need send notify or log\r\n }\r\n }\r\n },\r\n initConfigApp(configApp: IConfigApp = {}) {\r\n console.log(\"initConfigApp:\", configApp)\r\n for (let k of Object.keys(configApp)) {\r\n if (\r\n k.startsWith(\"config\") ||\r\n k === \"fnList\" ||\r\n k === \"appInfo\" ||\r\n k === \"UIAppConfig\"\r\n ) {\r\n HCF.setCFMultiObj(configApp[k])\r\n mergeObjIfExist(Config[k], configApp[k])\r\n }\r\n }\r\n //\r\n HCF.setCF(\"addPublicRoutes\", Config.addPublicRoutes)\r\n //\r\n Config.configApp = configApp\r\n Config.initConfigAppExt()\r\n C.initC(Config)\r\n //other helpers\r\n initLink(Config.configLink)\r\n initI18n(Config.configI18n)\r\n initLocalStorage({})\r\n initApi({ ...Config.configApi, appName: Config.appInfo.appName })\r\n initAuth({\r\n ...configApp.configAuth,\r\n afterLogin: () => {\r\n // console.warn(\"afterLogin\")\r\n if (configApp.configAuth && configApp.configAuth.afterLogin) {\r\n configApp.configAuth.afterLogin()\r\n } else {\r\n //go to home - shouldnot push -> create loop\r\n console.warn(\"need push to home\")\r\n // push(Config.appInfo.home)\r\n }\r\n if (Config.extAfterLogin && Config.extAfterLogin.length > 0) {\r\n for (let fn of Config.extAfterLogin) {\r\n if (isFunction(fn)) {\r\n ;(fn as () => void)()\r\n }\r\n }\r\n }\r\n },\r\n afterLogout: () => {\r\n console.warn(\"afterLogout\")\r\n if (configApp.configAuth && configApp.configAuth.afterLogout) {\r\n configApp.configAuth.afterLogout()\r\n } else {\r\n HLink.push(\"/\")\r\n }\r\n },\r\n })\r\n\r\n //modules\r\n HModules.initModules(\r\n configApp.modules as any[],\r\n Config.configModules,\r\n Config\r\n )\r\n // if (configApp.modules && configApp.modules.length > 0) {\r\n // for (let i = 0; i < configApp.modules.length; i++) {\r\n // runFuntion(\r\n // configApp.modules[i],\r\n // HConstant.Modules.FnList.runAfterInit,\r\n // [Config]\r\n // )\r\n // }\r\n // }\r\n runFuntion(configApp.fnList, HConstant.ConfigApp.FnList.onAfterInit, [\r\n Config,\r\n ])\r\n\r\n HServiceWorker.init()\r\n },\r\n fnList: {},\r\n UIAppConfig: {},\r\n getConfig(key: string) {\r\n if (Config.configAppExt && Config.configAppExt.hasOwnProperty(key)) {\r\n return Config.configAppExt[key]\r\n }\r\n if (Config.UIAppConfig && Config.UIAppConfig.hasOwnProperty(key)) {\r\n return Config.UIAppConfig[key]\r\n }\r\n return Config[key]\r\n },\r\n getPublicRoutes() {\r\n return Config.configRoutes.routesPublic\r\n },\r\n getPrivateRoutes() {\r\n return Config.configRoutes.routesPrivate\r\n },\r\n addPublicRoutes(list: IServer.IConfigPage[]) {\r\n addArray2Array(Config.configRoutes.routesPublic, list)\r\n fnListUI.fnForceUpdateRoutes()\r\n },\r\n addPrivateRoutes(list: IServer.IConfigPage[]) {\r\n addArray2Array(Config.configRoutes.routesPrivate, list)\r\n },\r\n addSidebarItems(list) {\r\n addArray2Array(Config.configSidebar.list, list)\r\n },\r\n registerAfterLogin(fn: never) {\r\n Config.extAfterLogin.push(fn)\r\n },\r\n registerExtSettingParts(fn: never) {\r\n Config.extSettingParts.push(fn)\r\n },\r\n registerHeaderTitle(component) {\r\n Config.headerComponent = component\r\n },\r\n changeTitle(title?: any, headerTitle?: any) {\r\n window.document.title = `${title != null ? title + \" - \" : \"\"}${\r\n Config.appInfo.title\r\n }`\r\n if (headerTitle != null && Config.fnList[\"updateHeaderTitle\"]) {\r\n Config.fnList[\"updateHeaderTitle\"](headerTitle)\r\n }\r\n },\r\n goToHome() {\r\n push(Config.appInfo.home)\r\n },\r\n getAuthUserName() {\r\n return getUserName()\r\n },\r\n getAuthUserId() {\r\n return getUserID()\r\n },\r\n getAppName() {\r\n return Config.appInfo.appName\r\n },\r\n addBodyClass(className: string) {\r\n document.body.classList.add(className)\r\n },\r\n removeBodyClass(className: string) {\r\n document.body.classList.remove(className)\r\n },\r\n getConfigFooter() {\r\n let _footer = 'Allianceitsc © 2022.'\r\n let _configFooter = {\r\n show: true,\r\n footer: _footer,\r\n }\r\n if (Config.configAppExt) {\r\n if (Config.configAppExt.hasOwnProperty(\"footer\")) {\r\n _configFooter.footer = Config.configAppExt[\"footer\"]\r\n }\r\n }\r\n return _configFooter\r\n },\r\n}\r\nwindow[\"HConfig\"] = Config\r\nexport default Config\r\n","import { HFormat, HIs, HCF, HColor, HUtils } from \"@macashipo/mlib\"\r\nimport HC from \"./c\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nimport moment from \"moment\"\r\nimport NumeralJs from \"src/libs/NumeralJs/numeral\"\r\n\r\nconst getValueOfFormat = (value: any, configFormat: any) => {\r\n if (configFormat && configFormat.fnList && configFormat.fnList.getValue) {\r\n return configFormat.fnList.getValue(configFormat)\r\n }\r\n return value\r\n}\r\n\r\nHFormat.Types[\"date\"] = {\r\n format: (value: any, configFormat: any) => {\r\n // console.warn(\"format date:\", value, configFormat)\r\n if (value != null && HIs.isDateValue(value)) {\r\n return moment(value).format(\r\n configFormat.format || HC.getDefaultFormatDate()\r\n )\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nHFormat.Types[\"fromnow\"] = {\r\n format: (value: any, configFormat: any) => {\r\n // console.warn(\"format date:\", value, configFormat)\r\n if (value != null && HIs.isDateValue(value)) {\r\n return moment(value).fromNow()\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nHFormat.Types[\"datetime\"] = {\r\n format: (value: any, configFormat: any) => {\r\n // console.warn(\"format date:\", value, configFormat)\r\n if (value != null && HIs.isDateValue(value)) {\r\n return moment(value).format(\r\n configFormat.format || HC.getDefaultFormatDateTime()\r\n )\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nHFormat.Types[\"numeral\"] = {\r\n format: (value: any, configFormat: any) => {\r\n let _format = configFormat.format || HCF.getCF(KConfigApp.numeralFormat)\r\n // console.warn(\"format numeral:\", value, configFormat, _format)\r\n return NumeralJs(value).format(_format)\r\n },\r\n}\r\n\r\nHFormat.Types[\"currency\"] = {\r\n format: (value: any, configFormat: any) => {\r\n let _num = Number(value)\r\n if (!isNaN(_num)) {\r\n let _configCurrencyLocaleOptions = HCF.getCF(\r\n KConfigApp.currencyLocaleOptions\r\n )\r\n let _s = _num.toLocaleString(HCF.getCF(KConfigApp.numberLocale), {\r\n style: \"decimal\",\r\n minimumFractionDigits: 2,\r\n maximumFractionDigits: 2,\r\n ..._configCurrencyLocaleOptions,\r\n })\r\n\r\n if (_configCurrencyLocaleOptions && _configCurrencyLocaleOptions.suffix) {\r\n return _s + _configCurrencyLocaleOptions.suffix\r\n } else if (\r\n _configCurrencyLocaleOptions &&\r\n _configCurrencyLocaleOptions.prefix\r\n ) {\r\n return _s + _configCurrencyLocaleOptions.prefix\r\n }\r\n return _s\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nHFormat.Types[\"decimal\"] = {\r\n format: (value: any, configFormat: any) => {\r\n let _num = Number(value)\r\n if (!isNaN(_num)) {\r\n let _s = _num.toLocaleString(HCF.getCF(KConfigApp.numberLocale), {\r\n style: \"decimal\",\r\n })\r\n return _s\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nHFormat.Types[\"number\"] = {\r\n format: (value: any, configFormat: any) => {\r\n let _num = Number(value)\r\n if (!isNaN(_num)) {\r\n return String(_num)\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nHFormat.Types[\"numColByWidth\"] = {\r\n format: (value: any, configFormat: any) => {\r\n // console.warn(\"format:\", value, configFormat)\r\n if (HIs.isNumber(value)) {\r\n return value\r\n } else if (HIs.isObject(value)) {\r\n let _objRes = value\r\n if (value.default) {\r\n _objRes = value.default\r\n }\r\n const windowWidth = (window && window.innerWidth) || Infinity\r\n let matchedBreakpoint = Infinity\r\n for (let k of Object.keys(value)) {\r\n const optBreakpoint = parseInt(k)\r\n const isCurrentBreakpoint =\r\n optBreakpoint > 0 && windowWidth <= optBreakpoint\r\n if (isCurrentBreakpoint && optBreakpoint < matchedBreakpoint) {\r\n matchedBreakpoint = optBreakpoint\r\n _objRes = value[k]\r\n }\r\n }\r\n if (HIs.isNumber(_objRes)) {\r\n return _objRes\r\n }\r\n }\r\n return configFormat.defaultValue || 5\r\n },\r\n}\r\n\r\n//copy from v1\r\nHFormat.Types[\"number_locale\"] = {\r\n format: (value, configFormat) => {\r\n let _num = Number(value)\r\n if (!isNaN(_num)) {\r\n let _numberLocale = HCF.getCF(KConfigApp.numberLocale)\r\n if (configFormat.numberLocale) {\r\n _numberLocale = configFormat.numberLocale\r\n }\r\n let _s = _num.toLocaleString(_numberLocale, {\r\n style: configFormat.style != null ? configFormat.style : \"decimal\",\r\n currency: configFormat.currency != null ? configFormat.currency : \"USD\",\r\n minimumFractionDigits:\r\n configFormat.minimumFractionDigits != null\r\n ? configFormat.minimumFractionDigits\r\n : 0,\r\n maximumFractionDigits:\r\n configFormat.maximumFractionDigits != null\r\n ? configFormat.maximumFractionDigits\r\n : 2,\r\n })\r\n return _s\r\n }\r\n return \"\"\r\n },\r\n}\r\nHFormat.Types[\"configByValue\"] = {\r\n format: (value, configFormat) => {\r\n let _configByValue = configFormat.configByValue\r\n if (_configByValue) {\r\n if (value != null && _configByValue[value]) {\r\n return _configByValue[value]\r\n } else if (value === null && _configByValue[\"_null\"]) {\r\n return _configByValue[\"_null\"]\r\n } else if ((value === \"\" || value === null) && _configByValue[\"_empty\"]) {\r\n return _configByValue[\"_empty\"]\r\n }\r\n }\r\n },\r\n}\r\nHFormat.Types[\"colorTextByBackground\"] = {\r\n format: (value, configFormat) => {\r\n let _colorForDark = configFormat.colorForDark || \"#ffffff\"\r\n let _colorForLight = configFormat.colorForLight || \"#000000\"\r\n if (configFormat && configFormat.fix && configFormat.fix[value]) {\r\n //tra ve theo danh sach\r\n return configFormat.fix[value]\r\n }\r\n let _lumina = HColor.getLumina(value)\r\n if (_lumina < 128) {\r\n return _colorForDark\r\n }\r\n return _colorForLight\r\n },\r\n}\r\nHFormat.Types[\"number_percent\"] = {\r\n format: (value, configFormat) => {\r\n let _num = Number(value)\r\n if (!isNaN(_num)) {\r\n //can nhan 100 cho TH: 0.5 => 50%\r\n if (configFormat.needMultip) {\r\n _num = _num * 100\r\n }\r\n //so le hien thi\r\n if (configFormat.numDecimal) {\r\n let _x = 10\r\n if (configFormat.numDecimal > 1 && configFormat.numDecimal <= 5) {\r\n _x = Math.pow(10, configFormat.numDecimal)\r\n }\r\n _num = Math.round(_num * _x) / _x\r\n }\r\n let _numberLocale = HCF.getCF(KConfigApp.numberLocale)\r\n if (configFormat.numberLocale) {\r\n _numberLocale = configFormat.numberLocale\r\n }\r\n let _s = _num.toLocaleString(_numberLocale, {\r\n style: \"decimal\",\r\n minimumFractionDigits:\r\n configFormat.minimumFractionDigits != null\r\n ? configFormat.minimumFractionDigits\r\n : 0,\r\n maximumFractionDigits:\r\n configFormat.maximumFractionDigits != null\r\n ? configFormat.maximumFractionDigits\r\n : 2,\r\n })\r\n let _suffix = \"%\"\r\n if (configFormat.suffix != null) {\r\n _suffix = configFormat.suffix\r\n }\r\n return `${_s}${_suffix}`\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nHFormat.Types[\"eval\"] = {\r\n format: (value: any, configFormat: any) => {\r\n console.warn(\"format eval:\", value, configFormat)\r\n if (configFormat.eval) {\r\n // eslint-disable-next-line\r\n var result = window.eval(configFormat.eval)\r\n return result || \"\"\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\n//Format compare\r\nHFormat.Types[\"hideCondition\"] = {\r\n format: (value: any, configFormat: any) => {\r\n let _configHideCondition = configFormat.configHideCondition || {}\r\n let _values = value || {}\r\n let _obj = _configHideCondition.obj\r\n let _opr = _configHideCondition.opr\r\n let _valueCompare = _configHideCondition.value\r\n if (_obj && typeof _obj == \"string\" && _obj.indexOf(\"[\") > -1) {\r\n _obj = HUtils.getTextWithData(_obj, _values)\r\n }\r\n if (\r\n _valueCompare &&\r\n typeof _valueCompare == \"string\" &&\r\n _valueCompare.indexOf(\"[\") > -1\r\n ) {\r\n _valueCompare = HUtils.getTextWithData(_valueCompare, _values)\r\n }\r\n console.log(\r\n \"hideCondition:\",\r\n _values,\r\n _configHideCondition,\r\n _obj,\r\n _opr,\r\n _valueCompare\r\n )\r\n let _isHide = false\r\n if (_opr) {\r\n let _config: any = {\r\n type: \"compare\",\r\n operator: _opr,\r\n valueCompare: _valueCompare,\r\n }\r\n _isHide = HFormat.format(_obj, _config)\r\n }\r\n return _isHide\r\n },\r\n}\r\nHFormat.Types[\"compare\"] = {\r\n format: (value: any, configFormat: any) => {\r\n let _value = getValueOfFormat(value, configFormat)\r\n let _operator = configFormat.operator\r\n let _valueCompare = configFormat.valueCompare\r\n console.log(\r\n \"format compare:\",\r\n `value: ${_value}`,\r\n `opr: ${_operator}`,\r\n `valueCompare: ${_valueCompare}`\r\n )\r\n if (_operator != null) {\r\n if (_valueCompare != null) {\r\n switch (_operator) {\r\n case \">\":\r\n return _value > _valueCompare\r\n case \">=\":\r\n return _value >= _valueCompare\r\n case \"==\":\r\n return _value == _valueCompare\r\n case \"!=\":\r\n return _value != _valueCompare\r\n case \"<=\":\r\n return _value <= _valueCompare\r\n case \"<\":\r\n return _value < _valueCompare\r\n default:\r\n // code block\r\n }\r\n }\r\n switch (_operator) {\r\n case \"null\":\r\n return _value == null\r\n case \"notnull\":\r\n return _value != null\r\n case \"empty\":\r\n return (\r\n _value == \"\" ||\r\n _value == 0 ||\r\n _value == null ||\r\n (_value != null && _value.length == 0)\r\n )\r\n case \"notempty\":\r\n return _value != \"\" && _value != 0 && _value != null\r\n case \"false\":\r\n return _value == false || _value == \"true\"\r\n case \"true\":\r\n return _value == true || _value == \"false\"\r\n default:\r\n // code block\r\n }\r\n }\r\n return false\r\n },\r\n}\r\n\r\n// compare or a ==\"2\" or a==\"3\"\r\n// configFormat = {type: \"compare_or\",list: [{type:\"compare\",\"operator\":\"==\",\"valueCompare\":\"2\"},{}]}\r\nHFormat.Types[\"compare_or\"] = {\r\n format: (value: any, configFormat: any) => {\r\n console.warn(\"format compare_or:\", value, configFormat)\r\n let _value = getValueOfFormat(value, configFormat)\r\n let _list = configFormat.list || []\r\n if (_list && _list.length > 0) {\r\n for (let _c of _list) {\r\n if (_c && _c.type) {\r\n let _r = HFormat.format(_value, {\r\n ..._c,\r\n fnList: { ...configFormat.fnList },\r\n })\r\n if (_r === true) {\r\n return true\r\n }\r\n }\r\n }\r\n }\r\n return false\r\n },\r\n}\r\nHFormat.Types[\"compare_and\"] = {\r\n format: (value: any, configFormat: any) => {\r\n console.warn(\"format compare_and:\", value, configFormat)\r\n let _value = getValueOfFormat(value, configFormat)\r\n let _list = configFormat.list || []\r\n if (_list && _list.length > 0) {\r\n for (let _c of _list) {\r\n if (_c && _c.type) {\r\n let _r = HFormat.format(_value, {\r\n ..._c,\r\n fnList: { ...configFormat.fnList },\r\n })\r\n if (_r === false) {\r\n return false\r\n }\r\n }\r\n }\r\n return true\r\n }\r\n return false\r\n },\r\n}\r\n\r\nHFormat.Types[\"fiesize\"] = {\r\n format: (value: any, configFormat: any) => {\r\n console.warn(\"format fiesize:\", value, configFormat)\r\n if (value != null) {\r\n let _decimals = configFormat.decimals || 2\r\n if (!+value) return \"0 Bytes\"\r\n const k = 1024\r\n const dm = _decimals < 0 ? 0 : _decimals\r\n const sizes = [\"Bytes\", \"KB\", \"MB\", \"GB\", \"TB\", \"PB\", \"EB\", \"ZB\", \"YB\"]\r\n const i = Math.floor(Math.log(value) / Math.log(k))\r\n return `${parseFloat((value / Math.pow(k, i)).toFixed(dm))} ${sizes[i]}`\r\n }\r\n return \"\"\r\n },\r\n}\r\n\r\nexport default HFormat\r\n","import { HIs, HLink } from \"@macashipo/mlib\"\r\nimport * as HJson from \"./json\"\r\nimport * as HUtils from \"./utils\"\r\nimport * as HLocalStorage from \"./localStorage\"\r\nimport * as HLog from \"./log\"\r\nimport * as HApi from \"./api\"\r\nimport * as HAuth from \"./auth\"\r\nimport * as HUI from \"./ui\"\r\nimport * as HRegex from \"./regex\"\r\n// import * as HLink from \"./link\"\r\nimport * as HQuery from \"./query\"\r\nimport * as HOptions from \"./options\"\r\nimport HConfig from \"./config\"\r\nimport HConstant from \"./constant\"\r\nimport HServiceWorker from \"./serviceWorker\"\r\nimport HFormat from \"./format\"\r\nimport HC from \"./c\"\r\nexport {\r\n HIs,\r\n HC,\r\n HLink,\r\n HJson,\r\n HUtils,\r\n HLocalStorage,\r\n HLog,\r\n HConfig,\r\n HApi,\r\n HAuth,\r\n HConstant,\r\n HUI,\r\n HRegex,\r\n HServiceWorker,\r\n HQuery,\r\n HOptions,\r\n HFormat,\r\n}\r\n\r\nHUtils.initMCore(\"HJson\", HJson)\r\nHUtils.initMCore(\"HUtils\", HUtils)\r\nHUtils.initMCore(\"HUI\", HUI)\r\n// HUtils.initMCore(\"HApi\", HApi)\r\n// HUtils.initMCore(\"HAuth\", HAuth)\r\n","export const SIDEMENU_UPDATE_TEXT_SEARCH =\r\n \"sidemenu/SIDEMENU_UPDATE_TEXT_SEARCH\"\r\n\r\nexport const SIDEMENU_UPDATE_MODE_SEARCH =\r\n \"sidemenu/SIDEMENU_UPDATE_MODE_SEARCH\"\r\n","import { HUtils } from \"@macashipo/mlib\"\r\nimport { fnGetConfigTable, fnListMyPage, KConfigPageTable } from \"./fnList\"\r\nimport {\r\n FlowAuth,\r\n FlowBuildColTableFromExtraData,\r\n FlowTableCell,\r\n FlowTableExpand,\r\n FlowTableFilter,\r\n FlowPage,\r\n FlowApi,\r\n FlowMNeedUpdateMLib,\r\n} from \"./Flow\"\r\n\r\nexport const Table_BuildCols = ({ fnList, onePage, extraData }) => {\r\n if (onePage) {\r\n let _configTable = fnListMyPage.fnGetConfigPageTable(fnList, [])\r\n return FlowBuildColTableFromExtraData({\r\n extraData: extraData || onePage._dataExtraData,\r\n fieldId:\r\n fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.fieldId,\r\n \"Id\",\r\n ]) || \"Id\",\r\n sourceList: onePage._dataOptions,\r\n fnList: fnList,\r\n showID: fnGetConfigTable(fnList, KConfigPageTable.showID),\r\n excludeFieldName: [],\r\n columnClassName: \"\",\r\n defaultFormatColumn: null,\r\n customProps: fnGetConfigTable(fnList, KConfigPageTable.customProps),\r\n customType: null,\r\n configTable: _configTable,\r\n })\r\n }\r\n return []\r\n}\r\n\r\n//Summary V3\r\n// const V3 = {\r\n// Table_BuildCols: Table_BuildCols,\r\n// }\r\n//Summary V5\r\nconst V5 = {\r\n Table_BuildCols: Table_BuildCols, //chua xu dung\r\n //TableExpand\r\n TableExpand_CheckExpandItem: FlowTableExpand.FlowCheckExpandItem,\r\n TableExpand_IsShowExpandItem: FlowTableExpand.FlowIsShowExpandItem,\r\n TableExpand_ToggleExpandItem: FlowTableExpand.FlowToggleExpandItem,\r\n //TableCell\r\n TableCell_KMore: FlowTableCell.KMore,\r\n TableCell_RenderTitleOfLink: FlowTableCell.FlowRenderTitleOfLink,\r\n TableCell_GetLinkTarget: FlowTableCell.FlowGetLinkTarget,\r\n TableCell_GetLink: FlowTableCell.FlowGetLink,\r\n TableCell_ClickLink: FlowTableCell.FlowActionClickLink,\r\n TableCell_GetTitleOfColumn: FlowTableCell.FlowGetTitleOfColumn,\r\n TableCell_RenderStatus: FlowTableCell.FlowRenderStatus,\r\n Cell_GetStyleCell: FlowTableCell.FlowGetStyleCell,\r\n Cell_GetHeaderTitle: FlowTableCell.FlowGetHeaderTitle,\r\n Cell_GetConfigModal: FlowTableCell.FlowGetConfigModal,\r\n //TableFilter\r\n TableFilter_IsShowFilter: FlowTableFilter.FlowIsShowFilter,\r\n TableFilter_IsShowSearch: FlowTableFilter.FlowIsShowSearch,\r\n //Page\r\n Page_GetSharedQueryOfPage: FlowPage.FlowGetSharedQueryOfPage,\r\n //Auth\r\n Auth_ParseAuthInfo: FlowAuth.FlowParseAuthInfo,\r\n //Api\r\n Api_Generic: FlowApi.FlowApiGeneric,\r\n Api_RefreshCache: FlowApi.FlowApiRefreshCache,\r\n //Need Update MLib\r\n M_addItemToArrayOrCreateNewArray:\r\n FlowMNeedUpdateMLib.addItemToArrayOrCreateNewArray,\r\n}\r\n\r\nexport default V5\r\n","import { useCallback, useState } from \"react\"\r\nexport default function useForceUpdate() {\r\n const [, setVF] = useState(Object.create(null))\r\n const memoizedDispatch = useCallback(() => {\r\n setVF(Object.create(null))\r\n }, [setVF])\r\n return memoizedDispatch\r\n}\r\n\r\n//Luu y co truong hop goi forceUpdate nay se bi loi reactjs\r\n","import { fnListMyPage } from \"src/helpers/fnList\"\r\nexport const FlowClientBuildOptions = ({\r\n buttonList,\r\n configHeader,\r\n configTable,\r\n moreSourceList,\r\n} = {}) => {\r\n let _screenConfig = {\r\n Header: { ...configHeader },\r\n Table: { ...configTable },\r\n }\r\n return {\r\n ButtonList: buttonList || [],\r\n ChartConfig: null,\r\n Configs: {\r\n ScreenConfig: JSON.stringify(_screenConfig),\r\n UITypeContents: {},\r\n },\r\n ...moreSourceList,\r\n }\r\n}\r\n\r\nexport const FlowClientClearLocalCache = (opts = {}) => {\r\n console.warn(\"clear local cache\")\r\n let _keys = Object.keys(localStorage)\r\n console.warn(\"clear local cache:\", _keys)\r\n for (let k of _keys) {\r\n if (k.indexOf(\"_ad-filter\") > -1) {\r\n localStorage.removeItem(k)\r\n }\r\n }\r\n if (opts.withoutReload !== true) {\r\n window.location.reload()\r\n }\r\n}\r\n","import { HCF } from \"@macashipo/mlib\"\r\nimport { KConfigPageFilter, fnListMyPage } from \"src/helpers/fnList\"\r\nimport { KConfigApp } from \"../K\"\r\nexport const KMore = {\r\n myui: \"myui\",\r\n isServer: \"isServer\",\r\n queryType: \"queryType\",\r\n isFrom: \"isFrom\", //for datefromto\r\n isTo: \"isTo\", //for datefromto\r\n showRanges: \"showRanges\", //for datefromto\r\n moreDateRangePicker: \"moreDateRangePicker\", //more props for date range picker\r\n multi: \"multi\", //multi or not, select2\r\n select2: \"select2\",\r\n placeholder: \"placeholder\",\r\n configPagination: \"configPagination\",\r\n virtualized: \"virtualized\",\r\n showSelectedOnFirstRow: \"showSelectedOnFirstRow\",\r\n fValue: \"fValue\",\r\n fText: \"fText\",\r\n configApi: \"configApi\",\r\n}\r\nexport const KMoreTableFilter = KMore\r\nexport const FlowIsShowFilter = onePage => {\r\n let _isShow = true\r\n if (onePage) {\r\n if (onePage._oneScreenConfig._filter.show === false) {\r\n _isShow = false\r\n }\r\n if (_isShow) {\r\n if (onePage._filterList && onePage._filterList.length == 0) {\r\n _isShow = false\r\n }\r\n }\r\n }\r\n // console.log(\"showFilter:\", _isShow, onePage)\r\n return _isShow\r\n}\r\n\r\nexport const FlowIsShowSearch = onePage => {\r\n let _isShow = true\r\n if (onePage) {\r\n if (onePage._oneScreenConfig._filter.showSearch === false) {\r\n _isShow = false\r\n }\r\n }\r\n // console.log(\"showSearch:\", _isShow, onePage)\r\n return _isShow\r\n}\r\n\r\nexport const FlowGetPlaceHolder = ({\r\n oneFilterControl,\r\n defaultValue,\r\n ...rest\r\n} = {}) => {\r\n const more = FlowGetMore({ oneFilterControl, ...rest })\r\n let _placeHolder = defaultValue || \"\"\r\n if (more[KMore.placeholder] != null) {\r\n _placeHolder = more[KMore.placeholder]\r\n }\r\n // console.log(\"placeholder:\", _placeHolder)\r\n return _placeHolder\r\n}\r\n\r\nexport const FlowGetMore = ({ oneFilterControl, ...rest } = {}) => {\r\n if (oneFilterControl && oneFilterControl.more) {\r\n return oneFilterControl.more\r\n }\r\n if (rest && rest.configOne && rest.configOne && rest.configOne.more) {\r\n return rest.configOne.more\r\n }\r\n return {}\r\n}\r\n\r\nexport const FlowGetOptionKey = ({ oneFilterControl, ...rest } = {}) => {\r\n if (oneFilterControl && oneFilterControl.optionKey) {\r\n return oneFilterControl.optionKey\r\n }\r\n if (rest && rest.configOne && rest.configOne && rest.configOne.optionKey) {\r\n return rest.configOne.optionKey\r\n }\r\n return \"\"\r\n}\r\n\r\nexport const FlowGetConfigOfMore = ({\r\n oneFilterControl,\r\n key,\r\n defaultValue,\r\n ...rest\r\n} = {}) => {\r\n let _defaultValue = defaultValue\r\n const more = FlowGetMore({ oneFilterControl, ...rest })\r\n console.warn(\"mtf more:\", more)\r\n if (more && more.hasOwnProperty(key)) {\r\n return more[key]\r\n }\r\n return _defaultValue\r\n}\r\n\r\nexport const FlowGetSourceData = ({\r\n oneFilterControl,\r\n fnList,\r\n ...rest\r\n} = {}) => {\r\n let _sourceList = fnListMyPage.getSourceList(fnList)\r\n let _optionKey = FlowGetOptionKey({ oneFilterControl, ...rest })\r\n console.warn(\"FlowGetSourceData:\", _sourceList, _optionKey, fnList)\r\n if (_sourceList && _optionKey) {\r\n return _sourceList[_optionKey] || []\r\n }\r\n return []\r\n}\r\n\r\nexport const FlowGetShowFilterAsPopover = ({ configFilter } = {}) => {\r\n let _rs = true\r\n let _rsInGlobalConfig = HCF.getCF(KConfigApp.dfShowFilterAsPopover)\r\n if (typeof _rsInGlobalConfig == \"boolean\") {\r\n _rs = _rsInGlobalConfig\r\n }\r\n if (\r\n configFilter &&\r\n configFilter.hasOwnProperty(KConfigPageFilter.showFilterAsPopover)\r\n ) {\r\n _rs = configFilter[KConfigPageFilter.showFilterAsPopover]\r\n }\r\n // console.warn(\"FlowGetShowFilterAsPopover:\", configFilter, _rs)\r\n return _rs\r\n}\r\n/**\r\n * onePage:\r\n * _filterList: list filter control arr: OneTableFilterControl\r\n * _oneFilters: filtes, arr: listFilter, get current filter,\r\n */\r\n","import { fnListMyPage } from \"src/helpers/fnList\"\r\nimport {\r\n HLink,\r\n HLocalStorage,\r\n MyUI,\r\n MyUIHelpers,\r\n CErrorBoundary,\r\n HUtils,\r\n} from \"@macashipo/mlib\"\r\nimport { KConfigPagePage, KOnePageMore } from \"../K\"\r\nimport { getUUID } from \"../U\"\r\nimport HI18, { loadExtLng } from \"src/core/helpers/i18n\"\r\n//share query for options, list, query api, form in header button, query all in cell, query all for detail table, query for child content page\r\nexport const FlowGetSharedQueryOfPage = (\r\n configPage,\r\n {\r\n onePage,\r\n match,\r\n defaultQuery,\r\n fnListOfParent,\r\n moreQuery,\r\n queryFilter,\r\n querySort,\r\n from,\r\n withoutQueryFilter,\r\n withoutQuerySort,\r\n } = {}\r\n) => {\r\n let _query = defaultQuery || {}\r\n // console.warn(\"query:\", _query)\r\n //from url neu co\r\n if (match && match.params) {\r\n _query = { ..._query, ...match.params }\r\n }\r\n //Bo sung QuerySearch\r\n if (window.location.search) {\r\n _query.QuerySearch = HLink.getAllParamOnUrl()\r\n }\r\n\r\n //ke thua tu parent\r\n if (fnListOfParent) {\r\n let _queryFromParent = fnListMyPage.fnGetSharedRequestData(fnListOfParent, [\r\n { from },\r\n ])\r\n if (_queryFromParent) {\r\n _query = { ..._query, ..._queryFromParent }\r\n }\r\n }\r\n //from configPage.RequestData\r\n if (configPage && configPage.RequestData) {\r\n _query = { ..._query, ...configPage.RequestData }\r\n }\r\n //from filter, sort neu co\r\n if (queryFilter && withoutQueryFilter !== true) {\r\n _query = { ..._query, ...queryFilter }\r\n }\r\n if (querySort && withoutQuerySort !== true) {\r\n _query = { ..._query, ...querySort }\r\n }\r\n\r\n //from configPage\r\n if (configPage && configPage.Id) {\r\n _query.ScreenGUID = configPage.Id\r\n }\r\n //from moreQuery\r\n if (moreQuery) {\r\n _query = { ..._query, ...moreQuery }\r\n }\r\n // console.warn(\"FlowGetSharedQueryOfPage:\", _query, from)\r\n return _query\r\n}\r\n\r\nexport const FlowGetMoreQueryFilterOfTable = () => {\r\n let _query = {}\r\n //export FilterQuery\r\n return _query\r\n}\r\n\r\nexport const FlowGetMoreQuerySortOfTable = () => {\r\n let _query = {}\r\n //export SortQuery\r\n return _query\r\n}\r\n\r\nexport const FlowGetConfigInLocalStorageOfPage = (configPage = {}) => {\r\n let _keyLocal = `${configPage.ScreenCode}-config`\r\n let _config = HLocalStorage.getObj(_keyLocal)\r\n return _config\r\n}\r\n\r\nexport const FlowUpdateConfigInLocalStorageOfPageWithKey = (\r\n configPage = {},\r\n key,\r\n value\r\n) => {\r\n let _keyLocal = `${configPage.ScreenCode}-config`\r\n let _config = HLocalStorage.getObj(_keyLocal) || {}\r\n if (key) {\r\n _config[key] = value\r\n HLocalStorage.saveObj(_keyLocal, _config)\r\n }\r\n}\r\n\r\nexport const FlowUpdateSizeOfPageFromLocal = onePage => {\r\n //check sizePerPage, get from local, 20 is default sizePerPage, chi lam voi phan trang client\r\n let _defaulPageSize = 20\r\n console.log(\"FlowUpdateSizeOfPageFromLocal\", onePage)\r\n if (onePage && onePage._configPagination._pageSize == _defaulPageSize) {\r\n let _configPageInLocal = FlowGetConfigInLocalStorageOfPage(\r\n onePage._configPage._configPageServer\r\n )\r\n if (\r\n _configPageInLocal &&\r\n _configPageInLocal.sizePerPage != null &&\r\n typeof _configPageInLocal.sizePerPage == \"number\" &&\r\n _configPageInLocal.sizePerPage != _defaulPageSize &&\r\n _configPageInLocal.sizePerPage > 0\r\n ) {\r\n onePage._configPagination._pageSize = _configPageInLocal.sizePerPage\r\n }\r\n }\r\n}\r\n\r\nexport const FlowParseOptions = (options, onePage) => {\r\n if (options) {\r\n let _UITypeContents = HUtils.get(options, \"Configs.UITypeContents\")\r\n if (_UITypeContents) {\r\n FlowParseUITypeContent(_UITypeContents)\r\n }\r\n let _configI18n = HUtils.get(onePage, \"_oneScreenConfig._page.i18n\")\r\n if (_configI18n) {\r\n let _screenCode = HUtils.get(\r\n onePage,\r\n \"_configPage._configPageServer.ScreenCode\"\r\n )\r\n if (_screenCode) {\r\n Object.keys(_configI18n).forEach((v, i) => {\r\n loadExtLng({\r\n lng: v,\r\n ns: _screenCode,\r\n resources: _configI18n[v],\r\n })\r\n })\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport const FlowParseUITypeContent = listObj => {\r\n if (listObj) {\r\n let _keys = Object.keys(listObj)\r\n for (let k of _keys) {\r\n if (MyUIHelpers.Types[k] == null) {\r\n MyUIHelpers.addTypes(k, props => {\r\n return (\r\n \r\n \r\n \r\n )\r\n })\r\n } else {\r\n console.warn(\"addListUI exist key:\", k)\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport const FlowInitPageId = onePage => {\r\n if (onePage) {\r\n if (onePage[KOnePageMore._pageUUID] == null) {\r\n onePage[KOnePageMore._pageUUID] = getUUID()\r\n }\r\n }\r\n}\r\n\r\nexport const FlowRenderUIWithConfig = (config = {}, fnList) => {\r\n // console.log(\"FlowRenderUIWithConfig:\", config)\r\n if (config && config.show) {\r\n let _type = config.type\r\n let _style = config.style || {}\r\n let _className = config.className\r\n let _morePropsFromExtraData = {}\r\n if (config.morePropsFromExtraData) {\r\n let _extraData = fnListMyPage.fnGetExtraDataTable(fnList)\r\n if (_extraData) {\r\n for (let k of Object.keys(config.morePropsFromExtraData)) {\r\n _morePropsFromExtraData[k] = _extraData[k]\r\n }\r\n }\r\n }\r\n if (_type) {\r\n return (\r\n \r\n )\r\n }\r\n }\r\n return null\r\n}\r\n\r\nexport const FlowRenderUIFromConfigPage = (key, fnList = {}) => {\r\n if (key) {\r\n let _config = fnListMyPage.fnGetConfigPagePage(fnList, [key])\r\n if (Array.isArray(_config)) {\r\n return (\r\n
\r\n {_config.map((v, i) => {\r\n return
{FlowRenderUIWithConfig(v, fnList)}
\r\n })}\r\n
\r\n )\r\n } else {\r\n return FlowRenderUIWithConfig(_config, fnList)\r\n }\r\n }\r\n}\r\n\r\nexport const FlowParseConfigInConfigPage = (\r\n configInConfigPage = {},\r\n df = {},\r\n opts = {}\r\n) => {\r\n let _config = { ...df, ...configInConfigPage }\r\n if (opts.isRootLevel) {\r\n if (_config.hideSideMenu) {\r\n window.document.body.classList.add(\"no-sidebar\")\r\n } else {\r\n window.document.body.classList.remove(\"no-sidebar\")\r\n }\r\n }\r\n}\r\n","import { HUtils } from \"src/core/helpers\"\r\n\r\nexport const K = {\r\n t_bottom_2fa_setup: \"t_bottom_2fa_setup\",\r\n t_bottom_2fa_verify: \"t_bottom_2fa_verify\",\r\n}\r\n\r\nconst Setting2FAHelpers = {\r\n Auth2FAEnabled: false,\r\n UniqueId: \"\",\r\n fnUpdateSetting2FAPart: null,\r\n FA2Methods: [],\r\n seletedMethod: null,\r\n t_bottom_2fa_setup: `
Please contact itsupport@ezyservicecentre.com if have any problem
`,\r\n t_bottom_2fa_verify: `
To view your pay slip please enter the 6-digit OTP. If you did not initiate this request please contact itsupport@ezyservicecentre.com.
`,\r\n}\r\n\r\nexport const updateSettingByResponse = res => {\r\n if (res && res.Data) {\r\n Setting2FAHelpers.Auth2FAEnabled = res.Data.Auth2FAEnabled\r\n Setting2FAHelpers.UniqueId = res.Data.UniqueId\r\n Setting2FAHelpers.FA2Methods = res.Data.FA2Methods\r\n }\r\n forceUpdateSetting2FAPart()\r\n}\r\nexport const updateSettingOneMethodByResponse = res => {\r\n if (res && res.Data && Setting2FAHelpers.FA2Methods) {\r\n for (let i = 0; i < Setting2FAHelpers.FA2Methods.length; i++) {\r\n let _method: any = Setting2FAHelpers.FA2Methods[i]\r\n if (res.Data.Id === _method.Id) {\r\n HUtils.mergeObjIfExist(_method, res.Data)\r\n }\r\n }\r\n }\r\n forceUpdateSetting2FAPart()\r\n}\r\nexport const updateFnUpdateSetting2FAPart = fnUpdate => {\r\n if (fnUpdate) {\r\n Setting2FAHelpers.fnUpdateSetting2FAPart = fnUpdate\r\n }\r\n}\r\nexport const getCurrentMethod = () => {\r\n return Setting2FAHelpers.seletedMethod\r\n}\r\n\r\nexport const getCurrentMethodId = () => {\r\n return HUtils.get(Setting2FAHelpers.seletedMethod, \"FA2MethodId\")\r\n}\r\n\r\nexport const getCurrentOtpRecipientRequired = () => {\r\n return HUtils.get(\r\n Setting2FAHelpers.seletedMethod,\r\n \"Configs.OtpRecipientRequired\"\r\n )\r\n}\r\nexport const getCurrentDisplayQRCode = () => {\r\n return HUtils.get(Setting2FAHelpers.seletedMethod, \"Configs.DisplayQRCode\")\r\n}\r\nexport const getCurrentOTPDescription = () => {\r\n return HUtils.get(Setting2FAHelpers.seletedMethod, \"Configs.OTPDescription\")\r\n}\r\nexport const getCurrentFA2MethodName = () => {\r\n return HUtils.get(Setting2FAHelpers.seletedMethod, \"FA2MethodName\")\r\n}\r\nexport const forceUpdateSetting2FAPart = () => {\r\n if (Setting2FAHelpers.fnUpdateSetting2FAPart) {\r\n HUtils.runFuntion(Setting2FAHelpers, \"fnUpdateSetting2FAPart\", [])\r\n }\r\n}\r\nexport default Setting2FAHelpers\r\n","import React from \"react\"\r\nimport styled from \"styled-components\"\r\nconst Wrap = styled.div`\r\n display: flex;\r\n align-items: center;\r\n flex-direction: row;\r\n flex-wrap: wrap;\r\n & > div {\r\n margin-right: 5px;\r\n cursor: pointer;\r\n font-weight: normal;\r\n padding: 0.25rem 0.75rem;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 3px;\r\n position: relative;\r\n color: #7c7c7c;\r\n margin-bottom: 5px;\r\n }\r\n & > div.active {\r\n border: 1px solid var(--blue-primary, #2d95ee);\r\n color: var(--blue-primary, #2d95ee);\r\n // font-weight: bold;\r\n }\r\n & > div .tick {\r\n width: 0.9375rem;\r\n height: 0.9375rem;\r\n position: absolute;\r\n overflow: hidden;\r\n right: 0;\r\n bottom: 0;\r\n }\r\n & > div .tick:before {\r\n border: 0.9375rem solid transparent;\r\n border-bottom: 0.9375rem solid var(--blue-primary, #2d95ee);\r\n content: \"\";\r\n position: absolute;\r\n right: -0.9375rem;\r\n bottom: 0;\r\n }\r\n & > div svg {\r\n position: absolute;\r\n right: 0;\r\n bottom: 0;\r\n color: #fff;\r\n font-size: 8px;\r\n overflow: hidden;\r\n display: inline-block;\r\n width: 1em;\r\n height: 1em;\r\n fill: currentColor;\r\n }\r\n`\r\n\r\nconst SvgTick = props => {\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n )\r\n}\r\nconst BaseControl = props => {\r\n const options =\r\n (props.fnList &&\r\n props.fnList.getSourceData &&\r\n props.fnList.getSourceData({ withEmpty: false })) ||\r\n []\r\n return (\r\n \r\n {options &&\r\n options.length > 0 &&\r\n options.map((v, i) => {\r\n return (\r\n {\r\n props.onChange &&\r\n props.onChange(props.value === v.Value ? null : v.Value)\r\n }}\r\n >\r\n {v.Text}\r\n {props.value === v.Value && (\r\n
\r\n \r\n
\r\n )}\r\n \r\n )\r\n })}\r\n
\r\n )\r\n}\r\n\r\nexport default BaseControl\r\n","export default __webpack_public_path__ + \"static/media/avatar.f1f7a488.jpg\";","import { fnListMyPage } from \"src/helpers/fnList\"\r\nimport { KMTC } from \"./More\"\r\nconst kfrConfigExpandByKey = \"_configExpandByKey\"\r\nconst kUI_DefaultShowExpand = \"UI_DefaultShowExpand\"\r\nconst FlowGetKeyOfExpandItem = configItemExpand => {\r\n if (configItemExpand) {\r\n return configItemExpand.key || configItemExpand.screenCode\r\n }\r\n}\r\n// const FlowIsConfigItemOneNotList = configItemExpand => {\r\n// if (\r\n// configItemExpand &&\r\n// configItemExpand.controller &&\r\n// configItemExpand.screenCode\r\n// ) {\r\n// return true\r\n// }\r\n// return false\r\n// }\r\nexport const FlowCheckExpandItem = ({\r\n configItemExpand,\r\n row,\r\n fnListOfMyTableCell,\r\n prefix = \"\",\r\n} = {}) => {\r\n let _onePage = fnListMyPage.fnGetOnePage(fnListOfMyTableCell)\r\n // console.log(\"_onePage:\", fnListOfMyTableCell, _onePage)\r\n let _configExpandOfRow = FlowConfigExpandOfRow({\r\n row,\r\n onePage: _onePage,\r\n fnListOfMyTableCell,\r\n })\r\n let _needUpdateConfigExpandOfRow = false\r\n if (row && configItemExpand) {\r\n let _firstCheck = false\r\n let _needForceUpdateDetail = false\r\n const item = configItemExpand\r\n let _keyOfExpand = FlowGetKeyOfExpandItem(configItemExpand)\r\n if (!_configExpandOfRow) {\r\n _configExpandOfRow = {}\r\n _needUpdateConfigExpandOfRow = true\r\n _firstCheck = true\r\n }\r\n if (_configExpandOfRow) {\r\n if (_keyOfExpand && !_configExpandOfRow[`${prefix}${_keyOfExpand}`]) {\r\n let _isShow = row[kUI_DefaultShowExpand] === true ? true : false\r\n if (_isShow === false && item[KMTC.defaultShowExpand] === true) {\r\n _isShow = true\r\n }\r\n _configExpandOfRow[`${prefix}${_keyOfExpand}`] = {\r\n ...item,\r\n _prefix: prefix,\r\n _isShow: _isShow,\r\n }\r\n if (_isShow) {\r\n _needForceUpdateDetail = true\r\n }\r\n } else if (item.list && item.list.length > 0) {\r\n for (let i = 0; i < item.list.length; i++) {\r\n let _itemInList = item.list[i]\r\n let _keyOfExpandInList = FlowGetKeyOfExpandItem(_itemInList)\r\n if (\r\n _keyOfExpandInList &&\r\n !_configExpandOfRow[`${prefix}${_keyOfExpandInList}`]\r\n ) {\r\n let _isShow = row[kUI_DefaultShowExpand] === true ? true : false\r\n if (\r\n _isShow === false &&\r\n _itemInList[KMTC.defaultShowExpand] === true\r\n ) {\r\n _isShow = true\r\n }\r\n _configExpandOfRow[`${prefix}${_keyOfExpandInList}`] = {\r\n ..._itemInList,\r\n _prefix: prefix,\r\n _isShow: _isShow,\r\n }\r\n if (_isShow) {\r\n _needForceUpdateDetail = true\r\n }\r\n }\r\n }\r\n }\r\n }\r\n if (_needUpdateConfigExpandOfRow) {\r\n if (_onePage && !_onePage[\"_configRowById\"]) {\r\n _onePage[\"_configRowById\"] = {}\r\n }\r\n if (\r\n row &&\r\n row.Id &&\r\n _onePage[\"_configRowById\"] &&\r\n !_onePage[\"_configRowById\"][row.Id]\r\n ) {\r\n _onePage[\"_configRowById\"][row.Id] = {}\r\n }\r\n if (_onePage[\"_configRowById\"][row.Id]) {\r\n _onePage[\"_configRowById\"][row.Id][kfrConfigExpandByKey] =\r\n _configExpandOfRow\r\n }\r\n row[kfrConfigExpandByKey] = _configExpandOfRow\r\n }\r\n if (\r\n _firstCheck &&\r\n _needForceUpdateDetail &&\r\n row &&\r\n row[\"_fnForceUpdateDetail\"]\r\n ) {\r\n console.warn(\"forceUpdate detail\")\r\n row[\"_fnForceUpdateDetail\"]()\r\n }\r\n }\r\n}\r\nexport const FlowGetAllExpandItemOfRow = ({ row, onePage } = {}) => {\r\n let _allExpand = []\r\n if (row) {\r\n if (row[kfrConfigExpandByKey]) {\r\n let _configExpand = row[kfrConfigExpandByKey]\r\n for (let k of Object.keys(_configExpand)) {\r\n _allExpand.push(_configExpand[k])\r\n }\r\n } else {\r\n if (\r\n row.Id &&\r\n onePage &&\r\n onePage[\"_configRowById\"] &&\r\n onePage[\"_configRowById\"][row.Id] &&\r\n onePage[\"_configRowById\"][row.Id][kfrConfigExpandByKey]\r\n ) {\r\n row[kfrConfigExpandByKey] =\r\n onePage[\"_configRowById\"][row.Id][kfrConfigExpandByKey]\r\n let _configExpand = row[kfrConfigExpandByKey]\r\n for (let k of Object.keys(_configExpand)) {\r\n _allExpand.push(_configExpand[k])\r\n }\r\n }\r\n }\r\n }\r\n // console.log(\"_allExpand:\", _allExpand)\r\n return _allExpand\r\n}\r\nexport const FlowConfigExpandOfRow = ({\r\n row,\r\n onePage,\r\n fnListOfMyTableCell,\r\n} = {}) => {\r\n let _configExpand = row[kfrConfigExpandByKey]\r\n let _onePage = onePage\r\n if (!_onePage && fnListOfMyTableCell) {\r\n _onePage = fnListMyPage.fnGetOnePage(fnListOfMyTableCell)\r\n }\r\n if (_configExpand == null) {\r\n if (\r\n row &&\r\n row.Id &&\r\n _onePage &&\r\n _onePage[\"_configRowById\"] &&\r\n _onePage[\"_configRowById\"][row.Id] &&\r\n _onePage[\"_configRowById\"][row.Id][kfrConfigExpandByKey]\r\n ) {\r\n row[kfrConfigExpandByKey] =\r\n _onePage[\"_configRowById\"][row.Id][kfrConfigExpandByKey]\r\n _configExpand = row[kfrConfigExpandByKey]\r\n }\r\n }\r\n return _configExpand\r\n}\r\nexport const FlowIsShowExpandItem = ({\r\n configItemExpand,\r\n row,\r\n fnListOfMyTableCell,\r\n prefix = \"\",\r\n} = {}) => {\r\n //init check first\r\n // console.log(\"FlowIsShowExpandItem\", fnListOfMyTableCell)\r\n FlowCheckExpandItem({ configItemExpand, row, fnListOfMyTableCell, prefix })\r\n let _configExpandOfRow = FlowConfigExpandOfRow({ row, fnListOfMyTableCell })\r\n // console.log(\"_configExpandOfRow:\", _configExpandOfRow)\r\n if (_configExpandOfRow && configItemExpand) {\r\n const item = configItemExpand\r\n if (_configExpandOfRow) {\r\n let _keyOfExpand = FlowGetKeyOfExpandItem(configItemExpand)\r\n if (_keyOfExpand && _configExpandOfRow[`${prefix}${_keyOfExpand}`]) {\r\n return _configExpandOfRow[`${prefix}${_keyOfExpand}`]._isShow === true\r\n ? true\r\n : false\r\n } else if (item.list && item.list.length > 0) {\r\n for (let i = 0; i < item.list.length; i++) {\r\n let _itemInList = item.list[i]\r\n let _keyOfExpandInList = FlowGetKeyOfExpandItem(_itemInList)\r\n if (\r\n _keyOfExpandInList &&\r\n _configExpandOfRow[`${prefix}${_keyOfExpandInList}`]\r\n ) {\r\n if (\r\n _configExpandOfRow[`${prefix}${_keyOfExpandInList}`]._isShow ===\r\n false\r\n ) {\r\n return false\r\n }\r\n }\r\n }\r\n return true\r\n }\r\n }\r\n }\r\n return false\r\n}\r\nexport const FlowToggleExpandItem = ({\r\n configItemExpand,\r\n row,\r\n fnListOfMyTableCell,\r\n prefix = \"\",\r\n forceUpdateCell,\r\n} = {}) => {\r\n let _configExpandOfRow = FlowConfigExpandOfRow({ row, fnListOfMyTableCell })\r\n if (row && configItemExpand) {\r\n const item = configItemExpand\r\n if (_configExpandOfRow) {\r\n let _keyOfExpand = FlowGetKeyOfExpandItem(configItemExpand)\r\n if (_keyOfExpand) {\r\n if (_configExpandOfRow[`${prefix}${_keyOfExpand}`]) {\r\n _configExpandOfRow[`${prefix}${_keyOfExpand}`]._isShow =\r\n _configExpandOfRow[`${prefix}${_keyOfExpand}`]._isShow === true\r\n ? false\r\n : true\r\n } else {\r\n console.warn(\"Missing config expand in row\", row)\r\n FlowCheckExpandItem({\r\n configItemExpand,\r\n row,\r\n fnListOfMyTableCell,\r\n prefix,\r\n })\r\n }\r\n }\r\n if (item.list && item.list.length > 0) {\r\n for (let i = 0; i < item.list.length; i++) {\r\n let _itemList = item.list[i]\r\n FlowToggleExpandItem({\r\n configItemExpand: _itemList,\r\n row,\r\n prefix,\r\n //an fnList di vi ko muon goi forceupdate ben trong\r\n // fnListOfMyTableCell,\r\n // forceUpdateCell,\r\n })\r\n }\r\n }\r\n if (forceUpdateCell) {\r\n forceUpdateCell()\r\n }\r\n console.warn(\"FlowToggleExpandItem:\", fnListOfMyTableCell)\r\n fnListMyPage.fnForceUpdateTable(fnListOfMyTableCell, []) //force update table tu fnListOfMyTableCell\r\n }\r\n }\r\n}\r\n","import { MyIcon } from \"@macashipo/mlib\"\r\n\r\nexport default MyIcon\r\n","import React from \"react\"\r\nimport { HUtils, HConstant } from \"./_helpers\"\r\nimport { MyUI } from \"@macashipo/mlib\"\r\nimport { evalInScope } from \"src/helpers/U\"\r\n\r\n/**\r\n *\r\n * t: type, tag: tagHTML, st: style, cn: className, p: more Props, ext: row, cell, btn,...\r\n * wb: wrap by MyUI,\r\n * ch_af: child array with field name\r\n * stf: style by, stfa: style field all // get style by field\r\n *\r\n * row: data, row, fnList\r\n * cell: data, fnList\r\n * btn: fnList\r\n *\r\n */\r\n\r\nclass MyUI_Object extends React.Component {\r\n renderArray = arr => {\r\n return (\r\n \r\n {arr.map((v, i) => {\r\n return (\r\n \r\n )\r\n })}\r\n \r\n )\r\n }\r\n renderString = str => {\r\n let _str = str\r\n if (_str && typeof _str == \"string\") {\r\n if (_str.startsWith(\"fn/\")) {\r\n let _arr = _str.split(\"/\")\r\n // console.warn(\"_arr:\",_arr,_str);\r\n return this.parseFunction(_arr)\r\n } else if (_str.startsWith(\"eval:\")) {\r\n // eslint-disable-next-line\r\n console.log(\"aaaaa:\", HUtils)\r\n // try {\r\n // let _v = eval(_str.slice(5, _str.length))\r\n // return _v\r\n // } catch (error) {\r\n // console.error(\"error eval:\", str)\r\n // }\r\n let _v = evalInScope(_str.slice(5, _str.length), {\r\n HUtils,\r\n })\r\n return _v || \"\"\r\n } else if (_str.indexOf(\"[\") > -1 && _str.indexOf(\"]\") > -1) {\r\n let _myData =\r\n HUtils.runFnList(this.getFnList(), HConstant.UIFnCore.myData, this, [\r\n \"\",\r\n ]) || {}\r\n _str = HUtils.SquareBracket.replace(_str, _myData, {\r\n emptyWhenNull: true,\r\n })\r\n // console.warn(\"myData\",_myData,_str);\r\n }\r\n }\r\n return _str\r\n }\r\n renderChildren = (ch, obj = {}) => {\r\n const { ch_af } = obj\r\n if (ch_af) {\r\n let _arr = this.parseFunction([\"fn\", \"myData\", [ch_af]])\r\n console.warn(\"_arr:\", _arr)\r\n if (Array.isArray(_arr)) {\r\n return (\r\n \r\n {_arr.map((v, i) => {\r\n return (\r\n \r\n )\r\n })}\r\n \r\n )\r\n } else {\r\n return
\r\n }\r\n } else if (typeof ch == \"string\") {\r\n return this.renderString(ch)\r\n } else if (Array.isArray(ch) && ch.length > 0) {\r\n return this.renderArray(ch)\r\n } else if (typeof ch == \"object\") {\r\n return \r\n }\r\n }\r\n parseFunction = arr => {\r\n const fnList = this.getFnList()\r\n // console.warn(\"parse Function\",arr,fnList);\r\n if (arr && arr.length > 2 && fnList) {\r\n let _fnName = arr[1]\r\n let _arg3 = arr[2]\r\n if (_arg3 == null) {\r\n // console.warn(\"_arg3 = null\");\r\n _arg3 = []\r\n } else if (Array.isArray(_arg3) == false) {\r\n // console.warn(\"_arg2 not array:\",_arg3);\r\n if (_arg3.startsWith(\"[\") && _arg3.endsWith(\"]\")) {\r\n try {\r\n _arg3 = _arg3.replace(/\\'/g, `\"`)\r\n let _newArg3 = JSON.parse(_arg3)\r\n // console.warn(\"_newArg3:\",_newArg3);\r\n // let _newArg3 = _arg3.replace(/\\[/g,'').replace(/\\]/g,'').split(',');\r\n for (let i = 0; i < _newArg3.length; i++) {\r\n let _item = _newArg3[i]\r\n if (_item && typeof _item == \"object\" && _item.fn != null) {\r\n _newArg3[i] = this.parseFunction([\"fn\", _item.fn, _item.args])\r\n // console.warn(\"_newArg3 i:\",i,_newArg3[i]);\r\n }\r\n }\r\n // console.warn(\"_newArg3:\",_newArg3);\r\n _arg3 = _newArg3\r\n } catch (error) {\r\n console.warn(\"error parse json:\", _arg3, error)\r\n // _arg3 = [arr[2]];\r\n }\r\n } else {\r\n _arg3 = [arr[2]]\r\n }\r\n }\r\n // console.warn(\"runFnList 1\",_fnName,_arg3,_value);\r\n if (Array.isArray(_arg3) == false) {\r\n //dam bao _arg3 la 1 array\r\n _arg3 = [_arg3]\r\n }\r\n let _value = HUtils.runFnList(fnList, _fnName, this, _arg3)\r\n // console.warn(\"runFnList\",_fnName,_arg3,_value);\r\n return _value\r\n }\r\n }\r\n parseMoreProp = p => {\r\n let _moreProps = p\r\n let _more = {}\r\n if (_moreProps) {\r\n let _keys = Object.keys(_moreProps)\r\n for (let k of _keys) {\r\n let _v = _moreProps[k]\r\n if (typeof _v == \"string\" && [\"onB\", \"onCl\", \"onC\"].indexOf(k) == -1) {\r\n _more[k] = this.renderString(_v)\r\n } else if (k === \"m\") {\r\n //khi thay doi ko lam thay doi m cua config chung\r\n _more[\"m\"] = { ..._moreProps[k] }\r\n } else {\r\n _more[k] = _moreProps[k]\r\n }\r\n }\r\n if (_more.hasOwnProperty(HConstant.UIOnClick.key)) {\r\n _more.m = {\r\n ..._more.m,\r\n onClick: () => {\r\n console.warn(\"Click\", p, this.props)\r\n let _onCl = HUtils.Obj.get(p, HConstant.UIOnClick.key)\r\n this.renderString(_onCl)\r\n },\r\n }\r\n // console.warn(\"add onCLick:\",_more);\r\n }\r\n }\r\n if (_more.m && Object.keys(_more.m).length > 0) {\r\n for (let k of Object.keys(_more.m)) {\r\n _more.m[k] = this.renderString(_more.m[k])\r\n }\r\n }\r\n return _more\r\n }\r\n getFnList = () => {\r\n const { fnList, data } = this.props\r\n if (this._fnList) {\r\n return this._fnList\r\n }\r\n let _myFnList = {\r\n myChange: (fieldName, v, opts) => {\r\n // console.warn(\"myChange:\",fieldName,v,this.props,opts);\r\n let _onC = HUtils.Obj.get(opts, HConstant.UIOnChange.key)\r\n if (_onC == HConstant.UIOnChange.updateField) {\r\n HUtils.runFnList(fnList, HConstant.UIFnPage.fnRequestUpdate, this, [\r\n data,\r\n fieldName,\r\n v,\r\n {\r\n // cbOK: ()=>{\r\n // console.warn(\"OK\");\r\n // }\r\n },\r\n ])\r\n }\r\n },\r\n myBlur: (fieldName, v, opts) => {\r\n // console.warn(\"myBlur:\",fieldName,v,this.props,opts);\r\n let _onB = HUtils.Obj.get(opts, HConstant.UIOnBlur.key)\r\n if (_onB == HConstant.UIOnBlur.updateField) {\r\n HUtils.runFnList(fnList, HConstant.UIFnPage.fnRequestUpdate, this, [\r\n data,\r\n fieldName,\r\n v,\r\n {\r\n // cbOK: ()=>{\r\n // console.warn(\"OK\");\r\n // }\r\n },\r\n ])\r\n }\r\n },\r\n }\r\n if (data) {\r\n _myFnList.myData = key => {\r\n return HUtils.Obj.get(this.props.data, key || \"\") //truong hop key = null se bi loi-> truyen chuoi rong\r\n }\r\n }\r\n this._fnList = {\r\n ...fnList,\r\n ..._myFnList, //uu tien fnList hien tai, overide lai cac fnList truoc do\r\n }\r\n return this._fnList\r\n }\r\n parseStyle = obj => {\r\n let _style = obj.st\r\n if (obj.stf) {\r\n let _styleField = {}\r\n let _keys = Object.keys(obj.stf)\r\n for (let k of _keys) {\r\n _styleField[k] = this.renderString(obj.stf[k])\r\n }\r\n // console.warn(\"parseStyle:\",_styleField,obj.stf);\r\n _style = Object.assign({}, _style, _styleField)\r\n }\r\n if (obj.stfa) {\r\n let _styleAllField = this.renderString(obj.stfa)\r\n _style = Object.assign({}, _style, _styleAllField)\r\n }\r\n return _style\r\n }\r\n render() {\r\n const { configObj, isWrap } = this.props\r\n // console.warn(\"render o:\",this.props);\r\n if (configObj && typeof configObj == \"object\" && configObj.t) {\r\n let _obj = configObj\r\n let _type = configObj.t\r\n let _wrapBy = configObj.wb\r\n if (_wrapBy && typeof _wrapBy == \"object\" && isWrap !== true) {\r\n _wrapBy.ch = Object.assign({}, configObj)\r\n delete _wrapBy.ch.wb\r\n return (\r\n \r\n )\r\n }\r\n let _moreProps = this.parseMoreProp(_obj.p)\r\n let _style = this.parseStyle(_obj)\r\n return (\r\n \r\n {_obj.ch != null && this.renderChildren(_obj.ch, _obj)}\r\n \r\n )\r\n } else if (Array.isArray(configObj)) {\r\n return this.renderArray(configObj)\r\n } else if (typeof configObj == \"string\") {\r\n let _value = this.renderString(configObj)\r\n if (_value) {\r\n return this.renderString(_value)\r\n } else {\r\n return \"\"\r\n }\r\n }\r\n console.warn(\"MyUI o missing type:\", configObj)\r\n return
\r\n }\r\n}\r\n\r\nexport default MyUI_Object\r\n","import React from \"react\"\r\nclass MyUI_Tag extends React.Component {\r\n render() {\r\n const { style, className, children, m } = this.props\r\n const Tag = this.props.tag || \"div\"\r\n if (Tag) {\r\n return (\r\n \r\n {children}\r\n \r\n )\r\n }\r\n console.warn(\"Missing tag:\", this.prop)\r\n return
\r\n }\r\n}\r\n\r\nexport default MyUI_Tag\r\n","import React from \"react\"\r\nimport { MyUI } from \"@macashipo/mlib\"\r\nimport classnames from \"classnames\"\r\nclass MyUI_TagCard extends React.Component {\r\n render() {\r\n const { style, className, children, h, f, hSt, fSt, hCn, fCn, fnList } =\r\n this.props\r\n return (\r\n
\r\n {h != null && (\r\n
\r\n \r\n
\r\n )}\r\n
{children}
\r\n {f != null && (\r\n
\r\n \r\n
\r\n )}\r\n
\r\n )\r\n }\r\n}\r\n\r\nexport default MyUI_TagCard\r\n","import React from \"react\"\r\nimport { MyUI } from \"@macashipo/mlib\"\r\n\r\n/**\r\n *\r\n * td: array\r\n * th: array\r\n * tr: fields get data\r\n *\r\n */\r\nclass MyUI_TagTable extends React.Component {\r\n renderTH = () => {\r\n const { th, thSt, thStR } = this.props\r\n if (th && Array.isArray(th)) {\r\n return (\r\n \r\n {th.map((v, i) => {\r\n let _style\r\n if (thSt && thSt[i] != null) {\r\n _style = thSt[i]\r\n }\r\n return (\r\n \r\n {v}\r\n \r\n )\r\n })}\r\n \r\n )\r\n }\r\n }\r\n renderTD = ({ data } = {}) => {\r\n const { td, tdSt } = this.props\r\n if (td && Array.isArray(td)) {\r\n return td.map((v, i) => {\r\n let _style\r\n if (tdSt && tdSt[i] != null) {\r\n _style = tdSt[i]\r\n }\r\n return (\r\n \r\n {this.renderCell({ v, data })}\r\n \r\n )\r\n })\r\n }\r\n }\r\n renderCell = ({ v, data }) => {\r\n const { fnList } = this.props\r\n if (v) {\r\n return \r\n }\r\n }\r\n renderTR = () => {\r\n const { tr, trSt, fRB, fnList } = this.props\r\n if (tr && Array.isArray(tr)) {\r\n return tr.map((v, i) => {\r\n let _style\r\n if (trSt && trSt[i] != null) {\r\n _style = trSt[i]\r\n }\r\n return (\r\n \r\n {fRB != null && (\r\n \r\n \r\n \r\n \r\n \r\n )}\r\n \r\n {this.renderTD({ data: v })}\r\n \r\n \r\n )\r\n })\r\n }\r\n }\r\n render() {\r\n const { style, className, fnList, th, tr } = this.props\r\n return (\r\n \r\n {th != null && this.renderTH()}\r\n {tr != null && this.renderTR()}\r\n
\r\n )\r\n }\r\n}\r\n\r\nexport default MyUI_TagTable\r\n","import React from \"react\"\r\nimport { MyUI } from \"@macashipo/mlib\"\r\nimport { Tooltip as CTooltip, Popover as cPopover } from \"./_helpers\"\r\nclass MyUI_Tooltip extends React.Component {\r\n renderOverlay = () => {\r\n const { ov, fnList } = this.props\r\n if (ov) {\r\n return \r\n } else {\r\n return
\r\n }\r\n }\r\n render() {\r\n const { style, className, children, pl, tg } = this.props\r\n // console.warn(\"MyUI_Tooltip:\",this.props);\r\n return (\r\n \r\n
{children}
\r\n \r\n )\r\n }\r\n}\r\n\r\nexport default MyUI_Tooltip\r\n","import React from \"react\"\r\nimport PropTypes from \"prop-types\"\r\n\r\nclass MyUI_ExtControl extends React.Component {\r\n static getDerivedStateFromProps(props, state) {\r\n if (props.debug) {\r\n console.warn(\"getDerivedStateFromProps\", props, state)\r\n }\r\n if (props.hasOwnProperty(\"v\")) {\r\n if (props.v !== state.value) {\r\n return {\r\n value: props.v != null ? props.v : props.dfe,\r\n }\r\n }\r\n } else {\r\n if (props.df !== state.defaultValue) {\r\n //bo sung props.defaultValue !== state.value vi truong hop truyen vao giong default truoc, nhung khac value thi no ko update\r\n //nhung ma defaultValue luon luon khac state.value => luon update value lai = defaultValue => ko xai duoc => phai xai value\r\n return {\r\n defaultValue: props.df,\r\n value: props.df != null ? props.df : props.dfe,\r\n }\r\n }\r\n }\r\n return null\r\n }\r\n constructor(props) {\r\n super(props)\r\n this.initState()\r\n }\r\n initState = () => {\r\n if (this.props.debug) {\r\n console.warn(\"initState:\", this.props, this)\r\n }\r\n this._controlled = false //ko control boi value ben ngoai truyen vao\r\n if (this.props.hasOwnProperty(\"v\") && this.props.hasOwnProperty(\"df\")) {\r\n console.warn(\"Only value using. value and defaultValue cannot using both\")\r\n this._controlled = true\r\n } else if (this.props.hasOwnProperty(\"v\")) {\r\n this._controlled = true\r\n }\r\n // eslint-disable-next-line\r\n this.state = {\r\n value:\r\n this.props.df != null ? this.props.df : this.getDefaultValueWhenEmpty(),\r\n defaultValue: this.props.df,\r\n }\r\n }\r\n getDefaultValueWhenEmpty = () => {\r\n const { dfe } = this.props\r\n return dfe || \"\"\r\n }\r\n getDelimiter = () => {\r\n return this.props.delimiter\r\n }\r\n getValue = () => {\r\n return this.state.value\r\n }\r\n getValueInOptionItem = item => {\r\n return item.Value || item.value\r\n }\r\n getTextInOptionItem = item => {\r\n return item.Text || item.label || item.text\r\n }\r\n onChange = (value, opts) => {\r\n const { onChange, typeDataOnChange } = this.props\r\n if (this._controlled == true) {\r\n if (onChange) {\r\n onChange(value, opts)\r\n }\r\n } else {\r\n this.setState(\r\n {\r\n value: value,\r\n },\r\n () => {\r\n // console.warn(\"onChange:\",this.state.value,\"<=>\",value)\r\n let _valueOnChange = value\r\n if (\r\n typeDataOnChange != null &&\r\n opts &&\r\n opts.typeData &&\r\n opts.typeData[typeDataOnChange] != null\r\n ) {\r\n _valueOnChange = opts.typeData[typeDataOnChange]\r\n }\r\n if (onChange) {\r\n onChange(_valueOnChange, opts)\r\n }\r\n }\r\n )\r\n }\r\n }\r\n}\r\nexport default MyUI_ExtControl\r\n","import React from \"react\"\r\nimport classnames from \"classnames\"\r\nimport PropTypes from \"prop-types\"\r\nimport { HUtils, HConstant } from \"./_helpers\"\r\nimport MyUI_InputExt from \"./t_input_ext\"\r\nclass MyUI_InputCheck extends MyUI_InputExt {\r\n _onChange = ev => {\r\n const { fnList, f } = this.props\r\n let _v = ev.currentTarget.checked\r\n this.setState(\r\n {\r\n value: _v,\r\n },\r\n () => {\r\n HUtils.runFnList(fnList, HConstant.UIFnCore.myChange, this, [\r\n f,\r\n _v,\r\n { ...this.props },\r\n ])\r\n }\r\n )\r\n }\r\n parseMore = () => {\r\n let _more = {}\r\n return _more\r\n }\r\n render() {\r\n let {\r\n className,\r\n //\r\n innerRef,\r\n valid,\r\n invalid,\r\n custom,\r\n disabled,\r\n m,\r\n ...attributes\r\n } = this.props\r\n\r\n // render\r\n const classes = classnames(\r\n custom ? \"custom-control-input\" : \"form-check-input\",\r\n invalid && \"is-invalid\",\r\n valid && \"is-valid\",\r\n className\r\n )\r\n\r\n return (\r\n \r\n )\r\n }\r\n}\r\nMyUI_InputCheck.propTypes = {\r\n m: PropTypes.any, //more props\r\n f: PropTypes.string, //field Name\r\n dfe: PropTypes.bool, //default empty\r\n df: PropTypes.bool, //default value\r\n v: PropTypes.bool, // value\r\n}\r\nMyUI_InputCheck.defaultProps = {\r\n dfe: false,\r\n}\r\nexport default MyUI_InputCheck\r\n","import React from \"react\"\r\nimport classnames from \"classnames\"\r\nimport PropTypes from \"prop-types\"\r\nimport { HUtils, HConstant } from \"./_helpers\"\r\nimport MyUI_InputExt from \"./t_input_ext\"\r\nclass MyUI_InputText extends MyUI_InputExt {\r\n _onChange = ev => {\r\n const { fnList, f } = this.props\r\n let _v = ev.currentTarget.value\r\n this.setState(\r\n {\r\n value: _v,\r\n },\r\n () => {\r\n HUtils.runFnList(fnList, HConstant.UIFnCore.myChange, this, [\r\n f,\r\n _v,\r\n { ...this.props },\r\n ])\r\n }\r\n )\r\n }\r\n _onBlur = ev => {\r\n const { fnList, f } = this.props\r\n let _v = ev.currentTarget.value\r\n this.setState(\r\n {\r\n value: _v,\r\n },\r\n () => {\r\n HUtils.runFnList(fnList, HConstant.UIFnCore.myBlur, this, [\r\n f,\r\n _v,\r\n { ...this.props },\r\n ])\r\n }\r\n )\r\n }\r\n parseMore = () => {\r\n let _more = {}\r\n return _more\r\n }\r\n render() {\r\n let {\r\n className,\r\n //\r\n innerRef,\r\n valid,\r\n invalid,\r\n custom,\r\n disabled,\r\n plaintext,\r\n size,\r\n m,\r\n ...attributes\r\n } = this.props\r\n\r\n // render\r\n const classes = classnames(\r\n plaintext ? \"form-control-plaintext\" : \"form-control\",\r\n size && `form-control-${size}`,\r\n invalid && \"is-invalid\",\r\n valid && \"is-valid\",\r\n className\r\n )\r\n\r\n return (\r\n \r\n )\r\n }\r\n}\r\nMyUI_InputText.propTypes = {\r\n m: PropTypes.any, //more props\r\n f: PropTypes.string, //field Name\r\n dfe: PropTypes.string, //default empty\r\n df: PropTypes.string, //default value\r\n v: PropTypes.string, // value\r\n}\r\nMyUI_InputText.defaultProps = {\r\n dfe: \"\",\r\n}\r\nexport default MyUI_InputText\r\n","import React from \"react\"\r\nclass MyUI_TagImg extends React.Component {\r\n render() {\r\n const { style, className, src, w, h, m, alt } = this.props\r\n const Tag = this.props.tag || \"img\"\r\n let _obj = {}\r\n if (w) {\r\n _obj.width = w\r\n }\r\n if (h) {\r\n _obj.height = h\r\n }\r\n if (alt) {\r\n _obj.alt = alt\r\n }\r\n let _src = src\r\n if (m && m.src) {\r\n _src = m.src\r\n }\r\n if (Tag && _src) {\r\n return \r\n }\r\n console.warn(\"Missing tag or src:\", this.prop, _src)\r\n return
\r\n }\r\n}\r\n\r\nexport default MyUI_TagImg\r\n","import React from \"react\"\r\nimport { HUtils } from \"./_helpers\"\r\nclass MyUI_HTML extends React.Component {\r\n render() {\r\n const { html, className, style, data, onClick, fnList } = this.props\r\n let _data = data\r\n if (_data == null && fnList && fnList.myData) {\r\n _data = fnList.myData()\r\n console.warn(\"_data:\", _data)\r\n }\r\n // console.warn(\"MyUI_HTML:\",this.props);\r\n if (_data && html && typeof _data == \"object\") {\r\n let _html = HUtils.SquareBracket.replace(html, _data)\r\n return (\r\n \r\n )\r\n } else if (html) {\r\n return (\r\n \r\n )\r\n }\r\n return
\r\n }\r\n}\r\n\r\nexport default MyUI_HTML\r\n","import { MyUI, MyUIHelpers } from \"@macashipo/mlib\"\r\n\r\nimport O from \"./UIContentsTypes/o\"\r\nimport T from \"./UIContentsTypes/t\"\r\nimport TCard from \"./UIContentsTypes/t_card\"\r\nimport TTable from \"./UIContentsTypes/t_table\"\r\nimport TTooltip from \"./UIContentsTypes/t_tooltip\"\r\nimport TInputCheck from \"./UIContentsTypes/t_input_check\"\r\nimport TInputText from \"./UIContentsTypes/t_input_text\"\r\nimport TImg from \"./UIContentsTypes/t_img\"\r\nimport THtml from \"./UIContentsTypes/t_html\"\r\n\r\nconst ListNotLazy = {\r\n o: O,\r\n t: T,\r\n t_div: T,\r\n t_card: TCard,\r\n t_table: TTable,\r\n t_tooltip: TTooltip,\r\n t_input_check: TInputCheck,\r\n t_input_text: TInputText,\r\n t_img: TImg,\r\n t_html: THtml,\r\n}\r\n\r\nMyUIHelpers.addTypesFromListWithoutLazy(ListNotLazy)\r\nexport default MyUI\r\n","import _extends from \"@babel/runtime/helpers/esm/extends\"\r\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\"\r\nimport React from \"react\"\r\nimport PropTypes from \"prop-types\"\r\nimport classNames from \"classnames\"\r\nimport { mapToCssModules, tagPropType } from \"reactstrap/src/utils\"\r\nvar propTypes = {\r\n color: PropTypes.string,\r\n pill: PropTypes.bool,\r\n tag: tagPropType,\r\n innerRef: PropTypes.oneOfType([\r\n PropTypes.object,\r\n PropTypes.func,\r\n PropTypes.string,\r\n ]),\r\n children: PropTypes.node,\r\n className: PropTypes.string,\r\n cssModule: PropTypes.object,\r\n style: PropTypes.object,\r\n}\r\nvar defaultProps = {\r\n color: \"secondary\",\r\n pill: false,\r\n tag: \"span\",\r\n}\r\n\r\nvar Badge = function Badge(props) {\r\n var className = props.className,\r\n cssModule = props.cssModule,\r\n color = props.color,\r\n innerRef = props.innerRef,\r\n pill = props.pill,\r\n Tag = props.tag,\r\n attributes = _objectWithoutPropertiesLoose(props, [\r\n \"className\",\r\n \"cssModule\",\r\n \"color\",\r\n \"innerRef\",\r\n \"pill\",\r\n \"tag\",\r\n ])\r\n\r\n var classes = mapToCssModules(\r\n classNames(\r\n className,\r\n \"badge\",\r\n \"bg-\" + color,\r\n pill ? \"rounded-pill\" : false\r\n ),\r\n cssModule\r\n )\r\n\r\n if (attributes.href && Tag === \"span\") {\r\n Tag = \"a\"\r\n }\r\n\r\n return /*#__PURE__*/ React.createElement(\r\n Tag,\r\n _extends({}, attributes, {\r\n className: classes,\r\n style: props.style,\r\n ref: innerRef,\r\n })\r\n )\r\n}\r\n\r\nBadge.propTypes = propTypes\r\nBadge.defaultProps = defaultProps\r\nexport default Badge\r\n","import { Alert } from \"reactstrap\"\r\nexport default Alert\r\n","import { MyLoading } from \"@macashipo/mlib\"\r\nexport default MyLoading\r\n","import MyModal from \"./MyModal\"\r\nconst MyDialog = {\r\n show({ title = \"\", msg = \"\", onClickOK = (cModal: any) => {} } = {}) {\r\n MyModal.showMyDialogWithConfigModal({\r\n title: title,\r\n component: msg,\r\n modalCentered: true,\r\n size: \"md\",\r\n showFooter: true,\r\n showFooterOK: true,\r\n backdrop: \"static\",\r\n onClickOK: cModal => {\r\n if (onClickOK) {\r\n onClickOK(cModal)\r\n }\r\n if (cModal.hide) {\r\n cModal.hide()\r\n }\r\n },\r\n })\r\n },\r\n showConfirm({ title = \"\", msg = \"\", onClickOK = (cModal: any) => {} } = {}) {\r\n MyModal.showMyDialogWithConfigModal({\r\n title: title,\r\n component: msg,\r\n modalCentered: true,\r\n size: \"md\",\r\n showFooter: true,\r\n showFooterOK: true,\r\n showFooterClose: true,\r\n backdrop: \"static\",\r\n onClickOK: cModal => {\r\n if (onClickOK) {\r\n onClickOK(cModal)\r\n }\r\n if (cModal.hide) {\r\n cModal.hide()\r\n }\r\n },\r\n })\r\n },\r\n}\r\n\r\nexport default MyDialog\r\n","import React from \"react\"\r\nimport { Button, Popover, PopoverHeader, PopoverBody } from \"reactstrap\"\r\n\r\nfunction PopoverBoostrap(props) {\r\n const [open, setOpen] = React.useState(false)\r\n const { targetId, overlay, styleWrap } = props\r\n const toggle = () => {\r\n setOpen(!open)\r\n }\r\n return (\r\n
\r\n {props.children ? (\r\n
\r\n {props.children}\r\n
\r\n ) : (\r\n \r\n )}\r\n \r\n {props.title && {props.title}}\r\n \r\n {typeof overlay == \"function\"\r\n ? overlay({\r\n hidePopover: () => {\r\n setOpen(false)\r\n },\r\n })\r\n : overlay}\r\n \r\n \r\n
\r\n )\r\n}\r\n\r\nexport default PopoverBoostrap\r\n","/*eslint-disable @typescript-eslint/no-unused-vars */\r\nimport { useState } from \"react\"\r\n\r\nfunction useForceUpdate() {\r\n const [valueFU, setValueFU] = useState(0) // integer state\r\n return () => setValueFU(valueFU => valueFU + 1) // update the state to force render\r\n}\r\n\r\nexport default useForceUpdate\r\n","export default __webpack_public_path__ + \"static/media/city1.fadfec7c.jpg\";","import sideBar6 from \"../assets/images/sidebar/city1.jpg\"\r\nimport { HLocalStorage } from \"@macashipo/mlib\"\r\n\r\nconst kEnableClosedSidebar = \"EnableClosedSidebar\"\r\nconst lastEnableClosedSidebar = HLocalStorage.getString(kEnableClosedSidebar)\r\n\r\nexport const SET_ENABLE_BACKGROUND_IMAGE =\r\n \"THEME_OPTIONS/SET_ENABLE_BACKGROUND_IMAGE\"\r\n\r\nexport const SET_ENABLE_MOBILE_MENU = \"THEME_OPTIONS/SET_ENABLE_MOBILE_MENU\"\r\nexport const SET_ENABLE_MOBILE_MENU_SMALL =\r\n \"THEME_OPTIONS/SET_ENABLE_MOBILE_MENU_SMALL\"\r\n\r\nexport const SET_ENABLE_FIXED_HEADER = \"THEME_OPTIONS/SET_ENABLE_FIXED_HEADER\"\r\nexport const SET_ENABLE_HEADER_SHADOW = \"THEME_OPTIONS/SET_ENABLE_HEADER_SHADOW\"\r\nexport const SET_ENABLE_SIDEBAR_SHADOW =\r\n \"THEME_OPTIONS/SET_ENABLE_SIDEBAR_SHADOW\"\r\nexport const SET_ENABLE_FIXED_SIDEBAR = \"THEME_OPTIONS/SET_ENABLE_FIXED_SIDEBAR\"\r\nexport const SET_ENABLE_CLOSED_SIDEBAR =\r\n \"THEME_OPTIONS/SET_ENABLE_CLOSED_SIDEBAR\"\r\nexport const SET_ENABLE_FIXED_FOOTER = \"THEME_OPTIONS/SET_ENABLE_FIXED_FOOTER\"\r\n\r\nexport const SET_ENABLE_PAGETITLE_ICON =\r\n \"THEME_OPTIONS/SET_ENABLE_PAGETITLE_ICON\"\r\nexport const SET_ENABLE_PAGETITLE_SUBHEADING =\r\n \"THEME_OPTIONS/SET_ENABLE_PAGETITLE_SUBHEADING\"\r\nexport const SET_ENABLE_PAGE_TABS_ALT = \"THEME_OPTIONS/SET_ENABLE_PAGE_TABS_ALT\"\r\n\r\nexport const SET_BACKGROUND_IMAGE = \"THEME_OPTIONS/SET_BACKGROUND_IMAGE\"\r\nexport const SET_BACKGROUND_COLOR = \"THEME_OPTIONS/SET_BACKGROUND_COLOR\"\r\nexport const SET_COLOR_SCHEME = \"THEME_OPTIONS/SET_COLOR_SCHEME\"\r\nexport const SET_BACKGROUND_IMAGE_OPACITY =\r\n \"THEME_OPTIONS/SET_BACKGROUND_IMAGE_OPACITY\"\r\n\r\nexport const SET_HEADER_BACKGROUND_COLOR =\r\n \"THEME_OPTIONS/SET_HEADER_BACKGROUND_COLOR\"\r\n\r\nexport const setEnableBackgroundImage = enableBackgroundImage => ({\r\n type: SET_ENABLE_BACKGROUND_IMAGE,\r\n enableBackgroundImage,\r\n})\r\n\r\nexport const setEnableFixedHeader = enableFixedHeader => ({\r\n type: SET_ENABLE_FIXED_HEADER,\r\n enableFixedHeader,\r\n})\r\n\r\nexport const setEnableHeaderShadow = enableHeaderShadow => ({\r\n type: SET_ENABLE_HEADER_SHADOW,\r\n enableHeaderShadow,\r\n})\r\n\r\nexport const setEnableSidebarShadow = enableSidebarShadow => ({\r\n type: SET_ENABLE_SIDEBAR_SHADOW,\r\n enableSidebarShadow,\r\n})\r\n\r\nexport const setEnablePageTitleIcon = enablePageTitleIcon => ({\r\n type: SET_ENABLE_PAGETITLE_ICON,\r\n enablePageTitleIcon,\r\n})\r\n\r\nexport const setEnablePageTitleSubheading = enablePageTitleSubheading => ({\r\n type: SET_ENABLE_PAGETITLE_SUBHEADING,\r\n enablePageTitleSubheading,\r\n})\r\n\r\nexport const setEnablePageTabsAlt = enablePageTabsAlt => ({\r\n type: SET_ENABLE_PAGE_TABS_ALT,\r\n enablePageTabsAlt,\r\n})\r\n\r\nexport const setEnableFixedSidebar = enableFixedSidebar => ({\r\n type: SET_ENABLE_FIXED_SIDEBAR,\r\n enableFixedSidebar,\r\n})\r\n\r\nexport const setEnableClosedSidebar = enableClosedSidebar => ({\r\n type: SET_ENABLE_CLOSED_SIDEBAR,\r\n enableClosedSidebar,\r\n})\r\n\r\nexport const setEnableMobileMenu = enableMobileMenu => ({\r\n type: SET_ENABLE_MOBILE_MENU,\r\n enableMobileMenu,\r\n})\r\n\r\nexport const setEnableMobileMenuSmall = enableMobileMenuSmall => ({\r\n type: SET_ENABLE_MOBILE_MENU_SMALL,\r\n enableMobileMenuSmall,\r\n})\r\n\r\nexport const setEnableFixedFooter = enableFixedFooter => ({\r\n type: SET_ENABLE_FIXED_FOOTER,\r\n enableFixedFooter,\r\n})\r\n\r\nexport const setBackgroundColor = backgroundColor => ({\r\n type: SET_BACKGROUND_COLOR,\r\n backgroundColor,\r\n})\r\n\r\nexport const setHeaderBackgroundColor = headerBackgroundColor => ({\r\n type: SET_HEADER_BACKGROUND_COLOR,\r\n headerBackgroundColor,\r\n})\r\n\r\nexport const setColorScheme = colorScheme => ({\r\n type: SET_COLOR_SCHEME,\r\n colorScheme,\r\n})\r\n\r\nexport const setBackgroundImageOpacity = backgroundImageOpacity => ({\r\n type: SET_BACKGROUND_IMAGE_OPACITY,\r\n backgroundImageOpacity,\r\n})\r\n\r\nexport const setBackgroundImage = backgroundImage => ({\r\n type: SET_BACKGROUND_IMAGE,\r\n backgroundImage,\r\n})\r\n\r\nexport default function reducer(\r\n state = {\r\n backgroundColor: \"bg-royal sidebar-text-light\",\r\n headerBackgroundColor: \"\", //\"bg-strong-bliss header-text-light\",\r\n enableMobileMenuSmall: \"\",\r\n enableBackgroundImage: true,\r\n enableClosedSidebar: lastEnableClosedSidebar === \"1\" ? true : false,\r\n enableFixedHeader: false,\r\n enableHoverSidebar: false, //bo sung de tat hover expand\r\n enableHeaderShadow: true,\r\n enableSidebarShadow: true,\r\n enableFixedFooter: true,\r\n enableFixedSidebar: true,\r\n colorScheme: \"white\", //\"white\",\r\n backgroundImage: sideBar6,\r\n backgroundImageOpacity: \"opacity-06\",\r\n enablePageTitleIcon: true,\r\n enablePageTitleSubheading: true,\r\n enablePageTabsAlt: false,\r\n },\r\n action\r\n) {\r\n switch (action.type) {\r\n case SET_ENABLE_BACKGROUND_IMAGE:\r\n return {\r\n ...state,\r\n enableBackgroundImage: action.enableBackgroundImage,\r\n }\r\n\r\n case SET_ENABLE_FIXED_HEADER:\r\n return {\r\n ...state,\r\n enableFixedHeader: action.enableFixedHeader,\r\n }\r\n\r\n case SET_ENABLE_HEADER_SHADOW:\r\n return {\r\n ...state,\r\n enableHeaderShadow: action.enableHeaderShadow,\r\n }\r\n\r\n case SET_ENABLE_SIDEBAR_SHADOW:\r\n return {\r\n ...state,\r\n enableSidebarShadow: action.enableSidebarShadow,\r\n }\r\n\r\n case SET_ENABLE_PAGETITLE_ICON:\r\n return {\r\n ...state,\r\n enablePageTitleIcon: action.enablePageTitleIcon,\r\n }\r\n\r\n case SET_ENABLE_PAGETITLE_SUBHEADING:\r\n return {\r\n ...state,\r\n enablePageTitleSubheading: action.enablePageTitleSubheading,\r\n }\r\n\r\n case SET_ENABLE_PAGE_TABS_ALT:\r\n return {\r\n ...state,\r\n enablePageTabsAlt: action.enablePageTabsAlt,\r\n }\r\n\r\n case SET_ENABLE_FIXED_SIDEBAR:\r\n return {\r\n ...state,\r\n enableFixedSidebar: action.enableFixedSidebar,\r\n }\r\n\r\n case SET_ENABLE_MOBILE_MENU:\r\n return {\r\n ...state,\r\n enableMobileMenu: action.enableMobileMenu,\r\n }\r\n\r\n case SET_ENABLE_MOBILE_MENU_SMALL:\r\n return {\r\n ...state,\r\n enableMobileMenuSmall: action.enableMobileMenuSmall,\r\n }\r\n\r\n case SET_ENABLE_CLOSED_SIDEBAR:\r\n HLocalStorage.saveString(\r\n kEnableClosedSidebar,\r\n action.enableClosedSidebar === true ? \"1\" : \"0\"\r\n )\r\n return {\r\n ...state,\r\n enableClosedSidebar: action.enableClosedSidebar,\r\n }\r\n\r\n case SET_ENABLE_FIXED_FOOTER:\r\n return {\r\n ...state,\r\n enableFixedFooter: action.enableFixedFooter,\r\n }\r\n\r\n case SET_BACKGROUND_COLOR:\r\n return {\r\n ...state,\r\n backgroundColor: action.backgroundColor,\r\n }\r\n\r\n case SET_HEADER_BACKGROUND_COLOR:\r\n return {\r\n ...state,\r\n headerBackgroundColor: action.headerBackgroundColor,\r\n }\r\n\r\n case SET_COLOR_SCHEME:\r\n return {\r\n ...state,\r\n colorScheme: action.colorScheme,\r\n }\r\n\r\n case SET_BACKGROUND_IMAGE:\r\n return {\r\n ...state,\r\n backgroundImage: action.backgroundImage,\r\n }\r\n\r\n case SET_BACKGROUND_IMAGE_OPACITY:\r\n return {\r\n ...state,\r\n backgroundImageOpacity: action.backgroundImageOpacity,\r\n }\r\n }\r\n return state\r\n}\r\n","import React from \"react\"\r\nimport { HUtils } from \"@macashipo/mlib\"\r\nimport NumeralJs from \"src/libs/NumeralJs/numeral\"\r\nimport HelperMore from \"./_helperMore\"\r\nimport { KMC } from \"src/helpers/Flows/More\"\r\nconst BaseText = props => {\r\n const more = HelperMore.getMoreFromProps(props) || {}\r\n const [isFocus, setIsFocus] = React.useState(false)\r\n const value = props.value\r\n const refValue = React.useRef(value)\r\n\r\n const getFormat = () => {\r\n return HUtils.runFuntion(props.fnList, \"getFormat\", []) || \"0,0.[00]\"\r\n }\r\n const getTypeInput = () => {\r\n return HUtils.runFuntion(props.fnList, \"getTypeInput\", []) || \"text\"\r\n }\r\n const fnFormatDefault = v => {\r\n return NumeralJs(v).format(getFormat())\r\n }\r\n const fnFormat =\r\n HUtils.runFuntion(props.fnList, \"fnFormat\", []) || fnFormatDefault\r\n let valueDisplay = fnFormat(value)\r\n // console.warn(\"render numeral valueDisplay:\", valueDisplay)\r\n const checkCanNotPress = (key = \"\") => {\r\n if (key == \"Enter\" && more[KMC.allowEnterToSubmit] === true) {\r\n return false\r\n }\r\n if (value) {\r\n let _sValue = String(value)\r\n if (key === \"-\" && _sValue.indexOf(\"-\") > -1) {\r\n return true\r\n }\r\n if (key === \".\" && _sValue.indexOf(\".\") > -1) {\r\n return true\r\n }\r\n }\r\n if (!/[0-9\\-\\.]/.test(key)) {\r\n return true\r\n }\r\n return false\r\n }\r\n const checkReplace = (newValue = \"\") => {\r\n //remove het cac ky tu ko mong muon khi copy vao\r\n newValue = newValue.replace(/[^0-9\\-\\.]/g, \"\")\r\n\r\n if (props.noDecimal) {\r\n newValue = newValue.replace(/[\\.\\,]/g, \"\")\r\n }\r\n //no negative\r\n if (props.noNegative === true && newValue.indexOf(\"-\") > -1) {\r\n newValue = newValue.replace(\"-\", \"\")\r\n }\r\n if (newValue.indexOf(\"-\") > -1 && newValue.indexOf(\"-\") > 0) {\r\n newValue = newValue.replace(/\\-/g, \"\")\r\n newValue = `-${newValue}`\r\n }\r\n if (newValue.indexOf(\".\") > -1) {\r\n if (newValue.indexOf(\".\") == 0) {\r\n newValue = `0${newValue}`\r\n }\r\n if (newValue.length > 1 && newValue.indexOf(\".\") == newValue.length) {\r\n newValue = `0${newValue}`\r\n }\r\n }\r\n return newValue\r\n }\r\n\r\n let _prefix = HelperMore.getPrefix(more) || props.prefix\r\n if (_prefix) {\r\n valueDisplay = _prefix + valueDisplay\r\n }\r\n let _suffix = HelperMore.getSuffix(more) || props.suffix\r\n if (_suffix) {\r\n valueDisplay += _suffix\r\n }\r\n\r\n if (value === \"\") {\r\n //== se bi truong hop 0 == \"\" => valueDisplay se bi rong\r\n valueDisplay = \"\"\r\n }\r\n // if (more[KMC.hideZero] || more[KMC.hideNull]) {\r\n // console.warn(\"hideZero\", props, more, value, valueDisplay)\r\n // }\r\n if (more[KMC.hideZero] == true && value == 0) {\r\n valueDisplay = \"\"\r\n }\r\n if (more[KMC.hideNull] == true && value == null) {\r\n valueDisplay = \"\"\r\n }\r\n //bo sung check valueDisplay == 0 do truong hop value == null\r\n if (more[KMC.hideZero] == true && valueDisplay == 0) {\r\n valueDisplay = \"\"\r\n }\r\n let Tag = \"input\"\r\n if (getTypeInput() === \"textarea\") {\r\n Tag = \"textarea\"\r\n }\r\n // console.warn(\"render numeral\", isFocus, props.value, valueDisplay, more)\r\n let _valueShowWhenFocus = value\r\n if (_valueShowWhenFocus === 0) {\r\n _valueShowWhenFocus = \"\"\r\n }\r\n // console.warn(\"render numeral:\", props, _valueShowWhenFocus, valueDisplay)\r\n let _moreProps = {}\r\n return (\r\n {\r\n let _value = checkReplace(ev.currentTarget.value)\r\n refValue.current = _value\r\n console.warn(\"onChange:\", _value)\r\n props.onChange && props.onChange(_value)\r\n }}\r\n onKeyPress={ev => {\r\n if (checkCanNotPress(ev.key)) {\r\n ev.preventDefault()\r\n }\r\n }}\r\n onFocus={ev => {\r\n //bo sung truong hop load list gia tri moi, khi bam vao bam ra thi luu gia tri null do onChange chua duoc goi\r\n refValue.current = _valueShowWhenFocus\r\n console.warn(\"onFocus:\", _valueShowWhenFocus)\r\n setIsFocus(true)\r\n }}\r\n onBlur={() => {\r\n setIsFocus(false)\r\n if (more.min != null && parseFloat(refValue.current) < more.min) {\r\n refValue.current = more.min\r\n props.onChange && props.onChange(refValue.current)\r\n }\r\n if (more.max != null && parseFloat(refValue.current) > more.max) {\r\n console.log(\"max:\", more.max)\r\n refValue.current = more.max\r\n props.onChange && props.onChange(refValue.current)\r\n }\r\n props.onBlur && props.onBlur(refValue.current)\r\n }}\r\n // onKeyDown={()=>{\r\n // }}\r\n className={props.className}\r\n style={props.style}\r\n {...props.attrs}\r\n {..._moreProps}\r\n />\r\n )\r\n}\r\n\r\nexport default BaseText\r\n","import { HUtils } from \"@macashipo/mlib\"\r\nimport LodashGet from \"lodash/get\"\r\nimport LodashDebounce from \"lodash/debounce\"\r\nimport { logOne } from \"./log\"\r\nimport HConstant from \"./constant\"\r\n\r\nexport const isFunction = (v: any) => {\r\n return typeof v === \"function\"\r\n}\r\nexport const isArray = (v: any) => {\r\n return Array.isArray(v)\r\n}\r\nexport const isString = (v: any) => {\r\n return typeof v === \"string\"\r\n}\r\nexport const isDateValue = (v: any) => {\r\n return new Date(v).getTime() > 0\r\n}\r\nexport const mergeObjIfExist = (srcObj, mergeObj) => {\r\n if (srcObj && mergeObj) {\r\n let _keys = Object.keys(mergeObj)\r\n if (_keys && _keys.length > 0) {\r\n for (let k of _keys) {\r\n srcObj[k] = mergeObj[k]\r\n }\r\n }\r\n }\r\n}\r\nexport const runFuntion = (fnList: any, name, args: any[] = []) => {\r\n if (fnList && isFunction(fnList[name])) {\r\n fnList[name].apply(null, args)\r\n } else {\r\n logOne(\"runFuntion failed:\", fnList, name)\r\n }\r\n}\r\nexport const safeInvoke = (fn, args: any[] = []) => {\r\n if (fn) {\r\n return fn.apply(null, args)\r\n }\r\n}\r\nexport const initMCore = (key, obj) => {\r\n if (window) {\r\n if (window[\"MCore\"] == null) {\r\n window[\"MCore\"] = {}\r\n }\r\n window[\"MCore\"][key] = obj\r\n }\r\n}\r\n\r\nexport const addArray2Array = (arr, moreArr) => {\r\n if (arr && moreArr) {\r\n // arr = arr.concat(moreArr);//ko dung concat duoc, chua biet tai sao\r\n arr.push(...moreArr)\r\n }\r\n}\r\n\r\nexport const objHasKey = (obj, key) => {\r\n if (obj && key && obj.hasOwnProperty) {\r\n return obj.hasOwnProperty(key)\r\n }\r\n}\r\n// export const combineArray = (array1, array2) => {\r\n// return [...array1, ...array2]\r\n// }\r\n\r\n// export const combineArray = (array1, array2) => {\r\n// return [].concat(array1, array2)\r\n// }\r\n\r\nexport const isLocalDev = () => {\r\n if (window.location.href.indexOf(\"localhost:\") > -1) {\r\n return true\r\n } else if (window.location.href.indexOf(\"192.168\") > -1) {\r\n return true\r\n }\r\n if (localStorage.getItem(HConstant.Dev.Key._DEBUG_) === \"true\") {\r\n return true\r\n }\r\n return false\r\n}\r\n\r\nexport const onKeyDownEnter = (ev, fn) => {\r\n if (ev.key === \"Enter\") {\r\n fn()\r\n }\r\n}\r\n\r\nexport const delay = (ms: number) => {\r\n return new Promise(resolve => setTimeout(resolve, ms))\r\n}\r\n\r\nexport const debounce = (fn, time, opts) => {\r\n return LodashDebounce(fn, time, opts)\r\n}\r\nexport const get = LodashGet\r\n\r\nexport const getTextWithData = HUtils.getTextWithData\r\n\r\nexport const checkConditionShow = (value: any, conditionValue) => {\r\n // console.warn(\"checkConditionShow:\", value, conditionValue)\r\n let _canShow = true\r\n if (isArray(conditionValue)) {\r\n _canShow = false\r\n for (let i = 0; i < conditionValue.length; i++) {\r\n let _check = checkConditionShow(value, conditionValue[i])\r\n if (_check === true) {\r\n //chi can 1 cai true thi se true\r\n return true\r\n }\r\n }\r\n } else {\r\n if (isArray(value)) {\r\n if (value.indexOf(conditionValue) === -1) {\r\n return false\r\n }\r\n } else if (value !== conditionValue) {\r\n return false\r\n }\r\n }\r\n return _canShow\r\n}\r\nexport const checkConditionShowWithOperator = (\r\n value: any,\r\n conditionValue,\r\n operator,\r\n format: any\r\n) => {\r\n console.warn(\"checkConditionShow:\", value, conditionValue)\r\n let _valueNeedCmp = value\r\n let _canShow = false\r\n if (_valueNeedCmp !== null && _valueNeedCmp !== undefined) {\r\n if (format?.type) {\r\n switch (format.type) {\r\n case \"year\":\r\n if (\r\n format?.cmpWith === \"now\" &&\r\n new Date().getFullYear() > new Date(_valueNeedCmp).getFullYear()\r\n ) {\r\n _valueNeedCmp =\r\n new Date().getFullYear() - new Date(_valueNeedCmp).getFullYear()\r\n }\r\n break\r\n\r\n default:\r\n break\r\n }\r\n }\r\n switch (operator) {\r\n case \">=\":\r\n if (_valueNeedCmp >= conditionValue) {\r\n _canShow = true\r\n }\r\n break\r\n case \">\":\r\n if (_valueNeedCmp > conditionValue) {\r\n _canShow = true\r\n }\r\n break\r\n case \"!=\":\r\n if (_valueNeedCmp !== conditionValue) {\r\n _canShow = true\r\n }\r\n break\r\n case \"=\":\r\n if (_valueNeedCmp === conditionValue) {\r\n _canShow = true\r\n }\r\n break\r\n case \"<\":\r\n if (_valueNeedCmp < conditionValue) {\r\n _canShow = true\r\n }\r\n break\r\n case \"<=\":\r\n if (_valueNeedCmp <= conditionValue) {\r\n _canShow = true\r\n }\r\n break\r\n default:\r\n break\r\n }\r\n }\r\n return _canShow\r\n}\r\n\r\nexport const isOnScreen = function (element) {\r\n if (element && element.offsetTop != null) {\r\n var curTop = element.offsetTop\r\n var heightOfWindow = window.innerHeight\r\n var offsetYOfWindow = window.scrollY\r\n if (curTop > offsetYOfWindow && curTop < heightOfWindow + offsetYOfWindow) {\r\n return true\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport const xorCrypt = function (str: string = \"\", key: number = 7) {\r\n var output = \"\"\r\n if (!key) {\r\n key = 6\r\n }\r\n for (var i = 0; i < str.length; ++i) {\r\n output += String.fromCharCode(key ^ str.charCodeAt(i))\r\n }\r\n return output\r\n}\r\nexport const isNotEmpty = (v: any) => {\r\n return v !== null && v !== undefined && v !== \"\" ? true : false\r\n}\r\nexport const isNotEmptyIncludeZero = (v: any) => {\r\n return isNotEmpty(v) && v !== 0 ? true : false\r\n}\r\nexport const squareBracket = {\r\n extract: function (s) {\r\n var matcher: any = (function () {\r\n var CSS_INTEGER = \"[-\\\\+]?\\\\d+%?\"\r\n var CSS_NUMBER = \"[-\\\\+]?\\\\d*\\\\.\\\\d+%?\"\r\n var CSS_UNIT = \"(?:\" + CSS_NUMBER + \")|(?:\" + CSS_INTEGER + \")\"\r\n var PERMISSIVE_MATCH3 =\r\n \"[\\\\s|\\\\(]+(\" +\r\n CSS_UNIT +\r\n \")[,|\\\\s]+(\" +\r\n CSS_UNIT +\r\n \")[,|\\\\s]+(\" +\r\n CSS_UNIT +\r\n \")\\\\s*\\\\)?\"\r\n var PERMISSIVE_MATCH4 =\r\n \"[\\\\s|\\\\(]+(\" +\r\n CSS_UNIT +\r\n \")[,|\\\\s]+(\" +\r\n CSS_UNIT +\r\n \")[,|\\\\s]+(\" +\r\n CSS_UNIT +\r\n \")[,|\\\\s]+(\" +\r\n CSS_UNIT +\r\n \")\\\\s*\\\\)?\"\r\n\r\n return {\r\n CSS_UNIT: new RegExp(CSS_UNIT),\r\n rgb: new RegExp(\"rgb\" + PERMISSIVE_MATCH3),\r\n rgba: new RegExp(\"rgba\" + PERMISSIVE_MATCH4),\r\n hsl: new RegExp(\"hsl\" + PERMISSIVE_MATCH3),\r\n hsla: new RegExp(\"hsla\" + PERMISSIVE_MATCH4),\r\n hsv: new RegExp(\"hsv\" + PERMISSIVE_MATCH3),\r\n hsva: new RegExp(\"hsva\" + PERMISSIVE_MATCH4),\r\n hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\r\n hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,\r\n hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\r\n hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,\r\n extSquareBracket: /\\[(.[^\\]]*)\\]/gm,\r\n }\r\n })()\r\n var _result: any = []\r\n if (s != null) {\r\n var _m\r\n while ((_m = matcher.extSquareBracket.exec(s)) !== null) {\r\n if (_m.index === matcher.lastIndex) {\r\n matcher.lastIndex++\r\n }\r\n if (_m.length > 1) {\r\n _result.push(_m[1])\r\n }\r\n }\r\n }\r\n return _result\r\n },\r\n replace: function (s, obj, { emptyWhenNull }: any = {}) {\r\n var extract = squareBracket.extract(s)\r\n var newS = s\r\n if (extract != null) {\r\n for (var _item of extract) {\r\n if (obj[_item] != null) {\r\n let rg = new RegExp(`\\\\[${_item}\\\\]`, \"g\")\r\n newS = newS.replace(rg, obj[_item])\r\n } else if (emptyWhenNull == true && obj[_item] == null) {\r\n ////Bo sung emptyWhenNull, de ko muon [] trong chuoi sau khi replace\r\n let rg = new RegExp(`\\\\[${_item}\\\\]`, \"g\")\r\n newS = newS.replace(rg, \"\")\r\n }\r\n }\r\n }\r\n return newS\r\n },\r\n}\r\n\r\nexport const getVideoCover = (file, seekTo = 0.0) => {\r\n console.log(\"getting video cover for file: \", file)\r\n return new Promise((resolve, reject) => {\r\n // load the file to a video player\r\n const videoPlayer = document.createElement(\"video\")\r\n videoPlayer.setAttribute(\"src\", URL.createObjectURL(file))\r\n videoPlayer.load()\r\n videoPlayer.addEventListener(\"error\", ex => {\r\n reject(\"error when loading video file\")\r\n })\r\n // load metadata of the video to get video duration and dimensions\r\n videoPlayer.addEventListener(\"loadedmetadata\", () => {\r\n // seek to user defined timestamp (in seconds) if possible\r\n if (videoPlayer.duration < seekTo) {\r\n reject(\"video is too short.\")\r\n return\r\n }\r\n // delay seeking or else 'seeked' event won't fire on Safari\r\n setTimeout(() => {\r\n videoPlayer.currentTime = seekTo\r\n }, 200)\r\n // extract video thumbnail once seeking is complete\r\n videoPlayer.addEventListener(\"seeked\", () => {\r\n console.log(\"video is now paused at %ss.\", seekTo)\r\n // define a canvas to have the same dimension as the video\r\n const canvas = document.createElement(\"canvas\")\r\n canvas.width = videoPlayer.videoWidth\r\n canvas.height = videoPlayer.videoHeight\r\n // draw the video frame to canvas\r\n const ctx = canvas.getContext(\"2d\")\r\n if (ctx) {\r\n ctx.drawImage(videoPlayer, 0, 0, canvas.width, canvas.height)\r\n // return the canvas image as a blob\r\n ctx.canvas.toBlob(\r\n blob => {\r\n resolve(blob)\r\n },\r\n \"image/jpeg\",\r\n 0.75 /* quality */\r\n )\r\n }\r\n })\r\n })\r\n })\r\n}\r\nwindow[\"_xorCrypt\"] = xorCrypt\r\n","import React from \"react\"\r\nimport MyUIHelpers from \"src/core/components/MyUI/MyUIHelpers\"\r\nimport { CSuppense } from \"src/core/components\"\r\n\r\nconst MUI_dev_simulator = React.lazy(() => import(\"./Types/dev_simulator\"))\r\nconst MUI_dev_jsonconverter = React.lazy(\r\n () => import(\"./Types/dev_jsonconverter\")\r\n)\r\n\r\nconst MyUIOne = {\r\n init() {\r\n MyUIHelpers.addTypes(\"dev_simulator\", props => {\r\n return CSuppense(props, MUI_dev_simulator)\r\n })\r\n MyUIHelpers.addTypes(\"dev_jsonconverter\", props => {\r\n return CSuppense(props, MUI_dev_jsonconverter)\r\n })\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","import React from \"react\"\r\nimport ReactDOM from \"react-dom\"\r\nimport { MyModal } from \"src/core/components\"\r\nclass DevMenu extends React.PureComponent {\r\n constructor(props) {\r\n super(props)\r\n this.state = {}\r\n }\r\n render() {\r\n return (\r\n
\r\n
\r\n \r\n
\r\n
\r\n {\r\n MyModal.showFromMyUI(\r\n {\r\n type: \"dev_jsonconverter\",\r\n },\r\n {\r\n title: \"JSON\",\r\n }\r\n )\r\n }}\r\n >\r\n Json\r\n \r\n
\r\n
\r\n )\r\n }\r\n}\r\n\r\nDevMenu.renderIntoId = divId => {\r\n if (divId && document.getElementById(divId)) {\r\n ReactDOM.render(, document.getElementById(divId))\r\n }\r\n}\r\nexport default DevMenu\r\n","import { HLocalStorage, HUtils, HApi } from \"src/core/helpers\"\r\nimport { MyModal } from \"src/core/components\"\r\nimport MyUIOne from \"./MyUI\"\r\nimport { HCF, HJson } from \"@macashipo/mlib\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nimport DevMenu from \"./MyUI/Types/dev_menu\"\r\nimport \"./scss/index.scss\"\r\n\r\ninterface IModuleDevSimulator extends IModuleOne {\r\n usingLocalBaseUrlKey?: any\r\n localBaseUrlKey?: any\r\n localConfigKey?: any\r\n usingLocalBaseUrl?: boolean\r\n runAfterInit: () => void\r\n setLocalBaseUrl: (newBaseUrl: any) => void\r\n setLocalConfig: (newConfigJsonString: any) => void\r\n getIsUsingLocalBaseUrl: () => boolean\r\n getLocalBaseUrl: () => string\r\n getLocalConfig: () => string\r\n showUIDevSimulator: () => void\r\n setIsUsingLocalBaseUrl: (value: any) => void\r\n}\r\nconst ModuleDevSimulator: IModuleDevSimulator = {\r\n usingLocalBaseUrlKey: \"_usingLocalBaseUrl\",\r\n localBaseUrlKey: \"_localBaseUrl\",\r\n localConfigKey: \"_localConfig\",\r\n usingLocalBaseUrl: false,\r\n runAfterInit: () => {\r\n MyUIOne.init()\r\n const localBaseUrl = ModuleDevSimulator.getLocalBaseUrl()\r\n const localConfigJson = ModuleDevSimulator.getLocalConfig()\r\n const isUsingLocalBaseUrl = ModuleDevSimulator.getIsUsingLocalBaseUrl()\r\n if (isUsingLocalBaseUrl === true) {\r\n ModuleDevSimulator.usingLocalBaseUrl = true\r\n if (localBaseUrl) {\r\n HCF.setCF(KConfigApp.baseUrl, localBaseUrl)\r\n HApi.initApi({ baseUrl: localBaseUrl })\r\n }\r\n }\r\n if (localConfigJson) {\r\n let _localConfig = HJson.getObj(localConfigJson)\r\n if (_localConfig) {\r\n HCF.setCFMultiObj(_localConfig)\r\n }\r\n }\r\n if (HUtils.isLocalDev() === true || isUsingLocalBaseUrl === true) {\r\n HCF.setCF(KConfigApp.isDevMode, true)\r\n ModuleDevSimulator.showUIDevSimulator()\r\n } else {\r\n console.log = () => {}\r\n console.warn = () => {}\r\n }\r\n if (!localBaseUrl) {\r\n ModuleDevSimulator.setLocalBaseUrl(\"http://localhost:12391\")\r\n }\r\n },\r\n getIsUsingLocalBaseUrl: () => {\r\n if (\r\n HLocalStorage.getObj(ModuleDevSimulator.usingLocalBaseUrlKey, {}) === true\r\n ) {\r\n return true\r\n }\r\n return false\r\n },\r\n getLocalBaseUrl: () => {\r\n return HLocalStorage.getString(ModuleDevSimulator.localBaseUrlKey, \"\")\r\n },\r\n getLocalConfig: () => {\r\n return HLocalStorage.getString(ModuleDevSimulator.localConfigKey, \"\")\r\n },\r\n setIsUsingLocalBaseUrl: value => {\r\n ModuleDevSimulator.usingLocalBaseUrl = value\r\n HLocalStorage.saveString(ModuleDevSimulator.usingLocalBaseUrlKey, value)\r\n },\r\n setLocalBaseUrl: newBaseUrl => {\r\n HLocalStorage.saveString(ModuleDevSimulator.localBaseUrlKey, newBaseUrl)\r\n },\r\n setLocalConfig: newConfigJsonString => {\r\n HLocalStorage.saveString(\r\n ModuleDevSimulator.localConfigKey,\r\n newConfigJsonString\r\n )\r\n },\r\n showUIDevSimulator: () => {\r\n if (!document.getElementById(\"dev_simulator\")) {\r\n const _localBaseUrl = ModuleDevSimulator.getLocalBaseUrl()\r\n let div = document.createElement(\"div\")\r\n div.id = \"dev_simulator\"\r\n div.className = \"ag-np\"\r\n let button = document.createElement(\"button\")\r\n button.type = \"button\"\r\n button.title = \"Show config dev debug\"\r\n button.innerHTML = ` ${\r\n ModuleDevSimulator.usingLocalBaseUrl && _localBaseUrl\r\n ? _localBaseUrl\r\n : \"\"\r\n }`\r\n button.className = \"btn btn-danger btn-dev-sml ag-np\"\r\n button.onclick = function () {\r\n MyModal.showFromMyUI(\r\n {\r\n type: \"dev_simulator\",\r\n },\r\n {\r\n title: \"Config BaseUrl\",\r\n }\r\n )\r\n }\r\n div.appendChild(button)\r\n\r\n let divMenu = document.createElement(\"div\")\r\n divMenu.id = \"dev_menu\"\r\n div.appendChild(divMenu)\r\n //add div to body\r\n document.body.appendChild(div)\r\n document.body.style.position = \"relative\"\r\n\r\n DevMenu.renderIntoId(\"dev_menu\")\r\n }\r\n },\r\n}\r\nexport default ModuleDevSimulator\r\n","import { HUtils as MHUtils, HRegex } from \"@macashipo/mlib\"\r\nimport Tooltip from \"src/core/components/Others/Tooltip\"\r\nimport Popover from \"src/core/components/Others/Popover\"\r\nimport { squareBracket } from \"src/core/helpers/utils\"\r\nconst HUtils = {\r\n Obj: {\r\n get: (obj, key) => {\r\n return MHUtils.get(obj, key)\r\n },\r\n },\r\n SquareBracket: {\r\n replace: (string, data, opts) => {\r\n squareBracket.replace(string, data)\r\n // HRegex.re\r\n },\r\n },\r\n runFnList: (fnList, name, args) => {\r\n return MHUtils.runFuntion(fnList, name, args)\r\n },\r\n}\r\nconst HConstant = {\r\n UIFnCore: {\r\n //fnFrom MyUI Core\r\n myData: \"myData\", //get data from this.props.data\r\n myChange: \"myChange\", //call function from onChange\r\n myBlur: \"myBlur\", //call function from onBlur\r\n },\r\n UIOnClick: {\r\n key: \"onCl\",\r\n },\r\n UIOnChange: {\r\n key: \"onC\",\r\n updateField: \"updateField\", //update field\r\n },\r\n UIOnBlur: {\r\n key: \"onB\",\r\n updateField: \"updateField\", //update field\r\n },\r\n UIFnPage: {\r\n //fn from MyPage\r\n fnRequestUpdate: \"fnRequestUpdate\", //fnRequestUpdate(row, fieldName, cellValue, opts)\r\n fnReloadList: \"fnReloadList\", //load lai list\r\n fnReloadTable: \"fnReloadTable\", //old: tuong tu fnReloadList\r\n fnReloadOptionsAndList: \"fnReloadOptionsAndList\",\r\n fnGetExpandList: \"fnGetExpandList\",\r\n fnForceUpdateTable: \"fnForceUpdateTable\", //forceupdate table, chi moi co ben category\r\n fnHeaderChangeExpand: \"fnHeaderChangeExpand\",\r\n fnGetCanEditOfField: \"fnGetCanEditOfField\",\r\n fnGetCanShowOfField: \"fnGetCanShowOfField\",\r\n fnGetCurrentProject: \"fnGetCurrentProject\", //get Current Project tu tren xuong\r\n fnGetCurrentProjectId: \"fnGetCurrentProjectId\", //get Current Project Id tu tren xuong, ko xai nua\r\n fnGetOptions: \"fnGetOptions\", //get Options cua page\r\n fnGetConfigFromScreenConfig: \"fnGetConfigFromScreenConfig\",\r\n fnGetListExtraData: \"fnGetListExtraData\", //get extradata\r\n fnGetExtraDataTable: \"fnGetExtraDataTable\", // tuong tu fnGetListExtraData\r\n fnGetListData: \"fnGetListData\", //get list data\r\n fnGetDataTable: \"fnGetDataTable\", //tuong tu get list data\r\n fnGetListObj: \"fnGetListObj\", //get list obj\r\n },\r\n}\r\nexport { HUtils, HConstant, Tooltip, Popover }\r\n","import React from \"react\"\r\nimport classnames from \"classnames\"\r\nimport { Modal, ModalBody, ModalFooter, ModalHeader, Button } from \"reactstrap\"\r\nimport { logW } from \"src/core/helpers/log\"\r\nimport { isFunction, objHasKey } from \"src/core/helpers/utils\"\r\nimport MyForm from \"src/core/components/MyForm/MyForm\"\r\nimport { MyUI, MyLoading, MyPage, HUtils } from \"@macashipo/mlib\"\r\nimport { kfnGetIsInModal } from \"src/helpers/fnList\"\r\nimport Draggable from \"react-draggable\"\r\nimport styled from \"styled-components\"\r\ninterface IProps {\r\n className?: any\r\n style?: any\r\n type: string\r\n level?: number\r\n}\r\n\r\ninterface IState {\r\n isShow?: boolean\r\n opts?: IConfigModal\r\n showLoading?: boolean\r\n size?: any\r\n customData?: any\r\n}\r\n\r\ninterface IConfigModal {\r\n component?: any\r\n showFooter?: boolean\r\n showHeader?: boolean\r\n modalClassName?: string\r\n modalCentered?: boolean\r\n modalScrollInside?: boolean\r\n title?: string\r\n usingModalBody?: boolean\r\n usingModalHeader?: boolean\r\n size?: string\r\n backdrop?: any | \"static\"\r\n fnList?: any\r\n msg?: any\r\n msgHtml?: any\r\n classNameBody?: string\r\n styleBody?: any\r\n onClickClose?: any\r\n onClickOK?: any\r\n showFooterClose?: boolean\r\n showFooterOK?: boolean\r\n titleBtnClose?: string\r\n titleBtnOK?: string\r\n colorBtnOK?: string\r\n configMyPage?: any\r\n wrapComponentBody?: any //wrap component thay the modalBody, khi usingModalBody = false\r\n level?: number //level modal,\r\n nextLevel?: boolean //without level, auto increate\r\n dragable?: boolean\r\n keepDragablePosition?: boolean\r\n onClose?: any\r\n showChangeSize?: boolean\r\n showMiniClose?: boolean\r\n morePropsModal?: any\r\n}\r\n\r\nconst ListSize = [\"xm\", \"lg\", \"xl\", \"full\"]\r\nconst WrapResize = styled.div`\r\n position: absolute;\r\n right: 15px;\r\n top: -15px;\r\n z-index: 1;\r\n & button {\r\n min-width: 28px;\r\n padding: 5px;\r\n line-height: 10px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n }\r\n`\r\n\r\nclass MyModal extends React.Component {\r\n state: any = {\r\n isShow: false,\r\n showLoading: false,\r\n size: null,\r\n opts: {},\r\n customData: null,\r\n }\r\n _fnList: any = {}\r\n _cDragable: any = null\r\n componentDidMount() {\r\n const { type, level } = this.props\r\n MyModal.Helpers.initComponent(type, this, level)\r\n this._fnList = {\r\n [kfnGetIsInModal]: () => {\r\n return true\r\n },\r\n getModal: () => {\r\n return this\r\n },\r\n hideModal: () => {\r\n this.hide()\r\n },\r\n showLoadingModal: v => {\r\n this.showLoading(v)\r\n },\r\n hideLoadingModal: () => {\r\n this.hideLoading()\r\n },\r\n setCustomData: this.setCustomData,\r\n }\r\n }\r\n show = (opts: any) => {\r\n this.setState(\r\n {\r\n isShow: true,\r\n opts: { ...MyModal.Helpers.defaultConfigModal, ...opts },\r\n },\r\n () => {\r\n let paddingRight = document.body.style.getPropertyValue(\"padding-right\")\r\n if (paddingRight == \"17px\") {\r\n document.body.style.paddingRight = \"8px\"\r\n }\r\n }\r\n )\r\n }\r\n showLoading = (v = true) => {\r\n this.setState({\r\n showLoading: v,\r\n })\r\n }\r\n hideLoading = () => {\r\n this.setState({\r\n showLoading: false,\r\n })\r\n }\r\n hide = () => {\r\n this.setState(\r\n {\r\n isShow: false,\r\n showLoading: false,\r\n opts: {},\r\n size: null,\r\n },\r\n () => {\r\n this.onClose()\r\n }\r\n )\r\n }\r\n toggle = () => {\r\n this.setState(\r\n {\r\n isShow: !this.state.isShow,\r\n },\r\n () => {\r\n const { opts, isShow } = this.state\r\n if (opts.keepDragablePosition !== true) {\r\n //reset position dragable\r\n // console.warn(\"this._cDragable:\", this._cDragable)\r\n if (this._cDragable && this._cDragable.state) {\r\n try {\r\n this._cDragable.state.x = 0\r\n this._cDragable.state.y = 0\r\n } catch (err) {\r\n // Fail silently\r\n }\r\n }\r\n }\r\n this.onClose()\r\n }\r\n )\r\n }\r\n onClose = () => {\r\n const { opts, isShow } = this.state\r\n if (isShow === false) {\r\n if (opts?.onClose) {\r\n opts.onClose()\r\n }\r\n }\r\n }\r\n setCustomData = data => {\r\n this.setState({\r\n customData: data,\r\n })\r\n }\r\n getCustomData = () => {\r\n return this.state.customData\r\n }\r\n _getConfig = key => {\r\n const { opts } = this.state\r\n if (objHasKey(opts, key)) {\r\n return opts[key]\r\n }\r\n }\r\n _renderContent = () => {\r\n let _ui = null\r\n const { type } = this.props\r\n const { opts, isShow } = this.state\r\n if (isShow !== true) {\r\n return
\r\n }\r\n switch (type) {\r\n case MyModal.Helpers.types.myui:\r\n console.log(\"mymodal:\", opts)\r\n return (\r\n \r\n )\r\n case MyModal.Helpers.types.mydialog:\r\n if (opts.component) {\r\n if (isFunction(opts.component)) {\r\n return opts.component({\r\n inMyModal: this,\r\n fnList: { ...this._fnList, ...opts.fnList },\r\n configFromModal: opts,\r\n })\r\n } else {\r\n return opts.component\r\n }\r\n } else {\r\n if (opts.msgHtml) {\r\n return \r\n } else if (opts.msg) {\r\n return opts.msg\r\n }\r\n return \"\"\r\n }\r\n case MyModal.Helpers.types.component:\r\n if (opts.component) {\r\n if (isFunction(opts.component)) {\r\n return opts.component({\r\n inMyModal: this,\r\n fnList: { ...this._fnList, ...opts.fnList },\r\n configFromModal: opts,\r\n })\r\n } else {\r\n return opts.component\r\n }\r\n } else {\r\n logW(\"Missing component\")\r\n return
\r\n }\r\n case MyModal.Helpers.types.mypage:\r\n return (\r\n \r\n )\r\n case MyModal.Helpers.types.cellinmodal:\r\n return \r\n case MyModal.Helpers.types.myform:\r\n if (opts.configForm) {\r\n return (\r\n \r\n )\r\n } else {\r\n logW(\"Missing configForm\")\r\n return
\r\n }\r\n }\r\n return _ui\r\n }\r\n _renderBody = () => {\r\n const { opts } = this.state\r\n if (opts.usingModalBody === true) {\r\n return (\r\n \r\n {this._renderContent()}\r\n \r\n )\r\n }\r\n if (opts.wrapComponentBody) {\r\n let TagBody = opts.wrapComponentBody\r\n return {this._renderContent()}\r\n }\r\n return this._renderContent()\r\n }\r\n _renderHeaderContent = () => {\r\n const { opts } = this.state\r\n return opts.title\r\n }\r\n _renderHeader = () => {\r\n const { opts } = this.state\r\n if (opts.showHeader === true) {\r\n return (\r\n \r\n {this._renderHeaderContent()}\r\n \r\n )\r\n }\r\n return null\r\n }\r\n _renderFooter = () => {\r\n const { opts } = this.state\r\n if (opts.showFooter === true) {\r\n return (\r\n \r\n {opts.showFooterClose && (\r\n {\r\n if (opts.onClickClose) {\r\n opts.onClickClose(this)\r\n } else {\r\n this.hide()\r\n }\r\n }}\r\n >\r\n {opts.titleBtnClose || \"Close\"}\r\n \r\n )}\r\n {opts.showFooterOK && (\r\n {\r\n if (opts.onClickOK) {\r\n opts.onClickOK(this)\r\n }\r\n }}\r\n >\r\n {opts.titleBtnOK || \"OK\"}\r\n \r\n )}\r\n \r\n )\r\n }\r\n return null\r\n }\r\n _getClassname = () => {\r\n const { opts, size } = this.state\r\n return classnames(opts.modalClassName, {\r\n \"modal-dialog-centered\": opts.modalCentered,\r\n [`modal-${size || opts.size}`]: true, //sm,lg,xl,full,overscreen\r\n \"modal-dialog-scrollable\": opts.modalScrollInside,\r\n [`modal-level-${opts.level}`]: opts.level != null,\r\n [`modal-dragable`]: opts.dragable === true,\r\n })\r\n }\r\n _renderOverlay = () => {\r\n if (this.state.showLoading === true) {\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n }\r\n _renderResize = () => {\r\n const { opts, size } = this.state\r\n if (opts.showChangeSize === true) {\r\n return (\r\n \r\n {\r\n this.setState({\r\n size: \"xm\",\r\n })\r\n }}\r\n >\r\n \r\n \r\n {\r\n this.setState({\r\n size: \"lg\",\r\n })\r\n }}\r\n >\r\n \r\n \r\n {\r\n this.setState({\r\n size: \"full\",\r\n })\r\n }}\r\n >\r\n \r\n \r\n {opts.showMiniClose === true && (\r\n {\r\n this.hide()\r\n }}\r\n >\r\n \r\n \r\n )}\r\n \r\n )\r\n }\r\n return null\r\n }\r\n render() {\r\n const { isShow, opts } = this.state\r\n const { backdrop } = opts\r\n const WrapModal = opts.dragable === true ? Draggable : React.Fragment\r\n const PropsWrapModal =\r\n opts.dragable === true\r\n ? {\r\n handle: \".a-dragable-handle\",\r\n ref: r => {\r\n this._cDragable = r\r\n },\r\n }\r\n : {}\r\n return (\r\n \r\n \r\n {this._renderResize()}\r\n {this._renderHeader()}\r\n {this._renderBody()}\r\n {this._renderFooter()}\r\n {this._renderOverlay()}\r\n \r\n \r\n )\r\n }\r\n static Helpers = {\r\n defaultConfigModal: {\r\n usingModalBody: true,\r\n showHeader: true,\r\n size: \"lg\",\r\n },\r\n types: {\r\n component: \"component\",\r\n myui: \"myui\",\r\n myform: \"myform\",\r\n mypage: \"mypage\",\r\n lightbox: \"lightbox\",\r\n mydialog: \"mydialog\",\r\n cellinmodal: \"cellinmodal\",\r\n globalloading: \"globalloading\",\r\n },\r\n initComponent: (type, component, level: any = null) => {\r\n if (type && component) {\r\n if (level != null) {\r\n MyModal.Helpers.components[`${type}_${level}`] = component\r\n } else {\r\n MyModal.Helpers.components[type] = component\r\n }\r\n }\r\n },\r\n components: {},\r\n }\r\n static showWithType = (type, opts) => {\r\n let _type = type\r\n if (opts) {\r\n if (opts.level != null) {\r\n _type = `${_type}_${opts.level}`\r\n } else if (opts.nextLevel === true) {\r\n let _level = 1\r\n let _listModal = document.querySelectorAll(\"body>div>div>.modal\")\r\n if (_listModal && _listModal.length > 0) {\r\n _level = _listModal.length + 1\r\n opts.level = _level\r\n _type = `${_type}_${_level}`\r\n }\r\n }\r\n }\r\n if (MyModal.Helpers.components[_type]) {\r\n MyModal.Helpers.components[_type].show(opts)\r\n }\r\n }\r\n static showFromMyUI = (configMyUI, configModal: IConfigModal | null) => {\r\n MyModal.showWithType(MyModal.Helpers.types.myui, {\r\n configMyUI: configMyUI,\r\n ...configModal,\r\n })\r\n }\r\n static showFromMyPage = (configMyPage, configModal: IConfigModal | null) => {\r\n MyModal.showWithType(MyModal.Helpers.types.mypage, {\r\n configMyPage: configMyPage,\r\n ...configModal,\r\n })\r\n }\r\n static showFromMyForm = (configForm, configModal: IConfigModal | null) => {\r\n MyModal.showWithType(MyModal.Helpers.types.myform, {\r\n configForm: configForm,\r\n backdrop: \"static\",\r\n ...configModal,\r\n })\r\n }\r\n static showFromComponent = (component, configModal: IConfigModal | null) => {\r\n MyModal.showWithType(MyModal.Helpers.types.component, {\r\n component: component,\r\n ...configModal,\r\n })\r\n }\r\n static showMyDialogWithInput = (\r\n { placeHolder, defaultValue }: any = {},\r\n configModal: IConfigModal | null\r\n ) => {\r\n MyModal.showWithType(MyModal.Helpers.types.mydialog, {\r\n size: \"xs\",\r\n showFooter: true,\r\n showFooterOK: true,\r\n showFooterClose: true,\r\n backdrop: \"static\",\r\n component: ({ fnList }) => {\r\n return (\r\n
\r\n {\r\n HUtils.runFuntion(fnList, \"setCustomData\", [\r\n ev.currentTarget.value,\r\n ])\r\n }}\r\n />\r\n
\r\n )\r\n },\r\n ...configModal,\r\n })\r\n }\r\n\r\n static showMyDialogWithConfigModal = (configModal: IConfigModal | null) => {\r\n MyModal.showWithType(MyModal.Helpers.types.mydialog, {\r\n ...configModal,\r\n })\r\n }\r\n\r\n static showMyDialog = (configDialog, configModal: IConfigModal | null) => {\r\n MyModal.showWithType(MyModal.Helpers.types.mydialog, {\r\n configDialog,\r\n ...configModal,\r\n })\r\n }\r\n static showCellInModal = (\r\n propsCell: any,\r\n configModal: IConfigModal | null\r\n ) => {\r\n MyModal.showWithType(MyModal.Helpers.types.cellinmodal, {\r\n configMyUI: {\r\n type: \"_wrapCellOnModal\",\r\n ...propsCell,\r\n },\r\n size: \"xl\",\r\n showHeader: true,\r\n showFooter: false,\r\n ...configModal,\r\n })\r\n }\r\n static showConfirm = (configModal: IConfigModal | null) => {\r\n MyModal.showWithType(MyModal.Helpers.types.mydialog, {\r\n size: \"xs\",\r\n showFooter: true,\r\n showFooterOK: true,\r\n showFooterClose: true,\r\n backdrop: \"static\",\r\n component: () => {\r\n if (configModal?.msg) {\r\n return (\r\n
\r\n {configModal?.msg}\r\n
\r\n )\r\n } else if (configModal?.msgHtml) {\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n },\r\n ...configModal,\r\n })\r\n }\r\n static showGlobalLoading = (configModal, ComponentClass) => {\r\n const GlobalLoading = () => {\r\n return (\r\n \r\n \r\n \r\n )\r\n }\r\n MyModal.showWithType(MyModal.Helpers.types.globalloading, {\r\n size: \"xs\",\r\n showFooter: false,\r\n showHeader: false,\r\n backdrop: \"static\",\r\n modalClassName: \"modal-transparent\",\r\n usingModalBody: false,\r\n morePropsModal: {\r\n modalTransition: { baseClass: \"\", timeout: 0 },\r\n },\r\n wrapComponentBody: ComponentClass || GlobalLoading,\r\n ...configModal,\r\n })\r\n }\r\n static hideGlobalLoading = () => {\r\n if (MyModal.Helpers.components[MyModal.Helpers.types.globalloading]) {\r\n MyModal.Helpers.components[MyModal.Helpers.types.globalloading].hide()\r\n }\r\n }\r\n static hideModalComponent = () => {\r\n if (MyModal.Helpers.components[MyModal.Helpers.types.component]) {\r\n MyModal.Helpers.components[MyModal.Helpers.types.component].hide()\r\n }\r\n }\r\n static hideModalMyUI = () => {\r\n if (MyModal.Helpers.components[MyModal.Helpers.types.myui]) {\r\n MyModal.Helpers.components[MyModal.Helpers.types.myui].hide()\r\n }\r\n }\r\n static hideComponent = () => {\r\n if (MyModal.Helpers.components[\"component\"]) {\r\n MyModal.Helpers.components[\"component\"].hide()\r\n }\r\n }\r\n static hideMyPage = () => {\r\n if (MyModal.Helpers.components[\"mypage\"]) {\r\n MyModal.Helpers.components[\"mypage\"].hide()\r\n }\r\n }\r\n static hideModal = type => {\r\n if (MyModal.Helpers.components[type]) {\r\n MyModal.Helpers.components[type].hide()\r\n }\r\n }\r\n static renderHeader = ({\r\n cModal,\r\n styleModalHeader,\r\n title,\r\n hideClose,\r\n }: {\r\n cModal?: any\r\n styleModalHeader?: any\r\n title?: any\r\n hideClose?: boolean\r\n } = {}) => {\r\n let _moreProps: any = {}\r\n if (hideClose !== true) {\r\n _moreProps.toggle = () => {\r\n if (cModal && cModal.hide) {\r\n cModal.hide()\r\n }\r\n }\r\n }\r\n return (\r\n \r\n {typeof title === \"function\" ? title({}) : title}\r\n \r\n )\r\n }\r\n}\r\n\r\nexport default MyModal\r\n","//more of table cell\r\nexport const KMTC = {\r\n usingI18n: \"usingI18n\",\r\n className: \"className\",\r\n style: \"style\",\r\n styleByValue: \"styleByValue\",\r\n styleDisabled: \"styleDisabled\",\r\n configIcon: \"configIcon\",\r\n configCheckbox: \"configCheckbox\",\r\n icon: \"icon\", // cho select_icon v.v..\r\n linkTitle: \"linkTitle\",\r\n fLinkTitle: \"fLinkTitle\",\r\n canEditF: \"canEditF\",\r\n fCanEdit: \"fCanEdit\",\r\n newWindow: \"newWindow\",\r\n showPhoto: \"showPhoto\",\r\n maxHeight: \"maxHeight\",\r\n maxWidth: \"maxWidth\",\r\n noScale: \"noScale\",\r\n styleImg: \"styleImg\",\r\n link: \"link\",\r\n fLink: \"fLink\",\r\n color: \"color\",\r\n fColor: \"fColor\",\r\n min: \"min\",\r\n fMin: \"fMin\",\r\n max: \"max\",\r\n fMax: \"fMax\",\r\n styleInput: \"styleInput\",\r\n styleControl: \"styleControl\",\r\n classNameWithColField: \"classNameWithColField\",\r\n classNameDisabled: \"classNameDisabled\",\r\n modal: \"modal\",\r\n placeHolder: \"placeHolder\",\r\n format: \"format\",\r\n dateFormat: \"dateFormat\",\r\n datetimeFormat: \"datetimeFormat\",\r\n dateTextFormat: \"dateTextFormat\",\r\n fBorderLeftColor: \"fBorderLeftColor\",\r\n configPage: \"configPage\",\r\n configApi: \"configApi\",\r\n configPagination: \"configPagination\",\r\n fSelectValue: \"fSelectValue\", //for select2_modal_table\r\n query: \"query\",\r\n querySelectValue: \"querySelectValue\", //for form_modal_table\r\n queryFromParent: \"queryFromParent\", //dung trong kieu expand api -> bo sung query lay tu parent\r\n queryWithQuerySharedPage: \"queryWithQuerySharedPage\", //boolean: query request bo sung them tu _onePage.getQueryShared()\r\n clickToSelect: \"clickToSelect\",\r\n button: \"button\",\r\n cbNormal: \"cbNormal\", //for checkbox\r\n cbPositive: \"cbPositive\", //for checkbox\r\n cbNegative: \"cbNegative\", //for checkbox\r\n configEditIcon: \"configEditIcon\", //\r\n configFileIcon: \"configFileIcon\",\r\n configTextDisplay: \"configTextDisplay\", //config text display {fDisplay,fShow,hasIconAndText,fIcon,icon}\r\n typeAdmin: \"typeAdmin\", //type danh rieng cho trang admin neu can thiet\r\n titleConfirm: \"titleConfirm\",\r\n titleExpand: \"titleExpand\",\r\n confirmMsg: \"confirmMsg\", //truoc khi click api v.v..\r\n fConfirmMsg: \"fConfirmMsg\", //f confirmMsg\r\n myui: \"myui\",\r\n styleByValueField: \"styleByValueField\", //styleByValueField or logic\r\n showDisplayWithMyUI: \"showDisplayWithMyUI\", //custom display bang myui\r\n showClear: \"showClear\", //show nut clear\r\n configClear: \"configClear\",\r\n hideWhenEmpty: \"hideWhenEmpty\",\r\n hideWhenNull: \"hideWhenNull\",\r\n fHideWhenNull: \"fHideWhenNull\",\r\n fHideWhenEmpty: \"fHideWhenEmpty\",\r\n fHide: \"fHide\",\r\n showDeleteRow: \"showDeleteRow\", //show nut clear row o right top bar\r\n showPreviewHTML: \"showPreviewHTML\", //show nut preview HTML\r\n showModalMultiLanguage: \"showModalMultiLanguage\", //bổ sung nút mở màn hình cấu hình ngôn ngữ\r\n configModalMultiLanguage: \"configModalMultiLanguage\",\r\n showTestCanEdit: \"showTestCanEdit\",\r\n configDisplay: \"configDisplay\", //bo sung config display cho cac cell show text\r\n virtualized: \"virtualized\", //ho tru virtualized true/false\r\n virtualizedMin: \"virtualizedMin\", //chuyen qua virtualized khi co min size la bao nhieu\r\n showSelectedOnFirstRow: \"showSelectedOnFirstRow\", //show selected item on first row, select modal\r\n apiCheckShowModal: \"apiCheckShowModal\", //check show modal o form\r\n autoOpenLink: \"autoOpenLink\", // auto open full path\r\n overideDefaultValues: \"overideDefaultValues\", //data truyen len se bao gom default Values, hien tai mac dinh se gom default values nen ko su dung nua\r\n rows: \"rows\",\r\n needReExpand: \"needReExpand\",\r\n needReloadOptionsAndList: \"needReloadOptionsAndList\",\r\n needReloadRow: \"needReloadRow\",\r\n needReload: \"needReload\",\r\n needReloadList: \"needReloadList\",\r\n needReloadTable: \"needReloadTable\",\r\n needReloadPage: \"needReloadPage\",\r\n needReloadListMain: \"needReloadListMain\", //bo sung needReloadListMain cho reload tu table mo tu button modal_page\r\n needReloadOptionsAndListMain: \"needReloadOptionsAndListMain\", //bo sung for main page\r\n needSendMsg: \"needSendMsg\",\r\n configFormat: \"configFormat\", //danh cho config format mac dinh ma cell su dung\r\n configProgress: \"configProgress\", //danh cho progress\r\n configPopover: \"configPopover\", //danh cho co su dung popover\r\n configTitleTooltip: \"configTitleTooltip\", //config title tooltip\r\n canShow: \"canShow\", //co show hay ko tu more\r\n fCanShow: \"fCanShow\",\r\n hideOfIds: \"hideOfIds\", //an dua theo Id\r\n showBlockMobile: \"showBlockMobile\",\r\n configWarning: \"configWarning\", //bo sung show icon warning kem tooltip\r\n alwayShow: \"alwayShow\", //luon muon show cell khi thoa man dieu kien hide\r\n isNegative: \"isNegative\", //bool, cho phép số âm hay không, nếu là false thì ko cho phép\r\n noDecimal: \"noDecimal\",\r\n acceptType: \"acceptType\", //file type dc phep upload\r\n typeInput: \"typeInput\", //chuyen doi textarea va input\r\n typeDisabled: \"typeDisabled\", //chuyen type khac khi disabled\r\n fValue: \"fValue\", //dung xac dinh field Value khi muon thay doi\r\n fText: \"fText\", //dung xac dinh field Text khi muon thay doi\r\n hideZero: \"hideZero\", //an show khi value = 0\r\n fPhoto: \"fPhoto\", //link photo o type link\r\n multi: \"multi\", //dung cho cac kieu select ho tro multi\r\n usingText: \"usingText\", // select_icon\r\n usingIconFont: \"usingIconFont\", // select_icon\r\n styleIcon: \"styleIcon\", // select_icon\r\n styleText: \"styleText\", // select_icon\r\n styleTextarea: \"styleTextarea\",\r\n updateUIRelative: \"updateUIRelative\", //update UI cell khac sau khi update field, string cach nhau dau ,\r\n keyControlDateTime: \"keyControlDateTime\", //luon render child component trong cell khi render cell\r\n fDefaultValues: \"fDefaultValues\",\r\n customDefaultValues: \"customDefaultValues\",\r\n excludeDefaultValues: \"excludeDefaultValues\",\r\n htmlEditorLib: \"htmlEditorLib\",\r\n htmlEditorConfig: \"htmlEditorConfig\",\r\n moreProps: \"moreProps\",\r\n configForm: \"configForm\",\r\n formConfig: \"formConfig\",\r\n fConfigForm: \"fConfigForm\",\r\n canDeselect: \"canDeselect\",\r\n autoTextWB: \"autoTextWB\", //tu dong set color trang den neu co set bgF\r\n styleInherit: \"styleInherit\", //ke thua style tu wrap\r\n editorAddFields: \"editorAddFields\", //danh sách field có thể bỏ vào editor\r\n defaultShowExpand: \"defaultShowExpand\", //dung cho kieu expand\r\n maxChar: \"maxChar\",\r\n maxCharUnicode: \"maxCharUnicode\",\r\n allowOver: \"allowOver\",\r\n pathDataInJsonString: \"pathDataInJsonString\",\r\n useCacheForDOMMeasurements: \"useCacheForDOMMeasurements\", //bat useCacheForDOMMeasurements cho textareafull\r\n needLoadingFullRow: \"needLoadingFullRow\", //loading full row khi update\r\n noReplaceData: \"noReplaceData\", //danh cho kieu getTextWithData ko muon replace data\r\n waitApi: \"waitApi\", // show loading wheen api requesting\r\n animation: \"animation\", //name of animation\r\n customRowBeforeRequest: \"customRowBeforeRequest\", //custom data row before Request\r\n needReloadAfterUpdateFields: \"needReloadAfterUpdateFields\", //bao gom fNeedReloadAfterUpdateFields\r\n}\r\n//more of button\r\nexport const KMB = {\r\n apiCheckShowModal: \"apiCheckShowModal\",\r\n acceptType: \"acceptType\", //upload\r\n apiUrlAfter: \"apiUrlAfter\", //upload\r\n title: \"title\", //show title cua button\r\n tooltip: \"tooltip\", //show tooltip cua button, chua su dung\r\n fQuery: \"fQuery\", //su dung fQuery cho cac query request can thiet: modal type list_check\r\n queryCheckList: \"queryCheckList\", //list_check_api\r\n source: \"source\", //su dung de lay source tu options// modal type list_check\r\n apiCheckList: \"apiCheckList\", //su dung de lay api get list modal type list_check_api\r\n apiSubmit: \"apiSubmit\", //api submit for list_check_api\r\n pathData: \"pathData\", //path Data get list modal type list_check_api\r\n fText: \"fText\", //fText convert to Text modal type list_check_api\r\n fValue: \"fValue\", //fValue convert to Value modal type list_check_api\r\n list: \"list\", //for group\r\n autoOpenLink: \"autoOpenLink\", //open link new window\r\n needShowModalPage: \"needShowModalPage\", //cho type api sau khi goi api\r\n driverjs: \"driverjs\", //config driverjs cho tutor\r\n html: \"html\",\r\n htmlBase64: \"htmlBase64\", //chuyen html qua dang base64 để xài\r\n linkOpen: \"linkOpen\", // them phuong an cho open link after call api thay vi Data.FullPath\r\n}\r\n//more of form\r\nexport const KMF = {\r\n typeWrapControl: \"typeWrapControl\",\r\n defaultConfigWrapControl: \"defaultConfigWrapControl\",\r\n btnSubmit: \"btnSubmit\", //config button submit {title}\r\n btnReset: \"btnReset\",\r\n hideFooter: \"hideFooter\", //an footer\r\n noValidateDefault: \"noValidateDefault\", //tat validate mac dinh\r\n positionButtonsBottom: \"positionButtonsBottom\", //left right\r\n moreButtons: \"moreButtons\", //array button\r\n usingI18n: \"usingI18n\",\r\n configApiAfterChange: \"configApiAfterChange\",\r\n}\r\n//more of control\r\nexport const KMC = {\r\n disabled: \"disabled\",\r\n placeholder: \"placeholder\",\r\n typeWrapControl: \"typeWrapControl\",\r\n configWrapControl: \"configWrapControl\",\r\n multi: \"multi\",\r\n select2: \"select2\", //more props of select2\r\n flatpickr: \"flatpickr\", //more props of flatpickr\r\n items: \"items\", //danh cho cac kieu layout\r\n styleWrapControl: \"styleWrapControl\",\r\n optionKey: \"optionKey\",\r\n isText: \"isText\", //kieu date text\r\n isOnlyTime: \"isOnlyTime\", //only time for date\r\n conditionShow: \"conditionShow\", //condition show\r\n relativeTo: \"relativeTo\", //relativeTo\r\n relativeFrom: \"relativeFrom\", //relativeFrom\r\n effectedBy: \"effectedBy\",\r\n htmlWhenHide: \"htmlWhenHide\", //html when hide\r\n hideCondition: \"hideCondition\",\r\n conditionHide: \"conditionHide\", //tuong tu voi hideCondition\r\n defaultValue: \"defaultValue\", //defaultValue trong truong hop muon co default value rieng\r\n colorType: \"colorType\", //color type dung cho cai kieu su dung warning/success/danger\r\n typeInput: \"typeInput\", // tuong tu typeInput ben cell\r\n apiMethod: \"apiMethod\",\r\n apiUrl: \"apiUrl\", //goi api\r\n mapFields: \"mapFields\", //dung trong kieu select_table_api\r\n extraData: \"extraData\", //dung mo ta extraData khi co table\r\n canAddNewRow: \"canAddNewRow\", //show add new row\r\n defaultObjNewRow: \"defaultObjNewRow\", //obj default khi add new\r\n maxRow: \"maxRow\", //max row can add new\r\n titleAddNewRow: \"titleAddNewRow\",\r\n configClientTable: \"configClientTable\", //config Table\r\n pathData: \"pathData\",\r\n classControl: \"classControl\",\r\n appendComponent: \"appendComponent\",\r\n prependComponent: \"prependComponent\",\r\n configAppend: \"configAppend\",\r\n configPrepend: \"configPrepend\",\r\n hint: \"hint\",\r\n required: \"required\",\r\n showRequiredMsg: \"showRequiredMsg\",\r\n requiredMsg: \"requiredMsg\",\r\n invalidMsg: \"invalidMsg\", //msg show khi bi invalid\r\n step: \"step\",\r\n sameChange: \"sameChange\", //se thay doi gia tri field tuong ung voi field o OptionItem {fNeedChange:fInOptionItem}\r\n hideVisibility: \"hideVisibility\", // ==true se hide bang cach gan style hideVisibility = hidden\r\n noNegative: \"noNegative\",\r\n noDecimal: \"noDecimal\",\r\n maxData: \"maxData\", //dung cho cai kieu select show ra bi chan neu data bi nhieu\r\n styleBase: \"styleBase\", //style cua Base control\r\n style: \"style\",\r\n showSearch: \"showSearch\",\r\n htmlEditorLib: \"htmlEditorLib\",\r\n morePropsCK5: \"morePropsCK5\",\r\n hideZero: \"hideZero\",\r\n hideNull: \"hideNull\", //khi gia tri default la null thi show rỗng thay vi để số 0\r\n min: \"min\",\r\n max: \"max\",\r\n prefix: \"prefix\",\r\n suffix: \"suffix\",\r\n theme: \"theme\",\r\n allowEnterToSubmit: \"allowEnterToSubmit\",\r\n submitOnChange: \"submitOnChange\",\r\n clickToSelect: \"clickToSelect\",\r\n usingColorOptions: \"usingColorOptions\",\r\n configApiSourceData: \"configApiSourceData\",\r\n}\r\nconst moreOfNumeral = [\r\n KMC.hideZero,\r\n KMC.hideNull,\r\n KMC.min,\r\n KMC.max,\r\n KMC.prefix,\r\n KMC.suffix,\r\n KMC.allowEnterToSubmit,\r\n KMC.noDecimal,\r\n]\r\nexport const FlowGetMoreForNumeral = (more = {}) => {\r\n let _more = {}\r\n for (let k of moreOfNumeral) {\r\n if (more.hasOwnProperty(k)) {\r\n _more[k] = more[k]\r\n }\r\n }\r\n return _more\r\n}\r\n\r\nexport const FlowGetStringOfMoreFromRow = ({ key, row, more, df } = {}) => {\r\n let _value = df\r\n let _fKey = `f${key.charAt(0).toUpperCase() + key.slice(1)}`\r\n if (row && more[_fKey] && row.hasOwnProperty(more[_fKey])) {\r\n _value = row[more[_fKey]]\r\n } else if (more.hasOwnProperty(key)) {\r\n _value = more[key]\r\n }\r\n return _value\r\n}\r\n\r\nexport const FlowGetBoolOfMoreFromRow = ({ key, row, more, df } = {}) => {\r\n let _value = df || false\r\n let _fKey = `f${key.charAt(0).toUpperCase() + key.slice(1)}`\r\n if (row && more[_fKey] && row.hasOwnProperty(more[_fKey])) {\r\n _value = row[more[_fKey]]\r\n } else if (more.hasOwnProperty(key)) {\r\n _value = more[key]\r\n }\r\n return _value\r\n}\r\n\r\nexport const FlowGetConfigOfMoreFromRow = ({\r\n key,\r\n row,\r\n more,\r\n df,\r\n parseConfig,\r\n} = {}) => {\r\n let _config = { ...df }\r\n if (key && key.length > 0) {\r\n let _configKey = `config${key.charAt(0).toUpperCase() + key.slice(1)}`\r\n let _fKey = `f${key.charAt(0).toUpperCase() + key.slice(1)}`\r\n if (row && more[_fKey] && row.hasOwnProperty(more[_fKey])) {\r\n _config.value = row[more[_fKey]]\r\n _config.show = true\r\n } else if (more.hasOwnProperty(key)) {\r\n _config.value = more[key]\r\n _config.show = true\r\n }\r\n\r\n if (more[_configKey]) {\r\n if (parseConfig) {\r\n parseConfig({ config: more[_configKey], row })\r\n }\r\n _config = { ..._config, ...more[_configKey] }\r\n if (\r\n row &&\r\n more[_configKey][_fKey] &&\r\n row.hasOwnProperty(more[_configKey][_fKey])\r\n ) {\r\n _config.value = row[more[_configKey][_fKey]]\r\n _config.show = true\r\n } else if (more[_configKey].hasOwnProperty(key)) {\r\n _config.value = more[_configKey][key]\r\n _config.show = true\r\n }\r\n }\r\n }\r\n return _config\r\n}\r\n","import { toast } from \"react-toastify\"\r\nimport { MyDialog } from \"src/core/components\"\r\nimport { HIs, HCF, HUI } from \"@macashipo/mlib\"\r\nimport { KUI } from \"src/helpers/K\"\r\nconst configToast = {\r\n hideProgressBar: true,\r\n pauseOnHover: true,\r\n autoClose: 2000,\r\n}\r\n\r\nconst ToastType = {\r\n success: \"success\",\r\n warn: \"warn\",\r\n warning: \"warning\",\r\n info: \"info\",\r\n error: \"error\",\r\n}\r\n\r\nexport const showToast = (msg, options: any = {}) => {\r\n let _options = { ...configToast, ...options }\r\n let _type = options.type || ToastType.success\r\n //check first msg\r\n if (HIs.isString(msg)) {\r\n if (msg.startsWith(\"[Warning]\")) {\r\n msg = msg.replace(\"[Warning]\", \"\")\r\n _type = ToastType.warning\r\n } else if (msg.startsWith(\"[Error]\")) {\r\n msg = msg.replace(\"[Error]\", \"\")\r\n _type = ToastType.error\r\n }\r\n }\r\n switch (_type) {\r\n case ToastType.success:\r\n toast.success(msg, _options)\r\n break\r\n case ToastType.warn:\r\n toast.warn(msg, _options)\r\n break\r\n case ToastType.warning:\r\n toast.warn(msg, _options)\r\n break\r\n case ToastType.info:\r\n toast.info(msg, _options)\r\n break\r\n case ToastType.error:\r\n toast.error(msg, _options)\r\n break\r\n }\r\n}\r\n\r\nexport const showToastWithCheckMsg = (msg, defaultType = ToastType.success) => {\r\n if (msg) {\r\n if (msg.startsWith(\"[\")) {\r\n if (msg.startsWith(\"[Warning]\")) {\r\n showToast(msg.replace(\"[Warning]\", \"\"), {\r\n type: ToastType.warning,\r\n })\r\n } else if (msg.startsWith(\"[Error]\")) {\r\n showToast(msg.replace(\"[Error]\", \"\"), {\r\n type: ToastType.error,\r\n })\r\n } else if (msg.startsWith(\"[Info]\")) {\r\n showToast(msg.replace(\"[Info]\", \"\"), {\r\n type: ToastType.info,\r\n })\r\n } else if (msg.startsWith(\"[Success]\")) {\r\n showToast(msg.replace(\"[Success]\", \"\"), {\r\n type: ToastType.success,\r\n })\r\n } else if (msg.startsWith(\"[Alert]\")) {\r\n showDialog({\r\n title: HCF.getCF(\"title\") || \"Notice\",\r\n msg: msg.replace(\"[Alert]\", \"\"),\r\n })\r\n } else if (msg.startsWith(\"[System]\") && window.alert) {\r\n window.alert(msg.replace(\"[System]\", \"\"))\r\n } else {\r\n showToast(msg, {\r\n type: defaultType,\r\n })\r\n }\r\n } else {\r\n showToast(msg, {\r\n type: defaultType,\r\n })\r\n }\r\n }\r\n}\r\n\r\nexport const showToastSuccess = msg => {\r\n showToastWithCheckMsg(msg, ToastType.success)\r\n}\r\n\r\nexport const showToastWarning = msg => {\r\n showToastWithCheckMsg(msg, ToastType.warning)\r\n}\r\n\r\nexport const showToastError = msg => {\r\n showToastWithCheckMsg(msg, ToastType.error)\r\n}\r\n\r\nexport const showToastLikeToast = msg => {\r\n if (msg) {\r\n showToast(msg, {\r\n type: ToastType.success,\r\n position: toast.POSITION.BOTTOM_CENTER,\r\n style: {\r\n background: \"black\",\r\n color: \"white\",\r\n },\r\n })\r\n }\r\n}\r\n\r\nexport const showApiMsg = msg => {\r\n if (msg) {\r\n showToastSuccess(msg)\r\n }\r\n}\r\n\r\nexport const hideInMyModalFromProps = props => {\r\n if (props && props.inMyModal && props.inMyModal.hide) {\r\n props.inMyModal.hide()\r\n }\r\n}\r\n\r\nexport const showDialog = (configDialog: any) => {\r\n console.warn(\"showDialog\", configDialog)\r\n MyDialog.show({\r\n ...configDialog,\r\n })\r\n}\r\n\r\nexport const showConfirm = (configDialog: any) => {\r\n console.warn(\"showConfirm\", configDialog)\r\n MyDialog.showConfirm({\r\n ...configDialog,\r\n })\r\n}\r\n\r\nexport const showLoadingScreen = () => {\r\n var dom_firstLoading = document.getElementById(\"first_loading\")\r\n if (dom_firstLoading) {\r\n dom_firstLoading.style.visibility = \"visible\"\r\n dom_firstLoading.style.zIndex = \"1000\"\r\n }\r\n}\r\nexport const hideLoadingScreen = () => {\r\n var dom_firstLoading = document.getElementById(\"first_loading\")\r\n if (dom_firstLoading) {\r\n dom_firstLoading.style.visibility = \"hidden\"\r\n }\r\n}\r\n\r\nHUI.showLoadingScreen = showLoadingScreen\r\nHUI[\"hideLoadingScreen\"] = hideLoadingScreen\r\n\r\nHCF.setCF(KUI.fnShowToast, showToast)\r\nHCF.setCF(KUI.fnshowDialog, showDialog)\r\nHCF.setCF(KUI.fnshowConfirm, showConfirm)\r\nwindow[\"showToastWithCheckMsg\"] = showToastWithCheckMsg\r\n","//version: 20221207\r\nimport { saveObj, saveString, getString, getObj } from \"./localStorage\"\r\nimport { mergeObjIfExist } from \"./utils\"\r\nimport ImgAvatar from \"src/assets/images/avatar.jpg\"\r\nimport V from \"src/helpers/V\"\r\nimport { HCF } from \"@macashipo/mlib\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nimport { KAuth } from \"src/helpers/Flows/Auth\"\r\nimport HI18 from \"./i18n\"\r\nconst AuthInfo: any = {\r\n kAuthToken: \"Auth-Token\",\r\n kAuthType: \"Auth-Type\",\r\n kAuthInfo: \"Auth-Info\",\r\n kAuthInfoSocial: \"Auth-InfoSocial\",\r\n token: \"\",\r\n type: \"Bearer\",\r\n info: {},\r\n infoSocial: null,\r\n info2FA: {},\r\n checkBeforeLogout: {},\r\n listAfterLogout: {},\r\n}\r\n\r\nconst AuthConfig: IAuthConfig = {\r\n afterLogout: () => {},\r\n afterLogin: () => {},\r\n}\r\n\r\nexport const initAuth = (config?: IAuthConfig) => {\r\n mergeObjIfExist(AuthConfig, config)\r\n loadLastSaved()\r\n HCF.setCF(KAuth.fnUpdateAuthInfo, authInfo => {\r\n console.log(\"update AuthInfo\", authInfo)\r\n if (authInfo) {\r\n AuthInfo.info = Object.assign(AuthInfo.info, authInfo)\r\n }\r\n })\r\n}\r\nexport const authCheckSavedAuthorized = () => {\r\n let _token = getString(AuthInfo.kAuthToken, \"\")\r\n if (_token) {\r\n return true\r\n }\r\n return false\r\n}\r\n\r\nexport const authGetAuthorizationHeader = () => {\r\n // console.warn(\"authGetAuthorizationHeader:\", AuthInfo)\r\n if (AuthInfo.token) {\r\n return `${AuthInfo.type} ${AuthInfo.token}`\r\n }\r\n}\r\n\r\nexport const registerCheckBeforeLogout = (key, fn) => {\r\n if (key) {\r\n if (fn) {\r\n AuthInfo.checkBeforeLogout[key] = fn\r\n } else {\r\n delete AuthInfo.checkBeforeLogout[key]\r\n }\r\n }\r\n}\r\nexport const registerAfterLogout = (key, fn) => {\r\n if (key) {\r\n if (fn) {\r\n AuthInfo.listAfterLogout[key] = fn\r\n } else {\r\n delete AuthInfo.listAfterLogout[key]\r\n }\r\n }\r\n}\r\nexport const checkBeforeLogout = () => {\r\n if (AuthInfo.checkBeforeLogout) {\r\n for (let k of Object.keys(AuthInfo.checkBeforeLogout)) {\r\n let _fn = AuthInfo.checkBeforeLogout[k]\r\n if (_fn) {\r\n let _check = _fn()\r\n if (_check === false) {\r\n return false\r\n }\r\n }\r\n }\r\n }\r\n return true\r\n}\r\n\r\nconst loadLastSaved = () => {\r\n // AuthInfo.auth = data;\r\n let _obj = {\r\n type: getString(AuthInfo.kAuthType, AuthInfo.type),\r\n token: getString(AuthInfo.kAuthToken, \"\"),\r\n info: getObj(AuthInfo.kAuthInfo, {}),\r\n }\r\n if (_obj.token) {\r\n authLogin(_obj)\r\n }\r\n}\r\nconst savedLocal = () => {\r\n saveString(AuthInfo.kAuthType, AuthInfo.type)\r\n saveString(AuthInfo.kAuthToken, AuthInfo.token)\r\n saveObj(AuthInfo.kAuthInfo, AuthInfo.info)\r\n HCF.setCF(KConfigApp.AuthInfo, AuthInfo.info)\r\n V.Auth_ParseAuthInfo(AuthInfo.info)\r\n}\r\n\r\nexport const authLogin = (data: IAuth) => {\r\n mergeObjIfExist(AuthInfo, data)\r\n savedLocal()\r\n // console.warn(\"authLogin:\", data)\r\n if (AuthConfig.afterLogin) {\r\n AuthConfig.afterLogin()\r\n }\r\n}\r\n\r\nconst getInfoFromData = function (data: any) {\r\n let _info = {}\r\n for (let k of Object.keys(data)) {\r\n if (k !== \"access_token\" && k !== \"token_type\") {\r\n _info[k] = data[k]\r\n }\r\n }\r\n return _info\r\n}\r\nconst parse2FAfromData = function (data: any) {\r\n if (data) {\r\n AuthInfo.info2FA[\"fa2_needenable\"] = data.fa2_needenable\r\n AuthInfo.info2FA[\"fa2_needverify\"] = data.fa2_needverify\r\n AuthInfo.info2FA[\"fa2_token\"] = data.fa2_token\r\n AuthInfo.info2FA[\"user_uniqueid\"] = data.user_uniqueid\r\n AuthInfo.info2FA[\"user_id\"] = data.user_id\r\n AuthInfo.info2FA[\"fa2_method\"] = data.fa2_method\r\n }\r\n}\r\nexport const authLoginWithRes = (data: any): boolean => {\r\n console.warn(\"authLoginWithRes:\", data)\r\n parse2FAfromData(data)\r\n console.warn(\"AuthInfo.info2FA:\", AuthInfo.info2FA)\r\n if (data && data.access_token) {\r\n let _info = getInfoFromData(data)\r\n let _obj = {\r\n token: data.access_token,\r\n type: data.token_type,\r\n info: _info,\r\n }\r\n if (_info[\"language_code\"]) {\r\n HI18.changeLanguage(_info[\"language_code\"], true)\r\n }\r\n authLogin(_obj)\r\n return true\r\n }\r\n return false\r\n}\r\nexport const authLoginSocialWithRes = (data: any): boolean => {\r\n if (data) {\r\n if (data.Token) {\r\n parse2FAfromData(data.Token)\r\n }\r\n if (data.Token && data.Token.access_token) {\r\n let _info = getInfoFromData(data.Token)\r\n let _obj = {\r\n token: data.Token.access_token,\r\n type: data.Token.token_type,\r\n info: _info,\r\n infoSocial: data.SocialInfo,\r\n }\r\n authLogin(_obj)\r\n return true\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport const authLogoutWithNothing = () => {\r\n localStorage.removeItem(AuthInfo.kAuthToken)\r\n localStorage.removeItem(AuthInfo.kAuthInfo)\r\n localStorage.removeItem(AuthInfo.kAuthType)\r\n AuthInfo.info2FA = {}\r\n AuthInfo.info = {}\r\n AuthInfo.token = \"\"\r\n}\r\n\r\nconst afterLogout = () => {\r\n if (AuthConfig.afterLogout) {\r\n AuthConfig.afterLogout()\r\n }\r\n if (AuthInfo.listAfterLogout) {\r\n for (let k of Object.keys(AuthInfo.listAfterLogout)) {\r\n let _fn = AuthInfo.listAfterLogout[k]\r\n if (_fn) {\r\n _fn()\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport const authLogout = () => {\r\n authLogoutWithNothing()\r\n afterLogout()\r\n}\r\n\r\nexport const authIsLogged = () => {\r\n return AuthInfo.token ? true : false\r\n}\r\n\r\n//danh cho viec da logout, nhung login o 1 tabkhac, khi quay lai can check lai localstorage\r\nexport const authCheckLoginAgain = () => {\r\n var _tk = localStorage.getItem(AuthInfo.kAuthToken)\r\n if (_tk) {\r\n let _obj = {\r\n type: getString(AuthInfo.kAuthType, AuthInfo.type),\r\n token: getString(AuthInfo.kAuthToken, \"\"),\r\n info: getObj(AuthInfo.kAuthInfo, {}),\r\n }\r\n mergeObjIfExist(AuthInfo, _obj)\r\n }\r\n return AuthInfo.token ? true : false\r\n}\r\n\r\nexport const getUserInfo = (): any => {\r\n return AuthInfo.info\r\n}\r\n\r\nexport const getInfo2FA = () => {\r\n return AuthInfo.info2FA\r\n}\r\n\r\nexport const getUserID = () => {\r\n return getUserInfo()?.user_id\r\n}\r\n\r\nexport const getUserName = () => {\r\n return getUserInfo()?.name\r\n}\r\n\r\nexport const getUserEmail = () => {\r\n return getUserInfo()?.user_name\r\n}\r\n\r\nexport const getUserAvatar = () => {\r\n if (getUserInfo() && getUserInfo()[\"avatar_url\"]) {\r\n return getUserInfo()?.avatar_url\r\n }\r\n return ImgAvatar\r\n}\r\n\r\nexport const getUserLogoApp = () => {\r\n return getUserInfo()?.appLogo_url\r\n}\r\n\r\nexport const checkShow2FAFromTokenResponse = resToken => {\r\n if (resToken) {\r\n if (resToken.fa2_needenable || resToken.fa2_needverify) {\r\n return true\r\n }\r\n }\r\n return false\r\n}\r\n","import {\r\n HCF,\r\n HJson,\r\n HUtils,\r\n MyTableCellHelpers,\r\n MyTableHeader,\r\n MyTableHeaderHelpers,\r\n} from \"@macashipo/mlib\"\r\nimport {\r\n fnListMyPage,\r\n fnListConfigApp,\r\n fnGetConfigTable,\r\n kfnGetColumnSelect,\r\n} from \"./fnList\"\r\nimport { KConfigPageTable } from \"./K\"\r\nimport * as FlowTableExpand from \"./Flows/TableExpand\"\r\nimport * as FlowTableExtraData from \"./Flows/TableExtraData\"\r\nimport * as FlowTableCell from \"./Flows/TableCell\"\r\nimport * as FlowTableFilter from \"./Flows/TableFilter\"\r\nimport * as FlowAuth from \"./Flows/Auth\"\r\nimport * as FlowRoutes from \"./Flows/Routes\"\r\nimport * as FlowVer from \"./FlowV3\"\r\nimport * as FlowPage from \"./Flows/Page\"\r\nimport * as FlowApi from \"./Flows/Api\"\r\nimport * as FlowMNeedUpdateMLib from \"./Flows/MNeedUpdateMLib\"\r\nimport * as FlowFormControl from \"./Flows/FormControl\"\r\nconst {\r\n DefaultWidthID,\r\n DefaultWidthCol,\r\n DefaultWidthColExpand,\r\n DefaultWidthColDelete,\r\n} = FlowVer\r\n\r\n// fnList bat buoc:\r\n// - fnGetConfigPageTable\r\n// - fnGetConfigPageDetail\r\n\r\nexport {\r\n FlowAuth,\r\n FlowTableExpand,\r\n FlowTableExtraData,\r\n FlowTableCell,\r\n FlowTableFilter,\r\n FlowRoutes,\r\n FlowPage,\r\n FlowApi,\r\n FlowMNeedUpdateMLib,\r\n FlowFormControl,\r\n}\r\nexport const FlowBuildColTable_BuildExtraColumns = ({\r\n extraData,\r\n fnList,\r\n sourceList,\r\n}) => {\r\n let _addExtraColumns =\r\n fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.addExtraColumns,\r\n ]) || {}\r\n //column select modal\r\n if (fnList && fnList[kfnGetColumnSelect]) {\r\n let _configColumnSelect = fnList[kfnGetColumnSelect]()\r\n if (_configColumnSelect) {\r\n _addExtraColumns[\"_ColSelectOnModal\"] = _configColumnSelect\r\n }\r\n }\r\n //column expand\r\n let _showDetails = fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.showDetails,\r\n ])\r\n let _showDetailsMulti = fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.showDetailsMulti,\r\n ])\r\n if (_showDetails || _showDetailsMulti) {\r\n let _detailConfig = fnListMyPage.fnGetConfigPageDetail(fnList, [])\r\n if (_detailConfig) {\r\n try {\r\n _detailConfig = JSON.stringify(_detailConfig)\r\n _addExtraColumns[\"_ColExpandMulti\"] = {\r\n Type: { type: \"expand_multi\", more: _detailConfig },\r\n Index: 0,\r\n CanShow: true,\r\n CanEdit: false,\r\n CanSort: false,\r\n Header: \" \",\r\n Width: DefaultWidthColExpand,\r\n }\r\n } catch (error) {\r\n console.warn(\"Error JSON\", error, _detailConfig)\r\n }\r\n }\r\n }\r\n //column action\r\n //column action menu\r\n let _configColsActions = fnGetConfigTable(\r\n fnList,\r\n KConfigPageTable.colsActions\r\n )\r\n if (_configColsActions) {\r\n if (_configColsActions.show === true) {\r\n _addExtraColumns[\"_colActions\"] = {\r\n Type: {\r\n type: \"actions_menu\",\r\n more: HJson.getString(_configColsActions),\r\n },\r\n CanShow: true,\r\n CanEdit: false,\r\n CanSort: false,\r\n Header: \" \",\r\n Width: DefaultWidthColExpand,\r\n }\r\n }\r\n }\r\n //column remove for table form table\r\n if (\r\n fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.showColRemoveRow,\r\n ]) === true\r\n ) {\r\n _addExtraColumns[\"_ActionRemove\"] = {\r\n Type: { type: \"remove_row\" },\r\n Index: 999,\r\n CanShow: true,\r\n CanEdit: true,\r\n CanSort: false,\r\n Header: `{\"type\":\"styled\",\"header\":\" \"}`,\r\n CanPrint: false,\r\n Width: DefaultWidthColDelete,\r\n }\r\n }\r\n //column delete\r\n if (\r\n fnListMyPage.fnGetConfigPageTable(fnList, [KConfigPageTable.canDelete]) !==\r\n false\r\n ) {\r\n let _isHideColDelete = false\r\n if (\r\n fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.hideColDelete,\r\n ]) === true\r\n ) {\r\n _isHideColDelete = true\r\n }\r\n if (\r\n fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.hideColDeleteOnSmallWidth,\r\n ]) === true &&\r\n fnListConfigApp.getIsMobileByWidth()\r\n ) {\r\n _isHideColDelete = true\r\n }\r\n if (_isHideColDelete !== true) {\r\n let _typeCell = { type: \"delete\" }\r\n let _customDelete =\r\n fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.customDelete,\r\n ]) || {}\r\n let _width = HUtils.get(_customDelete, \"width\") || DefaultWidthColDelete\r\n if (_customDelete) {\r\n let _type = HUtils.get(_customDelete, \"type\")\r\n let _more = HUtils.get(_customDelete, \"more\")\r\n if (_type) {\r\n _typeCell.type = _type\r\n }\r\n if (_more) {\r\n _typeCell.more = _more\r\n }\r\n }\r\n _addExtraColumns[\"_ActionDelete\"] = {\r\n Type: _typeCell,\r\n Index: 1000,\r\n CanShow: true,\r\n CanEdit: true,\r\n CanSort: false,\r\n Header: `{\"type\":\"styled\",\"header\":\" \"}`,\r\n CanPrint: false,\r\n Width: _width,\r\n }\r\n }\r\n }\r\n //return\r\n return _addExtraColumns\r\n}\r\nexport const FlowBuildColTable_BuildOneCol_ParseCustomProps = ({\r\n colExtra,\r\n colConfig = {},\r\n fieldName,\r\n customProps,\r\n customType,\r\n} = {}) => {\r\n let _fieldName = fieldName\r\n //\r\n if (customProps != null && customProps[\"_Arr\"] != null) {\r\n let _regex = customProps[\"_Arr\"].regex\r\n let _test = _regex.test(_fieldName)\r\n if (_test == true) {\r\n colConfig.colProps = Object.assign(\r\n colConfig.colProps,\r\n customProps[\"_Arr\"].props\r\n )\r\n }\r\n }\r\n if (customProps != null && customProps[_fieldName] != null) {\r\n colConfig.colProps = Object.assign(\r\n colConfig.colProps,\r\n customProps[_fieldName]\r\n )\r\n }\r\n if (customType != null && customType[_fieldName] != null) {\r\n colExtra.Type = Object.assign(colExtra.Type, customType[_fieldName])\r\n }\r\n}\r\nexport const FlowBuildColTable_BuildOneCol_ParseColWidth = ({\r\n colExtra,\r\n colConfig = {},\r\n} = {}) => {\r\n let _item = colExtra\r\n //\r\n if (_item.MWAS && _item.MWASD) {\r\n let _w = window.innerWidth > _item.MWAS ? \"100%\" : _item.MWASD + \"px\"\r\n colConfig.width = _w\r\n }\r\n}\r\nexport const FlowBuildColTable_BuildOneCol_ParseHeader = ({\r\n colExtra,\r\n colConfig = {},\r\n extraData,\r\n fnList,\r\n} = {}) => {\r\n let _item = colExtra\r\n //\r\n if (_item.CanSort != null) {\r\n colConfig.colProps.dataSort = _item.CanSort\r\n }\r\n if (_item.CanPrint === false) {\r\n colConfig.columnClassName =\r\n colConfig.columnClassName || \"\" + \" no-print-col\"\r\n colConfig.className = colConfig.className || \"\" + \" no-print-col\"\r\n }\r\n if (_item.Cls != null) {\r\n colConfig.className = colConfig.className || \"\" + \" \" + _item.Cls\r\n }\r\n if (_item.CCls != null) {\r\n colConfig.columnClassName =\r\n colConfig.columnClassName || \"\" + \" \" + _item.CCls\r\n }\r\n if (_item.Width == \"hidden\" || _item.Width == \"-1px\") {\r\n colConfig.hidden = true\r\n }\r\n //parse json header\r\n if (_item.Header && _item.Header.startsWith(\"{\")) {\r\n try {\r\n _item._HeaderObj = JSON.parse(_item.Header)\r\n let _headerObj = _item._HeaderObj\r\n if (_headerObj) {\r\n //\r\n // console.warn(\"render header:\", _headerObj)\r\n colConfig.header = _headerObj.title || _headerObj.header || \"\"\r\n colConfig.colProps.headerText = _headerObj.header || colConfig.header //bo sung title cho column\r\n if (_headerObj.type) {\r\n // colConfig.header = (\r\n //
\r\n // {colConfig.header}\r\n //
\r\n // )\r\n if (_headerObj.type && MyTableHeaderHelpers.Types[_headerObj.type]) {\r\n colConfig.colProps.componentHeader = (header, fieldName) => {\r\n // console.warn(\"style header:\", header, fieldName, _headerObj)\r\n return (\r\n \r\n )\r\n }\r\n }\r\n }\r\n if (_headerObj.hideSort) {\r\n colConfig.colProps.caretRender = (sort, dataField) => {\r\n return
\r\n }\r\n }\r\n if (\r\n _headerObj.canSort != null &&\r\n typeof _headerObj.canSort == \"boolean\"\r\n ) {\r\n colConfig.colProps.dataSort = _headerObj.canSort\r\n }\r\n if (_headerObj.canPrint === false) {\r\n colConfig.columnClassName =\r\n colConfig.columnClassName || \"\" + \" no-print-col\"\r\n colConfig.className = colConfig.className || \"\" + \" no-print-col\"\r\n }\r\n if (_headerObj.Cls != null) {\r\n colConfig.className = colConfig.className || \"\" + \" \" + _headerObj.Cls\r\n }\r\n if (_headerObj.CCls != null) {\r\n colConfig.columnClassName =\r\n colConfig.columnClassName || \"\" + \" \" + _headerObj.CCls\r\n }\r\n if (_headerObj.hidden) {\r\n colConfig.hidden = true\r\n }\r\n if (_headerObj.moreColProps) {\r\n Object.assign(colConfig.colProps, _headerObj.moreColProps)\r\n }\r\n }\r\n } catch (error) {\r\n console.warn(\"error JSON\", error, _item, _item.Header)\r\n }\r\n }\r\n}\r\nexport const FlowBuildColTable_BuildOneCol = ({\r\n extraData,\r\n colExtra,\r\n fieldName,\r\n fnList,\r\n sourceList,\r\n fieldId,\r\n showID,\r\n excludeFieldName,\r\n columnClassName,\r\n defaultFormatColumn,\r\n customProps,\r\n customType,\r\n}) => {\r\n let _col = {}\r\n let _item = colExtra\r\n let _fieldName = fieldName\r\n //check fieldID\r\n if (_fieldName == fieldId) {\r\n let _hidden = true\r\n if (showID != null && showID == true) {\r\n _hidden = false\r\n }\r\n if (_hidden == true) {\r\n _col = {\r\n width: DefaultWidthID,\r\n hidden: true,\r\n isKey: true,\r\n dataField: fieldId,\r\n orderNo: _item.OrderNo,\r\n header: \"ID\",\r\n }\r\n } else {\r\n _col = {\r\n width: _item.Width || DefaultWidthID,\r\n hidden: false,\r\n isKey: true,\r\n dataField: fieldId,\r\n orderNo: _item.OrderNo,\r\n header: _item.Header || _fieldName,\r\n }\r\n }\r\n } else {\r\n if (excludeFieldName != null && excludeFieldName.indexOf(_fieldName) > -1) {\r\n return null\r\n } else if (_item.CanShow == true) {\r\n _col = {\r\n width: _item.Width || DefaultWidthCol,\r\n dataField: _fieldName,\r\n orderNo: _item.OrderNo,\r\n header: _item.Header || _fieldName,\r\n colProps: {},\r\n }\r\n\r\n //\r\n if (columnClassName != null) {\r\n _col.columnClassName = columnClassName\r\n }\r\n if (defaultFormatColumn != null) {\r\n _col.dataFormat = defaultFormatColumn\r\n } else {\r\n if (MyTableCellHelpers.Types._auto) {\r\n _col.dataFormat = MyTableCellHelpers.Types._auto //auto parse type\r\n } else {\r\n _col.dataFormat = MyTableCellHelpers.Types._empty\r\n }\r\n }\r\n\r\n //parse header\r\n FlowBuildColTable_BuildOneCol_ParseHeader({\r\n colExtra,\r\n colConfig: _col,\r\n extraData,\r\n fnList,\r\n })\r\n //parse width column\r\n FlowBuildColTable_BuildOneCol_ParseColWidth({ colExtra, colConfig: _col })\r\n //parse custom props\r\n FlowBuildColTable_BuildOneCol_ParseCustomProps({\r\n colExtra,\r\n colConfig: _col,\r\n customProps,\r\n customType,\r\n fieldName,\r\n })\r\n //format Extra Data\r\n let _formatExtraData = {\r\n fieldName: _fieldName,\r\n extraData: extraData,\r\n sourceList: sourceList || {},\r\n fnList: fnList || {},\r\n }\r\n _formatExtraData = Object.assign(_formatExtraData, _item)\r\n _col.colProps.formatExtraData = _formatExtraData\r\n //\r\n }\r\n }\r\n return _col\r\n}\r\nexport const FlowBuildColTableFromExtraData = ({\r\n extraData,\r\n fieldId = \"Id\",\r\n sourceList,\r\n fnList = {},\r\n showID = false,\r\n excludeFieldName = [],\r\n columnClassName,\r\n defaultFormatColumn,\r\n customProps,\r\n customType,\r\n configTable = {},\r\n} = {}) => {\r\n // console.log(\"\\n\\n\\nFlowBuildColTableFromExtraData\\n\\n\\n\")\r\n let _cols = []\r\n let _extraColumns = {}\r\n if (extraData && extraData.Columns) {\r\n _extraColumns = extraData.Columns\r\n } else {\r\n //return empty\r\n return _cols\r\n }\r\n //build addExtraColumns\r\n let _addExtraColumns = FlowBuildColTable_BuildExtraColumns({\r\n extraData,\r\n sourceList,\r\n fnList,\r\n })\r\n if (_addExtraColumns) {\r\n for (let k of Object.keys(_addExtraColumns)) {\r\n _extraColumns[k] = _addExtraColumns[k]\r\n }\r\n }\r\n //build cols\r\n let _arrColumns = Object.keys(_extraColumns)\r\n // console.log(\"_arrColumns:\", _arrColumns)\r\n for (let i = 0; i < _arrColumns.length; i++) {\r\n let _fieldName = _arrColumns[i]\r\n let _colExtra = _extraColumns[_fieldName]\r\n let _col = FlowBuildColTable_BuildOneCol({\r\n extraData,\r\n colExtra: _colExtra,\r\n fieldName: _fieldName,\r\n fnList,\r\n sourceList,\r\n fieldId,\r\n showID,\r\n excludeFieldName,\r\n columnClassName,\r\n defaultFormatColumn,\r\n customProps,\r\n customType,\r\n })\r\n if (_col && _col.dataField) {\r\n if (_colExtra.Index != null) {\r\n if (_colExtra.Index == 0) {\r\n _cols.unshift(_col)\r\n } else {\r\n _cols.push(_col)\r\n }\r\n } else {\r\n _cols.push(_col)\r\n }\r\n }\r\n }\r\n if (configTable && configTable[KConfigPageTable.usingOrderNo]) {\r\n _cols = FlowMNeedUpdateMLib.getDataBySort(_cols, \"orderNo\")\r\n console.log(\"after sort:\", _cols)\r\n }\r\n //return\r\n return _cols\r\n}\r\n\r\n// colsHide: IsShow, FieldName, GroupFields\r\nexport const FlowFilterColsWithHidden = ({ cols, columnsFilterList } = {}) => {\r\n let _colsHide = columnsFilterList.filter(v => v.IsShow === false)\r\n let _cols = cols\r\n for (let i = 0; i < _colsHide.length; i++) {\r\n _cols = _cols.filter(v => {\r\n if (_colsHide[i].FieldName) {\r\n return v.dataField !== _colsHide[i].FieldName\r\n } else if (_colsHide[i].GroupFields) {\r\n return _colsHide[i].GroupFields.indexOf(v.dataField) == -1\r\n ? true\r\n : false\r\n }\r\n return true\r\n })\r\n }\r\n return _cols\r\n}\r\n\r\nconst getConfigColumnHide = (extraData, fieldName) => {\r\n let _configFilter = FlowTableExtraData.FlowGetMoreFilterOfCellFromExtraData(\r\n extraData,\r\n fieldName\r\n )\r\n if (_configFilter && _configFilter.columnHide) {\r\n return _configFilter.columnHide\r\n }\r\n}\r\n\r\nexport const FlowBuildColumnHidden = ({ cols, extraData }) => {\r\n if (cols) {\r\n let _cFL = []\r\n let _group = {}\r\n for (let i = 0; i < cols.length; i++) {\r\n const _item = cols[i]\r\n if (_item.dataField !== \"Id\" && !_item.dataField.startsWith(\"_\")) {\r\n let _configColumnHide =\r\n getConfigColumnHide(extraData, _item.dataField) || {}\r\n if (_configColumnHide.show !== false) {\r\n if (_configColumnHide.group) {\r\n if (_group[_configColumnHide.group] == null) {\r\n _group[_configColumnHide.group] = {\r\n Title: _configColumnHide.group,\r\n GroupFields: [_item.dataField],\r\n IsShow: _configColumnHide.isDefautHide === true ? false : true,\r\n Styles: _configColumnHide.style,\r\n }\r\n _cFL.push(_group[_configColumnHide.group])\r\n } else {\r\n _group[_configColumnHide.group].GroupFields.push(_item.dataField)\r\n }\r\n } else {\r\n let _obj = {\r\n Title: _item.header || _item.dataField,\r\n IsShow:\r\n _configColumnHide.isDefautHide === true\r\n ? false\r\n : _item.isDefautHide === true\r\n ? false\r\n : true,\r\n FieldName: _item.dataField,\r\n Styles: _configColumnHide.style,\r\n }\r\n _cFL.push(_obj)\r\n }\r\n }\r\n }\r\n }\r\n console.warn(\"cFL\", _cFL)\r\n return _cFL\r\n }\r\n}\r\n\r\nexport const FlowGetClassNameTable = (fnList = {}) => {\r\n let _configPageTable = fnListMyPage.fnGetConfigPageTable(fnList, [])\r\n let _className =\r\n _configPageTable[KConfigPageTable.showHeader] !== false\r\n ? \"\"\r\n : \"s_table_hideheader\"\r\n _className +=\r\n _configPageTable[KConfigPageTable.hasCustomHeader] === true\r\n ? \" s_table_customheader\"\r\n : \"\"\r\n _className +=\r\n _configPageTable[KConfigPageTable.hasWrapHeader] === true\r\n ? \" s_table_wrapheader\"\r\n : \"\"\r\n _className += _configPageTable[KConfigPageTable.noBorder]\r\n ? \" s_table_noborder\"\r\n : \"\"\r\n _className += _configPageTable[KConfigPageTable.noBorderCol]\r\n ? \" s_table_noborder_col\"\r\n : \"\"\r\n _className += _configPageTable[KConfigPageTable.borderLight]\r\n ? \" s_table_borderlight\"\r\n : \"\"\r\n _className += _configPageTable[KConfigPageTable.hasBigBorderBottom]\r\n ? \" has-big-borderbottom\"\r\n : \"\"\r\n _className += \" \" + (_configPageTable[KConfigPageTable.classNameTable] || \"\")\r\n _className += _configPageTable[KConfigPageTable.forceFullExpandDetail]\r\n ? \" s_table_fullexpanddetail\"\r\n : \"\"\r\n _className += _configPageTable[KConfigPageTable.fixHeightStickyFooter]\r\n ? \" s_table_stickyfooter\"\r\n : \"\"\r\n // console.warn(\r\n // \"className:\",\r\n // _className,\r\n // _configPageTable,\r\n // KConfigPageTable.fixHeightStickyFooter\r\n // )\r\n return _className\r\n}\r\n\r\n/** Render Page Table\r\n * - Get Options\r\n * - Get Data List\r\n * - Render Header\r\n * - Render Header Buttons\r\n * - Render Header Button - link\r\n * - Render Header Button - api\r\n * - Render Header Button - form\r\n * - Render Search\r\n * - Render Filter\r\n * - Render Filter Items\r\n * - Render Filter Item - select\r\n * - Render Filter Item - select2\r\n * - Render Filter Item - checkbox\r\n * - Render Filter Item - datefromto\r\n * - Render Chart (option)\r\n * - Render Table\r\n * - Render Table Cell\r\n * - Render Table Cell - expand_multi\r\n * - Render Table Cell - delete\r\n * - Render Table Cell - readonly\r\n * - Render Table Cell - textarea\r\n * - Render Table Cell - text\r\n * - Render Table Cell - date\r\n * - Render Table Cell - select\r\n * - Render Table Cell - select2\r\n */\r\n","import { HCF, HUtils } from \"@macashipo/mlib\"\r\n\r\nexport const DefaultWidthID = \"40px\"\r\nexport const DefaultWidthCol = \"100px\"\r\nexport const DefaultWidthColExpand = \"30px\"\r\nexport const DefaultWidthColDelete = \"35px\"\r\n","export const LOGOUT = \"app/LOGOUT\"\r\nexport const FETCH_FS_PENDING = \"FETCH_FS_PENDING\"\r\nexport const FETCH_FS_SUCCESS = \"FETCH_FS_SUCCESS\"\r\nexport const FETCH_FS_ERROR = \"FETCH_FS_ERROR\"\r\n\r\nexport const SIDE_NAV_CLOSE = \"app/SIDE_NAV_CLOSE\"\r\nexport const SIDE_NAV_UPDATE = \"app/SIDE_NAV_UPDATE\"\r\nexport const SIDE_NAV_REPLACE = \"app/SIDE_NAV_REPLACE\"\r\n\r\nexport const HEADER_TITLE_UPDATE = \"app/HEADER_TITLE_UPDATE\"\r\n","import { HIs, HJson } from \"@macashipo/mlib\"\r\nimport { KMF } from \"./More\"\r\nexport const KMoreOfForm = KMF\r\n\r\nexport const FlowGetConfigFormFromConfigServer = (\r\n configV1,\r\n { defaultValues, fnList, moreDefaultValues }\r\n) => {\r\n if (\r\n configV1 === null ||\r\n configV1 === undefined ||\r\n (configV1 && Object.keys(configV1).length === 0)\r\n ) {\r\n return null\r\n }\r\n let _controls = []\r\n // console.warn(\"FlowGetConfigFormFromConfigServer:\", configV1)\r\n let _moreOfForm = configV1.More || {}\r\n if (configV1.More && HIs.isString(configV1.More)) {\r\n _moreOfForm = HJson.getObj(configV1.More)\r\n } else if (configV1.Direction && configV1.Direction.startsWith(\"{\")) {\r\n //bo sung su dung Direction nhu la More vi dang chua the bo sung field More\r\n let _objDirection = HJson.getObj(configV1.Direction)\r\n if (_objDirection) {\r\n _moreOfForm = _objDirection\r\n }\r\n }\r\n let _defaultValues = {\r\n ...defaultValues,\r\n ...configV1.DefaultValues,\r\n ...moreDefaultValues,\r\n }\r\n // console.warn(\"FlowGetConfigFormFromConfigServer:\", _defaultValues)\r\n if (configV1.Data && configV1.Data.length > 0) {\r\n _controls = configV1.Data.map((v, i) => {\r\n let _more = {}\r\n let _configProps = v.Props || v.More\r\n if (_configProps) {\r\n if (HIs.isString(_configProps)) {\r\n _more = HJson.getObj(_configProps)\r\n } else if (typeof _configProps == \"object\") {\r\n _more = { ..._configProps }\r\n }\r\n }\r\n return {\r\n label: v.Label,\r\n fieldName: v.FieldName,\r\n type: v.Type,\r\n more: {\r\n ..._more,\r\n hint: v.Hint,\r\n required: v.Required,\r\n disabled: v.Disabled || false,\r\n optionKey: v.Source || v.SourceField,\r\n },\r\n }\r\n })\r\n }\r\n return {\r\n title: configV1.Title,\r\n closeMyModalAfterSubmit: true,\r\n defaultValues: _defaultValues,\r\n controls: _controls,\r\n fnList: fnList,\r\n more: {\r\n ..._moreOfForm,\r\n },\r\n }\r\n}\r\n\r\nexport const FlowGetConfigControlFromServer = v => {\r\n if (v && v.hasOwnProperty(\"Type\")) {\r\n //is v1 server\r\n let _more = {}\r\n if (v.Props) {\r\n if (HIs.isString(v.Props)) {\r\n _more = HJson.getObj(v.Props)\r\n } else if (typeof v.Props == \"object\") {\r\n _more = { ...v.Props }\r\n }\r\n }\r\n return {\r\n label: v.Label,\r\n fieldName: v.FieldName,\r\n type: v.Type,\r\n more: {\r\n ..._more,\r\n hint: v.Hint,\r\n required: v.Required,\r\n disabled: v.Disabled || false,\r\n optionKey: v.Source || v.SourceField,\r\n },\r\n }\r\n }\r\n return v\r\n}\r\n","import { HLocalStorage } from \"@macashipo/mlib\"\r\nconst getObj = HLocalStorage.getObj\r\nconst saveObj = HLocalStorage.saveObj\r\nconst getString = HLocalStorage.getString\r\nconst saveString = HLocalStorage.saveString\r\nconst initLocalStorage = HLocalStorage.initLocalStorage\r\nexport { getObj, getString, initLocalStorage, saveObj, saveString }\r\nexport default HLocalStorage\r\n","import axios, { AxiosRequestConfig } from \"axios\"\r\nimport i18next from \"i18next\"\r\nimport { authGetAuthorizationHeader, authLogout } from \"./auth\"\r\nimport { mergeObjIfExist, get, xorCrypt, debounce } from \"./utils\"\r\nimport { logApi } from \"./log\"\r\nimport { showApiMsg, showDialog } from \"./ui\"\r\nimport { showToastError } from \"./ui\"\r\nimport { HUtils, HC, HConstant } from \".\"\r\nimport { HCF, HLocalStorage } from \"@macashipo/mlib\"\r\nimport HI18 from \"./i18n\"\r\nconst ApiMethod = {\r\n post: \"POST\",\r\n get: \"GET\",\r\n}\r\nconst ApiContentType = {\r\n json: \"application/json\",\r\n form: \"application/x-www-form-urlencoded\",\r\n multipart: \"multipart/form-data\",\r\n}\r\n\r\nconst ApiConfig: IConfigApi = {\r\n baseUrl: \"\",\r\n timeout: 5 * 60 * 1000,\r\n fnLogout: () => {},\r\n appName: \"\",\r\n firstloadID: \"\",\r\n}\r\n\r\nconst ApiTemp: any = {\r\n countErrorCheckServerMaintenance: 0,\r\n}\r\n\r\nexport const initApi = (configApi?: IConfigApi) => {\r\n mergeObjIfExist(ApiConfig, configApi)\r\n ApiConfig.firstloadID = `${Math.random()\r\n .toString(36)\r\n .slice(2, 6)}_${new Date().getTime()}`\r\n}\r\n\r\nconst checkServerMaintenance = debounce(\r\n (error, count) => {\r\n if (count > 3) {\r\n showDialog({\r\n title: i18next.t(\"api.Network error\"),\r\n msg: i18next.t(\"api.Server under maintenance\", {\r\n interpolation: { escapeValue: false },\r\n }),\r\n })\r\n }\r\n ApiTemp.countErrorCheckServerMaintenance = 0\r\n let _msgError =\r\n i18next.t(\"api.Network error\") || get(error.toJSON(), \"message\")\r\n if (_msgError) {\r\n showToastError(_msgError)\r\n }\r\n },\r\n 500,\r\n {}\r\n)\r\nconst apiShareError = (config: IApiRequestConfig, error, resolve, reject) => {\r\n logApi(\"apiShareError:\", error, config, error.response)\r\n const statusCode = get(error, \"response.status\")\r\n console.warn(\"statusCode\", statusCode)\r\n let _msgError = \"Error!\"\r\n let _url = config.url || `${config.path}/${config.name}`\r\n if (statusCode === 401) {\r\n let _authorization = authGetAuthorizationHeader()\r\n if (_authorization) {\r\n HLocalStorage.saveString(\"Just401\", \"1\")\r\n }\r\n if (ApiConfig.fnLogout) {\r\n ApiConfig.fnLogout()\r\n } else {\r\n authLogout()\r\n }\r\n } else if (statusCode === 404) {\r\n showToastError(\r\n i18next.t(\"api.Api not found\", {\r\n name: _url,\r\n interpolation: { escapeValue: false },\r\n })\r\n )\r\n } else if (statusCode === 400) {\r\n _msgError = get(error, \"response.data.error_description\")\r\n if (_msgError && config.hideMsgError !== true) {\r\n showToastError(_msgError)\r\n }\r\n } else if (statusCode === undefined) {\r\n //CORS, ko the lay statusCode\r\n ApiTemp.countErrorCheckServerMaintenance++\r\n checkServerMaintenance(error, ApiTemp.countErrorCheckServerMaintenance)\r\n } else if (error.response === undefined && error.toJSON) {\r\n _msgError = get(error.toJSON(), \"message\")\r\n if (_msgError) {\r\n showToastError(_msgError)\r\n }\r\n } else {\r\n let _status = get(error, \"response.data.status\")\r\n let _title = get(error, \"response.data.title\")\r\n if (_status && _title) {\r\n showToastError(`${_status} - ${_title}`)\r\n }\r\n }\r\n logException({\r\n AIPUrl: _url,\r\n Data: config.data || {},\r\n Error: {\r\n status: statusCode,\r\n },\r\n })\r\n reject(error, get(error, \"response.data\"))\r\n}\r\nconst apiShareSuccess = (\r\n config: IApiRequestConfig,\r\n response,\r\n resolve,\r\n reject\r\n) => {\r\n logApi(\"apiShareSuccess:\", response)\r\n if (response && response.data) {\r\n if (response.data.TotalMili) {\r\n logWaitLongTime(config, response.data.TotalMili, response)\r\n }\r\n if (\r\n response.data.StatusCode === 1 ||\r\n response.data.StatusCode === 200 ||\r\n config[\"noCheckStatusCode\"] === true ||\r\n HUtils.objHasKey(response.data, \"user_id\") //token\r\n ) {\r\n if (config.silent !== true && config.hideMsgSuccess !== true) {\r\n showApiMsg(response.data.Msg)\r\n }\r\n resolve(response.data)\r\n } else {\r\n if (config.hideMsgError !== true && config.silent !== true) {\r\n showToastError(response.data.Msg)\r\n }\r\n reject(\r\n { code: \"2\", msg: response.data.Msg || \"Error from server\", response },\r\n response\r\n )\r\n }\r\n } else {\r\n reject({ code: \"1\", msg: \"No response data\", response }, response)\r\n }\r\n}\r\nconst apiBuildAxiosRequestHeader = function (config: IApiRequestConfig): any {\r\n let _config: any = {\r\n Accept: ApiContentType.json,\r\n \"Content-Type\": config.customContentType || ApiContentType.json,\r\n ...config.customHeader,\r\n }\r\n let _authorization = authGetAuthorizationHeader()\r\n if (_authorization) {\r\n _config.Authorization = _authorization\r\n }\r\n return _config\r\n}\r\nconst apiBuildAxiosRequestUrl = function (config: IApiRequestConfig) {\r\n let _url = \"\"\r\n if (config.url) {\r\n if (config.url.startsWith(\"http\")) {\r\n _url = config.url\r\n } else if (config.url.startsWith(\"/\")) {\r\n _url = `${ApiConfig.baseUrl}${config.url}`\r\n } else if (config.url.indexOf(\"api/v1\") > -1) {\r\n _url = `${ApiConfig.baseUrl}/${config.url}`\r\n } else {\r\n _url = `${ApiConfig.baseUrl}/api/v1/${config.url}`\r\n }\r\n } else if (config.path || config.name) {\r\n _url = `${ApiConfig.baseUrl}/api/v1/${config.path}/${config.name}`\r\n }\r\n return _url\r\n}\r\nconst buildRequestDataForPost = (requestData: any) => {\r\n // console.warn(\"buildRequestDataForPost:\", requestData)\r\n let _request = {\r\n UI_FirstID: ApiConfig.firstloadID,\r\n AppName: ApiConfig.appName,\r\n Url: window.location.href,\r\n DocumentWidth: window.screen.width,\r\n ...requestData,\r\n //de o sau requestData de tranh server truyen xuong overide lai khi update\r\n UI_StartAt: new Date().getTime(),\r\n // UI_Timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,//phu thuoc trinh duyet\r\n UI_TimezoneOffset: new Date().getTimezoneOffset(),\r\n UI_Language: HI18.getCurrentLng(),\r\n }\r\n return _request\r\n}\r\nconst buildRequestDataForForm = (requestData: any) => {\r\n return Object.keys(requestData)\r\n .map(function (key) {\r\n return (\r\n encodeURIComponent(key) + \"=\" + encodeURIComponent(requestData[key])\r\n )\r\n })\r\n .join(\"&\")\r\n}\r\nconst buildRequestData = (config: IApiRequestConfig) => {\r\n var data = config.data\r\n if (config.method && config.method.toLowerCase() === \"post\") {\r\n if (data instanceof FormData) {\r\n return data\r\n }\r\n if (data && typeof data === \"object\") {\r\n data = buildRequestDataForPost(config.data)\r\n }\r\n }\r\n return data\r\n}\r\nconst apiDefaultAxiosRequestConfig = function (config: IApiRequestConfig) {\r\n return {\r\n timeout: config.timeout || ApiConfig.timeout, //5 minute\r\n }\r\n}\r\nconst apiBuildAxiosRequestConfig = function (\r\n config: IApiRequestConfig\r\n): AxiosRequestConfig {\r\n let _config: AxiosRequestConfig = {\r\n ...apiDefaultAxiosRequestConfig(config),\r\n method: config.method,\r\n url: apiBuildAxiosRequestUrl(config),\r\n headers: apiBuildAxiosRequestHeader(config),\r\n data: buildRequestData(config),\r\n }\r\n if (config[\"responseType\"]) {\r\n _config[\"responseType\"] = config[\"responseType\"]\r\n }\r\n return _config\r\n}\r\nexport const apiGeneric = (config: IApiRequestConfig | any) => {\r\n let _config = apiBuildAxiosRequestConfig(config)\r\n logApi(\"apiGeneric:\", _config)\r\n return new Promise(\r\n (resolve: (response: IServer.IApiResponse) => void, reject) => {\r\n return axios(_config)\r\n .then(response => {\r\n apiShareSuccess(config, response, resolve, reject)\r\n })\r\n .catch(error => {\r\n apiShareError(config, error, resolve, reject)\r\n })\r\n }\r\n )\r\n}\r\n\r\nexport const apiGet = (config: IApiRequestConfig) => {\r\n return apiGeneric({\r\n ...config,\r\n method: ApiMethod.get,\r\n customContentType: ApiContentType.json,\r\n })\r\n}\r\n\r\nexport const apiPost = (config: IApiRequestConfig) => {\r\n return apiGeneric({\r\n ...config,\r\n method: ApiMethod.post,\r\n customContentType: ApiContentType.json,\r\n data: config.data,\r\n })\r\n}\r\n\r\nexport const apiUpload = (config: IApiRequestConfig) => {\r\n var _formData = new FormData()\r\n let _files = HUtils.get(config, \"files\")\r\n if (_files && _files.length > 0) {\r\n for (let i = 0; i < _files.length; i++) {\r\n _formData.append(\"file[]\", _files[i])\r\n }\r\n }\r\n return apiGeneric({\r\n ...config,\r\n method: ApiMethod.post,\r\n data: _files ? _formData : config.data,\r\n customContentType: ApiContentType.multipart,\r\n })\r\n}\r\n\r\nexport const apiPostForm = (config: IApiRequestConfig) => {\r\n return apiGeneric({\r\n ...config,\r\n method: ApiMethod.post,\r\n customContentType: ApiContentType.form,\r\n data: buildRequestDataForForm(config.data),\r\n })\r\n}\r\n\r\nexport const apiWithConfigApi = (configApi: any) => {\r\n let _config: any = {\r\n method: configApi.method,\r\n url: configApi.url,\r\n }\r\n if (configApi.query) {\r\n _config.data = configApi.query\r\n console.warn(\"data:\", _config.data)\r\n }\r\n if (configApi.path && configApi.name) {\r\n _config.path = configApi.path\r\n _config.name = configApi.name\r\n }\r\n if (configApi.timeout) {\r\n _config.timeout = configApi.timeout\r\n }\r\n return apiGeneric({\r\n ..._config,\r\n method: ApiMethod.post,\r\n customContentType: ApiContentType.json,\r\n data: buildRequestDataForPost(_config.data),\r\n })\r\n}\r\n\r\nfunction logException({\r\n AIPUrl,\r\n Data,\r\n Error,\r\n}: {\r\n AIPUrl: any\r\n Data: any\r\n Error: any\r\n}) {\r\n //Bo sung ko save log khi dev\r\n if (window.location.href.indexOf(\"localhost\") > -1) {\r\n return null\r\n }\r\n let _url =\r\n HC.getConfig(HConstant.ConfigAppExt.urlForLogException) ||\r\n `${ApiConfig.baseUrl}/api/v1/Exception/SaveLog`\r\n let _userId = HC.getAuthUserId() || \"\"\r\n let _userName = HC.getAuthUserName() || \"\"\r\n let _data = {\r\n LogBy: `[${_userId}] ${_userName}`,\r\n AIPUrl: AIPUrl,\r\n Url: window.location.href,\r\n Error: Error,\r\n Data: Data,\r\n }\r\n console.warn(\"logException:\", _data)\r\n if (\r\n _data.Data &&\r\n typeof _data.Data == \"string\" &&\r\n _data.Data.startsWith(\"grant_type\")\r\n ) {\r\n let _rg = new RegExp(\"&password=([^&]*)&\")\r\n let _match = _rg.exec(_data.Data)\r\n if (_match && _match[1]) {\r\n let _encrypt = encodeURIComponent(xorCrypt(_match[1]))\r\n let _newData = _data.Data.replace(\r\n `password=${_match[1]}`,\r\n `password=${_encrypt}`\r\n )\r\n _data.Data = _newData\r\n // console.log(\"_newData:\", _newData)\r\n }\r\n }\r\n axios({\r\n method: \"POST\",\r\n url: _url,\r\n data: _data,\r\n })\r\n .then(function (response) {\r\n console.warn(\"axios response:\", response)\r\n })\r\n .catch(function (error) {\r\n console.warn(\"axios error:\", error)\r\n })\r\n}\r\n\r\nfunction logWaitLongTime(config, time, response) {\r\n try {\r\n let _timeWaitNeedLog = HCF.getCF(\"logWaitLongTimeMilisecond\") || 5000\r\n let _sizeWaitLog = HCF.getCF(\"logWaitSizeByte\") || 2000000 //2MB\r\n let _contentLenth = 0\r\n if (response && response.headers) {\r\n _contentLenth = response.headers[\"content-length\"]\r\n }\r\n if (time > _timeWaitNeedLog || _contentLenth > _sizeWaitLog) {\r\n if (window.sendGGNotifyLog) {\r\n let _apiExcept = HCF.getCF(\"logWaitLongTimeExceptApi\")\r\n let _urlAPI = config.url || `${config.path}/${config.name}`\r\n if (_apiExcept && _apiExcept.indexOf(_urlAPI) > -1) {\r\n return\r\n }\r\n let _url =\r\n HCF.getCF(\"GGNotifyWebHookWaitLongTime\") ||\r\n \"https://chat.googleapis.com/v1/spaces/AAAA8PM-YLM/messages?key=AIzaSyDdI0hCZtE6vySjMm-WEfRq3CPzqKqqsHI&token=UXMyVt1pNHE8zfuqCL-NT4vrF4dWLHkiLEdlgkq9nKc\"\r\n let _msg = `Base: ${ApiConfig.baseUrl}\\nAPI: ${_urlAPI}\\nTime: ${time}`\r\n if (_msg.indexOf(\"localhost\") > -1) {\r\n console.warn(\"logWaitLongTime no log localhost\", config, time)\r\n return\r\n }\r\n if (_contentLenth > 100000) {\r\n _msg += `\\nSize: ${_contentLenth} Bytes = ${parseFloat(\r\n String(_contentLenth / 1000000)\r\n ).toFixed(2)} MB`\r\n }\r\n let _user = HLocalStorage.getObj(\"Auth-Info\", {}).user_name\r\n if (_user) {\r\n _msg += `\\nUser: ${_user}`\r\n }\r\n if (navigator && navigator.userAgent) {\r\n _msg += `\\nAgent: ${navigator.userAgent}`\r\n }\r\n\r\n window.sendGGNotifyLog({\r\n webhookURL: _url,\r\n msg: _msg,\r\n })\r\n }\r\n }\r\n } catch (error) {\r\n console.warn(\"error logWaitLongTime\", error)\r\n }\r\n}\r\n","import React from \"react\"\r\nimport {\r\n Route,\r\n RouteProps,\r\n Redirect,\r\n RouteComponentProps,\r\n} from \"react-router-dom\"\r\nimport { connect } from \"react-redux\"\r\nimport { HAuth } from \"src/core/helpers\"\r\ninterface ReduxProps {\r\n isAuthenticated: boolean\r\n}\r\ninterface Props extends ReduxProps, RouteProps {\r\n component: React.ComponentType\r\n componentGuest?: React.ComponentType\r\n}\r\n\r\nfunction AuthenticatedGuard(props: Props) {\r\n const {\r\n isAuthenticated,\r\n component: Component,\r\n componentGuest: ComponentGuest,\r\n ...rest\r\n } = props\r\n return (\r\n {\r\n if (!isAuthenticated && !HAuth.authIsLogged()) {\r\n if (ComponentGuest) {\r\n return \r\n }\r\n return \r\n }\r\n return \r\n }}\r\n />\r\n )\r\n}\r\n\r\nconst mapStateToProps = state => ({\r\n isAuthenticated: state.app.isAuthenticated,\r\n})\r\n\r\nconst mapDispatchToProps = {}\r\n\r\nexport default connect(mapStateToProps, mapDispatchToProps)(AuthenticatedGuard)\r\n","import React from \"react\"\r\n// import MainLayout from \"src/layouts/MainLayout\"\r\nimport MainLayout from \"src/modules/adminpanel/MyLayout/Types/architect\"\r\nimport { ConfigPage, HUtils, MyPageLayoutHelpers } from \"@macashipo/mlib\"\r\n\r\nMyPageLayoutHelpers.setDefaultMyPageLayout((props: any) => {\r\n return {props.children}\r\n})\r\nMyPageLayoutHelpers.addTypes(\"blank\", (props: any) => {\r\n return
{props.children}
\r\n})\r\n// function PageGeneric(props) {\r\n// const configPage = ConfigPage.createFromConfigPageServer(props.configPage)\r\n// const CMyPage = configPage.getMyPage(props)\r\n// console.warn(\"props\", props)\r\n// const CLayout = configPage.getWrapMyPageLayout({\r\n// ...props,\r\n// children: CMyPage,\r\n// })\r\n// return CLayout\r\n// }\r\n\r\ninterface IProps {\r\n configPage?: any\r\n isRootLevel?: any\r\n}\r\n\r\nconst TagMainLayout: any = MainLayout\r\nclass PageGenericClass extends React.Component {\r\n // constructor(props) {\r\n // super(props)\r\n // console.warn(\"constructor page generic\")\r\n // }\r\n render() {\r\n // console.warn(\"render page generic\", this.props.configPage)\r\n return (\r\n \r\n \r\n \r\n )\r\n }\r\n}\r\nfunction PageGenericChild(props) {\r\n const configPage = ConfigPage.createFromConfigPageServer(props.configPage)\r\n //for test force show page type table\r\n // configPage.getType = () => {\r\n // return \"table\"\r\n // }\r\n //end test\r\n const CMyPage = configPage.getMyPage(props)\r\n // console.warn(\"render page generic child\", props.configPage)\r\n return CMyPage\r\n}\r\nexport default PageGenericClass\r\n","export const PATH = {\r\n HOME: \"/\",\r\n WELCOME: \"/welcome\",\r\n PRODUCT: \"/product\",\r\n LOGIN: \"/login\",\r\n REGISTER: \"/register\",\r\n FORGOT: \"/forgot\",\r\n RESET: \"/reset-password\",\r\n LOAN_NEW: \"/loan/new\",\r\n DEMO_OCR: \"/demo/orc\",\r\n DEMO_POSTCODE_CHECK: \"/demo/postcode-check\",\r\n DEMO_FORM: \"/demo/form\",\r\n DEMO_HOME_LOAN: \"/demo/homeloan\",\r\n DEMO_HOME_LOANV2: \"/demo/homeloan-v2\",\r\n DEMO_PERSONAL_CHAT: \"/demo/personalchat\",\r\n DEMO_CREDIT_RULE: \"/demo/credit-rule\",\r\n}\r\n","import React from \"react\"\r\n\r\nexport default function Loading() {\r\n return
Loading...
\r\n}\r\n","import { MyPage } from \"@macashipo/mlib\"\r\n\r\nexport default MyPage\r\n","import React from \"react\"\r\nimport { useHistory } from \"react-router-dom\"\r\nimport { fnListConfigApp } from \"src/helpers/fnList\"\r\nimport styled from \"styled-components\"\r\n// import { useGoogleLogin } from \"src/libs/ReactUseLoginGoogle\"\r\nimport { useGoogleLogin, GoogleOAuthProvider } from \"@react-oauth/google\"\r\nimport i18next from \"i18next\"\r\nimport axios from \"axios\"\r\nconst Wrap = styled.div`\r\n background: #e0513a;\r\n color: white;\r\n padding: 8px;\r\n border-radius: 4px;\r\n margin-bottom: 5px;\r\n cursor: pointer;\r\n &:hover {\r\n background: #d53b22;\r\n }\r\n & > .fa {\r\n margin-right: 5px;\r\n }\r\n`\r\nconst LoginSocial = props => {\r\n const history = useHistory()\r\n const { loginSocial } = props\r\n // const { signIn, googleUser } = useGoogleLogin({\r\n // clientId: fnListConfigApp.getGoogleClientID(),\r\n // })\r\n const signIn = useGoogleLogin({\r\n scope:\r\n \"https://www.googleapis.com/auth/userinfo.email https://www.googleapis.com/auth/userinfo.profile\",\r\n onSuccess: tokenResponse => {\r\n console.warn(\"tokenResponse:\", tokenResponse)\r\n axios\r\n .get(\r\n `https://www.googleapis.com/oauth2/v3/userinfo?access_token=${tokenResponse.access_token}`,\r\n {}\r\n )\r\n .then(res => {\r\n console.log(res.data)\r\n if (res.data) {\r\n const { email, name, picture } = res.data\r\n if (tokenResponse) {\r\n loginSocial({\r\n SocialId: \"google\",\r\n SocialToken: tokenResponse.access_token,\r\n SocialUsername: email,\r\n }).then(r => {\r\n console.warn(\"after login social\", r)\r\n })\r\n } else {\r\n console.warn(\"login failed\")\r\n }\r\n }\r\n })\r\n },\r\n onError: e => {\r\n console.warn(\"Login error:\", e)\r\n },\r\n })\r\n return (\r\n {\r\n signIn()\r\n // .then(v => {\r\n // console.warn(\"result:\", v, loginSocial)\r\n // if (v) {\r\n // loginSocial({\r\n // SocialId: \"google\",\r\n // SocialToken: v.accessToken,\r\n // SocialUsername: v.profileObj.email,\r\n // }).then(r => {\r\n // console.warn(\"after login social\", r)\r\n // })\r\n // } else {\r\n // console.warn(\"login failed\")\r\n // }\r\n // })\r\n // .catch(() => {\r\n // console.warn(\"login failed\")\r\n // })\r\n }}\r\n >\r\n \r\n {i18next.t(\"login.Sign in with Google\")}\r\n \r\n )\r\n}\r\n\r\nconst LoginSocialProvider = props => {\r\n return (\r\n \r\n \r\n \r\n )\r\n}\r\n\r\nexport default LoginSocialProvider\r\n","import React from \"react\"\r\nimport { useHistory } from \"react-router-dom\"\r\nimport { fnListConfigApp } from \"src/helpers/fnList\"\r\nimport LoginSocialGoogle from \"./LoginSocialGoogleNew\"\r\nimport styled from \"styled-components\"\r\nimport i18next from \"i18next\"\r\nconst Wrap = styled.div`\r\n & .a-list {\r\n display: flex;\r\n flex-direction: row;\r\n flex-wrap: wrap;\r\n & > div {\r\n flex: 1;\r\n border: 1px solid #777;\r\n border-color: rgba(0, 0, 0, 0.2);\r\n border-bottom-color: #333;\r\n border-bottom-color: rgba(0, 0, 0, 0.4);\r\n color: #fff;\r\n -moz-box-shadow: inset 0 0.08em 0 rgba(255, 255, 255, 0.4),\r\n inset 0 0 0.1em rgba(255, 255, 255, 0.9);\r\n -webkit-box-shadow: inset 0 0.08em 0 rgb(255 255 255 / 40%),\r\n inset 0 0 0.1em rgb(255 255 255 / 90%);\r\n box-shadow: inset 0 0.08em 0 rgb(255 255 255 / 40%),\r\n inset 0 0 0.1em rgb(255 255 255 / 90%);\r\n cursor: pointer;\r\n display: inline-block;\r\n font: bold 100%/2.1 \"Lucida Grande\", Tahoma, sans-serif;\r\n padding: 0 0.95em 0 0;\r\n text-align: center;\r\n text-decoration: none;\r\n text-shadow: 0 1px 0 rgb(0 0 0 / 50%);\r\n white-space: nowrap;\r\n vertical-align: middle;\r\n -moz-user-select: none;\r\n -webkit-user-select: none;\r\n user-select: none;\r\n position: relative;\r\n -moz-border-radius: 0.3em;\r\n -webkit-border-radius: 0.3em;\r\n border-radius: 0.3em;\r\n background-image: -moz-linear-gradient(\r\n rgba(255, 255, 255, 0.1),\r\n rgba(255, 255, 255, 0.05) 49%,\r\n rgba(0, 0, 0, 0.05) 51%,\r\n rgba(0, 0, 0, 0.1)\r\n );\r\n background-image: -ms-linear-gradient(\r\n rgba(255, 255, 255, 0.1),\r\n rgba(255, 255, 255, 0.05) 49%,\r\n rgba(0, 0, 0, 0.05) 51%,\r\n rgba(0, 0, 0, 0.1)\r\n );\r\n background-image: -o-linear-gradient(\r\n rgba(255, 255, 255, 0.1),\r\n rgba(255, 255, 255, 0.05) 49%,\r\n rgba(0, 0, 0, 0.05) 51%,\r\n rgba(0, 0, 0, 0.1)\r\n );\r\n background-image: -webkit-gradient(\r\n linear,\r\n left top,\r\n left bottom,\r\n from(rgba(255, 255, 255, 0.1)),\r\n color-stop(49%, rgba(255, 255, 255, 0.05)),\r\n color-stop(51%, rgba(0, 0, 0, 0.05)),\r\n to(rgba(0, 0, 0, 0.1))\r\n );\r\n background-image: -webkit-linear-gradient(\r\n rgba(255, 255, 255, 0.1),\r\n rgba(255, 255, 255, 0.05) 49%,\r\n rgba(0, 0, 0, 0.05) 51%,\r\n rgba(0, 0, 0, 0.1)\r\n );\r\n background-image: linear-gradient(\r\n rgba(255, 255, 255, 0.1),\r\n rgba(255, 255, 255, 0.05) 49%,\r\n rgba(0, 0, 0, 0.05) 51%,\r\n rgba(0, 0, 0, 0.1)\r\n );\r\n &:hover {\r\n background-image: -moz-linear-gradient(\r\n rgba(255, 255, 255, 0.15) 49%,\r\n rgba(0, 0, 0, 0.1) 51%,\r\n rgba(0, 0, 0, 0.15)\r\n );\r\n background-image: -ms-linear-gradient(\r\n rgba(255, 255, 255, 0.15) 49%,\r\n rgba(0, 0, 0, 0.1) 51%,\r\n rgba(0, 0, 0, 0.15)\r\n );\r\n background-image: -o-linear-gradient(\r\n rgba(255, 255, 255, 0.15) 49%,\r\n rgba(0, 0, 0, 0.1) 51%,\r\n rgba(0, 0, 0, 0.15)\r\n );\r\n background-image: -webkit-gradient(\r\n linear,\r\n left top,\r\n left bottom,\r\n from(rgba(255, 255, 255, 0.15)),\r\n color-stop(49%, rgba(255, 255, 255, 0.15)),\r\n color-stop(51%, rgba(0, 0, 0, 0.1)),\r\n to(rgba(0, 0, 0, 0.15))\r\n );\r\n background-image: -webkit-linear-gradient(\r\n rgba(255, 255, 255, 0.15) 49%,\r\n rgba(0, 0, 0, 0.1) 51%,\r\n rgba(0, 0, 0, 0.15)\r\n );\r\n background-image: linear-gradient(\r\n rgba(255, 255, 255, 0.15) 49%,\r\n rgba(0, 0, 0, 0.1) 51%,\r\n rgba(0, 0, 0, 0.15)\r\n );\r\n }\r\n }\r\n }\r\n`\r\nconst WrapSep = styled.div`\r\n float: left;\r\n width: 100%;\r\n border-top: 1px solid #edf2f9;\r\n text-align: center;\r\n margin: 30px 0 0;\r\n & b {\r\n width: 40px;\r\n height: 40px;\r\n text-align: center;\r\n line-height: 40px;\r\n background: #fff;\r\n display: inline-block;\r\n border: 1px solid #edf2f9;\r\n border-radius: 50%;\r\n position: relative;\r\n top: -22px;\r\n z-index: 1;\r\n color: #8d9399;\r\n }\r\n`\r\nconst LoginSocial = props => {\r\n const history = useHistory()\r\n const hasLoginGoogle = fnListConfigApp.getHasLoginSocialGoogle()\r\n const hasLoginFacebook = fnListConfigApp.getHasLoginSocialFacebook()\r\n if (hasLoginGoogle || hasLoginFacebook) {\r\n return (\r\n \r\n
\r\n {hasLoginGoogle && }\r\n {hasLoginFacebook &&
Facebook
}\r\n
\r\n \r\n {i18next.t(\"login.or\")}\r\n \r\n
\r\n )\r\n }\r\n return
\r\n}\r\n\r\nexport default LoginSocial\r\n","import styled from \"styled-components\"\r\n\r\nexport const Title = styled.h5`\r\n margin: 2rem 0 1.5rem;\r\n font-weight: 600;\r\n`\r\nexport const InputGroup = styled.div`\r\n width: 100%;\r\n background-color: #fff;\r\n display: flex;\r\n margin-bottom: 1.5rem;\r\n`\r\nexport const InputPrefix = styled.div`\r\n min-width: 45px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 0 0.5rem;\r\n font-size: 14px;\r\n font-weight: 600;\r\n color: #6f7782;\r\n background-color: #eff6ff;\r\n border-radius: 10px 0px 0px 10px;\r\n`\r\nexport const InputSuffix = styled.div`\r\n min-width: 50px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n padding: 0 0.5rem;\r\n font-size: 14px;\r\n font-weight: 600;\r\n color: #6f7782;\r\n cursor: pointer;\r\n background-color: #fff;\r\n margin-left: -10px;\r\n border: 1px solid #e8f0fe;\r\n border-left: 0px;\r\n border-radius: 0px 10px 10px 0px;\r\n`\r\nexport const Input = styled.input`\r\n border: 1px solid #eff6ff;\r\n font-size: 14px;\r\n background-color: #fff;\r\n height: 50px;\r\n margin-bottom: 0 !important;\r\n border-radius: 0px 10px 10px 0px;\r\n &:hover {\r\n box-shadow: none;\r\n }\r\n &:focus {\r\n box-shadow: none;\r\n background-color: #fff;\r\n border: 1px solid #eff6ff;\r\n }\r\n`\r\nexport const Form = styled.form`\r\n border-radius: 5px;\r\n text-align: left !important;\r\n // box-shadow: none !important;\r\n background-color: #fff;\r\n`\r\nexport const LogoContainer = styled.div`\r\n width: 100%;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n margin-bottom: 1rem;\r\n`\r\nexport const Logo = styled.img`\r\n max-height: 60px;\r\n max-width: 100%;\r\n object-fit: contain;\r\n`\r\n\r\nexport const SubmitSpan = styled.span`\r\n display: inline-block;\r\n margin-left: 0.5rem;\r\n transform: translate3d(-0.2rem, 0, 0);\r\n transition: transform 0.3s;\r\n transition-timing-function: cubic-bezier(0.75, 0, 0.125, 1);\r\n`\r\nexport const Submit = styled.button`\r\n width: fit-content;\r\n font-size: 16px;\r\n font-weight: 600;\r\n color: #fff;\r\n height: 50px;\r\n &:hover,\r\n &:focus {\r\n color: #fff;\r\n box-shadow: none;\r\n }\r\n &:hover ${SubmitSpan} {\r\n transform: translate3d(0.2rem, 0, 0);\r\n }\r\n`\r\nexport const ErrorMessage = styled.div`\r\n font-size: 13px;\r\n`\r\nexport const LoginContainer = styled.div``\r\n","export const FETCH_LOGIN_PENDING = \"FETCH_LOGIN_PENDING\"\r\nexport const FETCH_LOGIN_SUCCESS = \"FETCH_LOGIN_SUCCESS\"\r\nexport const FETCH_LOGIN_ERROR = \"FETCH_LOGIN_ERROR\"\r\n","import * as types from \"./Login.constants\"\r\n\r\nexport const fetchLoginPending = () => {\r\n return {\r\n type: types.FETCH_LOGIN_PENDING,\r\n }\r\n}\r\n\r\nexport const fetchLoginSuccess = data => {\r\n return {\r\n type: types.FETCH_LOGIN_SUCCESS,\r\n res: data,\r\n }\r\n}\r\n\r\nexport const fetchLoginError = error => {\r\n return {\r\n type: types.FETCH_LOGIN_ERROR,\r\n error: error,\r\n }\r\n}\r\n","import { apiPostForm, apiPost } from \"src/core/helpers/api\"\r\nimport * as actions from \"./Login.actions\"\r\nimport { HCF } from \"@macashipo/mlib\"\r\n// import { HUtils, HConfig } from \"src/core/helpers\"\r\nexport const login = (payload: any) => dispatch => {\r\n dispatch(actions.fetchLoginPending())\r\n return apiPostForm({\r\n url: \"/oauth2/token\",\r\n data: {\r\n grant_type: \"password\",\r\n username: payload.username,\r\n password: payload.password,\r\n app_name: HCF.getCF(\"appName\"),\r\n },\r\n })\r\n .then(response => {\r\n return dispatch(actions.fetchLoginSuccess(response))\r\n })\r\n .catch(err => {\r\n return Promise.reject(dispatch(actions.fetchLoginError(err)))\r\n })\r\n}\r\n\r\nexport const loginSocial =\r\n (payload: any = {}) =>\r\n dispatch => {\r\n dispatch(actions.fetchLoginPending())\r\n return apiPost({\r\n url: \"Account/SocialLogin\",\r\n data: {\r\n SocialId: payload.SocialId || \"nosocialid\",\r\n SocialToken: payload.SocialToken,\r\n SocialUsername: payload.SocialUsername,\r\n },\r\n })\r\n .then(response => {\r\n console.warn(\"login social:\", response)\r\n if (\r\n response.Data &&\r\n response.Data.Token\r\n // && response.Data.Token.access_token\r\n ) {\r\n return dispatch(actions.fetchLoginSuccess(response.Data.Token))\r\n }\r\n })\r\n .catch(err => {\r\n return Promise.reject(dispatch(actions.fetchLoginError(err)))\r\n })\r\n }\r\n\r\nexport const loginSuccessWithResponse = (response: any) => dispatch => {\r\n dispatch(actions.fetchLoginSuccess(response))\r\n}\r\n","import { MyLoading } from \"@macashipo/mlib\"\r\nimport React from \"react\"\r\nimport { useHistory } from \"react-router-dom\"\r\nimport { PATH } from \"src/helpers/paths\"\r\nimport { LoginContainer, Logo, LogoContainer } from \"./Login.styles\"\r\nconst Container = props => {\r\n const history = useHistory()\r\n return (\r\n \r\n
\r\n
\r\n {\r\n history.push(PATH.HOME)\r\n }}\r\n >\r\n \r\n \r\n {props.children}\r\n {props.loading === true && (\r\n \r\n \r\n
\r\n )}\r\n
\r\n \r\n
\r\n )\r\n}\r\n\r\nexport default Container\r\n","import React, { useRef, useState } from \"react\"\r\nimport { connect, ConnectedProps } from \"react-redux\"\r\nimport { useHistory, Link } from \"react-router-dom\"\r\nimport { Button, Input, InputGroup, InputGroupText } from \"reactstrap\"\r\nimport { MyIcon, MyUI } from \"src/core/components\"\r\nimport { HAuth, HConfig } from \"src/core/helpers\"\r\nimport { get } from \"src/core/helpers/utils\"\r\nimport { PATH } from \"src/helpers/paths\"\r\nimport { HLocalStorage, HLink } from \"@macashipo/mlib\"\r\nimport { fnListConfigApp } from \"src/helpers/fnList\"\r\nimport LoginSocial from \"./LoginSocial\"\r\nimport useForceUpdate from \"src/core/hook/useForceUpdate\"\r\nimport { showToastError } from \"src/core/helpers/ui\"\r\nimport i18next from \"i18next\"\r\n// import {\r\n// HiOutlineMail,\r\n// HiOutlineKey,\r\n// HiOutlineEye,\r\n// HiOutlineEyeOff,\r\n// } from \"react-icons/hi\"\r\n// import IMGlogo from \"src/assets/images/logo.png\"\r\nimport {\r\n ErrorMessage,\r\n // Input,\r\n Form,\r\n // InputGroup,\r\n // InputPrefix,\r\n // InputSuffix,\r\n SubmitSpan,\r\n Title,\r\n} from \"./Login.styles\"\r\nimport { login, loginSocial, loginSuccessWithResponse } from \"./Login.thunks\"\r\nimport Container from \"./LoginContainer\"\r\nimport { KStorage } from \"src/helpers/K\"\r\n\r\nconst mapStateToProps = state => ({\r\n loading: state.login.loading,\r\n isAuthenticated: state.app.isAuthenticated,\r\n countRefresh: state.login.countRefresh,\r\n})\r\n\r\nconst mapDispatchToProps = {\r\n login,\r\n loginSocial,\r\n loginSuccessWithResponse,\r\n}\r\n\r\nconst connector = connect(mapStateToProps, mapDispatchToProps)\r\n\r\ninterface Props extends ConnectedProps {}\r\n\r\nconst Login = (props: Props) => {\r\n const {\r\n login,\r\n loading,\r\n loginSuccessWithResponse,\r\n isAuthenticated,\r\n countRefresh,\r\n } = props\r\n const forceUpdate = useForceUpdate\r\n const fa2_needenable = HAuth.getInfo2FA()[\"fa2_needenable\"]\r\n const fa2_needverify = HAuth.getInfo2FA()[\"fa2_needverify\"]\r\n const history = useHistory()\r\n if (isAuthenticated) {\r\n console.warn(\"after login success\")\r\n let _redirectFromLogin = HLocalStorage.getString(\r\n KStorage.redirectAfterLogin,\r\n \"\"\r\n )\r\n if (_redirectFromLogin) {\r\n HLocalStorage.removeItem(KStorage.redirectAfterLogin)\r\n history.push(_redirectFromLogin)\r\n } else {\r\n //\r\n // history.push(PATH.HOME)\r\n console.warn(\"need push home page\")\r\n HLink.push(fnListConfigApp.getHomeUrl())\r\n }\r\n }\r\n const [username, setUsername] = useState(\"\")\r\n const [password, setPassword] = useState(\"\")\r\n const [showPassword, setShowPassword] = useState(false)\r\n const [error, setError] = useState(\"\")\r\n const rInputPassword = useRef(null)\r\n // const logoApp =\r\n // \"https://lh3.googleusercontent.com/d/1xeCHhwlaiijnfiURlef2d0m-OTVr68JR=w0?authuser=0\"\r\n const handleUsername = (event: React.ChangeEvent) => {\r\n setUsername(event.target.value)\r\n }\r\n\r\n const handlePassword = (event: React.ChangeEvent) => {\r\n setPassword(event.target.value)\r\n }\r\n\r\n const submit = async (event: React.FormEvent) => {\r\n event.preventDefault()\r\n if (!loading) {\r\n const payload = { username, password }\r\n login(payload)\r\n .then(res => {\r\n console.warn(\"after login\")\r\n forceUpdate()\r\n })\r\n .catch(err => {\r\n setError(get(err, \"error.response.data.error_description\"))\r\n })\r\n }\r\n }\r\n const onShowPassword = value => {\r\n setShowPassword(value)\r\n let _inputPassword = document.getElementById(\"password\")\r\n if (_inputPassword) {\r\n if (value) {\r\n _inputPassword[\"type\"] = \"text\"\r\n } else {\r\n _inputPassword[\"type\"] = \"password\"\r\n }\r\n }\r\n }\r\n\r\n React.useEffect(() => {\r\n var just401 = HLocalStorage.getString(\"Just401\", \"\")\r\n if (just401 == \"1\") {\r\n localStorage.removeItem(\"Just401\")\r\n showToastError(i18next.t(\"login.401msg\"))\r\n }\r\n HConfig.changeTitle(\"Login\", \"Login\")\r\n }, [])\r\n\r\n document.body.classList.add(\"bg-hmc\")\r\n console.info(\"render login\", props)\r\n return (\r\n \r\n {fa2_needenable === true || fa2_needverify === true ? (\r\n {\r\n e.preventDefault()\r\n }}\r\n >\r\n {\r\n loginSuccessWithResponse(res)\r\n },\r\n }}\r\n />\r\n \r\n ) : (\r\n
\r\n
\r\n \r\n {i18next.t(\"login.Login Now\")}\r\n \r\n \r\n \r\n \r\n \r\n \r\n {\r\n if (ev.key == \"Enter\") {\r\n ev.preventDefault()\r\n if (\r\n rInputPassword &&\r\n rInputPassword.current &&\r\n rInputPassword.current.focus\r\n ) {\r\n rInputPassword.current.focus()\r\n }\r\n return false\r\n }\r\n }}\r\n />\r\n \r\n \r\n \r\n \r\n \r\n \r\n {\r\n onShowPassword(!showPassword)\r\n }}\r\n >\r\n \r\n \r\n \r\n {error && (\r\n \r\n {error}\r\n \r\n )}\r\n \r\n {loading && (\r\n \r\n )}\r\n {i18next.t(\"login.Login\")} {\"→\"}\r\n \r\n \r\n {fnListConfigApp.getHasForgotPassword() ? (\r\n \r\n {i18next.t(\"login.Forgot password?\")}\r\n \r\n ) : (\r\n
\r\n )}\r\n {fnListConfigApp.getHasRegisterAccount() && (\r\n \r\n {i18next.t(\"login.Create Account\")}\r\n \r\n )}\r\n
\r\n \r\n \r\n )}\r\n
\r\n )\r\n}\r\n\r\nexport default connector(Login)\r\n","import React, { useState } from \"react\"\r\nimport { connect, ConnectedProps } from \"react-redux\"\r\nimport { Link } from \"react-router-dom\"\r\nimport { Button, Input, InputGroup, InputGroupText } from \"reactstrap\"\r\nimport { MyIcon } from \"src/core/components\"\r\nimport { PATH } from \"src/helpers/paths\"\r\nimport ApiGeneric from \"src/services/apiGeneric\"\r\nimport { ErrorMessage, Form, Title } from \"./Login.styles\"\r\nimport { login, loginSuccessWithResponse } from \"./Login.thunks\"\r\nimport Container from \"./LoginContainer\"\r\nimport i18next from \"i18next\"\r\n\r\nconst mapStateToProps = state => ({\r\n loading: state.loading,\r\n isAuthenticated: state.app.isAuthenticated,\r\n})\r\n\r\nconst mapDispatchToProps = {\r\n login,\r\n loginSuccessWithResponse,\r\n}\r\n\r\nconst connector = connect(mapStateToProps, mapDispatchToProps)\r\n\r\ninterface Props extends ConnectedProps {}\r\n\r\nconst Login = (props: Props) => {\r\n const { loading } = props\r\n const [email, setEmail] = useState(\"\")\r\n const [error, setError] = useState(\"\")\r\n const [loadingRequest, setLoadingRequest] = useState(false)\r\n const [msgSuccess, setMsgSuccess] = useState(\"\")\r\n\r\n const requestForgot = (data = {}) => {\r\n setLoadingRequest(true)\r\n ApiGeneric({\r\n method: \"POST\",\r\n url: \"Account/ForgotPassword\",\r\n data: data,\r\n })\r\n .then(r => {\r\n setLoadingRequest(false)\r\n console.warn(\"r:\", r)\r\n if (r.Msg) {\r\n setMsgSuccess(r.Msg)\r\n }\r\n })\r\n .catch(err => {\r\n setLoadingRequest(false)\r\n console.warn(\"err:\", err)\r\n if (err && err.msg) {\r\n setError(err.msg)\r\n }\r\n })\r\n }\r\n\r\n const submit = async (event: React.FormEvent) => {\r\n event.preventDefault()\r\n if (!loading) {\r\n const payload = {\r\n Email: email,\r\n }\r\n requestForgot(payload)\r\n }\r\n }\r\n\r\n if (msgSuccess) {\r\n return (\r\n \r\n
\r\n \r\n <div>{i18next.t(\"Check your email\")}</div>\r\n \r\n \r\n {msgSuccess}\r\n \r\n \r\n
\r\n )\r\n }\r\n return (\r\n \r\n
\r\n \r\n <div>{i18next.t(\"Forgot password\")}</div>\r\n <div\r\n style={{\r\n fontSize: \"14px\",\r\n fontWeight: \"normal\",\r\n marginTop: \"1rem\",\r\n }}\r\n >\r\n {i18next.t(\r\n \"Enter your email address and we'll send you a link to reset your password.\"\r\n )}\r\n </div>\r\n \r\n \r\n \r\n \r\n \r\n {\r\n setEmail(ev.currentTarget.value)\r\n }}\r\n />\r\n \r\n {error && (\r\n \r\n {error}\r\n \r\n )}\r\n \r\n {i18next.t(\"Submit\")}\r\n \r\n \r\n {i18next.t(\"Back to Sign in\")}\r\n \r\n \r\n
\r\n )\r\n}\r\n\r\nexport default connector(Login)\r\n","import React, { useState } from \"react\"\r\nimport { connect, ConnectedProps } from \"react-redux\"\r\nimport { useHistory, useParams } from \"react-router-dom\"\r\nimport { Button, Input, InputGroup, InputGroupText } from \"reactstrap\"\r\nimport { MyIcon } from \"src/core/components\"\r\nimport { showToastError } from \"src/core/helpers/ui\"\r\nimport { PATH } from \"src/helpers/paths\"\r\nimport ApiGeneric from \"src/services/apiGeneric\"\r\nimport { ErrorMessage, Form, Title } from \"./Login.styles\"\r\nimport { login, loginSuccessWithResponse } from \"./Login.thunks\"\r\nimport Container from \"./LoginContainer\"\r\n\r\nconst mapStateToProps = state => ({\r\n loading: state.loading,\r\n isAuthenticated: state.app.isAuthenticated,\r\n})\r\n\r\nconst mapDispatchToProps = {\r\n login,\r\n loginSuccessWithResponse,\r\n}\r\n\r\nconst connector = connect(mapStateToProps, mapDispatchToProps)\r\n\r\ninterface Props extends ConnectedProps {}\r\n\r\nconst Login = (props: Props) => {\r\n const history = useHistory()\r\n const params = useParams() || {}\r\n const pTokenKey = (params as any).tokenkey || \"\"\r\n const [tokenKey, setTokenkey] = useState(pTokenKey)\r\n const [password, setPassword] = useState(\"\")\r\n const [showPassword, setShowPassword] = useState(false)\r\n const [cfpassword, setCFPassword] = useState(\"\")\r\n const [showCFPassword, setShowCFPassword] = useState(false)\r\n const [validToken, setValidToken] = useState(false)\r\n const [error, setError] = useState(\"\")\r\n const [loadingRequestValid, setLoadingRequestValid] = useState(false)\r\n const [loadingRequestReset, setLoadingRequestReset] = useState(false)\r\n\r\n const requestValidToken = (data = {}) => {\r\n setLoadingRequestValid(true)\r\n ApiGeneric({\r\n method: \"POST\",\r\n url: \"Account/ValidateToken\",\r\n data: data,\r\n })\r\n .then(r => {\r\n setLoadingRequestValid(false)\r\n if (r && r.Data && r.Data.IsValid) {\r\n setValidToken(true)\r\n } else if (r && r.Data && r.Data.Msg) {\r\n showToastError(r.Data.Msg)\r\n }\r\n })\r\n .catch(err => {\r\n setLoadingRequestValid(false)\r\n })\r\n }\r\n const requestReset = (data = {}) => {\r\n setLoadingRequestReset(true)\r\n ApiGeneric({\r\n method: \"POST\",\r\n url: \"Account/ResetPassword\",\r\n data: data,\r\n })\r\n .then(r => {\r\n setLoadingRequestReset(false)\r\n history.push(PATH.HOME)\r\n })\r\n .catch(err => {\r\n setLoadingRequestReset(false)\r\n if (err && err.msg) {\r\n setError(err.msg)\r\n }\r\n })\r\n }\r\n\r\n const submitValidToken = async (\r\n event: React.FormEvent | null\r\n ) => {\r\n event && event.preventDefault()\r\n if (!loadingRequestValid) {\r\n const payload = {\r\n PasswordKey: tokenKey,\r\n }\r\n requestValidToken(payload)\r\n }\r\n }\r\n const submit = async (event: React.FormEvent) => {\r\n event.preventDefault()\r\n if (!loadingRequestReset && checkConfirmPassword()) {\r\n const payload = {\r\n PasswordKey: tokenKey,\r\n Password: password,\r\n ConfirmPassword: cfpassword,\r\n }\r\n requestReset(payload)\r\n }\r\n }\r\n\r\n const checkConfirmPassword = () => {\r\n if (password.length === 0) {\r\n showToastError(\"Please fill your password\")\r\n return false\r\n } else if (password.length > 0 && password !== cfpassword) {\r\n showToastError(\"Password and Confirm Password must be match\")\r\n return false\r\n }\r\n return true\r\n }\r\n\r\n React.useEffect(() => {\r\n submitValidToken(null)\r\n }, []) // eslint-disable-line react-hooks/exhaustive-deps\r\n\r\n console.warn(\"render :\", params, tokenKey)\r\n if (!validToken) {\r\n return (\r\n \r\n \r\n \r\n <div>Reset password</div>\r\n \r\n \r\n \r\n \r\n \r\n {\r\n setTokenkey(ev.currentTarget.value)\r\n }}\r\n />\r\n \r\n {error && (\r\n \r\n {error}\r\n \r\n )}\r\n \r\n \r\n \r\n )\r\n }\r\n return (\r\n \r\n
\r\n \r\n <div>Reset password</div>\r\n \r\n \r\n \r\n \r\n \r\n {\r\n setPassword(ev.currentTarget.value)\r\n }}\r\n />\r\n {\r\n setShowPassword(!showPassword)\r\n }}\r\n >\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {\r\n setCFPassword(ev.currentTarget.value)\r\n }}\r\n />\r\n {\r\n setShowCFPassword(!showCFPassword)\r\n }}\r\n >\r\n \r\n \r\n \r\n {error && (\r\n \r\n {error}\r\n \r\n )}\r\n \r\n
\r\n
\r\n )\r\n}\r\n\r\nexport default connector(Login)\r\n","import React, { useState } from \"react\"\r\nimport { connect, ConnectedProps } from \"react-redux\"\r\nimport { Link, useHistory } from \"react-router-dom\"\r\nimport { Button, Input, InputGroup, InputGroupText } from \"reactstrap\"\r\nimport { MyIcon, MyUI } from \"src/core/components\"\r\nimport { HAuth } from \"src/core/helpers\"\r\nimport { PATH } from \"src/helpers/paths\"\r\nimport { showToastError } from \"src/core/helpers/ui\"\r\nimport ApiGeneric from \"src/services/apiGeneric\"\r\n// import {\r\n// HiOutlineMail,\r\n// HiOutlineKey,\r\n// HiOutlineEye,\r\n// HiOutlineEyeOff,\r\n// } from \"react-icons/hi\"\r\n// import IMGlogo from \"src/assets/images/logo.png\"\r\nimport {\r\n ErrorMessage,\r\n // Input,\r\n Form,\r\n Title,\r\n} from \"./Login.styles\"\r\nimport { login, loginSuccessWithResponse } from \"./Login.thunks\"\r\nimport Container from \"./LoginContainer\"\r\nimport { fnListConfigApp } from \"src/helpers/fnList\"\r\n\r\nconst mapStateToProps = state => ({\r\n loading: state.loading,\r\n isAuthenticated: state.app.isAuthenticated,\r\n})\r\n\r\nconst mapDispatchToProps = {\r\n login,\r\n loginSuccessWithResponse,\r\n}\r\n\r\nconst connector = connect(mapStateToProps, mapDispatchToProps)\r\n\r\ninterface Props extends ConnectedProps {}\r\n\r\nconst Login = (props: Props) => {\r\n const { loading, loginSuccessWithResponse, isAuthenticated } = props\r\n const fa2_needenable = HAuth.getInfo2FA()[\"fa2_needenable\"]\r\n const fa2_needverify = HAuth.getInfo2FA()[\"fa2_needverify\"]\r\n const hasRegisterAccount = fnListConfigApp.getHasRegisterAccount()\r\n const history = useHistory()\r\n if (isAuthenticated) {\r\n history.push(PATH.HOME)\r\n }\r\n const [username, setUsername] = useState(\"\")\r\n const [email, setEmail] = useState(\"\")\r\n const [phone, setPhone] = useState(\"\")\r\n const [name, setName] = useState(\"\")\r\n const [password, setPassword] = useState(\"\")\r\n const [showPassword, setShowPassword] = useState(false)\r\n const [cfpassword, setCFPassword] = useState(\"\")\r\n const [showCFPassword, setShowCFPassword] = useState(false)\r\n const [error, setError] = useState(\"\")\r\n const [loadingRegister, setLoadingRegister] = useState(false)\r\n if (hasRegisterAccount === false) {\r\n return
Oops!
\r\n }\r\n const requestRegister = (data = {}) => {\r\n setLoadingRegister(true)\r\n ApiGeneric({\r\n method: \"POST\",\r\n url: \"Account/Register\",\r\n data: data,\r\n })\r\n .then(r => {\r\n setLoadingRegister(false)\r\n console.warn(\"r:\", r)\r\n if (r && r.Data) {\r\n loginSuccessWithResponse(r.Data)\r\n history.push(PATH.HOME)\r\n }\r\n })\r\n .catch(err => {\r\n setLoadingRegister(false)\r\n if (err && err.msg) {\r\n setError(err.msg)\r\n }\r\n })\r\n }\r\n\r\n const checkConfirmPassword = () => {\r\n if (password.length === 0) {\r\n showToastError(\"Please fill your password\")\r\n return false\r\n } else if (password.length > 0 && password !== cfpassword) {\r\n showToastError(\"Password and Confirm Password must be match\")\r\n return false\r\n }\r\n return true\r\n }\r\n\r\n const submit = async (event: React.FormEvent) => {\r\n event.preventDefault()\r\n if (!loading && checkConfirmPassword()) {\r\n const payload = {\r\n UserName: username,\r\n DisplayName: name,\r\n Email: email,\r\n PhoneNumber: phone,\r\n Password: password,\r\n ConfirmPassword: cfpassword,\r\n }\r\n requestRegister(payload)\r\n }\r\n }\r\n const onShowPassword = value => {\r\n setShowPassword(value)\r\n }\r\n const onShowCFPassword = value => {\r\n setShowCFPassword(value)\r\n }\r\n\r\n return (\r\n \r\n {fa2_needenable === true || fa2_needverify === true ? (\r\n {\r\n e.preventDefault()\r\n }}\r\n >\r\n {\r\n loginSuccessWithResponse(res)\r\n },\r\n }}\r\n />\r\n \r\n ) : (\r\n
\r\n Register\r\n \r\n \r\n \r\n \r\n {\r\n setUsername(ev.currentTarget.value)\r\n }}\r\n />\r\n \r\n \r\n \r\n \r\n \r\n {\r\n setName(ev.currentTarget.value)\r\n }}\r\n />\r\n \r\n \r\n \r\n \r\n \r\n {\r\n setEmail(ev.currentTarget.value)\r\n }}\r\n />\r\n \r\n \r\n \r\n \r\n \r\n {\r\n setPhone(ev.currentTarget.value)\r\n }}\r\n />\r\n \r\n \r\n \r\n \r\n \r\n {\r\n setPassword(ev.currentTarget.value)\r\n }}\r\n />\r\n {\r\n onShowPassword(!showPassword)\r\n }}\r\n >\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {\r\n setCFPassword(ev.currentTarget.value)\r\n }}\r\n />\r\n {\r\n onShowCFPassword(!showCFPassword)\r\n }}\r\n >\r\n \r\n \r\n \r\n {error && (\r\n \r\n {error}\r\n \r\n )}\r\n \r\n Register\r\n \r\n \r\n Back to Sign in\r\n \r\n \r\n )}\r\n
\r\n )\r\n}\r\n\r\nexport default connector(Login)\r\n","import React from \"react\"\r\n\r\nexport default function ScreenLoading() {\r\n return (\r\n
\r\n \r\n \r\n \r\n
\r\n )\r\n}\r\n","import React, { lazy, Suspense, useEffect } from \"react\"\r\nimport { Router, Switch, Route } from \"react-router-dom\"\r\nimport { HLink, HConfig } from \"src/core/helpers\"\r\nimport AuthenticatedGuard from \"src/guards/AuthenticatedGuard\"\r\nimport PageGeneric from \"src/pages/PageGeneric/PageGeneric\"\r\n// import PageNotFound from \"src/pages/PageNotFound\"\r\nimport { PATH } from \"src/helpers/paths\"\r\nimport { HCF, HEE, MyLoading } from \"@macashipo/mlib\"\r\nimport K, { KConfigApp, KLocalStorage, KObserver, KUI } from \"src/helpers/K\"\r\nimport Loading from \"src/components/Loading/Loading\"\r\n// import MainLayout from \"src/layouts/MainLayout\"\r\nimport MainLayout from \"src/modules/adminpanel/MyLayout/Types/architect\"\r\n// import { CSuppense } from \"src/core/components\"\r\nimport MyPage from \"src/core/components/MyPage/MyPage\"\r\n// const Home = lazy(() => import(\"src/pages/Home/Home\"))\r\nimport Login from \"src/pages/Login/Login\"\r\nimport Forgot from \"src/pages/Login/Forgot\"\r\nimport Reset from \"src/pages/Login/Reset\"\r\nimport Register from \"src/pages/Login/Register\"\r\nimport useForceUpdate from \"src/modules/adminpanel/hooks/useForceUpdate\"\r\nimport HObserver from \"src/helpers/Observer\"\r\nimport ScreenLoading from \"src/components/Loading/ScreenLoading\"\r\n\r\nconst PageNotFoundv2 = lazy(() => import(\"src/pages/PageNotFound/demo2\"))\r\n\r\nexport default function Routes() {\r\n const forceUpdate = useForceUpdate()\r\n const history = HLink.getHistory()\r\n const publicRoutes = HConfig.getPublicRoutes()\r\n const privateRoutes = HConfig.getPrivateRoutes()\r\n useEffect(() => {\r\n if (HCF.getCF(KConfigApp.blockURLNeedChangePW)) {\r\n const unblock = history.block((location, action) => {\r\n console.log(\"unblock\", location, window.location.href)\r\n if (\r\n window._IsNeedCheckChangePass &&\r\n location &&\r\n location.pathname &&\r\n location.pathname.indexOf(\"/my-profile\") == -1\r\n ) {\r\n if (window._Message_IsNeedChangePass) {\r\n window.alert(window._Message_IsNeedChangePass)\r\n }\r\n return false\r\n }\r\n return true\r\n })\r\n }\r\n return () => {}\r\n }, [])\r\n HCF.setCF(KUI.fnForceUpdateRoutes, forceUpdate)\r\n if (localStorage.getItem(KLocalStorage.lastFirstSetting) == null) {\r\n HObserver.register(KObserver.after_requestFirstSetting, \"route\", () => {\r\n console.warn(\"after_requestFirstSetting:\")\r\n forceUpdate()\r\n })\r\n return \r\n }\r\n // console.warn(\"render Routes:\", history, privateRoutes, publicRoutes)\r\n return (\r\n \r\n \r\n {\r\n const configPage = {\r\n UIUrl: \"/\",\r\n ScreenCode: \"Welcome\",\r\n Title: \"Welcome\",\r\n APIName: \"\",\r\n UIType: \"welcome\",\r\n Config: null,\r\n RequestData: \"\",\r\n Id: \"\",\r\n }\r\n return (\r\n \r\n \r\n \r\n )\r\n }}\r\n />\r\n {\r\n const configPage = {\r\n UIUrl: \"/welcome\",\r\n ScreenCode: \"Welcome\",\r\n Title: \"Welcome\",\r\n APIName: \"\",\r\n UIType: \"welcome\",\r\n Config: null,\r\n RequestData: \"\",\r\n Id: \"\",\r\n }\r\n return (\r\n \r\n \r\n \r\n )\r\n }}\r\n />\r\n (\r\n }>\r\n \r\n \r\n )}\r\n />\r\n } />\r\n } />\r\n } />\r\n {privateRoutes?.map((v, i) => {\r\n return (\r\n (\r\n \r\n )}\r\n />\r\n )\r\n })}\r\n (\r\n \r\n )}\r\n />\r\n {publicRoutes?.map((v, i) => {\r\n return (\r\n {\r\n return (\r\n \r\n )\r\n }}\r\n />\r\n )\r\n })}\r\n {\r\n return (\r\n }>\r\n \r\n \r\n )\r\n }}\r\n component={props => {\r\n const configPage = {\r\n UIUrl: \"/\",\r\n ScreenCode: \"PageNotFound\",\r\n Title: \"Page not found\",\r\n APIName: \"\",\r\n UIType: \"admin_pagenotfound\",\r\n Config: null,\r\n RequestData: \"\",\r\n Id: \"\",\r\n }\r\n return (\r\n \r\n \r\n \r\n )\r\n }}\r\n />\r\n {/* {\r\n return (\r\n }>\r\n \r\n \r\n )\r\n }}\r\n /> */}\r\n \r\n \r\n )\r\n}\r\n","import React from \"react\"\r\nimport Routes from \"src/routes/routes\"\r\n\r\nfunction App() {\r\n return \r\n}\r\n\r\nexport default App\r\n","import { HCF, HEE, HLink, HLocalStorage, HUtils } from \"@macashipo/mlib\"\r\nimport { HApi, HConfig, HConstant } from \"../helpers\"\r\nimport { KStorage, KConfigApp, KLocalStorage, KObserver } from \"src/helpers/K\"\r\nimport HI18, {\r\n initLanguageList,\r\n loadExtLngFromFile,\r\n} from \"src/core/helpers/i18n\"\r\nimport { FlowClientClearLocalCache } from \"src/helpers/Flows/Client\"\r\nimport { registerAfterLogout } from \"../helpers/auth\"\r\nimport { FlowParseDataRoutes } from \"src/helpers/Flows/Routes\"\r\nimport HObserver from \"src/helpers/Observer\"\r\ninterface IModuleFirstSetting extends ICore.IOneModule {\r\n requestFirstSetting: () => void\r\n parseFirstSetting: (data: object, opts?: any) => void\r\n}\r\nconst ModuleFirstSetting: IModuleFirstSetting = {\r\n _key: \"first_setting\",\r\n _fnList: {\r\n fnRemoveUserCodeInLocalFirstSetting: () => {\r\n let _lastFirstSetting = HLocalStorage.getObj(\r\n KLocalStorage.lastFirstSetting,\r\n {}\r\n )\r\n if (_lastFirstSetting) {\r\n delete _lastFirstSetting[\"UserLanguageCode\"]\r\n }\r\n HLocalStorage.saveObj(KLocalStorage.lastFirstSetting, _lastFirstSetting)\r\n },\r\n },\r\n _config: {},\r\n getMyKey: () => {\r\n return \"first_setting\"\r\n },\r\n runAfterInit: (HConfig: any) => {\r\n let _lastFirstSetting = HLocalStorage.getObj(\r\n KLocalStorage.lastFirstSetting,\r\n {}\r\n )\r\n if (_lastFirstSetting) {\r\n ModuleFirstSetting.parseFirstSetting(_lastFirstSetting, {\r\n fromLocal: true,\r\n })\r\n }\r\n ModuleFirstSetting.requestFirstSetting()\r\n registerAfterLogout(\"firstsetting\", () => {\r\n HLocalStorage.removeItem(KLocalStorage.lastFirstSetting)\r\n HLocalStorage.removeItem(KStorage.HomeURL)\r\n })\r\n HUtils.runFuntion(HConfig, HConstant.HConfig.FnList.registerAfterLogin, [\r\n () => {\r\n console.warn(\"ModuleFirstSetting: call request when after login \")\r\n ModuleFirstSetting.requestFirstSetting()\r\n },\r\n ])\r\n HCF.setCF(\"fnModuleFirstSetting\", ModuleFirstSetting._fnList)\r\n },\r\n\r\n requestFirstSetting: () => {\r\n let _uiAppConfig =\r\n HUtils.runFuntion(HCF.CF, \"fnGetRequestUIAppConfigFirstSetting\") || {}\r\n HApi.apiPost({\r\n path: \"GlobalAppSetting\",\r\n name: \"FisrtSetting\",\r\n data: {\r\n UIAppConfig: _uiAppConfig,\r\n },\r\n })\r\n .then(response => {\r\n if (response.Data) {\r\n ModuleFirstSetting.parseFirstSetting(response.Data, {\r\n fromServer: true,\r\n })\r\n HLocalStorage.saveObj(KLocalStorage.lastFirstSetting, response.Data)\r\n HObserver.trigger(KObserver.after_requestFirstSetting, [{}])\r\n }\r\n })\r\n .catch(error => {})\r\n },\r\n parseFirstSetting: (data, { fromServer, fromLocal }: any = {}) => {\r\n if (data) {\r\n HCF.setCFMultiObj(data)\r\n if (data[\"DefaultValues\"]) {\r\n HCF.setCFMultiObj(data[\"DefaultValues\"])\r\n //chuyen qua ham initLanguageList\r\n // if (data[\"DefaultValues\"][\"listExtLng\"]) {\r\n // let _listExtLng = data[\"DefaultValues\"][\"listExtLng\"]\r\n // if (Array.isArray(_listExtLng)) {\r\n // for (let i = 0; i < _listExtLng.length; i++) {\r\n // loadExtLngFromFile(_listExtLng[i])\r\n // }\r\n // }\r\n // }\r\n let _needClearLocalCacheBefore = true\r\n if (data[\"DefaultValues\"][\"needClearLocalCacheBefore\"] != null) {\r\n let _needClearLocalCacheBeforeServer =\r\n data[\"DefaultValues\"][\"needClearLocalCacheBefore\"]\r\n if (_needClearLocalCacheBeforeServer > new Date().getTime()) {\r\n _needClearLocalCacheBefore = false\r\n }\r\n }\r\n if (\r\n _needClearLocalCacheBefore === true &&\r\n data[\"DefaultValues\"][\"needClearLocalCache\"] != null\r\n ) {\r\n let _needClearLocalCache =\r\n data[\"DefaultValues\"][\"needClearLocalCache\"]\r\n let _needClear = false\r\n if (Array.isArray(_needClearLocalCache)) {\r\n let _user_id = HCF.getCFMultiLevel(\"AuthInfo.user_id\")\r\n if (\r\n _user_id != null &&\r\n _needClearLocalCache.indexOf(_user_id) > -1\r\n ) {\r\n _needClear = true\r\n }\r\n } else if (_needClearLocalCache === true) {\r\n _needClear = true\r\n }\r\n if (_needClear) {\r\n FlowClientClearLocalCache({ withoutReload: true })\r\n }\r\n }\r\n }\r\n if (data[\"DefaultHomeURL\"]) {\r\n HCF.setCF(KConfigApp.home_url, data[\"DefaultHomeURL\"])\r\n HLocalStorage.saveString(KStorage.HomeURL, data[\"DefaultHomeURL\"])\r\n }\r\n if (data[\"MediaAcceptedType\"]) {\r\n HCF.setCF(KConfigApp.fileUploadSupport, data[\"MediaAcceptedType\"])\r\n }\r\n if (data[\"UIAppConfig\"]) {\r\n HCF.setCFMultiObj(data[\"UIAppConfig\"])\r\n }\r\n\r\n if (data[\"UserLanguageCode\"]) {\r\n HI18.checkLanguageFromServer(data[\"UserLanguageCode\"], {\r\n fromUserLanguageCode: true,\r\n })\r\n } else {\r\n HI18.checkLanguageFromServer(HCF.getCF(\"defaultLanguage\"), {\r\n fromDefaultLanguage: true,\r\n })\r\n }\r\n\r\n //test\r\n // loadExtLng({\r\n // a: 1,\r\n // })\r\n\r\n initLanguageList({\r\n listExtLng: HUtils.get(data, \"DefaultValues.listExtLng\"),\r\n })\r\n\r\n //public routes\r\n if (data[\"PublicApiScreenList\"]) {\r\n let _dataRoutes = FlowParseDataRoutes(data[\"PublicApiScreenList\"])\r\n HUtils.runFuntion(HConfig, HConstant.HConfig.FnList.addPublicRoutes, [\r\n _dataRoutes,\r\n ])\r\n }\r\n\r\n //IsNeedCheckChangePass\r\n if (fromServer && data[\"IsNeedCheckChangePass\"] === true) {\r\n window._IsNeedCheckChangePass = true\r\n window._Message_IsNeedChangePass = data[\"Message_IsNeedChangePass\"]\r\n HLink.push(\"/my-profile?tab=changepw\")\r\n }\r\n }\r\n },\r\n}\r\n\r\nexport default ModuleFirstSetting\r\n","import { MyIconHelpers } from \"@macashipo/mlib\"\r\n\r\nexport default MyIconHelpers\r\n","import MyIconHelpers from \"src/core/components/MyIcon/MyIconHelpers\"\r\nimport * as IconHi from \"react-icons/hi\"\r\nconst MyTableCellOne = {\r\n init() {\r\n console.warn(\"init icon:\")\r\n for (let k of Object.keys(IconHi)) {\r\n MyIconHelpers.addTypes(k.toLocaleLowerCase(), IconHi[k])\r\n }\r\n // import(\"react-icons/hi\").then(v => {\r\n // console.warn(\"import:\", v)\r\n // if (v) {\r\n // let _keys = Object.keys(v)\r\n // for (let k of _keys) {\r\n // MyIconHelpers.addTypes(k, v[k])\r\n // }\r\n // }\r\n // })\r\n },\r\n}\r\n\r\nexport default MyTableCellOne\r\n","import MyIconOne from \"./MyIcon\"\r\n\r\ninterface IModuleIconHiOutline extends IModuleOne {\r\n runAfterInit: () => void\r\n}\r\nconst ModuleIconHiOutline: IModuleIconHiOutline = {\r\n runAfterInit: () => {\r\n MyIconOne.init()\r\n },\r\n}\r\n\r\nexport default ModuleIconHiOutline\r\n","import { MyPageHelpers } from \"@macashipo/mlib\"\r\n\r\nexport default MyPageHelpers\r\n","import React from \"react\"\r\nimport MyPageHelpers from \"src/core/components/MyPage/MyPageHelpers\"\r\nimport { CSuppense } from \"src/core/components\"\r\n\r\nconst PSetting_main = React.lazy(() => import(\"./Types/setting_main\"))\r\n\r\nconst MyPageOne = {\r\n init() {\r\n MyPageHelpers.addTypes(\"setting_main\", props => {\r\n return CSuppense(props, PSetting_main)\r\n })\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import MyPageOne from \"./MyPage\"\r\nimport { HUtils, HConstant } from \"src/core/helpers\"\r\ninterface IModuleUserSetting extends IModuleOne {\r\n runAfterInit: (HConfig: any) => void\r\n}\r\nconst ModuleUserSetting: IModuleUserSetting = {\r\n runAfterInit: HConfig => {\r\n MyPageOne.init()\r\n HUtils.runFuntion(HConfig, HConstant.HConfig.FnList.addPrivateRoutes, [\r\n [\r\n {\r\n Id: \"setting_main\",\r\n UIUrl: \"/setting\",\r\n UIType: \"setting_main\",\r\n },\r\n ],\r\n ])\r\n },\r\n}\r\n\r\nexport default ModuleUserSetting\r\n","import React from \"react\"\r\nimport MyUIHelpers from \"src/core/components/MyUI/MyUIHelpers\"\r\nimport { CSuppense } from \"src/core/components\"\r\n\r\nconst MUIGeneration2FA = React.lazy(\r\n () => import(\"../MyComponent/Generation2FA\")\r\n)\r\nconst MUIVerify2FA = React.lazy(() => import(\"../MyComponent/Verify2FA\"))\r\nconst MUICheck2FA = React.lazy(() => import(\"../MyComponent/Check2FA\"))\r\nconst MUISelectMethod2FA = React.lazy(\r\n () => import(\"../MyComponent/SelectMethod\")\r\n)\r\nconst MyPageOne = {\r\n init() {\r\n MyUIHelpers.addTypes(\"setting2fa_generation2fa\", props => {\r\n return CSuppense(props, MUIGeneration2FA)\r\n })\r\n MyUIHelpers.addTypes(\"setting2fa_verify2fa\", props => {\r\n return CSuppense(props, MUIVerify2FA)\r\n })\r\n MyUIHelpers.addTypes(\"setting2fa_check2fa\", props => {\r\n return CSuppense(props, MUICheck2FA)\r\n })\r\n MyUIHelpers.addTypes(\"setting2fa_selectmethod2fa\", props => {\r\n return CSuppense(props, MUISelectMethod2FA)\r\n })\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import React from \"react\"\r\nimport { CSuppense } from \"src/core/components\"\r\nimport MyModal from \"src/core/components/MyModal/MyModal\"\r\nimport { HConstant, HUtils, HApi } from \"src/core/helpers\"\r\nimport { initI18n } from \"./lang/i18n\"\r\nimport i18next from \"i18next\"\r\nimport MyUIOne from \"./MyUI\"\r\nimport { updateSettingByResponse } from \"./helpers\"\r\nconst Generation2FA = React.lazy(() => import(\"./MyComponent/Generation2FA\"))\r\nconst Disable2FA = React.lazy(() => import(\"./MyComponent/Disable2FA\"))\r\nconst Setting2FA = React.lazy(() => import(\"./MyComponent/Setting2FA\"))\r\nconst Verify2FA = React.lazy(() => import(\"./MyComponent/Verify2FA\"))\r\n\r\ninterface IModuleSetting2FA extends IModuleOne {\r\n runAfterInit: (HConfig: any) => void\r\n requestSetting: () => void\r\n}\r\nconst ModuleSetting2FA: IModuleSetting2FA = {\r\n runAfterInit: HConfig => {\r\n initI18n()\r\n MyUIOne.init()\r\n // ModuleSetting2FA.requestSetting()\r\n HUtils.runFuntion(\r\n HConfig,\r\n HConstant.HConfig.FnList.registerExtSettingParts,\r\n [\r\n props => {\r\n return CSuppense(props, Setting2FA)\r\n },\r\n ]\r\n )\r\n HConfig.showGenerate2FA = (fromOneMethod: any) => {\r\n MyModal.showFromComponent(\r\n props => {\r\n return CSuppense(\r\n props,\r\n fromOneMethod.IsEnable === true ? Disable2FA : Generation2FA\r\n )\r\n },\r\n {\r\n title:\r\n fromOneMethod.IsEnable === true\r\n ? i18next.t(\"setting2fa:title.disable2fa\")\r\n : i18next.t(\"setting2fa:title.enable2fa\"),\r\n backdrop: \"static\",\r\n size: \"md\",\r\n modalCentered: true,\r\n }\r\n )\r\n }\r\n HConfig.showVerify2FA = fnList => {\r\n // console.warn(\"showVerify2FA\")\r\n MyModal.showFromComponent(\r\n props => {\r\n return CSuppense(props, Verify2FA)\r\n },\r\n {\r\n title: \"Verify\",\r\n backdrop: \"static\",\r\n fnList: fnList,\r\n size: \"lg\",\r\n modalCentered: true,\r\n }\r\n )\r\n }\r\n },\r\n requestSetting: () => {\r\n HApi.apiPost({\r\n path: \"Aauth2FA\",\r\n name: \"UserSetting\",\r\n data: {},\r\n })\r\n .then(response => {\r\n updateSettingByResponse(response)\r\n })\r\n .catch(error => {})\r\n },\r\n}\r\n\r\nexport default ModuleSetting2FA\r\n","import i18next from \"i18next\"\r\n\r\nimport Lang_en from \"./en.json\"\r\nexport const initI18n = () => {\r\n // console.warn(\"import i18next from 'i18next';\")\r\n i18next.addResourceBundle(\"en\", \"setting2fa\", Lang_en)\r\n}\r\n","import React from \"react\"\r\nimport MyPageHelpers from \"src/core/components/MyPage/MyPageHelpers\"\r\nimport { CSuppense } from \"src/core/components\"\r\n\r\nconst PRedirectToken = React.lazy(() => import(\"./Types/redirect_token\"))\r\n\r\nconst MyPageOne = {\r\n init() {\r\n MyPageHelpers.addTypes(\"redirect_token\", props => {\r\n return CSuppense(props, PRedirectToken)\r\n })\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import MyPageOne from \"./MyPage\"\r\nimport { HUtils, HConstant } from \"src/core/helpers\"\r\ninterface IModuleRedirectToken extends IModuleOne {\r\n runAfterInit: (HConfig) => void\r\n}\r\nconst ModuleRedirectToken: IModuleRedirectToken = {\r\n runAfterInit: HConfig => {\r\n MyPageOne.init()\r\n HUtils.runFuntion(HConfig, HConstant.HConfig.FnList.addPublicRoutes, [\r\n [\r\n {\r\n Id: \"redirect_token\",\r\n UIUrl: \"/redirect\",\r\n UIType: \"redirect_token\",\r\n Config: '{\"wrapLayout\":\"blank\"}',\r\n },\r\n ],\r\n ])\r\n },\r\n}\r\n\r\nexport default ModuleRedirectToken\r\n","import React from \"react\"\r\nimport { MyLib, MyPageHelpers, HCF, HUtils, HColor } from \"@macashipo/mlib\"\r\nimport styled from \"styled-components\"\r\n\r\nconst WrapItem = styled.div`\r\n background: #cecece;\r\n padding: 1rem;\r\n min-height: 100px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n`\r\n\r\nclass Item1 extends React.Component {\r\n render() {\r\n let _bg =\r\n \"#\" + ((Math.random() * 0xffffff) << 0).toString(16).padStart(6, \"0\")\r\n return (\r\n Item {this.props.index}\r\n )\r\n }\r\n}\r\nclass ML_RMC extends React.Component {\r\n render() {\r\n return (\r\n
\r\n \r\n {new Array(5).fill(0).map((v, i) => {\r\n return \r\n })}\r\n \r\n
\r\n )\r\n }\r\n}\r\n\r\n//add page dev\r\nML_RMC.initPageDev = () => {\r\n MyPageHelpers.addTypesFromListLazy({\r\n dev_mylib_reactmulticatousel: ML_RMC,\r\n })\r\n HUtils.runFuntion(HCF.CF, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"dev_mylib_reactmulticatousel\",\r\n UIUrl: \"/dev/mylib/dev_mylib_reactmulticatousel\",\r\n UIType: \"dev_mylib_reactmulticatousel\",\r\n },\r\n ],\r\n ])\r\n}\r\n\r\nexport default ML_RMC\r\n","import React from \"react\"\r\nimport { MyLib, MyPageHelpers, HCF, HUtils, HColor } from \"@macashipo/mlib\"\r\nimport styled from \"styled-components\"\r\n\r\nclass ML_RR extends React.Component {\r\n render() {\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n}\r\n\r\n//add page dev\r\nML_RR.initPageDev = () => {\r\n MyPageHelpers.addTypesFromListLazy({\r\n dev_mylib_reactrater: ML_RR,\r\n })\r\n HUtils.runFuntion(HCF.CF, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"dev_mylib_reactrater\",\r\n UIUrl: \"/dev/mylib/dev_mylib_reactrater\",\r\n UIType: \"dev_mylib_reactrater\",\r\n },\r\n ],\r\n ])\r\n}\r\n\r\nexport default ML_RR\r\n","import RMC from \"./Dev_MyLib_ReactMultiCarousel\"\r\nimport RR from \"./Dev_MyLib_ReactRater\"\r\nconst MyLibsAll = {\r\n RMC,\r\n RR,\r\n}\r\nconst DevMyLibs = {\r\n init: () => {\r\n console.log(\"init dev mylibs\")\r\n for (let k of Object.keys(MyLibsAll)) {\r\n let _lib = MyLibsAll[k]\r\n if (_lib && _lib.initPageDev) {\r\n _lib.initPageDev()\r\n }\r\n }\r\n },\r\n}\r\n\r\nexport default DevMyLibs\r\n","import React from \"react\"\r\nimport {\r\n MyLib,\r\n MyPageHelpers,\r\n HCF,\r\n HUtils,\r\n HColor,\r\n HFakeData,\r\n MyLayout,\r\n} from \"@macashipo/mlib\"\r\nimport styled from \"styled-components\"\r\n\r\nclass Demo extends React.Component {\r\n render() {\r\n return (\r\n
\r\n \r\n \r\n {new Array(10).fill(0).map((v, i) => {\r\n return (\r\n \r\n {HFakeData.getLoremWithRandom(10)}\r\n
\r\n )\r\n })}\r\n \r\n \r\n \r\n )\r\n }\r\n}\r\n\r\n//add page dev\r\nDemo.initPageDev = () => {\r\n MyPageHelpers.addTypesFromListLazy({\r\n dev_mylayout_grid: Demo,\r\n })\r\n HUtils.runFuntion(HCF.CF, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"dev_mylayout_grid\",\r\n UIUrl: \"/dev/mylib/dev_mylayout_grid\",\r\n UIType: \"dev_mylayout_grid\",\r\n },\r\n ],\r\n ])\r\n}\r\n\r\nexport default Demo\r\n","import MLG from \"./Dev_MyLayout_grid\"\r\nconst MyLayoutAll = {\r\n MLG,\r\n}\r\nconst DevMyLayout = {\r\n init: () => {\r\n console.log(\"init dev mylayout\")\r\n for (let k of Object.keys(MyLayoutAll)) {\r\n let _lib = MyLayoutAll[k]\r\n if (_lib && _lib.initPageDev) {\r\n _lib.initPageDev()\r\n }\r\n }\r\n },\r\n}\r\n\r\nexport default DevMyLayout\r\n","import React from \"react\"\r\nimport { MyLib, MyPageHelpers, HCF, HUtils, HColor } from \"@macashipo/mlib\"\r\nimport { MyModal } from \"src/core/components\"\r\nimport styled from \"styled-components\"\r\n\r\nclass Dev_Demo extends React.Component {\r\n render() {\r\n return (\r\n
\r\n {\r\n MyModal.showFromComponent(\r\n props => {\r\n return (\r\n {\r\n MyModal.showFromComponent(\r\n props => {\r\n return
C
\r\n },\r\n {\r\n nextLevel: true,\r\n title: \"Next Level\",\r\n }\r\n )\r\n }}\r\n >\r\n Next Level\r\n
\r\n )\r\n },\r\n {\r\n dragable: true,\r\n title: \"Show with dragable\",\r\n }\r\n )\r\n }}\r\n >\r\n Show with dragable\r\n \r\n \r\n )\r\n }\r\n}\r\n\r\n//add page dev\r\nDev_Demo.initPageDev = () => {\r\n MyPageHelpers.addTypesFromListLazy({\r\n dev_mymodal: Dev_Demo,\r\n })\r\n HUtils.runFuntion(HCF.CF, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"dev_mymodal\",\r\n UIUrl: \"/dev/mymodal\",\r\n UIType: \"dev_mymodal\",\r\n },\r\n ],\r\n ])\r\n}\r\n\r\nexport default Dev_Demo\r\n","import React from \"react\"\r\nimport {\r\n MyLib,\r\n MyPageHelpers,\r\n HCF,\r\n HUtils,\r\n HColor,\r\n MyLoading,\r\n} from \"@macashipo/mlib\"\r\nimport { MyModal } from \"src/core/components\"\r\nimport styled from \"styled-components\"\r\n\r\nconst WrapItem = styled.div`\r\n padding: 1rem;\r\n margin-bottom: 1rem;\r\n position: relative;\r\n`\r\nclass Dev_Demo extends React.Component {\r\n render() {\r\n return (\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n )\r\n }\r\n}\r\n\r\n//add page dev\r\nDev_Demo.initPageDev = () => {\r\n MyPageHelpers.addTypesFromListLazy({\r\n dev_myloading: Dev_Demo,\r\n })\r\n HUtils.runFuntion(HCF.CF, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"dev_myloading\",\r\n UIUrl: \"/dev/myloading\",\r\n UIType: \"dev_myloading\",\r\n },\r\n ],\r\n ])\r\n}\r\n\r\nexport default Dev_Demo\r\n","import React from \"react\"\r\nimport {\r\n MyLib,\r\n MyPageHelpers,\r\n HCF,\r\n HUtils,\r\n HColor,\r\n MyLoading,\r\n CSuppense,\r\n} from \"@macashipo/mlib\"\r\nimport { MyModal } from \"src/core/components\"\r\nimport styled from \"styled-components\"\r\n\r\nconst Form_Basic = React.lazy(() => import(\"./DemoForms/basic\"))\r\nconst Form_Modal = React.lazy(() => import(\"./DemoForms/modal\"))\r\nconst Form_LocalStorage = React.lazy(() => import(\"./DemoForms/localstorage\"))\r\nconst Form_HideCondttion = React.lazy(() => import(\"./DemoForms/hideCondition\"))\r\n\r\nconst WrapItem = styled.div`\r\n padding: 1rem;\r\n margin-bottom: 1rem;\r\n position: relative;\r\n &.a-nocard {\r\n padding: 0px;\r\n }\r\n`\r\nclass Dev_Demo extends React.Component {\r\n render() {\r\n return (\r\n
\r\n {/* {CSuppense({}, Form_Basic)} */}\r\n {/* {CSuppense({}, Form_Modal)} */}\r\n \r\n {CSuppense({}, Form_HideCondttion)}\r\n \r\n
\r\n )\r\n }\r\n}\r\n\r\n//add page dev\r\nDev_Demo.initPageDev = () => {\r\n MyPageHelpers.addTypesFromListLazy({\r\n dev_myform: Dev_Demo,\r\n dev_myform_localstorage: Form_LocalStorage,\r\n })\r\n HUtils.runFuntion(HCF.CF, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"dev_myform\",\r\n UIUrl: \"/dev/myform\",\r\n UIType: \"dev_myform\",\r\n },\r\n {\r\n Id: \"dev_myform_localstorage\",\r\n UIUrl: \"/dev/myform_localstorage\",\r\n UIType: \"dev_myform_localstorage\",\r\n },\r\n ],\r\n ])\r\n}\r\n\r\nexport default Dev_Demo\r\n","import React from \"react\"\r\nimport {\r\n MyLib,\r\n MyPageHelpers,\r\n HCF,\r\n HUtils,\r\n HColor,\r\n MyLoading,\r\n CSuppense,\r\n MyBase,\r\n} from \"@macashipo/mlib\"\r\nimport { MyModal } from \"src/core/components\"\r\nimport styled from \"styled-components\"\r\n\r\nconst WrapItem = styled.div`\r\n padding: 1rem;\r\n margin-bottom: 1rem;\r\n position: relative;\r\n &.a-nocard {\r\n padding: 0px;\r\n }\r\n`\r\nclass Dev_Demo extends React.Component {\r\n render() {\r\n return (\r\n
\r\n Hello MyBase\r\n \r\n select2_api\r\n {\r\n return new Array(10).fill(1).map((v, i) => {\r\n return {\r\n Text: \"a\" + i,\r\n Value: i,\r\n }\r\n })\r\n },\r\n }}\r\n onChange={() => {}}\r\n />\r\n \r\n
\r\n )\r\n }\r\n}\r\n\r\n//add page dev\r\nDev_Demo.initPageDev = () => {\r\n MyPageHelpers.addTypesFromListLazy({\r\n dev_mybase: Dev_Demo,\r\n })\r\n HUtils.runFuntion(HCF.CF, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"dev_mybase\",\r\n UIUrl: \"/dev/mybase\",\r\n UIType: \"dev_mybase\",\r\n },\r\n ],\r\n ])\r\n}\r\n\r\nexport default Dev_Demo\r\n","import React from \"react\"\r\nimport MyPageHelpers from \"src/core/components/MyPage/MyPageHelpers\"\r\nimport { CSuppense } from \"src/core/components\"\r\nimport DevMyLibs from \"./Types/Dev_MyLib_All\"\r\nimport DevMyLayoutAll from \"./Types/Dev_MyLayout_All\"\r\nimport Dev_MyModal from \"./Types/Dev_MyModal\"\r\nimport Dev_MyLoading from \"./Types/Dev_MyLoading\"\r\nimport Dev_MyForm_All from \"./Types/Dev_MyForm_All\"\r\nimport Dev_MyBase_All from \"./Types/Dev_MyBase_All\"\r\n\r\nconst PDev_ListMyControl = React.lazy(() => import(\"./Types/Dev_ListMyControl\"))\r\nconst PDev_CategoryList = React.lazy(() => import(\"./Types/Dev_CategoryList\"))\r\nconst PDev_MyPage = React.lazy(() => import(\"./Types/Dev_MyPage\"))\r\nconst PDev_MyForm = React.lazy(() => import(\"./Types/Dev_MyForm\"))\r\nconst PDev_Notification = React.lazy(() => import(\"./Types/Dev_Notification\"))\r\nconst PDev_Other = React.lazy(() => import(\"./Types/Dev_Other\"))\r\nconst PDev_Resize = React.lazy(() => import(\"./Types/Dev_Resize\"))\r\nconst PDev_UseScript = React.lazy(() => import(\"./Types/Dev_UseScript\"))\r\nconst PDev_CustomHook = React.lazy(() => import(\"./Types/Dev_CustomHook\"))\r\nconst PDev_Common_Config = React.lazy(() => import(\"./Types/Dev_Common_Config\"))\r\nconst MyPageOne = {\r\n init() {\r\n DevMyLayoutAll.init()\r\n DevMyLibs.init()\r\n Dev_MyModal.initPageDev()\r\n Dev_MyLoading.initPageDev()\r\n Dev_MyForm_All.initPageDev()\r\n Dev_MyBase_All.initPageDev()\r\n //\r\n MyPageHelpers.addTypes(\"dev_listmycontrol\", props => {\r\n return CSuppense(props, PDev_ListMyControl)\r\n })\r\n MyPageHelpers.addTypes(\"dev_categorylist\", props => {\r\n return CSuppense(props, PDev_CategoryList)\r\n })\r\n MyPageHelpers.addTypes(\"dev_mypage\", props => {\r\n return CSuppense(props, PDev_MyPage)\r\n })\r\n MyPageHelpers.addTypes(\"dev_myform\", props => {\r\n return CSuppense(props, PDev_MyForm)\r\n })\r\n MyPageHelpers.addTypes(\"dev_notification\", props => {\r\n return CSuppense(props, PDev_Notification)\r\n })\r\n MyPageHelpers.addTypes(\"dev_other\", props => {\r\n return CSuppense(props, PDev_Other)\r\n })\r\n MyPageHelpers.addTypes(\"dev_resize\", props => {\r\n return CSuppense(props, PDev_Resize)\r\n })\r\n MyPageHelpers.addTypes(\"dev_hook\", props => {\r\n return CSuppense(props, PDev_UseScript)\r\n })\r\n MyPageHelpers.addTypes(\"dev_customhook\", props => {\r\n return CSuppense(props, PDev_CustomHook)\r\n })\r\n MyPageHelpers.addTypes(\"dev_common_config\", props => {\r\n return CSuppense(props, PDev_Common_Config)\r\n })\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import MyPageOne from \"./MyPage\"\r\nimport { runFuntion, isLocalDev } from \"src/core/helpers/utils\"\r\nimport HConstant from \"src/core/helpers/constant\"\r\nimport * as actions from \"src/App/App.actions\"\r\nimport { HCF } from \"@macashipo/mlib\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\ninterface IModuleDev extends IModuleOne {\r\n runAfterInit: (HConfig: any) => void\r\n}\r\nconst ModuleDev: IModuleDev = {\r\n runAfterInit: HConfig => {\r\n if (isLocalDev()) {\r\n HCF.setCF(KConfigApp.isDevMode, true)\r\n MyPageOne.init()\r\n //update routes\r\n runFuntion(HConfig, HConstant.HConfig.FnList.addPublicRoutes, [\r\n [\r\n {\r\n Id: \"dev1\",\r\n UIUrl: \"/dev/1\",\r\n UIType: \"dev_listmycontrol\",\r\n },\r\n {\r\n Id: \"dev2\",\r\n UIUrl: \"/dev/categorylist\",\r\n UIType: \"dev_categorylist\",\r\n },\r\n {\r\n Id: \"dev2\",\r\n UIUrl: \"/dev/mypage\",\r\n UIType: \"dev_mypage\",\r\n },\r\n {\r\n Id: \"devmyform\",\r\n UIUrl: \"/dev/myform\",\r\n UIType: \"dev_myform\",\r\n },\r\n {\r\n Id: \"devnotification\",\r\n UIUrl: \"/dev/notification\",\r\n UIType: \"dev_notification\",\r\n },\r\n {\r\n Id: \"devother\",\r\n UIUrl: \"/dev/other\",\r\n UIType: \"dev_other\",\r\n },\r\n {\r\n Id: \"devresize\",\r\n UIUrl: \"/dev/resize\",\r\n UIType: \"dev_resize\",\r\n },\r\n {\r\n Id: \"dev_hook\",\r\n UIUrl: \"/dev/hook\",\r\n UIType: \"dev_hook\",\r\n },\r\n {\r\n Id: \"dev_customhook\",\r\n UIUrl: \"/dev/customhook\",\r\n UIType: \"dev_customhook\",\r\n },\r\n {\r\n Id: \"dev_common_config\",\r\n UIUrl: \"/dev/common_config\",\r\n UIType: \"dev_common_config\",\r\n },\r\n ],\r\n ])\r\n\r\n //update sidenav\r\n runFuntion(HConfig.fnList, HConstant.HConfig.FnList.dispatchFromStore, [\r\n actions.sideNavUpdate([\r\n {\r\n isDev: true,\r\n name: \"Dev 1\",\r\n url: \"/dev/1\",\r\n },\r\n {\r\n isDev: true,\r\n name: \"Dev Category List\",\r\n url: \"/dev/categorylist\",\r\n },\r\n {\r\n isDev: true,\r\n name: \"Dev My Page\",\r\n url: \"/dev/mypage\",\r\n },\r\n {\r\n isDev: true,\r\n name: \"Dev My Form\",\r\n url: \"/dev/myform\",\r\n },\r\n {\r\n isDev: true,\r\n name: \"Dev Other\",\r\n url: \"/dev/other\",\r\n },\r\n ]),\r\n ])\r\n }\r\n },\r\n}\r\n\r\nexport default ModuleDev\r\n","import React from \"react\"\r\nimport { HUtils } from \"src/core/helpers\"\r\nimport { HUtils_getTextWithData } from \"src/helpers/Flows/MNeedUpdateMLib\"\r\nclass MyUI_HTML extends React.Component {\r\n render() {\r\n const { html, className, style, data, onClick, noReplaceData } = this.props\r\n // console.warn(\"MyUI_HTML:\",this.props);\r\n if (data && html && typeof data == \"object\" && noReplaceData !== true) {\r\n let _html = HUtils_getTextWithData(html, data)\r\n // console.warn(\"MyUI_HTML:\",_html);\r\n return (\r\n \r\n )\r\n } else if (html) {\r\n return (\r\n \r\n )\r\n }\r\n return
\r\n }\r\n}\r\n\r\nexport default MyUI_HTML\r\n","import { HFormat, HUtils } from \"@macashipo/mlib\"\r\n\r\nexport const KConfigMyUI = {\r\n type: \"type\",\r\n typeMyLayout: \"typeMyLayout\",\r\n moreProps: \"moreProps\",\r\n customProps: \"customProps\",\r\n customData: \"customData\", //lay data tu props\r\n customDataFormat: \"customDataFormat\", //customData bang HFormat\r\n notypemyui: \"notypemyui\",\r\n dataIsRow: \"dataIsRow\", //data is row chu ko phai cell, dung cho table cell\r\n}\r\n\r\nexport const getMoreProps = (props = {}) => {\r\n const config = props.config || {}\r\n let _moreProps = config.moreProps || {}\r\n if (config[KConfigMyUI.customProps]) {\r\n for (let k of Object.keys(config[KConfigMyUI.customProps])) {\r\n _moreProps[k] = HUtils.get(props, config[KConfigMyUI.customProps][k])\r\n }\r\n }\r\n return _moreProps\r\n}\r\nexport const getData = (props = {}) => {\r\n const config = props.config || {}\r\n const data = props.data\r\n if (data && typeof data == \"object\") {\r\n let _moreData = { ...data }\r\n if (config[KConfigMyUI.customData]) {\r\n for (let k of Object.keys(config[KConfigMyUI.customData])) {\r\n _moreData[k] = HUtils.get(props, config[KConfigMyUI.customData][k])\r\n }\r\n }\r\n if (config[KConfigMyUI.customDataFormat]) {\r\n for (let k of Object.keys(config[KConfigMyUI.customDataFormat])) {\r\n let _configFormat = config[KConfigMyUI.customDataFormat][k]\r\n if (_configFormat.type && HFormat.Types[_configFormat.type]) {\r\n let _value = _configFormat.value\r\n if (typeof _value == \"string\") {\r\n if (_value.indexOf(\"[\") > -1) {\r\n _value = HUtils.getTextWithData(_configFormat.value, data)\r\n } else if (_value.indexOf(\".\" > -1)) {\r\n _value = HUtils.get(props, _value)\r\n }\r\n }\r\n _moreData[k] = HFormat.format(_value, _configFormat)\r\n }\r\n }\r\n }\r\n // console.warn(\"_moreData\", _moreData)\r\n return _moreData\r\n }\r\n\r\n // console.warn(\"data\", data)\r\n return data\r\n}\r\nexport const getStyle = (props = {}) => {\r\n const config = props.config || {}\r\n const data = getData(props)\r\n const style = config.style || {}\r\n let _style = { ...style }\r\n // console.warn(\"getStyle\", _style)\r\n if (data && style && Object.keys(style).length > 0) {\r\n for (let k of Object.keys(style)) {\r\n if (_style[k] && _style[k].startsWith(\"[\")) {\r\n let _fieldName = _style[k].replace(\"[\", \"\").replace(\"]\", \"\")\r\n if (data.hasOwnProperty(_fieldName)) {\r\n _style[k] = data[_fieldName]\r\n }\r\n }\r\n }\r\n }\r\n return _style\r\n}\r\nexport const getTypeMyLayout = (config = {}) => {\r\n return config[KConfigMyUI.typeMyLayout] || \"div\"\r\n}\r\nexport const getTypeMyUI = (config = {}) => {\r\n return config[KConfigMyUI.type] || \"notypemyui\"\r\n}\r\n","import React from \"react\"\r\nimport { MyUI, MyLayout } from \"@macashipo/mlib\"\r\nimport { getData, getTypeMyLayout, getTypeMyUI, getStyle } from \"./_helpers\"\r\nclass MyUI_Data_Obj extends React.Component {\r\n render() {\r\n const { data } = this.props\r\n const config = this.props.config || {}\r\n let _configChild = config.configChild || {}\r\n // console.error(\"data_obj\", this.props)\r\n if (data != null) {\r\n return (\r\n \r\n \r\n \r\n )\r\n }\r\n return
\r\n }\r\n}\r\n\r\nexport default MyUI_Data_Obj\r\n","import React from \"react\"\r\nimport { MyUI, MyLayout } from \"@macashipo/mlib\"\r\nimport { getTypeMyLayout, getTypeMyUI, getStyle } from \"./_helpers\"\r\nclass MyUI_Data_Array extends React.Component {\r\n render() {\r\n const { data } = this.props\r\n const config = this.props.config || {}\r\n if (data && Array.isArray(data)) {\r\n return (\r\n \r\n {data.map((v, i) => {\r\n let _configChild = config.configChild || {}\r\n // console.warn(\"child:\", _configChild, v, config.type)\r\n return (\r\n \r\n )\r\n })}\r\n \r\n )\r\n }\r\n return
\r\n }\r\n}\r\n\r\nexport default MyUI_Data_Array\r\n","import React from \"react\"\r\nimport { HText, HUtils, MyUI } from \"@macashipo/mlib\"\r\nimport { getData, getMoreProps, getStyle, getTypeMyUI } from \"./_helpers\"\r\nimport { HUtils_getTextWithData } from \"src/helpers/Flows/MNeedUpdateMLib\"\r\nclass MyUI_Data_Tag extends React.Component {\r\n render() {\r\n const config = this.props.config || {}\r\n const data = getData(this.props)\r\n let _configChild = config.configChild\r\n // console.error(\"data_tag\", this.props)\r\n let Tag = config.tag || \"div\"\r\n let _moreProps = getMoreProps(this.props)\r\n let _childIsMyUI = true\r\n let _childIsText = false\r\n let _textDisplay = \"\"\r\n if (typeof _configChild == \"string\" || _configChild == null) {\r\n _childIsMyUI = false\r\n _childIsText = true\r\n if (_configChild) {\r\n if (data && data[_configChild]) {\r\n _textDisplay = data[_configChild]\r\n } else {\r\n _textDisplay = HUtils_getTextWithData(_configChild, data)\r\n }\r\n }\r\n //neu ko phai myui thi chuyen quanh children\r\n _moreProps.children = _textDisplay\r\n }\r\n // console.warn(\"childs:\", _childIsMyUI, _moreProps)\r\n if (_childIsMyUI === false) {\r\n //vidu the img, ko the co props childrens -> bao loi -> bo children di mac du da ko show\r\n return (\r\n \r\n )\r\n }\r\n return (\r\n \r\n {_childIsMyUI && (\r\n \r\n )}\r\n {_childIsText && _textDisplay}\r\n
\r\n )\r\n }\r\n}\r\n\r\nexport default MyUI_Data_Tag\r\n","import React from \"react\"\r\nimport { HText, HUtils, MyUI } from \"@macashipo/mlib\"\r\nimport { getData, getMoreProps, getStyle, getTypeMyUI } from \"./_helpers\"\r\nimport { HUtils_getTextWithData } from \"src/helpers/Flows/MNeedUpdateMLib\"\r\nclass MyUI_Data_Tag extends React.Component {\r\n constructor(props) {\r\n super(props)\r\n this._fontSize = 1\r\n }\r\n render() {\r\n const config = this.props.config || {}\r\n const data = getData(this.props)\r\n let _configChild = config.configChild\r\n // console.error(\"data_tag\", this.props)\r\n let Tag = config.tag || \"span\"\r\n let _moreProps = getMoreProps(this.props)\r\n let _childIsMyUI = true\r\n let _childIsText = false\r\n let _textDisplay = \"\"\r\n if (typeof _configChild == \"string\" || _configChild == null) {\r\n _childIsMyUI = false\r\n _childIsText = true\r\n if (_configChild) {\r\n if (data && data[_configChild]) {\r\n _textDisplay = data[_configChild]\r\n } else {\r\n _textDisplay = HUtils_getTextWithData(_configChild, data)\r\n }\r\n }\r\n //neu ko phai myui thi chuyen quanh children\r\n _moreProps.children = _textDisplay\r\n }\r\n let _style = getStyle(this.props)\r\n if (_style.fontSize) {\r\n let _fontSizeInStyle = Number(_style.fontSize.replace(/[^0-9]/g, \"\"))\r\n if (_fontSizeInStyle != this._fontSize && this._fontSize == 1) {\r\n this._fontSize = _fontSizeInStyle\r\n }\r\n }\r\n let _minFontSize = config.minFontSize || 6\r\n _style.fontSize = `${this._fontSize}px`\r\n return (\r\n {\r\n if (r) {\r\n // console.warn(\"refff\", r, r.clientHeight, r.scrollHeight)\r\n if (\r\n r.clientHeight < r.scrollHeight &&\r\n this._fontSize > _minFontSize\r\n ) {\r\n this._fontSize -= 1\r\n this.forceUpdate()\r\n } else if (\r\n r.clientWidth < r.scrollWidth &&\r\n this._fontSize > _minFontSize\r\n ) {\r\n this._fontSize -= 1\r\n this.forceUpdate()\r\n }\r\n }\r\n }}\r\n />\r\n )\r\n }\r\n}\r\n\r\nexport default MyUI_Data_Tag\r\n","import React from \"react\"\r\n\r\nclass StateLoading extends React.Component {\r\n componentDidMount() {}\r\n\r\n render() {\r\n return
Loading...
\r\n }\r\n}\r\n\r\nexport default StateLoading\r\n","import React from \"react\"\r\nimport styled from \"styled-components\"\r\nimport i18next from \"i18next\"\r\nclass StateError extends React.Component {\r\n componentDidMount() {}\r\n\r\n render() {\r\n const configError = this.props.configError || {}\r\n const error = this.props.error\r\n let msgError = String(error)\r\n if (error && typeof error == \"object\") {\r\n if (error[\"msg\"]) {\r\n msgError = error[\"msg\"]\r\n }\r\n }\r\n console.log(\"error:\", error)\r\n return (\r\n \r\n
Error!
\r\n
{msgError || i18next.t(\"Something went wrong\")}
\r\n {configError.onTryAgain && (\r\n
\r\n {\r\n configError.onTryAgain()\r\n }}\r\n >\r\n {i18next.t(\"Try again\")}\r\n \r\n
\r\n )}\r\n
\r\n )\r\n }\r\n}\r\n\r\nconst WrapUI = styled.div`\r\n text-align: center;\r\n & .a-title {\r\n font-weight: bold;\r\n }\r\n`\r\nexport default StateError\r\n","import { MyUI } from \"@macashipo/mlib\"\r\nimport React from \"react\"\r\n\r\nclass StateWrap extends React.Component {\r\n componentDidMount() {}\r\n\r\n render() {\r\n const { loading, error, configError, configLoading } = this.props\r\n // console.log(\"render wrap:\", loading, error)\r\n if (loading == true) {\r\n return \r\n }\r\n //bo sung chi show error khi loading===false\r\n if (loading == false && error != null) {\r\n return \r\n }\r\n return this.props.children\r\n }\r\n}\r\n\r\nexport default StateWrap\r\n","import React from \"react\"\r\nimport { MyUIHelpers } from \"@macashipo/mlib\"\r\nimport MUI_html from \"./Types/html\"\r\nimport MUI_data_obj from \"./Types/data_obj\"\r\nimport MUI_data_array from \"./Types/data_array\"\r\nimport MUI_data_tag from \"./Types/data_tag\"\r\nimport MUI_data_span_autoresize from \"./Types/data_span_autoresize\"\r\n\r\nimport MUI_state_loading from \"./Types/state_loading\"\r\nimport MUI_state_error from \"./Types/state_error\"\r\nimport MUI_state_wrap from \"./Types/state_wrap\"\r\n\r\nconst ListNoLazy = {\r\n html: MUI_html,\r\n data_obj: MUI_data_obj,\r\n data_array: MUI_data_array,\r\n data_tag: MUI_data_tag,\r\n data_span_autoresize: MUI_data_span_autoresize,\r\n state_error: MUI_state_error,\r\n state_loading: MUI_state_loading,\r\n state_wrap: MUI_state_wrap,\r\n}\r\nconst MyUIOne = {\r\n init() {\r\n MyUIHelpers.addTypesFromListWithoutLazy(ListNoLazy)\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","import React from \"react\"\r\nimport { MyLayoutHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MUI_grid_autofit = React.lazy(() => import(\"./Types/grid_autofit\"))\r\nconst MUI_grid = React.lazy(() => import(\"./Types/grid\"))\r\nconst MUI_title_content = React.lazy(() => import(\"./Types/title_content\"))\r\nconst MUI_flex = React.lazy(() => import(\"./Types/flex\"))\r\nconst MUI_div = React.lazy(() => import(\"./Types/div\"))\r\nconst List = {\r\n title_content: MUI_title_content,\r\n grid: MUI_grid,\r\n grid_autofit: MUI_grid_autofit,\r\n flex: MUI_flex,\r\n div: MUI_div,\r\n}\r\nconst MyUIOne = {\r\n init() {\r\n MyLayoutHelpers.addTypesFromListWithoutLazy(List)\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","import React from \"react\"\r\nimport { MyPageHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MUI_simulator_sender_email = React.lazy(() =>\r\n import(\"./Types/simulator_sender_email\")\r\n)\r\n\r\nconst List = {\r\n simulator_sender_email: MUI_simulator_sender_email,\r\n}\r\nconst MyPageOne = {\r\n init() {\r\n MyPageHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import React from \"react\"\r\nimport { MyUI, MyLayout } from \"@macashipo/mlib\"\r\nclass MC_with_myui extends React.Component {\r\n render() {\r\n const config = this.props.config || {}\r\n const configMyUI = config.myui || {}\r\n return (\r\n \r\n )\r\n }\r\n}\r\n\r\nexport default MC_with_myui\r\n","import React from \"react\"\r\nimport { MyCardHelpers } from \"@macashipo/mlib\"\r\nimport MC_with_myui from \"./Types/with_myui\"\r\nconst ListNoLazy = {\r\n with_myui: MC_with_myui,\r\n}\r\nconst MyCardOne = {\r\n init() {\r\n MyCardHelpers.addTypesFromListWithoutLazy(ListNoLazy)\r\n },\r\n}\r\n\r\nexport default MyCardOne\r\n","import React from \"react\"\r\nimport { MyLoadingHelpers, CSuppense } from \"@macashipo/mlib\"\r\n\r\nconst ML_threedotsvertical = React.lazy(() =>\r\n import(\"./Types/threedotsvertical\")\r\n)\r\nconst ML_arc = React.lazy(() => import(\"./Types/arc\"))\r\nconst ML_lds_ellipsis = React.lazy(() => import(\"./Types/lds_ellipsis\"))\r\nconst List = {\r\n arc: ML_arc,\r\n threedotsvertical: ML_threedotsvertical,\r\n lds_ellipsis: ML_lds_ellipsis,\r\n}\r\nconst MyPageOne = {\r\n init() {\r\n if (List) {\r\n let _keys = Object.keys(List)\r\n if (_keys && _keys.length > 0) {\r\n for (let k of Object.keys(List)) {\r\n MyLoadingHelpers.addTypes(k, props => {\r\n return CSuppense(props, List[k])\r\n })\r\n }\r\n }\r\n }\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import MyUIOne from \"./MyUI\"\r\nimport MyLayoutOne from \"./MyLayout\"\r\nimport MyPageOne from \"./MyPage\"\r\nimport MyCardOne from \"./MyCard\"\r\nimport MyLoadingOne from \"./MyLoading\"\r\ninterface IModuleCorePage extends IModuleOne {\r\n runAfterInit: () => void\r\n}\r\nconst ModuleCorePage: IModuleCorePage = {\r\n runAfterInit: () => {\r\n MyLayoutOne.init()\r\n MyUIOne.init()\r\n MyPageOne.init()\r\n MyCardOne.init()\r\n MyLoadingOne.init()\r\n },\r\n}\r\n\r\nexport default ModuleCorePage\r\n","import ReactGA from \"react-ga\"\r\nimport ReactGA4 from \"react-ga4\"\r\nimport { HModules, HCF, HLink, HUtils } from \"@macashipo/mlib\"\r\nconst trackPageView = (url = \"\") => {\r\n console.log(\"trackPageView\", url, window.gtag)\r\n if (ModuleReactGA._config.isUniversal) {\r\n ReactGA.send({\r\n hitType: \"pageview\",\r\n page: url,\r\n })\r\n } else {\r\n ReactGA4.send({\r\n hitType: \"pageview\",\r\n page: url,\r\n })\r\n }\r\n}\r\nconst initGA = GAId => {\r\n if (ModuleReactGA._config.isUniversal) {\r\n ReactGA.initialize(GAId)\r\n ModuleReactGA._config.initGAdone = true\r\n } else {\r\n ReactGA4.initialize(GAId)\r\n ModuleReactGA._config.initGAdone = true\r\n }\r\n if (GAId === ModuleReactGA._config.GAIdDev) {\r\n ModuleReactGA._config.isUsingDev = true\r\n }\r\n}\r\nconst ModuleReactGA = {\r\n _key: \"reactga\",\r\n _fnList: {\r\n gaTrackCurrentPageView: () => {\r\n if (ModuleReactGA._config.initGAdone) {\r\n if (ModuleReactGA._config.isUsingDev) {\r\n trackPageView(`/${HCF.getCF(\"appName\")}/${window.location.href}`)\r\n } else {\r\n trackPageView(\r\n window.location.pathname +\r\n window.location.search +\r\n window.location.hash\r\n )\r\n }\r\n }\r\n },\r\n gaTrackPageView: ({ page } = {}) => {\r\n if (ModuleReactGA._config.initGAdone) {\r\n trackPageView(page)\r\n }\r\n },\r\n gaTrackEvent: ({ category, action }) => {\r\n if (ModuleReactGA._config.initGAdone) {\r\n ReactGA.event({\r\n category: category,\r\n action: action,\r\n })\r\n }\r\n },\r\n },\r\n _config: {\r\n initGAdone: false,\r\n isUsingDev: false,\r\n isUniversal: true,\r\n GAIdDev: \"UA-119777650-2\",\r\n },\r\n getMyKey: () => {\r\n return \"reactga\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleReactGA, {})\r\n var GAId = HCF.getCF(\"GAId\") || ModuleReactGA._config.GAIdDev\r\n if (HUtils.isLocalDev()) {\r\n GAId = ModuleReactGA._config.GAIdDev\r\n }\r\n if (GAId && GAId.indexOf(\"UA\") > -1) {\r\n ModuleReactGA._config.isUniversal = true\r\n } else {\r\n ModuleReactGA._config.isUniversal = false\r\n }\r\n if (GAId) {\r\n initGA(GAId)\r\n //settimeout de lay title cho dung\r\n setTimeout(() => {\r\n HModules.runFunctionInModuleFnList(\r\n \"reactga\",\r\n \"gaTrackCurrentPageView\",\r\n []\r\n )\r\n }, 500)\r\n const history = HLink.getHistory()\r\n if (history && history.listen) {\r\n history.listen(h => {\r\n console.log(\"change history\")\r\n HModules.runFunctionInModuleFnList(\r\n \"reactga\",\r\n \"gaTrackCurrentPageView\",\r\n []\r\n )\r\n })\r\n }\r\n }\r\n },\r\n}\r\n\r\nexport default ModuleReactGA\r\n","import React from \"react\"\r\nimport { MyPageHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MyPageWelcome = React.lazy(() => import(\"./Types/welcome\"))\r\nconst MP_iframe = React.lazy(() => import(\"./Types/iframe\"))\r\nconst MyPageAdminTab = React.lazy(() => import(\"./Types/admin_tab\"))\r\nconst MyPageAdminTable = React.lazy(() => import(\"./Types/admin_table\"))\r\nconst MyPageAdminPanel = React.lazy(() => import(\"./Types/admin_panel\"))\r\nconst MyPageAdminPanelGrid = React.lazy(() =>\r\n import(\"./Types/admin_panel_grid\")\r\n)\r\nconst MyPageAdminTableClient = React.lazy(() =>\r\n import(\"./Types/admin_table_client\")\r\n)\r\nconst MyPageAdminPageNotFound = React.lazy(() =>\r\n import(\"./Types/admin_pagenotfound\")\r\n)\r\nconst MyPageWithMyUI = React.lazy(() => import(\"./Types/with_myui\"))\r\nconst MyPageAdminDashboard = React.lazy(() => import(\"./Types/admin_dashboard\"))\r\nconst MyPageAdminList = React.lazy(() => import(\"./Types/admin_table_list\"))\r\nconst MyPageAdminListCard = React.lazy(() =>\r\n import(\"./Types/admin_table_list_card\")\r\n)\r\nconst MyPageAdminGridCard = React.lazy(() =>\r\n import(\"./Types/admin_table_grid_card\")\r\n)\r\nconst MP_API_Document = React.lazy(() => import(\"./Types/api_document\"))\r\nconst MyPageMyProfile = React.lazy(() => import(\"./Types/myprofile\"))\r\nconst MP_MyProfileSignatureEmail = React.lazy(() =>\r\n import(\"./Types/myprofile_signature_email\")\r\n)\r\nconst MP_MyProfileSignaturePhoto = React.lazy(() =>\r\n import(\"./Types/myprofile_signature_photo\")\r\n)\r\nconst MyPageApiRequest = React.lazy(() => import(\"./Types/api_request\"))\r\nconst MP_redirect = React.lazy(() => import(\"./Types/redirect\"))\r\nconst MP_mobile_dashboard = React.lazy(() => import(\"./Types/mobile_dashboard\"))\r\nconst MP_chart_chartjs = React.lazy(() => import(\"./Types/chart_chartjs\"))\r\nconst MP_chart = React.lazy(() => import(\"./Types/chart\"))\r\nconst MP_grid = React.lazy(() => import(\"./Types/grid\"))\r\nconst MP_wrap = React.lazy(() => import(\"./Types/wrap\"))\r\nconst MP_calendar = React.lazy(() => import(\"./Types/calendar\"))\r\nconst MP_dashboard_one = React.lazy(() => import(\"./Types/dashboard_one\"))\r\nconst MP_flow = React.lazy(() => import(\"./Types/flow\"))\r\nconst MP_html = React.lazy(() => import(\"./Types/html\"))\r\nconst MP_admin_tab_client = React.lazy(() => import(\"./Types/admin_tab_client\"))\r\n\r\n// Report\r\nconst MP_report = React.lazy(() => import(\"./Types/report\"))\r\nconst MP_report_html = React.lazy(() => import(\"./TypesReport/report_html\"))\r\nconst MP_report_array_html = React.lazy(() =>\r\n import(\"./TypesReport/report_array_html\")\r\n)\r\nconst MP_report_array_photo = React.lazy(() =>\r\n import(\"./TypesReport/report_array_photo\")\r\n)\r\nconst MP_report_table = React.lazy(() => import(\"./TypesReport/report_table\"))\r\nconst MP_report_chart = React.lazy(() => import(\"./TypesReport/report_chart\"))\r\nconst MP_report_signature = React.lazy(() =>\r\n import(\"./TypesReport/report_signature\")\r\n)\r\nconst MP_report_layout = React.lazy(() => import(\"./TypesReport/report_layout\"))\r\nconst MP_report_multi_table = React.lazy(() =>\r\n import(\"./TypesReport/report_multi_table\")\r\n)\r\nconst MP_report_title_browser = React.lazy(() =>\r\n import(\"./TypesReport/report_title_browser\")\r\n)\r\n//Dashboard\r\nconst MP_widget = React.lazy(() => import(\"./Types/widget\"))\r\nconst MP_multi_table = React.lazy(() => import(\"./Types/multi_table\"))\r\nconst MP_survey = React.lazy(() => import(\"./Types/survey\"))\r\n\r\nconst MP_map_goong = React.lazy(() => import(\"./Types/map_goong\"))\r\n\r\nconst List = {\r\n map_goong: MP_map_goong,\r\n survey: MP_survey,\r\n multi_table: MP_multi_table,\r\n widget: MP_widget,\r\n //report\r\n report: MP_report,\r\n report_title_browser: MP_report_title_browser,\r\n report_html: MP_report_html,\r\n report_table: MP_report_table,\r\n report_array_html: MP_report_array_html,\r\n report_array_photo: MP_report_array_photo,\r\n report_chart: MP_report_chart,\r\n report_signature: MP_report_signature,\r\n report_layout: MP_report_layout,\r\n report_multi_table: MP_report_multi_table,\r\n admin_tab_client: MP_admin_tab_client,\r\n html: MP_html,\r\n flow: MP_flow,\r\n dashboard_one: MP_dashboard_one,\r\n calendar: MP_calendar,\r\n grid: MP_grid,\r\n wrap: MP_wrap,\r\n chart_chartjs: MP_chart_chartjs,\r\n chart: MP_chart,\r\n admin_tab: MyPageAdminTab,\r\n admin_table: MyPageAdminTable,\r\n admin_panel: MyPageAdminPanel,\r\n admin_pagenotfound: MyPageAdminPageNotFound,\r\n admin_table_client: MyPageAdminTableClient,\r\n admin_dashboard: MyPageAdminDashboard,\r\n admin_table_list: MyPageAdminList,\r\n admin_table_list_card: MyPageAdminListCard,\r\n admin_table_grid_card: MyPageAdminGridCard,\r\n welcome: MyPageWelcome,\r\n with_myui: MyPageWithMyUI,\r\n //default type\r\n panel: MyPageAdminPanel,\r\n panel_grid: MyPageAdminPanelGrid,\r\n table: MyPageAdminTable,\r\n tab: MyPageAdminTab,\r\n table_list: MyPageAdminList,\r\n table_list_card: MyPageAdminListCard,\r\n table_grid_card: MyPageAdminGridCard,\r\n myprofile: MyPageMyProfile,\r\n myprofile_signature_email: MP_MyProfileSignatureEmail,\r\n myprofile_signature_photo: MP_MyProfileSignaturePhoto,\r\n // api_document: MP_API_Document,\r\n api_request: MyPageApiRequest,\r\n iframe: MP_iframe,\r\n redirect: MP_redirect,\r\n mobile_dashboard: MP_mobile_dashboard,\r\n}\r\nconst MyPageOne = {\r\n init() {\r\n MyPageHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import { HFormat, MyUI } from \"@macashipo/mlib\"\r\nimport React from \"react\"\r\nimport styled from \"styled-components\"\r\n\r\nconst Wrap = styled.div`\r\n width: 100%;\r\n display: grid;\r\n gap: 10px 1%;\r\n`\r\nexport default function MUIGrid(props) {\r\n const { data, typeItem, numCol } = props\r\n let _templateColumns = \"\"\r\n let _numCol = HFormat.format(numCol, {\r\n type: \"numColByWidth\",\r\n defaultValue: 5,\r\n })\r\n for (let i = 0; i < _numCol; i++) {\r\n _templateColumns += \"1fr\"\r\n if (i < _numCol - 1) {\r\n _templateColumns += \" \"\r\n }\r\n }\r\n if (props.minmaxAutoFit) {\r\n _templateColumns = `repeat(auto-fit, minmax(${props.minmaxAutoFit}px, 1fr))`\r\n } else if (props.minmaxAutoFill) {\r\n _templateColumns = `repeat(auto-fill, minmax(${props.minmaxAutoFit}px, 1fr))`\r\n }\r\n // console.warn(\"render grid:\", _numCol, _templateColumns)\r\n return (\r\n \r\n {data &&\r\n data.length > 0 &&\r\n data.map((v, i) => {\r\n if (props.renderItem) {\r\n return props.renderItem(v, i)\r\n }\r\n return (\r\n \r\n )\r\n })}\r\n \r\n )\r\n}\r\n","import React from \"react\"\r\nimport { MyUIHelpers } from \"@macashipo/mlib\"\r\nimport MUIGrid from \"./Types/grid\"\r\nconst MUIATHeader = React.lazy(() => import(\"./Types/admintable_header\"))\r\nconst MUIATChart = React.lazy(() => import(\"./Types/admintable_chart\"))\r\nconst MUIATHeaderDetail = React.lazy(() =>\r\n import(\"./Types/admintable_header_detail\")\r\n)\r\nconst MUIATHeaderMini = React.lazy(() =>\r\n import(\"./Types/admintable_header_mini\")\r\n)\r\nconst MUIATHeaderButtons = React.lazy(() =>\r\n import(\"./Types/admintable_header_buttons\")\r\n)\r\nconst MUIATFilter = React.lazy(() => import(\"./Types/admintable_filter\"))\r\nconst MUIATFilterDetail = React.lazy(() =>\r\n import(\"./Types/admintable_filter_detail\")\r\n)\r\nconst MUIATTable = React.lazy(() => import(\"./Types/admintable_table\"))\r\nconst MUIATTableDetails = React.lazy(() =>\r\n import(\"./Types/admintable_table\").then(module => ({\r\n default: module.MUIATTableDetails,\r\n }))\r\n)\r\nconst MUIATTableList = React.lazy(() => import(\"./Types/admintable_table_list\"))\r\nconst MUIATTableListCard = React.lazy(() =>\r\n import(\"./Types/admintable_table_list_card\")\r\n)\r\nconst MUIATTableGridCard = React.lazy(() =>\r\n import(\"./Types/admintable_table_grid_card\")\r\n)\r\nconst MUIATTableCalendar = React.lazy(() =>\r\n import(\"./Types/admintable_table_calendar\")\r\n)\r\nconst MUISelectBox = React.lazy(() => import(\"./Types/select_box\"))\r\nconst MUISelectBoxSearch = React.lazy(() => import(\"./Types/select_box_search\"))\r\nconst MUI_select_box_search_paging = React.lazy(() =>\r\n import(\"./Types/select_box_search_paging\")\r\n)\r\nconst MUISelectBoxSearchV2 = React.lazy(() =>\r\n import(\"./Types/select_box_search_v2\")\r\n)\r\nconst MUISelectCheckBoxSearch = React.lazy(() =>\r\n import(\"./Types/selectcheck_box_search\")\r\n)\r\nconst MUIMsgBoxConfirm = React.lazy(() => import(\"./Types/msgbox_confirm\"))\r\nconst MUIMsgBoxError = React.lazy(() => import(\"./Types/msgbox_error\"))\r\nconst MUIAnimate = React.lazy(() => import(\"./Types/animate\"))\r\nconst MUIFileManager = React.lazy(() => import(\"./Types/file_manager\"))\r\nconst MUIFileManagerItem = React.lazy(() => import(\"./Types/file_manager_item\"))\r\nconst MUIArrTags = React.lazy(() => import(\"./Types/arr_tags\"))\r\nconst MUIActionMenu = React.lazy(() => import(\"./Types/actions_menu\"))\r\nconst MUILayoutSquare = React.lazy(() => import(\"./Types/layout_square\"))\r\nconst MUISearchBox = React.lazy(() => import(\"./Types/search_box\"))\r\nconst MUIATFilterPopover = React.lazy(() =>\r\n import(\"./Types/admintable_filter_popover\")\r\n)\r\nconst MUIWrapCellOnModal = React.lazy(() => import(\"./Types/_wrapCellOnModal\"))\r\nconst MUIWrapEditRowInCard = React.lazy(() =>\r\n import(\"./Types/_wrapEditRowInCard\")\r\n)\r\nconst MUI_avatar = React.lazy(() => import(\"./Types/avatar\"))\r\nconst MUI_html_canedit = React.lazy(() => import(\"./Types/html_canedit\"))\r\nconst MUI_Api_Client = React.lazy(() => import(\"./Types/api_client\"))\r\nconst MUI_Select_Box_Search_Virtualized = React.lazy(() =>\r\n import(\"./Types/select_box_search_virtualized\")\r\n)\r\nconst MUI_Block_Mobile = React.lazy(() => import(\"./Types/block_mobile\"))\r\nconst MUI_Obj_Editor = React.lazy(() => import(\"./Types/obj_editor\"))\r\nconst MUI_Json_Viewer = React.lazy(() => import(\"./Types/json_viewer\"))\r\nconst MUI_timeline = React.lazy(() => import(\"./Types/timeline\"))\r\nconst MUI_list_check = React.lazy(() => import(\"./Types/list_check\"))\r\nconst MUI_list_check_api = React.lazy(() => import(\"./Types/list_check_api\"))\r\nconst MUI_table_check = React.lazy(() => import(\"./Types/table_check\"))\r\n\r\nconst MUI_diffview = React.lazy(() => import(\"./Types/diffview\"))\r\nconst MUI_modal_request_diffview = React.lazy(() =>\r\n import(\"./Types/modal_request_diffview\")\r\n)\r\nconst MUI_search_box_withdata = React.lazy(() =>\r\n import(\"./Types/search_box_withdata\")\r\n)\r\nconst MUI_btn_take_photo = React.lazy(() => import(\"./Types/btn_take_photo\"))\r\nconst MUI_scanqrcode = React.lazy(() => import(\"./Types/scanqrcode\"))\r\nconst MUI_admintable_flow = React.lazy(() => import(\"./Types/admintable_flow\"))\r\nconst MUI_select_month = React.lazy(() => import(\"./Types/select_month\"))\r\nconst MUI_print_bill = React.lazy(() => import(\"./Types/print_bill\"))\r\nconst MUI_map_goong = React.lazy(() => import(\"./Types/map_goong\"))\r\n\r\n//Custom\r\nconst MUI_masu_addproduct = React.lazy(() => import(\"./Custom/masu_addproduct\"))\r\nconst MUI_masu_cell_attribute = React.lazy(() =>\r\n import(\"./Custom/masu_cell_attribute\")\r\n)\r\nconst MUI_masu_cell_editproduct = React.lazy(() =>\r\n import(\"./Custom/masu_cell_editproduct\")\r\n)\r\nconst List = {\r\n _wrapEditRowInCard: MUIWrapEditRowInCard,\r\n _wrapCellOnModal: MUIWrapCellOnModal,\r\n //Custom\r\n masu_addproduct: MUI_masu_addproduct,\r\n masu_cell_attribute: MUI_masu_cell_attribute,\r\n masu_cell_editproduct: MUI_masu_cell_editproduct,\r\n //Types\r\n map_goong: MUI_map_goong,\r\n print_bill: MUI_print_bill,\r\n select_month: MUI_select_month,\r\n html_canedit: MUI_html_canedit,\r\n admintable_flow: MUI_admintable_flow,\r\n scanqrcode: MUI_scanqrcode,\r\n btn_take_photo: MUI_btn_take_photo,\r\n search_box_withdata: MUI_search_box_withdata,\r\n avatar: MUI_avatar,\r\n json_viewer: MUI_Json_Viewer,\r\n timeline: MUI_timeline,\r\n admintable_filter_popover: MUIATFilterPopover,\r\n admintable_chart: MUIATChart,\r\n search_box: MUISearchBox,\r\n layout_square: MUILayoutSquare,\r\n actions_menu: MUIActionMenu,\r\n arr_tags: MUIArrTags,\r\n selectcheck_box_search: MUISelectCheckBoxSearch,\r\n admintable_header: MUIATHeader,\r\n admintable_header_detail: MUIATHeaderDetail,\r\n admintable_header_mini: MUIATHeaderMini,\r\n admintable_header_buttons: MUIATHeaderButtons,\r\n admintable_filter: MUIATFilter,\r\n admintable_filter_detail: MUIATFilterDetail,\r\n admintable_table: MUIATTable,\r\n admintable_table_details: MUIATTableDetails,\r\n admintable_table_list: MUIATTableList,\r\n admintable_table_list_card: MUIATTableListCard,\r\n admintable_table_grid_card: MUIATTableGridCard,\r\n admintable_table_calendar: MUIATTableCalendar,\r\n select_box: MUISelectBox,\r\n select_box_search: MUISelectBoxSearch,\r\n select_box_search_paging: MUI_select_box_search_paging,\r\n select_box_search_v2: MUISelectBoxSearchV2,\r\n msgbox_confirm: MUIMsgBoxConfirm,\r\n msgbox_error: MUIMsgBoxError,\r\n animate: MUIAnimate,\r\n file_manager: MUIFileManager,\r\n file_manager_item: MUIFileManagerItem,\r\n api_client: MUI_Api_Client,\r\n select_box_search_virtualized: MUI_Select_Box_Search_Virtualized,\r\n block_mobile: MUI_Block_Mobile,\r\n obj_editor: MUI_Obj_Editor,\r\n list_check: MUI_list_check,\r\n list_check_api: MUI_list_check_api,\r\n table_check: MUI_table_check,\r\n diffview: MUI_diffview,\r\n modal_request_diffview: MUI_modal_request_diffview,\r\n}\r\n\r\nconst ListNoLazy = {\r\n grid: MUIGrid,\r\n}\r\nconst MyUIOne = {\r\n init() {\r\n MyUIHelpers.addTypesFromListLazy(List)\r\n MyUIHelpers.addTypesFromListWithoutLazy(ListNoLazy)\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","import React from \"react\"\r\nimport { MyButtonHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MB_link = React.lazy(() => import(\"./Types/link\"))\r\nconst MB_api = React.lazy(() => import(\"./Types/api\"))\r\nconst MB_api_select = React.lazy(() => import(\"./Types/api_select\"))\r\nconst MB_form = React.lazy(() => import(\"./Types/form\"))\r\nconst MB_add_new = React.lazy(() => import(\"./Types/add_new\"))\r\nconst MB_upload = React.lazy(() => import(\"./Types/upload\"))\r\nconst MB_print = React.lazy(() => import(\"./Types/print\"))\r\nconst MB_switch_view = React.lazy(() => import(\"./Types/switch_view\"))\r\nconst MB_switch_request = React.lazy(() => import(\"./Types/switch_request\"))\r\nconst MB_modal = React.lazy(() => import(\"./Types/modal\"))\r\nconst MB_modal_page = React.lazy(() => import(\"./Types/modal_page\"))\r\nconst MB_group = React.lazy(() => import(\"./Types/group\"))\r\nconst MB_linktaga = React.lazy(() => import(\"./Types/linktaga\"))\r\nconst MB_action_fnList = React.lazy(() => import(\"./Types/action_fnList\"))\r\nconst MB_tutor = React.lazy(() => import(\"./Types/tutor\"))\r\nconst MB_modal_html = React.lazy(() => import(\"./Types/modal_html\"))\r\nconst MB_info_from_api = React.lazy(() => import(\"./Types/info_from_api\"))\r\nconst MB_input_qr = React.lazy(() => import(\"./Types/input_qr\"))\r\nconst MB_with_myui = React.lazy(() => import(\"./Types/with_myui\"))\r\n\r\n//Custom\r\nconst MB_select_to_diffview = React.lazy(() =>\r\n import(\"./TypesClient/select_to_diffview\")\r\n)\r\n\r\nconst List = {\r\n with_myui: MB_with_myui,\r\n input_qr: MB_input_qr,\r\n info_from_api: MB_info_from_api,\r\n modal_html: MB_modal_html,\r\n tutor: MB_tutor,\r\n action_fnList: MB_action_fnList,\r\n linktaga: MB_linktaga,\r\n link: MB_link,\r\n api: MB_api,\r\n api_select: MB_api_select,\r\n form: MB_form,\r\n add_new: MB_add_new,\r\n upload: MB_upload,\r\n print: MB_print,\r\n switch_view: MB_switch_view,\r\n switch_request: MB_switch_request,\r\n modal: MB_modal,\r\n modal_page: MB_modal_page,\r\n group: MB_group,\r\n //custom\r\n select_to_diffview: MB_select_to_diffview,\r\n}\r\nconst MyButtonOne = {\r\n init() {\r\n MyButtonHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyButtonOne\r\n","import React from \"react\"\r\nimport { MyLayoutHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MyLayoutArchitect = React.lazy(() => import(\"./Types/architect/index\"))\r\nconst ML_wfc_inline = React.lazy(() => import(\"./Types/wfc_inline\"))\r\nconst List = {\r\n admin_panel: MyLayoutArchitect,\r\n wfc_inline: ML_wfc_inline,\r\n}\r\nconst MyLayoutOne = {\r\n init() {\r\n MyLayoutHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyLayoutOne\r\n","import React from \"react\"\r\nimport { MyTableCellHelpers, HUtils, HJson, HCF } from \"@macashipo/mlib\"\r\nimport { FlowGetCanShow, KMore } from \"src/helpers/Flows/TableCell\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\n\r\nconst MTCReadonly = React.lazy(() => import(\"./Types/readonly\"))\r\n// const MTCText = React.lazy(() => import(\"./Types/text\"))\r\nconst MTCTextarea = React.lazy(() => import(\"./Types/textarea\"))\r\nconst MTC_textarea_with_count = React.lazy(() =>\r\n import(\"./Types/textarea_with_count\")\r\n)\r\nconst MTCApi = React.lazy(() => import(\"./Types/api\"))\r\nconst MTCJsonEditor = React.lazy(() => import(\"./Types/json_editor\"))\r\nconst MTCCheckbox = React.lazy(() => import(\"./Types/checkbox\"))\r\nconst MTCCheckboxNull = React.lazy(() => import(\"./Types/checkbox_null\"))\r\nconst MTCExpandMulti = React.lazy(() => import(\"./Types/expand_multi\"))\r\n// const MTCSelect = React.lazy(() => import(\"./Types/select\"))\r\nconst MTCSelect2Modal = React.lazy(() => import(\"./Types/select2_modal\"))\r\nconst MTCSelect2ModalApi = React.lazy(() => import(\"./Types/select2_modal_api\"))\r\nconst MTCSelectModern = React.lazy(() => import(\"./Types/select_modern\"))\r\nconst MTCDelete = React.lazy(() => import(\"./Types/delete\"))\r\nconst MTCTextareafull = React.lazy(() => import(\"./Types/textareafull\"))\r\nconst MTCLink = React.lazy(() => import(\"./Types/link\"))\r\nconst MTCNotexist = React.lazy(() => import(\"./Types/notexist\"))\r\nconst MTCFiles = React.lazy(() => import(\"./Types/files\"))\r\nconst MTCDate = React.lazy(() => import(\"./Types/date\"))\r\nconst MTCDateTime = React.lazy(() => import(\"./Types/datetime\"))\r\nconst MTCDateText = React.lazy(() => import(\"./Types/date_text\"))\r\nconst MTC_datetime_text = React.lazy(() => import(\"./Types/datetime_text\"))\r\nconst MTCArrayEditableModal = React.lazy(() =>\r\n import(\"./Types/array_editable_modal\")\r\n)\r\nconst MTCActionsMenu = React.lazy(() => import(\"./Types/actions_menu\"))\r\nconst MTCActionsMenuMulti = React.lazy(() =>\r\n import(\"./Types/actions_menu_multi\")\r\n)\r\nconst MTCForm = React.lazy(() => import(\"./Types/form\"))\r\nconst MTCReadOnlyArray = React.lazy(() => import(\"./Types/readonly_array\"))\r\nconst MTCurrency = React.lazy(() => import(\"./Types/currency\"))\r\nconst MTCNumberDecimal = React.lazy(() => import(\"./Types/number_decimal\"))\r\nconst MTCNumberNatural = React.lazy(() => import(\"./Types/number_natural\"))\r\nconst MTCNumber = React.lazy(() => import(\"./Types/number\"))\r\nconst MTCListText = React.lazy(() => import(\"./Types/list_text\"))\r\nconst MTCWithMyUI = React.lazy(() => import(\"./Types/with_myui\"))\r\nconst MTCActions = React.lazy(() => import(\"./Types/actions\"))\r\nconst MTCCopy = React.lazy(() => import(\"./Types/copy\"))\r\nconst MTC_readonly_date = React.lazy(() => import(\"./Types/readonly_date\"))\r\nconst MTC_pickcolor = React.lazy(() => import(\"./Types/pickcolor\"))\r\nconst MTC_chromecolor = React.lazy(() => import(\"./Types/chromecolor\"))\r\nconst MTC_readonly_html = React.lazy(() => import(\"./Types/readonly_html\"))\r\nconst MTCJsonEditorValue = React.lazy(() => import(\"./Types/json_editor_value\"))\r\n// const MTCText = React.lazy(() => import(\"./Types/text\"))\r\nconst MTCSuperMan = React.lazy(() => import(\"./Types/superman\"))\r\nconst MTCReadonlyWithTree = React.lazy(() =>\r\n import(\"./Types/readonly_with_tree\")\r\n)\r\nconst MTC_modal_table_extra = React.lazy(() =>\r\n import(\"./Types/modal_table_extra\")\r\n)\r\nconst MTC_quality = React.lazy(() => import(\"./Types/quality\"))\r\nconst MTC_readonly_status = React.lazy(() => import(\"./Types/readonly_status\"))\r\nconst MTC__barTopRight = React.lazy(() => import(\"./Types/_barTopRight\"))\r\nconst MTCSelect2ModalTable = React.lazy(() =>\r\n import(\"./Types/select2_modal_table\")\r\n)\r\nconst MTC__SelectOnModal = React.lazy(() => import(\"./Types/_select_on_modal\"))\r\nconst MTC_html_editor = React.lazy(() => import(\"./Types/html_editor\"))\r\nconst MTCFormModalTable = React.lazy(() => import(\"./Types/form_modal_table\"))\r\nconst MTCDevTest = React.lazy(() => import(\"./Types/dev_test\"))\r\nconst MTCSelect2 = React.lazy(() => import(\"./Types/select2\"))\r\nconst MTC_cs_email_tp_action = React.lazy(() =>\r\n import(\"./Types/cs_email_tp_action\")\r\n)\r\nconst MTC_readonly_datetime = React.lazy(() =>\r\n import(\"./Types/readonly_datetime\")\r\n)\r\nconst MTC_readonly_percent = React.lazy(() =>\r\n import(\"./Types/readonly_percent\")\r\n)\r\nconst MTC_readonly_progress = React.lazy(() =>\r\n import(\"./Types/readonly_progress\")\r\n)\r\nconst MTC_percent = React.lazy(() => import(\"./Types/percent\"))\r\n//custom\r\nconst MTC_checkbox_disabled = React.lazy(() =>\r\n import(\"./Types/checkbox_disabled\")\r\n)\r\n\r\nconst MTCObjEditor = React.lazy(() => import(\"./Types/obj_editor\"))\r\nconst MTCTestCanEdit = React.lazy(() => import(\"./Types/test_canedit\"))\r\nconst MTC_quantity = React.lazy(() => import(\"./Types/quantity\"))\r\nconst MTC_modal = React.lazy(() => import(\"./Types/modal\"))\r\nconst MTC_select_icon = React.lazy(() => import(\"./Types/select_icon\"))\r\nconst MTC_select_tag = React.lazy(() => import(\"./Types/select_tag\"))\r\nconst MTC_text_select = React.lazy(() => import(\"./Types/text_select\"))\r\nconst MTC_array_editable = React.lazy(() => import(\"./Types/array_editable\"))\r\nconst MTC_upload_one_photo = React.lazy(() =>\r\n import(\"./Types/upload_one_photo\")\r\n)\r\nconst MTC_date_native = React.lazy(() => import(\"./Types/date_native\"))\r\nconst MTC_remove_row = React.lazy(() => import(\"./Types/remove_row\"))\r\nconst MTC_suggest_address = React.lazy(() => import(\"./Types/suggest_address\"))\r\nconst MTC_pos_printbill = React.lazy(() => import(\"./Types/pos_printbill\"))\r\n\r\nconst List = {\r\n pos_printbill: MTC_pos_printbill,\r\n suggest_address: MTC_suggest_address,\r\n actions_menu_multi: MTCActionsMenuMulti,\r\n remove_row: MTC_remove_row,\r\n date_native: MTC_date_native,\r\n textarea_with_count: MTC_textarea_with_count,\r\n upload_one_photo: MTC_upload_one_photo,\r\n array_editable: MTC_array_editable,\r\n text_select: MTC_text_select,\r\n select_tag: MTC_select_tag,\r\n _select_on_modal: MTC__SelectOnModal,\r\n _barTopRight: MTC__barTopRight,\r\n cs_email_tp_action: MTC_cs_email_tp_action,\r\n dev_test: MTCDevTest,\r\n form_modal_table: MTCFormModalTable,\r\n html_editor: MTC_html_editor,\r\n select2_modal_table: MTCSelect2ModalTable,\r\n readonly_status: MTC_readonly_status,\r\n quality: MTC_quality,\r\n modal_table_extra: MTC_modal_table_extra,\r\n readonly_with_tree: MTCReadonlyWithTree,\r\n // text: MTCText,\r\n superman: MTCSuperMan,\r\n readonly_html: MTC_readonly_html,\r\n chromecolor: MTC_chromecolor,\r\n pickcolor: MTC_pickcolor,\r\n readonly_date: MTC_readonly_date,\r\n with_myui: MTCWithMyUI,\r\n list_text: MTCListText,\r\n number: MTCNumber,\r\n number_decimal: MTCNumberDecimal,\r\n number_natural: MTCNumberNatural,\r\n input_format_numeral_money: MTCurrency,\r\n currency: MTCurrency,\r\n readonly_array: MTCReadOnlyArray,\r\n form: MTCForm,\r\n actions: MTCActions,\r\n action: MTCActions,\r\n actions_menu: MTCActionsMenu,\r\n array_editable_modal: MTCArrayEditableModal,\r\n date: MTCDate,\r\n datepicker: MTCDate,\r\n datetime: MTCDateTime,\r\n date_text: MTCDateText,\r\n datetime_text: MTC_datetime_text,\r\n link: MTCLink,\r\n readonly: MTCReadonly,\r\n text: MTCTextarea, //xai chung voi textarea\r\n select: MTCSelectModern,\r\n select2: MTCSelect2,\r\n // select2_addable: MTCSelectModern,\r\n select2_modal: MTCSelect2Modal,\r\n select2_modal_api: MTCSelect2ModalApi,\r\n select_modern: MTCSelectModern,\r\n textarea: MTCTextarea,\r\n textareafull: MTCTextareafull,\r\n api: MTCApi,\r\n json_editor: MTCJsonEditor,\r\n json_editor_value: MTCJsonEditorValue,\r\n checkbox: MTCCheckbox,\r\n checkbox_null: MTCCheckboxNull,\r\n expand_multi: MTCExpandMulti,\r\n expand_api: MTCExpandMulti,\r\n delete: MTCDelete,\r\n notexist: MTCNotexist,\r\n files: MTCFiles,\r\n readonly_datetime: MTC_readonly_datetime,\r\n readonly_percent: MTC_readonly_percent,\r\n readonly_progress: MTC_readonly_progress,\r\n // copy: MTCCopy,\r\n //custom\r\n checkbox_disabled: MTC_checkbox_disabled,\r\n test_canedit: MTCTestCanEdit,\r\n quantity: MTC_quantity,\r\n modal: MTC_modal,\r\n percent: MTC_percent,\r\n select_icon: MTC_select_icon,\r\n}\r\nconst MyTableCellOne = {\r\n init() {\r\n MyTableCellHelpers.addTypesFromListLazy(List)\r\n MyTableCellHelpers.Types[\"_auto\"] = (cell, row, extra, index) => {\r\n let _type = HUtils.get(extra, \"Type.type\")\r\n let _more = HUtils.get(extra, \"Type.more\")\r\n // console.log(\"_more:\", _more)\r\n if (\r\n _more &&\r\n typeof _more == \"string\" &&\r\n _more.indexOf(KMore.typeAdmin) > -1 &&\r\n HCF.getCF(KConfigApp.verAdmin) == \"v5\"\r\n ) {\r\n let _moreObj = HJson.getObj(_more)\r\n if (_moreObj && _moreObj[KMore.typeAdmin]) {\r\n _type = _moreObj[KMore.typeAdmin]\r\n }\r\n\r\n //check canshow chung\r\n // let _canShow = FlowGetCanShow({ extra, row, more: _moreObj })\r\n // if (_canShow === false) {\r\n // return MyTableCellHelpers.Types._empty({ cell, row, extra, index })\r\n // }\r\n }\r\n if (MyTableCellHelpers.Types[_type]) {\r\n let TagCell = MyTableCellHelpers.Types[_type]\r\n //phai tra ve dang tag moi de nhan dien trong TableColumn\r\n return \r\n } else {\r\n if (MyTableCellHelpers.Types.notexist) {\r\n return MyTableCellHelpers.Types.notexist({ cell, row, extra, index })\r\n }\r\n return MyTableCellHelpers.Types._empty({ cell, row, extra, index })\r\n }\r\n }\r\n MyTableCellHelpers[\"ConfigByTypes\"] = {\r\n api: {\r\n isHide: oneTableCell => {\r\n let _isHide = null\r\n if (oneTableCell) {\r\n let _valueCell = oneTableCell.getValue()\r\n // console.log(\"check is Hide\")\r\n if (_valueCell === \"\" || _valueCell === null) {\r\n _isHide = true\r\n }\r\n }\r\n if (\r\n _isHide &&\r\n oneTableCell.more &&\r\n oneTableCell.more[KMore.alwayShow] === true\r\n ) {\r\n return false\r\n }\r\n return _isHide\r\n },\r\n },\r\n // datetime: {\r\n // moreAttrs: {\r\n // moreOptions: {\r\n // enableTime: true,\r\n // dateFormat: \"d/m/Y H:i\",\r\n // },\r\n // },\r\n // },\r\n }\r\n },\r\n}\r\n\r\nexport default MyTableCellOne\r\n","import React from \"react\"\r\nimport { MyTableHeaderHelpers, HFormat } from \"@macashipo/mlib\"\r\n\r\nconst MTHstyled = React.lazy(() => import(\"./Types/styled\"))\r\nconst MTHhtml = React.lazy(() => import(\"./Types/html\"))\r\nconst MTHcheo = React.lazy(() => import(\"./Types/cheo\"))\r\nconst MTHtooltip = React.lazy(() => import(\"./Types/tooltip\"))\r\nconst List = {\r\n cheo: MTHcheo,\r\n diagonal: MTHcheo,\r\n styled: MTHstyled,\r\n html: MTHhtml,\r\n tooltip: MTHtooltip,\r\n}\r\nconst MyTableHeaderOne = {\r\n init() {\r\n MyTableHeaderHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyTableHeaderOne\r\n","import { MyFormControlHelpers, MyLayoutHelpers } from \"@macashipo/mlib\"\r\nimport React from \"react\"\r\n\r\nconst MFCText = React.lazy(() => import(\"./Types/text\"))\r\nconst MFCAlert = React.lazy(() => import(\"./Types/alert\"))\r\nconst MFCTextarea = React.lazy(() => import(\"./Types/textarea\"))\r\nconst MFCSelect2 = React.lazy(() => import(\"./Types/select2\"))\r\nconst MFCDatePicker = React.lazy(() => import(\"./Types/datepicker\"))\r\nconst MFCNumberDecimal = React.lazy(() => import(\"./Types/number_decimal\"))\r\nconst MFCNumberNatural = React.lazy(() => import(\"./Types/number_natural\"))\r\nconst MFCNumber = React.lazy(() => import(\"./Types/number\"))\r\nconst MFCCurrency = React.lazy(() => import(\"./Types/currency\"))\r\nconst MFCPassword = React.lazy(() => import(\"./Types/password\"))\r\nconst MFC_checkbox = React.lazy(() => import(\"./Types/checkbox\"))\r\nconst MFC_readonly = React.lazy(() => import(\"./Types/readonly\"))\r\nconst MFC_layout_row = React.lazy(() => import(\"./Types/layout_row\"))\r\nconst MFC_layout_grid = React.lazy(() => import(\"./Types/layout_grid\"))\r\nconst MFC_layout_group = React.lazy(() => import(\"./Types/layout_group\"))\r\nconst MFC_timepicker = React.lazy(() => import(\"./Types/timepicker\"))\r\nconst MFC_timepicker_text = React.lazy(() => import(\"./Types/timepicker_text\"))\r\nconst MFC_datepicker_text = React.lazy(() => import(\"./Types/datepicker_text\"))\r\nconst MFC_arrtext = React.lazy(() => import(\"./Types/arrtext\"))\r\nconst MFC_select_tag = React.lazy(() => import(\"./Types/select_tag\"))\r\nconst MFC_datetimepicker = React.lazy(() => import(\"./Types/datetimepicker\"))\r\nconst MFC_select_table_api = React.lazy(() =>\r\n import(\"./Types/select_table_api\")\r\n)\r\nconst MFC_custom = React.lazy(() => import(\"./Types/custom\"))\r\nconst MFC_checkbox_yesno = React.lazy(() => import(\"./Types/checkbox_yesno\"))\r\nconst MFC_checkbox_inbox = React.lazy(() => import(\"./Types/checkbox_inbox\"))\r\nconst MFC_percent = React.lazy(() => import(\"./Types/percent\"))\r\nconst MFC_range = React.lazy(() => import(\"./Types/range\"))\r\nconst MFC_files = React.lazy(() => import(\"./Types/files\"))\r\nconst MFC_textareafull = React.lazy(() => import(\"./Types/textareafull\"))\r\nconst MFC_readonly_html = React.lazy(() => import(\"./Types/readonly_html\"))\r\nconst MFC_html_editor = React.lazy(() => import(\"./Types/html_editor\"))\r\nconst MFC_selectlist = React.lazy(() => import(\"./Types/selectlist\"))\r\nconst MFC_selectlist_check = React.lazy(() =>\r\n import(\"./Types/selectlist_check\")\r\n)\r\nconst MFC_suggest_address = React.lazy(() => import(\"./Types/suggest_address\"))\r\nconst MFC_table = React.lazy(() => import(\"./Types/table\"))\r\nconst MFC_group_checkbox = React.lazy(() => import(\"./Types/group_checkbox\"))\r\nconst MFC_multi_input = React.lazy(() => import(\"./Types/multi_input\"))\r\nconst MFC_signature = React.lazy(() => import(\"./Types/signature\"))\r\nconst MFC_select2_api = React.lazy(() => import(\"./Types/select2_api\"))\r\nconst MFC_selectlist_check_api = React.lazy(() =>\r\n import(\"./Types/selectlist_check_api\")\r\n)\r\n\r\nconst List = {\r\n selectlist_check_api: MFC_selectlist_check_api,\r\n select2_api: MFC_select2_api,\r\n signature: MFC_signature,\r\n multi_input: MFC_multi_input,\r\n group_checkbox: MFC_group_checkbox,\r\n table: MFC_table,\r\n suggest_address: MFC_suggest_address,\r\n selectlist_check: MFC_selectlist_check,\r\n selectlist: MFC_selectlist,\r\n html_editor: MFC_html_editor,\r\n readonly_html: MFC_readonly_html,\r\n textareafull: MFC_textareafull,\r\n currency: MFCCurrency,\r\n number: MFCNumber,\r\n number_decimal: MFCNumberDecimal,\r\n number_natural: MFCNumberNatural,\r\n date: MFCDatePicker,\r\n datepicker: MFCDatePicker,\r\n select2: MFCSelect2,\r\n textarea: MFCTextarea,\r\n text: MFCText,\r\n alert: MFCAlert,\r\n password: MFCPassword,\r\n checkbox: MFC_checkbox,\r\n readonly: MFC_readonly,\r\n layout_row: MFC_layout_row,\r\n layout_grid: MFC_layout_grid,\r\n layout_group: MFC_layout_group,\r\n timepicker: MFC_timepicker,\r\n timepicker_text: MFC_timepicker_text,\r\n datepicker_text: MFC_datepicker_text,\r\n arrtext: MFC_arrtext,\r\n select_tag: MFC_select_tag,\r\n datetime: MFC_datetimepicker,\r\n datetimepicker: MFC_datetimepicker,\r\n select_table_api: MFC_select_table_api,\r\n custom: MFC_custom,\r\n checkbox_yesno: MFC_checkbox_yesno,\r\n checkbox_inbox: MFC_checkbox_inbox,\r\n percent: MFC_percent,\r\n range: MFC_range,\r\n files: MFC_files,\r\n}\r\n\r\nconst MFCW_ngang = React.lazy(() => import(\"./WrapControlTypes/ngang\"))\r\nconst ListWrapLayout = {\r\n form_ngang: MFCW_ngang,\r\n form_horizontal: MFCW_ngang,\r\n form_row: MFCW_ngang,\r\n}\r\nconst MyLayoutOne = {\r\n init() {\r\n MyFormControlHelpers.addTypesFromListLazy(List)\r\n MyLayoutHelpers.addTypesFromListLazy(ListWrapLayout)\r\n },\r\n}\r\n\r\nexport default MyLayoutOne\r\n","import React from \"react\"\r\nimport { HUtils } from \"@macashipo/mlib\"\r\nimport BaseNumeral from \"./numeral\"\r\nimport HelperMore from \"./_helperMore\"\r\nconst BaseText = props => {\r\n const more = HUtils.runFuntion(props.fnList, \"getMore\", [])\r\n const isNumeral = HelperMore.getIsNumeral(more)\r\n if (isNumeral === true) {\r\n return BaseNumeral(props)\r\n }\r\n return (\r\n {\r\n props.onChange && props.onChange(ev.currentTarget.value)\r\n }}\r\n className={props.className}\r\n style={props.style}\r\n // onInvalid={e => {\r\n // // e.target.setCustomValidity(\"No no no no\")//set custom valid default\r\n // //disabled check required default\r\n // // e.preventDefault()\r\n // }}\r\n {...props.attrs}\r\n // autoComplete=\"new-password\"\r\n />\r\n )\r\n}\r\n\r\nexport default BaseText\r\n","import React from \"react\"\r\nimport HelperMore from \"./_helperMore\"\r\nconst BaseText = props => {\r\n // const more = HUtils.runFuntion(props.fnList, \"getMore\", [])\r\n return (\r\n {\r\n props.onChange && props.onChange(ev.currentTarget.value)\r\n }}\r\n onBlur={ev => {\r\n props.onBlur && props.onBlur(ev.currentTarget.value)\r\n }}\r\n className={props.className}\r\n style={props.style}\r\n {...props.attrs}\r\n />\r\n )\r\n}\r\n\r\nexport default BaseText\r\n","import React from \"react\"\r\nimport SelectCheck from \"./select_check\"\r\nimport HelperMore from \"./_helperMore\"\r\nimport { HOptions } from \"src/core/helpers\"\r\nconst BaseSelect = props => {\r\n const more = HelperMore.getMoreFromProps(props)\r\n const isSelectCheck = HelperMore.getIsSelectCheck(more)\r\n if (isSelectCheck === true) {\r\n return SelectCheck(props)\r\n }\r\n const options =\r\n (props.fnList &&\r\n props.fnList.getSourceData &&\r\n props.fnList.getSourceData({ withEmpty: true })) ||\r\n []\r\n return (\r\n {\r\n props.onChange &&\r\n props.onChange(ev.currentTarget.value, {\r\n item: HOptions.getOptionByValue(options, ev.currentTarget.value),\r\n })\r\n }}\r\n className={props.className}\r\n style={props.style}\r\n placeholder={props.placeholder}\r\n {...props.attrs}\r\n >\r\n {options &&\r\n options.length > 0 &&\r\n Array.isArray(options) &&\r\n options.map((v, i) => {\r\n return (\r\n \r\n )\r\n })}\r\n \r\n )\r\n}\r\n\r\nexport default BaseSelect\r\n","import React from \"react\"\r\nimport { MyBaseHelpers } from \"@macashipo/mlib\"\r\nimport MB_text from \"./Types/text\"\r\nimport MB_textarea from \"./Types/textarea\"\r\nimport MB_select from \"./Types/select\"\r\n\r\nconst MB_textareafull = React.lazy(() => import(\"./Types/textareafull\"))\r\nconst MB_numeral = React.lazy(() => import(\"./Types/numeral\"))\r\nconst MB_select2 = React.lazy(() => import(\"./Types/select2\"))\r\nconst MB_select2_api = React.lazy(() => import(\"./Types/select2_api\"))\r\nconst MB_switch = React.lazy(() => import(\"./Types/switch\"))\r\nconst MB_checkbox = React.lazy(() => import(\"./Types/checkbox\"))\r\nconst MB_checkbox_yesno = React.lazy(() => import(\"./Types/checkbox_yesno\"))\r\nconst MB_checkbox_styled = React.lazy(() => import(\"./Types/checkbox_styled\"))\r\nconst MB_date_flatpickr = React.lazy(() => import(\"./Types/date_flatpickr\"))\r\nconst MB_date_flatpickr_selectmonth = React.lazy(() =>\r\n import(\"./Types/date_flatpickr_selectmonth\")\r\n)\r\nconst MB_datefromto_flatpickr = React.lazy(() =>\r\n import(\"./Types/datefromto_flatpickr\")\r\n)\r\nconst MB_daterangepicker = React.lazy(() => import(\"./Types/daterangepicker\"))\r\nconst MB_monacoeditor = React.lazy(() => import(\"./Types/monacoeditor\"))\r\nconst MB_range = React.lazy(() => import(\"./Types/range\"))\r\nconst MB_select_tag = React.lazy(() => import(\"./Types/select_tag\"))\r\nconst MB_select_tag_button = React.lazy(() =>\r\n import(\"./Types/select_tag_button\")\r\n)\r\nconst MB_selectlist = React.lazy(() => import(\"./Types/selectlist\"))\r\nconst MB_selectlist_check = React.lazy(() => import(\"./Types/selectlist_check\"))\r\nconst MB_date_native = React.lazy(() => import(\"./Types/date_native\"))\r\n\r\nconst ListNoLazy = {\r\n text: MB_text,\r\n textarea: MB_textarea,\r\n select: MB_select,\r\n}\r\nconst List = {\r\n date_flatpickr_selectmonth: MB_date_flatpickr_selectmonth,\r\n date_native: MB_date_native,\r\n selectlist: MB_selectlist,\r\n selectlist_check: MB_selectlist_check,\r\n monacoeditor: MB_monacoeditor,\r\n daterangepicker: MB_daterangepicker,\r\n textareafull: MB_textareafull,\r\n numeral: MB_numeral,\r\n select2: MB_select2,\r\n select2_api: MB_select2_api,\r\n switch: MB_switch,\r\n checkbox: MB_checkbox,\r\n checkbox_yesno: MB_checkbox_yesno,\r\n checkbox_styled: MB_checkbox_styled,\r\n date_flatpickr: MB_date_flatpickr,\r\n datefromto_flatpickr: MB_datefromto_flatpickr,\r\n range: MB_range,\r\n select_tag_button: MB_select_tag_button,\r\n select_tag: MB_select_tag,\r\n}\r\nconst MyBaseOne = {\r\n init() {\r\n MyBaseHelpers.addTypesFromListWithoutLazy(ListNoLazy)\r\n MyBaseHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyBaseOne\r\n","import React from \"react\"\r\nimport { MyTableFilterControlHelpers, HFormat } from \"@macashipo/mlib\"\r\nimport i18next from \"i18next\"\r\nimport moment from \"moment\"\r\n\r\nconst MTFCSelect2 = React.lazy(() => import(\"./Types/select2\"))\r\nconst MTFCSelect2Content = React.lazy(() => import(\"./Types/select2content\"))\r\nconst MTFCSwitch = React.lazy(() => import(\"./Types/switch\"))\r\nconst MTFCCheckbox = React.lazy(() => import(\"./Types/checkbox\"))\r\nconst MTFCDateFromTo = React.lazy(() => import(\"./Types/datefromto\"))\r\nconst MTFCDateFromToText = React.lazy(() => import(\"./Types/datefromto_text\"))\r\nconst MTFCText = React.lazy(() => import(\"./Types/text\"))\r\nconst MTFC_select2_multi = React.lazy(() => import(\"./Types/select2_multi\"))\r\nconst MTFC_select2_modal = React.lazy(() => import(\"./Types/select2_modal\"))\r\nconst MTFC_select2_modal_api = React.lazy(() =>\r\n import(\"./Types/select2_modal_api\")\r\n)\r\nconst MTFC_select_month = React.lazy(() => import(\"./Types/select_month\"))\r\nconst MTFC_month_year = React.lazy(() => import(\"./Types/month_year\"))\r\nconst MTFC_select = React.lazy(() => import(\"./Types/select\"))\r\nconst List = {\r\n select: MTFC_select,\r\n month_year: MTFC_month_year,\r\n select_month: MTFC_select_month,\r\n datefromto: MTFCDateFromTo,\r\n datefromto_text: MTFCDateFromToText,\r\n checkbox: MTFCCheckbox,\r\n select2: MTFCSelect2,\r\n select2_multi: MTFC_select2_multi,\r\n select2_modal: MTFC_select2_modal,\r\n select2_modal_api: MTFC_select2_modal_api,\r\n select2content: MTFCSelect2Content,\r\n switch: MTFCSwitch,\r\n text: MTFCText,\r\n}\r\nconst MyTableFilterControlOne = {\r\n init() {\r\n MyTableFilterControlHelpers.addTypesFromListLazy(List)\r\n if (MyTableFilterControlHelpers.ConfigByType == null) {\r\n MyTableFilterControlHelpers.ConfigByType = {}\r\n }\r\n if (MyTableFilterControlHelpers.ConfigByType) {\r\n MyTableFilterControlHelpers.ConfigByType[\"_default\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n // console.log(\"getFilterOut _default\", value, oneFilter)\r\n if (value === null) {\r\n //neu value la null, set currentFilter = null\r\n return null\r\n }\r\n let _isServer = false\r\n if (oneFilter.more) {\r\n if (oneFilter.more.isServer === true) {\r\n _isServer = true\r\n }\r\n }\r\n return {\r\n t: oneFilter.type,\r\n fieldName: oneFilter.fieldName,\r\n isServer: _isServer,\r\n more: oneFilter.more,\r\n title: oneFilter.title,\r\n value: value,\r\n valueDisplay: value,\r\n }\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"select2\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n console.warn(\"getFilterOut:\", value, oneFilter)\r\n if (value === null) {\r\n //neu value la null, set currentFilter = null\r\n return null\r\n }\r\n //multi\r\n if (Array.isArray(value)) {\r\n if (value.length > 0) {\r\n let _charSplitArray = \",\"\r\n let _valueDisplay = value\r\n .map(v => {\r\n return v.Text\r\n })\r\n .join(_charSplitArray)\r\n let _valueFilterServer = value\r\n .map(v => {\r\n return v.Value\r\n })\r\n .join(_charSplitArray)\r\n let _valueFilterClient = value.map(v => {\r\n return v.Value\r\n })\r\n return {\r\n ...MyTableFilterControlHelpers.ConfigByType[\r\n \"_default\"\r\n ].getFilterOut(value, oneFilter),\r\n type: \"ArrayFilter\",\r\n value: value,\r\n valueDisplay: _valueDisplay,\r\n valueFilterServer: _valueFilterServer,\r\n valueFilterClient: _valueFilterClient,\r\n }\r\n } else {\r\n return null\r\n }\r\n }\r\n return {\r\n ...MyTableFilterControlHelpers.ConfigByType[\r\n \"_default\"\r\n ].getFilterOut(value, oneFilter),\r\n type: \"SelectFilter\",\r\n // cond: \"eq\",//an di vi se bo sung truc tiep vao type SelectFilter\r\n value: {\r\n Text: value.Text,\r\n Value: value.Value,\r\n },\r\n valueDisplay: value.Text,\r\n valueFilterServer: value.Value,\r\n valueFilterClient: value.Value,\r\n }\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"month_year\"] = {\r\n getCustomFilter: filterOut => {\r\n return {\r\n type: \"CustomFilter\",\r\n value: {\r\n callbackParameters: filterOut,\r\n callback: (targetVal, itemP) => {\r\n if (\r\n targetVal != null &&\r\n typeof targetVal == \"number\" &&\r\n itemP &&\r\n typeof itemP.value == \"number\"\r\n ) {\r\n let _startMili = itemP.value\r\n let _endMili = moment(_startMili).endOf(\"month\").format(\"x\")\r\n console.log(\"filter month_year\", _startMili, _endMili)\r\n if (targetVal >= _startMili && targetVal <= _endMili) {\r\n return true\r\n }\r\n }\r\n return false\r\n },\r\n },\r\n }\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"select2_multi\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n return MyTableFilterControlHelpers.ConfigByType[\r\n \"select2\"\r\n ].getFilterOut(value, oneFilter)\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"select2_modal\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n return MyTableFilterControlHelpers.ConfigByType[\r\n \"select2\"\r\n ].getFilterOut(value, oneFilter)\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"select2_modal_api\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n return MyTableFilterControlHelpers.ConfigByType[\r\n \"select2\"\r\n ].getFilterOut(value, oneFilter)\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"select_month\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n return MyTableFilterControlHelpers.ConfigByType[\r\n \"select2\"\r\n ].getFilterOut(value, oneFilter)\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"select2content\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n if (value === null) {\r\n //neu value la null, set currentFilter = null\r\n return null\r\n }\r\n console.warn(\"getFilterOut4554:\", value, oneFilter)\r\n return {\r\n ...MyTableFilterControlHelpers.ConfigByType[\r\n \"_default\"\r\n ].getFilterOut(value, oneFilter),\r\n value: {\r\n Text: value.Text,\r\n Value: value.Value,\r\n },\r\n type: value.Filter.type,\r\n valueDisplay: value.Text,\r\n valueFilterServer: value.Filter.value,\r\n valueFilterClient: value.Filter.value,\r\n }\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"switch\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n // console.log(\"getFilterOut:\", value, oneFilter)\r\n return {\r\n ...MyTableFilterControlHelpers.ConfigByType[\r\n \"_default\"\r\n ].getFilterOut(value, oneFilter),\r\n value: value,\r\n valueDisplay: \"Yes\",\r\n }\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"checkbox\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n // console.log(\"getFilterOut:\", value, oneFilter)\r\n if (value === null) {\r\n //neu value la null, set currentFilter = null\r\n return null\r\n }\r\n return {\r\n ...MyTableFilterControlHelpers.ConfigByType[\r\n \"_default\"\r\n ].getFilterOut(value, oneFilter),\r\n value: value,\r\n valueDisplay: `${\r\n value === true\r\n ? i18next.t(\"Yes\")\r\n : value === false\r\n ? i18next.t(\"No\")\r\n : \"\"\r\n }`,\r\n }\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"datefromto\"] = {\r\n getCustomFilter: itemOut => {\r\n return {\r\n type: \"CustomFilter\",\r\n value: {\r\n callbackParameters: itemOut,\r\n callback: (targetVal, itemP) => {\r\n if (\r\n targetVal != null &&\r\n typeof targetVal == \"number\" &&\r\n itemP &&\r\n Array.isArray(itemP.value) &&\r\n itemP.value.length > 1\r\n ) {\r\n let _startMili = new Date(itemP.value[0]).getTime()\r\n let _endMili = new Date(itemP.value[1]).getTime()\r\n if (targetVal >= _startMili && targetVal <= _endMili) {\r\n return true\r\n }\r\n }\r\n return false\r\n },\r\n },\r\n }\r\n },\r\n getFilterOut: (value, oneFilter) => {\r\n if (value === null) {\r\n //neu value la null, set currentFilter = null\r\n return null\r\n }\r\n console.warn(\"getFilterOut:\", value, oneFilter)\r\n let _testDisplay = \"\"\r\n let _valueFilterServer = {}\r\n if (value && value.length > 1) {\r\n let _from = HFormat.format(value[0], {\r\n type: \"date\",\r\n format: \"DD/MM/YYYY\",\r\n })\r\n let _to = HFormat.format(value[1], {\r\n type: \"date\",\r\n format: \"DD/MM/YYYY\",\r\n })\r\n _valueFilterServer = {\r\n start: new Date(value[0]).getTime(),\r\n end: new Date(value[1]).getTime(),\r\n }\r\n _testDisplay = `${_from} - ${_to}`\r\n }\r\n return {\r\n ...MyTableFilterControlHelpers.ConfigByType[\r\n \"_default\"\r\n ].getFilterOut(value, oneFilter),\r\n value: value,\r\n valueDisplay: _testDisplay,\r\n valueFilterServer: _valueFilterServer,\r\n }\r\n },\r\n }\r\n MyTableFilterControlHelpers.ConfigByType[\"datefromto_text\"] = {\r\n getFilterOut: (value, oneFilter) => {\r\n if (value === null) {\r\n //neu value la null, set currentFilter = null\r\n return null\r\n }\r\n // console.log(\"getFilterOut:\", value, oneFilter)\r\n let _testDisplay = \"\"\r\n let _valueFilterServer = {}\r\n if (value && value.length > 1) {\r\n let _from = HFormat.format(value[0], {\r\n type: \"date\",\r\n format: \"DD/MM/YYYY\",\r\n })\r\n let _to = HFormat.format(value[1], {\r\n type: \"date\",\r\n format: \"DD/MM/YYYY\",\r\n })\r\n _valueFilterServer = {\r\n start: HFormat.format(new Date(value[0]).getTime(), {\r\n type: \"date\",\r\n format: \"YYYY-MM-DD\",\r\n }),\r\n end: HFormat.format(new Date(value[1]).getTime(), {\r\n type: \"date\",\r\n format: \"YYYY-MM-DD\",\r\n }),\r\n }\r\n _testDisplay = `${_from} - ${_to}`\r\n }\r\n return {\r\n ...MyTableFilterControlHelpers.ConfigByType[\r\n \"_default\"\r\n ].getFilterOut(value, oneFilter),\r\n value: value,\r\n valueDisplay: _testDisplay,\r\n valueFilterServer: _valueFilterServer,\r\n }\r\n },\r\n }\r\n }\r\n },\r\n}\r\n\r\nexport default MyTableFilterControlOne\r\n","import React from \"react\"\r\nimport { MyLibHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MLSelect2 = React.lazy(() => import(\"./Types/select2\"))\r\nconst ML_select2_required = React.lazy(() => import(\"./Types/select2_required\"))\r\nconst MLMonacoEditor = React.lazy(() => import(\"./Types/monacoeditor\"))\r\nconst ML_chromepicker = React.lazy(() => import(\"./Types/chromepicker\"))\r\nconst ML_code_mirror = React.lazy(() => import(\"./Types/code_mirror\"))\r\nconst ML_diff_viewer = React.lazy(() => import(\"./Types/diff_viewer\"))\r\nconst ML_draft_wysiwyg = React.lazy(() => import(\"./Types/draft_wysiwyg\"))\r\nconst ML_react_rte = React.lazy(() => import(\"./Types/react_rte\"))\r\nconst ML_ckeditor5 = React.lazy(() => import(\"./Types/ckeditor5\"))\r\nconst ML_ckeditor5_min = React.lazy(() => import(\"./Types/ckeditor5_min\"))\r\nconst ML_ckeditor5_email = React.lazy(() => import(\"./Types/ckeditor5_email\"))\r\nconst ML_pdfexpress = React.lazy(() => import(\"./Types/pdfexpress\"))\r\nconst ML_dearflip = React.lazy(() => import(\"./Types/dearflip\"))\r\nconst ML_big_calendar = React.lazy(() => import(\"./Types/big_calendar\"))\r\nconst List = {\r\n big_calendar: ML_big_calendar,\r\n dearflip: ML_dearflip,\r\n pdfexpress: ML_pdfexpress,\r\n ckeditor5: ML_ckeditor5,\r\n ckeditor5_min: ML_ckeditor5_min,\r\n ckeditor5_email: ML_ckeditor5_email,\r\n draft_wysiwyg: ML_draft_wysiwyg,\r\n react_rte: ML_react_rte,\r\n diff_viewer: ML_diff_viewer,\r\n code_mirror: ML_code_mirror,\r\n chromepicker: ML_chromepicker,\r\n select2: MLSelect2,\r\n select2_required: ML_select2_required,\r\n monacoeditor: MLMonacoEditor,\r\n}\r\nconst MyLibOne = {\r\n init() {\r\n MyLibHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyLibOne\r\n","import { MyChartHelpers } from \"@macashipo/mlib\"\r\nimport React from \"react\"\r\n\r\nconst MCH_gg_column = React.lazy(() => import(\"./Types/gg_column\"))\r\nconst MCH_gg_line = React.lazy(() => import(\"./Types/gg_line\"))\r\nconst MCH_gg_pie = React.lazy(() => import(\"./Types/gg_pie\"))\r\nconst MCH_gg_area = React.lazy(() => import(\"./Types/gg_area\"))\r\nconst MCH_gg_bar = React.lazy(() => import(\"./Types/gg_bar\"))\r\nconst MCH_gg_bubble = React.lazy(() => import(\"./Types/gg_bubble\"))\r\nconst MCH_gg_combo = React.lazy(() => import(\"./Types/gg_combo\"))\r\nconst MCH_gg_timeline = React.lazy(() => import(\"./Types/gg_timeline\"))\r\nconst MCH_gg_orgchart = React.lazy(() => import(\"./Types/gg_orgchart\"))\r\nconst MCH_gg_material_bar = React.lazy(() => import(\"./Types/gg_material_bar\"))\r\n//chartjs\r\nconst MCH_chartjs_line = React.lazy(() => import(\"./Types/chartjs_line\"))\r\nconst MCH_chartjs_bar = React.lazy(() => import(\"./Types/chartjs_bar\"))\r\nconst MCH_chartjs_pie = React.lazy(() => import(\"./Types/chartjs_pie\"))\r\n\r\nconst List = {\r\n gg_column: MCH_gg_column,\r\n gg_line: MCH_gg_line,\r\n gg_pie: MCH_gg_pie,\r\n gg_area: MCH_gg_area,\r\n gg_bar: MCH_gg_bar,\r\n gg_bubble: MCH_gg_bubble,\r\n gg_combo: MCH_gg_combo,\r\n gg_timeline: MCH_gg_timeline,\r\n gg_orgchart: MCH_gg_orgchart,\r\n //\r\n gg_material_bar: MCH_gg_material_bar,\r\n //chartjs\r\n chartjs_line: MCH_chartjs_line,\r\n chartjs_bar: MCH_chartjs_bar,\r\n chartjs_pie: MCH_chartjs_pie,\r\n}\r\nconst MyChartOne = {\r\n init() {\r\n MyChartHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyChartOne\r\n","import React from \"react\"\r\nimport { MyCardHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MC_card_row_email_template = React.lazy(() =>\r\n import(\"./Types/card_row_email_template\")\r\n)\r\nconst List = {\r\n card_row_email_template: MC_card_row_email_template,\r\n}\r\nconst MyLibOne = {\r\n init() {\r\n MyCardHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyLibOne\r\n","import { HAuth, HConstant, HConfig } from \"src/core/helpers\"\r\nimport { HRegex, HLocalStorage, HUtils, HCF, HJson } from \"@macashipo/mlib\"\r\nimport ApiGeneric from \"src/services/apiGeneric\"\r\nimport { FlowForceUpdateRoutes } from \"src/helpers/Flows/Routes\"\r\n\r\nconst kCategoryScreen = \"CategoryScreen\"\r\nconst kFnConvertUIType = \"fnConvertUIType\"\r\nconst kfnUpdateRouteFromLocalCategoryScreen =\r\n \"fnUpdateRouteFromLocalCategoryScreen\"\r\nconst ConvertType = {\r\n table: \"admin_table\",\r\n tab: \"admin_tab\",\r\n dashboard: \"admin_dashboard\",\r\n panel: \"admin_panel\",\r\n table_list: \"admin_table_list\",\r\n table_list_card: \"admin_table_list_card\",\r\n table_grid_card: \"admin_table_grid_card\",\r\n}\r\nconst ModuleCategoryScreen = {\r\n init: HConfig => {\r\n if (HAuth.authIsLogged()) {\r\n ModuleCategoryScreen.updateRoutes()\r\n ModuleCategoryScreen.requestCategoryScreen()\r\n } else {\r\n HUtils.runFuntion(HConfig, HConstant.HConfig.FnList.registerAfterLogin, [\r\n () => {\r\n console.warn(\"call request when after login \")\r\n ModuleCategoryScreen.requestCategoryScreen({ callAfterLogin: true })\r\n },\r\n ])\r\n }\r\n HCF.setCF(kFnConvertUIType, ModuleCategoryScreen.convertUIType)\r\n HCF.setCF(\r\n kfnUpdateRouteFromLocalCategoryScreen,\r\n ModuleCategoryScreen.updateRoutes\r\n )\r\n },\r\n requestCategoryScreen: ({ callAfterLogin } = {}) => {\r\n ApiGeneric({\r\n method: \"POST\",\r\n path: \"ConfigMenu\",\r\n name: \"CategoryScreenList\",\r\n data: {},\r\n })\r\n .then(response => {\r\n if (response.Data) {\r\n if (callAfterLogin == true) {\r\n ModuleCategoryScreen.parseData(response.Data, { forceChange: true })\r\n let _just404 = HCF.getCF(\"just404\")\r\n console.warn(\"_just404:\", _just404)\r\n if (_just404 != null) {\r\n //render route again\r\n FlowForceUpdateRoutes()\r\n } else {\r\n HCF.setCF(\"needUpdateRoutesIn404\", true)\r\n }\r\n } else {\r\n ModuleCategoryScreen.parseData(response.Data)\r\n }\r\n }\r\n })\r\n .catch(error => {})\r\n },\r\n updateRoutes: data => {\r\n let _newData = data || HLocalStorage.getObj(kCategoryScreen, [])\r\n HUtils.runFuntion(HConfig, HConstant.HConfig.FnList.addPublicRoutes, [\r\n _newData,\r\n ])\r\n },\r\n parseData: (data, { forceChange } = {}) => {\r\n let _newData = []\r\n if (data && data.length > 0) {\r\n _newData = data.map((v, i) => {\r\n if (v.UIUrl && v.UIUrl.indexOf(\"[\") > -1) {\r\n v.UIUrl = v.UIUrl.replace(HRegex.RGSquareBracket, \":$1\")\r\n }\r\n ModuleCategoryScreen.convertUIType(v)\r\n return v\r\n })\r\n }\r\n let _isDifference = true\r\n if (\r\n HJson.getString(_newData) == HLocalStorage.getString(kCategoryScreen, \"\")\r\n ) {\r\n _isDifference = false\r\n console.warn(\"category screen is not difference\")\r\n }\r\n if (_isDifference || forceChange === true) {\r\n HLocalStorage.saveObj(kCategoryScreen, _newData)\r\n ModuleCategoryScreen.updateRoutes(_newData)\r\n }\r\n },\r\n convertUIType: (configPage = {}) => {\r\n if (configPage.UIType === null || configPage.UIType === \"\") {\r\n configPage.UIType = \"Table\"\r\n }\r\n if (configPage.UIType && ConvertType[configPage.UIType.toLowerCase()]) {\r\n configPage.UIType = ConvertType[configPage.UIType.toLowerCase()]\r\n }\r\n // console.warn(\"convertUIType\", configPage)\r\n },\r\n}\r\n\r\nexport default ModuleCategoryScreen\r\n","import { HUtils, HJson, HLocalStorage, HCF, HEE } from \"@macashipo/mlib\"\r\nimport { HAuth, HConstant } from \"src/core/helpers\"\r\nimport { registerAfterLogout } from \"src/core/helpers/auth\"\r\nimport { KConfigApp, KEventsApp, KObserver } from \"src/helpers/K\"\r\nimport ApiGeneric from \"src/services/apiGeneric\"\r\n\r\nconst kSideMenu = \"SideMenu\"\r\nconst kAppMenu = \"AppMenu\"\r\nconst kAppLogo = \"AppLogo\"\r\nconst kSideMenuHCF = \"UI_SideMenu\"\r\nconst kAppMenuHCF = \"UI_AppMenu\"\r\nconst ModuleProjectScreen = {\r\n init: HConfig => {\r\n ModuleProjectScreen.initLastSaved()\r\n if (HAuth.authIsLogged()) {\r\n ModuleProjectScreen.requestProjectScreens()\r\n }\r\n HUtils.runFuntion(HConfig, HConstant.HConfig.FnList.registerAfterLogin, [\r\n () => {\r\n console.warn(\"ModuleProjectScreen: call request when after login \")\r\n ModuleProjectScreen.requestProjectScreens()\r\n },\r\n ])\r\n registerAfterLogout(\"projectscreen\", () => {\r\n HLocalStorage.removeItem(kSideMenu)\r\n HLocalStorage.removeItem(kAppMenu)\r\n HLocalStorage.removeItem(kAppLogo)\r\n })\r\n },\r\n initLastSaved: () => {\r\n const sidemenu = HLocalStorage.getString(kSideMenu, \"\")\r\n const appmenu = HLocalStorage.getString(kAppMenu, \"\")\r\n const appLogo = HLocalStorage.getString(kAppLogo, \"\")\r\n if (sidemenu) {\r\n ModuleProjectScreen.parseData({\r\n side_menu: sidemenu,\r\n app_menu: appmenu,\r\n appLogo_url: appLogo,\r\n })\r\n }\r\n },\r\n requestProjectScreens: () => {\r\n ApiGeneric({\r\n method: \"POST\",\r\n path: \"ProjectScreenHeader\",\r\n name: \"ProjectScreens\",\r\n data: {},\r\n })\r\n .then(response => {\r\n if (response.Data) {\r\n ModuleProjectScreen.parseData(response.Data)\r\n }\r\n })\r\n .catch(error => {})\r\n },\r\n updateRoutes: data => {},\r\n parseData: data => {\r\n let _sideMenu = []\r\n let _app_menu = []\r\n if (data.side_menu) {\r\n _sideMenu = HJson.getObj(data.side_menu, [])\r\n HLocalStorage.saveString(kSideMenu, data.side_menu)\r\n }\r\n if (data.app_menu) {\r\n _app_menu = HJson.getObj(data.app_menu, [])\r\n HLocalStorage.saveString(kAppMenu, data.app_menu)\r\n }\r\n if (data.appLogo_url) {\r\n HCF.setCF(KConfigApp.appLogo_url, data.appLogo_url)\r\n HLocalStorage.saveString(kAppLogo, data.appLogo_url)\r\n }\r\n HCF.setCF(kSideMenuHCF, _sideMenu)\r\n HCF.setCF(kAppMenuHCF, _app_menu)\r\n console.warn(\"parseData:\", data, _sideMenu, _app_menu)\r\n HEE.emit(KEventsApp.ee_sidemenu_forceupdate)\r\n },\r\n}\r\n\r\nexport default ModuleProjectScreen\r\n","import { HModules, CSuppense, HUtils } from \"@macashipo/mlib\"\r\nimport MyPageOne from \"./MyPage\"\r\nimport MyUIOne from \"./MyUI\"\r\nimport MyButtonOne from \"./MyButton\"\r\nimport MyLayoutOne from \"./MyLayout\"\r\nimport MyTableCellOne from \"./MyTableCell\"\r\nimport MyTableHeaderOne from \"./MyTableHeader\"\r\nimport MyFormControlOne from \"./MyFormControl\"\r\nimport MyBaseOne from \"./MyBase\"\r\nimport MyTableFilterControlOne from \"./MyTableFilterControl\"\r\nimport MyLibOne from \"./MyLib\"\r\nimport MyChartOne from \"./MyChart\"\r\nimport MyCardOne from \"./MyCard\"\r\nimport CategoryScreen from \"./boot/categoryscreen\"\r\nimport ProjectScreen from \"./boot/projectscreen\"\r\nconst ModuleAdminPanel = {\r\n _key: \"adminpanel\",\r\n _fnList: {},\r\n _config: {},\r\n getMyKey: () => {\r\n return \"adminpanel\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleAdminPanel, {\r\n MyBaseOne,\r\n MyUIOne,\r\n MyPageOne,\r\n MyLayoutOne,\r\n MyButtonOne,\r\n MyTableCellOne,\r\n MyFormControlOne,\r\n MyTableFilterControlOne,\r\n MyLibOne,\r\n MyChartOne,\r\n MyCardOne,\r\n MyTableHeaderOne,\r\n })\r\n CategoryScreen.init(HConfig)\r\n ProjectScreen.init(HConfig)\r\n CSuppense.LazyLoading = () => {\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n HUtils.runFuntion(HConfig, \"addPrivateRoutes\", [\r\n [\r\n {\r\n Id: \"myprofile\",\r\n UIUrl: \"/my-profile\",\r\n UIType: \"myprofile\",\r\n },\r\n ],\r\n ])\r\n },\r\n}\r\n\r\nexport default ModuleAdminPanel\r\n","import { HModules, HCF, HLink, HLocalStorage } from \"@macashipo/mlib\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nimport ReactDOM from \"react-dom\"\r\nimport React from \"react\"\r\nimport { Animated } from \"react-animated-css\"\r\nimport styled from \"styled-components\"\r\nimport { Button } from \"reactstrap\"\r\nimport i18next from \"i18next\"\r\nimport \"src/assets/scss/animate.css\"\r\nconst kDivId = \"chromenotify_question\"\r\nconst kLocalShowedChromeNotify = \"chromenotify_question_showed\"\r\nconst kPathSWNotify = \"sw-notify.js\"\r\nconst WrapDiv = styled.div`\r\n font-size: 16px;\r\n position: fixed;\r\n z-index: 2258594000;\r\n top: 0;\r\n left: 0;\r\n right: 0;\r\n -webkit-font-smoothing: initial;\r\n &.hide {\r\n display: none;\r\n }\r\n & div.a-content {\r\n width: 450px;\r\n box-sizing: border-box;\r\n max-width: 100%;\r\n margin: 0 auto;\r\n box-shadow: 0 1px 6px rgba(5, 27, 44, 0.06),\r\n 0 2px 32px rgba(5, 27, 44, 0.16) !important;\r\n background: #fff !important;\r\n padding: 20px 20px 15px 20px;\r\n border-bottom-left-radius: 0.5em;\r\n border-bottom-right-radius: 0.5em;\r\n & .a-body {\r\n display: flex;\r\n flex-direction: row;\r\n align-items: center;\r\n & i {\r\n font-size: 3em;\r\n margin-right: 10px;\r\n color: #0081ff;\r\n }\r\n }\r\n & .a-btns {\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-end;\r\n & > button:first-child {\r\n margin-right: 5px;\r\n }\r\n }\r\n }\r\n`\r\nconst NotifyQuestion = props => {\r\n return (\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n {i18next.t(\r\n \"We'd like to show you notifications for lastest news and updates.\"\r\n )}\r\n
\r\n
\r\n {\r\n var _div = document.querySelector(`#${kDivId}>div`)\r\n _div.classList.add(\"hide\")\r\n HLocalStorage.saveString(kLocalShowedChromeNotify, \"2\")\r\n }}\r\n >\r\n {i18next.t(\"Maybe Later\")}\r\n \r\n {\r\n var _div = document.querySelector(`#${kDivId}>div`)\r\n _div.classList.add(\"hide\")\r\n ModuleChromeNotification._fnList.requestPermission({\r\n cbSuccess: () => {\r\n ModuleChromeNotification._fnList.subscribe()\r\n },\r\n })\r\n }}\r\n >\r\n {i18next.t(\"Allow\")}\r\n \r\n
\r\n
\r\n \r\n
\r\n )\r\n}\r\n\r\n//gen from: https://vapidkeys.com/\r\n// {\r\n// \"subject\": \"mailto: \",\r\n// \"publicKey\": \"BF4SZXN6S2qMGkWzZ7HSXx2-OQ2Y1wfiEZ4aA1QIzQxZmv5btlQwwGgIW5ffRS5wzNFB6gxnralCJAmFQxbdTUE\",\r\n// \"privateKey\": \"7PLays62IEqnaBaL_a_08cdQyDtRq0mGGXb81XOPOTc\"\r\n// }\r\nconst ModuleChromeNotification = {\r\n _key: \"chrome_notification\",\r\n _fnList: {\r\n requestPermission: ({ cbSuccess } = {}) => {\r\n if (!(\"Notification\" in window)) {\r\n console.warn(\"This browser does not support desktop notification\")\r\n HLocalStorage.saveString(kLocalShowedChromeNotify, \"-2\")\r\n } else {\r\n Notification.requestPermission().then(result => {\r\n if (result === \"granted\") {\r\n console.warn(\"granted\")\r\n if (cbSuccess) {\r\n cbSuccess()\r\n }\r\n } else {\r\n HLocalStorage.saveString(kLocalShowedChromeNotify, \"-3\")\r\n }\r\n })\r\n }\r\n },\r\n checkExist: async () => {\r\n let swregister = await navigator.serviceWorker.register(kPathSWNotify)\r\n navigator.serviceWorker.ready.then(function (serviceWorkerRegistration) {\r\n console.log(\"serviceWorkerRegistration\", serviceWorkerRegistration)\r\n serviceWorkerRegistration.pushManager.getSubscription().then(sub => {\r\n console.warn(\"sub:\", sub)\r\n console.warn(\r\n \"sub p256dh:\",\r\n sub.getKey(\"p256dh\"),\r\n ModuleChromeNotification._fnList.encode(sub.getKey(\"p256dh\"))\r\n )\r\n console.warn(\r\n \"sub auth:\",\r\n sub.getKey(\"auth\"),\r\n ModuleChromeNotification._fnList.encode(sub.getKey(\"auth\"))\r\n )\r\n })\r\n })\r\n },\r\n encode: buffer => {\r\n return btoa(String.fromCharCode.apply(null, new Uint8Array(buffer)))\r\n .replace(/\\+/g, \"-\")\r\n .replace(/\\//g, \"_\")\r\n .replace(/=+$/, \"\")\r\n },\r\n subscribe: async () => {\r\n let swregister = await navigator.serviceWorker.register(kPathSWNotify)\r\n console.log(\"swregister\", swregister)\r\n // let sw = await navigator.serviceWorker.ready\r\n // console.log(\"sw\", sw)\r\n // let push = await sw.pushManager.subscribe({\r\n // userVisibleOnly: true,\r\n // applicationServerKey:\r\n // \"BF4SZXN6S2qMGkWzZ7HSXx2-OQ2Y1wfiEZ4aA1QIzQxZmv5btlQwwGgIW5ffRS5wzNFB6gxnralCJAmFQxbdTUE\",\r\n // })\r\n // console.warn(JSON.stringify(push))\r\n\r\n navigator.serviceWorker.ready.then(function (serviceWorkerRegistration) {\r\n console.log(\"serviceWorkerRegistration\", serviceWorkerRegistration)\r\n var options = {\r\n userVisibleOnly: true,\r\n applicationServerKey:\r\n \"BF4SZXN6S2qMGkWzZ7HSXx2-OQ2Y1wfiEZ4aA1QIzQxZmv5btlQwwGgIW5ffRS5wzNFB6gxnralCJAmFQxbdTUE\",\r\n }\r\n serviceWorkerRegistration.pushManager.subscribe(options).then(\r\n function (pushSubscription) {\r\n console.log(\"pushSubscription\", pushSubscription.endpoint)\r\n HLocalStorage.saveString(kLocalShowedChromeNotify, \"1\")\r\n // The push subscription details needed by the application\r\n // server are now available, and can be sent to it using,\r\n // for example, an XMLHttpRequest.\r\n },\r\n function (error) {\r\n // During development it often helps to log errors to the\r\n // console. In a production environment it might make sense to\r\n // also report information about errors back to the\r\n // application server.\r\n console.log(\"error:\", error)\r\n HLocalStorage.saveString(kLocalShowedChromeNotify, \"-1\")\r\n }\r\n )\r\n })\r\n },\r\n },\r\n _config: {},\r\n getMyKey: () => {\r\n return \"chrome_notification\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleChromeNotification, {})\r\n // navigator.serviceWorker.ready.then(registration => {\r\n // if (\"pushManager\" in registration) {\r\n // registration.pushManager.getSubscription().then(sub => {\r\n // if (sub) {\r\n // console.log(\"sub\", sub)\r\n // }\r\n // })\r\n // }\r\n // })\r\n // navigator.serviceWorker.register(kPathSWNotify)\r\n //\r\n let _currentLocalShowed = HLocalStorage.getString(kLocalShowedChromeNotify)\r\n if (HCF.getCF(KConfigApp.hasPushNotify)) {\r\n var _divNotify = document.getElementById(kDivId)\r\n if (!_divNotify && _currentLocalShowed != \"1\") {\r\n _divNotify = document.createElement(\"div\")\r\n _divNotify.setAttribute(\"id\", kDivId)\r\n document.body.appendChild(_divNotify)\r\n setTimeout(() => {\r\n console.warn(\"add portal\")\r\n let _contain = document.getElementById(kDivId)\r\n if (_contain) {\r\n ReactDOM.render(\r\n ReactDOM.createPortal(, _contain),\r\n document.createElement(\"div\")\r\n )\r\n }\r\n }, 2000)\r\n } else {\r\n ModuleChromeNotification._fnList.checkExist()\r\n }\r\n }\r\n },\r\n}\r\n\r\nexport default ModuleChromeNotification\r\n","import React from \"react\"\r\nimport { MyUIHelpers } from \"@macashipo/mlib\"\r\nconst MUI_notifySignalR = React.lazy(() => import(\"./Types/notifySignalR\"))\r\n\r\nconst List = {\r\n notifySignalR: MUI_notifySignalR,\r\n}\r\nconst MyUIOne = {\r\n init() {\r\n MyUIHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","import { HModules, HCF, HLink } from \"@macashipo/mlib\"\r\nimport MyUIOne from \"./MyUI\"\r\nconst ModuleSignalR = {\r\n _key: \"signalR\",\r\n _fnList: {},\r\n _config: {},\r\n getMyKey: () => {\r\n return \"signalR\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleSignalR, { MyUIOne })\r\n },\r\n}\r\n\r\nexport default ModuleSignalR\r\n","import { useEffect, useRef, useState } from \"react\"\r\nconst useCountdown = (targetDate, { stopWhenFinish, forceStop } = {}) => {\r\n // const [stop, setStop] = useState(false)\r\n const countDownDate = new Date(targetDate).getTime()\r\n const config = useRef({\r\n needStopInterval: false,\r\n }).current\r\n\r\n const [countDown, setCountDown] = useState(\r\n countDownDate - new Date().getTime()\r\n )\r\n // console.log(\"countDownDate:\", countDownDate, countDown)\r\n useEffect(() => {\r\n const interval = setInterval(() => {\r\n // console.log(\"interval tick\", stopWhenFinish, config.needStopInterval)\r\n if (stopWhenFinish && config.needStopInterval) {\r\n clearInterval(interval)\r\n } else if (forceStop) {\r\n config.needStopInterval = true\r\n setCountDown(0)\r\n } else {\r\n let _countDown = countDownDate - new Date().getTime()\r\n if (_countDown <= 0) {\r\n config.needStopInterval = true\r\n }\r\n setCountDown(_countDown)\r\n }\r\n }, 500)\r\n return () => clearInterval(interval)\r\n }, [countDownDate, stopWhenFinish, forceStop, config])\r\n\r\n return getReturnValues(countDown)\r\n}\r\n\r\nconst getReturnValues = countDown => {\r\n // calculate time left\r\n if (countDown > 0) {\r\n const days = Math.floor(countDown / (1000 * 60 * 60 * 24))\r\n const hours = Math.floor(\r\n (countDown % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)\r\n )\r\n const minutes = Math.floor((countDown % (1000 * 60 * 60)) / (1000 * 60))\r\n const seconds = Math.floor((countDown % (1000 * 60)) / 1000)\r\n const totalSeconds = Math.floor(countDown / 1000)\r\n const finish = countDown <= 0 ? true : false\r\n return [days, hours, minutes, seconds, totalSeconds, finish]\r\n } else {\r\n const days = 0\r\n const hours = 0\r\n const minutes = 0\r\n const seconds = 0\r\n const totalSeconds = 0\r\n const finish = countDown <= 0 ? true : false\r\n return [days, hours, minutes, seconds, totalSeconds, finish]\r\n }\r\n}\r\n\r\nexport { useCountdown }\r\n","import React, { useRef } from \"react\"\r\nimport styled from \"styled-components\"\r\nimport { useCountdown } from \"src/core/hook/useCountdown\"\r\nimport { HUtils } from \"@macashipo/mlib\"\r\nimport { Button } from \"reactstrap\"\r\nconst Wrap = styled.div`\r\n padding: 1rem;\r\n padding-bottom: 0px;\r\n padding-left: 0px;\r\n padding-right: 0px;\r\n & .a-body {\r\n display: flex;\r\n flex-direction: row;\r\n align-items: center;\r\n & .a-icon {\r\n font-size: 30px;\r\n color: #cbc70f;\r\n width: 40px;\r\n height: 40px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n }\r\n }\r\n & .aa-footer {\r\n display: flex;\r\n align-items: center;\r\n flex-direction: row;\r\n justify-content: end;\r\n margin-top: 1rem;\r\n & > button {\r\n margin-left: 5px;\r\n }\r\n }\r\n`\r\nconst TextDisplay = props => {\r\n const { days, hours, minutes, seconds } = props\r\n return (\r\n \r\n {days > 0 && `${days} days `}\r\n {hours > 0 && `${hours} hours `}\r\n {minutes > 0 && `${minutes} minutes `}\r\n {seconds > 0 && `${seconds} seconds`}\r\n \r\n )\r\n}\r\nconst CheckIdleCountDown = props => {\r\n // const [fu, forceUpdate] = React.useState(0)\r\n var countSeconds = props.countSeconds || 60\r\n if (props.isExpired === true) {\r\n countSeconds = -1\r\n }\r\n const fnList = props.fnList || {}\r\n\r\n const targetDate = useRef(\r\n new Date(new Date().getTime() + countSeconds * 1000)\r\n )\r\n const forceStop = useRef(false)\r\n const [days, hours, minutes, seconds, totalSeconds] = useCountdown(\r\n targetDate.current,\r\n {\r\n stopWhenFinish: true,\r\n forceStop: forceStop.current,\r\n }\r\n )\r\n if (totalSeconds <= 0) {\r\n // HUtils.runFuntion(fnList, \"hideModal\")\r\n HUtils.runFuntion(fnList, \"onTimeout\")\r\n } else {\r\n HUtils.runFuntion(fnList, \"updateRemainSecond\", [\r\n totalSeconds,\r\n () => {\r\n console.log(\"updateExpired\")\r\n if (forceStop.current == false) {\r\n console.log(\"need update expired\", totalSeconds, forceStop.current)\r\n forceStop.current = true\r\n // forceUpdate(fu + 1)\r\n }\r\n },\r\n ])\r\n }\r\n console.log(\"render check idle\", totalSeconds)\r\n return (\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n {totalSeconds > 0 ? (\r\n
Your session is about to expire
\r\n ) : (\r\n
Your session expired
\r\n )}\r\n {totalSeconds > 0 && (\r\n
\r\n You will be logged out in{\" \"}\r\n \r\n .\r\n
\r\n )}\r\n
\r\n
\r\n {totalSeconds > 0 ? (\r\n
\r\n {\r\n HUtils.runFuntion(fnList, \"onSignOut\")\r\n }}\r\n >\r\n Sign me out\r\n \r\n {\r\n HUtils.runFuntion(fnList, \"onKeepSignIn\")\r\n HUtils.runFuntion(fnList, \"hideModal\")\r\n }}\r\n >\r\n Keep me signed in\r\n \r\n
\r\n ) : (\r\n
\r\n {\r\n HUtils.runFuntion(fnList, \"onBackToSignIn\")\r\n }}\r\n >\r\n Back to sign in\r\n \r\n
\r\n )}\r\n
\r\n )\r\n}\r\n\r\nexport default CheckIdleCountDown\r\n","import React from \"react\"\r\nimport { MyUIHelpers } from \"@macashipo/mlib\"\r\n// const MUI_checkidle_countdown = React.lazy(() =>\r\n// import(\"./Types/checkidle_countdown\")\r\n// )\r\nimport MUI_checkidle_countdown from \"./Types/checkidle_countdown\"\r\n\r\n// const List = {\r\n// checkidle_countdown: MUI_checkidle_countdown,\r\n// }\r\nconst ListNoLazy = {\r\n checkidle_countdown: MUI_checkidle_countdown,\r\n}\r\nconst MyUIOne = {\r\n init() {\r\n // MyUIHelpers.addTypesFromListLazy(List)\r\n //Chuyen sang nolazy de ko bi loi khi mat connection luc bat popup\r\n MyUIHelpers.addTypesFromListWithoutLazy(ListNoLazy)\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","//require version\r\n//auth: 20221207\r\n// import LodashDebounce from \"lodash/debounce\"\r\nimport LodashThrottle from \"lodash/throttle\"\r\nimport { MyModal } from \"src/core/components\"\r\nimport { HCF, HLocalStorage, HUtils, HModules, MyUI } from \"@macashipo/mlib\"\r\nimport {\r\n authLogoutWithNothing,\r\n authIsLogged,\r\n authCheckLoginAgain,\r\n registerAfterLogout,\r\n} from \"src/core/helpers/auth\"\r\nimport { HConstant } from \"src/core/helpers\"\r\nimport MyUIOne from \"./MyUI\"\r\n\r\nconst CheckIdleStatus = {\r\n Check: \"Check\", //dang dem\r\n Countdown: \"Countdown\", //dang dem nguoc signout\r\n Expired: \"Expired\", //da logout\r\n}\r\nconst KCheckIdle = {\r\n // kCheckIdleLocal: \"kCheckIdleLocal\",\r\n checkIdleLocalTimeIdle: \"checkIdleLocalTimeIdle\",\r\n hasCheckIdle: \"hasCheckIdle\", //co check idle hay khong\r\n checkIdleSecond: \"checkIdleSecond\", //thoi gian se hien popup thong bao het han\r\n checkIdleInterval: \"checkIdleInterval\", //thoi gian kiem tra lien tuc sau x giay\r\n checkIdleCountdown: \"checkIdleCountdown\", //thoi gian popup thong bao het han se dem de logout\r\n checkIdleCountdownRemainSecond: \"checkIdleCountdownRemainSecond\", //thoi gian dem nguoc con lai\r\n checkIdleStatus: \"checkIdleStatus\",\r\n _noCheckIdle: \"_noCheckIdle\",\r\n}\r\nconst ModuleCheckIdle = {\r\n _key: \"check_idle\",\r\n _fnList: {\r\n resetTimerDebounce: null,\r\n start: () => {\r\n // ModuleCheckIdle._config.currentIdle = 0\r\n //remove all current\r\n HLocalStorage.removeItem(KCheckIdle.checkIdleCountdownRemainSecond)\r\n HLocalStorage.saveString(\r\n KCheckIdle.checkIdleStatus,\r\n CheckIdleStatus.Check\r\n )\r\n ModuleCheckIdle._fnList.updateTimeIdle()\r\n if (ModuleCheckIdle._config.timer) {\r\n clearInterval(ModuleCheckIdle._config.timer)\r\n }\r\n ModuleCheckIdle._config.timer = setInterval(\r\n ModuleCheckIdle._fnList.timerIncrement,\r\n ModuleCheckIdle._config.checkAfterSecond * 1000\r\n )\r\n document.addEventListener(\r\n \"mousemove\",\r\n ModuleCheckIdle._fnList.resetTimerDebounce\r\n )\r\n document.addEventListener(\r\n \"touchmove\",\r\n ModuleCheckIdle._fnList.resetTimerDebounce\r\n )\r\n document.addEventListener(\r\n \"keydown\",\r\n ModuleCheckIdle._fnList.resetTimerDebounce\r\n )\r\n },\r\n onIdle: ({ isExpired } = {}) => {\r\n console.log(\"on Idle\")\r\n if (isExpired !== true) {\r\n HLocalStorage.saveString(\r\n KCheckIdle.checkIdleStatus,\r\n CheckIdleStatus.Countdown\r\n )\r\n }\r\n clearInterval(ModuleCheckIdle._config.timer)\r\n document.removeEventListener(\r\n \"mousemove\",\r\n ModuleCheckIdle._fnList.resetTimerDebounce\r\n )\r\n document.removeEventListener(\r\n \"touchmove\",\r\n ModuleCheckIdle._fnList.resetTimerDebounce\r\n )\r\n document.removeEventListener(\r\n \"keydown\",\r\n ModuleCheckIdle._fnList.resetTimerDebounce\r\n )\r\n HLocalStorage.removeItem(KCheckIdle.checkIdleLocalTimeIdle)\r\n MyModal.showFromComponent(\r\n props => {\r\n return (\r\n \r\n )\r\n },\r\n {\r\n size: \"xs\",\r\n showHeader: false,\r\n modalCentered: true,\r\n backdrop: \"static\",\r\n fnList: {\r\n onTimeout: () => {\r\n console.log(\"timeout\")\r\n HLocalStorage.saveString(\r\n KCheckIdle.checkIdleStatus,\r\n CheckIdleStatus.Expired\r\n )\r\n authLogoutWithNothing()\r\n document.addEventListener(\r\n \"visibilitychange\",\r\n ModuleCheckIdle._fnList.ee_onfocus_after_signout\r\n )\r\n },\r\n updateRemainSecond: (totalSecondCountdown, updateExpired) => {\r\n let _current = HLocalStorage.getString(\r\n KCheckIdle.checkIdleCountdownRemainSecond\r\n )\r\n let _currentStatus = ModuleCheckIdle._fnList.getCurrentStatus()\r\n if (_currentStatus == CheckIdleStatus.Expired) {\r\n //update modal expired\r\n if (updateExpired) {\r\n updateExpired()\r\n }\r\n return\r\n } else if (_currentStatus == CheckIdleStatus.Check) {\r\n var _currentTime = HLocalStorage.getString(\r\n KCheckIdle.checkIdleLocalTimeIdle\r\n )\r\n if (_currentTime) {\r\n console.log(\"other tab is check time again\")\r\n ModuleCheckIdle._fnList.start()\r\n //hide modal countdown\r\n MyModal.hideModalComponent()\r\n }\r\n }\r\n if (totalSecondCountdown < _current) {\r\n HLocalStorage.saveString(\r\n KCheckIdle.checkIdleCountdownRemainSecond,\r\n totalSecondCountdown\r\n )\r\n } else {\r\n console.log(\"no save countdown\", totalSecondCountdown, _current)\r\n }\r\n },\r\n onSignOut: () => {\r\n console.log(\"onSignOut\")\r\n authLogoutWithNothing()\r\n window.location.reload()\r\n },\r\n onKeepSignIn: () => {\r\n console.log(\"onKeepSignIn\")\r\n ModuleCheckIdle._fnList.start()\r\n },\r\n onBackToSignIn: () => {\r\n console.log(\"onBackToSignInonBackToSignIn\")\r\n window.location.reload()\r\n },\r\n },\r\n }\r\n )\r\n // MyModal.showMyDialog({\r\n // title: \"Session Expire Warning\",\r\n // msg: `You're being timed out due to inactivity. \\nYou will logged off automatically`,\r\n // size: \"xs\",\r\n // modalCentered: true,\r\n // backdrop: \"static\",\r\n // showHeader: false,\r\n // showFooter: true,\r\n // showFooterOK: true,\r\n // classNameBody: \"text-pre-line\",\r\n // onClickOK: () => {\r\n // console.log(\"ok\")\r\n // window.location.reload()\r\n // },\r\n // })\r\n },\r\n ee_onfocus_after_signout: () => {\r\n if (document.visibilityState == \"visible\") {\r\n console.log(\"just focus tab:\", new Date().toISOString())\r\n if (authCheckLoginAgain()) {\r\n document.removeEventListener(\r\n \"visibilitychange\",\r\n ModuleCheckIdle._fnList.ee_onfocus_after_signout\r\n )\r\n console.log(\"login again\")\r\n ModuleCheckIdle._fnList.start()\r\n //hide modal expired\r\n MyModal.hideModalComponent()\r\n }\r\n }\r\n },\r\n updateTimeIdle: () => {\r\n let _current = new Date().getTime()\r\n _current += ModuleCheckIdle._config.idleAfterSecond * 1000\r\n HLocalStorage.saveString(KCheckIdle.checkIdleLocalTimeIdle, _current)\r\n // HLocalStorage.saveString(\r\n // KCheckIdle.checkIdleStatus,\r\n // CheckIdleStatus.Check\r\n // )\r\n },\r\n getCurrentStatus: () => {\r\n return HLocalStorage.getString(KCheckIdle.checkIdleStatus)\r\n },\r\n resetTimer: () => {\r\n // console.log(\"resetTimer\")\r\n // ModuleCheckIdle._config.currentIdle = 0\r\n // HLocalStorage.removeItem(KCheckIdle.kCheckIdleLocal)\r\n ModuleCheckIdle._fnList.updateTimeIdle()\r\n //\r\n },\r\n timerIncrement: () => {\r\n // ModuleCheckIdle._config.currentIdle +=\r\n let _currentTime = new Date().getTime()\r\n let _currentStatus = HLocalStorage.getString(KCheckIdle.checkIdleStatus)\r\n if (_currentStatus == CheckIdleStatus.Countdown) {\r\n ModuleCheckIdle._fnList.onIdle()\r\n return\r\n } else if (_currentStatus == CheckIdleStatus.Expired) {\r\n ModuleCheckIdle._fnList.onIdle({ isExpired: true })\r\n return\r\n }\r\n //still check\r\n let _currentTimeIdle = Number(\r\n HLocalStorage.getString(KCheckIdle.checkIdleLocalTimeIdle)\r\n )\r\n if (_currentTime >= _currentTimeIdle) {\r\n ModuleCheckIdle._fnList.onIdle()\r\n }\r\n console.log(\r\n \"timer:\",\r\n _currentTime,\r\n _currentTimeIdle,\r\n _currentTimeIdle - _currentTime\r\n )\r\n },\r\n },\r\n _config: {\r\n // currentIdle: 0,\r\n timer: null,\r\n countdown: 60,\r\n idleAfterSecond: 60 * 10, //10p\r\n checkAfterSecond: 5, //5s\r\n },\r\n getMyKey: () => {\r\n return \"check_idle\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleCheckIdle, { MyUIOne })\r\n console.log(\"run check_idle\")\r\n //\r\n // ModuleCheckIdle._fnList.resetTimerDebounce = LodashDebounce(\r\n // ModuleCheckIdle._fnList.resetTimer,\r\n // 500\r\n // )\r\n ModuleCheckIdle._fnList.resetTimerDebounce = LodashThrottle(\r\n ModuleCheckIdle._fnList.resetTimer,\r\n 500\r\n )\r\n //\r\n let _hasCheckIdle = HCF.getCF(KCheckIdle.hasCheckIdle)\r\n let _checkSecond = HCF.getCF(KCheckIdle.checkIdleSecond)\r\n let _checkCountdown = HCF.getCF(KCheckIdle.checkIdleCountdown)\r\n let _checkIdleInterval = HCF.getCF(KCheckIdle.checkIdleInterval)\r\n if (_checkSecond > 0) {\r\n ModuleCheckIdle._config.idleAfterSecond = _checkSecond\r\n }\r\n if (_checkIdleInterval > 0) {\r\n ModuleCheckIdle._config.checkAfterSecond = _checkIdleInterval\r\n }\r\n if (_checkCountdown > 0) {\r\n ModuleCheckIdle._config.countdown = _checkCountdown\r\n }\r\n if (_hasCheckIdle === true) {\r\n console.log(\"check_idle run start\")\r\n if (authIsLogged()) {\r\n let _noCheck = HLocalStorage.getString(KCheckIdle._noCheckIdle)\r\n if (_noCheck === \"1\") {\r\n return\r\n }\r\n ModuleCheckIdle._fnList.start()\r\n } else {\r\n //waiting login\r\n HUtils.runFuntion(\r\n HConfig,\r\n HConstant.HConfig.FnList.registerAfterLogin,\r\n [\r\n () => {\r\n console.log(\"check idle: call request when after login \")\r\n ModuleCheckIdle._fnList.start()\r\n },\r\n ]\r\n )\r\n }\r\n }\r\n //after logout\r\n registerAfterLogout(\"afterlogout_checkidle\", () => {\r\n let _currentTimeIdle = HLocalStorage.getString(\r\n KCheckIdle.checkIdleLocalTimeIdle\r\n )\r\n if (_currentTimeIdle != null) {\r\n HLocalStorage.removeItem(KCheckIdle.checkIdleLocalTimeIdle)\r\n window.location.reload()\r\n }\r\n })\r\n },\r\n}\r\n\r\n// document.addEventListener(\"visibilitychange\", () => {\r\n// console.log(\"visibilitychange\", document.visibilityState)\r\n// if (document.visibilityState == \"visible\") {\r\n// //focus tab browser\r\n// }\r\n// })\r\n\r\nexport default ModuleCheckIdle\r\n","import React from \"react\"\r\nimport { MyPageHelpers } from \"@macashipo/mlib\"\r\nconst MP_prj_manager = React.lazy(() => import(\"./prj_manager\"))\r\nconst MP_prj_info = React.lazy(() => import(\"./prj_info\"))\r\nconst MP_prj_api = React.lazy(() => import(\"./prj_api\"))\r\nconst MP_prj_task = React.lazy(() => import(\"./prj_task\"))\r\nconst MP_prj_dailytask = React.lazy(() => import(\"./prj_dailytask\"))\r\nconst MP_prj_dailytask_detail = React.lazy(() =>\r\n import(\"./prj_dailytask_detail\")\r\n)\r\nconst MP_prj_schedule = React.lazy(() => import(\"./prj_schedule\"))\r\nconst MP_prj_users = React.lazy(() => import(\"./prj_users\"))\r\nconst MP_prj_releases = React.lazy(() => import(\"./prj_releases\"))\r\nconst MP_prj_infoenv = React.lazy(() => import(\"./prj_infoenv\"))\r\nconst MP_prj_flow = React.lazy(() => import(\"./prj_flow\"))\r\nconst List = {\r\n prj_flow: MP_prj_flow,\r\n prj_info: MP_prj_info,\r\n prj_api: MP_prj_api,\r\n prj_task: MP_prj_task,\r\n prj_dailytask: MP_prj_dailytask,\r\n prj_dailytask_detail: MP_prj_dailytask_detail,\r\n prjmanager: MP_prj_manager,\r\n prj_users: MP_prj_users,\r\n prj_releases: MP_prj_releases,\r\n prj_infoenv: MP_prj_infoenv,\r\n prj_schedule: MP_prj_schedule,\r\n}\r\nconst MyPageOne = {\r\n init() {\r\n MyPageHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import React from \"react\"\r\nimport { MyUIHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MUICard_Task = React.lazy(() => import(\"./card_task\"))\r\nconst MUINewDailyTask = React.lazy(() => import(\"./prj_dailytask\"))\r\nconst MUINewProject = React.lazy(() => import(\"./prj_new_project\"))\r\nconst MUITaskItem = React.lazy(() => import(\"./prj_task_item\"))\r\nconst MUINewTask = React.lazy(() => import(\"./prj_new_task\"))\r\nconst MUIUserSetting = React.lazy(() => import(\"./prj_task_user_setting\"))\r\nconst MUIProjectItem = React.lazy(() => import(\"./prj_pj_item\"))\r\nconst MUIAPITestCase = React.lazy(() => import(\"./prj_api_testcases\"))\r\nconst MUIAPISetting = React.lazy(() => import(\"./prj_api_setting\"))\r\nconst MUINewRelease = React.lazy(() => import(\"./prj_new_release\"))\r\nconst MUISET = React.lazy(() => import(\"./prj_set\"))\r\nconst List = {\r\n card_task: MUICard_Task,\r\n prj_dailytask: MUINewDailyTask,\r\n prj_new_project: MUINewProject,\r\n prj_task_item: MUITaskItem,\r\n prj_new_task: MUINewTask,\r\n prj_new_release: MUINewRelease,\r\n prj_task_user_setting: MUIUserSetting,\r\n prj_pj_item: MUIProjectItem,\r\n prj_api_testcases: MUIAPITestCase,\r\n prj_api_setting: MUIAPISetting,\r\n prj_set: MUISET,\r\n}\r\nconst MyUIOne = {\r\n init() {\r\n MyUIHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","import { HModules, HCF, HLink, HUtils } from \"@macashipo/mlib\"\r\nimport MyPageOne from \"./MyPage\"\r\nimport MyUIOne from \"./MyUI\"\r\nconst ModuleQLProject = {\r\n _key: \"qlproject\",\r\n _fnList: {},\r\n _config: {},\r\n getMyKey: () => {\r\n return \"qlproject\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleQLProject, { MyUIOne, MyPageOne })\r\n HUtils.runFuntion(HConfig, \"addPrivateRoutes\", [\r\n [\r\n {\r\n Id: \"pjdailytask\",\r\n UIUrl: \"/dailytasks/:taskid\",\r\n UIType: \"prj_dailytask_detail\",\r\n },\r\n {\r\n Id: \"pjdailytask\",\r\n UIUrl: \"/dailytasks\",\r\n UIType: \"prj_dailytask\",\r\n },\r\n {\r\n Id: \"pjmanager\",\r\n UIUrl: \"/pj/:pj\",\r\n UIType: \"prjmanager\",\r\n },\r\n {\r\n Id: \"pjmanager\",\r\n UIUrl: \"/pj\",\r\n UIType: \"prjmanager\",\r\n },\r\n ],\r\n ])\r\n },\r\n}\r\n\r\nexport default ModuleQLProject\r\n","import React from \"react\"\r\nimport { MyUIHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MWContent = React.lazy(() => import(\"./Types/WContent\"))\r\nconst MUnsupportedMedia = React.lazy(() => import(\"./Types/UnsupportedMedia\"))\r\nconst List = {\r\n wcontent: MWContent,\r\n unsupportedmedia: MUnsupportedMedia,\r\n}\r\nconst MyUIOne = {\r\n init() {\r\n MyUIHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyUIOne\r\n","import React from \"react\"\r\nimport { MyPageHelpers } from \"@macashipo/mlib\"\r\n\r\nconst PageARowForm = React.lazy(() => import(\"./Types/PageARowForm\"))\r\n\r\nconst List = {\r\n a_row_form: PageARowForm,\r\n}\r\nconst MyPageOne = {\r\n init() {\r\n MyPageHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import React from \"react\"\r\nimport { MyControlHelpers } from \"@macashipo/mlib\"\r\nconst MCInputCurrency = React.lazy(() => import(\"./Types/input_currency\"))\r\nconst MCInputPercentage = React.lazy(() => import(\"./Types/input_percentage\"))\r\nconst MCInputText = React.lazy(() => import(\"./Types/input_text\"))\r\nconst MCInputNumber = React.lazy(() => import(\"./Types/input_number\"))\r\nconst MCGroupControls = React.lazy(() => import(\"./Types/group_controls\"))\r\nconst MCInputDate = React.lazy(() => import(\"./Types/input_date\"))\r\nconst MCInputDateString = React.lazy(() => import(\"./Types/input_date_string\"))\r\nconst MCInputAddress = React.lazy(() => import(\"./Types/input_address\"))\r\nconst MCInputCheckbox = React.lazy(() => import(\"./Types/checkbox_custom\"))\r\nconst MCReadonly = React.lazy(() => import(\"./Types/readonly_text\"))\r\nconst MCButton = React.lazy(() => import(\"./Types/button\"))\r\nconst MCCheckInbox = React.lazy(() => import(\"./Types/check_inbox\"))\r\nconst MCCheckYesNo = React.lazy(() => import(\"./Types/check_yes_no\"))\r\nconst MCRadioOption = React.lazy(() => import(\"./Types/check_option_radio\"))\r\nconst MCSelect2IconOption = React.lazy(\r\n () => import(\"./Types/select2_icon_option\")\r\n)\r\nconst MCLink = React.lazy(() => import(\"./Types/link\"))\r\nconst MC_input_textarea = React.lazy(() => import(\"./Types/input_textarea\"))\r\nconst MC_readonly_html = React.lazy(() => import(\"./Types/readonly_html\"))\r\nconst MC_input_textarea_autosize = React.lazy(\r\n () => import(\"./Types/input_textarea_autosize\")\r\n)\r\nconst MC_files = React.lazy(() => import(\"./Types/mc_files\"))\r\n/**v1 page module*/\r\nconst v1_mfc_select2 = React.lazy(\r\n () => import(\"src/core/modules/v1page/MyControl/Types/select2\")\r\n)\r\n/** */\r\nconst List = {\r\n input_currency: MCInputCurrency,\r\n input_percentage: MCInputPercentage,\r\n input_text: MCInputText,\r\n input_number: MCInputNumber,\r\n group_controls: MCGroupControls,\r\n input_date: MCInputDate,\r\n input_date_string: MCInputDateString,\r\n input_address: MCInputAddress,\r\n checkbox_custom: MCInputCheckbox,\r\n readonly_text: MCReadonly,\r\n button: MCButton,\r\n check_inbox: MCCheckInbox,\r\n check_yes_no: MCCheckYesNo,\r\n check_option_radio: MCRadioOption,\r\n select2_icon_option: MCSelect2IconOption,\r\n link: MCLink,\r\n input_textarea: MC_input_textarea,\r\n readonly_html2: MC_readonly_html,\r\n input_textarea_autosize: MC_input_textarea_autosize,\r\n mc_files: MC_files,\r\n /**v1 page module*/\r\n v1_mfc_select2: v1_mfc_select2,\r\n /** */\r\n}\r\nconst MyControlSMSFOne = {\r\n init() {\r\n MyControlHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyControlSMSFOne\r\n","import React from \"react\"\r\nimport { MyFormControlHelpers, CSuppense } from \"@macashipo/mlib\"\r\n\r\nconst V1_mfc_mycontrol = React.lazy(\r\n () => import(\"src/core/modules/v1page/MyForm/Types/v1_mfc_mycontrol\")\r\n)\r\n\r\nconst ListControl = {\r\n input_currency: \"input_currency\",\r\n input_percentage: \"input_percentage\",\r\n input_text: \"input_text\",\r\n input_number: \"input_number\",\r\n group_controls: \"group_controls\",\r\n input_date: \"input_date\",\r\n input_date_string: \"input_date_string\",\r\n input_address: \"input_address\",\r\n checkbox_custom: \"checkbox_custom\",\r\n readonly_text: \"readonly_text\",\r\n button: \"button\",\r\n check_inbox: \"check_inbox\",\r\n check_yes_no: \"check_yes_no\",\r\n check_option_radio: \"check_option_radio\",\r\n v1_mfc_select2: \"v1_mfc_select2\",\r\n select2_icon_option: \"select2_icon_option\",\r\n link: \"link\",\r\n input_textarea: \"input_textarea\",\r\n readonly_html2: \"readonly_html2\",\r\n input_textarea_autosize: \"input_textarea_autosize\",\r\n mc_files: \"mc_files\",\r\n}\r\nconst MyFormControlSMSFOne = {\r\n init() {\r\n for (let k of Object.keys(ListControl)) {\r\n MyFormControlHelpers.addTypes(k, props => {\r\n return CSuppense({ ...props, typeControl: k }, V1_mfc_mycontrol)\r\n })\r\n }\r\n },\r\n}\r\n\r\nexport default MyFormControlSMSFOne\r\n","import React from \"react\"\r\nimport MyFormControlHelpers from \"src/core/components/MyForm/MyFormControlHelpers\"\r\nconst MFCOnlyLabel = React.lazy(() => import(\"./Types/only_label\"))\r\nconst V1PageMFCGroupRow = React.lazy(\r\n () => import(\"src/core/modules/v1page/MyForm/Types/v1_mfc_group_row\")\r\n)\r\nconst MFCArrayForm = React.lazy(() => import(\"./Types/array_form\"))\r\nconst List = {\r\n only_label: MFCOnlyLabel,\r\n v1_mfc_group_row: V1PageMFCGroupRow,\r\n array_form: MFCArrayForm,\r\n}\r\nconst MyControlForm = {\r\n init() {\r\n MyFormControlHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyControlForm\r\n","import { MyLibHelpers } from \"@macashipo/mlib\"\r\nimport React from \"react\"\r\n\r\nconst MyLib_react_google_places_autocomplete = React.lazy(() =>\r\n import(\"./Types/react_google_places_autocomplete\")\r\n)\r\nconst MyLib_react_google_places_autocomplete_custom = React.lazy(() =>\r\n import(\"./Types/react_google_places_autocomplete_custom\")\r\n)\r\nconst List = {\r\n react_google_places_autocomplete: MyLib_react_google_places_autocomplete,\r\n react_google_places_autocomplete_custom: MyLib_react_google_places_autocomplete_custom\r\n}\r\nconst MyLibOne = {\r\n init() {\r\n MyLibHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyLibOne\r\n","import { HModules, HCF, HLink, HUtils, CSuppense } from \"@macashipo/mlib\"\r\nimport {\r\n MyUIOne,\r\n MyPageOne,\r\n MyControlOne,\r\n MyFormControlOne,\r\n // MyCardOne,\r\n // MyTableCellOne,\r\n MyControlForm,\r\n MyLibOne\r\n} from \"./components\"\r\nimport \"./assets/theme-vfc.scss\"\r\nconst ModuleAppCRMHF = {\r\n _key: \"appvfc\",\r\n _fnList: {},\r\n _config: {},\r\n getMyKey: () => {\r\n return \"appvfc\"\r\n },\r\n runAfterInit: HConfig => {\r\n window.document.body.classList.add(\"theme-vfc\")\r\n HModules.initDefault(ModuleAppCRMHF, {\r\n MyLibOne,\r\n MyUIOne,\r\n MyPageOne,\r\n MyControlOne,\r\n MyFormControlOne,\r\n // MyCardOne,\r\n // MyTableCellOne,\r\n MyControlForm,\r\n })\r\n const userAgent =\r\n window?.navigator?.userAgent && window.navigator.userAgent.toLowerCase()\r\n if (userAgent && userAgent.indexOf(\"iphone\") > -1) {\r\n window.document.body.classList.add(\"on-ios\")\r\n }\r\n CSuppense.LazyLoading = () => {\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n },\r\n}\r\n\r\nexport default ModuleAppCRMHF\r\n","import * as types from \"./App.constants\"\r\nimport { FETCH_LOGIN_SUCCESS } from \"src/pages/Login/Login.constants\"\r\nimport produce from \"immer\"\r\nimport {\r\n authLogout,\r\n authLoginWithRes,\r\n authCheckSavedAuthorized,\r\n} from \"../core/helpers/auth\"\r\nconst initialState: any = {\r\n isAuthenticated: authCheckSavedAuthorized(),\r\n closeSideNav: true,\r\n sideNavItems: [],\r\n headerTitle: \"\",\r\n dataFirstSetting: {},\r\n}\r\n\r\nif (window.document.body.clientWidth <= 1024) {\r\n initialState.closeSideNav = true\r\n}\r\n\r\nexport const AppReducer = (state = initialState, action) =>\r\n produce(state, draft => {\r\n // console.warn(\"AppReducer\", state, draft, action)\r\n switch (action.type) {\r\n case types.LOGOUT:\r\n authLogout()\r\n draft.isAuthenticated = false\r\n break\r\n case FETCH_LOGIN_SUCCESS:\r\n draft.isAuthenticated = authLoginWithRes(action.res)\r\n break\r\n case types.SIDE_NAV_CLOSE:\r\n draft.closeSideNav = !state.closeSideNav\r\n break\r\n case types.SIDE_NAV_UPDATE:\r\n draft.sideNavItems = [...draft.sideNavItems, ...action.items]\r\n break\r\n case types.HEADER_TITLE_UPDATE:\r\n draft.headerTitle = action.title\r\n break\r\n case types.FETCH_FS_ERROR:\r\n break\r\n case types.FETCH_FS_PENDING:\r\n break\r\n case types.FETCH_FS_SUCCESS:\r\n draft.dataFirstSetting = action.data\r\n break\r\n default:\r\n return state\r\n }\r\n })\r\n","import * as types from \"./Login.constants\"\r\nimport produce from \"immer\"\r\n\r\nconst initialState = {\r\n loading: false,\r\n countRefresh: 1,\r\n}\r\n\r\nexport const loginReducer = (state = initialState, action) =>\r\n produce(state, draft => {\r\n // console.warn(\"loginReducer\", state, draft, action)\r\n switch (action.type) {\r\n case types.FETCH_LOGIN_PENDING:\r\n draft.loading = true\r\n break\r\n case types.FETCH_LOGIN_SUCCESS:\r\n draft.loading = false\r\n draft.countRefresh = draft.countRefresh + 1\r\n break\r\n case types.FETCH_LOGIN_ERROR:\r\n draft.loading = false\r\n break\r\n default:\r\n return state\r\n }\r\n })\r\n","import * as types from \"./sidemenu.constants\"\r\nimport produce from \"immer\"\r\n\r\nconst initialState = {\r\n textSearch: \"\",\r\n modeSearch: false,\r\n}\r\n\r\nexport const SideMenuReducer = (state = initialState, action) =>\r\n produce(state, draft => {\r\n switch (action.type) {\r\n case types.SIDEMENU_UPDATE_MODE_SEARCH:\r\n draft.modeSearch = action.mode\r\n break\r\n case types.SIDEMENU_UPDATE_TEXT_SEARCH:\r\n draft.textSearch = action.textSearch\r\n break\r\n default:\r\n return state\r\n }\r\n })\r\n","import { combineReducers } from \"redux\"\r\nimport { AppReducer } from \"src/App/App.reducer\"\r\nimport { loginReducer } from \"src/pages/Login/Login.reducer\"\r\nimport { SideMenuReducer } from \"./sidemenu/sidemenu.reducer\"\r\nimport ThemeOptions from \"./ThemeOptions\"\r\nconst initialReducer = {\r\n app: AppReducer,\r\n login: loginReducer,\r\n sidemenu: SideMenuReducer,\r\n ThemeOptions,\r\n}\r\nconst rootReducer = combineReducers(initialReducer)\r\nexport { initialReducer }\r\nexport default rootReducer\r\n","export class ReducerRegistry {\r\n constructor() {\r\n this._emitChange = null\r\n this._reducers = {}\r\n }\r\n\r\n initReducer(initialReducer) {\r\n this._reducers = {\r\n ...initialReducer,\r\n }\r\n }\r\n\r\n getReducers() {\r\n return { ...this._reducers }\r\n }\r\n\r\n register(name, reducer) {\r\n this._reducers = { ...this._reducers, [name]: reducer }\r\n if (this._emitChange) {\r\n this._emitChange(this.getReducers())\r\n }\r\n }\r\n\r\n setChangeListener(listener) {\r\n this._emitChange = listener\r\n }\r\n}\r\n\r\nconst reducerRegistry = new ReducerRegistry()\r\nexport default reducerRegistry\r\n","import { createStore, applyMiddleware, compose, combineReducers } from \"redux\"\r\nimport thunk from \"redux-thunk\"\r\nimport rootReducer from \"src/reducer/reducer\"\r\nimport { initialReducer } from \"src/reducer/reducer\"\r\nimport reducerRegistry from \"../reducer/reducerRegistry\"\r\nconst composeEnhancers =\r\n typeof window === \"object\" &&\r\n process.env.NODE_ENV === \"development\" &&\r\n (window as any).__REDUX_DEVTOOLS_EXTENSION_COMPOSE__\r\n ? (window as any).__REDUX_DEVTOOLS_EXTENSION_COMPOSE__({})\r\n : compose\r\nconst enhancer = composeEnhancers(applyMiddleware(thunk))\r\n// export const store = createStore(rootReducer, enhancer)\r\n\r\nconst combine = (reducers, initialState = {}) => {\r\n Object.keys(initialState).forEach(item => {\r\n reducers[item] = (state = initialState[item]) => state\r\n })\r\n return combineReducers(reducers)\r\n}\r\nreducerRegistry.initReducer(initialReducer)\r\nreducerRegistry.setChangeListener(reducers => {\r\n console.log(\"reducerRegistry setChangeListener\", reducers)\r\n // @ts-ignore\r\n store.replaceReducer(combine(reducers))\r\n})\r\n\r\n// const reducer = combine(reducerRegistry.getReducers())\r\n// export const store = createStore(reducer, enhancer)\r\n\r\nexport const store = createStore(\r\n combineReducers(reducerRegistry.getReducers()),\r\n enhancer\r\n)\r\n","import React from \"react\"\r\nimport { MyPageHelpers } from \"@macashipo/mlib\"\r\n\r\nconst MP_Css_2React_Style = React.lazy(() => import(\"./Types/css_2react_style\"))\r\nconst MP_API_Document = React.lazy(() => import(\"./Types/api_document\"))\r\nconst MP_Demo_ButtonList = React.lazy(() =>\r\n import(\"./Types/demo_buttonlist/index\")\r\n)\r\nconst MP_Demo_FormControl = React.lazy(() =>\r\n import(\"./Types/demo_formcontrol/index\")\r\n)\r\nconst MP_Demo_Form = React.lazy(() => import(\"./Types/demo_form/index\"))\r\nconst MP_Demo_TableCell = React.lazy(() =>\r\n import(\"./Types/demo_tablecell/index\")\r\n)\r\nconst MP_Demo_TableTotal = React.lazy(() =>\r\n import(\"./Types/demo_tablecell/_tableTotal\")\r\n)\r\nconst MP_Demo_TableFilter = React.lazy(() =>\r\n import(\"./Types/demo_tablefilter/index\")\r\n)\r\nconst MP_Demo_MyUI = React.lazy(() => import(\"./Types/demo_myui/index\"))\r\nconst MP_Demo_Libs = React.lazy(() => import(\"./Types/demo_libs/index\"))\r\nconst MP_Demo_Dashboard_one = React.lazy(() =>\r\n import(\"./Types/demo_dashboard_one/index\")\r\n)\r\nconst MP_Demo_ChartJS = React.lazy(() =>\r\n import(\"./Types/demo_chart/dc_chartjs\")\r\n)\r\nconst MP_Demo_GGChart = React.lazy(() =>\r\n import(\"./Types/demo_chart/dc_ggchart\")\r\n)\r\nconst MP_Test_InputRange = React.lazy(() => import(\"./Types/test/input_range\"))\r\nconst MP_Test_Camera = React.lazy(() => import(\"./Types/test/camera\"))\r\nconst MP_Demo_Table = React.lazy(() => import(\"./Types/demo_table/index\"))\r\nconst MP_Demo_Table_Span = React.lazy(() =>\r\n import(\"./Types/demo_table/dt_span\")\r\n)\r\nconst MPD_dt_multi_table = React.lazy(() =>\r\n import(\"./Types/demo_table/dt_multi_table\")\r\n)\r\nconst MPD_dt_table_footer = React.lazy(() =>\r\n import(\"./Types/demo_table/dt_table_footer\")\r\n)\r\nconst MPD_demo_docs = React.lazy(() => import(\"./Types/docs\"))\r\n\r\nconst List = {\r\n demo_docs: MPD_demo_docs,\r\n demo_table_footer: MPD_dt_table_footer,\r\n demo_multi_table: MPD_dt_multi_table,\r\n test_input_range: MP_Test_InputRange,\r\n test_camera: MP_Test_Camera,\r\n css_2react_style: MP_Css_2React_Style,\r\n api_document: MP_API_Document,\r\n demo_buttonlist: MP_Demo_ButtonList,\r\n demo_formcontrol: MP_Demo_FormControl,\r\n demo_form: MP_Demo_Form,\r\n demo_table: MP_Demo_Table,\r\n demo_table_span: MP_Demo_Table_Span,\r\n demo_tablecell: MP_Demo_TableCell,\r\n demo_tabletotal: MP_Demo_TableTotal,\r\n demo_tablefilter: MP_Demo_TableFilter,\r\n demo_myui: MP_Demo_MyUI,\r\n demo_libs: MP_Demo_Libs,\r\n demo_dashboard_one: MP_Demo_Dashboard_one,\r\n demo_chartjs: MP_Demo_ChartJS,\r\n demo_ggchart: MP_Demo_GGChart,\r\n}\r\nconst MyPageOne = {\r\n init() {\r\n MyPageHelpers.addTypesFromListLazy(List)\r\n },\r\n}\r\n\r\nexport default MyPageOne\r\n","import { HModules, CSuppense, HUtils } from \"@macashipo/mlib\"\r\nimport MyPageOne from \"./MyPage\"\r\nconst ModuleAppDemo = {\r\n _key: \"appdemo\",\r\n _fnList: {},\r\n _config: {},\r\n getMyKey: () => {\r\n return \"appdemo\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleAppDemo, {\r\n MyPageOne,\r\n })\r\n CSuppense.LazyLoading = () => {\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n HUtils.runFuntion(HConfig, \"addPublicRoutes\", [\r\n [\r\n {\r\n Id: \"test_input_range\",\r\n UIUrl: \"/test/test_input_range\",\r\n UIType: \"test_input_range\",\r\n },\r\n {\r\n Id: \"test_camera\",\r\n UIUrl: \"/test/test_camera\",\r\n UIType: \"test_camera\",\r\n },\r\n ],\r\n ])\r\n HUtils.runFuntion(HConfig, \"addPrivateRoutes\", [\r\n [\r\n {\r\n Id: \"css_2react_style\",\r\n UIUrl: \"/2react-style\",\r\n UIType: \"css_2react_style\",\r\n },\r\n {\r\n Id: \"api_document\",\r\n UIUrl: \"/demo/api_document\",\r\n UIType: \"api_document\",\r\n },\r\n {\r\n Id: \"demo_buttonlist\",\r\n UIUrl: \"/demo/buttonlist\",\r\n UIType: \"demo_buttonlist\",\r\n },\r\n {\r\n Id: \"demo_formcontrol\",\r\n UIUrl: \"/demo/formcontrol\",\r\n UIType: \"demo_formcontrol\",\r\n },\r\n {\r\n Id: \"demo_form\",\r\n UIUrl: \"/demo/form\",\r\n UIType: \"demo_form\",\r\n },\r\n {\r\n Id: \"demo_tablecell\",\r\n UIUrl: \"/demo/tablecell\",\r\n UIType: \"demo_tablecell\",\r\n },\r\n {\r\n Id: \"demo_tabletotal\",\r\n UIUrl: \"/demo/tabletotal\",\r\n UIType: \"demo_tabletotal\",\r\n },\r\n {\r\n Id: \"demo_tablefilter\",\r\n UIUrl: \"/demo/tablefilter\",\r\n UIType: \"demo_tablefilter\",\r\n },\r\n {\r\n Id: \"demo_myui\",\r\n UIUrl: \"/demo/myui\",\r\n UIType: \"demo_myui\",\r\n },\r\n {\r\n Id: \"demo_libs\",\r\n UIUrl: \"/demo/libs\",\r\n UIType: \"demo_libs\",\r\n },\r\n {\r\n Id: \"demo_dashboard_one\",\r\n UIUrl: \"/demo/demo_dashboard_one\",\r\n UIType: \"demo_dashboard_one\",\r\n },\r\n {\r\n Id: \"demo_chart_chartjs\",\r\n UIUrl: \"/demo/demo_chartjs\",\r\n UIType: \"demo_chartjs\",\r\n },\r\n {\r\n Id: \"demo_chart_ggchart\",\r\n UIUrl: \"/demo/demo_ggchart\",\r\n UIType: \"demo_ggchart\",\r\n },\r\n {\r\n Id: \"demo_table\",\r\n UIUrl: \"/demo/table\",\r\n UIType: \"demo_table\",\r\n },\r\n {\r\n Id: \"demo_table\",\r\n UIUrl: \"/adoc/:name\",\r\n UIType: \"demo_docs\",\r\n },\r\n {\r\n Id: \"demo_survey\",\r\n UIUrl: \"/demo/survey\",\r\n UIType: \"survey\",\r\n },\r\n ],\r\n ])\r\n },\r\n}\r\n\r\nexport default ModuleAppDemo\r\n","import { HCF } from \"@macashipo/mlib\"\r\n\r\nexport const sendWebhook = ({ webhookURL, msg } = {}) => {\r\n if (webhookURL && msg) {\r\n const data = JSON.stringify({\r\n text: msg,\r\n })\r\n let resp\r\n fetch(webhookURL, {\r\n method: \"POST\",\r\n headers: {\r\n \"Content-Type\": \"application/json; charset=UTF-8\",\r\n },\r\n body: data,\r\n }).then(response => {\r\n resp = response\r\n console.log(response)\r\n })\r\n return resp\r\n }\r\n}\r\n\r\nexport const sendGGNotifyLog = ({ webhookURL, msg, force } = {}) => {\r\n let _webHook = webhookURL || HCF.getCF(\"GGNotifyWebHook\")\r\n if (force !== true && window.location.href.indexOf(\"localhost\") > -1) {\r\n return null\r\n }\r\n if (_webHook) {\r\n let _msg = `From: ${window.location.href}\\n` + \"```\" + msg + \"```\"\r\n sendWebhook({\r\n webhookURL: _webHook,\r\n msg: _msg,\r\n })\r\n }\r\n}\r\n","import { HLog } from \"src/core/helpers\"\r\n// import ModuleV1Page from \"src/core/modules/v1page\"\r\n// import ModuleDev from \"src/core/modules/dev\"\r\nimport ModuleFirstSetting from \"src/core/modules/firstsetting\"\r\nimport ModuleIconHiOutline from \"src/core/modules/iconHiOutline\"\r\nimport ModuleSetting from \"src/core/modules/setting\"\r\nimport ModuleSetting2FA from \"src/core/modules/setting2fa\"\r\nimport ModuleRedirectToken from \"src/core/modules/redirectToken\"\r\nimport ModuleDevSimulator from \"src/core/modules/dev_simulator\"\r\nimport ModuleDev from \"src/core/modules/dev\"\r\nimport ModuleCore from \"src/core/modules/core\"\r\nimport ModuleReactGA from \"src/modules/reactga\"\r\nimport ModuleAdminPanel from \"src/modules/adminpanel\"\r\nimport ModuleChromeNotification from \"src/modules/chrome_notification\"\r\nimport ModuleSignalR from \"src/modules/signalR\"\r\nimport ModuleCheckIDLE from \"src/modules/check_idle\"\r\n// import ModuleV1Page from \"src/core/modules/v1page\"\r\nimport ModuleQLProject from \"src/modules/qlproject\"\r\nimport ModuleAppVFC from \"src/modules/app_vfc\"\r\nimport { HLink, HLocalStorage } from \"@macashipo/mlib\"\r\nimport Lang_en from \"../assets/i18n/en.json\"\r\nimport Lang_vn from \"../assets/i18n/vn.json\"\r\n\r\nimport { store } from \"src/store/store\"\r\nimport { logout, updateHeaderTitle } from \"src/App/App.actions\"\r\nimport { fnListConfigApp } from \"src/helpers/fnList\"\r\nimport \"src/assets/scss/theme-layout.css\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nimport ModuleAppDemo from \"src/modules/app_demo/indes\"\r\nimport { sendGGNotifyLog } from \"src/services/apiWebhookGGChat\"\r\n\r\n// eslint-disable-next-line\r\nconst ModulesExternal = process.env[\"REACT_APP_MODULES\"]\r\n\r\nconst DFLanguage = process.env[\"REACT_APP_MODULES\"] || \"vn\"\r\nconst AppConfig: IConfigApp = {\r\n appInfo: {\r\n title: \"Admin\",\r\n appName: \"adminv5\",\r\n home: \"/\",\r\n GAId: \"UA-119777650-2\",\r\n GooglePlaceApiKey: \"AIzaSyBzpjMv2KczEub9Od-uYrB6Skvqslkf3Fg\",\r\n // GooglePlaceApiKey: \"AIzaSyBCngEVc4wGqeENChmkZMXL0I3LWZGhSPY\", //prj AllianceITSC\r\n footer:\r\n 'AllianceITSC© 2022 ',\r\n autoRedirectLoginPageNotFound: true,\r\n verAdmin: \"v5\",\r\n defaultTagInputCell: \"textarea\",\r\n // serviceWorkersRun: [\"/sw-notify.js\"],\r\n // hasSignalR: true,\r\n // signalRHub: \"/NotificationHub\",\r\n // signalRKey: \"jkfghweUIT0923klhgfvas65t823fajkwq\",\r\n hasPushNotify: false,\r\n hasLoginSocialGoogle: false,\r\n hasForgotPassword: true,\r\n hasRegisterAccount: false,\r\n charSplitArray: \",\",\r\n showClearLocalCache: true,\r\n //// --- check idle\r\n // hasCheckIdle: true,\r\n // checkIdleSecond: 30,\r\n //// --- end check idle\r\n numberLocale: \"it-IT\", //en-US:,. it-IT,vi-VI:.,\r\n Goong_APIKEY: \"0KsekHsHczoT6HZWBVsYK86yZBmtbQmpGjkeq4i8\", //show map vfc\r\n autoRedirectHomePage: true,\r\n GGNotifyWebHook:\r\n \"https://chat.googleapis.com/v1/spaces/AAAAvEKTVmk/messages?key=AIzaSyDdI0hCZtE6vySjMm-WEfRq3CPzqKqqsHI&token=_7Sucf66JSiofT_paDvLUQr3NHZNrEVuXjwDPcSQD2k\",\r\n GoogleClientId:\r\n \"261599714010-770nfjc7ot1s4jh799tone21mmj34cjv.apps.googleusercontent.com\",\r\n },\r\n configApi: {\r\n baseUrl: \"https://vfc1apicore.ajumagarden.com\",\r\n fnLogout: () => {\r\n // console.warn(\"logout\")\r\n store.dispatch(logout())\r\n },\r\n },\r\n configI18n: {\r\n lng: DFLanguage,\r\n defaultNS: \"common\",\r\n resources: {\r\n en: {\r\n common: Lang_en,\r\n },\r\n vn: {\r\n common: Lang_vn,\r\n },\r\n vi: {\r\n common: Lang_vn,\r\n },\r\n },\r\n },\r\n configAuth: {\r\n afterLogin: () => {\r\n HLog.logW(\"afterLogin\")\r\n // HLink.push(fnListConfigApp.getHomeUrl()) //dang bi loi, chua biet vi sao -> chuyen vao page login xu ly\r\n },\r\n afterLogout: () => {\r\n HLocalStorage.removeItem(\"FirstLoad\")\r\n HLocalStorage.removeItem(\"SideMenu\")\r\n console.warn(\"afterLogout\")\r\n // window.location.href = \"/\"\r\n // window.open(\"/\", \"_self\")\r\n // window.location.reload()\r\n setTimeout(() => {\r\n HLink.push(\"/\")\r\n }, 500) //ko the chay truc tiep, bi loi redux\r\n },\r\n },\r\n fnList: {\r\n dispatchFromStore(action) {\r\n store.dispatch(action)\r\n },\r\n updateHeaderTitle: title => {\r\n store.dispatch(updateHeaderTitle(title))\r\n },\r\n onAfterInit: function (HConfig) {\r\n HLog.logW(\"After init\", HConfig)\r\n window.sendGGNotifyLog = sendGGNotifyLog\r\n },\r\n fnGetRequestUIAppConfigFirstSetting: () => {\r\n let _keys = [KConfigApp.expandIconHideColor, KConfigApp.defaultLanguage]\r\n let _obj = {}\r\n for (let k of _keys) {\r\n if (AppConfig.UIAppConfig[k] != null) {\r\n _obj[k] = AppConfig.UIAppConfig[k]\r\n }\r\n }\r\n return _obj\r\n },\r\n },\r\n modules: [\r\n ModuleCore,\r\n ModuleDev,\r\n ModuleDevSimulator,\r\n ModuleFirstSetting,\r\n // ModuleCategoryScreen,\r\n // ModuleV1Page,\r\n ModuleIconHiOutline,\r\n ModuleSetting,\r\n ModuleSetting2FA,\r\n ModuleRedirectToken,\r\n ModuleReactGA,\r\n ModuleAdminPanel,\r\n ModuleChromeNotification,\r\n ModuleSignalR,\r\n ModuleAppDemo,\r\n ModuleCheckIDLE,\r\n ModuleQLProject,\r\n ModuleAppVFC,\r\n ],\r\n UIAppConfig: {\r\n numeralFormat: \"0,0.[0]\",\r\n numeralFormatMoney: \"0,0.[00]\",\r\n isCheckInvalidProjectId: true,\r\n ignoreNoProjectId: false,\r\n timeFormat: \"HH:mm\",\r\n dateFormat: \"DD-MMMYY\", //MomentJS\r\n datetimeFormat: \"DD-MMMYY HH:mm\", //MomentJS\r\n dateFPFormat: \"d/m/Y\",\r\n datetimeFPFormat: \"d/m/Y H:i\",\r\n widthMobile: 1000,\r\n symbolDecimal: \",\",\r\n symbolThousand: \".\",\r\n expandIconHideColor: \"\",\r\n expandBgColor: \"#e4e5e6\", //#93d4e3\r\n styleDefaultCell: { padding: \"2px\" },\r\n defaultLanguage: DFLanguage,\r\n hideEffectAddNew: false,\r\n hideEffectDelete: false,\r\n hasSettingPage: false,\r\n hasChangeLanguage: false,\r\n listLng: [\r\n {\r\n code: \"en\",\r\n name: \"English\",\r\n },\r\n {\r\n code: \"vn\",\r\n name: \"Tiếng Việt\",\r\n },\r\n ],\r\n },\r\n}\r\n\r\nexport default AppConfig\r\n","import classnames from \"classnames\"\r\nimport React from \"react\"\r\nimport MyModal from \"src/core/components/MyModal/MyModal\"\r\nimport MyLightbox from \"src/core/components/MyModal/MyLightbox\"\r\nimport Dropzone from \"react-dropzone\"\r\nimport HUpload from \"src/helpers/Upload\"\r\nclass WrapDropzone extends React.Component {\r\n state = {\r\n accept: \"\",\r\n }\r\n componentDidMount() {\r\n HUpload.fnUpdateAccept = (accept, cb) => {\r\n this.setState({ accept }, () => {\r\n if (cb) {\r\n cb()\r\n }\r\n })\r\n }\r\n }\r\n render() {\r\n // console.warn(\"render:\", this.state.accept)\r\n return (\r\n \r\n {\r\n if (HUpload.onDrop) {\r\n HUpload.onDrop(acceptedFiles, fileRejections)\r\n }\r\n }}\r\n ref={r => {\r\n console.warn(\"refDropzone:\", r)\r\n HUpload.globalDropzone = r\r\n }}\r\n >\r\n {({ getRootProps, getInputProps }) => (\r\n
\r\n
\r\n \r\n
\r\n
\r\n )}\r\n \r\n
\r\n )\r\n }\r\n}\r\nclass MyModalWrap extends React.Component {\r\n render() {\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n )\r\n }\r\n}\r\n\r\nexport default MyModalWrap\r\n","import { HModules, HCF, HLink, HUtils } from \"@macashipo/mlib\"\r\nimport { GTMProvider } from \"@elgorditosalsero/react-gtm-hook\"\r\nimport React from \"react\"\r\nimport { fnListConfigApp } from \"src/helpers/fnList\"\r\n\r\nconst ModuleGTag = {\r\n _key: \"gtag\",\r\n _fnList: {},\r\n _config: {\r\n GTMKey: \"GTMKeyPageGlobal\",\r\n GTMIdDev: \"GTM-W3HNM37\",\r\n },\r\n getMyKey: () => {\r\n return \"gtag\"\r\n },\r\n runAfterInit: HConfig => {\r\n HModules.initDefault(ModuleGTag, {})\r\n console.warn(\"init module gtag\")\r\n },\r\n}\r\n\r\nexport default ModuleGTag\r\n\r\nconst ProviderGTAG = props => {\r\n let _gtagID = HCF.getCF(ModuleGTag._config.GTMKey)\r\n if (_gtagID == null && fnListConfigApp.getIsDevMode()) {\r\n _gtagID = ModuleGTag._config.GTMIdDev\r\n }\r\n console.warn(\"render providergtag\", _gtagID, props)\r\n if (_gtagID) {\r\n return {props.children}\r\n }\r\n return {props.children}\r\n}\r\nexport { ProviderGTAG }\r\n","import React from \"react\"\r\nimport ReactDOM from \"react-dom\"\r\nimport { Provider } from \"react-redux\"\r\nimport { I18nextProvider } from \"react-i18next\"\r\nimport i18next from \"i18next\"\r\nimport { ToastContainer } from \"react-toastify\"\r\nimport \"src/assets/scss/index.scss\"\r\nimport App from \"./App/App\"\r\nimport AppConfig from \"./App/AppConfig\"\r\n// eslint-disable-next-line\r\nimport * as HCore from \"./core/helpers/index\"\r\nimport * as serviceWorker from \"./serviceWorker\"\r\nimport { store } from \"./store/store\"\r\nimport MyModal from \"src/core/components/MyModal/MyModal\"\r\nimport MyLightbox from \"src/core/components/MyModal/MyLightbox\"\r\nimport MyModalWrap from \"src/core/components/MyModal/MyModalWrap\"\r\nimport \"react-toastify/dist/ReactToastify.css\"\r\nimport \"font-awesome/css/font-awesome.min.css\"\r\nimport * as MLib from \"@macashipo/mlib\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nimport { ProviderGTAG } from \"src/modules/gtag\"\r\n\r\n//Assign MLib\r\nwindow[\"MLib\"] = MLib\r\n\r\n/** Init Config App */\r\nHCore.HConfig.initConfigApp(AppConfig)\r\n\r\n//Stop show overlay error when error in mode development\r\n// if (process.env.NODE_ENV === \"development\") {\r\n// import(\"react-error-overlay\").then(m => {\r\n// m.stopReportingRuntimeErrors()\r\n// })\r\n// }\r\n\r\nif (window[\"_MissingConfig\"] === true) {\r\n ReactDOM.render(\r\n // \r\n
,\r\n //
\r\n document.getElementById(\"root\")\r\n )\r\n} else {\r\n ReactDOM.render(\r\n // \r\n \r\n \r\n \r\n \r\n {/* \r\n \r\n \r\n \r\n \r\n \r\n */}\r\n \r\n \r\n {MLib.HCF.getCF(KConfigApp.hasSignalR) === true && (\r\n \r\n )}\r\n \r\n \r\n ,\r\n // \r\n document.getElementById(\"root\")\r\n )\r\n}\r\n\r\n//an vung first loading sau khi render reactjs\r\nvar dom_firstLoading = document.getElementById(\"first_loading\")\r\nif (dom_firstLoading) {\r\n dom_firstLoading.style.visibility = \"hidden\"\r\n}\r\n\r\n//test\r\n// console.warn(\r\n// \"MLib.HCF.getCF(KConfigApp.hasSignalR)\",\r\n// MLib.HCF.getCF(KConfigApp.hasSignalR)\r\n// )\r\n\r\n// If you want your app to work offline and load faster, you can change\r\n// unregister() to register() below. Note this comes with some pitfalls.\r\n// Learn more about service workers: https://bit.ly/CRA-PWA\r\n// serviceWorker.unregister()\r\n","import { apiGeneric } from \"src/core/helpers/api\"\r\n\r\nwindow[\"_apiGeneric\"] = apiGeneric\r\nexport default apiGeneric\r\n","const HelperMore = {\r\n getSourceData: (props = {}) => {\r\n const options =\r\n (props.fnList &&\r\n props.fnList.getSourceData &&\r\n props.fnList.getSourceData({ withEmpty: false })) ||\r\n []\r\n return options\r\n },\r\n getMoreFromProps: (props = {}) => {\r\n if (props.fnList && props.fnList.getMore) {\r\n return props.fnList.getMore() || {}\r\n }\r\n return {}\r\n },\r\n getClassCol: (more = {}) => {\r\n if (more.classCol) {\r\n return more.classCol\r\n }\r\n return \"\"\r\n },\r\n getIsCheckListYesNo: (more = {}) => {\r\n // console.warn(\"getIsCheckListYesNo:\",more)\r\n if (more.isCheckListYesNo === true) {\r\n return true\r\n }\r\n return false\r\n },\r\n getIsSelectCheck: (more = {}) => {\r\n if (more.isSelectCheck === true) {\r\n return true\r\n }\r\n return false\r\n },\r\n getIsNumeral: (more = {}) => {\r\n if (more.isNumeral === true) {\r\n return true\r\n }\r\n return false\r\n },\r\n getInputType: (more = {}, defaultType = \"text\") => {\r\n if (more.inputType) {\r\n return more.inputType\r\n }\r\n return defaultType\r\n },\r\n getSuffix: (more = {}) => {\r\n if (more && more.suffix) {\r\n return more.suffix\r\n }\r\n return null\r\n },\r\n getPrefix: (more = {}) => {\r\n if (more && more.prefix) {\r\n return more.prefix\r\n }\r\n return null\r\n },\r\n getNoDecimal: (more = {}) => {\r\n if (more && more.noDecimal === true) {\r\n return true\r\n }\r\n return false\r\n },\r\n getOptionNegative: (more = {}, opts = {}) => {\r\n let _obj = opts.default || {\r\n Text: \"NO\",\r\n Value: false,\r\n }\r\n if (more.hasOwnProperty(\"negativeValue\")) {\r\n _obj.Value = more.negativeValue\r\n }\r\n if (more.hasOwnProperty(\"negativeText\")) {\r\n _obj.Text = more.negativeText\r\n }\r\n return _obj\r\n },\r\n getOptionPositive: (more = {}, opts = {}) => {\r\n let _obj = opts.default || {\r\n Text: \"YES\",\r\n Value: true,\r\n }\r\n if (more.hasOwnProperty(\"positiveValue\")) {\r\n _obj.Value = more.positiveValue\r\n }\r\n if (more.hasOwnProperty(\"positiveText\")) {\r\n _obj.Text = more.positiveText\r\n }\r\n return _obj\r\n },\r\n getOptionAll: (more = {}, opts = {}) => {\r\n let _obj = opts.default || {\r\n Text: \"All\",\r\n Value: null,\r\n }\r\n if (more.hasOwnProperty(\"allValue\")) {\r\n _obj.Value = more.allValue\r\n }\r\n if (more.hasOwnProperty(\"allText\")) {\r\n _obj.Text = more.allText\r\n }\r\n return _obj\r\n },\r\n getPropsValues: (\r\n props = {},\r\n {\r\n defaultValueWhenNull,\r\n keyValue = \"value\",\r\n keyDefaultValue = \"defaultValue\",\r\n } = {}\r\n ) => {\r\n let _propsValues = {}\r\n if (props.hasOwnProperty(\"value\")) {\r\n //control value from parent\r\n _propsValues[keyValue] = props.value\r\n if (_propsValues[keyValue] === null && defaultValueWhenNull != null) {\r\n _propsValues[keyValue] = defaultValueWhenNull\r\n }\r\n }\r\n if (props.hasOwnProperty(\"defaultValue\")) {\r\n //without control value\r\n _propsValues[keyDefaultValue] = props.defaultValue\r\n }\r\n return _propsValues\r\n },\r\n}\r\n\r\nexport default HelperMore\r\n","import i18next from \"i18next\"\r\nimport axios from \"axios\"\r\nimport { HCF, HLocalStorage } from \"@macashipo/mlib\"\r\nimport { apiGeneric } from \"./api\"\r\nimport { KConfigApp } from \"src/helpers/K\"\r\nimport { FlowForceUpdateRoutes } from \"src/helpers/Flows/Routes\"\r\nimport { HUtils } from \".\"\r\nconst KLocalLanguage = \"Language\"\r\nconst HI18: any = {\r\n currentLng: \"\",\r\n currentLngLocalStorage: localStorage.getItem(KLocalLanguage),\r\n defaultLng: \"en\",\r\n listLng: null,\r\n getCurrentLng: () => {\r\n return HI18.currentLng\r\n },\r\n listPathLoadedExtLng: [],\r\n getCurrentLngFlagUrl: code => {\r\n let _code = code || HI18.getCurrentLng()\r\n if (_code == \"en\") {\r\n _code = \"gb\"\r\n }\r\n if (HI18.hasLngInList(code)) {\r\n return `/css/flags/1x1/${_code}.svg`\r\n }\r\n return `/css/imgs/globe.png`\r\n },\r\n hasLngInList: lng => {\r\n if (lng && Array.isArray(HI18.listLng)) {\r\n for (let i = 0; i < HI18.listLng.length; i++) {\r\n if (HI18.listLng[i].Value == lng) {\r\n return true\r\n }\r\n }\r\n }\r\n console.log(\"hasLngInList\", HI18.listLng)\r\n return false\r\n },\r\n changeLanguage: (lng, saveLocal) => {\r\n // console.log(\"changeLanguage:\", lng, saveLocal)\r\n if (lng) {\r\n HI18.currentLng = lng\r\n if (saveLocal === true) {\r\n // console.log(\"changeLanguage saveLocal:\", lng)\r\n localStorage.setItem(KLocalLanguage, lng)\r\n HI18.currentLngLocalStorage = lng\r\n }\r\n i18next.changeLanguage(lng)\r\n }\r\n },\r\n changeLanguageOnUI: (\r\n lng,\r\n saveLocal,\r\n { needReload, needCallApi, cbLoading, cbSuccess, cbError }\r\n ) => {\r\n if (needCallApi) {\r\n cbLoading && cbLoading()\r\n apiGeneric({\r\n method: \"POST\",\r\n path: \"Account\",\r\n name: \"UpdateFields\",\r\n silent: true, //khong show msg\r\n data: {\r\n Values: [\r\n {\r\n FieldName: \"LanguageCode\",\r\n NewValue: lng,\r\n },\r\n ],\r\n },\r\n })\r\n .then(response => {\r\n HI18.changeLanguage(lng, saveLocal)\r\n //update local first setting\r\n HUtils.runFuntion(\r\n HCF.getCF(\"fnModuleFirstSetting\"),\r\n \"fnRemoveUserCodeInLocalFirstSetting\"\r\n )\r\n HLocalStorage.removeItem(\"CategoryScreen\")\r\n HLocalStorage.removeItem(\"SideMenu\")\r\n cbSuccess && cbSuccess(response)\r\n if (needReload) {\r\n window.location.reload()\r\n }\r\n })\r\n .catch(e => {\r\n cbError && cbError(e)\r\n })\r\n } else {\r\n if (needReload) {\r\n window.location.reload()\r\n }\r\n }\r\n },\r\n checkLanguageFromServer: (lng, opts: any = {}) => {\r\n // console.log(\r\n // \"checkLanguageFromServer:\",\r\n // `current: ${HI18.currentLng},`,\r\n // lng,\r\n // opts\r\n // )\r\n if (\r\n opts[\"fromDefaultLanguage\"] === true &&\r\n HI18.currentLng == HI18.defaultLng\r\n ) {\r\n //neu thay doi tu defaultLanguage thi neu hien tai la en thi moi doi, neu khac roi thi ko can doi default\r\n return\r\n }\r\n //nếu chưa có ngôn ngữ ở local mà truyền vào lng -> đổi qua lng\r\n if (HI18.currentLngLocalStorage == null && lng) {\r\n if (lng != HI18.currentLng) {\r\n HI18.changeLanguage(lng, false)\r\n }\r\n } else if (HI18.currentLngLocalStorage != HI18.currentLng) {\r\n //nếu có ở local và nó đang khác với current -> đổi qua lng local\r\n // console.log(\r\n // \"prepare changeLanguage:\",\r\n // `current: ${HI18.currentLng},`,\r\n // `local: ${HI18.currentLngLocalStorage},`,\r\n // lng,\r\n // opts\r\n // )\r\n HI18.changeLanguage(HI18.currentLngLocalStorage, false)\r\n }\r\n\r\n //nếu user lgn từ server khác hiện tại\r\n if (lng && opts.fromUserLanguageCode && HI18.currentLng != lng) {\r\n // console.log(\r\n // \"need reload\",\r\n // window.sendGGNotifyLog,\r\n // lng,\r\n // HI18.currentLng,\r\n // HI18.currentLng != lng,\r\n // HI18.currentLngLocalStorage,\r\n // opts.fromUserLanguageCode\r\n // )\r\n HI18.changeLanguage(lng, true)\r\n // fetch(\r\n // \"https://chat.googleapis.com/v1/spaces/AAAAuWV60uo/messages?key=AIzaSyDdI0hCZtE6vySjMm-WEfRq3CPzqKqqsHI&token=LiuSwZCwrNkyff5CnzR3rSiRVQXJG9WuerziVUl2Zvk\",\r\n // {\r\n // method: \"POST\",\r\n // headers: {\r\n // \"Content-Type\": \"application/json; charset=UTF-8\",\r\n // },\r\n // body: JSON.stringify({\r\n // text: \"reload\",\r\n // }),\r\n // }\r\n // )\r\n // window.location.reload()\r\n return\r\n }\r\n },\r\n}\r\nexport const initI18n = (config?: any) => {\r\n let _lngInLocalStorage = localStorage.getItem(KLocalLanguage)\r\n console.log(\"initI18n:\", _lngInLocalStorage)\r\n if (\r\n _lngInLocalStorage &&\r\n config &&\r\n config[\"resources\"] &&\r\n config[\"resources\"][`${_lngInLocalStorage}`]\r\n ) {\r\n config[\"lng\"] = _lngInLocalStorage\r\n }\r\n HI18.currentLng = config?.lng\r\n i18next.init(config)\r\n initLanguageList({ listExtLng: null })\r\n}\r\n\r\nexport const initLanguageList = ({ listExtLng }) => {\r\n HI18.listLng = HCF.getCF(KConfigApp.LanguageList)\r\n console.warn(\"LanguageList:\", HI18.listLng, listExtLng)\r\n if (listExtLng && listExtLng.length > 0) {\r\n for (let i = 0; i < listExtLng.length; i++) {\r\n loadExtLngFromFile(listExtLng[i])\r\n }\r\n }\r\n}\r\n\r\nexport const loadExtLng = (config: any = {}) => {\r\n const { lng, ns, resources } = config\r\n console.log(\"loadExtLng:\", config)\r\n i18next.addResourceBundle(lng || \"en\", ns || \"common\", resources || {})\r\n}\r\n\r\nconst getPathFromCodeInListLng = lng => {\r\n if (HI18.listLng && HI18.listLng.length > 0) {\r\n for (let k of HI18.listLng) {\r\n if (k && k.Value == lng) {\r\n return k.Path\r\n }\r\n }\r\n }\r\n}\r\nexport const loadExtLngFromFile = (config: any = {}) => {\r\n const { lng, ns, path, isDefault, v } = config\r\n console.log(\"loadExtLngFromFile:\", config)\r\n let _path = path || getPathFromCodeInListLng(lng)\r\n if (_path) {\r\n if (\r\n HI18.listPathLoadedExtLng &&\r\n HI18.listPathLoadedExtLng.indexOf(_path) > -1\r\n ) {\r\n //chỉ load ext lng 1 lần\r\n return\r\n }\r\n //add version for path\r\n HI18.listPathLoadedExtLng.push(_path)\r\n if (_path.indexOf(\"?\") == -1) {\r\n if (v) {\r\n _path += `?v=${v}`\r\n } else if (window._M && window._M.AppBuildVersion) {\r\n _path += `?v=${window._M.AppBuildVersion}`\r\n }\r\n }\r\n axios.get(_path).then(rs => {\r\n console.log(\"rs:\", rs)\r\n if (rs && rs.data) {\r\n i18next.addResourceBundle(lng || \"en\", ns || \"common\", rs.data)\r\n if (isDefault === true) {\r\n HI18.defaultLng = lng\r\n HI18.checkLanguageFromServer(lng)\r\n FlowForceUpdateRoutes()\r\n }\r\n }\r\n })\r\n }\r\n}\r\n\r\nexport default HI18\r\n","const HConstant = {\r\n Modules: {\r\n FnList: {\r\n runAfterInit: \"runAfterInit\",\r\n },\r\n },\r\n ConfigAppExt: {\r\n footer: \"footer\",\r\n dateFormat: \"dateFormat\",\r\n datetimeFormat: \"datetimeFormat\",\r\n urlForLogException: \"urlForLogException\",\r\n },\r\n ConfigApp: {\r\n FnList: {\r\n onAfterInit: \"onAfterInit\",\r\n },\r\n },\r\n Dev: {\r\n Key: {\r\n _DEBUG_: \"_DEBUG_\",\r\n },\r\n },\r\n Api: {\r\n Name: {\r\n List: \"List\",\r\n UpdateFields: \"UpdateFields\",\r\n },\r\n },\r\n HConfig: {\r\n FnList: {\r\n addPublicRoutes: \"addPublicRoutes\",\r\n addPrivateRoutes: \"addPrivateRoutes\",\r\n registerAfterLogin: \"registerAfterLogin\",\r\n registerExtSettingParts: \"registerExtSettingParts\",\r\n registerHeaderTitle: \"registerHeaderTitle\",\r\n dispatchFromStore: \"dispatchFromStore\",\r\n updateHeaderTitle: \"updateHeaderTitle\",\r\n },\r\n },\r\n MyTableCell: {\r\n FnList: {\r\n onUpdateValue: \"onUpdateValue\",\r\n },\r\n // UIRowField: {\r\n // _UI_JustUpdated: \"_UI_JustUpdated\",\r\n // },\r\n },\r\n MyFormControl: {\r\n FnList: {\r\n onUpdateValue: \"onUpdateValue\",\r\n },\r\n },\r\n Auth: {\r\n dispatchLoginSuccess: \"dispatchLoginSuccess\",\r\n },\r\n ExtModulesName: {\r\n sidenavitems: \"sidenavitems\",\r\n },\r\n ScreenConfig: {\r\n Header: {\r\n showProjectHeader: \"showProjectHeader\",\r\n showAddNew: \"showAddNew\",\r\n },\r\n Table: {\r\n isCheckInvalidProject: \"isCheckInvalidProject\",\r\n tableProps: \"tableProps\",\r\n \"tableProps.hover\": \"hover\",\r\n hasExpand: \"hasExpand\",\r\n showDetails: \"showDetails\",\r\n canDelete: \"canDelete\",\r\n },\r\n Detail: {\r\n titleField: \"titleField\",\r\n controller: \"controller\",\r\n screenCode: \"screenCode\",\r\n queryFromParent: \"queryFromParent\",\r\n },\r\n },\r\n}\r\n\r\nexport default HConstant\r\n","import { HFormat } from \"@macashipo/mlib\"\r\nimport merge from \"lodash/merge\"\r\nimport { fnListMyForm, fnListMyFormControl } from \"src/helpers/fnList\"\r\nimport { KMC } from \"./More\"\r\nimport { FlowGetConfigControlFromServer } from \"./Form\"\r\nimport * as AHOptions from \"src/core/helpers/options\"\r\nimport { HUtils } from \"src/core/components/MyUI/UIContentsTypes/_helpers\"\r\n\r\nexport const KMore = KMC\r\nexport const KMoreOfFormControl = KMore\r\n\r\nexport const FlowGetConfigFormControlFromV1 = ({\r\n configFormControl,\r\n config = {},\r\n} = {}) => {\r\n //for v5\r\n if (configFormControl) {\r\n return configFormControl\r\n }\r\n let _propsControl\r\n if (config.Props) {\r\n _propsControl = config.Props\r\n }\r\n let _more = {}\r\n if (config.Hint) {\r\n _more.hint = config.Hint\r\n }\r\n if (config.Source || config.SourceField) {\r\n _more.optionKey = config.Source || config.SourceField\r\n }\r\n if (_propsControl) {\r\n _more = {\r\n ..._more,\r\n ..._propsControl,\r\n }\r\n }\r\n\r\n let _configFormControl = {\r\n label: config.Label,\r\n fieldName: config.FieldName,\r\n type: config.Type,\r\n more: _more,\r\n }\r\n return _configFormControl\r\n}\r\n\r\nexport const FlowGetMore = ({ configFormControl = {}, ...rest } = {}) => {\r\n let _more = {}\r\n let _configFormControl = FlowGetConfigFormControlFromV1({\r\n configFormControl,\r\n ...rest,\r\n })\r\n if (_configFormControl && _configFormControl.more) {\r\n return _configFormControl.more\r\n }\r\n return _more\r\n}\r\n\r\nexport const FlowMergeWithCustomProps = ({ configFormControl, custom }) => {\r\n if (\r\n configFormControl &&\r\n custom &&\r\n configFormControl[\"_mergeCustom\"] !== true\r\n ) {\r\n if (configFormControl.more && custom.more) {\r\n console.warn(\"more:\", custom.more)\r\n for (let k of Object.keys(custom.more)) {\r\n if (!configFormControl.more.hasOwnProperty(k)) {\r\n configFormControl.more[k] = custom.more[k]\r\n console.warn(\"merge custom:\", k, configFormControl)\r\n } else if (\r\n typeof configFormControl.more[k] == \"object\" &&\r\n typeof custom.more[k] == \"object\"\r\n ) {\r\n configFormControl.more[k] = merge(\r\n configFormControl.more[k],\r\n custom.more[k]\r\n )\r\n console.warn(\r\n \"merge custom 2:\",\r\n k,\r\n configFormControl.more[k],\r\n custom.more[k]\r\n )\r\n }\r\n }\r\n }\r\n configFormControl[\"_mergeCustom\"] = true\r\n }\r\n}\r\n\r\nexport const FlowGetMoreOfKey = ({\r\n configFormControl = {},\r\n key,\r\n defaultValue,\r\n ...rest\r\n} = {}) => {\r\n let _more = FlowGetMore({ configFormControl, ...rest })\r\n if (_more && _more.hasOwnProperty(key)) {\r\n // console.warn(\"FlowGetMoreOfKey:\", key, _more)\r\n return _more[key]\r\n }\r\n return defaultValue\r\n}\r\n\r\nexport const FlowGetCanEdit = ({ configFormControl, ...rest } = {}) => {\r\n let _configFormControl = FlowGetConfigFormControlFromV1({\r\n configFormControl,\r\n ...rest,\r\n })\r\n let _more = FlowGetMore({ configFormControl: _configFormControl, ...rest })\r\n if (_more[KMore.disabled] == true) {\r\n return false\r\n }\r\n return true\r\n}\r\n\r\nexport const FlowGetDisabledOfControl = ({ more, fnList } = {}) => {\r\n if (more && more.disabled) {\r\n return true\r\n }\r\n let _disabledForm = HUtils.runFnList(fnList, \"fnGetDisabledForm\")\r\n if (_disabledForm) {\r\n return true\r\n }\r\n return false\r\n}\r\n\r\nexport const FlowGetCanShow = ({\r\n configFormControl,\r\n fnList,\r\n more,\r\n ...rest\r\n} = {}) => {\r\n let _canShow = true\r\n let _more =\r\n more || FlowGetMore({ configFormControl: configFormControl, ...rest })\r\n // console.warn(\"FlowGetCanShow:\", _more, configFormControl)\r\n let _currentValues = null\r\n if (_more) {\r\n if (\r\n _more.hasOwnProperty(KMore.conditionHide) ||\r\n _more.hasOwnProperty(KMore.hideCondition)\r\n ) {\r\n _currentValues =\r\n _currentValues || fnListMyForm.getCurrentValues(fnList) || {}\r\n let _conditionHide =\r\n _more[KMore.conditionHide] || _more[KMore.hideCondition]\r\n let _willHideByCondition = HFormat.format(_currentValues, {\r\n type: \"hideCondition\",\r\n configHideCondition: _conditionHide,\r\n })\r\n console.log(\"_willHideByCondition:\", _willHideByCondition, _conditionHide)\r\n if (_willHideByCondition === true) {\r\n _canShow = false\r\n }\r\n }\r\n if (_more.hasOwnProperty(KMore.conditionShow)) {\r\n let _conditionShow = _more[KMore.conditionShow] || {}\r\n _currentValues =\r\n _currentValues || fnListMyForm.getCurrentValues(fnList) || {}\r\n if (_conditionShow.isCondition) {\r\n // let _valueRelative = HUtils.get(\r\n // _currentValuesOfForm,\r\n // _conditionShow.fieldRelative\r\n // )\r\n // _canShow = checkConditionShowWithOperator(\r\n // _valueRelative,\r\n // _conditionShow.whenValue,\r\n // _conditionShow.operator,\r\n // _conditionShow.formatDataToCmp\r\n // )\r\n // _canShow = HFormat.format(_currentValues,{..._conditionShow})\r\n } else if (_conditionShow.conditionFormat) {\r\n _canShow = HFormat.format(_currentValues, {\r\n ..._conditionShow.conditionFormat,\r\n fnList: {\r\n getValue: configFormat => {\r\n if (configFormat && configFormat.valueOfField) {\r\n return _currentValues[configFormat.valueOfField]\r\n }\r\n },\r\n },\r\n })\r\n } else {\r\n for (let k of Object.keys(_conditionShow)) {\r\n let _fieldName = k\r\n let _valueExpected = _conditionShow[_fieldName]\r\n let _valueOfField = _currentValues[_fieldName]\r\n if (_valueExpected !== _valueOfField) {\r\n return false\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return _canShow\r\n}\r\n\r\nexport const FlowGetPlaceHolder = ({ configFormControl, ...rest } = {}) => {\r\n let _more = FlowGetMore({ configFormControl: configFormControl, ...rest })\r\n if (_more[KMore.placeholder]) {\r\n return _more[KMore.placeholder]\r\n }\r\n if (rest.defaultValue) {\r\n return rest.defaultValue\r\n }\r\n return \"\"\r\n}\r\n\r\nexport const FlowGetSameChange = ({\r\n configFormControl,\r\n optionItem,\r\n ...rest\r\n} = {}) => {\r\n let _more = FlowGetMore({ configFormControl: configFormControl, ...rest })\r\n console.log(\"optionItem:\", optionItem)\r\n if (\r\n optionItem != null &&\r\n _more[KMore.sameChange] &&\r\n typeof _more[KMore.sameChange] === \"object\"\r\n ) {\r\n let _obj = {}\r\n for (let k of Object.keys(_more[KMore.sameChange])) {\r\n //chi update khi co field trong optionItem\r\n if (optionItem.hasOwnProperty(_more[KMore.sameChange][k])) {\r\n _obj[k] = optionItem[_more[KMore.sameChange][k]]\r\n }\r\n }\r\n return _obj\r\n }\r\n return null\r\n}\r\n\r\nexport const FlowGetDefaultValues = ({\r\n configFormControl,\r\n fnList,\r\n ...rest\r\n} = {}) => {\r\n let _defaultValues = fnListMyForm.getDefaultValues(fnList)\r\n // console.warn(\"FlowGetDefaultValues\",_defaultValues)\r\n return _defaultValues\r\n}\r\n\r\nexport const FlowGetDefaultValueOfFieldName = ({\r\n configFormControl,\r\n fieldName,\r\n defaultValue,\r\n ...rest\r\n} = {}) => {\r\n let _configFormControl = FlowGetConfigFormControlFromV1({\r\n configFormControl,\r\n ...rest,\r\n })\r\n let _fieldName = fieldName || _configFormControl.fieldName\r\n let _defaultValues = FlowGetDefaultValues({ configFormControl, ...rest })\r\n if (_defaultValues && _defaultValues.hasOwnProperty(_fieldName)) {\r\n return _defaultValues[_fieldName]\r\n }\r\n return defaultValue != null ? defaultValue : null\r\n}\r\n\r\nexport const FlowUpdateValueForm = ({\r\n configFormControl,\r\n fnList,\r\n fieldName,\r\n newValue,\r\n fnForceUpdateCell,\r\n ...rest\r\n} = {}) => {\r\n let _configFormControl = FlowGetConfigFormControlFromV1({\r\n configFormControl,\r\n ...rest,\r\n })\r\n let _fieldName = fieldName || _configFormControl.fieldName\r\n console.warn(\"FlowUpdateValueForm\", newValue, fnList)\r\n if (fnList) {\r\n //v1,v3\r\n if (fnList.onUpdateValueOfField) {\r\n fnList.onUpdateValueOfField({\r\n fieldName: _fieldName,\r\n newValue: newValue,\r\n })\r\n }\r\n }\r\n}\r\n\r\nexport const FlowUpdateRelativeControls = ({\r\n objRelatives,\r\n objEffectedBy,\r\n configFormControl,\r\n fieldName,\r\n more,\r\n ...rest\r\n} = {}) => {\r\n console.warn(\"FlowUpdateRelativeControls:\", fieldName, more)\r\n let _fieldName = fieldName || configFormControl.fieldName || \"\"\r\n if (_fieldName && objRelatives && objEffectedBy) {\r\n let _more = more || FlowGetMore({ configFormControl, ...rest })\r\n if (_more) {\r\n //update relatives\r\n if (_more[KMore.relativeTo] && _more[KMore.relativeTo].length > 0) {\r\n if (objRelatives[_fieldName] === undefined) {\r\n objRelatives[_fieldName] = []\r\n }\r\n //update objRelatives\r\n objRelatives[_fieldName] = objRelatives[_fieldName].concat(\r\n _more[KMore.relativeTo]\r\n )\r\n }\r\n\r\n //update relatives from more.relativeFrom\r\n if (\r\n _more[KMore.relativeFrom] &&\r\n Array.isArray(_more[KMore.relativeFrom]) &&\r\n _more[KMore.relativeFrom].length > 0\r\n ) {\r\n for (let k of _more[KMore.relativeFrom]) {\r\n let _fFrom = k\r\n if (objRelatives[_fFrom] === undefined) {\r\n objRelatives[_fFrom] = []\r\n }\r\n if (\r\n Array.isArray(objRelatives[_fFrom]) &&\r\n objRelatives[_fFrom].indexOf(_fieldName) == -1\r\n ) {\r\n objRelatives[_fFrom].push(_fieldName)\r\n }\r\n }\r\n }\r\n\r\n //update relative with conditionshow\r\n if (_more && _more[KMore.conditionShow]) {\r\n let _keys = Object.keys(_more[KMore.conditionShow])\r\n if (!_keys.includes(\"isCondition\")) {\r\n for (let k of _keys) {\r\n if (objRelatives[k] === undefined) {\r\n objRelatives[k] = []\r\n }\r\n if (objRelatives[k].indexOf(_fieldName) === -1) {\r\n objRelatives[k].push(_fieldName)\r\n }\r\n }\r\n } else {\r\n // Khi dieu kien show của 1 control la 1 dieu kien khong phai 1 gia tri cu the\r\n const conditionShow = _more[KMore.conditionShow]\r\n const fieldRelative = conditionShow?.fieldRelative\r\n // Danh cho truong hop phu thuoc 1 control trong 1 group\r\n if (fieldRelative.indexOf(\".\") > -1) {\r\n //Chi lay field cua cha vi ben trong thay doi thi se thay doi luon ca group va se update control phu thuoc\r\n let _fieldParent = fieldRelative.split(\".\")?.[0]\r\n if (objRelatives[_fieldParent] === undefined) {\r\n objRelatives[_fieldParent] = []\r\n }\r\n if (objRelatives[_fieldParent].indexOf(_fieldName) === -1) {\r\n objRelatives[_fieldParent].push(_fieldName)\r\n }\r\n } else {\r\n if (objRelatives[fieldRelative] === undefined) {\r\n objRelatives[fieldRelative] = []\r\n }\r\n if (objRelatives[fieldRelative].indexOf(_fieldName) === -1) {\r\n objRelatives[fieldRelative].push(_fieldName)\r\n }\r\n }\r\n }\r\n }\r\n\r\n //update effected\r\n if (_more[KMore.effectedBy] && _more[KMore.effectedBy].length > 0) {\r\n for (let k of _more[KMore.effectedBy]) {\r\n if (objEffectedBy[k] === undefined) {\r\n objEffectedBy[k] = []\r\n }\r\n if (objEffectedBy[k].indexOf(_fieldName) === -1) {\r\n objEffectedBy[k].push(_fieldName)\r\n }\r\n }\r\n }\r\n }\r\n }\r\n //for child type layout\r\n if (more && more[\"items\"] && Array.isArray(more[\"items\"])) {\r\n for (let k of more[\"items\"]) {\r\n let _configChild = FlowGetConfigControlFromServer(k)\r\n FlowUpdateRelativeControls({\r\n objRelatives,\r\n objEffectedBy,\r\n configFormControl: _configChild,\r\n fieldName: _configChild.fieldName,\r\n more: _configChild.more,\r\n })\r\n }\r\n }\r\n}\r\n\r\nexport const FlowFnListFromExtControl = {\r\n keys: {\r\n resetFormControl: \"resetFormControl\",\r\n forceUpdate: \"forceUpdate\",\r\n updateValueEffect: \"updateValueEffect\",\r\n updateValue: \"updateValue\",\r\n },\r\n isHasFn: ({ fnListFromExtControl, fieldName, fnName } = {}) => {\r\n if (\r\n fnListFromExtControl &&\r\n fieldName &&\r\n fnListFromExtControl[fieldName] &&\r\n fnListFromExtControl[fieldName][fnName]\r\n ) {\r\n return true\r\n }\r\n return false\r\n },\r\n forceUpdate: ({ fnListFromExtControl, fieldName } = {}) => {\r\n console.warn(\r\n \"ExtControl forceUpdate:\",\r\n fieldName,\r\n fnListFromExtControl[fieldName]\r\n )\r\n if (\r\n FlowFnListFromExtControl.isHasFn({\r\n fnListFromExtControl,\r\n fieldName,\r\n fnName: FlowFnListFromExtControl.keys.forceUpdate,\r\n })\r\n ) {\r\n fnListFromExtControl[fieldName].forceUpdate()\r\n }\r\n },\r\n updateValueEffect: ({ fnListFromExtControl, fieldName } = {}) => {\r\n console.warn(\r\n \"ExtControl updateValueEffect:\",\r\n fieldName,\r\n fnListFromExtControl[fieldName]\r\n )\r\n if (\r\n FlowFnListFromExtControl.isHasFn({\r\n fnListFromExtControl,\r\n fieldName,\r\n fnName: FlowFnListFromExtControl.keys.updateValueEffect,\r\n })\r\n ) {\r\n fnListFromExtControl[fieldName].updateValueEffect()\r\n }\r\n },\r\n updateValue: ({ fnListFromExtControl, fieldName, newValue } = {}) => {\r\n console.warn(\r\n \"ExtControl updateValue:\",\r\n fieldName,\r\n fnListFromExtControl[fieldName]\r\n )\r\n if (\r\n FlowFnListFromExtControl.isHasFn({\r\n fnListFromExtControl,\r\n fieldName,\r\n fnName: FlowFnListFromExtControl.keys.updateValue,\r\n })\r\n ) {\r\n fnListFromExtControl[fieldName].updateValue(newValue)\r\n }\r\n },\r\n}\r\n\r\nexport const FlowFCGetDefaultValueControlSelect = ({\r\n cfc,\r\n isReset,\r\n isMulti,\r\n sourceData,\r\n charSplit,\r\n} = {}) => {\r\n if (cfc) {\r\n let _valueControl = cfc.valueControl\r\n if (isReset) {\r\n _valueControl = cfc.defaultValues[cfc.fieldName] || \"\"\r\n }\r\n //truong hop 0 hoac rong van tinh\r\n if (_valueControl != null) {\r\n if (isMulti && _valueControl.indexOf(charSplit || \",\") > -1) {\r\n let _splitValue = _valueControl.split(charSplit || \",\")\r\n return _splitValue.map((v, i) => {\r\n let _option = AHOptions.getOptionByValue(\r\n sourceData || fnListMyFormControl.getSourceData(cfc.fnList),\r\n v\r\n )\r\n if (_option) {\r\n return _option\r\n }\r\n return {\r\n Value: v,\r\n Text: v,\r\n }\r\n })\r\n } else {\r\n let _option = AHOptions.getOptionByValue(\r\n sourceData || fnListMyFormControl.getSourceData(cfc.fnList),\r\n _valueControl\r\n )\r\n if (_option) {\r\n return _option\r\n }\r\n if (_valueControl != \"\") {\r\n //tranh truong hop value = \"\"\r\n return {\r\n Value: _valueControl,\r\n Text: _valueControl,\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return null\r\n}\r\n\r\nexport const FlowFCGetSelectedControlSelect = ({\r\n valueSelect,\r\n itemOption,\r\n} = {}) => {\r\n if (valueSelect && itemOption) {\r\n if (Array.isArray(valueSelect)) {\r\n for (let i = 0; i < valueSelect.length; i++) {\r\n if (valueSelect[i] && valueSelect[i].Value == itemOption.Value) {\r\n return true\r\n }\r\n }\r\n } else if (valueSelect.Value == itemOption.Value) {\r\n return true\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport const FlowFCUpdateValueControlSelect = ({\r\n cfc,\r\n valueSelect,\r\n itemOption,\r\n checked,\r\n value,\r\n isMulti,\r\n charSplit,\r\n setValueControl,\r\n} = {}) => {\r\n console.warn(\r\n \"FlowFCUpdateValueControlSelect:\",\r\n isMulti,\r\n checked,\r\n itemOption,\r\n valueSelect\r\n )\r\n if (cfc && setValueControl) {\r\n if (isMulti == true) {\r\n let _valueSelect = valueSelect || []\r\n let _charSplit = charSplit || \",\"\r\n if (checked) {\r\n _valueSelect.push(itemOption)\r\n } else {\r\n let _index = null\r\n for (let i = 0; i < _valueSelect.length; i++) {\r\n if (_valueSelect[i].Value == itemOption.Value) {\r\n _index = i\r\n break\r\n }\r\n }\r\n if (_index >= 0) {\r\n _valueSelect.splice(_index, 1)\r\n }\r\n }\r\n setValueControl(_valueSelect)\r\n cfc.updateValueControl(\r\n _valueSelect\r\n .map((v, i) => {\r\n return v.Value\r\n })\r\n .join(_charSplit)\r\n )\r\n } else {\r\n if (checked) {\r\n setValueControl(itemOption)\r\n cfc.updateValueControl(itemOption.Value)\r\n } else {\r\n setValueControl(null)\r\n cfc.updateValueControl(\"\")\r\n }\r\n }\r\n }\r\n}\r\n","import { HIs, HLink, HUtils, MyUI } from \"@macashipo/mlib\"\r\nimport { KMTC } from \"./More\"\r\nimport i18next from \"i18next\"\r\n//ham can bo sung tu mlib\r\n\r\nexport const addItemToArrayOrCreateNewArray = (currArr = [], newItem) => {\r\n let _arr = [\"empty\"]\r\n if (currArr) {\r\n if (HIs.isArray(currArr)) {\r\n if (currArr.length > 0) {\r\n _arr = currArr\r\n }\r\n } else {\r\n _arr = [currArr]\r\n }\r\n }\r\n // console.warn(\"addItemToArrayOrCreateNewArray\",currArr,newItem)\r\n return [..._arr, newItem]\r\n}\r\n\r\n//Utils.mergeRecursive\r\nexport const mergeRecursive = (obj1, obj2) => {\r\n for (var p in obj2) {\r\n try {\r\n // Property in destination object set; update its value.\r\n if (obj2[p].constructor == Object) {\r\n obj1[p] = mergeRecursive(obj1[p], obj2[p])\r\n } else {\r\n obj1[p] = obj2[p]\r\n }\r\n } catch (e) {\r\n // Property in destination object not set; create it and set its value.\r\n obj1[p] = obj2[p]\r\n }\r\n }\r\n return obj1\r\n}\r\n\r\n//HUtils.getDataBySort\r\nexport const getDataBySort = (\r\n data,\r\n sortByField,\r\n sortType = \"asc\",\r\n sortDataType = \"string\"\r\n) => {\r\n if (sortByField && data && data.length > 0) {\r\n let _sortType = sortType\r\n let _sortDataType = sortDataType\r\n if (sortType !== \"asc\") {\r\n _sortType = \"desc\"\r\n }\r\n if (sortDataType !== \"string\") {\r\n _sortDataType = \"number\"\r\n }\r\n return data.sort((a, b) => {\r\n if (a && b) {\r\n let _itemA = a[sortByField]\r\n let _itemB = b[sortByField]\r\n if (_sortDataType == \"number\") {\r\n let _compare = _itemA - _itemB\r\n return _compare * (_sortType == \"desc\" ? -1 : 1)\r\n } else {\r\n let _compare = 0\r\n if (_itemA > _itemB) {\r\n _compare = _sortType == \"desc\" ? -1 : 1\r\n } else if (_itemA < _itemB) {\r\n _compare = _sortType == \"desc\" ? 1 : -1\r\n }\r\n return _compare\r\n }\r\n }\r\n return false\r\n })\r\n }\r\n return data\r\n}\r\n\r\n//HUtils.PrintHtml\r\nexport const FlowPrintHtml = (htmlString = \"\", { autoPrint } = {}) => {\r\n window.onbeforeprint = function () {\r\n console.log(\"Printing prepare...\")\r\n }\r\n window.onafterprint = function () {\r\n console.log(\"Printing completed...\")\r\n }\r\n let _idPrintfGloabl = \"printf_global\"\r\n let _idPrintfGloablIframe = \"printf_global_iframe\"\r\n let _eContain = document.getElementById(_idPrintfGloabl)\r\n console.log(\"FlowPrintHtml:\", _eContain)\r\n if (_eContain == null) {\r\n const el = document.createElement(\"div\")\r\n el.setAttribute(\"id\", _idPrintfGloabl)\r\n el.setAttribute(\"style\", \"display: none;\")\r\n document.body.appendChild(el)\r\n _eContain = document.getElementById(_idPrintfGloabl)\r\n }\r\n if (_eContain) {\r\n _eContain.innerHTML = ``\r\n }\r\n //insert htmlString\r\n let _eIframe = document.getElementById(_idPrintfGloablIframe)\r\n if (_eIframe) {\r\n _eIframe.contentDocument.write(htmlString)\r\n window.frames[_idPrintfGloablIframe].focus()\r\n let _height = _eIframe.contentWindow.document.body.scrollHeight\r\n _eIframe.style.height = `${_height}px`\r\n if (autoPrint !== false) {\r\n setTimeout(() => {\r\n // if(document && document.body && document.body.style && document.documentElement && document.documentElement.clientWidth){\r\n // document.body.style.width = `${document.documentElement.clientWidth}px`;\r\n // }//fix print change columns size\r\n\r\n if (window.frames[_idPrintfGloablIframe]) {\r\n if (window.frames[_idPrintfGloablIframe].document.execCommand) {\r\n window.frames[_idPrintfGloablIframe].document.execCommand(\r\n \"print\",\r\n false,\r\n null\r\n ) //chay duoc voi Coccoc\r\n } else {\r\n window.frames[_idPrintfGloablIframe].print() //sau khi gen iframe thì tự động in\r\n }\r\n } else {\r\n console.error(\"not found frames printf\", window.frames)\r\n }\r\n }, 250)\r\n }\r\n }\r\n}\r\n\r\n//valueSelected can list string value with , or array value\r\n//HOptions.getArrayOptionSelectedFromOptions\r\nexport const FlowConvertSelectedMultiToArrayOptions = (\r\n valueSelected = \"\",\r\n sourceData = [],\r\n { arraySplitChar } = {}\r\n) => {\r\n let _arrSelected = []\r\n if (Array.isArray(valueSelected)) {\r\n _arrSelected = valueSelected\r\n } else if (valueSelected) {\r\n //bo sung truong hop loi neu valueSelected la number\r\n let _valueSelected = valueSelected\r\n if (typeof valueSelected !== \"string\") {\r\n _valueSelected = \"\" + valueSelected\r\n }\r\n _arrSelected = _valueSelected.split(arraySplitChar || \",\")\r\n }\r\n if (sourceData) {\r\n return sourceData.filter((v, i) => {\r\n return _arrSelected.indexOf(v.Value) > -1\r\n })\r\n }\r\n return []\r\n}\r\n\r\nexport const HOptionsGetArrayOptionFromArrayValue = (\r\n arrValue = [],\r\n options = [],\r\n { arraySplitChar } = { arraySplitChar: \",\" }\r\n) => {\r\n let _arrOption = []\r\n let _arrValue = arrValue\r\n if (typeof _arrValue === \"string\") {\r\n _arrValue = _arrValue.split(arraySplitChar)\r\n }\r\n // console.warn(\"get arr:\", _arrValue, options)\r\n if (_arrValue && Array.isArray(_arrValue) && _arrValue.length > 0) {\r\n for (let i = 0; i < _arrValue.length; i++) {\r\n for (let j = 0; j < options.length; j++) {\r\n if (options[j].Value == _arrValue[i]) {\r\n _arrOption.push(options[j])\r\n break\r\n }\r\n }\r\n }\r\n }\r\n return _arrOption\r\n}\r\n\r\nexport const HOptionsGetItemOfValueFromOptions = (options, value) => {\r\n let _item = null\r\n if (options != null) {\r\n for (let i = 0; i < options.length; i++) {\r\n if (options[i].Value == value) {\r\n _item = options[i]\r\n break\r\n }\r\n }\r\n }\r\n return _item\r\n}\r\n\r\nexport const HOptionsGetNextItemOfValueFromOptions = (options, value) => {\r\n let _item = null\r\n if (options != null && options.length > 0) {\r\n if (value == null) {\r\n return options[0]\r\n }\r\n for (let i = 0; i < options.length; i++) {\r\n // console.warn('nextItem: ', i,options[i],options[i].Value, value);\r\n if (options[i].Value == value) {\r\n if (i == options.length - 1) {\r\n _item = options[0]\r\n } else {\r\n _item = options[i + 1]\r\n }\r\n break\r\n }\r\n //khong tim thay value trong options\r\n if (i == options.length - 1) {\r\n return options[0]\r\n }\r\n }\r\n }\r\n return _item\r\n}\r\n\r\n//bo sung fConfigForm\r\nexport const OneTableCell_getConfigForm = ({\r\n customMore,\r\n oneTableCell,\r\n row,\r\n} = {}) => {\r\n let _configForm = {}\r\n if (oneTableCell && customMore && row) {\r\n console.log(\"OneTableCell_getConfigForm:\", customMore, row)\r\n if (\r\n customMore[KMTC.fConfigForm] &&\r\n row.hasOwnProperty(customMore[KMTC.fConfigForm])\r\n ) {\r\n return row[customMore[KMTC.fConfigForm]]\r\n }\r\n return oneTableCell.getConfigForm({ customMore })\r\n }\r\n return _configForm\r\n}\r\n\r\nexport const HLink_updateParamOnUrl = (\r\n name,\r\n value,\r\n url = window.location.href,\r\n opts = { isReplace: false }\r\n) => {\r\n let _allPrams = HLink.getAllParamOnUrl(url)\r\n let _newUrl = url\r\n if (_allPrams) {\r\n _allPrams[name] = value\r\n return HLink_updateUrlWithAllParams(_allPrams, url, {\r\n isReplace: opts.isReplace,\r\n })\r\n }\r\n return _newUrl\r\n}\r\nexport function HLink_updateUrlWithAllParams(\r\n allParams,\r\n url = window.location.href,\r\n opts = { updateUrlWithoutReload: true, isReplace: false }\r\n) {\r\n let _newUrl = url\r\n if (allParams) {\r\n let _indexQuestionMark = url.lastIndexOf(\"?\")\r\n if (_indexQuestionMark == -1) {\r\n _indexQuestionMark = url.length\r\n }\r\n _newUrl =\r\n url.substr(0, _indexQuestionMark) +\r\n \"?\" +\r\n Object.keys(allParams)\r\n .map(v => {\r\n return `${v}=${allParams[v]}`\r\n })\r\n .join(\"&\")\r\n let _updateUrlWithoutReload = opts.updateUrlWithoutReload !== false\r\n if (_updateUrlWithoutReload) {\r\n HLink_setNewUrlWithoutReload(_newUrl, { isReplace: opts.isReplace })\r\n }\r\n }\r\n return _newUrl\r\n}\r\nexport function HLink_setNewUrlWithoutReload(url, opts = { isReplace: false }) {\r\n if (url) {\r\n if (opts.isReplace === true) {\r\n window.history.replaceState({ path: url }, \"\", url)\r\n } else {\r\n window.history.pushState({ path: url }, \"\", url)\r\n }\r\n }\r\n}\r\n\r\nexport function HUtils_getTextWithData(text = \"\", data = {}, opts) {\r\n try {\r\n if (text && typeof text == \"string\" && text.indexOf(\"[\") > -1) {\r\n return HUtils.getTextWithData(text, data, opts)\r\n } else {\r\n return text\r\n }\r\n } catch (error) {\r\n console.warn(\"error parse html:\", text)\r\n return text\r\n }\r\n}\r\n\r\nexport function HUtils_getTextOrHTML(text = \"\", opts = {}) {\r\n if (typeof text === \"string\") {\r\n try {\r\n if (\r\n String(text).trim().startsWith(\"<\") &&\r\n String(text).trim().endsWith(\">\")\r\n ) {\r\n return \r\n } else {\r\n if (opts.usingI18n) {\r\n if (opts.from) {\r\n return i18next.t(`${opts.from}.${text}`, {\r\n ns: opts.ns || \"common\",\r\n defaultValue: i18next.t(text, {\r\n ns: opts.ns || \"common\",\r\n defaultValue: text,\r\n }),\r\n })\r\n }\r\n return i18next.t(text, {\r\n ns: opts.ns || \"common\",\r\n defaultValue: text,\r\n })\r\n }\r\n return text\r\n }\r\n } catch (error) {\r\n console.warn(\"error parse text:\", text)\r\n return text\r\n }\r\n }\r\n return text\r\n}\r\n","export const KConfigPageTable = {\r\n addExtraColumns: \"addExtraColumns\", //extra columns\r\n showDetails: \"showDetails\", //co expand ko\r\n showDetailsMulti: \"showDetailsMulti\", //co expand ko\r\n hideColDelete: \"hideColDelete\", //an cot delete\r\n hideColDeleteOnSmallWidth: \"hideColDeleteOnSmallWidth\", //an cot delete neu width nho ko\r\n customDelete: \"customDelete\", //custom delete column\r\n canDelete: \"canDelete\", //cho phep delete ko\r\n showColRemoveRow: \"showColRemoveRow\", //show col remove cho table form\r\n showHeader: \"showHeader\", //co show header table ko\r\n show: \"show\", //co show table ko\r\n hasCustomHeader: \"hasCustomHeader\", //co custom header ko, thay doi class table\r\n hasWrapHeader: \"hasWrapHeader\", //co wrap header ko, thay doi class table\r\n noBorder: \"noBorder\",\r\n noBorderCol: \"noBorderCol\",\r\n borderLight: \"borderLight\",\r\n hasBigBorderBottom: \"hasBigBorderBottom\",\r\n classNameTable: \"classNameTable\", //bo sung class name cho table\r\n forceFullExpandDetail: \"forceFullExpandDetail\",\r\n showLoadingWhenFilter: \"showLoadingWhenFilter\",\r\n showID: \"showID\", //show col ID\r\n colsActions: \"colsActions\", //cols actions\r\n customProps: \"customProps\", //custom props table build cols\r\n needRebuildColAfterGetList: \"needRebuildColAfterGetList\",\r\n buildColsAfterReloadList: \"buildColsAfterReloadList\", //do quên needRebuildColAfterGetList bên v1 nên tạo mới bên v5\r\n hasExpand: \"hasExpand\",\r\n sizePerPage: \"sizePerPage\",\r\n hideSizePerPage: \"hideSizePerPage\",\r\n optionsTable: \"optionsTable\", //options cho table\r\n hasPagingRemote: \"hasPagingRemote\", // paging server\r\n tableProps: \"tableProps\", //bo sung props cho tabled\r\n deleteTitle: \"deleteTitle\",\r\n deleteContent: \"deleteContent\",\r\n deleteContentHtml: \"deleteContentHtml\",\r\n deleteWithNote: \"deleteWithNote\",\r\n fDelete: \"fDelete\", //dung o delete\r\n styleHeader: \"styleHeader\", //style chung cho header neu custom style header\r\n belowTable: \"belowTable\", //config MyUI show below table array item: type, groupByFn, groupByFnArgs\r\n needReloadAfterUpdateFields: \"needReloadAfterUpdateFields\", //array field khi goi update field, se goi reload list\r\n needReloadChartAfterUpdateFields: \"needReloadChartAfterUpdateFields\", //array field khi goi update field se reload chart\r\n hideTableWhenEmpty: \"hideTableWhenEmpty\", //an luon vung table khi data rong\r\n configSelectRow: \"configSelectRow\", //show select row o table\r\n canSort: \"canSort\", //default can sort column\r\n canSortByField: \"canSortByField\",\r\n fixHeightScrollTable: \"fixHeightScrollTable\", //bool: gom table vao vung co the scroll duoc\r\n fixHeightStickyNumColumn: \"fixHeightStickyNumColumn\", //num: freeze column khi gom vung\r\n fixHeightStickyFooter: \"fixHeightStickyFooter\", //bool: sticky footer\r\n showTotal: \"showTotal\", //show footer\r\n configTotal: \"configTotal\", //configTotal\r\n needReloadAfterDelete: \"needReloadAfterDelete\",\r\n noCheckFullPath: \"noCheckFullPath\", //khong check fullpath cua api\r\n fieldId: \"fieldId\", //thay the field Id\r\n showLoadMore: \"showLoadMore\", //show nut load more thay vi pagination\r\n autoLoadMore: \"autoLoadMore\",\r\n autoLoadMoreMode: \"autoLoadMoreMode\",\r\n autoLoadMoreOffset: \"autoLoadMoreOffset\",\r\n noWrap: \"noWrap\", //bỏ style của thẻ card\r\n hasAddNewAtBottom: \"hasAddNewAtBottom\", //bổ sung nút addnew cuối bảng\r\n btnAddNewAtBottom: \"btnAddNewAtBottom\", // config btn add new at bottom\r\n defaultHeaderAlign: \"defaultHeaderAlign\",\r\n headerAlignByField: \"headerAlignByField\",\r\n defaultHeaderStyle: \"defaultHeaderStyle\",\r\n headerStyleByField: \"headerStyleByField\",\r\n headerColPropsByField: \"headerColPropsByField\",\r\n usingOrderNo: \"usingOrderNo\", //su dung orderNo cho viec sap xep\r\n defaultOrderNo: \"defaultOrderNo\", //gia tri defaultOrderNo mac dinh//chua xai\r\n showLoadingRowWhenRequestUpdateRow: \"showLoadingRowWhenRequestUpdateRow\", //show loading\r\n isRenderFooterByField: \"isRenderFooterByField\",\r\n loadMoreSelectorScroll: \"loadMoreSelectorScroll\",\r\n isAvoidBreakPrint: \"isAvoidBreakPrint\", //tránh chia đôi row khi in\r\n hideHeaderWhenNoData: \"hideHeaderWhenNoData\",\r\n styleWrap: \"styleWrap\",\r\n maxWidthByColumnWidth: \"maxWidthByColumnWidth\",\r\n maxWidthPercent100: \"maxWidthPercent100\", //dugn de tinh toan maxWidthByColumnWidth, mac dinh la 200\r\n loadMoreAutoSwitchScrollWindow: \"loadMoreAutoSwitchScrollWindow\",\r\n}\r\n\r\nexport const KConfigPageTableDefault = {\r\n showHeader: true,\r\n showID: false,\r\n}\r\n\r\nexport const KConfigPageFilter = {\r\n type: \"type\",\r\n customQueryFromSever: \"customQueryFromSever\",\r\n position: \"position\",\r\n searchServer: \"searchServer\",\r\n showSearch: \"showSearch\",\r\n showFilterAsPopover: \"showFilterAsPopover\",\r\n needCheckLastItemQueryServer: \"needCheckLastItemQueryServer\", //kiem tra last item filter co isServer ko de quyet dinh co requestList hay ko, mac dinh la false\r\n}\r\n\r\nexport const KConfigPageDetail = {\r\n multi: \"multi\",\r\n needReloadMaster: \"needReloadMaster\",\r\n needReloadMasterAfterDeleteItem: \"needReloadMasterAfterDeleteItem\",\r\n needReloadMasterAfterUpdateField: \"needReloadMasterAfterUpdateField\",\r\n needReloadMasterAfterAddNew: \"needReloadMasterAfterAddNew\",\r\n needReloadMasterAfterSubmitModal: \"needReloadMasterAfterSubmitModal\",\r\n needReExpandAfterReloadMasterFromDetail:\r\n \"needReExpandAfterReloadMasterFromDetail\", //need re expand after reload master\r\n needReExpandAfterAddNewFromDetail: \"needReExpandAfterAddNewFromDetail\",\r\n}\r\n\r\nexport const KConfigPageHeader = {\r\n show: \"show\",\r\n title: \"title\", //custom title on header\r\n hideTitle: \"hideTitle\", //hide title\r\n showAddNew: \"showAddNew\",\r\n showProjectHeader: \"showProjectHeader\", //show project header for solid\r\n hideButtons: \"hideButtons\",\r\n usingButtonTypeInMore: \"usingButtonTypeInMore\", //using type from more, getButtonsList ko hỗ trợ\r\n preButtons: \"preButtons\", //bo sung button tu ScreenConfig, them phia truoc\r\n sufButtons: \"sufButtons\", //bo sung button tu ScreenConfig, them phia sau\r\n onlyShowButtonInSmallWidth: \"onlyShowButtonInSmallWidth\",\r\n}\r\n\r\nexport const KConfigPagePage = {\r\n dashboard: \"dashboard\",\r\n topTable: \"topTable\",\r\n topHeader: \"topHeader\",\r\n belowHeader: \"belowHeader\",\r\n belowFilter: \"belowFilter\",\r\n belowTable: \"belowTable\", //bên dưới table\r\n topPage: \"topPage\", //đầu trang\r\n footerPage: \"footerPage\", //cuối trang\r\n configFlow: \"configFlow\",\r\n configCard: \"configCard\", //dung de config card, dung cho cac page su dung card\r\n hasSwitchView: \"hasSwitchView\", //switch view\r\n listSwitchView: \"listSwitchView\", //switch view\r\n defaultSwitchView: \"defaultSwitchView\", //defautl switch view\r\n prefixId: \"prefixId\", //prefixIdfor chart, date picker v.v...\r\n configChart: \"configChart\", //config chart thay the Options, trong truong hop Options config chart null\r\n configMultiTable: \"configMultiTable\", //config cho man hinh multi_table\r\n listChart: \"listChart\", //list chart thay the Options\r\n headerChart: \"headerChart\", //trong page chart\r\n footerChart: \"footerChart\", //trong page chart\r\n i18n: \"i18n\",\r\n}\r\n\r\nexport const KConfigPageExpander = {\r\n defaultExpand: \"defaultExpand\",\r\n hasPageExpand: \"hasPageExpand\",\r\n}\r\n\r\nexport const KEventsApp = {\r\n ee_sidemenu_forceupdate: \"ee_sidemenu_forceupdate\",\r\n}\r\n\r\nexport const KConfigPage = {\r\n hideLoadingReport: \"hideLoadingReport\",\r\n hasEditMode: \"hasEditMode\", //cho man hinh report\r\n}\r\n\r\nexport const KConfigApp = {\r\n baseUrl: \"baseUrl\",\r\n defaultTypeHubFilter: \"defaultTypeHubFilter\",\r\n defaultPositionFilter: \"defaultPositionFilter\",\r\n GoogleClientId: \"GoogleClientId\",\r\n GooglePlaceApiKey: \"GooglePlaceApiKey\",\r\n hasRegisterAccount: \"hasRegisterAccount\",\r\n hasForgotPassword: \"hasForgotPassword\",\r\n hasLoginSocialFacebook: \"hasLoginSocialFacebook\",\r\n hasLoginSocialGoogle: \"hasLoginSocialGoogle\",\r\n widthMobile: \"widthMobile\",\r\n isDevMode: \"isDevMode\", //from v5\r\n home_url: \"home_url\",\r\n DefaultHomeURL: \"DefaultHomeURL\",\r\n AuthInfo: \"AuthInfo\",\r\n appLogo_url: \"appLogo_url\",\r\n verAdmin: \"verAdmin\", //version admin, v1,v3,v5\r\n defaultTagInputCell: \"defaultTagInputCell\", //default tag, input or textarea for cell using input\r\n hasSetting2FA: \"hasSetting2FA\", //co setting 2FA ko\r\n showClassFieldOnCell: \"showClassFieldOnCell\",\r\n title: \"title\",\r\n serviceWorkersRun: \"serviceWorkersRun\",\r\n hasSignalR: \"hasSignalR\", //for signalR\r\n signalRHub: \"signalRHub\", //signalR hub link\r\n signalRKey: \"signalRKey\", //signalR key\r\n hasPushNotify: \"hasPushNotify\",\r\n fileUploadSupport: \"fileUploadSupport\",\r\n numberLocale: \"numberLocale\",\r\n currencyLocaleOptions: \"currencyLocaleOptions\",\r\n expandIconHideColor: \"expandIconHideColor\", //\r\n autoRedirectLoginPageNotFound: \"autoRedirectLoginPageNotFound\", //auto redirect login when show page not found\r\n mtf_datefromto_showRange: \"mtf_datefromto_showRange\", //default showRange filter datefromto\r\n styleDefaultCell: \"styleDefaultCell\", //style chung cho cell\r\n charSplitArray: \"charSplitArray\", //charSplitArray default ,\r\n showClearLocalCache: \"showClearLocalCache\", //show clear local Cache o avatar menu\r\n dfShowFilterAsPopover: \"dfShowFilterAsPopover\",\r\n dateFormat: \"dateFormat\",\r\n datetimeFormat: \"datetimeFormat\",\r\n dateFPFormat: \"dateFPFormat\",\r\n datetimeFPFormat: \"datetimeFPFormat\",\r\n numeralFormat: \"numeralFormat\",\r\n autoRedirectHomePage: \"autoRedirectHomePage\", //tu dong chuyen redirect / -> homepage\r\n defaultLanguage: \"defaultLanguage\",\r\n hideEffectDelete: \"hideEffectDelete\",\r\n hideEffectAddNew: \"hideEffectAddNew\",\r\n hasChangeLanguage: \"hasChangeLanguage\",\r\n hasSettingPage: \"hasSettingPage\",\r\n LanguageList: \"LanguageList\", //danh sach ngon ngu tu firstsetting\r\n defaultStyledTab: \"defaultStyledTab\",\r\n hasSwitchTheme: \"hasSwitchTheme\",\r\n blockURLNeedChangePW: \"blockURLNeedChangePW\",\r\n}\r\n\r\nexport const KConfigModal = {\r\n key: \"key\", //\r\n title: \"title\", //\r\n fTitle: \"fTitle\", //use for cell, get title from row\r\n className: \"className\",\r\n showFooter: \"showFooter\",\r\n showHeader: \"showHeader\",\r\n type: \"type\", //type of modal\r\n typeMyPage: \"typeMyPage\", //type mypage if type is mypage\r\n backdrop: \"backdrop\", //static or false\r\n size: \"size\", //md lg xl\r\n}\r\n\r\nexport const KUI = {\r\n fnshowDialog: \"fnshowDialog\",\r\n fnShowToast: \"fnShowToast\",\r\n fnshowConfirm: \"fnshowConfirm\",\r\n fnShowLoadingScreen: \"fnShowLoadingScreen\",\r\n fnForceUpdateRoutes: \"fnForceUpdateRoutes\",\r\n}\r\n\r\nexport const KConstant = {\r\n _NullOrEmpty_: \"_NullOrEmpty_\",\r\n}\r\n\r\nexport const KApiName = {\r\n List: \"List\",\r\n Options: \"Options\",\r\n UpdateFields: \"UpdateFields\",\r\n}\r\n\r\nexport const KOnePageMore = {\r\n _currentSearchText: \"_currentSearchText\", //co text dang search khong\r\n _componentTable: \"_componentTable\", //component Table\r\n _componentTableLoading: \"_componentTableLoading\",\r\n _forceUpdateTable: \"_forceUpdateTable\",\r\n _waitingComponentTableForFilter: \"_waitingComponentTableForFilter\",\r\n _configRowById: \"_configRowById\",\r\n _isShowLoadMore: \"_isShowLoadMore\",\r\n _configLoadMore: \"_configLoadMore\",\r\n _pageUUID: \"_pageUUID\",\r\n _noLocalFilter: \"_noLocalFilter\", //khong load local/save filter\r\n _loadedList: \"_loadedList\",\r\n _dataTotal: \"_dataTotal\",\r\n _isPanel: \"_isPanel\", //trang là 1 panel\r\n _isInPanel: \"_isInPanel\", //trang nằm trong 1 panel\r\n _isLoadedDefaultScreenConfig: \"_isLoadedDefaultScreenConfig\",\r\n UI_LoadOptionError: \"UI_LoadOptionError\",\r\n}\r\n\r\n//when using json on table header\r\nexport const KConfigTableHeader = {\r\n type: \"type\",\r\n header: \"header\",\r\n style: \"style\",\r\n title: \"title\",\r\n tooltip: \"tooltip\",\r\n html: \"html\",\r\n}\r\n\r\nexport const KConfigInConfigPage = {\r\n type: \"type\",\r\n needWaitingOptions: \"needWaitingOptions\",\r\n configGrid: \"configGrid\",\r\n wrapLayout: \"wrapLayout\",\r\n wrapType: \"wrapType\", //type child page cho type wrap\r\n noLocalFilter: \"noLocalFilter\",\r\n wrapStyle: \"wrapStyle\", //style bao ben ngoai page, danh cho con cua grid\r\n classNameWrap: \"classNameWrap\",\r\n styleTab: \"styleTab\",\r\n styleTabActive: \"styleTabActive\",\r\n styleItem: \"styleItem\",\r\n styleWrap: \"styleWrap\", //tuong tu wrapStyle\r\n styled: \"styled\",\r\n hideTabOnlyOneTab: \"hideTabOnlyOneTab\",\r\n}\r\n\r\nexport const KTypeCellControl = {\r\n textarea: \"textarea\",\r\n input: \"input\",\r\n}\r\n\r\nexport const KMyUITypeCommon = {\r\n html: \"html\",\r\n}\r\n\r\nexport const kRequestFromClient = {\r\n UI_TextSearch: \"UI_TextSearch\",\r\n UI_Sorts: \"UI_Sorts\",\r\n}\r\n\r\nexport const KRowMore = {\r\n _UI_NeedUpdateUIByFields: \"_UI_NeedUpdateUIByFields\",\r\n UI_MergeRowByField: \"UI_MergeRowByField\", //dùng sai tên, đáng lẽ là merge col\r\n UI_Span: \"UI_Span\",\r\n UI_StyleRow: \"UI_StyleRow\",\r\n UI_StyleRowByField: \"UI_StyleRowByField\",\r\n UI_ClassTableRow: \"UI_ClassTableRow\",\r\n UI_ClassTableCell: \"UI_ClassTableCell\",\r\n UI_ComponentAppendCell: \"UI_ComponentAppendCell\",\r\n UI_DefaultShowExpand: \"UI_DefaultShowExpand\", //default expand\r\n UI_ShowRemove: \"UI_ShowRemove\", //defautl field check show remove\r\n _fnForceUpdateDetail: \"_fnForceUpdateDetail\", //fn forceupdate detail of row\r\n}\r\n\r\nexport const kClientKeyUI = {\r\n _UI_Missing: \"_UI_Missing\", //boolean for option source item, missing from source\r\n _RelativeByField: \"_RelativeByField\",\r\n}\r\n\r\nexport const KStorage = {\r\n _localConfig: \"_localConfig\",\r\n _localBaseUrl: \"_localBaseUrl\",\r\n _usingLocalBaseUrl: \"_usingLocalBaseUrl\",\r\n redirectAfterLogin: \"redirectAfterLogin\",\r\n HomeURL: \"HomeURL\",\r\n AuthInfo: \"Auth-Info\",\r\n}\r\n\r\nexport const KClassBody = {\r\n appFullContainer: \"app-full-container\", //remove padding container of page\r\n}\r\n\r\nexport const kMyUICore = {\r\n //fnFrom MyUI Core\r\n myData: \"myData\", //get data from this.props.data\r\n myChange: \"myChange\", //call function from onChange\r\n myBlur: \"myBlur\", //call function from onBlur\r\n}\r\n\r\nexport const KObserver = {\r\n beforeSearchTable: \"beforeSearchTable\",\r\n beforeFilterTable: \"beforeFilterTable\",\r\n window_resize: \"window_resize\",\r\n after_login: \"after_login\",\r\n after_request_list: \"after_request_list\",\r\n after_requestFirstSetting: \"after_requestFirstSetting\",\r\n}\r\n\r\nexport const KLocalStorage = {\r\n useTheme: \"useTheme\",\r\n themeSeason: \"themeSeason\",\r\n lastFirstSetting: \"lastFirstSetting\",\r\n}\r\n\r\nconst K = {\r\n fnGetListExtraData: \"fnGetListExtraData\",\r\n fnGetConfigFilter: \"fnGetConfigFilter\",\r\n fnGetOptions: \"fnGetOptions\",\r\n KConfigApp,\r\n KConfigPageTable,\r\n KConfigPageTableDefault,\r\n KConfigPageFilter,\r\n KConfigPagePage,\r\n KConfigPage,\r\n KUI,\r\n KConstant,\r\n KApiName,\r\n KMyUITypeCommon,\r\n kMyUICore,\r\n}\r\nexport default K\r\n","import { HLog } from \"@macashipo/mlib\"\r\n\r\nconst logApi = HLog.logApi\r\nconst logExistType = HLog.logExistType\r\nconst logNoAnyType = HLog.logNoAnyType\r\nconst logOne = HLog.logOne\r\nconst logParseJson = HLog.logParseJson\r\nconst logTest = HLog.logTest\r\nconst logW = HLog.logW\r\nexport {\r\n logApi,\r\n logExistType,\r\n logNoAnyType,\r\n logOne,\r\n logParseJson,\r\n logTest,\r\n logW,\r\n}\r\n","import { fnListUI } from \"src/helpers/fnList\"\r\nimport * as HRegex from \"src/core/helpers/regex\"\r\nexport const RoutesPublic = []\r\nexport const RoutesPrivate = []\r\nexport const RoutesTest = []\r\n\r\n/**\r\n * Route Config:\r\n * {UIUrl:'/demo',ScreenCode:'',Title:'',APIName:'API',UIType:'Client', Config: '{\"type\":\"solid_wpgstandard_searchv3\",\"test\":true}'},\r\n */\r\n\r\n//gan forceupdate vao HCF, goi force update tu HCF\r\nexport const FlowForceUpdateRoutes = () => {\r\n fnListUI.fnForceUpdateRoutes()\r\n}\r\n\r\n//from categoryScreenList\r\nexport const FlowParseCategoryScreenList = () => {}\r\n\r\n//from first setting\r\nexport const FlowParsePublicApiScreenList = () => {}\r\n\r\nconst AddRoutes = (list = [], arrConfigRoute) => {\r\n if (arrConfigRoute && arrConfigRoute.length > 0) {\r\n for (let i = 0; i < arrConfigRoute.length; i++) {\r\n list.push(arrConfigRoute[i])\r\n }\r\n }\r\n FlowForceUpdateRoutes()\r\n}\r\nexport const FlowAddPublicRoute = (arrConfigRoute = []) => {\r\n AddRoutes(RoutesPublic, arrConfigRoute)\r\n}\r\n\r\nexport const FlowAddPrivateRoute = (arrConfigRoute = []) => {\r\n AddRoutes(RoutesPrivate, arrConfigRoute)\r\n}\r\n\r\nexport const FlowAddTestRoute = (arrConfigRoute = []) => {\r\n AddRoutes(RoutesTest, arrConfigRoute)\r\n}\r\n\r\nexport const FlowParseDataRoutes = (data, { forceChange } = {}) => {\r\n let _newData = []\r\n if (data && data.length > 0) {\r\n _newData = data.map((v, i) => {\r\n if (v.UIUrl && v.UIUrl.indexOf(\"[\") > -1) {\r\n v.UIUrl = v.UIUrl.replace(HRegex.RGSquareBracket, \":$1\")\r\n }\r\n FlowConvertUIType(v)\r\n if (v.Config && v.Config.indexOf(\"noSidebar\") > -1 && v.Id) {\r\n HRoutes.listIdNoSidebar[v.Id] = v.Id\r\n }\r\n return v\r\n })\r\n }\r\n return _newData\r\n}\r\n\r\nexport const HRoutes = {\r\n listIdNoSidebar: {},\r\n checkNoSidebar: configPage => {\r\n if (configPage && configPage.Id && HRoutes.listIdNoSidebar[configPage.Id]) {\r\n return true\r\n }\r\n return false\r\n },\r\n}\r\n\r\nconst ConvertType = {\r\n table: \"admin_table\",\r\n tab: \"admin_tab\",\r\n dashboard: \"admin_dashboard\",\r\n panel: \"admin_panel\",\r\n table_list: \"admin_table_list\",\r\n table_list_card: \"admin_table_list_card\",\r\n table_grid_card: \"admin_table_grid_card\",\r\n}\r\n\r\nexport const FlowConvertUIType = (configPage = {}) => {\r\n if (configPage.UIType === null || configPage.UIType === \"\") {\r\n configPage.UIType = \"Table\"\r\n }\r\n if (configPage.UIType && ConvertType[configPage.UIType.toLowerCase()]) {\r\n configPage.UIType = ConvertType[configPage.UIType.toLowerCase()]\r\n }\r\n // console.warn(\"convertUIType\", configPage)\r\n}\r\n\r\nwindow._Routes = {\r\n HRoutes,\r\n RoutesPublic,\r\n RoutesPrivate,\r\n RoutesTest,\r\n}\r\n","import { ApiGeneric } from \"src/services/apiServices\"\r\nimport { fnListUI } from \"src/helpers/fnList\"\r\nimport { HCF, HLink, HUtils } from \"@macashipo/mlib\"\r\nimport { isIphone } from \"../U\"\r\n\r\nexport const FlowApiPost = () => {}\r\n\r\nexport const FlowApiGet = () => {}\r\n\r\nexport const FlowApiGeneric = ({\r\n request,\r\n cbSuccess,\r\n cbError,\r\n cbFinal,\r\n ...rest\r\n} = {}) => {\r\n //v1\r\n ApiGeneric({\r\n request,\r\n successCallBack: response => {\r\n let _verAdmin = HCF.getCF(\"verAdmin\")\r\n if (_verAdmin != \"v5\") {\r\n fnListUI.fnShowToast(response.Msg)\r\n }\r\n if (cbSuccess) {\r\n cbSuccess(response)\r\n }\r\n if (cbFinal) {\r\n cbFinal({ response })\r\n }\r\n },\r\n errorCallBack: (error, response) => {\r\n if (cbError) {\r\n cbError(error, response)\r\n }\r\n if (cbFinal) {\r\n cbFinal({ error, response })\r\n }\r\n },\r\n ...rest,\r\n })\r\n}\r\n\r\nexport const FlowApiUpdateFields = ({\r\n row,\r\n apiController,\r\n apiName = \"UpdateFields\",\r\n multiObjUpdate,\r\n sharedRequestData = {},\r\n cbSuccess,\r\n cbError,\r\n} = {}) => {\r\n //v1\r\n ApiGeneric({\r\n request: {\r\n method: \"POST\",\r\n path: apiController,\r\n name: apiName,\r\n },\r\n data: {\r\n Id: row.Id,\r\n ProjectId: row.ProjectId,\r\n RequestData: sharedRequestData,\r\n Values: Object.keys(multiObjUpdate).map(v => {\r\n return {\r\n FieldName: v,\r\n NewValue: multiObjUpdate[v],\r\n }\r\n }),\r\n },\r\n successCallBack: response => {\r\n if (cbSuccess) {\r\n cbSuccess(response)\r\n }\r\n },\r\n errorCallBack: (error, response) => {\r\n if (cbError) {\r\n cbError(error, response)\r\n }\r\n },\r\n })\r\n}\r\n\r\nexport const FlowApiRefreshCache = () => {\r\n FlowApiGeneric({\r\n request: {\r\n method: \"POST\",\r\n path: \"Cache\",\r\n name: \"Refresh\",\r\n },\r\n data: {\r\n Id: \"ALL\",\r\n },\r\n cbSuccess: () => {\r\n // an di vì v1 ko reload\r\n // window.location.reload()\r\n },\r\n })\r\n}\r\n\r\n// 18/11/2023: Bo sung FullPathListName, FullPathName\r\nexport const FlowApiShowFullPath = ({\r\n response,\r\n configFullPath,\r\n target,\r\n autoOpenLink,\r\n linkOpen,\r\n} = {}) => {\r\n if (configFullPath) {\r\n let _target = target || \"_blank\"\r\n let _autoOpenLink = autoOpenLink != null ? autoOpenLink : false\r\n if (configFullPath.FullPathNewWindow === false) {\r\n _target = \"_self\"\r\n }\r\n let _isDownload = false\r\n if (configFullPath.FullPathDownload === true) {\r\n _isDownload = true\r\n }\r\n let _linkOpen = configFullPath.FullPath || linkOpen\r\n if (\r\n _linkOpen &&\r\n _linkOpen.indexOf(\"[\") > -1 &&\r\n _linkOpen.indexOf(\"]\") > -1\r\n ) {\r\n _linkOpen = HUtils.getTextWithData(_linkOpen, configFullPath)\r\n }\r\n if (_linkOpen) {\r\n if (_autoOpenLink === true) {\r\n if (isIphone()) {\r\n setTimeout(() => {\r\n HLink.openUrl(_linkOpen, _target)\r\n })\r\n } else {\r\n HLink.openUrl(_linkOpen, _target)\r\n }\r\n } else {\r\n fnListUI.fnshowDialog({\r\n title: configFullPath.FullPathTitle || \"Link\",\r\n msg: (\r\n
\r\n
{configFullPath.FullPathInfo}
\r\n \r\n {configFullPath.FullPathName || _linkOpen}\r\n \r\n
\r\n ),\r\n })\r\n }\r\n } else if (\r\n configFullPath.FullPathList &&\r\n configFullPath.FullPathList.length > 0\r\n ) {\r\n fnListUI.fnshowDialog({\r\n title: configFullPath.FullPathTitle || \"Links\",\r\n msg: (\r\n
\r\n
{configFullPath.FullPathInfo}
\r\n {configFullPath.FullPathList.map(v => {\r\n return (\r\n
\r\n \r\n {v}\r\n \r\n
\r\n )\r\n })}\r\n
\r\n ),\r\n })\r\n } else if (\r\n configFullPath.FullPathListName &&\r\n configFullPath.FullPathListName.length > 0\r\n ) {\r\n fnListUI.fnshowDialog({\r\n title: configFullPath.FullPathTitle || \"Links\",\r\n msg: (\r\n
\r\n {configFullPath.FullPathListName.map(v => {\r\n return (\r\n
\r\n
{v.FullPathInfo}
\r\n \r\n {v.FullPathName || v.FullPath}\r\n \r\n
\r\n )\r\n })}\r\n
\r\n ),\r\n })\r\n }\r\n }\r\n}\r\n","import { MyUIHelpers } from \"@macashipo/mlib\"\r\nexport default MyUIHelpers\r\n","import {\r\n MyIcon,\r\n HIs,\r\n HUtils,\r\n MyUI,\r\n HCF,\r\n HJson,\r\n HFormat,\r\n MyTableCell,\r\n HColor,\r\n} from \"@macashipo/mlib\"\r\nimport * as FlowTableExtraData from \"./TableExtraData\"\r\nimport * as FlowApi from \"./Api\"\r\nimport { ApiGeneric } from \"src/services/apiServices\"\r\nimport { fnListMyPage, fnListUI } from \"src/helpers/fnList\"\r\nimport {\r\n KConfigApp,\r\n KConfigModal,\r\n KConfigPageTable,\r\n KOnePageMore,\r\n kClientKeyUI,\r\n} from \"../K\"\r\nimport { FlowGetBoolOfMoreFromRow, KMTC } from \"./More\"\r\nimport { FlowTestResponseFullPath } from \"./Test\"\r\nimport { HUtils_getTextOrHTML } from \"./MNeedUpdateMLib\"\r\nexport const KMore = KMTC\r\nexport const KMoreOfTableCell = KMTC\r\n\r\nexport const KConfigInRow = {\r\n _UI_Loading: \"_UI_Loading\",\r\n _UI_Error: \"_UI_Error\",\r\n _UI_NeedUpdateUI: \"_UI_NeedUpdateUI\", //true: luon render lai ui\r\n}\r\n\r\nconst KTypeCellShared = {\r\n _cell_loading: \"_cell_loading\",\r\n}\r\n\r\nexport const FlowGetExtraDataFromExtra = (extra = {}) => {\r\n return extra.extraData || {}\r\n}\r\nexport const FlowGetFieldNameFromExtra = (extra = {}) => {\r\n return extra.fieldName\r\n}\r\nexport const FlowGetExtraOfFieldName = (extra = {}, fieldName) => {\r\n let _extraCol = extra\r\n if (fieldName && extra.fieldName != fieldName) {\r\n _extraCol = FlowTableExtraData.FlowGetColumnFromExtraData(\r\n FlowGetExtraDataFromExtra(extra),\r\n fieldName\r\n )\r\n }\r\n return _extraCol\r\n}\r\nexport const FlowGetMore = ({ extra, more, fieldName }) => {\r\n let _fieldName = fieldName || FlowGetFieldNameFromExtra(extra)\r\n return (\r\n more ||\r\n FlowTableExtraData.FlowGetMoreOfCellFromExtraData(\r\n FlowGetExtraDataFromExtra(extra),\r\n _fieldName\r\n )\r\n )\r\n}\r\n\r\n//////// More\r\nexport const FlowGetCanShow = ({\r\n extra,\r\n row,\r\n more,\r\n fieldName,\r\n defaultCanShow,\r\n}) => {\r\n let _canShow = defaultCanShow != null ? defaultCanShow : true\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n // console.log(\"FlowGetCanShow\")\r\n if (_more) {\r\n if (_canShow != _more[KMore.canShow]) {\r\n _canShow = _more[KMore.canShow]\r\n }\r\n if (\r\n _more[KMore.fCanShow] &&\r\n row[_more[KMore.fCanShow]] != null &&\r\n _canShow != row[_more[KMore.fCanShow]]\r\n ) {\r\n _canShow = row[_more[KMore.fCanShow]]\r\n }\r\n if (_more[KMore.hideOfIds] && _more[KMore.hideOfIds].indexOf(row.Id) > -1) {\r\n _canShow = false\r\n }\r\n }\r\n return _canShow\r\n}\r\nexport const FlowActionClickApi = ({ extra, more, fieldName }) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n}\r\nexport const FlowGetFValue = ({ extra, row, more, fieldName }) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.fValue]) {\r\n return row[_more[KMore.fValue]]\r\n }\r\n return \"Value\"\r\n}\r\nexport const FlowGetFText = ({ extra, row, more, fieldName }) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.fText]) {\r\n return row[_more[KMore.fText]]\r\n }\r\n return \"Text\"\r\n}\r\nexport const FlowActionClickForm = () => {}\r\nexport const FlowActionClickLink = ({ extra, row, more, fieldName, link }) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n let _link = link || FlowGetLink({ extra, row, more: _more, fieldName })\r\n if (_link) {\r\n window.open(\r\n _link,\r\n FlowGetLinkTarget({ extra, row, more: _more, fieldName })\r\n )\r\n }\r\n console.warn(\"Click link\", _link)\r\n}\r\n\r\n// 18/11/2023: Ngưng oneTableCell.parseResponse, chuyển qua FlowApi.FlowApiShowFullPath\r\nexport const FlowParseResponseAndNeedReload = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n oneTableCell,\r\n response,\r\n configApi,\r\n fnList,\r\n}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName }) || {}\r\n console.warn(\"parseResponse\", oneTableCell)\r\n if (oneTableCell) {\r\n let _configApi =\r\n configApi || oneTableCell.getConfigApi({ customMore: more })\r\n ////Test FlowTestResponseFullPath\r\n // FlowTestResponseFullPath(response)\r\n ////End Test\r\n //// oneTableCell.parseResponse(response) //chuyển qua FlowApi.FlowApiShowFullPath\r\n FlowApi.FlowApiShowFullPath({\r\n response: response,\r\n configFullPath: response.Data,\r\n autoOpenLink:\r\n _more[KMore.autoOpenLink] != null ? _more[KMore.autoOpenLink] : null,\r\n })\r\n //chua xu ly more.needReloadOptionsAndList ben trong nen chuyen ra ngoai xu ly\r\n // oneTableCell.parseNeedReload(_configApi, response)\r\n if (_configApi) {\r\n if (fnList) {\r\n if (_configApi.needReloadPage === true) {\r\n fnList.onReloadPage && fnList.onReloadPage()\r\n return\r\n }\r\n\r\n if (_configApi.needReloadOptionsAndList) {\r\n fnList.fnReloadOptionsAndList && fnList.fnReloadOptionsAndList()\r\n } else if (_configApi.needReloadList === true) {\r\n fnList.onReloadList && fnList.onReloadList()\r\n }\r\n\r\n if (_configApi.needSendMsg === true) {\r\n fnList.onSendMsg && fnList.onSendMsg(_configApi.needSendMsg)\r\n }\r\n if (_configApi.needReExpand === true) {\r\n fnList.onReExpand && fnList.onReExpand()\r\n }\r\n }\r\n\r\n if (\r\n _configApi.needReloadRow &&\r\n response &&\r\n response.Data &&\r\n response.Data.Id === row.Id\r\n ) {\r\n fnList.onUpdateRow &&\r\n fnList.onUpdateRow({\r\n row: row,\r\n newRow: response.Data,\r\n })\r\n }\r\n }\r\n }\r\n if (_more) {\r\n if (_more[KMore.needReloadOptionsAndListMain]) {\r\n let _fnReloadOptionsAndListOfMain = HUtils.get(\r\n fnList,\r\n \"fnListOfPage.fnListOfButton.fnListOfPage.fnReloadOptionsAndList\"\r\n )\r\n if (_fnReloadOptionsAndListOfMain) {\r\n _fnReloadOptionsAndListOfMain()\r\n }\r\n } else if (_more[KMore.needReloadListMain]) {\r\n let _fnReloadListOfMain = HUtils.get(\r\n fnList,\r\n \"fnListOfPage.fnListOfButton.fnListOfPage.fnReloadList\"\r\n )\r\n if (_fnReloadListOfMain) {\r\n _fnReloadListOfMain()\r\n }\r\n }\r\n }\r\n}\r\nexport const FlowCheckShowModal = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultValue,\r\n}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName }) || {}\r\n let _configModal = _more[KMore.modal]\r\n let _canShowModal = defaultValue != null ? defaultValue : true\r\n if (_configModal) {\r\n if (_configModal.canShowModal == false) {\r\n _canShowModal = false\r\n }\r\n if (\r\n _configModal.fCanShowModal &&\r\n row[_configModal.fCanShowModal] === false\r\n ) {\r\n _canShowModal = false\r\n }\r\n }\r\n return _canShowModal\r\n}\r\n\r\nexport const FlowGetRequestFromConfigObj = ({ row, configApi } = {}) => {\r\n let _configApi = configApi || {}\r\n let _request = {\r\n method: \"POST\" || _configApi.method,\r\n url: _configApi.url,\r\n path: _configApi.path,\r\n name: _configApi.name,\r\n }\r\n //for old style v1 request inside configApi\r\n if (_configApi.request) {\r\n _request = { ..._request, ..._configApi.request }\r\n }\r\n\r\n if (_request.url) {\r\n if (_request.url.indexOf(\"[\") > -1) {\r\n _request.url = HUtils.getTextWithData(_request.url, row)\r\n }\r\n }\r\n if (_request.name) {\r\n if (_request.name.indexOf(\"[\") > -1) {\r\n _request.name = HUtils.getTextWithData(_request.name, row)\r\n }\r\n }\r\n\r\n // console.log(\"_request:\", _request)\r\n return _request\r\n}\r\n\r\nexport const FlowGetRequestQueryFromConfigObj = ({\r\n row,\r\n query,\r\n queryByField,\r\n configApi,\r\n df,\r\n}) => {\r\n let _query = df || {}\r\n if (query) {\r\n _query = Object.assign(_query, query)\r\n let _keys = Object.keys(_query)\r\n for (let k of _keys) {\r\n let _value = query[k]\r\n if (row.hasOwnProperty(_value) == true) {\r\n if (row[_value] != null) {\r\n _query[k] = row[_value]\r\n }\r\n }\r\n }\r\n }\r\n //queryByField old v1 get from row only\r\n if (queryByField) {\r\n for (let k of Object.keys(queryByField)) {\r\n _query[k] = row[queryByField[k]]\r\n }\r\n }\r\n //\r\n if (configApi != null) {\r\n let _queryFromConfigApi = FlowGetRequestQueryFromConfigObj({\r\n row,\r\n query: configApi.query,\r\n queryByField: configApi.queryByField,\r\n })\r\n _query = { ..._query, ..._queryFromConfigApi }\r\n }\r\n return _query\r\n}\r\n\r\nexport const FlowCheckApiShowModal = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n cb,\r\n fnList,\r\n}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName }) || {}\r\n let _configCheckShow = _more[KMore.apiCheckShowModal]\r\n let _canShowModal = FlowCheckShowModal({ extra, more, row })\r\n //test\r\n // FlowApi.FlowApiShowFullPath({\r\n // response: {},\r\n // configFullPath: { FullPath: \"http://google.com\" },\r\n // })\r\n // cb({\r\n // canShow: true,\r\n // })\r\n // return\r\n //\r\n //clear focus button\r\n document.activeElement.blur()\r\n if (cb) {\r\n if (_canShowModal == false) {\r\n cb({\r\n canShow: false,\r\n })\r\n } else if (_configCheckShow) {\r\n let _request = FlowGetRequestFromConfigObj({\r\n row,\r\n configApi: _configCheckShow,\r\n })\r\n let _query = FlowGetRequestQueryFromConfigObj({\r\n row,\r\n query: _configCheckShow.query,\r\n })\r\n ApiGeneric({\r\n request: _request,\r\n data: _query,\r\n successCallBack: response => {\r\n let _config = HUtils.get(response, \"Data.Config\")\r\n if (_config) {\r\n FlowApi.FlowApiShowFullPath({\r\n response,\r\n configFullPath: _config,\r\n autoOpenLink:\r\n more[KMore.autoOpenLink] != null\r\n ? more[KMore.autoOpenLink]\r\n : null,\r\n })\r\n }\r\n if (_config && _config.IsShow) {\r\n //muc dinh khi click form -> update row -> show tren ui\r\n //pos -> user click btn -> chuyen tu order qua bill -> ko can show form\r\n let _resultModel = HUtils.get(response, \"Data.Config.ResultModel\")\r\n if (_resultModel && row) {\r\n //update model vao row\r\n HUtils.runFuntion(fnList, \"onUpdateRow\", [\r\n {\r\n row,\r\n newRow: _resultModel,\r\n },\r\n ])\r\n }\r\n if (cb) {\r\n cb({\r\n canShow: true,\r\n config: _config,\r\n data: _config.FormData,\r\n configFormFromServer: _config.ConfigForm, //chưa xài, chưa test, bổ sung sẵn\r\n })\r\n }\r\n } else {\r\n if (cb) {\r\n cb({\r\n canShow: false,\r\n })\r\n }\r\n }\r\n // oneButton.changeIsLoading(false)\r\n },\r\n errorCallBack: (error, response) => {\r\n // oneButton.changeIsLoading(false)\r\n if (cb) {\r\n cb({\r\n canShow: false,\r\n })\r\n }\r\n },\r\n })\r\n } else {\r\n cb({\r\n canShow: true,\r\n })\r\n }\r\n }\r\n return false\r\n}\r\nexport const FlowCheckConfirmMsg = ({ extra, more, row, fieldName, cb }) => {\r\n let _more = FlowGetMore({ extra, more, fieldName }) || {}\r\n let _confirmMsg = _more[KMore.confirmMsg]\r\n let _confirmTitle = _more[KMore.titleConfirm] || \"Confirm\"\r\n if (row && _more[KMore.fConfirmMsg] && row[_more[KMore.fConfirmMsg]]) {\r\n _confirmMsg = row[_more[KMore.fConfirmMsg]]\r\n }\r\n if (_confirmMsg) {\r\n fnListUI.fnshowConfirm({\r\n title: _confirmTitle,\r\n msg: _confirmMsg,\r\n onClickOK: () => {\r\n if (cb) {\r\n cb()\r\n }\r\n },\r\n })\r\n } else {\r\n if (cb) {\r\n cb()\r\n }\r\n }\r\n}\r\nexport const FlowGetConfigButton = ({ extra, more, row, fieldName }) => {\r\n let _configButton = {}\r\n let _more = FlowGetMore({ extra, more, fieldName }) || {}\r\n if (_more[KMore.button]) {\r\n _configButton = _more[KMore.button]\r\n }\r\n return _configButton || {}\r\n}\r\nexport const FlowGetMorePropsButton = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultValue,\r\n forceValue,\r\n}) => {\r\n let _moreProps = defaultValue || {}\r\n let _configButton = FlowGetConfigButton({ extra, more, row, fieldName }) || {}\r\n if (_configButton.style) {\r\n _moreProps.style = { ..._moreProps.style, ..._configButton.style }\r\n }\r\n if (HIs.isBoolean(_configButton.outline)) {\r\n _moreProps.outline = _configButton.outline\r\n }\r\n if (_configButton.color != null) {\r\n _moreProps.color = _configButton.color\r\n }\r\n if (_configButton.colorByValue != null) {\r\n if (row[fieldName]) {\r\n if (_configButton.colorByValue[row[fieldName]]) {\r\n _moreProps.color = _configButton.colorByValue[row[fieldName]]\r\n }\r\n }\r\n }\r\n if (_configButton.className != null) {\r\n _moreProps.className = _configButton.className\r\n }\r\n //titleTooltip\r\n // console.warn(\r\n // \"config titleTooltip:\",\r\n // more,\r\n // _configButton,\r\n // _configButton.titleTooltip\r\n // )\r\n if (_configButton.fTitleTooltip != null) {\r\n _moreProps.title = row[_configButton.fTitleTooltip] || \"\"\r\n } else if (_configButton.titleTooltip != null) {\r\n if (_configButton.titleTooltip.indexOf(\"[\") > -1) {\r\n _moreProps.title = HUtils.getTextWithData(_configButton.titleTooltip, row)\r\n } else {\r\n _moreProps.title = _configButton.titleTooltip\r\n }\r\n }\r\n if (HIs.isBoolean(_configButton.disabled)) {\r\n _moreProps.disabled = _configButton.disabled\r\n }\r\n if (_configButton.fDisabled != null) {\r\n if (typeof _configButton.fDisabled == \"boolean\") {\r\n _moreProps.disabled = _configButton.fDisabled\r\n } else if (row && typeof row[_configButton.fDisabled] == \"boolean\") {\r\n FlowUpdateRelativeByField({\r\n extra,\r\n fieldName,\r\n fEdit: _configButton.fDisabled,\r\n row,\r\n checkChange: true,\r\n })\r\n _moreProps.disabled = row[_configButton.fDisabled]\r\n }\r\n }\r\n if (forceValue) {\r\n _moreProps = { ..._moreProps, ...forceValue }\r\n }\r\n // console.log(\"FlowGetMorePropsButton\", _moreProps, more)\r\n return _moreProps\r\n}\r\nexport const FlowGetConfigMyUI = ({ extra, more, row, fieldName }) => {\r\n let _configMyUI = {}\r\n let _more = FlowGetMore({ extra, more, fieldName }) || {}\r\n if (_more[KMore.myui]) {\r\n _configMyUI = _more[KMore.myui]\r\n }\r\n return _configMyUI\r\n}\r\n//thay the TableHelper render icon\r\nexport const FlowRenderIconFromMore = ({\r\n extra,\r\n more,\r\n fieldName,\r\n isActive,\r\n}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n let _isActive = isActive !== false\r\n if (_more) {\r\n let _icon = _more[KMore.configIcon] || _more[KMore.icon]\r\n if (_icon) {\r\n if (HIs.isString(_icon)) {\r\n return \r\n } else if (HIs.isObject(_icon)) {\r\n if (_icon.hideWhenNoActive && _isActive == false) {\r\n return null\r\n }\r\n let _style = {\r\n ..._icon.style,\r\n ...(_isActive === false ? _icon.styleInactive : {}),\r\n }\r\n if (_icon.className) {\r\n return \r\n }\r\n }\r\n }\r\n }\r\n}\r\nexport const FlowGetScreenCodeFromCell = ({ extra, fnList }) => {\r\n if (extra && extra[\"_ScreenCode\"]) {\r\n return extra[\"_ScreenCode\"]\r\n }\r\n let _screenCode = fnListMyPage.fnGetScreenCode(fnList)\r\n if (_screenCode) {\r\n extra[\"_ScreenCode\"] = _screenCode\r\n }\r\n return _screenCode\r\n}\r\nexport const FlowGetTextOrHTMLWithI18n = (\r\n text,\r\n { extra, more, fieldName, fnList, from } = {}\r\n) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMTC.usingI18n]) {\r\n let _ns = FlowGetScreenCodeFromCell({ extra, fnList })\r\n return HUtils_getTextOrHTML(text, {\r\n usingI18n: true,\r\n ns: _ns,\r\n from: from || \"cell\",\r\n })\r\n }\r\n return text\r\n}\r\nexport const FlowGetTextDisplay = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n oneTableCell,\r\n cell,\r\n valueCell,\r\n isButton,\r\n}) => {\r\n if (oneTableCell) {\r\n let _configTextDisplay = { ...more }\r\n if (isButton) {\r\n _configTextDisplay = FlowGetConfigTextDisplayOfButton({\r\n row,\r\n extra,\r\n more,\r\n fieldName,\r\n })\r\n }\r\n // console.warn(\"_configTextDisplay:\", _configTextDisplay, row)\r\n //luu y truong hop muon display empty, nhung cell co gia tri thi hien tai lib dang tra ve gia tri cell\r\n return oneTableCell.getTextDisplay(_configTextDisplay)\r\n }\r\n return cell || valueCell\r\n}\r\n\r\nexport const FlowGetCustomDisplay = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n oneTableCell,\r\n props,\r\n value,\r\n defaultConfigDisplay,\r\n placeHolder,\r\n}) => {\r\n // console.log(\"FlowGetCustomDisplay\", placeHolder)\r\n if (more && more[KMore.showDisplayWithMyUI]) {\r\n const configMyUI = FlowGetConfigMyUI({ extra, more, fieldName })\r\n if (configMyUI && configMyUI.type) {\r\n return (\r\n
\r\n \r\n
\r\n )\r\n }\r\n }\r\n let _valueDisplay = value\r\n if (typeof value == \"string\") {\r\n let _configDisplay = more[KMore.configDisplay] || defaultConfigDisplay\r\n if (_configDisplay) {\r\n if (_configDisplay.showShortText) {\r\n let _countShort = _configDisplay.countShort || 50\r\n _valueDisplay = value.slice(0, _countShort)\r\n _valueDisplay += `${_valueDisplay.length == _countShort ? \"...\" : \"\"}`\r\n } else if (_configDisplay.text) {\r\n _valueDisplay = HUtils.getTextWithData(_configDisplay.text, row)\r\n } else if (_configDisplay.configFormat) {\r\n _valueDisplay = HFormat.format(_valueDisplay, {\r\n ..._configDisplay.configFormat,\r\n row: row,\r\n })\r\n } else if (_configDisplay.isHide) {\r\n _valueDisplay = \"\"\r\n }\r\n }\r\n }\r\n if ((placeHolder && _valueDisplay == null) || String(_valueDisplay) == \"\") {\r\n return (\r\n \r\n {placeHolder}\r\n \r\n )\r\n }\r\n return
{String(_valueDisplay)}
\r\n}\r\n\r\nexport const FlowGetConfigTextDisplayOfButton = ({\r\n row,\r\n extra,\r\n more,\r\n fieldName,\r\n}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n let _config = { ..._more, customMore: _more }\r\n if (_more) {\r\n let _configButton = more[KMore.button]\r\n if (_configButton) {\r\n if (_configButton.hasOwnProperty(\"icon\")) {\r\n _config.icon = _configButton.icon\r\n }\r\n if (\r\n _configButton.hasOwnProperty(\"iconByValue\") &&\r\n row &&\r\n row[fieldName]\r\n ) {\r\n _config.icon = _configButton.iconByValue[row[fieldName]]\r\n }\r\n if (_configButton.hasOwnProperty(\"title\")) {\r\n _config.title = _configButton.title\r\n }\r\n if (_configButton.hasOwnProperty(\"hasIconAndText\")) {\r\n _config.hasIconAndText = _configButton.hasIconAndText\r\n }\r\n }\r\n }\r\n return _config\r\n}\r\n\r\nexport const FlowRenderStatus = ({\r\n extra,\r\n more,\r\n fieldName,\r\n row,\r\n valueCell,\r\n link,\r\n canEdit,\r\n}) => {\r\n let _ui = []\r\n if (more) {\r\n if (\r\n more[KMore.configEditIcon] &&\r\n more[KMore.configEditIcon].using &&\r\n canEdit\r\n ) {\r\n _ui.push(\r\n \r\n )\r\n }\r\n }\r\n if (_ui.length > 0) {\r\n return
\r\n }\r\n}\r\n\r\nexport const FlowRenderTitleOfLink = ({\r\n extra,\r\n more,\r\n fieldName,\r\n row,\r\n valueCell,\r\n link,\r\n}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.showPhoto] === true) {\r\n let _maxHeight = \"120px\"\r\n let _maxWidth = \"120px\"\r\n if (_more[KMore.maxHeight]) {\r\n _maxHeight = _more[KMore.maxHeight]\r\n }\r\n if (_more[KMore.maxWidth]) {\r\n _maxWidth = _more[KMore.maxWidth]\r\n }\r\n let _styleImg = { width: \"100%\", height: \"100%\", maxHeight: _maxHeight }\r\n if (_more[KMore.noScale] == true) {\r\n _styleImg = {\r\n maxHeight: _maxHeight,\r\n display: \"block\",\r\n maxWidth: _maxWidth,\r\n width: \"auto\",\r\n height: \"auto\",\r\n }\r\n }\r\n if (_more[KMore.styleImg]) {\r\n _styleImg = Object.assign(_styleImg, _more[KMore.styleImg])\r\n }\r\n let _linkPhoto = link\r\n if (more[KMore.fPhoto]) {\r\n _linkPhoto = row[more[KMore.fPhoto]]\r\n }\r\n if (_linkPhoto) {\r\n return \"\"\r\n } else {\r\n return
\r\n }\r\n }\r\n let _uiIcon = FlowRenderIconFromMore({\r\n extra,\r\n more,\r\n fieldName,\r\n isActive: valueCell != null && valueCell != \"\",\r\n })\r\n if (_uiIcon) {\r\n return _uiIcon\r\n }\r\n let _title = valueCell\r\n if (_more[KMore.linkTitle]) {\r\n _title = _more[KMore.linkTitle]\r\n } else if (row && _more[KMore.fLinkTitle] && row[_more[KMore.fLinkTitle]]) {\r\n _title = row[_more[KMore.fLinkTitle]]\r\n }\r\n return _title\r\n}\r\n\r\nexport const FlowGetLinkTarget = ({ extra, more, fieldName }) => {\r\n let _target = \"_blank\"\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.newWindow] === true) {\r\n return \"_blank\"\r\n } else if (_more[KMore.newWindow] === false) {\r\n return \"_self\"\r\n }\r\n return _target\r\n}\r\n\r\nexport const FlowGetStyleInput = ({ extra, more, fieldName, defaultStyle }) => {\r\n let _styleInput = defaultStyle || {}\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.styleInput]) {\r\n _styleInput = { ..._styleInput, ..._more[KMore.styleInput] }\r\n }\r\n return _styleInput\r\n}\r\n\r\nexport const FlowGetMoreAttrsInput = ({\r\n extra,\r\n more,\r\n fieldName,\r\n defaultAttrs,\r\n}) => {\r\n let _attrs = defaultAttrs || {}\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.placeHolder]) {\r\n _attrs = Object.assign(_attrs, {\r\n placeholder: _more[KMore.placeHolder],\r\n })\r\n }\r\n return _attrs\r\n}\r\n\r\nexport const FlowGetLink = ({ extra, row, more, fieldName, valueCell }) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n let _link = valueCell\r\n if (extra && extra.Type && extra.Type.link) {\r\n _link = extra.Type.link\r\n }\r\n if (_more[KMore.fLink]) {\r\n if (row && row[_more[KMore.fLink]]) _link = row[_more[KMore.fLink]]\r\n else {\r\n _link = \"\"\r\n }\r\n } else if (_more[KMore.link]) {\r\n _link = _more[KMore.link]\r\n }\r\n if (_link && typeof _link == \"string\" && _link.indexOf(\"[\") > -1) {\r\n _link = HUtils.getTextWithData(_link, row)\r\n }\r\n return _link\r\n}\r\n\r\nexport const FlowGetHeaderTitle = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultValue,\r\n notUseFieldName,\r\n customTitle,\r\n} = {}) => {\r\n let _title = defaultValue || \"\"\r\n let _extraOfColumn = FlowGetExtraOfFieldName(extra, fieldName)\r\n // let _more = FlowGetMore({ extra, more, fieldName })\r\n // console.warn(\"FlowGetHeaderTitle\", _title)\r\n if (notUseFieldName !== true && _title == \"\") {\r\n _title = fieldName || extra.fieldName\r\n }\r\n if (_extraOfColumn.Header) {\r\n //for header json\r\n if (_extraOfColumn.Header.startsWith(\"{\")) {\r\n let _objHeader = HJson.getObj(_extraOfColumn.Header)\r\n _title = _objHeader.header || \"\"\r\n } else {\r\n _title = _extraOfColumn.Header\r\n }\r\n }\r\n if (customTitle) {\r\n return customTitle(_title)\r\n }\r\n return _title\r\n}\r\n\r\nexport const FlowGetTitleOfColumn = ({ extra, row, more, fieldName }) => {\r\n return FlowGetHeaderTitle({ extra, row, more, fieldName })\r\n}\r\n\r\n//Dung cho cac kieu title de hover show tooltip, button\r\nexport const FlowGetTitleTooltipOfColumn = ({\r\n extra,\r\n row,\r\n more,\r\n fieldName,\r\n title,\r\n fnList,\r\n}) => {\r\n let _title = title || FlowGetTitleOfColumn({ extra, fieldName })\r\n let _configTitleTooltip = FlowGetConfigOfMore({\r\n extra,\r\n row,\r\n fieldName,\r\n key: KMore.configTitleTooltip,\r\n })\r\n if (_configTitleTooltip) {\r\n if (_configTitleTooltip.fTitle != null) {\r\n _title = row[_configTitleTooltip.fTitle]\r\n } else if (_configTitleTooltip.title != null) {\r\n _title = HUtils.getTextWithData(_configTitleTooltip.title, row)\r\n }\r\n }\r\n return FlowGetTextOrHTMLWithI18n(_title, {\r\n extra,\r\n more,\r\n fieldName,\r\n fnList,\r\n from: \"ctt\",\r\n })\r\n}\r\n\r\nexport const FlowGetTableConfig = ({ extra, row, more, key, defaultValue }) => {\r\n let _fnList = FlowGetFnList({ extra, fieldName: extra.fieldName })\r\n if (_fnList) {\r\n let _value = null\r\n //v1\r\n if (_fnList.fnGetTableConfig) {\r\n _value = _fnList.fnGetTableConfig(key, defaultValue)\r\n } else {\r\n _value = fnListMyPage.fnGetConfigPageTable(_fnList, [key])\r\n }\r\n }\r\n}\r\nexport const FlowGetConfigTrueByAllLevel = ({ key, extra, row, more } = {}) => {\r\n const _configInTableConfig = FlowGetTableConfig({ extra, row, more, key })\r\n if (more && more[key] === true) {\r\n // console.warn(\"more:\",more)\r\n return true\r\n } else if (_configInTableConfig === true) {\r\n // console.warn(\"_configInTableConfig:\",_configInTableConfig)\r\n return true\r\n } else if (HCF.getCF(key) === true) {\r\n // console.warn(\"AppConfig:\",HConfig)\r\n return true\r\n }\r\n return false\r\n}\r\n\r\nexport const FlowGetBackgroundStyleCell = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultStyle,\r\n}) => {\r\n let _style = defaultStyle || {}\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.style]) {\r\n _style = { ..._style, ..._more[KMore.style] }\r\n }\r\n if (extra != null && row != null) {\r\n if (extra.Type) {\r\n //style from bgF\r\n if (extra.Type.bgF != null) {\r\n if (row[extra.Type.bgF] != null) {\r\n // let _color = HColor.getTextWB(row[extra.Type.bgF]);\r\n _style = Object.assign(_style, { background: row[extra.Type.bgF] })\r\n } else if (\r\n extra.Type.bgF.startsWith(\"#\") ||\r\n extra.Type.bgF.startsWith(\"linear-gradient\")\r\n ) {\r\n // let _color = HColor.getTextWB(extra.Type.bgF);\r\n _style = Object.assign(_style, { background: extra.Type.bgF })\r\n }\r\n }\r\n }\r\n }\r\n // console.warn(\"FlowGetBackgroundStyleCell:\", _style)\r\n return _style.background\r\n}\r\n\r\nexport const FlowGetStyleControlOfCell = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n styleWrap,\r\n defaultStyle,\r\n typeControl,\r\n}) => {\r\n let _style = { ...defaultStyle }\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (typeControl == \"textarea\" && _more[KMore.styleTextarea]) {\r\n _style = { ..._style, ..._more[KMore.styleTextarea] }\r\n } else if (typeControl == \"input\" && _more[KMore.styleInput]) {\r\n _style = { ..._style, ..._more[KMore.styleInput] }\r\n } else if (_more[KMore.styleControl]) {\r\n _style = { ..._style, ..._more[KMore.styleControl] }\r\n }\r\n //style Inherit\r\n if (_more[KMTC.styleInherit] && styleWrap) {\r\n if (_more[KMTC.styleInherit] === true) {\r\n _style = { ..._style, ...styleWrap }\r\n } else if (Array.isArray(_more[KMTC.styleInherit])) {\r\n for (let k of _more[KMTC.styleInherit]) {\r\n if (styleWrap[k]) {\r\n _style[k] = styleWrap[k]\r\n }\r\n }\r\n }\r\n }\r\n return _style\r\n}\r\nexport const FlowGetStyleCell = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultStyle,\r\n overideStyle,\r\n oneTableCell,\r\n}) => {\r\n let _styleDefaultCell = HCF.getCF(KConfigApp.styleDefaultCell)\r\n let _style = { ..._styleDefaultCell, ...defaultStyle }\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.style]) {\r\n _style = { ..._style, ..._more[KMore.style] }\r\n }\r\n if (extra != null && row != null) {\r\n let _styleInRow = null\r\n //from row.StyleRow\r\n if (row && row.StyleRow) {\r\n _styleInRow = row.StyleRow\r\n }\r\n //from row.UI_StyleRow\r\n if (row && row.UI_StyleRow) {\r\n _styleInRow = row.UI_StyleRow\r\n }\r\n if (_styleInRow) {\r\n if (typeof _styleInRow == \"object\") {\r\n _style = Object.assign(_style, _styleInRow)\r\n } else if (HIs.isJsonString(_styleInRow)) {\r\n _style = Object.assign(_style, HJson.getObj(_styleInRow))\r\n }\r\n }\r\n\r\n //from extra.Style\r\n if (extra.Style) {\r\n if (HIs.isJsonString(extra.Style)) {\r\n _style = { ..._style, ...HJson.getObj(extra.Style) }\r\n } else if (HIs.isObject(extra.Style)) {\r\n _style = { ..._style, ...extra.Style }\r\n }\r\n }\r\n if (extra.Type) {\r\n //style from bgF\r\n if (extra.Type.bgF != null) {\r\n if (row[extra.Type.bgF] != null) {\r\n // let _color = HColor.getTextWB(row[extra.Type.bgF]);\r\n let _s = {\r\n background: row[extra.Type.bgF],\r\n }\r\n // console.log(\"_s:\", _s)\r\n if (_more[KMore.autoTextWB] == true) {\r\n _s.color = HColor.getTextWB(_s.background)\r\n }\r\n _style = Object.assign(_style, _s)\r\n } else if (\r\n extra.Type.bgF.startsWith(\"#\") ||\r\n extra.Type.bgF.startsWith(\"linear-gradient\")\r\n ) {\r\n // let _color = HColor.getTextWB(extra.Type.bgF);\r\n _style = Object.assign(_style, { background: extra.Type.bgF })\r\n }\r\n }\r\n //style from colorF\r\n if (extra.Type.colorF != null) {\r\n if (row[extra.Type.colorF] != null) {\r\n _style = Object.assign(_style, { color: row[extra.Type.colorF] })\r\n } else if (extra.Type.colorF.startsWith(\"#\")) {\r\n _style = Object.assign(_style, { color: extra.Type.colorF })\r\n }\r\n }\r\n }\r\n }\r\n //bo sung styleDisabled\r\n if (_more[KMore.styleDisabled]) {\r\n _style = Object.assign(_style, _more[KMore.styleDisabled])\r\n }\r\n\r\n //styleByValue\r\n // console.warn(\"styleByValue 1\",extra.Type,_more,_more[KMore.styleByValue])\r\n if (_more[KMore.styleByValue]) {\r\n // console.warn(\"styleByValue\",_more[KMore.styleByValue])\r\n let _fieldName = fieldName || FlowGetFieldNameFromExtra(extra)\r\n let _valueCell = row[_fieldName]\r\n if (HFormat.Types.configByValue) {\r\n let _moreStyle = HFormat.format(_valueCell, {\r\n type: \"configByValue\",\r\n configByValue: _more[KMore.styleByValue],\r\n })\r\n if (_moreStyle) {\r\n _style = Object.assign(_style, _moreStyle)\r\n }\r\n }\r\n }\r\n //bo sung cho dep\r\n if (\r\n _more[KMore.fBorderLeftColor] &&\r\n row[_more[KMore.fBorderLeftColor]] &&\r\n _style\r\n ) {\r\n _style.borderLeft = `4px solid ${row[_more[KMore.fBorderLeftColor]]}`\r\n }\r\n\r\n //bo sung overideStyle\r\n if (overideStyle) {\r\n _style = { ..._style, ...overideStyle }\r\n }\r\n return _style\r\n}\r\n\r\nexport const FlowGetClassCell = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultClass,\r\n}) => {\r\n let _className = defaultClass || \"\"\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n //class from extra\r\n if (extra.ClassName) {\r\n _className += ` ${extra.ClassName}`\r\n }\r\n //class from more\r\n if (_more[KMore.className]) {\r\n _className += ` ${_more[KMore.className]}`\r\n }\r\n //class fieldName\r\n if (extra.fieldName) {\r\n if (\r\n FlowGetConfigTrueByAllLevel({\r\n key: KConfigApp.showClassFieldOnCell,\r\n extra,\r\n row,\r\n more: _more,\r\n })\r\n ) {\r\n _className += ` col-${extra.fieldName}`\r\n } else if (_more.classNameWithColField != null) {\r\n if (_more.classNameWithColField === true) {\r\n _className += ` col-${extra.fieldName}`\r\n } else {\r\n _className += ` ${_more.classNameWithColField}-${extra.fieldName}`\r\n }\r\n }\r\n }\r\n return _className\r\n}\r\n\r\nexport const FlowGetCanEdit = ({ extra, row, more, fieldName } = {}) => {\r\n let _canEdit = true\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n //check row locked\r\n if (row && row.IsLocked === true) {\r\n return false\r\n }\r\n //check extraColumn.CanEdit\r\n let _extraCol = extra\r\n if (_extraCol) {\r\n if (fieldName && extra.fieldName != fieldName) {\r\n _extraCol = FlowTableExtraData.FlowGetColumnFromExtraData(\r\n FlowGetExtraDataFromExtra(extra),\r\n fieldName\r\n )\r\n if (_extraCol && _extraCol.CanEdit != null) {\r\n _canEdit = _extraCol.CanEdit\r\n }\r\n } else if (_extraCol.CanEdit != null) {\r\n _canEdit = _extraCol.CanEdit\r\n }\r\n }\r\n //check more.fCanEdit more.canEditF\r\n if (_canEdit == true) {\r\n if (_more.fCanEdit == null && _more.canEditF != null) {\r\n _more.fCanEdit = _more.canEditF\r\n }\r\n if (typeof _more.fCanEdit === \"boolean\") {\r\n _canEdit = _more.fCanEdit\r\n } else if (typeof _more.fCanEdit === \"string\") {\r\n if (_more.fCanEdit.length > 0) {\r\n FlowUpdateRelativeByField({\r\n extra,\r\n fieldName,\r\n fEdit: _more.fCanEdit,\r\n row,\r\n checkChange: true,\r\n })\r\n if (row[_more.fCanEdit] != null) {\r\n _canEdit = row[_more.fCanEdit]\r\n } else if (_more.fCanEdit.indexOf(\",\") > -1) {\r\n let _arrcanEditF = _more.fCanEdit.split(\",\")\r\n if (_arrcanEditF && _arrcanEditF.length > 0) {\r\n for (let f of _arrcanEditF) {\r\n if (row[f] == false) {\r\n //only need one cannot edit -> cannot edit\r\n _canEdit = false\r\n break\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n //check more.lockF more.fLock\r\n if (_more.lockF != null || _more.fLock != null) {\r\n let _fLock = _more.lockF || _more.fLock\r\n if (typeof _fLock == \"boolean\") {\r\n _canEdit = !_fLock\r\n } else if (typeof _fLock == \"string\") {\r\n if (_fLock.length > 0) {\r\n FlowUpdateRelativeByField({\r\n extra,\r\n fieldName,\r\n fEdit: _fLock,\r\n row,\r\n checkChange: true,\r\n })\r\n if (row[_fLock] != null) {\r\n _canEdit = !row[_fLock]\r\n } else if (_fLock.indexOf(\",\") > -1) {\r\n let _arrLock = _fLock.split(\",\")\r\n if (_arrLock && _arrLock.length > 0) {\r\n for (let f of _arrLock) {\r\n if (row[f] == true) {\r\n //only need one lock edit -> cannot edit\r\n _canEdit = false\r\n break\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return _canEdit\r\n}\r\n\r\nexport const FlowUpdateRelativeByField = ({\r\n extra,\r\n fieldName,\r\n fEdit,\r\n row,\r\n checkChange,\r\n} = {}) => {\r\n if (extra && extra.extraData) {\r\n if (extra.extraData[kClientKeyUI._RelativeByField] == null) {\r\n extra.extraData[kClientKeyUI._RelativeByField] = {}\r\n }\r\n if (extra.extraData[kClientKeyUI._RelativeByField]) {\r\n if (extra.extraData[kClientKeyUI._RelativeByField][fEdit] == null) {\r\n extra.extraData[kClientKeyUI._RelativeByField][fEdit] = []\r\n }\r\n if (\r\n extra.extraData[kClientKeyUI._RelativeByField][fEdit] &&\r\n extra.extraData[kClientKeyUI._RelativeByField][fEdit].indexOf(\r\n fieldName\r\n ) == -1\r\n ) {\r\n extra.extraData[kClientKeyUI._RelativeByField][fEdit].push(fieldName)\r\n }\r\n }\r\n }\r\n if (row && checkChange == true) {\r\n let _fielsEffect =\r\n HUtils.get(row, `_UI_CheckChange.${fEdit}.fielsEffect`) || []\r\n if (_fielsEffect.indexOf(fieldName) == -1) {\r\n _fielsEffect.push(fieldName)\r\n }\r\n row[`_UI_CheckChange`] = {\r\n ...row[`_UI_CheckChange`],\r\n [fEdit]: {\r\n value: row[fEdit],\r\n fielsEffect: _fielsEffect,\r\n },\r\n }\r\n }\r\n // console.warn(\"FlowUpdateRelativeByField:\", extra, row)\r\n}\r\n\r\nexport const FlowGetConfigOfMore = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n key,\r\n defaultValue,\r\n fKey,\r\n} = {}) => {\r\n let _value = defaultValue\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (fKey && _more.hasOwnProperty(fKey) && row[_more.hasOwnProperty(fKey)]) {\r\n _value = row[_more.hasOwnProperty(fKey)]\r\n } else if (_more.hasOwnProperty(key)) {\r\n _value = _more[key]\r\n }\r\n return _value\r\n}\r\n\r\nexport const FlowGetConfigModal = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultValue,\r\n} = {}) => {\r\n let _configModal = FlowGetConfigOfMore({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n key: KMore.modal,\r\n defaultValue: defaultValue || {},\r\n })\r\n if (\r\n _configModal[KConfigModal.fTitle] &&\r\n row[_configModal[KConfigModal.fTitle]]\r\n ) {\r\n _configModal.title = row[_configModal[KConfigModal.fTitle]]\r\n delete _configModal[KConfigModal.fTitle] //xoa fTitle trong _configModal\r\n }\r\n if (more && more[KMTC.usingI18n] && _configModal.title) {\r\n _configModal.title = FlowGetTextOrHTMLWithI18n(_configModal.title, {\r\n extra,\r\n more,\r\n fieldName,\r\n fnList: null,\r\n from: \"modal\",\r\n })\r\n }\r\n return _configModal\r\n}\r\n\r\nexport const FlowClickToSelectInput = ({ extra, fieldName, more, ev } = {}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (ev && ev.target && _more && _more[KMore.clickToSelect] === true) {\r\n ev.target.select()\r\n }\r\n}\r\n\r\nexport const FlowGetDateFormat = ({\r\n extra,\r\n fieldName,\r\n more,\r\n keyConfig,\r\n defaultFormat,\r\n} = {}) => {\r\n // console.warn(\"FlowGetDateFormat\", fieldName)\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n let _formatFromKeyConfig = null\r\n if (keyConfig) {\r\n _formatFromKeyConfig = HCF.getCF(keyConfig)\r\n }\r\n let _format =\r\n _more[KMore.dateFormat] ||\r\n _more[KMore.format] ||\r\n _formatFromKeyConfig ||\r\n defaultFormat ||\r\n HCF.getCF(KConfigApp.dateFormat)\r\n return _format\r\n}\r\n\r\nexport const FlowGetDateTimeFormat = ({\r\n extra,\r\n fieldName,\r\n more,\r\n keyConfig,\r\n defaultFormat,\r\n} = {}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n let _formatFromKeyConfig = null\r\n if (keyConfig) {\r\n _formatFromKeyConfig = HCF.getCF(keyConfig)\r\n }\r\n let _format =\r\n _more[KMore.dateFormat] ||\r\n _more[KMore.format] ||\r\n _formatFromKeyConfig ||\r\n defaultFormat ||\r\n HCF.getCF(KConfigApp.datetimeFormat)\r\n return _format\r\n}\r\n\r\nexport const FlowGetColor = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n defaultColor,\r\n} = {}) => {\r\n let _color = defaultColor || \"gray\"\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMore.fColor] && row && row[_more[KMore.fColor]]) {\r\n _color = row[_more[KMore.fColor]]\r\n } else if (_more[KMore.color]) {\r\n _color = _more[KMore.color]\r\n }\r\n return _color\r\n}\r\n\r\nexport const FlowGetFnList = ({ extra, fieldName } = {}) => {\r\n let _extraCol = FlowGetExtraOfFieldName(extra, fieldName)\r\n if (_extraCol.fnList) {\r\n return _extraCol.fnList\r\n } else if (extra.fnList) {\r\n return extra.fnList\r\n }\r\n return {}\r\n}\r\n\r\nexport const FlowGetIsUpdatingCell = ({ extra, row, fieldName } = {}) => {\r\n let _fieldName = fieldName || FlowGetFieldNameFromExtra(extra)\r\n if (\r\n row &&\r\n row[KConfigInRow._UI_Loading] &&\r\n row[KConfigInRow._UI_Loading][_fieldName] === true\r\n ) {\r\n return true\r\n }\r\n return false\r\n}\r\n\r\nexport const FlowAfterUpdateCell = ({\r\n row,\r\n response,\r\n fieldName,\r\n fnList,\r\n forceNeedReload,\r\n}) => {\r\n ////show msg da show o trong api nen ko can show nua\r\n //// fnListUI.fnShowToast(response.Msg)\r\n\r\n //update new Data to row\r\n if (response && response.Data && response.Data.Id == row.Id) {\r\n row[KConfigInRow._UI_NeedUpdateUI] = true //de table cell render lai\r\n // //Test\r\n // if (window._testOne !== true) {\r\n // response.Data.ActiveFrom_UTC = null\r\n // window._testOne = true\r\n // }\r\n\r\n HUtils.mergeObjIfExist(row, response.Data)\r\n }\r\n //remove row UI loading, error\r\n if (row[KConfigInRow._UI_Loading] != null) {\r\n delete row[KConfigInRow._UI_Loading][fieldName]\r\n }\r\n if (row[KConfigInRow._UI_Error] != null) {\r\n delete row[KConfigInRow._UI_Error][fieldName]\r\n }\r\n\r\n let _arrFieldNeedReload = []\r\n let _fieldNeedReload = fnListMyPage.fnGetConfigPageTable(fnList, [\r\n KConfigPageTable.needReloadAfterUpdateFields,\r\n ])\r\n if (typeof _fieldNeedReload == \"string\") {\r\n _arrFieldNeedReload.push(_fieldNeedReload)\r\n } else if (Array.isArray(_fieldNeedReload)) {\r\n _arrFieldNeedReload = [..._fieldNeedReload]\r\n }\r\n if (forceNeedReload === true || _arrFieldNeedReload.indexOf(fieldName) > -1) {\r\n console.warn(\"RELOAD after update field\", fnList)\r\n fnListMyPage.fnReloadList(fnList, [])\r\n } else if (forceNeedReload == \"optionslist\") {\r\n fnListMyPage.fnReloadOptionsAndList(fnList, [])\r\n }\r\n}\r\n\r\nexport const FlowUpdateCell = ({\r\n extra,\r\n more,\r\n row,\r\n fieldName,\r\n newValue,\r\n alwaysUpdate,\r\n fnForceUpdateCell,\r\n fnSuccessCallBack,\r\n forceNeedReload,\r\n} = {}) => {\r\n let _fieldName = fieldName || FlowGetFieldNameFromExtra(extra)\r\n let _valueCell = row[_fieldName]\r\n let _fnList = FlowGetFnList({ extra, fieldName })\r\n // let _extraCol = FlowGetExtraOfFieldName(extra,fieldName)\r\n //lay fnRequestUpdate\r\n // let _fnRequestUpdate = _fnList.fnRequestUpdate;\r\n // if(_extraCol.fnRequestUpdate){\r\n // _fnRequestUpdate = _extraCol.fnRequestUpdate;\r\n // }\r\n // console.warn(\"FlowUpdateCell:\",_valueCell,\"[new]:\",newValue,_fnRequestUpdate)\r\n\r\n //init UILoading,Error o row\r\n if (row[KConfigInRow._UI_Loading] == null) {\r\n row[KConfigInRow._UI_Loading] = {}\r\n }\r\n if (row[KConfigInRow._UI_Error] == null) {\r\n row[KConfigInRow._UI_Error] = {}\r\n }\r\n\r\n let _canUpdate = false\r\n //kiem tra co update dc ko\r\n if (newValue != _valueCell && !(_valueCell == null && newValue == \"\")) {\r\n _canUpdate = true\r\n } else if (newValue == _valueCell) {\r\n if (\r\n row[KConfigInRow._UI_Error] &&\r\n row[KConfigInRow._UI_Error][_fieldName] != null\r\n ) {\r\n _canUpdate = true\r\n } else if (alwaysUpdate == true) {\r\n _canUpdate = true\r\n }\r\n console.warn(\"New Update = current value cell:\", newValue, _valueCell)\r\n }\r\n //tien hanh update\r\n if (_canUpdate) {\r\n console.warn(\"Need Update:\", newValue, _fnList)\r\n //gan gia tri updating vao row\r\n if (row[KConfigInRow._UI_Loading] != null) {\r\n row[KConfigInRow._UI_Loading][_fieldName] = true\r\n }\r\n\r\n //loading update\r\n if (fnForceUpdateCell) {\r\n fnForceUpdateCell()\r\n }\r\n\r\n //Bo sung goi request update neu truyen tu ben ngoai vao, mot so man hinh cu van su dung, de update detail\r\n if (extra.fnRequestUpdate) {\r\n extra.fnRequestUpdate(row, _fieldName, newValue, {\r\n fnUpdateUILoading: (isLoading, opts) => {\r\n if (row[KConfigInRow._UI_Loading] == null) {\r\n row[KConfigInRow._UI_Loading] = {}\r\n }\r\n if (row[KConfigInRow._UI_Loading] != null) {\r\n row[KConfigInRow._UI_Loading][_fieldName] = isLoading\r\n }\r\n if (opts && opts.component && opts.component.forceUpdate) {\r\n opts.component.forceUpdate()\r\n }\r\n if (fnForceUpdateCell) {\r\n fnForceUpdateCell()\r\n }\r\n },\r\n fnUpdateUIError: (msg, opts) => {\r\n if (row[KConfigInRow._UI_Error] == null) {\r\n row[KConfigInRow._UI_Error] = {}\r\n }\r\n if (msg == null) {\r\n //msg == null nghia la xoa error di\r\n delete row[KConfigInRow._UI_Error][_fieldName]\r\n } else {\r\n row[KConfigInRow._UI_Error][_fieldName] = {\r\n msg: msg,\r\n }\r\n }\r\n // console.warn(\"fnUpdateUIError\",msg,fieldName,row,opts,component);\r\n if (opts && opts.component && opts.component.forceUpdate) {\r\n opts.component.forceUpdate()\r\n }\r\n if (fnForceUpdateCell) {\r\n fnForceUpdateCell()\r\n }\r\n },\r\n fnSuccessCallBack: (response, opts) => {\r\n if (fnSuccessCallBack) {\r\n fnSuccessCallBack(response, opts)\r\n }\r\n },\r\n })\r\n } else {\r\n //goi ham request update\r\n FlowApi.FlowApiUpdateFields({\r\n row,\r\n apiController: fnListMyPage.fnGetApiPath(_fnList) || \"NoApiPath\",\r\n sharedRequestData: fnListMyPage.fnGetSharedRequestData(_fnList),\r\n multiObjUpdate: {\r\n [_fieldName]: newValue,\r\n },\r\n cbSuccess: response => {\r\n console.warn(\"success:\", response)\r\n FlowAfterUpdateCell({\r\n row,\r\n response,\r\n fieldName: _fieldName,\r\n fnList: _fnList,\r\n forceNeedReload,\r\n })\r\n\r\n //force update cell\r\n if (fnForceUpdateCell) {\r\n fnForceUpdateCell()\r\n }\r\n //forece update table de update row khac neu co su thay doi\r\n fnListMyPage.fnForceUpdateTable(_fnList)\r\n },\r\n cbError: (error, response) => {\r\n console.warn(\"error:\", error, response)\r\n if (fnForceUpdateCell) {\r\n fnForceUpdateCell()\r\n }\r\n //remove row UI loading, update error\r\n if (row[KConfigInRow._UI_Loading] != null) {\r\n delete row[KConfigInRow._UI_Loading][_fieldName]\r\n }\r\n if (row[KConfigInRow._UI_Error] != null) {\r\n row[KConfigInRow._UI_Error][_fieldName] = error || response.Msg\r\n }\r\n //force update cell\r\n if (fnForceUpdateCell) {\r\n fnForceUpdateCell()\r\n }\r\n },\r\n })\r\n }\r\n }\r\n}\r\n\r\nexport const FlowGetQueryFromConfigQuery = ({ row, configQuery } = {}) => {\r\n let _newQuery = {}\r\n if (configQuery && row) {\r\n let _keys = Object.keys(configQuery)\r\n if (_keys && _keys.length > 0) {\r\n for (let k of _keys) {\r\n if (\r\n HIs.isString(configQuery[k]) &&\r\n row.hasOwnProperty(configQuery[k])\r\n ) {\r\n _newQuery[k] = row[configQuery[k]]\r\n } else {\r\n _newQuery[k] = configQuery[k]\r\n }\r\n }\r\n }\r\n }\r\n return _newQuery\r\n}\r\n\r\nexport const FlowRenderLoading = ({ extra, row, fieldName, uiLoading }) => {\r\n if (FlowGetIsUpdatingCell({ extra, row, fieldName }) === true) {\r\n if (uiLoading) {\r\n return uiLoading\r\n }\r\n return \r\n }\r\n}\r\n\r\nexport const FlowRenderOverlay = ({ extra, row, fieldName, uiLoading }) => {\r\n //render loading, error, addable, infomation, clear\r\n}\r\n\r\nexport const FlowCheckUpdateValueAfterWillReceiveProps = (\r\n props,\r\n nextProps,\r\n valueDefault = \"\"\r\n) => {\r\n const { cell, row, extra } = props\r\n const newCell = nextProps.cell\r\n if (row && extra && row._UI_NeedUpdate) {\r\n let _fieldName = extra.fieldName\r\n if (_fieldName && row._UI_NeedUpdate.hasOwnProperty(_fieldName)) {\r\n let _value = row._UI_NeedUpdate[_fieldName]\r\n delete row._UI_NeedUpdate[_fieldName]\r\n return {\r\n needUpdate: true,\r\n value: _value,\r\n }\r\n }\r\n }\r\n if (newCell != null && cell != null && newCell != cell) {\r\n return {\r\n needUpdate: true,\r\n value: newCell,\r\n }\r\n } else if (cell == null && newCell != cell) {\r\n return {\r\n needUpdate: true,\r\n value: newCell,\r\n }\r\n } else if (newCell == null && newCell != cell) {\r\n return {\r\n needUpdate: true,\r\n value: valueDefault,\r\n }\r\n }\r\n return {\r\n needUpdate: false,\r\n newCell: newCell,\r\n }\r\n}\r\n\r\nexport const FlowAddNeedUpdateUIByFields = ({\r\n extra,\r\n row,\r\n fieldNeedUpdate,\r\n}) => {\r\n if (row) {\r\n let _UI_NeedUpdateUIByFields = row[\"_UI_NeedUpdateUIByFields\"] || []\r\n if (_UI_NeedUpdateUIByFields.indexOf(fieldNeedUpdate) == -1) {\r\n _UI_NeedUpdateUIByFields.push(fieldNeedUpdate)\r\n }\r\n row[\"_UI_NeedUpdateUIByFields\"] = _UI_NeedUpdateUIByFields\r\n }\r\n}\r\nexport const FlowUpdateOtherFieldRelative = ({\r\n extra,\r\n row,\r\n newRow,\r\n fieldName,\r\n more,\r\n relativeOfField,\r\n}) => {\r\n // console.error(\"FlowUpdateOtherFieldRelative:\", extra, relativeOfField)\r\n if (row) {\r\n let _more = FlowGetMore({ extra, more, fieldName }) || {}\r\n let _UI_NeedUpdateUIByFields = row[\"_UI_NeedUpdateUIByFields\"] || []\r\n if (Array.isArray(_UI_NeedUpdateUIByFields)) {\r\n if (\r\n _more[KMore.updateUIRelative] &&\r\n _more[KMore.updateUIRelative].split\r\n ) {\r\n let _arr = _more[KMore.updateUIRelative].split(\",\")\r\n for (let k of _arr) {\r\n _UI_NeedUpdateUIByFields.push(k)\r\n }\r\n }\r\n //by check fCanEdit\r\n if (relativeOfField && Array.isArray(relativeOfField)) {\r\n for (let k of relativeOfField) {\r\n _UI_NeedUpdateUIByFields.push(k)\r\n }\r\n }\r\n //test\r\n // _UI_NeedUpdateUIByFields.push(\"Value\")\r\n }\r\n if (row[\"_UI_CheckChange\"] && newRow != null) {\r\n console.warn(\"_UI_CheckChange:\", row)\r\n for (let k of Object.keys(row[\"_UI_CheckChange\"])) {\r\n let _f = k\r\n if (row[\"_UI_CheckChange\"][k].value != newRow[k]) {\r\n row[\"_UI_CheckChange\"][k].value = newRow[k]\r\n if (\r\n Array.isArray(row[\"_UI_CheckChange\"][k].fielsEffect) &&\r\n row[\"_UI_CheckChange\"][k].fielsEffect.length > 0\r\n ) {\r\n for (let f of row[\"_UI_CheckChange\"][k].fielsEffect) {\r\n if (_UI_NeedUpdateUIByFields.indexOf(f) == -1) {\r\n _UI_NeedUpdateUIByFields.push(f)\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n row[\"_UI_NeedUpdateUIByFields\"] = _UI_NeedUpdateUIByFields\r\n // console.warn(\"_UI_NeedUpdateUIByFields:\")\r\n }\r\n}\r\n\r\nexport const FlowGetCustomDefaultValueFromRow = ({\r\n row,\r\n custom, //{\"fForm\":\"fRow\"}\r\n}) => {\r\n let _defaultValues = {}\r\n if (row && custom) {\r\n for (let k of Object.keys(custom)) {\r\n _defaultValues[k] = row[custom[k]]\r\n }\r\n }\r\n return _defaultValues\r\n}\r\n\r\nexport const FlowGetDefaultValueFromRow = ({ row, more, dataFromApi }) => {\r\n //uu tien data tu checkapishowmodal\r\n if (dataFromApi != null) {\r\n return dataFromApi\r\n }\r\n let _defaultValuesForm = row\r\n if (more[KMore.customDefaultValues]) {\r\n //dung cho viec muon co defaultValue nhung chi vai field cua row\r\n _defaultValuesForm = FlowGetCustomDefaultValueFromRow({\r\n row,\r\n custom: more[KMore.customDefaultValues],\r\n })\r\n } else if (more[KMore.fDefaultValues]) {\r\n if (more[KMore.fDefaultValues] == \"row\") {\r\n _defaultValuesForm = { ...row }\r\n } else if (row[more[KMore.fDefaultValues]]) {\r\n _defaultValuesForm = row[more[KMore.fDefaultValues]]\r\n } else {\r\n _defaultValuesForm = {}\r\n }\r\n } else if (more[KMore.fDefaultValues] === null) {\r\n _defaultValuesForm = {}\r\n }\r\n //dung de loai tru mot so field\r\n if (more[KMore.excludeDefaultValues]) {\r\n let _newDefaulValues = {\r\n ..._defaultValuesForm,\r\n }\r\n for (let k of more[KMore.excludeDefaultValues]) {\r\n delete _newDefaulValues[k]\r\n }\r\n _defaultValuesForm = _newDefaulValues\r\n }\r\n return _defaultValuesForm\r\n}\r\n\r\nexport const FlowGetNeedReloadForCell = ({ extra, more, row, fieldName }) => {\r\n let _forceNeedReload = false\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n _forceNeedReload = FlowGetBoolOfMoreFromRow({\r\n row,\r\n more: _more,\r\n key: KMoreOfTableCell.needReloadAfterUpdateFields,\r\n })\r\n console.warn(\"_forceNeedReload:\", _forceNeedReload)\r\n return _forceNeedReload\r\n}\r\n\r\nexport const FlowUpdateQuery = ({\r\n extra,\r\n more,\r\n row,\r\n oneTableCell,\r\n fieldName,\r\n fnList,\r\n currentQuery,\r\n}) => {\r\n let _query = currentQuery || {}\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n if (_more[KMTC.queryWithQuerySharedPage] === true) {\r\n let _qureySharedMyPage = fnListMyPage.fnGetSharedRequestData(fnList)\r\n console.warn(\"_queryShared:\", _qureySharedMyPage)\r\n _query = Object.assign(_qureySharedMyPage, _query)\r\n }\r\n\r\n return _query\r\n}\r\n\r\nexport const FlowShowLoadingFullRow = ({\r\n row,\r\n more,\r\n extra,\r\n isShow,\r\n fieldName,\r\n}) => {\r\n if (\r\n FlowGetBoolOfMoreFromRow({\r\n key: KMore.needLoadingFullRow,\r\n row,\r\n more,\r\n }) !== true\r\n ) {\r\n return\r\n }\r\n if (row && extra && extra.fnForceUpdateTableBody) {\r\n if (isShow) {\r\n row.UI_ClassTableRow = \"ag-row-isloading\"\r\n if (row.UI_ClassTableCell == null) {\r\n row.UI_ClassTableCell = {}\r\n }\r\n if (row.UI_ClassTableCell) {\r\n row.UI_ClassTableCell[fieldName] = \"ag-cell-isloading\"\r\n }\r\n if (row.UI_ComponentAppendCell == null) {\r\n row.UI_ComponentAppendCell = {}\r\n }\r\n if (row.UI_ComponentAppendCell) {\r\n // row.UI_ComponentAppendCell[fieldName] = \"Hello\"\r\n row.UI_ComponentAppendCell[fieldName] = () => {\r\n return (\r\n
\r\n {/* */}\r\n
\r\n )\r\n }\r\n }\r\n if (extra && extra.fnForceUpdateTableBody) {\r\n extra.fnForceUpdateTableBody()\r\n }\r\n } else {\r\n row.UI_ClassTableRow = \"\"\r\n if (row.UI_ClassTableCell == null) {\r\n row.UI_ClassTableCell = {}\r\n }\r\n if (row.UI_ClassTableCell) {\r\n row.UI_ClassTableCell[fieldName] = \"\"\r\n }\r\n if (row.UI_ComponentAppendCell == null) {\r\n row.UI_ComponentAppendCell = {}\r\n }\r\n if (row.UI_ComponentAppendCell) {\r\n // row.UI_ComponentAppendCell[fieldName] = \"Hello\"\r\n row.UI_ComponentAppendCell[fieldName] = null\r\n }\r\n if (extra && extra.fnForceUpdateTableBody) {\r\n extra.fnForceUpdateTableBody()\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport const FlowUpdateWaitingApi = ({\r\n extra,\r\n row,\r\n newRow,\r\n fieldName,\r\n more,\r\n oneTableCell,\r\n loading,\r\n}) => {\r\n let _more = FlowGetMore({ extra, more, fieldName })\r\n console.log(\"FlowUpdateWaitingApi:\", _more)\r\n if (_more[KMore.customRowBeforeRequest]) {\r\n let _fields = Object.keys(_more[KMore.customRowBeforeRequest])\r\n for (let k of _fields) {\r\n row[k] = _more[KMore.customRowBeforeRequest][k]\r\n }\r\n }\r\n if (_more[KMore.waitApi] && Array.isArray(_more[KMore.waitApi])) {\r\n for (let k of _more[KMore.waitApi]) {\r\n FlowAddNeedUpdateUIByFields({ extra, row, fieldNeedUpdate: k })\r\n FlowSetConfigCellInRow({\r\n oneTableCell,\r\n row,\r\n fieldName: k,\r\n key: `waiting`,\r\n value: loading,\r\n })\r\n }\r\n }\r\n}\r\n\r\nexport const FlowSetConfigCellInRow = ({\r\n oneTableCell,\r\n row,\r\n fieldName,\r\n key,\r\n value,\r\n}) => {\r\n if (oneTableCell && oneTableCell._onePage) {\r\n if (oneTableCell._onePage[KOnePageMore._configRowById] == undefined) {\r\n oneTableCell._onePage[KOnePageMore._configRowById] = {}\r\n }\r\n console.log(\"FlowSetConfigCellInRow:\", key, value, oneTableCell)\r\n let _obj = oneTableCell._onePage[KOnePageMore._configRowById]\r\n if (row.Id && key) {\r\n if (_obj[row.Id] == undefined) {\r\n _obj[row.Id] = {}\r\n }\r\n if (_obj[row.Id][fieldName] == undefined) {\r\n _obj[row.Id][fieldName] = {}\r\n }\r\n _obj[row.Id][fieldName][key] = value\r\n }\r\n }\r\n}\r\n\r\nexport const FlowGetOnePageFromOneTableCell = ({ oneTableCell, onePage }) => {\r\n if (oneTableCell && oneTableCell._onePage) {\r\n return oneTableCell._onePage\r\n }\r\n return onePage || null\r\n}\r\n\r\nexport const FlowGetConfigRows = ({ oneTableCell, onePage }) => {\r\n let _onePage = FlowGetOnePageFromOneTableCell({ oneTableCell, onePage })\r\n if (_onePage) {\r\n if (_onePage[KOnePageMore._configRowById] == undefined) {\r\n _onePage[KOnePageMore._configRowById] = {\r\n a: 1,\r\n }\r\n }\r\n return _onePage[KOnePageMore._configRowById]\r\n }\r\n}\r\n\r\nexport const FlowGetConfigRowById = ({ oneTableCell, onePage, row }) => {\r\n let _configRows = FlowGetConfigRows({ oneTableCell, onePage })\r\n if (_configRows && row && row.Id) {\r\n if (_configRows[row.Id] == undefined) {\r\n _configRows[row.Id] = {}\r\n }\r\n return _configRows[row.Id]\r\n }\r\n}\r\n\r\nexport const FlowSetConfigInRow = ({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n key,\r\n value,\r\n}) => {\r\n let _configInRow = FlowGetConfigRowById({ oneTableCell, onePage, row })\r\n if (_configInRow && key) {\r\n _configInRow[key] = value\r\n }\r\n}\r\n\r\nexport const FlowGetConfigInRow = ({ oneTableCell, onePage, row, key }) => {\r\n let _configInRow = FlowGetConfigRowById({ oneTableCell, onePage, row })\r\n if (_configInRow && key) {\r\n return _configInRow[key]\r\n }\r\n}\r\n\r\nexport const FlowGetConfigCellInRow = ({\r\n oneTableCell,\r\n row,\r\n fieldName,\r\n key,\r\n df,\r\n}) => {\r\n return (\r\n HUtils.get(\r\n oneTableCell,\r\n `_onePage.${KOnePageMore._configRowById}.${row.Id}.${fieldName}.${key}`\r\n ) || df\r\n )\r\n}\r\n\r\nexport const FlowGetConfigWaitingCellInRow = ({\r\n oneTableCell,\r\n row,\r\n fieldName,\r\n df,\r\n}) => {\r\n return FlowGetConfigCellInRow({\r\n oneTableCell,\r\n row,\r\n fieldName,\r\n key: \"waiting\",\r\n df,\r\n })\r\n}\r\n\r\nexport const FlowForceUpdateTable = ({ row, oneTableCell }) => {\r\n if (\r\n oneTableCell &&\r\n oneTableCell._onePage &&\r\n oneTableCell._onePage[KOnePageMore._forceUpdateTable]\r\n ) {\r\n oneTableCell._onePage[KOnePageMore._forceUpdateTable]({ row, oneTableCell })\r\n }\r\n}\r\nexport const FlowForceUpdateTableRow = ({ oneTableCell, onePage, row }) => {\r\n let _configInRow = FlowGetConfigRowById({ oneTableCell, onePage, row })\r\n if (_configInRow && _configInRow[\"fnForceUpdateTableRow\"]) {\r\n _configInRow[\"fnForceUpdateTableRow\"]()\r\n }\r\n}\r\n//justnew\r\nexport const FlowAddConfigJustNewInRow = ({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n needForceUpdate,\r\n}) => {\r\n FlowSetConfigInRow({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n key: \"justNew\",\r\n value: true,\r\n })\r\n if (needForceUpdate) {\r\n FlowForceUpdateTableRow({ oneTableCell, onePage, row })\r\n }\r\n}\r\nexport const FlowGetConfigJustNewInRow = ({ oneTableCell, onePage, row }) => {\r\n return FlowGetConfigInRow({ oneTableCell, onePage, row, key: \"justNew\" })\r\n}\r\n//justdelete\r\nexport const FlowAddConfigJustDeleteInRow = ({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n needForceUpdate,\r\n}) => {\r\n FlowSetConfigInRow({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n key: \"justDelete\",\r\n value: true,\r\n })\r\n if (needForceUpdate) {\r\n FlowForceUpdateTableRow({ oneTableCell, onePage, row })\r\n }\r\n}\r\nexport const FlowGetConfigJustDeleteInRow = ({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n}) => {\r\n return FlowGetConfigInRow({ oneTableCell, onePage, row, key: \"justDelete\" })\r\n}\r\n//loading\r\nexport const FlowAddConfigLoadingInRow = ({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n value,\r\n needForceUpdate,\r\n}) => {\r\n FlowSetConfigInRow({\r\n oneTableCell,\r\n onePage,\r\n row,\r\n key: \"loading\",\r\n value: value === false ? false : true,\r\n })\r\n if (needForceUpdate) {\r\n FlowForceUpdateTableRow({ oneTableCell, onePage, row })\r\n }\r\n}\r\nexport const FlowGetConfigLoadingInRow = ({ oneTableCell, onePage, row }) => {\r\n return FlowGetConfigInRow({ oneTableCell, onePage, row, key: \"loading\" })\r\n}\r\n","import { HUtils, HJson } from \"@macashipo/mlib\"\r\nexport const FlowGetColumnFromExtraData = (extraData, fieldName) => {\r\n return HUtils.get(extraData, `Columns.${fieldName}`)\r\n}\r\n\r\nexport const FlowGetMoreFilterOfCellFromExtraData = (extraData, fieldName) => {\r\n let _colExtra = FlowGetColumnFromExtraData(extraData, fieldName)\r\n if (_colExtra) {\r\n if (_colExtra._moreFilterObj) {\r\n return _colExtra._moreFilterObj\r\n } else {\r\n if (_colExtra.Filter && _colExtra.Filter.more) {\r\n let _moreFilterObj = HJson.getObj(_colExtra.Filter.more) || {}\r\n _colExtra._moreFilterObj = _moreFilterObj\r\n return _moreFilterObj\r\n }\r\n }\r\n }\r\n return {}\r\n}\r\n\r\nexport const FlowGetMoreOfCellFromExtraData = (extraData, fieldName) => {\r\n let _colExtra = FlowGetColumnFromExtraData(extraData, fieldName)\r\n return FlowGetMoreOfCellFromExtraColumn(_colExtra)\r\n}\r\nexport const FlowGetMoreOfCellFromExtraColumn = _colExtra => {\r\n if (_colExtra) {\r\n if (_colExtra._moreObj) {\r\n return _colExtra._moreObj\r\n } else {\r\n if (_colExtra.Type && _colExtra.Type.more) {\r\n let _moreObj = HJson.getObj(_colExtra.Type.more) || {}\r\n _colExtra._moreObj = _moreObj\r\n return _moreObj\r\n }\r\n }\r\n }\r\n return {}\r\n}\r\n","import i18next from \"i18next\"\r\nimport React, { Fragment, lazy, Suspense } from \"react\"\r\n\r\nconst Dashboards = lazy(() => import(\"../CDashboard\"))\r\n\r\nconst AppMain = props => {\r\n return (\r\n \r\n {/* Dashboards */}\r\n\r\n \r\n
\r\n
\r\n {i18next.t(\"Please wait while we load all the components\")}\r\n \r\n {i18next.t(\r\n \"Because this is a demonstration, we load at once all the components\"\r\n )}\r\n \r\n
\r\n
\r\n \r\n }\r\n >\r\n {props.children}\r\n \r\n
\r\n )\r\n}\r\n\r\nexport default AppMain\r\n","import * as React from \"react\"\r\n\r\nconst changedArray = (a: Array = [], b: Array = []) =>\r\n a.length !== b.length || a.some((item, index) => !Object.is(item, b[index]))\r\n\r\ninterface FallbackProps {\r\n error: Error\r\n resetErrorBoundary: (...args: Array) => void\r\n}\r\n\r\ninterface ErrorBoundaryPropsWithComponent {\r\n onResetKeysChange?: (\r\n prevResetKeys: Array | undefined,\r\n resetKeys: Array | undefined\r\n ) => void\r\n onReset?: (...args: Array) => void\r\n onError?: (error: Error, info: { componentStack: string }) => void\r\n resetKeys?: Array\r\n fallback?: never\r\n FallbackComponent: React.ComponentType\r\n fallbackRender?: never\r\n}\r\n\r\ndeclare function FallbackRender(\r\n props: FallbackProps\r\n): React.ReactElement<\r\n unknown,\r\n string | React.FunctionComponent | typeof React.Component\r\n> | null\r\n\r\ninterface ErrorBoundaryPropsWithRender {\r\n onResetKeysChange?: (\r\n prevResetKeys: Array | undefined,\r\n resetKeys: Array | undefined\r\n ) => void\r\n onReset?: (...args: Array) => void\r\n onError?: (error: Error, info: { componentStack: string }) => void\r\n resetKeys?: Array\r\n fallback?: never\r\n FallbackComponent?: never\r\n fallbackRender: typeof FallbackRender\r\n}\r\n\r\ninterface ErrorBoundaryPropsWithFallback {\r\n onResetKeysChange?: (\r\n prevResetKeys: Array | undefined,\r\n resetKeys: Array | undefined\r\n ) => void\r\n onReset?: (...args: Array) => void\r\n onError?: (error: Error, info: { componentStack: string }) => void\r\n resetKeys?: Array\r\n fallback: React.ReactElement<\r\n unknown,\r\n string | React.FunctionComponent | typeof React.Component\r\n > | null\r\n FallbackComponent?: never\r\n fallbackRender?: never\r\n}\r\n\r\ntype ErrorBoundaryProps =\r\n | ErrorBoundaryPropsWithFallback\r\n | ErrorBoundaryPropsWithComponent\r\n | ErrorBoundaryPropsWithRender\r\n\r\ntype ErrorBoundaryState = { error: Error | null }\r\n\r\nconst initialState: ErrorBoundaryState = { error: null }\r\n\r\nclass ErrorBoundary extends React.Component<\r\n React.PropsWithRef>,\r\n ErrorBoundaryState\r\n> {\r\n static getDerivedStateFromError(error: Error) {\r\n return { error }\r\n }\r\n\r\n state = initialState\r\n resetErrorBoundary = (...args: Array) => {\r\n this.props.onReset?.(...args)\r\n this.reset()\r\n }\r\n\r\n reset() {\r\n this.setState(initialState)\r\n }\r\n\r\n componentDidCatch(error: Error, info: React.ErrorInfo) {\r\n this.props.onError?.(error, info)\r\n }\r\n\r\n componentDidUpdate(\r\n prevProps: ErrorBoundaryProps,\r\n prevState: ErrorBoundaryState\r\n ) {\r\n const { error } = this.state\r\n const { resetKeys } = this.props\r\n\r\n // There's an edge case where if the thing that triggered the error\r\n // happens to *also* be in the resetKeys array, we'd end up resetting\r\n // the error boundary immediately. This would likely trigger a second\r\n // error to be thrown.\r\n // So we make sure that we don't check the resetKeys on the first call\r\n // of cDU after the error is set\r\n\r\n if (\r\n error !== null &&\r\n prevState.error !== null &&\r\n changedArray(prevProps.resetKeys, resetKeys)\r\n ) {\r\n this.props.onResetKeysChange?.(prevProps.resetKeys, resetKeys)\r\n this.reset()\r\n }\r\n }\r\n\r\n render() {\r\n const { error } = this.state\r\n\r\n const { fallbackRender, FallbackComponent, fallback } = this.props\r\n\r\n if (error !== null) {\r\n const props = {\r\n error,\r\n resetErrorBoundary: this.resetErrorBoundary,\r\n }\r\n if (React.isValidElement(fallback)) {\r\n return fallback\r\n } else if (typeof fallbackRender === \"function\") {\r\n return fallbackRender(props)\r\n } else if (FallbackComponent) {\r\n return \r\n } else {\r\n throw new Error(\r\n \"react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop\"\r\n )\r\n }\r\n }\r\n\r\n return this.props.children\r\n }\r\n}\r\n\r\nfunction withErrorBoundary

(\r\n Component: React.ComponentType

,\r\n errorBoundaryProps: ErrorBoundaryProps\r\n): React.ComponentType

{\r\n const Wrapped: React.ComponentType

= props => {\r\n return (\r\n \r\n \r\n \r\n )\r\n }\r\n\r\n // Format for display in DevTools\r\n const name = Component.displayName || Component.name || \"Unknown\"\r\n Wrapped.displayName = `withErrorBoundary(${name})`\r\n\r\n return Wrapped\r\n}\r\n\r\nfunction useErrorHandler(givenError?: unknown): (error: unknown) => void {\r\n const [error, setError] = React.useState(null)\r\n if (givenError != null) throw givenError\r\n if (error != null) throw error\r\n return setError\r\n}\r\n\r\nexport { ErrorBoundary, withErrorBoundary, useErrorHandler }\r\nexport type {\r\n FallbackProps,\r\n ErrorBoundaryPropsWithComponent,\r\n ErrorBoundaryPropsWithRender,\r\n ErrorBoundaryPropsWithFallback,\r\n ErrorBoundaryProps,\r\n}\r\n\r\n/*\r\neslint\r\n @typescript-eslint/sort-type-union-intersection-members: \"off\",\r\n @typescript-eslint/no-throw-literal: \"off\",\r\n @typescript-eslint/prefer-nullish-coalescing: \"off\"\r\n*/\r\n","export default __webpack_public_path__ + \"static/media/icon-error.054702dd.png\";","import React, { Fragment } from \"react\"\r\nimport { connect } from \"react-redux\"\r\nimport classnames from \"classnames\"\r\nimport { withRouter } from \"react-router-dom\"\r\nimport AppMain from \"./AppMain\"\r\nimport ResizeDetector from \"react-resize-detector\"\r\nimport \"./assets/base.css\"\r\nimport { ErrorBoundary } from \"src/libs/ReactErrorBoundary\"\r\nimport styled from \"styled-components\"\r\nimport { Button } from \"reactstrap\"\r\nimport ImgIconError from \"src/assets/images/icon-error.png\"\r\nimport { HLocalStorage } from \"@macashipo/mlib\"\r\nimport { HRoutes } from \"src/helpers/Flows/Routes\"\r\nconst WrapError = styled.div`\r\n margin: 0 auto;\r\n width: 300px;\r\n margin-top: 2rem;\r\n min-width: 300px;\r\n max-width: 100%;\r\n background: white;\r\n border-radius: 0.5rem;\r\n padding: 1rem;\r\n box-shadow: rgba(17, 17, 26, 0.1) 0px 4px 16px,\r\n rgba(17, 17, 26, 0.05) 0px 8px 32px;\r\n .a-img {\r\n text-align: center;\r\n & img {\r\n width: 100px;\r\n height: auto;\r\n }\r\n }\r\n & .a-title {\r\n text-align: center;\r\n font-size: 2rem;\r\n font-weight: bold;\r\n }\r\n & .a-msg {\r\n text-align: center;\r\n white-space: pre-wrap;\r\n }\r\n & .a-buttons {\r\n > button {\r\n margin-right: 5px;\r\n }\r\n }\r\n`\r\nfunction ErrorFallback({ error, resetErrorBoundary }) {\r\n if (error && error.message) {\r\n // let _sNeedReload = \"img is a void\"//test\r\n let _sNeedReload = \"Loading chunk\"\r\n if (window.sendGGNotifyLog) {\r\n let _msg = `${error.message}\\n${String(error.stack).slice(0, 300)}`\r\n if (navigator && navigator.userAgent) {\r\n _msg += `\\nAgent: ${navigator.userAgent}`\r\n }\r\n window.sendGGNotifyLog({ msg: _msg })\r\n }\r\n if (error.message.indexOf(_sNeedReload) > -1) {\r\n let _justReloadOne = HLocalStorage.getString(\"_justReloadOne\")\r\n let _currentTime = new Date().getTime()\r\n let _needReload = true\r\n if (_justReloadOne) {\r\n if (_currentTime - parseInt(_justReloadOne) < 1000 * 10) {\r\n //10s\r\n _needReload = false\r\n }\r\n }\r\n console.warn(\"reload one\", _needReload)\r\n if (_needReload) {\r\n HLocalStorage.saveString(\"_justReloadOne\", String(_currentTime))\r\n window.location.reload()\r\n }\r\n }\r\n }\r\n return (\r\n \r\n

\r\n \"Error\"\r\n
\r\n
Oh no!
\r\n

\r\n {`Sorry! Something went wrong.\r\n Please try again later.`}\r\n

\r\n
{error.message}
\r\n
\r\n \r\n {\r\n window.location.reload()\r\n }}\r\n >\r\n Reload\r\n \r\n
\r\n \r\n )\r\n}\r\nclass Main extends React.Component {\r\n constructor(props) {\r\n super(props)\r\n this.state = {\r\n closedSmallerSidebar: false,\r\n width: undefined,\r\n }\r\n }\r\n\r\n onResize = width => this.setState({ width })\r\n\r\n render() {\r\n const configPage = this.props.configPage || {}\r\n const { width } = this.state\r\n\r\n let {\r\n colorScheme,\r\n enableFixedHeader,\r\n enableFixedSidebar,\r\n enableFixedFooter,\r\n enableClosedSidebar,\r\n closedSmallerSidebar,\r\n enableMobileMenu,\r\n // enablePageTabsAlt,\r\n children,\r\n } = this.props\r\n\r\n return (\r\n \r\n {\r\n // reset the state of your app so the error doesn't happen again\r\n }}\r\n >\r\n \r\n {children}\r\n \r\n \r\n \r\n \r\n )\r\n }\r\n}\r\n\r\nconst mapStateToProp = state => ({\r\n colorScheme: state.ThemeOptions.colorScheme,\r\n enableFixedHeader: state.ThemeOptions.enableFixedHeader,\r\n enableMobileMenu: state.ThemeOptions.enableMobileMenu,\r\n enableFixedFooter: state.ThemeOptions.enableFixedFooter,\r\n enableFixedSidebar: state.ThemeOptions.enableFixedSidebar,\r\n enableClosedSidebar: state.ThemeOptions.enableClosedSidebar,\r\n enablePageTabsAlt: state.ThemeOptions.enablePageTabsAlt,\r\n})\r\n\r\nexport default withRouter(connect(mapStateToProp)(Main))\r\n","import { HFormat } from \"@macashipo/mlib\"\r\nimport HW from \"./W\"\r\n//year-month-day\r\nexport const isStringDate = str => {\r\n if (\r\n /\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}.\\d{3}Z?/.test(str) ||\r\n /\\d{4}-\\d{2}-\\d{2}\\s\\d{2}:\\d{2}:\\d{2}/.test(str) ||\r\n /\\d{4}-\\d{2}-\\d{2}/.test(str)\r\n ) {\r\n var d = new Date(str)\r\n return d.toString() !== \"Invalid Date\"\r\n }\r\n return false\r\n}\r\n\r\nexport const isIsoDate = str => {\r\n if (\r\n /\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}.\\d{3}Z?/.test(str) ||\r\n /\\d{4}-\\d{2}-\\d{2}\\s\\d{2}:\\d{2}:\\d{2}/.test(str)\r\n ) {\r\n var d = new Date(str)\r\n return d.toString() !== \"Invalid Date\"\r\n }\r\n return false\r\n}\r\n\r\nexport const isHexColorString = str => {\r\n if (str && typeof str == \"string\" && str.startsWith(\"#\") && str.length == 7) {\r\n return true\r\n }\r\n return false\r\n}\r\n\r\nexport const isIphone = () => {\r\n if (navigator.platform) {\r\n return /iPad|iPhone|iPod/.test(navigator.platform)\r\n }\r\n if (navigator.userAgentData && navigator.userAgentData.platform) {\r\n return /iPad|iPhone|iPod/.test(navigator.userAgentData.platform)\r\n }\r\n if (navigator.userAgent) {\r\n return /iPad|iPhone|iPod/.test(navigator.userAgent)\r\n }\r\n return false\r\n}\r\n\r\nexport const isMobile = () => {\r\n return /Mobi|Android/i.test(navigator.userAgent)\r\n}\r\n\r\nexport const isObject = function (value) {\r\n return Object(value) === value\r\n}\r\n\r\nexport const isArray =\r\n Array.isArray ||\r\n function (value) {\r\n // check native isArray first\r\n return toString.call(value) === \"[object Array]\"\r\n }\r\n\r\nexport const isArguments = function (value) {\r\n // fallback check is for IE\r\n return (\r\n toString.call(value) === \"[object Arguments]\" ||\r\n (value != null && typeof value === \"object\" && \"callee\" in value)\r\n )\r\n}\r\nexport const isEmpty = function (value) {\r\n if (isObject(value)) {\r\n var length = Object.getOwnPropertyNames(value).length\r\n if (\r\n length === 0 ||\r\n (length === 1 && isArray(value)) ||\r\n (length === 2 && isArguments(value))\r\n ) {\r\n return true\r\n }\r\n return false\r\n }\r\n return value === \"\"\r\n}\r\n\r\nexport const getDateWithString = str => {\r\n var _date = new Date(str)\r\n return _date\r\n}\r\n\r\n//12:05, 01:10\r\nexport const isStringHourMinute = str => {\r\n if (/\\d{1,2}:\\d{1,2}/.test(str)) {\r\n var arr = str.split(\":\")\r\n if (Number(arr[0]) < 24 && Number(arr[1]) < 60) {\r\n return true\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport const getDateWithHourMinute = str => {\r\n var _date = new Date()\r\n if (/\\d{1,2}:\\d{1,2}/.test(str)) {\r\n var arr = str.split(\":\")\r\n if (Number(arr[0]) < 24 && Number(arr[1]) < 60) {\r\n _date.setHours(Number(arr[0]))\r\n _date.setMinutes(Number(arr[1]))\r\n }\r\n }\r\n return _date\r\n}\r\n\r\nexport const getStringHourMinuteFromDate = date => {\r\n let _str = \"\"\r\n if (date) {\r\n _str = `${padString(2, String(date.getHours()), \"0\")}:${padString(\r\n 2,\r\n String(date.getMinutes()),\r\n \"0\"\r\n )}`\r\n }\r\n return _str\r\n}\r\n\r\nexport const getStringDateFromDate = date => {\r\n let _str = \"\"\r\n if (date) {\r\n _str = HFormat.format(date.getTime(), {\r\n type: \"date\",\r\n format: \"YYYY-MM-DD\",\r\n })\r\n }\r\n return _str\r\n}\r\n\r\nexport const padString = (width, string, padding) => {\r\n return width <= string.length\r\n ? string\r\n : padString(width, padding + string, padding)\r\n}\r\n\r\nexport const checkPushArrayInObjIfNotExist = (obj, key, value) => {\r\n if (obj) {\r\n if (obj[key] == null) {\r\n obj[key] = []\r\n }\r\n if (obj[key] && obj[key].indexOf(value) == -1) {\r\n obj[key].push(value)\r\n }\r\n }\r\n}\r\n\r\nexport const downloadFile = (fileUrl = \"\", name) => {\r\n //Set the File URL.\r\n var url = fileUrl\r\n var fileName = name || url.split(\"/\").pop()\r\n //Create XMLHTTP Request.\r\n var req = new XMLHttpRequest()\r\n req.open(\"GET\", url, true)\r\n req.responseType = \"blob\"\r\n req.onload = function () {\r\n //Convert the Byte Data to BLOB object.\r\n var blob = new Blob([req.response], { type: \"application/octetstream\" })\r\n //Check the Browser type and download the File.\r\n var isIE = false || !!document.documentMode\r\n if (isIE) {\r\n window.navigator.msSaveBlob(blob, fileName)\r\n } else {\r\n var url = window.URL || window.webkitURL\r\n var link = url.createObjectURL(blob)\r\n var a = document.createElement(\"a\")\r\n a.setAttribute(\"download\", fileName)\r\n a.setAttribute(\"href\", link)\r\n document.body.appendChild(a)\r\n a.click()\r\n document.body.removeChild(a)\r\n }\r\n }\r\n req.send()\r\n}\r\n\r\nexport const removeObjectFromArrayByFieldValue = (\r\n arr = [],\r\n fieldName,\r\n fieldValue\r\n) => {\r\n if (arr && arr.length > 0 && fieldName) {\r\n for (var i = 0; i < arr.length; i++) {\r\n var obj = arr[i]\r\n if (obj[fieldName] == fieldValue) {\r\n arr.splice(i, 1)\r\n i--\r\n }\r\n }\r\n return arr\r\n }\r\n return []\r\n}\r\n\r\nexport const getUUID = () => {\r\n return Math.random().toString(36).slice(2, 7)\r\n}\r\n\r\nexport const parseJwt = token => {\r\n var base64Url = token.split(\".\")[1]\r\n var base64 = base64Url.replace(/-/g, \"+\").replace(/_/g, \"/\")\r\n var jsonPayload = decodeURIComponent(\r\n window\r\n .atob(base64)\r\n .split(\"\")\r\n .map(function (c) {\r\n return \"%\" + (\"00\" + c.charCodeAt(0).toString(16)).slice(-2)\r\n })\r\n .join(\"\")\r\n )\r\n\r\n return JSON.parse(jsonPayload)\r\n}\r\n\r\nexport const mergeDeepObjects = (obj1, obj2) => {\r\n const merged = { ...obj1 }\r\n\r\n for (const key in obj2) {\r\n if (obj2.hasOwnProperty(key)) {\r\n if (\r\n typeof obj2[key] === \"object\" &&\r\n !Array.isArray(obj2[key]) &&\r\n obj1.hasOwnProperty(key) &&\r\n typeof obj1[key] === \"object\"\r\n ) {\r\n merged[key] = mergeDeepObjects(obj1[key], obj2[key])\r\n } else {\r\n merged[key] = obj2[key]\r\n }\r\n }\r\n }\r\n\r\n return merged\r\n}\r\n\r\nexport const isHasDoubleByte = str => {\r\n for (var i = 0, n = str.length; i < n; i++) {\r\n if (str.charCodeAt(i) > 255) {\r\n return true\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport const addClassBody = cls => {\r\n if (cls) {\r\n window.document.body.classList.add(cls)\r\n }\r\n}\r\n\r\nexport const removeClassBody = cls => {\r\n if (cls) {\r\n window.document.body.classList.remove(cls)\r\n }\r\n}\r\n\r\nexport const addScript = url => {\r\n var script = document.createElement(\"script\")\r\n script.type = \"application/javascript\"\r\n script.src = url\r\n document.head.appendChild(script)\r\n}\r\n//addScript('https://cdnjs.cloudflare.com/ajax/libs/html2pdf.js/0.10.1/html2pdf.bundle.min.js');\r\n\r\nexport const getParentNodeHasClass = (node, classParent, deep = 5) => {\r\n if (node && node.parentNode) {\r\n if (node.parentNode.classList.contains(classParent)) {\r\n return node.parentNode\r\n } else if (deep > 0) {\r\n return getParentNodeHasClass(node.parentNode, classParent, deep - 1)\r\n }\r\n }\r\n return null\r\n}\r\n\r\nexport const getQueryFromData = (query, data) => {\r\n let _queryMore = query || {}\r\n let _query = {}\r\n let _obj = Object.keys(_queryMore)\r\n if (_obj && _obj.length > 0) {\r\n for (let i of _obj) {\r\n let _value = _queryMore[i]\r\n if (data.hasOwnProperty(_value) == true) {\r\n if (data[_value] != null) {\r\n _query[i] = data[_value]\r\n }\r\n } else {\r\n _query[i] = _queryMore[i]\r\n }\r\n }\r\n }\r\n return _query\r\n}\r\n\r\nexport const addDataToObj = (sourceObj, addedObj) => {\r\n if (sourceObj && addedObj) {\r\n let _keys = Object.keys(addedObj)\r\n for (let k of _keys) {\r\n if (Array.isArray(addedObj[k])) {\r\n sourceObj[k] = addedObj[k]\r\n } else if (typeof addedObj[k] == \"object\") {\r\n if (sourceObj[k] == null) {\r\n //kiem tra neu chua co source[k] thi khoi tao object rong\r\n sourceObj[k] = {}\r\n }\r\n addDataToObj(sourceObj[k], addedObj[k])\r\n } else {\r\n sourceObj[k] = addedObj[k]\r\n }\r\n }\r\n }\r\n return sourceObj\r\n}\r\n\r\nexport const evalInScope = (js, contextAsScope) => {\r\n try {\r\n // eslint-disable-next-line\r\n return new Function(`with (this) { return (${js}); }`).call(contextAsScope)\r\n // eslint-disable-next-line\r\n // return eval(js)\r\n } catch (error) {\r\n console.error(\"evalInScope:\", js, contextAsScope, error)\r\n }\r\n}\r\n\r\nexport const cloneObj = (obj = {}) => {\r\n try {\r\n return JSON.parse(JSON.stringify(obj))\r\n } catch (error) {\r\n console.warn(\"error:\", error)\r\n }\r\n return null\r\n}\r\n","import React from \"react\"\r\nimport { HUtils, HIs } from \"@macashipo/mlib\"\r\nconst OptionsInfo = {\r\n fValue: \"Value\",\r\n fText: \"Text\",\r\n}\r\n\r\nexport const KEmptyOptionValue = \"_empty_\"\r\nexport const getSourceDataWithEmptyItem = (\r\n sourceData?: any[],\r\n { placeHolder }: any = {}\r\n) => {\r\n let _source = sourceData || []\r\n if (_source && _source.length > 0) {\r\n if (_source[0].Value != KEmptyOptionValue || _source[0].Text != \"\") {\r\n return [{ Text: placeHolder || \"\", Value: KEmptyOptionValue }, ..._source]\r\n }\r\n }\r\n return _source\r\n}\r\nexport const getListSelectTagBySourceData = (\r\n sourceData?: any[],\r\n opts: any = {}\r\n) => {\r\n if (sourceData && sourceData.length > 0) {\r\n let _ui: any = []\r\n if (opts) {\r\n if (opts.noAddAutoEmpty !== true) {\r\n _ui.push(\r\n \r\n )\r\n }\r\n }\r\n for (let i = 0; i < sourceData.length; i++) {\r\n let _text = sourceData[i].Text || sourceData[i].label || \"\"\r\n let _value = sourceData[i].Value || sourceData[i].value || \"\"\r\n _ui.push(\r\n \r\n )\r\n }\r\n return _ui\r\n }\r\n}\r\n\r\nexport const convertSourceDataToString = (sourceData?: any[]) => {\r\n if (sourceData) {\r\n return sourceData.join(\",\")\r\n }\r\n return \"\"\r\n}\r\n\r\nexport const getOptionByValue = (sourceList: any = [], value) => {\r\n // console.warn(\"getOptionByValue:\", sourceList, value)\r\n if (sourceList && sourceList.length > 0 && value != null) {\r\n for (let i = 0; i < sourceList.length; i++) {\r\n if (sourceList[i].Value == value) {\r\n //luu y truong hop 0 == \"\"\r\n return sourceList[i]\r\n }\r\n }\r\n }\r\n}\r\n\r\nexport const getTextByValue = (sourceList = [], value) => {\r\n let _text = value\r\n let _option = getOptionByValue(sourceList, value)\r\n // console.warn(\"getTextByValue\", sourceList, value)\r\n if (_option && _option.Text) {\r\n _text = _option.Text\r\n }\r\n return _text\r\n}\r\n\r\nexport const convertSourceDataToArrayValue = (sourceData?: any[]) => {\r\n if (sourceData) {\r\n return sourceData.map((v: any, i) => {\r\n return v[OptionsInfo.fValue]\r\n })\r\n }\r\n return []\r\n}\r\n\r\nexport const getSourceDataFromSourceList = (sourceList: any, key: string) => {\r\n if (sourceList && sourceList[key]) {\r\n return sourceList[key]\r\n }\r\n return []\r\n}\r\n\r\nexport const getSourceListFromFnList = (fnList: any) => {\r\n if (fnList && fnList.getSourceList) {\r\n return fnList.getSourceList()\r\n }\r\n return {}\r\n}\r\n\r\nexport const isHasLevelOptionKey = optionKey => {\r\n if (optionKey) {\r\n if (optionKey.indexOf(\".\") > -1 && optionKey.indexOf(\"[\") != 0) {\r\n return true\r\n }\r\n }\r\n return false\r\n}\r\n\r\nexport const convertOptionKeyLevelMissingField = (\r\n optionKey = \"\",\r\n fieldNames = []\r\n) => {\r\n let _optionKey = optionKey\r\n //truong hop a.b cua cell, ko day du a.[field].b\r\n if (\r\n _optionKey.indexOf(\".\") > -1 &&\r\n _optionKey.indexOf(\"[\") === -1 &&\r\n fieldNames.length > 0\r\n ) {\r\n let _countDot = 0\r\n for (let i = 0; i < _optionKey.length; i++) {\r\n if (_optionKey[i] === \".\") {\r\n _countDot++\r\n if (fieldNames.length > 0) {\r\n if (HIs.isString(fieldNames)) {\r\n let _add = `[${fieldNames}].`\r\n _optionKey =\r\n _optionKey.slice(0, i + 1) +\r\n _add +\r\n _optionKey.slice(i + 1, _optionKey.length)\r\n i += _add.length\r\n } else if (fieldNames[_countDot - 1]) {\r\n //is array\r\n let _add = `[${fieldNames[_countDot - 1]}].`\r\n _optionKey =\r\n _optionKey.slice(0, i + 1) +\r\n _add +\r\n _optionKey.slice(i + 1, _optionKey.length)\r\n i += _add.length\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return _optionKey\r\n}\r\nexport const getOptionsByLevel = (\r\n sourceList = {},\r\n optionKey = \"\",\r\n data = {},\r\n fieldNames = []\r\n) => {\r\n optionKey = convertOptionKeyLevelMissingField(optionKey, fieldNames)\r\n // console.warn(\"optionKey\", optionKey, fieldNames, data)\r\n if (sourceList[optionKey]) {\r\n //if exist\r\n return sourceList[optionKey]\r\n } else {\r\n // a.[field].b = a.value of field.b\r\n let _newOptionKey = HUtils.getTextWithData(optionKey, data)\r\n let _options: any = null\r\n let _split = _newOptionKey.split(\".\")\r\n let _prefixK = \"\" //bo sung prefixK cho truong hop Value co dau .\r\n for (let i = 0; i < _split.length; i++) {\r\n let k = _split[i]\r\n let _k = k\r\n if (_prefixK) {\r\n _k = `${_prefixK}.${k}`\r\n }\r\n if (_options === null && sourceList[_k]) {\r\n //truong hop co trong sourceList thi lay _options = sourceList[_k]\r\n _options = sourceList[_k]\r\n } else if (_options && HIs.isArray(_options) && _options.length > 0) {\r\n //truong hop co _option tu truoc-> can di kiem tra value\r\n let _hasItem = false\r\n for (let i = 0; i < _options.length; i++) {\r\n if (_options[i].Value == _k) {\r\n _options = _options[i]\r\n _hasItem = true\r\n _prefixK = \"\" //reset prefix neu co\r\n break\r\n }\r\n }\r\n if (_hasItem === false) {\r\n //phai co item neu ko thi la rong\r\n if (i < _split.length - 1) {\r\n //neu chua phai cuoi cung, co the la value chua dau .\r\n _prefixK = _k\r\n continue\r\n } else {\r\n _options = []\r\n }\r\n }\r\n } else if (_options && _options.Value && _options[k]) {\r\n //thuong thi k o buoc nay ko co dau .\r\n _options = _options[k]\r\n } else {\r\n _options = []\r\n }\r\n }\r\n sourceList[_newOptionKey] = _options\r\n // console.warn(\"options:\", _options, sourceList)\r\n return _options || []\r\n }\r\n}\r\n// ;(window as any)[\"test\"] = convertOptionKeyLevelMissingField\r\n\r\nexport const isExistValueInSourceList = (sourceList = [], value) => {\r\n let _isExist = false\r\n if (sourceList.length > 0) {\r\n for (let i = 0; i < sourceList.length; i++) {\r\n let _item: any = sourceList[i]\r\n if (_item.Value == value) {\r\n return true\r\n }\r\n }\r\n }\r\n return _isExist\r\n}\r\n","import { apiGeneric } from \"src/core/helpers/api\"\r\nconst ApiGeneric = ({\r\n request,\r\n data,\r\n successCallBack,\r\n errorCallBack,\r\n customHeader,\r\n opts,\r\n}) => {\r\n apiGeneric({\r\n method: request.method || \"POST\",\r\n url: request.url || `${request.path}/${request.name}` || \"NoApiUrl\",\r\n data,\r\n customHeader: customHeader,\r\n ...opts,\r\n })\r\n .then(v => {\r\n if (successCallBack) {\r\n successCallBack(v)\r\n }\r\n })\r\n .catch(e => {\r\n if (errorCallBack) {\r\n errorCallBack(e)\r\n }\r\n })\r\n}\r\nexport { ApiGeneric }\r\n","import { HUtils } from \"@macashipo/mlib\"\r\nimport apiGeneric from \"src/services/apiGeneric\"\r\nconst HUpload = {\r\n globalDropzone: null,\r\n onDrop: null,\r\n fnUpdateAccept: null,\r\n open: onDrop => {\r\n if (HUpload.globalDropzone && HUpload.globalDropzone.open) {\r\n HUpload.onDrop = onDrop\r\n HUpload.globalDropzone.open()\r\n }\r\n },\r\n openAndUpload: ({ beforeUpload, afterUpload, accept } = {}) => {\r\n if (HUpload.globalDropzone && HUpload.globalDropzone.open) {\r\n if (accept && HUpload.fnUpdateAccept) {\r\n HUpload.fnUpdateAccept(accept, () => {\r\n HUpload.onDrop = acceptedFiles => {\r\n beforeUpload && beforeUpload()\r\n var _formData = new FormData()\r\n if (acceptedFiles && acceptedFiles.length > 0) {\r\n for (let i = 0; i < acceptedFiles.length; i++) {\r\n _formData.append(\"file[]\", acceptedFiles[i])\r\n }\r\n apiGeneric({\r\n url: \"ProjectPhoto/FileUploadFile\",\r\n method: \"POST\",\r\n data: _formData,\r\n silent: true,\r\n customContentType: \"multipart/form-data\",\r\n })\r\n .then(rs => {\r\n console.warn(\"rs:\", rs)\r\n let _url = HUtils.get(rs, \"Data.Photos.0.FileUrl\")\r\n afterUpload && afterUpload(rs, null, _url)\r\n })\r\n .catch((err, rs) => {\r\n afterUpload && afterUpload(rs, err)\r\n })\r\n } else {\r\n console.warn(\"No acceptedFiles\", acceptedFiles)\r\n }\r\n }\r\n HUpload.globalDropzone.open()\r\n })\r\n } else {\r\n console.warn(\"Missing accept\")\r\n }\r\n }\r\n },\r\n dataURItoBlob(dataURI) {\r\n var byteString\r\n if (dataURI.split(\",\")[0].indexOf(\"base64\") >= 0)\r\n byteString = atob(dataURI.split(\",\")[1])\r\n else byteString = unescape(dataURI.split(\",\")[1])\r\n\r\n // separate out the mime component\r\n var mimeString = dataURI.split(\",\")[0].split(\":\")[1].split(\";\")[0]\r\n\r\n // write the bytes of the string to a typed array\r\n var ia = new Uint8Array(byteString.length)\r\n for (var i = 0; i < byteString.length; i++) {\r\n ia[i] = byteString.charCodeAt(i)\r\n }\r\n return new Blob([ia], { type: mimeString })\r\n },\r\n}\r\n\r\nexport default HUpload\r\n","import * as types from \"./App.constants\"\r\n\r\nexport const logout = () => ({\r\n type: types.LOGOUT,\r\n})\r\n\r\nexport const toggleSideNav = () => ({\r\n type: types.SIDE_NAV_CLOSE,\r\n})\r\n\r\nexport const sideNavUpdate = data => ({\r\n type: types.SIDE_NAV_UPDATE,\r\n items: data,\r\n})\r\n\r\nexport const fetchFirstSettingPending = () => {\r\n return {\r\n type: types.FETCH_FS_PENDING,\r\n }\r\n}\r\n\r\nexport const fetchFirstSettingSuccess = data => {\r\n return {\r\n type: types.FETCH_FS_SUCCESS,\r\n dataFirstSetting: data,\r\n }\r\n}\r\n\r\nexport const fetchFirstSettingError = error => {\r\n return {\r\n type: types.FETCH_FS_ERROR,\r\n error: error,\r\n }\r\n}\r\n\r\nexport const updateHeaderTitle = title => ({\r\n type: types.HEADER_TITLE_UPDATE,\r\n title: title,\r\n})\r\n"],"sourceRoot":""}