가맹점 정리

This commit is contained in:
focp212@naver.com
2025-10-01 11:06:34 +09:00
parent c36ecc60d5
commit 851545e81c
9 changed files with 62 additions and 62 deletions

View File

@@ -44,7 +44,7 @@ export enum EscrowStatus {
ACTIVE = 'ACTIVE',
INACTIVE = 'INACTIVE'
};
export enum InfoWrapKeys {
export enum SectionKeys {
Merchant = 'Merchant',
Technical = 'Technical',
Settlement = 'Settlement',

View File

@@ -1,10 +1,10 @@
import { useEffect, useState } from 'react';
import { useMerchantMidMutation } from '../api/use-merchant-mid-mutation';
import { BusinessInfoWrap } from './info-wrap/business-info-wrap';
import { ManagerInfoWrap } from './info-wrap/manager-info-wrap';
import { AccountInfoWrap } from './info-wrap/account-info-wrap';
import { BusinessSection } from './section/business-section';
import { ManagerSection } from './section/manager-section';
import { AccountSection } from './section/account-section';
import {
InfoWrapKeys,
SectionKeys,
MerchantMidParams,
MerchantMidResponse
} from '../model/types';
@@ -16,7 +16,7 @@ export const InfoWrap = () => {
const [data, setData] = useState<MerchantMidResponse>();
const [openChild, setOpenChild] = useState<InfoWrapKeys | null>(null);
const [openChild, setOpenChild] = useState<SectionKeys | null>(null);
const { mutateAsync: merchantMid } = useMerchantMidMutation();
@@ -57,43 +57,43 @@ export const InfoWrap = () => {
</div>
<div className="merchant-info">
<BusinessInfoWrap
<BusinessSection
data={ data }
></BusinessInfoWrap>
></BusinessSection>
<div className="info-divider mb-16"></div>
<ManagerInfoWrap
type={ InfoWrapKeys.Merchant }
<ManagerSection
type={ SectionKeys.Merchant }
title='계약 담당자'
manager={ data?.merchantManager }
managerTelephone={ data?.merchantManagerTelephone }
managetEmail={ data?.merchantManagerEmail }
openChild={ openChild }
setOpenChild={ setOpenChild }
></ManagerInfoWrap>
></ManagerSection>
<div className="info-divider mb-16"></div>
<ManagerInfoWrap
type={ InfoWrapKeys.Technical }
<ManagerSection
type={ SectionKeys.Technical }
title='기술 담당자'
manager={ data?.technicalManager }
managerTelephone={ data?.technicalManagerTelephone }
managetEmail={ data?.technicalManagerEmail }
openChild={ openChild }
setOpenChild={ setOpenChild }
></ManagerInfoWrap>
></ManagerSection>
<div className="info-divider mb-16"></div>
<ManagerInfoWrap
type={ InfoWrapKeys.Settlement }
<ManagerSection
type={ SectionKeys.Settlement }
title='정산 담당자'
manager={ data?.settlementManager }
managerTelephone={ data?.settlementManagerTelephone }
managetEmail={ data?.settlementManagerEmail }
openChild={ openChild }
setOpenChild={ setOpenChild }
></ManagerInfoWrap>
></ManagerSection>
<div className="info-divider mb-16"></div>
<AccountInfoWrap
<AccountSection
data={ data }
></AccountInfoWrap>
></AccountSection>
<div className="notice-bottom left-align">
<p className="notice-tip"> .<br/>PC .</p>
</div>

View File

@@ -3,15 +3,15 @@ import { useMerchantMidStatusMutation } from '../api/use-merchant-mid-status-mut
import {
CardApplications,
Escrow,
InfoWrapKeys,
SectionKeys,
MerchantMidStatusParams,
MerchantMidStatusResponse,
OfflineInfomation,
OnlineInfomation
} from '../model/types';
import { OnlineInfoWrap } from './info-wrap/online-info-wrap';
import { CardInfoWrap } from './info-wrap/card-info-wrap';
import { EscrowInfoWrap } from './info-wrap/escrow-info-wrap';
import { OnlineSection } from './section/online-section';
import { CardSection } from './section/card-section';
import { EscrowSection } from './section/escrow-section';
import { useStore } from '@/shared/model/store';
export const RegistrationStatusWrap = () => {
@@ -23,7 +23,7 @@ export const RegistrationStatusWrap = () => {
const [cardApplications, setCardApplications] = useState<Array<CardApplications>>();
const [escrow, setEscrow] = useState<Escrow>();
const [openChild, setOpenChild] = useState<InfoWrapKeys | null>(null);
const [openChild, setOpenChild] = useState<SectionKeys | null>(null);
const { mutateAsync: merchantMidStatus } = useMerchantMidStatusMutation();
const callInfo = (selectedMid: string) => {
@@ -65,20 +65,20 @@ export const RegistrationStatusWrap = () => {
</select>
</div>
<div className="merchant-info">
<OnlineInfoWrap
<OnlineSection
data={ onlineInfomation }
></OnlineInfoWrap>
></OnlineSection>
<div className="info-divider mb-16"></div>
<CardInfoWrap
type={ InfoWrapKeys.Card }
<CardSection
type={ SectionKeys.Card }
title='신용카드 심사현황'
cardApplications={ cardApplications }
openChild={ openChild }
setOpenChild={ setOpenChild }
></CardInfoWrap>
></CardSection>
<div className="info-divider mb-16"></div>
<EscrowInfoWrap
type={ InfoWrapKeys.Escrow }
<EscrowSection
type={ SectionKeys.Escrow }
title='에스크로 가입현황'
companyName={ escrow?.companyName }
businessRegistrationNumber={ escrow?.businessRegistrationNumber }
@@ -88,7 +88,7 @@ export const RegistrationStatusWrap = () => {
serviceRegistrationNumber={ escrow?.serviceRegistrationNumber }
openChild={ openChild }
setOpenChild={ setOpenChild }
></EscrowInfoWrap>
></EscrowSection>
</div>
</>
);

View File

@@ -1,12 +1,12 @@
import { MerchantMidResponse } from '../../model/types';
export interface AccountInfoWrapProps {
export interface AccountSectionProps {
data?: MerchantMidResponse
};
export const AccountInfoWrap = ({
export const AccountSection = ({
data
}: AccountInfoWrapProps) => {
}: AccountSectionProps) => {
return (
<>

View File

@@ -1,12 +1,12 @@
import { MerchantMidResponse } from '../../model/types';
export interface BusinessInfoWrapProps {
export interface BusinessSectionProps {
data?: MerchantMidResponse
};
export const BusinessInfoWrap = ({
export const BusinessSection = ({
data
}: BusinessInfoWrapProps) => {
}: BusinessSectionProps) => {
return (
<>

View File

@@ -1,24 +1,24 @@
import { SectionTitleArrow } from '@/entities/common/ui/section-title-arrow';
import { CardApplications, Escrow, EscrowStatus, InfoWrapKeys, MerchantMidResponse } from '../../model/types';
import { CardApplications, SectionKeys } from '../../model/types';
import SlideDown from 'react-slidedown';
import 'react-slidedown/lib/slidedown.css';
import { useEffect, useState } from 'react';
export interface CardInfoWrapProps {
type: InfoWrapKeys;
export interface CardSectionProps {
type: SectionKeys;
title?: string;
cardApplications?: Array<CardApplications>
openChild: InfoWrapKeys | null;
setOpenChild: (openChild: InfoWrapKeys | null) => void;
openChild: SectionKeys | null;
setOpenChild: (openChild: SectionKeys | null) => void;
};
export const CardInfoWrap = ({
export const CardSection = ({
type,
title,
cardApplications,
openChild,
setOpenChild
}: CardInfoWrapProps) => {
}: CardSectionProps) => {
const [isOpen, setIsOpen] = useState<boolean>(false);

View File

@@ -1,17 +1,17 @@
import { SectionTitleArrow } from '@/entities/common/ui/section-title-arrow';
import { Escrow, EscrowStatus, InfoWrapKeys, MerchantMidResponse } from '../../model/types';
import { Escrow, SectionKeys } from '../../model/types';
import SlideDown from 'react-slidedown';
import 'react-slidedown/lib/slidedown.css';
import { useEffect, useState } from 'react';
export interface EscrowInfoWrapProps extends Escrow {
type: InfoWrapKeys;
export interface EscrowSectionProps extends Escrow {
type: SectionKeys;
title?: string;
openChild: InfoWrapKeys | null;
setOpenChild: (openChild: InfoWrapKeys | null) => void;
openChild: SectionKeys | null;
setOpenChild: (openChild: SectionKeys | null) => void;
};
export const EscrowInfoWrap = ({
export const EscrowSection = ({
type,
title,
companyName,
@@ -22,7 +22,7 @@ export const EscrowInfoWrap = ({
serviceRegistrationNumber,
openChild,
setOpenChild
}: EscrowInfoWrapProps) => {
}: EscrowSectionProps) => {
const [isOpen, setIsOpen] = useState<boolean>(false);

View File

@@ -1,20 +1,20 @@
import { SectionTitleArrow } from '@/entities/common/ui/section-title-arrow';
import { InfoWrapKeys, MerchantMidResponse } from '../../model/types';
import { SectionKeys } from '../../model/types';
import SlideDown from 'react-slidedown';
import 'react-slidedown/lib/slidedown.css';
import { useEffect, useState } from 'react';
export interface ManagerInfoWrapProps {
type: InfoWrapKeys;
export interface ManagerSectionProps {
type: SectionKeys;
title?: string;
manager?: string;
managerTelephone?: string;
managetEmail?: string;
openChild: InfoWrapKeys | null;
setOpenChild: (openChild: InfoWrapKeys | null) => void;
openChild: SectionKeys | null;
setOpenChild: (openChild: SectionKeys | null) => void;
};
export const ManagerInfoWrap = ({
export const ManagerSection = ({
type,
title,
manager,
@@ -22,7 +22,7 @@ export const ManagerInfoWrap = ({
managetEmail,
openChild,
setOpenChild
}: ManagerInfoWrapProps) => {
}: ManagerSectionProps) => {
const [isOpen, setIsOpen] = useState<boolean>(false);

View File

@@ -1,13 +1,13 @@
import moment from 'moment';
import { OnlineInfomation } from '../../model/types';
export interface OnlineInfoWrapProps {
export interface OnlineSectionProps {
data?: OnlineInfomation
};
export const OnlineInfoWrap = ({
export const OnlineSection = ({
data
}: OnlineInfoWrapProps) => {
}: OnlineSectionProps) => {
return (
<>