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AAS,6BAA+BC,UAClFF,EAAAA,EAAAA,KAACmK,EAAiB,MAE1B,IAAK,aACD,OAAOnK,EAAAA,EAAAA,KAAA,OAAKlC,GAAI,6BAA8BmC,UAAS,6BAA+BC,UAClFF,EAAAA,EAAAA,KAACkK,EAAa,MAEtB,IAAK,oBACD,OAAOlK,EAAAA,EAAAA,KAAA,OAAKlC,GAAI,6BAA8BmC,UAAS,6BAA+BC,UAClFF,EAAAA,EAAAA,KAACoK,EAAmB,CAACY,SAAUA,MAEvC,QACI,OAAOhL,EAAAA,EAAAA,KAACuL,EAAAA,GAAQ,CAACC,GAAI,YAAc7N,EAAe,wBAC1D,C","sources":["hook/useCategoryContext.ts","hook/useFetchBranch.ts","module/booking/component/TimeBoxList.tsx","module/booking/component/TimeButtonSubmit.tsx","module/booking/component/TimeCalendar.tsx","module/booking/component/TimeHeader.tsx","module/booking/constant/bookingDataDefault.ts","module/booking/hooks/useGetServiceAndTechnician.ts","module/booking/hooks/usePostBranch.tsx","module/booking/hooks/useSetDefaultBookingData.ts","module/booking/view/TimeBookingMobile.tsx","module/booking/view/BookingRouterView.tsx"],"sourcesContent":["import {useContext} from \"react\";\nimport {CategoryContext} from \"../context/CategoryContext\";\n\nexport const useCategoryContext = () => useContext(CategoryContext);","import { useAppContext } from \"./useAppContext\";\nimport AppUtil from \"../util/AppUtil\";\nimport { BookingApi } from \"../module/booking/Constant\";\nimport _ from \"lodash\";\nimport { useCategoryContext } from \"./useCategoryContext\";\nimport usePostBranch from \"../module/booking/hooks/usePostBranch\";\n\nconst useFetchBranch = () => {\n    const { appState, setAppState } = useAppContext()!;\n    const { postBranch } = usePostBranch()\n    const { setCateState } = useCategoryContext()!;\n\n    const fetchBranch = async () => {\n        setAppState({ loading: true })\n        const requestGetBranch = await AppUtil.getApi(BookingApi.getBranch, { locationCode: appState.locationCode })\n\n        if (_.get(requestGetBranch, \"data.success\") && _.get(requestGetBranch, \"data.result\")) {\n            const dataBranch = _.get(requestGetBranch, \"data.result\")\n            const id = _.get(dataBranch, '0.id')\n            const name = _.get(dataBranch, '0.name')\n            const branch = _.get(dataBranch, '0')\n            let branchConfigs = _.get(dataBranch, \"0.branchConfigs\");\n            if (_.size(dataBranch) === 1) {\n                postBranch({ id, name, branch, resetData: false })\n                setCateState({ branchData: dataBranch })\n            } else {\n                setCateState({ branchData: dataBranch })\n            }\n\n            if (!_.isNull(branchConfigs)) {\n                const findSymbol = _.find(\n                    branchConfigs,\n                    (x) => _.get(x, \"type\") === \"SYMBOL_MONEY\"\n                );\n                let symbol = \"CAD\";\n                if (findSymbol) {\n                    symbol = findSymbol.value;\n                }\n                AppUtil.GLOBAL_SYMBOL_MONEY = symbol;\n\n                const findBookingConfirm = _.find(\n                    branchConfigs,\n                    (x) => _.get(x, \"type\") === \"BRANCH_BOOKING_CONFIRMED\"\n                );\n                if (findBookingConfirm) {\n                    AppUtil.GLOBAL_BOOKING_CONFIRMED = findBookingConfirm.value;\n                }\n\n                const findBookingCongratulations = _.find(\n                    branchConfigs,\n                    (x) => _.get(x, \"type\") === \"BRANCH_BOOKING_CONGRATULATIONS\"\n                );\n                if (findBookingCongratulations) {\n                    AppUtil.GLOBAL_BOOKING_CONGRATULATIONS = findBookingCongratulations.value;\n                }\n\n            }\n\n        } else {\n            AppUtil.ToastSuccess(\"Cannot load data from server!\")\n        }\n        setTimeout(() => {\n            setAppState({ loading: false })\n        }, 300)\n    }\n    return { fetchBranch }\n}\nexport default useFetchBranch;\n","import React from 'react';\nimport moment, {Moment} from \"moment\"\nimport {useBookingInfoContext} from \"../../../hook/useBookingInfoContext\";\nimport _ from \"lodash\"\nimport {useAppContext} from \"../../../hook/useAppContext\";\nimport {t} from '@core/idtek-component';\n\nconst TimeBoxList = ({state, setState}: {\n    state: {\n        currentPickingDate?: Moment;\n        isSelectAble?: boolean;\n        disabledDay?: any[];\n        startTime?: moment.Moment | null;\n        timePickerData?: {\n            label: string;\n            dateTime: string;\n            isBookAvailable: boolean;\n        }[];\n        services?: any[]\n    }, setState?: any\n}) => {\n\n    const { bookingInfoState } = useBookingInfoContext()!;\n\n    const { appState } = useAppContext()!;\n\n\n    const onTimeSelected = (timeEle: any) => {\n        const elementById = document.getElementById(timeEle.label);\n        if (elementById?.classList.contains(\"time-item-disabled\")) {\n            return;\n        }\n\n        setState({\n            ...state,\n            isSelectAble: true,\n            startTime: _.get(timeEle, \"dateTime\"),\n            services: _.get(timeEle, \"guests\"),\n            servicesForValidation: _.get(timeEle, \"guestForValidates\")\n        })\n    };\n\n    const renderTimeItem = (element: any, index: number) => {\n        const isDisabledTime = moment(element.dateTime).isBefore(moment().add(0, \"minute\")) || !element.isBookAvailable ? \" time-item-disabled\" : \"\";\n        const isActiveTime = (!state.startTime && moment(element.dateTime).isSame(bookingInfoState.startTime))\n        || (state.startTime && moment(element.dateTime).isSame(state.startTime)) ? \" time-item-active\" : \"\";\n        return (\n            <div key={index} className={\"time-container\"}>\n                <div id={element.dateTime.trim()}\n                    onClick={() => onTimeSelected(element)}\n                    className={`time-item${isActiveTime}${isDisabledTime}`}>\n                    <span>{element.label}</span>\n                </div>\n            </div>\n        );\n    }\n\n    const renderTimeList = (name: string, list: any[]) => {\n        const newList = list.filter((element) => {\n            return !(moment(element.dateTime).isBefore(moment().add(0, \"minute\")) || !element.isBookAvailable);\n        })\n\n        if (_.isEmpty(newList)) {\n            return <></>\n        }\n\n        return (\n            <div className={\"column-time-piker\"}>\n                <div className={\"column-time-piker-header\"}>{name}</div>\n                {newList?.map((element, index) => {\n                    return renderTimeItem(element, index)\n                })}\n            </div>\n        );\n    }\n\n    const morningList = _.filter(state.timePickerData, (ele) => moment(ele.dateTime).isBefore(moment(ele.dateTime).hour(11).minute(59)));\n    const afternoonList = _.filter(\n        state.timePickerData,\n        (ele) => moment(ele.dateTime).isAfter(moment(ele.dateTime).hour(11).minute(59)) && moment(ele.dateTime).isBefore(moment(ele.dateTime).hour(16).minute(59))\n    );\n\n    const eveningList = _.filter(state.timePickerData, (ele) => moment(ele.dateTime).isAfter(moment(ele.dateTime).hour(16).minute(59)));\n\n    const renderContactBranchLine = () => {\n        return <div style={{ color: `var(--theme-color)`, fontSize: \"16px\", textAlign: \"center\" }}>\n            {t(\"CANNOT_FIND_A_TIME_SLOT_THAT_WORKS_FOR_YOU?\") + \" \"}\n            {t(\"PLEASE_CALL_US_AT\") + \" \"} <a href={`tel:${appState?.location?.phone}`}\n                style={{ fontWeight: 600 }}>{appState?.location?.phoneDisplay}</a>\n            {\" \" + t(\"AND_WE_CAN_ASSIST_IN_FINDING_YOU_AN_APPOINTMENT_THAT_WORKS_WITH_YOUR_SCHEDULE\")}\n        </div>\n    }\n\n    return (\n        <div id={\"branch-section\"} className=\"branch-section col-12\">\n            <h5 className={\"section-title\"}>{`2. ${t(\"PICK_TIME\").toUpperCase()}`}</h5>\n\n            <div className=\"time-booking-picker\">\n                {renderTimeList(t(\"MORNING\").toUpperCase(), morningList)}\n\n                {renderTimeList(t(\"AFTERNOON\").toUpperCase(), afternoonList)}\n\n                {renderTimeList(t(\"EVENING\").toUpperCase(), eveningList)}\n            </div>\n            {renderContactBranchLine()}\n        </div>\n    );\n};\n\nexport default TimeBoxList;\n","import React from 'react';\nimport {Affix, Button, t} from \"@core/idtek-component\";\nimport {Moment} from \"moment\";\n\nconst TimeButtonSubmit = ({state, postTime}: {\n    state: {\n        currentPickingDate?: Moment;\n        isSelectAble?: boolean;\n        disabledDay?: any[];\n        timePickerData?: any[];\n        services?: any[]\n    },\n    postTime: any\n}) => {\n    if (!state.isSelectAble) {\n        return <></>\n    }\n\n    return (\n        <Affix offsetBottom={0}>\n            <div id={\"branch-section\"} className=\"branch-section col-12 submit-button-container\">\n                <div className=\"submit-button-container\">\n                    <Button className={!state.isSelectAble ? \"time-button-disabled\" : \"time-button\"} type=\"primary\"\n                            htmlType=\"submit\" onClick={postTime}>\n                        {t(\"CONTINUE_BOOKING\")}\n                    </Button>\n                </div>\n            </div>\n        </Affix>\n    );\n};\n\nexport default TimeButtonSubmit;","import React from 'react';\nimport {Calendar} from \"@core/antd-component\";\nimport moment, {Moment} from \"moment\";\nimport _ from \"lodash\"\nimport {Icon, t} from \"@core/idtek-component\"\n\nconst TimeCalendar = ({state, setState}: {\n    state: {\n        currentPickingDate?: Moment;\n        isSelectAble?: boolean;\n        disabledDay?: any[];\n        timePickerData?: any[];\n        services?: any[]\n    }, setState?: any\n}) => {\n    const disabledDateChecking = (currentDate: Moment) => {\n        if (currentDate.isBefore(moment(), \"day\")) {\n            return true;\n        }\n        const filter = _.filter(state.disabledDay, x => {\n            return moment(x).isSame(currentDate, \"day\")\n        })\n\n        return !_.isEmpty(filter);\n    };\n\n    const onChangeCalendar = (date: Moment) => {\n        setState({...state, currentPickingDate: date});\n    };\n\n    return (\n        <div id={\"branch-section\"} className=\"branch-section col-12 calendar-section\">\n            <h5 className={\"section-title\"}>{`1. ${t(\"PICK_DATE\")}`}</h5>\n            <Calendar\n                fullscreen={false}\n                headerRender={({value, type, onChange}) => {\n                    return (\n                        <div\n                            style={{\n                                width: \"100%\",\n                                display: \"flex\",\n                                justifyContent: \"center\",\n                                fontSize: \"20px\",\n                                lineHeight: \"35px\",\n                            }}\n                        >\n                            <Icon type={'left'} onClick={() => {\n                                const newMoment = _.cloneDeep(value).add(-1, \"month\");\n                                onChange(newMoment);\n                            }}/>\n\n                            <div\n                                style={{\n                                    flex: 1,\n                                    display: \"flex\",\n                                    justifyContent: \"center\",\n                                }}\n                            >\n                                {\" \"}\n                                {moment(value).format(\"MMMM\")}\n                            </div>\n                            <Icon type={'right'} onClick={() => {\n                                const newMoment = _.cloneDeep(value).add(1, \"month\");\n                                onChange(newMoment);\n                            }}/>\n\n                        </div>\n                    );\n                }}\n                disabledDate={disabledDateChecking}\n                onChange={onChangeCalendar}\n                defaultValue={state.currentPickingDate as any}\n            />\n        </div>\n    );\n};\n\nexport default TimeCalendar;","import React from 'react';\nimport {useNavigate} from \"react-router-dom\";\nimport {useAppContext} from \"../../../hook/useAppContext\";\nimport {Icon} from \"@core/idtek-component\"\n\nconst TimeHeader = ({title}: { title: string }) => {\n    const navigate = useNavigate();\n    const {appState} = useAppContext()!;\n    return (\n        <div className={\"booking-header\"}\n             style={appState.isMobile ? {boxShadow: '0 0 10px var(--theme-color-boxshadow)'} : {}}>\n            <Icon type={'arrow-left'} style={{fontSize: \"35px\"}}\n                  onClick={() => navigate(-1)}/>\n            <h1 className=\"title\">{title}</h1>\n        </div>\n    );\n};\n\nexport default TimeHeader;","import IBookingData from \"../../../interface/IBooking\";\n\nexport const defaultBookingData: IBookingData = {\n    branch: null,\n    guest: [],\n    guests: [],\n    startTime: null,\n    sessionId: '',\n    quantity: undefined,\n    isFirst: true,\n    block: false,\n    sex: 'any',\n    technician: null,\n    customerName: null,\n    phone: null,\n    description: null,\n    email: null,\n    bookingDataFromApi: undefined,\n    customer: undefined\n};","import AppUtil from \"../../../util/AppUtil\";\nimport {BookingApi} from \"../Constant\";\nimport _ from \"lodash\";\nimport {useAppContext} from \"../../../hook/useAppContext\";\nimport {useCategoryContext} from \"../../../hook/useCategoryContext\";\n\nconst UseGetServiceAndTechnician = ({branchIdList}: { branchIdList?: (string | null)[] }) => {\n    const {\n        appState, setAppState\n    } = useAppContext()!;\n    const {setCateState} = useCategoryContext()!;\n    const FetchServiceAndTechnician = async (branchId: string) => {\n        setAppState({loading: true})\n        const param = branchId ? {branchIdList: [branchId]} : {branchIdList}\n\n        const requestGetService = AppUtil.getApi(BookingApi.getService, param)\n        const requestTechnician = AppUtil.getApi(BookingApi.getTechnician, param)\n\n        const [responseService, responseTechnician] = await AppUtil.axios.all([requestGetService, requestTechnician]);\n\n        if (_.get(responseService, \"data.success\") === true) {\n            setCateState({serviceData: _.get(responseService, \"data.result\")})\n        }\n        if (_.get(responseTechnician, \"data.success\") === true) {\n            setCateState({\n                technician: _.get(responseTechnician, \"data.result.technician\"),\n                skillsData: _.get(responseTechnician, \"data.result.skill\")\n            })\n        }\n        setTimeout(() => {\n            setAppState({loading: false})\n        }, 300)\n    }\n    return {FetchServiceAndTechnician}\n}\nexport default UseGetServiceAndTechnician;","import AppUtil from \"../../../util/AppUtil\";\nimport {BookingApi} from \"../Constant\";\nimport _ from \"lodash\";\nimport {defaultBookingData} from \"../constant/bookingDataDefault\";\nimport {useAppContext} from \"../../../hook/useAppContext\";\nimport {useBookingInfoContext} from \"../../../hook/useBookingInfoContext\";\nimport axios from \"axios\";\nimport IBranch from \"../../../interface/IBranch\";\n\nconst usePostBranch = () => {\n    const {setAppState} = useAppContext()!;\n    const {bookingInfoState, setBookingInfoState} = useBookingInfoContext()!;\n    const postBranch = async ({\n                                  id,\n                                  name,\n                                branch,\n                                  resetData = false\n                              }: { id: string; name: string,branch: IBranch, resetData: boolean }): Promise<void> => {\n        if (id) {\n            // const sectionInStore = localStorage.getItem(\"SessionCacheId\")\n            setAppState({loading: true})\n            const fetchs = [\n                AppUtil.postApi(`${BookingApi.postBranch}`, {\n                    branchId: id,\n                    sessionId: bookingInfoState.sessionId,\n                })\n            ]\n            // if (sectionInStore) {\n            //     fetchs.push(AppUtil.getApi(BookingApi.getCache, {\n            //         sessionId: sectionInStore,\n            //     }))\n            // }\n            axios.all(fetchs)\n                .then(([res1,\n                           //    res2\n                       ]) => {\n                    let defaultData = {}\n                    if (_.get(res1, \"data.success\")) {\n                        defaultData = {\n                            ...defaultBookingData,\n                            isFirst: resetData ? null : bookingInfoState?.isFirst,\n                            phone: resetData ? null : bookingInfoState?.phone,\n                            email: resetData ? null : bookingInfoState?.email,\n                            customerName: resetData ? null : bookingInfoState.customerName,\n                            sessionId: _.get(res1, \"data.result.sessionId\"),\n\n                        }\n                    }\n                    // if (_.get(res2, \"data.success\")) {\n                    //     const rs2 = _.get(res2, \"data.result\")\n                    //     if (rs2) {\n                    //         defaultData = {\n                    //             ...defaultData,\n                    //             guest: rs2.guest || [],\n                    //             quantity: rs2.quantity,\n                    //             startTime: rs2.startTime,\n                    //             phone: rs2.phone,\n                    //             email: rs2.email,\n                    //             customerName: rs2.customerName,\n                    //             description: rs2.description,\n                    //\n                    //         }\n                    //     }\n                    //\n                    // }\n                    setBookingInfoState({\n                        ...defaultData, guest: [], branch: {\n                            id: id,\n                            name,\n                            code: ''\n                        }\n                    })\n                    setAppState({numberLimitBookGroup: _.get(branch, \"numberLimitBookGroup\")});\n                }).catch((error) => {\n                AppUtil.ToastError(\"Server error! Try again!\");\n                console.log('Function: error -> : ', error);\n            });\n\n            setTimeout(() => {\n                setAppState({loading: false});\n            }, 300)\n\n\n        } else {\n            AppUtil.ToastError(\"Cannot send branch data!\");\n        }\n    };\n    return {postBranch}\n}\nexport default usePostBranch;\n","import {useCategoryContext} from \"../../../hook/useCategoryContext\";\nimport _ from \"lodash\";\nimport usePostBranch from \"./usePostBranch\";\nimport {useBookingInfoContext} from \"../../../hook/useBookingInfoContext\";\nimport {defaultBookingData} from \"../constant/bookingDataDefault\";\n\nconst UseSetDefaultBookingData = () => {\n    const {cateState, setCateState} = useCategoryContext()!;\n    const {setBookingInfoState, bookingInfoState} = useBookingInfoContext()!;\n\n    const {postBranch} = usePostBranch()\n    const setDefaultData = (resetData = false) => {\n        if (_.size(cateState.branchData) === 1) {\n            const id = _.get(cateState.branchData, '0.id')\n            const name = _.get(cateState.branchData, '0.name')\n            const branch = _.get(cateState.branchData, '0')\n            postBranch({id, name, branch, resetData})\n        } else {\n            setBookingInfoState({\n                ...defaultBookingData,\n            });\n            console.log(bookingInfoState)\n        }\n    }\n\n    return {setDefaultData}\n};\n\nexport default UseSetDefaultBookingData;","import React, {useEffect} from 'react';\nimport TimeHeader from \"../component/TimeHeader\";\nimport TimeCalendar from \"../component/TimeCalendar\";\nimport TimeBoxList from \"../component/TimeBoxList\";\nimport {t, useMergeState} from \"@core/idtek-component\";\nimport moment, {Moment} from \"moment\";\nimport {useBookingInfoContext} from \"../../../hook/useBookingInfoContext\";\nimport AppUtil from \"../../../util/AppUtil\";\nimport {BookingApi} from \"../Constant\";\nimport _ from \"lodash\";\nimport \"../style/time-booking.scss\";\nimport TimeButtonSubmit from \"../component/TimeButtonSubmit\";\nimport {useNavigate} from \"react-router-dom\";\nimport {useAppContext} from \"../../../hook/useAppContext\";\nimport useSetDefaultBookingData from \"../hooks/useSetDefaultBookingData\";\n\nconst TimeBookingMobile = () => {\n\n    const {bookingInfoState, setBookingInfoState} = useBookingInfoContext()!;\n    const {setDefaultData} = useSetDefaultBookingData();\n    const {appState, setAppState} = useAppContext()!;\n\n    const [state, setState] = useMergeState<{\n        currentPickingDate: Moment;\n        isSelectAble: boolean;\n        disabledDay: any[];\n        startTime: moment.Moment | null;\n        timePickerData: {\n            label: string;\n            dateTime: string;\n            isBookAvailable: boolean;\n        }[];\n        services: any[];\n        servicesForValidation?: any[]\n    }>({\n        currentPickingDate: bookingInfoState.startTime ? moment(bookingInfoState.startTime) : moment(),\n        isSelectAble: !!bookingInfoState.startTime,\n        disabledDay: [] as any[],\n        startTime: null as moment.Moment | null,\n        timePickerData: [] as {\n            label: string;\n            dateTime: string;\n            isBookAvailable: boolean;\n        }[],\n        services: [],\n        servicesForValidation: []\n    })\n\n    const navigate = useNavigate();\n\n    useEffect(() => {\n        if (bookingInfoState.branch === null || bookingInfoState.guest === undefined || _.size(bookingInfoState.guest) === 0) {\n            navigate({\n                pathname: `/booking/${appState.locationCode}`,\n                search: `?action=set-booking`\n            });\n        }\n    }, [bookingInfoState.guest])\n\n    const fetchMonth = async () => {\n        setAppState({loading: true})\n        const responseWorkingTime = await AppUtil.getApi(`${BookingApi.getMonthAvailable}`, {\n            dateTime: state.currentPickingDate.format(\"yyyy-MM-DD\"),\n            sessionId: bookingInfoState.sessionId,\n        })\n\n        if (_.get(responseWorkingTime, \"data.success\")) {\n            const data = _.get(responseWorkingTime, \"data.result\");\n            const listDate = _.map(data, x => moment(x.toString()));\n            setState({disabledDay: listDate});\n        } else if (_.get(responseWorkingTime, \"data.success\") == false) {\n            setState({timePickerData: []})\n            AppUtil.ToastError(_.get(responseWorkingTime, \"data.message\"));\n        }\n        setTimeout(() => {\n            setAppState({loading: false})\n        }, 300)\n    }\n\n    const fetchTime = async () => {\n        setAppState({loading: true})\n        const responseWorkingTime = await AppUtil.getApi(`${BookingApi.getTimeAvailable}`, {\n            dateTime: state.currentPickingDate.format(\"yyyy-MM-DD\"),\n            sessionId: bookingInfoState.sessionId,\n        })\n        if (_.get(responseWorkingTime, \"data.success\")) {\n            setState({timePickerData: _.get(responseWorkingTime, \"data.result\")})\n\n        } else if (_.get(responseWorkingTime, \"data.error.outOfSession\")) {\n            setDefaultData();\n        } else if (_.get(responseWorkingTime, \"data.success\") == false && _.get(responseWorkingTime, \"data.error.dayNotAvailable\") == false) {\n            setState({timePickerData: []})\n            AppUtil.ToastError(t(_.get(responseWorkingTime, \"data.message\")));\n        }else if (_.get(responseWorkingTime, \"data.success\") == false && _.get(responseWorkingTime, \"data.error.dayNotAvailable\") == true) {\n            setState({timePickerData: []})\n            AppUtil.ToastError(t(_.get(responseWorkingTime, \"data.message\")));\n        }\n        setTimeout(() => {\n            setAppState({loading: false})\n        }, 300)\n\n    }\n\n    useEffect(() => {\n        fetchMonth();\n    }, [state?.currentPickingDate?.month()]);\n\n    useEffect(() => {\n        fetchTime();\n    }, [state?.currentPickingDate]);\n\n    const postTime = async () => {\n        setAppState({loading: true})\n\n        const response = await AppUtil.postApi(BookingApi.postTime,\n            {\n                startTime: moment(state.startTime).format(\"YYYY-MM-DD HH:mm:ss\"),\n                guest: state.services,\n                guestForValidates: state.servicesForValidation,\n                sessionId: bookingInfoState.sessionId,\n            })\n\n        if (response?.data?.success) {\n            setBookingInfoState({\n                startTime: state.startTime,\n            });\n        } else if (response?.data?.error?.outOfSession) {\n            AppUtil.ToastWarning(t(\"SESSION_TIMEOUT!\"));\n            setDefaultData();\n        } else {\n            AppUtil.ToastError(t(\"CANNOT_SEND_TIME_DATA!\"));\n        }\n        setTimeout(() => {\n            setAppState({loading: false});\n        }, 300)\n        navigate && navigate({\n            pathname: `/booking/${appState.locationCode}`,\n            search: `?action=set-booking`\n        });\n    };\n\n    const renderHeader = () => {\n        return <TimeHeader title={t(\"SELECT_TIME\").toUpperCase()}/>\n    }\n\n    const renderCalendar = () => {\n        return <TimeCalendar state={state} setState={setState}/>\n    }\n\n    const renderListTime = () => {\n        return <TimeBoxList state={state} setState={setState}/>\n    }\n\n    const renderButtonSubmit = () => {\n        return <TimeButtonSubmit state={state} postTime={postTime}/>\n    }\n\n    return (\n        <div id={\"booking-container\"} className=\"booking-container  time-booking-module\">\n            <div id={\"booking-step-contain\"} className=\"booking-step-contain\"\n                 style={appState.isMobile ? {margin: 'none'} : {}}>\n                <div className=\"technician-contain\">\n                    {renderHeader()}\n                </div>\n                <div>\n                    {renderCalendar()}\n                    {renderListTime()}\n                </div>\n                {renderButtonSubmit()}\n            </div>\n        </div>\n\n    );\n};\n\nexport default TimeBookingMobile;","import React, { lazy, useEffect } from 'react';\nimport { Navigate, useParams, useSearchParams } from \"react-router-dom\";\nimport { useAppContext } from \"../../../hook/useAppContext\";\nimport { useCategoryContext } from \"../../../hook/useCategoryContext\";\nimport _ from \"lodash\";\nimport { useBookingInfoContext } from \"../../../hook/useBookingInfoContext\";\nimport '../style/booking.scss'\nimport UseGetServiceAndTechnician from \"../hooks/useGetServiceAndTechnician\";\nimport TimeBookingMobile from './TimeBookingMobile';\nimport useFetchBranch from \"../../../hook/useFetchBranch\";\nimport { BRANCH_OPENING } from '../../review/Constant';\n\n\nconst Booking = lazy(() => import('./Booking'));\nconst BranchBooking = lazy(() => import('./BranchBooking'));\nconst ServiceBookingMobile = lazy(() => import('./ServiceBookingMobile'));\nconst ServiceBooking = lazy(() => import('./ServiceBooking'));\nconst TimeBooking = lazy(() => import('./TimeBooking'));\nconst TechnicianBookingMobile = lazy(() => import('./TechnicianBookingMobile'));\nconst TechnicianBooking = lazy(() => import('./TechnicianBooking'));\nconst BookingComplete = lazy(() => import('./BookingComplete'));\n\nconst ReviewBooking = lazy(() => import('./ReviewBooking'));\nconst RateReviewBooking = lazy(() => import('./RateReviewBooking'));\nconst DetailReviewBooking = lazy(() => import('./DetailReviewBooking'));\nconst BranchCloseIncoming = lazy(() => import('./BranchCloseIncoming'));\n\nconst BookingRouterView = () => {\n    const { locationCode } = useParams<{ locationCode?: string }>();\n    const { fetchBranch } = useFetchBranch();\n\n    const { cateState } = useCategoryContext()!;\n\n    const branchId = _.map(cateState.branchData, x => x.id || null);\n    const { FetchServiceAndTechnician } = UseGetServiceAndTechnician({ branchIdList: branchId });\n\n\n    const { appState, setAppState } = useAppContext()!;\n\n\n    const { bookingInfoState, setBookingInfoState } = useBookingInfoContext()!;\n\n    const [searchParams] = useSearchParams();\n\n    const action = searchParams.get(\"action\");\n\n    const guestDisplayIndex = searchParams.get('guestDisplayIndex');\n\n    const serviceId = searchParams.get('serviceId');\n\n    const reviewId = searchParams.get('reviewId');\n\n    const branchData = _.get(cateState, \"branchData\");\n\n    useEffect(() => {\n        appState.location && !cateState.branchData && fetchBranch()\n    }, [appState.location])\n\n    useEffect(() => {\n        setAppState({ locationCode: locationCode })\n    }, [locationCode])\n\n    useEffect(() => {\n        bookingInfoState.branch?.id && FetchServiceAndTechnician(bookingInfoState.branch?.id)\n    }, [bookingInfoState.branch?.id])\n\n\n    const classMobile = appState.isMobile ? \"booking-container-mobile\" : \"\"\n\n    if (branchData?.length === 1) {\n        const statusBranch = _.get(_.first(branchData), \"openingStatus\", \"\");\n        if (statusBranch !== BRANCH_OPENING) {\n            return <div className='branch-container-closed-incoming'>\n                <BranchCloseIncoming />\n            </div>\n        }\n    }\n    switch (action) {\n        case 'set-booking':\n            return <div id={\"booking-container-outsider\"} className=\"booking-container-outsider\">\n                <Booking />\n            </div>;\n        case 'set-branch':\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider ${classMobile}`}>\n                <BranchBooking />\n            </div>;\n\n        case 'set-service':\n            const service = appState.isMobile ? \"booking-container-mobile booking-container-service\"\n                : \"booking-container-mobile\"\n\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider ${service}`}>\n                {appState.isMobile ? <ServiceBookingMobile guestDisplayIndex={guestDisplayIndex} /> :\n                    <ServiceBooking guestDisplayIndex={guestDisplayIndex} />}\n            </div>;\n\n        case 'set-technician':\n            const classTech = appState.isMobile ? \"booking-container-mobile booking-container-tech\" : \"booking-container-mobile\"\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider ${classTech}`}>\n                {appState.isMobile ? <TechnicianBookingMobile\n                    serviceId={serviceId}\n                    guestDisplayIndex={guestDisplayIndex} /> :\n                    <TechnicianBooking serviceId={serviceId}\n                        guestDisplayIndex={guestDisplayIndex} />}\n            </div>;\n\n        case 'set-time':\n\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider ${classMobile}`}>\n                {appState.isMobile ? <TimeBookingMobile /> : <TimeBooking />}\n                {/* <TimeBooking/> */}\n            </div>;\n\n        case 'complete':\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider ${classMobile}`}>\n                {<BookingComplete />}\n            </div>;\n\n        case 'review':\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider`}>\n                <RateReviewBooking />\n            </div>;\n        case 'set-review':\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider`}>\n                <ReviewBooking />\n            </div>;\n        case 'set-detail-review':\n            return <div id={\"booking-container-outsider\"} className={`booking-container-outsider`}>\n                <DetailReviewBooking reviewId={reviewId} />\n            </div>;\n        default:\n            return <Navigate to={'/booking/' + locationCode + '?action=set-booking'} />\n    }\n};\n\nexport default BookingRouterView;"],"names":["useCategoryContext","useContext","CategoryContext","useFetchBranch","appState","setAppState","useAppContext","postBranch","usePostBranch","setCateState","fetchBranch","async","loading","requestGetBranch","AppUtil","getApi","BookingApi","getBranch","locationCode","_","dataBranch","id","name","branch","branchConfigs","resetData","branchData","findSymbol","x","symbol","value","GLOBAL_SYMBOL_MONEY","findBookingConfirm","GLOBAL_BOOKING_CONFIRMED","findBookingCongratulations","GLOBAL_BOOKING_CONGRATULATIONS","ToastSuccess","setTimeout","_ref","state","setState","bookingInfoState","useBookingInfoContext","renderTimeItem","element","index","isDisabledTime","moment","dateTime","isBefore","add","isBookAvailable","isActiveTime","startTime","isSame","_jsx","className","children","trim","onClick","timeEle","elementById","document","getElementById","label","classList","contains","_objectSpread","isSelectAble","services","servicesForValidation","onTimeSelected","concat","renderTimeList","list","newList","filter","_Fragment","_jsxs","map","morningList","timePickerData","ele","hour","minute","afternoonList","isAfter","eveningList","t","toUpperCase","renderContactBranchLine","_appState$location","_appState$location2","style","color","fontSize","textAlign","href","location","phone","fontWeight","phoneDisplay","postTime","Affix","offsetBottom","Button","type","htmlType","Calendar","fullscreen","headerRender","_ref2","onChange","width","display","justifyContent","lineHeight","Icon","newMoment","flex","format","disabledDate","currentDate","disabledDay","date","currentPickingDate","defaultValue","title","navigate","useNavigate","isMobile","boxShadow","defaultBookingData","guest","guests","sessionId","quantity","undefined","isFirst","block","sex","technician","customerName","description","email","bookingDataFromApi","customer","branchIdList","FetchServiceAndTechnician","param","branchId","requestGetService","getService","requestTechnician","getTechnician","responseService","responseTechnician","axios","all","serviceData","skillsData","setBookingInfoState","fetchs","postApi","then","res1","defaultData","code","numberLimitBookGroup","catch","error","ToastError","console","log","UseSetDefaultBookingData","cateState","setDefaultData","arguments","length","TimeBookingMobile","_state$currentPicking","useSetDefaultBookingData","useMergeState","useEffect","pathname","search","responseWorkingTime","getMonthAvailable","data","listDate","toString","fetchMonth","month","getTimeAvailable","fetchTime","_response$data","_response$data2","_response$data2$error","response","guestForValidates","success","outOfSession","ToastWarning","margin","TimeHeader","TimeCalendar","TimeBoxList","TimeButtonSubmit","Booking","lazy","BranchBooking","ServiceBookingMobile","ServiceBooking","TimeBooking","TechnicianBookingMobile","TechnicianBooking","BookingComplete","ReviewBooking","RateReviewBooking","DetailReviewBooking","BranchCloseIncoming","BookingRouterView","_bookingInfoState$bra3","useParams","UseGetServiceAndTechnician","searchParams","useSearchParams","action","get","guestDisplayIndex","serviceId","reviewId","_bookingInfoState$bra","_bookingInfoState$bra2","classMobile","BRANCH_OPENING","service","classTech","Navigate","to"],"sourceRoot":""}