- ars,SMS,KeyIn 수정
This commit is contained in:
@@ -39,11 +39,14 @@ export interface ExtensionArsListParams {
|
|||||||
};
|
};
|
||||||
export interface ArsListContent {
|
export interface ArsListContent {
|
||||||
tid?: string;
|
tid?: string;
|
||||||
paymentDate?: string;
|
orderDate?: string;
|
||||||
paymentStatus?: PaymentStatus | string;
|
orderTime?: string;
|
||||||
orderStatus?: OrderStatus;
|
buyerName?: string;
|
||||||
arsPaymentMethod?: string;
|
buyerPhoneLast4?: string;
|
||||||
|
orderStatus?: string;
|
||||||
|
transactionType?: string;
|
||||||
amount?: number;
|
amount?: number;
|
||||||
|
statusColor?: string;
|
||||||
};
|
};
|
||||||
export interface ExtensionArsListResponse extends DefaulResponsePagination {
|
export interface ExtensionArsListResponse extends DefaulResponsePagination {
|
||||||
content: Array<ArsListContent>;
|
content: Array<ArsListContent>;
|
||||||
@@ -67,6 +70,7 @@ export interface ExtensionArsDetailResponse {
|
|||||||
corpName: string;
|
corpName: string;
|
||||||
mid: string;
|
mid: string;
|
||||||
arsPaymentMethod: string;
|
arsPaymentMethod: string;
|
||||||
|
amount: string;
|
||||||
paymentStatus: PaymentStatus;
|
paymentStatus: PaymentStatus;
|
||||||
orderStatus: string;
|
orderStatus: string;
|
||||||
paymentDate: string;
|
paymentDate: string;
|
||||||
@@ -89,4 +93,16 @@ export interface ExtensionArsApplyParams {
|
|||||||
email: string;
|
email: string;
|
||||||
arsPaymentMethod: string;
|
arsPaymentMethod: string;
|
||||||
};
|
};
|
||||||
export interface ExtensionArsApplyResponse {};
|
export interface ExtensionArsApplyResponse {
|
||||||
|
status: boolean;
|
||||||
|
error?: {
|
||||||
|
root?: string;
|
||||||
|
errKey?: string;
|
||||||
|
code?: string;
|
||||||
|
message?: string;
|
||||||
|
timestamp?: string;
|
||||||
|
details?: {
|
||||||
|
path?: string;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
@@ -93,8 +93,7 @@ export interface ExtensionKeyinDownloadExcelResponse {
|
|||||||
|
|
||||||
export interface ExtensionKeyinApplyParams extends ExtensionRequestParams {
|
export interface ExtensionKeyinApplyParams extends ExtensionRequestParams {
|
||||||
cardNo: string;
|
cardNo: string;
|
||||||
expYear: string;
|
cardExpire: string;
|
||||||
expMon: string;
|
|
||||||
instmnt: string;
|
instmnt: string;
|
||||||
amount: number;
|
amount: number;
|
||||||
productName: string;
|
productName: string;
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import { DefaulResponsePagination, DefaultRequestPagination } from '@/entities/c
|
|||||||
import { AdditionalServiceCategory, ExtensionRequestParams, FilterProps, ListItemProps } from '../types';
|
import { AdditionalServiceCategory, ExtensionRequestParams, FilterProps, ListItemProps } from '../types';
|
||||||
|
|
||||||
export enum SmsCl {
|
export enum SmsCl {
|
||||||
ALL = "",
|
ALL = "ALL",
|
||||||
VACCOUNT_REQ = "VACCOUNT_REQ",
|
VACCOUNT_REQ = "VACCOUNT_REQ",
|
||||||
VACCOUNT_REQ_DEPOSIT = "VACCOUNT_REQ_DEPOSIT"
|
VACCOUNT_REQ_DEPOSIT = "VACCOUNT_REQ_DEPOSIT"
|
||||||
}
|
}
|
||||||
@@ -15,9 +15,13 @@ export enum SmsPaymentSearchCl {
|
|||||||
export interface SmsPaymentListItem {
|
export interface SmsPaymentListItem {
|
||||||
mid?: string;
|
mid?: string;
|
||||||
tid?: string;
|
tid?: string;
|
||||||
paymentDate?: string;
|
buyerName?: string;
|
||||||
paymentStatus?: string;
|
buyerPhoneLast4?: string;
|
||||||
|
sendDate?: string;
|
||||||
|
amount?: number;
|
||||||
|
smsTypeName?: string;
|
||||||
smsCl?: string;
|
smsCl?: string;
|
||||||
|
resendEnabled?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SmsPaymentListProps {
|
export interface SmsPaymentListProps {
|
||||||
|
|||||||
@@ -60,8 +60,8 @@ export const ArsFilter = ({
|
|||||||
|
|
||||||
const [filterMid, setFilterMid] = useState<string>(mid);
|
const [filterMid, setFilterMid] = useState<string>(mid);
|
||||||
const [filterMoid, setFilterMoid] = useState<string>(moid);
|
const [filterMoid, setFilterMoid] = useState<string>(moid);
|
||||||
const [filterFromDate, setFilterFromDate] = useState<string>(moment(fromDate).format('YYYY.MM.DD'));
|
const [filterFromDate, setFilterFromDate] = useState<string>(moment(fromDate).format('YYYYMMDD'));
|
||||||
const [filterToDate, setFilterToDate] = useState<string>(moment(toDate).format('YYYY.MM.DD'));
|
const [filterToDate, setFilterToDate] = useState<string>(moment(toDate).format('YYYYMMDD'));
|
||||||
const [filterPaymentStatus, setFilterPaymentStatus] = useState<PaymentStatus>(paymentStatus);
|
const [filterPaymentStatus, setFilterPaymentStatus] = useState<PaymentStatus>(paymentStatus);
|
||||||
const [filterOrderStatus, setFilterOrderStatus] = useState<OrderStatus>(orderStatus);
|
const [filterOrderStatus, setFilterOrderStatus] = useState<OrderStatus>(orderStatus);
|
||||||
const [filterMinAmount, setFilterMinAmount] = useState<number | undefined>(minAmount);
|
const [filterMinAmount, setFilterMinAmount] = useState<number | undefined>(minAmount);
|
||||||
@@ -75,7 +75,7 @@ export const ArsFilter = ({
|
|||||||
|
|
||||||
const onClickToSetFilter = () => {
|
const onClickToSetFilter = () => {
|
||||||
setMid(filterMid);
|
setMid(filterMid);
|
||||||
setFilterMoid(filterMoid);
|
setMoid(filterMoid);
|
||||||
setFromDate(filterFromDate);
|
setFromDate(filterFromDate);
|
||||||
setToDate(filterToDate);
|
setToDate(filterToDate);
|
||||||
setPaymentStatus(filterPaymentStatus);
|
setPaymentStatus(filterPaymentStatus);
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ export const ListDateGroup = ({
|
|||||||
key={ key }
|
key={ key }
|
||||||
mid={ mid }
|
mid={ mid }
|
||||||
tid={ items[i]?.tid }
|
tid={ items[i]?.tid }
|
||||||
paymentDate= { items[i]?.paymentDate}
|
orderDate= { items[i]?.orderDate}
|
||||||
paymentStatus={ items[i]?.paymentStatus}
|
paymentStatus={ items[i]?.paymentStatus}
|
||||||
requestDate={ items[i]?.requestDate }
|
requestDate={ items[i]?.requestDate }
|
||||||
requestTime={ items[i]?.requestTime}
|
requestTime={ items[i]?.requestTime}
|
||||||
@@ -58,9 +58,10 @@ export const ListDateGroup = ({
|
|||||||
status={ items[i]?.status }
|
status={ items[i]?.status }
|
||||||
|
|
||||||
orderStatus={ items[i]?.orderStatus }
|
orderStatus={ items[i]?.orderStatus }
|
||||||
arsPaymentMethod={ items[i]?.arsPaymentMethod }
|
orderTime={ items[i]?.orderTime }
|
||||||
|
buyerPhoneLast4={ items[i]?.buyerPhoneLast4 }
|
||||||
buyerName={ items[i]?.buyerName}
|
buyerName={ items[i]?.buyerName}
|
||||||
|
statusColor={ items[i]?.statusColor}
|
||||||
cursorId={ items[i]?.cursorId}
|
cursorId={ items[i]?.cursorId}
|
||||||
subReqId={ items[i]?.subReqId}
|
subReqId={ items[i]?.subReqId}
|
||||||
requestId={ items[i]?.requestId}
|
requestId={ items[i]?.requestId}
|
||||||
|
|||||||
@@ -16,16 +16,12 @@ import { getPayoutStatusText } from '../model/payout/constant';
|
|||||||
|
|
||||||
export const ListItem = ({
|
export const ListItem = ({
|
||||||
additionalServiceCategory,
|
additionalServiceCategory,
|
||||||
mid, tid, paymentDate, paymentStatus,
|
mid, tid, orderDate, paymentStatus,
|
||||||
|
orderTime,buyerPhoneLast4,statusColor,
|
||||||
applicationDate, requestDate, bankName, accountNo, resultStatus, resultMessage,
|
applicationDate, requestDate, bankName, accountNo, resultStatus, resultMessage,
|
||||||
amount, sendMethod, processStatus, registDate,
|
amount, sendMethod, processStatus, registDate,
|
||||||
|
transactionTime,transactionCode,transactionType,
|
||||||
accountName,
|
accountName,submallId, settlementDate, companyName,orderStatus,
|
||||||
|
|
||||||
submallId, settlementDate, companyName,
|
|
||||||
|
|
||||||
orderStatus, arsPaymentMethod,
|
|
||||||
|
|
||||||
alimCl, sendType, sendCl,
|
alimCl, sendType, sendCl,
|
||||||
paymentMethod, receiverName,
|
paymentMethod, receiverName,
|
||||||
@@ -36,6 +32,7 @@ export const ListItem = ({
|
|||||||
|
|
||||||
smsCl, groupId, userMallId, transType,
|
smsCl, groupId, userMallId, transType,
|
||||||
authResult, failReason, requestTime,
|
authResult, failReason, requestTime,
|
||||||
|
resendEnabled,
|
||||||
onResendClick
|
onResendClick
|
||||||
}: ListItemProps) => {
|
}: ListItemProps) => {
|
||||||
const { navigate } = useNavigate();
|
const { navigate } = useNavigate();
|
||||||
@@ -59,16 +56,16 @@ export const ListItem = ({
|
|||||||
const getDotClass = (str?: string) => {
|
const getDotClass = (str?: string) => {
|
||||||
let rs = '';
|
let rs = '';
|
||||||
if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
||||||
if (paymentStatus === '') {
|
if (transactionType === '') {
|
||||||
rs = '';
|
rs = '';
|
||||||
}
|
}
|
||||||
else if (paymentStatus === "APPROVAL") {
|
else if (transactionType === "APPROVAL") {
|
||||||
rs = 'blue';
|
rs = 'blue';
|
||||||
}
|
}
|
||||||
else if (paymentStatus === "ALL_CANCEL") {
|
else if (transactionType === "FULL_CANCEL") {
|
||||||
rs = 'gray';
|
rs = 'gray';
|
||||||
}
|
}
|
||||||
else if (paymentStatus === 'AFTER_CANCEL') {
|
else if (transactionType === 'PARTIAL_CANCEL') {
|
||||||
rs = 'gray';
|
rs = 'gray';
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -143,6 +140,12 @@ export const ListItem = ({
|
|||||||
} else if (status === "FAIL") {
|
} else if (status === "FAIL") {
|
||||||
rs = 'gray';
|
rs = 'gray';
|
||||||
}
|
}
|
||||||
|
} else if (additionalServiceCategory === AdditionalServiceCategory.Ars) {
|
||||||
|
if (paymentStatus === "PENDING" || paymentStatus === "SUCCESS") {
|
||||||
|
rs = 'blue';
|
||||||
|
} else {
|
||||||
|
rs = 'gray';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return rs;
|
return rs;
|
||||||
|
|
||||||
@@ -231,8 +234,7 @@ export const ListItem = ({
|
|||||||
state: {
|
state: {
|
||||||
additionalServiceCategory: additionalServiceCategory,
|
additionalServiceCategory: additionalServiceCategory,
|
||||||
mid: mid,
|
mid: mid,
|
||||||
tid: tid,
|
tid: tid
|
||||||
amount: amount
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -261,7 +263,7 @@ export const ListItem = ({
|
|||||||
const getTime = () => {
|
const getTime = () => {
|
||||||
let timeStr = '';
|
let timeStr = '';
|
||||||
if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
||||||
let time = paymentDate?.substring(8, 12);
|
let time = transactionTime?.substring(0, 4);
|
||||||
timeStr = time?.substring(0, 2) + ':' + time?.substring(2, 4);
|
timeStr = time?.substring(0, 2) + ':' + time?.substring(2, 4);
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.AccountHolderAuth) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.AccountHolderAuth) {
|
||||||
@@ -289,8 +291,7 @@ export const ListItem = ({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.Ars) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.Ars) {
|
||||||
let time = paymentDate?.substring(8, 12);
|
timeStr = orderTime?.substring(0, 2) + ':' + orderTime?.substring(2, 4);
|
||||||
timeStr = time?.substring(0, 2) + ':' + time?.substring(2, 4);
|
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.Alimtalk) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.Alimtalk) {
|
||||||
let time = sendDate?.substring(8, 12);
|
let time = sendDate?.substring(8, 12);
|
||||||
@@ -323,7 +324,7 @@ export const ListItem = ({
|
|||||||
statusText = getSmsClName(smsCl);
|
statusText = getSmsClName(smsCl);
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
||||||
statusText = getKeyInPaymentPaymentStatusName(paymentStatus)
|
statusText = getKeyInPaymentPaymentStatusName(transactionType)
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.Ars) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.Ars) {
|
||||||
statusText = getArsPaymentStatusName(paymentStatus)
|
statusText = getArsPaymentStatusName(paymentStatus)
|
||||||
@@ -337,7 +338,7 @@ export const ListItem = ({
|
|||||||
const getTitle = () => {
|
const getTitle = () => {
|
||||||
let str: string | undefined = '';
|
let str: string | undefined = '';
|
||||||
if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
if (additionalServiceCategory === AdditionalServiceCategory.KeyInPayment) {
|
||||||
str = `${tid}(${amount})`;
|
str = `${transactionCode}`;
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.AccountHolderAuth) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.AccountHolderAuth) {
|
||||||
str = `${accountName}(${accountNo})`;
|
str = `${accountName}(${accountNo})`;
|
||||||
@@ -363,10 +364,15 @@ export const ListItem = ({
|
|||||||
str = `${accountName}(${accountNo})`;
|
str = `${accountName}(${accountNo})`;
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.SMSPayment) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.SMSPayment) {
|
||||||
str = `${paymentDate}(${paymentStatus})[추후 수정 필요]`
|
if (buyerPhoneLast4) {
|
||||||
|
str = `${buyerName}(${buyerPhoneLast4})`
|
||||||
|
} else {
|
||||||
|
str = `${buyerName}`
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.Ars) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.Ars) {
|
||||||
str = '이름(' + tid + ')';
|
str = `${buyerName}(${tid})`;
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.Alimtalk) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.Alimtalk) {
|
||||||
str = `${receiverName}(${getAlimtalkSendTypeText(sendType)})`;
|
str = `${receiverName}(${getAlimtalkSendTypeText(sendType)})`;
|
||||||
@@ -493,7 +499,7 @@ export const ListItem = ({
|
|||||||
<span className="separator">|</span>
|
<span className="separator">|</span>
|
||||||
<span>{getArsOrderStatusName(orderStatus)}</span>
|
<span>{getArsOrderStatusName(orderStatus)}</span>
|
||||||
<span className="separator">|</span>
|
<span className="separator">|</span>
|
||||||
<span>{arsPaymentMethod}</span>
|
<span>{transactionType}</span>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -625,12 +631,12 @@ export const ListItem = ({
|
|||||||
>{getAlimtalkSendClTypeText(sendCl)}</div>
|
>{getAlimtalkSendClTypeText(sendCl)}</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
else if (additionalServiceCategory === AdditionalServiceCategory.SMSPayment && onResendClick && tid) {
|
else if (additionalServiceCategory === AdditionalServiceCategory.SMSPayment && onResendClick && resendEnabled) {
|
||||||
rs.push(
|
rs.push(
|
||||||
<div
|
<div
|
||||||
key="sms-payment-amount"
|
key="sms-payment-amount"
|
||||||
className={`status-label success`}
|
className={`status-label success`}
|
||||||
onClick={() => mid && tid && onResendClick(mid, tid)}
|
onClick={() => mid && onResendClick(mid, tid || '')}
|
||||||
>{'재발송'}</div>
|
>{'재발송'}</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -30,8 +30,8 @@ export const SmsPaymentFilter = ({
|
|||||||
const [filterMid, setFilterMid] = useState<string>(mid);
|
const [filterMid, setFilterMid] = useState<string>(mid);
|
||||||
const [filterSearchCl, setFilterSearchCl] = useState<SmsPaymentSearchCl>(searchCl);
|
const [filterSearchCl, setFilterSearchCl] = useState<SmsPaymentSearchCl>(searchCl);
|
||||||
const [filterSearchValue, setFilterSearchValue] = useState<string>(searchValue);
|
const [filterSearchValue, setFilterSearchValue] = useState<string>(searchValue);
|
||||||
const [filterFromDate, setFilterFromDate] = useState<string>(moment(fromDate).format('YYYY.MM.DD'));
|
const [filterFromDate, setFilterFromDate] = useState<string>(moment(fromDate).format('YYYYMMDD'));
|
||||||
const [filterToDate, setFilterToDate] = useState<string>(moment(toDate).format('YYYY.MM.DD'));
|
const [filterToDate, setFilterToDate] = useState<string>(moment(toDate).format('YYYYMMDD'));
|
||||||
const [filterSmsCl, setFilterSmsCl] = useState<SmsCl>(smsCl);
|
const [filterSmsCl, setFilterSmsCl] = useState<SmsCl>(smsCl);
|
||||||
|
|
||||||
const midOptions = useStore.getState().UserStore.selectOptionsMids;
|
const midOptions = useStore.getState().UserStore.selectOptionsMids;
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
import { SmsPaymentListItem, SmsPaymentListProps } from '../../model/sms-payment/types';
|
import { SmsPaymentListProps } from '../../model/sms-payment/types';
|
||||||
import { AdditionalServiceCategory } from '../../model/types';
|
|
||||||
import { ListDateGroup } from '../list-date-group';
|
import { ListDateGroup } from '../list-date-group';
|
||||||
|
|
||||||
export const SmsPaymentList = ({
|
export const SmsPaymentList = ({
|
||||||
@@ -16,24 +15,26 @@ export const SmsPaymentList = ({
|
|||||||
for (let i = 0; i < listItems.length; i++) {
|
for (let i = 0; i < listItems.length; i++) {
|
||||||
let items = listItems[i];
|
let items = listItems[i];
|
||||||
if(!!items) {
|
if(!!items) {
|
||||||
let paymentDate = items?.paymentDate;
|
let sendDate = items?.sendDate;
|
||||||
paymentDate = paymentDate?.substring(0, 8);
|
sendDate = sendDate?.substring(0, 8);
|
||||||
if(!!paymentDate) {
|
if(!!sendDate) {
|
||||||
if(i === 0) {
|
if(i === 0) {
|
||||||
date = paymentDate;
|
date = sendDate;
|
||||||
}
|
}
|
||||||
if(date !== paymentDate) {
|
if(date !== sendDate) {
|
||||||
if(list.length > 0) {
|
if(list.length > 0) {
|
||||||
rs.push(
|
rs.push(
|
||||||
<ListDateGroup
|
<ListDateGroup
|
||||||
|
onResendClick={onResendClick}
|
||||||
additionalServiceCategory={additionalServiceCategory}
|
additionalServiceCategory={additionalServiceCategory}
|
||||||
key={ date + '-' + i}
|
key={ date + '-' + i}
|
||||||
|
mid={mid}
|
||||||
date={ date }
|
date={ date }
|
||||||
items={ list }
|
items={ list }
|
||||||
></ListDateGroup>
|
></ListDateGroup>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
date = paymentDate;
|
date = sendDate;
|
||||||
list = [];
|
list = [];
|
||||||
}
|
}
|
||||||
list.push(items);
|
list.push(items);
|
||||||
|
|||||||
@@ -9,13 +9,15 @@ export interface LoginTypeBottomSheetProps {
|
|||||||
loginType: LoginType;
|
loginType: LoginType;
|
||||||
setLoginType: (loginType: string) => void;
|
setLoginType: (loginType: string) => void;
|
||||||
onBiometricRegistered?: () => void;
|
onBiometricRegistered?: () => void;
|
||||||
|
isAndroid: boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const LoginTypeBottomSheet = ({
|
export const LoginTypeBottomSheet = ({
|
||||||
setLoginTypeBottomSheetOn,
|
setLoginTypeBottomSheetOn,
|
||||||
loginType,
|
loginType,
|
||||||
setLoginType,
|
setLoginType,
|
||||||
onBiometricRegistered
|
onBiometricRegistered,
|
||||||
|
isAndroid
|
||||||
}: LoginTypeBottomSheetProps) => {
|
}: LoginTypeBottomSheetProps) => {
|
||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
const { registerBiometric, setLoginType: setLoginTypeNative } = useAppBridge();
|
const { registerBiometric, setLoginType: setLoginTypeNative } = useAppBridge();
|
||||||
@@ -25,6 +27,14 @@ export const LoginTypeBottomSheet = ({
|
|||||||
};
|
};
|
||||||
const onChangeLoginType = async (type: string) => {
|
const onChangeLoginType = async (type: string) => {
|
||||||
if (loginType !== type) {
|
if (loginType !== type) {
|
||||||
|
if (isAndroid) {
|
||||||
|
setLoginTypeNative(type).then(() => {
|
||||||
|
setLoginType(type);
|
||||||
|
onClickToClose();
|
||||||
|
}).catch(() => {
|
||||||
|
onClickToClose();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
if (type === 'BIOMETRIC') {
|
if (type === 'BIOMETRIC') {
|
||||||
onClickToClose();
|
onClickToClose();
|
||||||
registerBiometric().then(() => {
|
registerBiometric().then(() => {
|
||||||
@@ -41,6 +51,8 @@ export const LoginTypeBottomSheet = ({
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@@ -30,7 +30,6 @@ export const ArsDetailPage = () => {
|
|||||||
|
|
||||||
const tid = location.state.tid;
|
const tid = location.state.tid;
|
||||||
const mid = location.state.mid;
|
const mid = location.state.mid;
|
||||||
const amount = location.state.amount;
|
|
||||||
|
|
||||||
const [detail, setDetail] = useState<ExtensionArsDetailResponse>();
|
const [detail, setDetail] = useState<ExtensionArsDetailResponse>();
|
||||||
const [bottomSheetOn, setBottomSheetOn] = useState<boolean>(false);
|
const [bottomSheetOn, setBottomSheetOn] = useState<boolean>(false);
|
||||||
@@ -86,7 +85,7 @@ export const ArsDetailPage = () => {
|
|||||||
<div className="num-amount">
|
<div className="num-amount">
|
||||||
<span className="amount">
|
<span className="amount">
|
||||||
<NumericFormat
|
<NumericFormat
|
||||||
value={ amount }
|
value={ detail?.amount }
|
||||||
thousandSeparator
|
thousandSeparator
|
||||||
displayType="text"
|
displayType="text"
|
||||||
suffix='원'
|
suffix='원'
|
||||||
@@ -153,7 +152,7 @@ export const ArsDetailPage = () => {
|
|||||||
<button
|
<button
|
||||||
className="btn-50 btn-blue flex-1"
|
className="btn-50 btn-blue flex-1"
|
||||||
onClick={ () => onClickToOpenResendBottomSheet() }
|
onClick={ () => onClickToOpenResendBottomSheet() }
|
||||||
disabled={ detail?.orderStatus !== OrderStatus.PENDING }
|
//disabled={ detail?.orderStatus !== OrderStatus.PENDING }
|
||||||
>SMS 재전송</button>
|
>SMS 재전송</button>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|||||||
@@ -187,8 +187,8 @@ export const ArsListPage = () => {
|
|||||||
for (let i = 0; i < listItems.length; i++) {
|
for (let i = 0; i < listItems.length; i++) {
|
||||||
let item = listItems[i];
|
let item = listItems[i];
|
||||||
if (!!item) {
|
if (!!item) {
|
||||||
let paymentDate = item?.paymentDate || '';
|
let orderDate = item?.orderDate || '';
|
||||||
let itemDate = paymentDate.substring(0, 8);
|
let itemDate = orderDate.substring(0, 8);
|
||||||
if (!!itemDate) {
|
if (!!itemDate) {
|
||||||
if (i === 0) {
|
if (i === 0) {
|
||||||
date = itemDate;
|
date = itemDate;
|
||||||
|
|||||||
@@ -11,13 +11,17 @@ import {
|
|||||||
useSetFooterMode,
|
useSetFooterMode,
|
||||||
useSetOnBack
|
useSetOnBack
|
||||||
} from '@/widgets/sub-layout/use-sub-layout';
|
} from '@/widgets/sub-layout/use-sub-layout';
|
||||||
import { ArsPaymentMethod, ExtensionArsApplyParams } from '@/entities/additional-service/model/ars/types';
|
import { ArsPaymentMethod, ExtensionArsApplyParams, ExtensionArsApplyResponse } from '@/entities/additional-service/model/ars/types';
|
||||||
import { ArsRequestSuccessPage } from './request-success-page';
|
import { ArsRequestSuccessPage } from './request-success-page';
|
||||||
|
import { useStore } from '@/shared/model/store';
|
||||||
|
import { snackBar } from '@/shared/lib';
|
||||||
|
|
||||||
export const ArsRequestPage = () => {
|
export const ArsRequestPage = () => {
|
||||||
const { navigate } = useNavigate();
|
const { navigate } = useNavigate();
|
||||||
const location = useLocation();
|
const location = useLocation();
|
||||||
|
|
||||||
|
const midOptions = useStore.getState().UserStore.selectOptionsMids
|
||||||
|
|
||||||
const { mid: receivedMid } = location.state || {};
|
const { mid: receivedMid } = location.state || {};
|
||||||
|
|
||||||
const { mutateAsync: arsApply } = useExtensionArsApplyMutation();
|
const { mutateAsync: arsApply } = useExtensionArsApplyMutation();
|
||||||
@@ -26,7 +30,7 @@ export const ArsRequestPage = () => {
|
|||||||
const [moid, setMoid] = useState<string>('');
|
const [moid, setMoid] = useState<string>('');
|
||||||
const [goodsName, setGoodsName] = useState<string>('');
|
const [goodsName, setGoodsName] = useState<string>('');
|
||||||
const [amount, setAmount] = useState<number>(0);
|
const [amount, setAmount] = useState<number>(0);
|
||||||
const [instmntMonth, setInstmntMonth] = useState<string>('');
|
const [instmntMonth, setInstmntMonth] = useState<string>('00');
|
||||||
const [buyerName, setBuyerName] = useState<string>('');
|
const [buyerName, setBuyerName] = useState<string>('');
|
||||||
const [phoneNumber, setPhoneNumber] = useState<string>('');
|
const [phoneNumber, setPhoneNumber] = useState<string>('');
|
||||||
const [email, setEamil] = useState<string>('');
|
const [email, setEamil] = useState<string>('');
|
||||||
@@ -53,15 +57,18 @@ export const ArsRequestPage = () => {
|
|||||||
email: email,
|
email: email,
|
||||||
arsPaymentMethod: arsPaymentMethod,
|
arsPaymentMethod: arsPaymentMethod,
|
||||||
};
|
};
|
||||||
arsApply(arsApplyParams).then((rs) => {
|
arsApply(arsApplyParams)
|
||||||
console.log(rs)
|
.then((rs: ExtensionArsApplyResponse) => {
|
||||||
setResultMessage('결제 신청이 완료되었습니다');
|
if (rs.status === true) {
|
||||||
setSuccessPageOn(true);
|
setSuccessPageOn(true);
|
||||||
}).catch(() => {
|
} else {
|
||||||
|
const errorMessage = rs.error?.message || '신청을 실패하였습니다.';
|
||||||
}).finally(() => {
|
snackBar(`[실패] ${errorMessage}`);
|
||||||
|
}
|
||||||
});
|
})
|
||||||
|
.catch((error) => {
|
||||||
|
snackBar(`[실패] ${error?.response?.data?.message || error?.response?.data?.error?.message}` || '[실패] 신청을 실패하였습니다.')
|
||||||
|
})
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -116,10 +123,19 @@ export const ArsRequestPage = () => {
|
|||||||
<div className="billing-row">
|
<div className="billing-row">
|
||||||
<div className="billing-label">가맹점 <span>*</span></div>
|
<div className="billing-label">가맹점 <span>*</span></div>
|
||||||
<div className="billing-field">
|
<div className="billing-field">
|
||||||
<input
|
<select
|
||||||
type="text"
|
|
||||||
value={mid}
|
value={mid}
|
||||||
/>
|
onChange={(e: ChangeEvent<HTMLSelectElement>) => setMid(e.target.value)}
|
||||||
|
>
|
||||||
|
{
|
||||||
|
midOptions.map((value) => (
|
||||||
|
<option
|
||||||
|
key={value.value}
|
||||||
|
value={value.value}
|
||||||
|
>{value.name}</option>
|
||||||
|
))
|
||||||
|
}
|
||||||
|
</select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -164,9 +180,12 @@ export const ArsRequestPage = () => {
|
|||||||
<div className="billing-row">
|
<div className="billing-row">
|
||||||
<div className="billing-label">할부기간 <span>*</span></div>
|
<div className="billing-label">할부기간 <span>*</span></div>
|
||||||
<div className="billing-field">
|
<div className="billing-field">
|
||||||
<select disabled>
|
<select
|
||||||
<option selected>일시불</option>
|
disabled
|
||||||
<option>일시불</option>
|
value={instmntMonth}
|
||||||
|
onChange={(e: ChangeEvent<HTMLSelectElement>) => setInstmntMonth(e.target.value)}
|
||||||
|
>
|
||||||
|
<option value="00">일시불</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ export const KeyInPaymentPage = () => {
|
|||||||
const callList = (type?: string) => {
|
const callList = (type?: string) => {
|
||||||
setOnActionIntersect(false);
|
setOnActionIntersect(false);
|
||||||
let listParams = {
|
let listParams = {
|
||||||
mid: mid,
|
mid: 'nictest02m',
|
||||||
startDate: startDate,
|
startDate: startDate,
|
||||||
endDate: endDate,
|
endDate: endDate,
|
||||||
transactionType: transactionType,
|
transactionType: transactionType,
|
||||||
|
|||||||
@@ -64,12 +64,11 @@ export const KeyInPaymentRequestPage = () => {
|
|||||||
|
|
||||||
const callKeyInPaymentRequest = () => {
|
const callKeyInPaymentRequest = () => {
|
||||||
const cardNo = `${cardNo1}${cardNo2}${cardNo3}${cardNo4}`;
|
const cardNo = `${cardNo1}${cardNo2}${cardNo3}${cardNo4}`;
|
||||||
|
const cardExpire = `${expMon}${expYear}`
|
||||||
let keyInApplyParams = {
|
let keyInApplyParams = {
|
||||||
mid: mid,
|
mid: mid,
|
||||||
cardNo: cardNo,
|
cardNo: cardNo,
|
||||||
expYear: expYear,
|
cardExpire: cardExpire,
|
||||||
expMon: expMon,
|
|
||||||
instmnt: instmnt,
|
instmnt: instmnt,
|
||||||
amount: amount,
|
amount: amount,
|
||||||
productName: productName,
|
productName: productName,
|
||||||
|
|||||||
@@ -440,6 +440,7 @@ export const SettingPage = () => {
|
|||||||
loginType={ loginType }
|
loginType={ loginType }
|
||||||
setLoginType={ handleSetLoginType }
|
setLoginType={ handleSetLoginType }
|
||||||
onBiometricRegistered={ loadLoginType }
|
onBiometricRegistered={ loadLoginType }
|
||||||
|
isAndroid={ isAndroid }
|
||||||
></LoginTypeBottomSheet>
|
></LoginTypeBottomSheet>
|
||||||
}
|
}
|
||||||
{ !!serviceLanguageBottomSheetOn &&
|
{ !!serviceLanguageBottomSheetOn &&
|
||||||
|
|||||||
@@ -91,7 +91,7 @@ export const API_URL_ADDITIONAL_SERVICE = {
|
|||||||
},
|
},
|
||||||
extensionSmsDetail: () => {
|
extensionSmsDetail: () => {
|
||||||
// POST: SMS 결제 통보 상세 조회
|
// POST: SMS 결제 통보 상세 조회
|
||||||
return `${API_BASE_URL}/api/v1/${API_URL_KEY}/extension/sms/detail`;
|
return `${API_BASE_URL}/api/v1/${API_URL_KEY}/extension/sms/resend-info`;
|
||||||
},
|
},
|
||||||
extensionList: () => {
|
extensionList: () => {
|
||||||
// POST: 부가서비스 조회
|
// POST: 부가서비스 조회
|
||||||
|
|||||||
Reference in New Issue
Block a user