import { useState } from 'react'; import { PATHS } from '@/shared/constants/paths'; import { useNavigate } from '@/shared/lib/hooks/use-navigate'; import { IMAGE_ROOT } from '@/shared/constants/common'; import { HeaderType } from '@/entities/common/model/types'; import { useExtensionKeyinApplyMutation } from '@/entities/additional-service/api/use-extension-keyin-apply-mutation'; import { useSetHeaderTitle, useSetHeaderType, useSetFooterMode, useSetOnBack } from '@/widgets/sub-layout/use-sub-layout'; import { number } from 'framer-motion'; export const KeyInPaymentRequestPage = () => { const { navigate } = useNavigate(); const { mutateAsync: keyInApply } = useExtensionKeyinApplyMutation(); useSetHeaderTitle('KEY-IN 결제'); useSetHeaderType(HeaderType.LeftArrow); useSetFooterMode(false); useSetOnBack(() => { navigate(PATHS.additionalService.keyInPayment.list); }); const callKeyInPaymentRequest = () => { let keyInApplyParams = { mid: 'string', goodsName: 'string', amount: 0, buyerName: 'string', email: 'string', phoneNumber: 'string', cardNo: 'string', cardExpirationDate: 'string', instmntMonth: 'string', moid: 'SMS', }; keyInApply(keyInApplyParams).then((rs) => { navigate(PATHS.additionalService.keyInPayment.requestSuccess); console.log(rs) }).catch(() => { }).finally(() => { }); }; const onClickToRequest = () => { callKeyInPaymentRequest(); }; return ( <>
가맹점 *
상품명 *
상품가격 *
구매자명 *
구매자 이메일 *
구매자 전화번호 *
카드번호 *
유효기간(월/년)*
할부 기간*
주문번호
) }