diff --git a/src/entities/additional-service/ui/list-date-group.tsx b/src/entities/additional-service/ui/list-date-group.tsx
index 4774afc..de08c67 100644
--- a/src/entities/additional-service/ui/list-date-group.tsx
+++ b/src/entities/additional-service/ui/list-date-group.tsx
@@ -71,6 +71,8 @@ export const ListDateGroup = ({
smsCl= { items[i]?.smsCl }
onResendClick={ onResendClick }
+
+ seq= { items[i]?.seq}
>
)
}
diff --git a/src/entities/additional-service/ui/list-item.tsx b/src/entities/additional-service/ui/list-item.tsx
index 056a95a..0097b8b 100644
--- a/src/entities/additional-service/ui/list-item.tsx
+++ b/src/entities/additional-service/ui/list-item.tsx
@@ -28,6 +28,7 @@ export const ListItem = ({
paymentMethod, receiverName,
requestId,subReqId,
buyerName,receiverInfo,
+ seq,
smsCl,
name,
@@ -190,8 +191,7 @@ export const ListItem = ({
navigate(PATHS.additionalService.fundAccount.transferDetail, {
state: {
additionalServiceCategory: additionalServiceCategory,
- mid: mid,
- tid: tid
+ seq: seq
}
});
}
diff --git a/src/entities/additional-service/ui/sms-payment/sms-payment-list.tsx b/src/entities/additional-service/ui/sms-payment/sms-payment-list.tsx
index cc8434d..628e551 100644
--- a/src/entities/additional-service/ui/sms-payment/sms-payment-list.tsx
+++ b/src/entities/additional-service/ui/sms-payment/sms-payment-list.tsx
@@ -6,58 +6,59 @@ export const SmsPaymentList = ({
listItems,
additionalServiceCategory,
mid,
- onResendClick,
- setTarget
+ onResendClick
}: SmsPaymentListProps) => {
- const getListDateGroup = () => {
- let rs = [];
- let date = '';
- let list: SmsPaymentListItem[] = [];
- for (let i = 0; i < listItems.length; i++) {
- let paymentDate = listItems[i]?.paymentDate || '';
- let itemDate = paymentDate.substring(0, 8);
- if (i === 0) {
- date = itemDate;
- }
- if (date !== itemDate) {
- date = itemDate;
- if (list.length > 0) {
- rs.push(
-
- );
- }
- list = [];
- }
- list.push(listItems[i] as any);
- }
- if (list.length > 0) {
- rs.push(
+ const getListDateGroup = () => {
+ let rs = [];
+ let date = '';
+ let list = [];
+ for (let i = 0; i < listItems.length; i++) {
+ let items = listItems[i];
+ if(!!items) {
+ let paymentDate = items?.paymentDate;
+ paymentDate = paymentDate?.substring(0, 8);
+ if(!!paymentDate) {
+ if(i === 0) {
+ date = paymentDate;
+ }
+ if(date !== paymentDate) {
+ date = paymentDate;
+ if(list.length > 0) {
+ rs.push(
- );
+ );
+ }
+ list = [];
+ }
+ list.push(items);
}
- return rs;
- };
+ }
+ }
+ if (list.length > 0) {
+ rs.push(
+
+ );
+ }
+ return rs;
+ };
return (
<>
>
)
diff --git a/src/entities/common/ui/email-bottom-sheet.tsx b/src/entities/common/ui/email-bottom-sheet.tsx
index 40fc175..3fe263c 100644
--- a/src/entities/common/ui/email-bottom-sheet.tsx
+++ b/src/entities/common/ui/email-bottom-sheet.tsx
@@ -18,12 +18,12 @@ export const EmailBottomSheet = ({
sendEmail,
sendRequest
}: EmailBottomSheetProps) => {
- const [userEmail, setUserEmail] = useState
('');
const emailList = [
{name: 'test1@nicepay.co.kr', value: 'test1@nicepay.co.kr'},
{name: 'test2@nicepay.co.kr', value: 'test2@nicepay.co.kr'},
{name: 'test3@nicepay.co.kr', value: 'test3@nicepay.co.kr'},
];
+ const [userEmail, setUserEmail] = useState(emailList[0]?.value || '');
const onClickToClose = () => {
setBottomSheetOn(false);
};
diff --git a/src/pages/account/password/modify-cancel-password-page.tsx b/src/pages/account/password/modify-cancel-password-page.tsx
index 19f884d..41a60dd 100644
--- a/src/pages/account/password/modify-cancel-password-page.tsx
+++ b/src/pages/account/password/modify-cancel-password-page.tsx
@@ -1,4 +1,4 @@
-import { useState, useRef, useEffect, ChangeEvent } from 'react';
+import { useState } from 'react';
import { PATHS } from '@/shared/constants/paths';
import { useNavigate } from '@/shared/lib/hooks/use-navigate';
import { HeaderType } from '@/entities/common/model/types';
@@ -10,7 +10,7 @@ import {
} from '@/widgets/sub-layout/use-sub-layout';
import { useUserChangeCancelPasswordMutation } from '@/entities/user/api/use-user-change-cancel-password-mutation';
import { useStore } from '@/shared/model/store';
-import { XKeypad, XKeypadManager, createPasswordKeypad } from '@/utils/xkeypad';
+import { snackBar } from '@/shared/lib/toast';
export const PasswordModifyCancelPasswordPage = () => {
const { navigate } = useNavigate();
@@ -20,69 +20,20 @@ export const PasswordModifyCancelPasswordPage = () => {
const [mid, setMid] = useState(userMid);
const [password, setPassword] = useState('');
const [confirmPassword, setConfirmPassword] = useState('');
- const [isKeypadLoaded, setIsKeypadLoaded] = useState(false);
-
- // Input refs for xkeypad
- const passwordInputRef = useRef(null);
- const confirmPasswordInputRef = useRef(null);
-
- // XKeypad instances
- const passwordKeypadRef = useRef(null);
- const confirmPasswordKeypadRef = useRef(null);
-
- // RSA Keys (실제 프로덕션에서는 서버에서 받아와야 함)
- const RSA_MODULUS = "C4F7B39E2E93DB19C016C7A0C1C05B028A1D57CB9B91E13F5B7353F8FB5AC6CE6BE31ABEB8E8F7AD18B90C08F4EBC011A6A8FCE614EA879ED5B96296B969CE92923BC9BAD6FD87F00E08F529F93010EA77E40937BDAC1C866E79ACE2F2822A3ECD982F90532D5301CF90D9BF89E953A0593AB6C5F31E99B690DD582FB85F85A9";
- const RSA_EXPONENT = "10001";
const changeCancelPasswordMutation = useUserChangeCancelPasswordMutation({
onSuccess: () => {
- // snackBar('비밀번호가 성공적으로 변경되었습니다.');
- // Clear form and keypads
+ snackBar('비밀번호가 성공적으로 변경되었습니다.');
+ // Clear form
setPassword('');
setConfirmPassword('');
- if (passwordKeypadRef.current) passwordKeypadRef.current.clear();
- if (confirmPasswordKeypadRef.current) confirmPasswordKeypadRef.current.clear();
- if (passwordInputRef.current) passwordInputRef.current.value = '';
- if (confirmPasswordInputRef.current) confirmPasswordInputRef.current.value = '';
// Navigate back
navigate(PATHS.account.password.manage);
},
onError: (error) => {
- // snackBar(error?.response?.data?.message || '비밀번호 변경에 실패했습니다.');
+ snackBar(error?.response?.data?.message || '비밀번호 변경에 실패했습니다.');
}
});
- // Initialize XKeypad
- useEffect(() => {
- const initializeKeypad = async () => {
- try {
- const manager = XKeypadManager.getInstance({
- modulus: RSA_MODULUS,
- exponent: RSA_EXPONENT
- });
-
- await manager.loadScripts();
-
- // RSA 키 설정을 명시적으로 다시 한번 수행
- manager.setRSAPublicKey(RSA_MODULUS, RSA_EXPONENT);
-
- setIsKeypadLoaded(true);
- } catch (error) {
- console.error('Failed to load XKeypad:', error);
- }
- };
-
- initializeKeypad();
-
- return () => {
- // Cleanup keypads on unmount
- if (passwordKeypadRef.current) {
- passwordKeypadRef.current.destroy();
- }
- if (confirmPasswordKeypadRef.current) {
- confirmPasswordKeypadRef.current.destroy();
- }
- };
- }, []);
useSetHeaderTitle('거래취소 비밀번호 변경');
useSetHeaderType(HeaderType.LeftArrow);
@@ -100,97 +51,10 @@ export const PasswordModifyCancelPasswordPage = () => {
);
};
- // Handle password keypad
- const handlePasswordKeypad = async () => {
- if (!passwordInputRef.current || !isKeypadLoaded) return;
-
- // Close other keypad if open
- if (confirmPasswordKeypadRef.current) {
- confirmPasswordKeypadRef.current.close();
- }
-
- // Create or initialize password keypad
- if (!passwordKeypadRef.current) {
- passwordKeypadRef.current = createPasswordKeypad(passwordInputRef.current, {
- keyType: 'qwertysmart',
- viewType: 'half',
- maxInputSize: 16,
- useOverlay: true,
- useModal: false,
- hasPressEffect: true,
- isE2E: false, // E2E 모드 비활성화
- onInputChange: (length: number) => {
- // Update password state as typing
- if (passwordKeypadRef.current) {
- const plainText = passwordKeypadRef.current.getPlainText();
- console.log('passwordKeypadRef:', plainText, passwordInputRef.current?.value);
- setPassword(plainText);
- }
- },
- onKeypadClose: () => {
- // Final update when keypad closes
- if (passwordKeypadRef.current) {
- const plainText = passwordKeypadRef.current.getPlainText();
- setPassword(plainText);
- }
- }
- });
- }
-
- const result = await passwordKeypadRef.current.initialize(passwordInputRef.current);
- if (result !== 0) {
- console.error('Failed to initialize password keypad');
- }
- };
-
- // Handle confirm password keypad
- const handleConfirmPasswordKeypad = async () => {
- if (!confirmPasswordInputRef.current || !isKeypadLoaded) return;
-
- // Close other keypad if open
- if (passwordKeypadRef.current) {
- passwordKeypadRef.current.close();
- }
-
- // Create or initialize confirm password keypad
- if (!confirmPasswordKeypadRef.current) {
- confirmPasswordKeypadRef.current = createPasswordKeypad(confirmPasswordInputRef.current, {
- keyType: 'qwertysmart',
- viewType: 'half',
- maxInputSize: 16,
- useOverlay: true,
- useModal: false,
- hasPressEffect: true,
- isE2E: false, // E2E 모드 비활성화
- onInputChange: (length: number) => {
- // Update confirm password state as typing
- if (confirmPasswordKeypadRef.current) {
- const plainText = confirmPasswordKeypadRef.current.getPlainText();
- console.log('confirmPasswordKeypadRef:', plainText, confirmPasswordInputRef.current?.value);
- setConfirmPassword(plainText);
- }
- },
- onKeypadClose: () => {
- // Final update when keypad closes
- if (confirmPasswordKeypadRef.current) {
- const plainText = confirmPasswordKeypadRef.current.getPlainText();
- setConfirmPassword(plainText);
- }
- }
- });
- }
-
- const result = await confirmPasswordKeypadRef.current.initialize(confirmPasswordInputRef.current);
- if (result !== 0) {
- console.error('Failed to initialize confirm password keypad');
- }
- };
-
// 저장 버튼 클릭 핸들러
const handleSave = () => {
if (!isFormValid()) return;
- // 평문 비밀번호 사용 (E2E 모드가 꺼져있으므로)
changeCancelPasswordMutation.mutate({
mid,
password: password
@@ -206,17 +70,17 @@ export const PasswordModifyCancelPasswordPage = () => {
가맹점 *
-
diff --git a/src/pages/additional-service/payout/list-page.tsx b/src/pages/additional-service/payout/list-page.tsx
index b4fe353..5f6f5a2 100644
--- a/src/pages/additional-service/payout/list-page.tsx
+++ b/src/pages/additional-service/payout/list-page.tsx
@@ -28,36 +28,14 @@ import { PayoutDisbursementStatusBtnGroup } from '@/entities/additional-service/
import { ListDateGroup } from '@/entities/additional-service/ui/list-date-group';
import { AdditionalServiceCategory } from '@/entities/additional-service/model/types';
import { useStore } from '@/shared/model/store';
-import useIntersectionObserver from '@/widgets/intersection-observer';
export const PayoutListPage = () => {
const { navigate } = useNavigate();
const userMid = useStore.getState().UserStore.mid;
- const [onActionIntersect, setOnActionIntersect] = useState
(false);
- const onIntersect: IntersectionObserverCallback = (entries: Array) => {
- entries.forEach((entry: IntersectionObserverEntry) => {
- if (entry.isIntersecting) {
- console.log('Element is now intersecting with the root. [' + onActionIntersect + ']');
- if (onActionIntersect) {
- callExtensionPayoutList();
- }
- }
- else {
- console.log('Element is no longer intersecting with the root.');
- }
- });
- };
-
- const { setTarget } = useIntersectionObserver({
- threshold: 1,
- onIntersect
- });
-
const [sortType, setSortType] = useState(SortTypeKeys.LATEST);
const [listItems, setListItems] = useState>([]);
const [filterOn, setFilterOn] = useState(false);
- const [nextCursor, setNextCursor] = useState(null);
const [pageParam, setPageParam] = useState(DEFAULT_PAGE_PARAM);
const [mid, setMid] = useState(userMid);
const [searchDateType, setSearchDateType] = useState(PayoutSearchDateType.REQUEST_DATE);
@@ -83,17 +61,8 @@ export const PayoutListPage = () => {
const callExtensionPayoutList = (option?: {
sortType?: SortTypeKeys,
- status?: PayoutDisbursementStatus,
- resetPage?: boolean
+ status?: PayoutDisbursementStatus
}) => {
- setOnActionIntersect(false);
-
- const currentPageParam = option?.resetPage
- ? { ...DEFAULT_PAGE_PARAM, sortType: option?.sortType ?? sortType }
- : { ...pageParam, sortType: option?.sortType ?? sortType };
-
- setPageParam(currentPageParam);
-
let newMinAmount = minAmount;
if(!!minAmount && typeof(minAmount) === 'string'){
newMinAmount = parseInt(minAmount);
@@ -110,25 +79,16 @@ export const PayoutListPage = () => {
status: option?.status ?? status,
minAmount: newMinAmount,
maxAmount: newMaxAmount,
- page: currentPageParam
+ page: pageParam
};
+
+ if(params.page){
+ params.page.sortType = option?.sortType || sortType;
+ setPageParam(params.page);
+ }
+
extensionPayoutList(params).then((rs: ExtensionPayoutListResponse) => {
- // resetPage면 기존 리스트 무시, 아니면 추가
- setListItems(option?.resetPage ? rs.content : [
- ...listItems,
- ...rs.content
- ]);
- if (rs.hasNext) {
- setNextCursor(rs.nextCursor);
- setPageParam({
- ...currentPageParam,
- cursor: rs.nextCursor
- });
- setOnActionIntersect(true)
- }
- else {
- setNextCursor(null);
- }
+ setListItems(rs.content);
});
};
@@ -156,21 +116,18 @@ export const PayoutListPage = () => {
const onClickToSort = (sort: SortTypeKeys) => {
setSortType(sort);
callExtensionPayoutList({
- sortType: sort,
- resetPage: true
+ sortType: sort
});
};
const onClickToDisbursementStatus = (val: PayoutDisbursementStatus) => {
setStatus(val);
callExtensionPayoutList({
- status: val,
- resetPage: true
+ status: val
});
};
useEffect(() => {
- // 필터 조건이 변경되면 첫 페이지부터 다시 시작
- callExtensionPayoutList({ resetPage: true });
+ callExtensionPayoutList();
}, [
mid,
searchDateType,
@@ -298,7 +255,6 @@ export const PayoutListPage = () => {
{
const { navigate } = useNavigate();
const userMid = useStore.getState().UserStore.mid;
- const [onActionIntersect, setOnActionIntersect] = useState(false);
- const onIntersect: IntersectionObserverCallback = (entries: Array) => {
- entries.forEach((entry: IntersectionObserverEntry) => {
- if (entry.isIntersecting) {
- console.log('Element is now intersecting with the root. [' + onActionIntersect + ']');
- if (onActionIntersect) {
- callList();
- }
- }
- else {
- console.log('Element is no longer intersecting with the root.');
- }
- });
- };
-
- const { setTarget } = useIntersectionObserver({
- threshold: 1,
- onIntersect
- });
-
const [bottomSmsPaymentDetailResendOn, setBottomSmsPaymentDetailResendOn] = useState(false)
const [sortType, setSortType] = useState(SortTypeKeys.LATEST);
const [listItems, setListItems] = useState>([]);
- const [nextCursor, setNextCursor] = useState(null);
const [pageParam, setPageParam] = useState(DEFAULT_PAGE_PARAM);
const [filterOn, setFilterOn] = useState(false);
const [mid, setMid] = useState(userMid);
@@ -75,15 +53,8 @@ export const SmsPaymentPage = () => {
navigate(PATHS.home);
});
const callList = (option?: {
- sortType?: SortTypeKeys,
- resetPage?: boolean
+ sortType?: SortTypeKeys
}) => {
- const currentPageParam = option?.resetPage
- ? { ...DEFAULT_PAGE_PARAM, sortType: option?.sortType ?? sortType }
- : { ...pageParam, sortType: option?.sortType ?? sortType };
-
- setPageParam(currentPageParam);
-
let listParams: ExtensionSmsPaymentListParams = {
mid: mid,
searchCl: searchCl,
@@ -91,26 +62,16 @@ export const SmsPaymentPage = () => {
fromDate: fromDate,
toDate: toDate,
smsCl: smsCl,
- ... {
- page: currentPageParam
- }
+ page: pageParam
+ }
+
+ if (listParams.page) {
+ listParams.page.sortType = option?.sortType || sortType;
+ setPageParam(listParams.page);
}
smsPaymentList(listParams).then((rs) => {
- setListItems(option?.resetPage ? rs.content : [
- ...listItems,
- ...rs.content
- ]);
- if (rs.hasNext) {
- setNextCursor(rs.nextCursor);
- setPageParam({
- ...currentPageParam,
- cursor: rs.nextCursor
- });
- setOnActionIntersect(true)
- } else {
- setNextCursor(null);
- }
+ setListItems(rs.content);
});
}
@@ -150,7 +111,7 @@ export const SmsPaymentPage = () => {
};
useEffect(() => {
- callList({resetPage: true});
+ callList();
}, [
mid,
searchCl,
@@ -203,7 +164,6 @@ export const SmsPaymentPage = () => {
additionalServiceCategory={AdditionalServiceCategory.SMSPayment}
mid={mid}
onResendClick={onClickToShowDetail}
- setTarget={setTarget}
>
diff --git a/src/shared/api/api-url-additional-service.ts b/src/shared/api/api-url-additional-service.ts
index 3f61148..a59876f 100644
--- a/src/shared/api/api-url-additional-service.ts
+++ b/src/shared/api/api-url-additional-service.ts
@@ -173,6 +173,10 @@ export const API_URL_ADDITIONAL_SERVICE = {
},
// Fund Account Management 부가서비스 > 자금이체 API
+ extensionFundAccountTransferRegist: () => {
+ // POST: 자금이체 > 이체등록
+ return `${API_BASE_URL}/api/v1/${API_URL_KEY}/extension/fund-account/transfer/regist`
+ },
extensionFundAccountTransferRequest: () => {
// POST: 자금이체 > 이체신청
return `${API_BASE_URL}/api/v1/${API_URL_KEY}/extension/fund-account/transfer/request`;
diff --git a/src/shared/ui/assets/css/style-fix.css b/src/shared/ui/assets/css/style-fix.css
index 4899f27..d5ec029 100644
--- a/src/shared/ui/assets/css/style-fix.css
+++ b/src/shared/ui/assets/css/style-fix.css
@@ -176,16 +176,22 @@ main.home-main{
}
.approval-cards-wrapper {
+ display: flex;
+ flex-direction: column;
gap: 16px;
+ padding: 16px;
padding-bottom: 2px;
}
.separate-approval-main .apply-row.two-button {
+ display: flex;
+ gap: 8px;
flex-shrink: 0;
position: sticky;
bottom: 0;
background: white;
z-index: 10;
+ padding: 16px;
}
/* 분할승인 안내 박스 */
@@ -215,13 +221,15 @@ main.home-main{
border: 2px solid var(--color-d6d6d6);
border-radius: 16px;
padding: 16px;
- margin-bottom: 16px;
- transition: all 0.4s ease;
+ margin-bottom: 0;
+ transition: all 0.3s ease;
+ box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}
.approval-card.selected {
border-color: var(--color-3E6AFC);
background: var(--color-F4F8FF);
+ box-shadow: 0 4px 12px rgba(62, 106, 252, 0.2);
}
.approval-card .card-checkbox {
@@ -270,6 +278,8 @@ main.home-main{
/* 분할승인 카드 헤더 */
.approval-card .card-header {
+ display: flex;
+ align-items: center;
gap: 8px;
margin-bottom: 16px;
padding-bottom: 12px;
@@ -309,6 +319,8 @@ main.home-main{
}
.approval-card .info-list {
+ display: flex;
+ flex-direction: column;
list-style: none;
padding: 0;
margin: 0;
@@ -316,6 +328,7 @@ main.home-main{
}
.approval-card .info-list li {
+ display: flex;
align-items: center;
font-size: var(--fs-14);
color: var(--color-2D3436);
@@ -351,6 +364,7 @@ main.home-main{
}
.approval-card .period-selector select {
+ flex: 1;
height: 36px;
font-size: var(--fs-14);
padding: 6px 30px 6px 12px;
@@ -358,6 +372,7 @@ main.home-main{
border-radius: 4px;
background-color: var(--color-white);
transition: all 0.2s ease;
+ cursor: pointer;
}
/* Scrollbar hide utility class */
diff --git a/src/widgets/sub-layout/index.tsx b/src/widgets/sub-layout/index.tsx
index 6882908..8c0a810 100644
--- a/src/widgets/sub-layout/index.tsx
+++ b/src/widgets/sub-layout/index.tsx
@@ -166,6 +166,12 @@ export const SubLayout = () => {
id: 'nictest00',
password: 'nictest00'
};
+
+ // userParmas = {
+ // id: 'medi9332',
+ // password: 'medi9332'
+ // };
+
}
callLogin(userParmas).then(() => {
callHomeGroups();