가맹점 정보, 일부 상수 및 공용 변경
This commit is contained in:
@@ -189,11 +189,11 @@ export interface AmountInfoWrapProps {
|
||||
};
|
||||
export interface SettlementInfoWrapProps {
|
||||
settlementInfo?: SettlementInfo;
|
||||
show: boolean;
|
||||
isOpen: boolean;
|
||||
onClickToShowInfo: (infoWrapKey: InfoWrapKeys) => void;
|
||||
};
|
||||
export interface TransactionInfoWrapProps {
|
||||
transactionInfo?: TransactionInfo;
|
||||
show: boolean;
|
||||
isOpen: boolean;
|
||||
onClickToShowInfo: (infoWrapKey: InfoWrapKeys) => void;
|
||||
};
|
||||
@@ -1,26 +0,0 @@
|
||||
import { useEffect, useState } from 'react';
|
||||
import { IMAGE_ROOT } from '@/shared/constants/common';
|
||||
import {
|
||||
AltMsgKeys,
|
||||
DetailArrowProps
|
||||
} from '@/entities/common/model/types';
|
||||
|
||||
export const DetailArrow = ({ show }: DetailArrowProps) => {
|
||||
const [altMsg, setAltMsg] = useState<AltMsgKeys>(AltMsgKeys.Fold);
|
||||
const [className, setClassName] = useState<string>('ic20 rot-180');
|
||||
|
||||
useEffect(() => {
|
||||
setAltMsg((show)? AltMsgKeys.Fold: AltMsgKeys.UnFold);
|
||||
setClassName(`ic20 ${(show)? 'rot-180': ''}`);
|
||||
}, [show]);
|
||||
|
||||
return (
|
||||
<>
|
||||
<img
|
||||
className={ className }
|
||||
src={ IMAGE_ROOT + '/select_arrow.svg' }
|
||||
alt={ altMsg }
|
||||
/>
|
||||
</>
|
||||
);
|
||||
};
|
||||
@@ -70,6 +70,12 @@ export const AmountInfoWrap = ({
|
||||
</li>
|
||||
</ul>
|
||||
}
|
||||
{ (periodType === SettlementPeriodType.TRANSACTION_DATE) &&
|
||||
<ul className="kv-list">
|
||||
|
||||
|
||||
</ul>
|
||||
}
|
||||
</div>
|
||||
</>
|
||||
);
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
import moment from 'moment';
|
||||
import { NumericFormat } from 'react-number-format';
|
||||
import { DetailArrow } from '../detail-arrow';
|
||||
import { SectionTitleArrow } from '@/entities/common/ui/section-title-arrow';
|
||||
import SlideDown from 'react-slidedown';
|
||||
import 'react-slidedown/lib/slidedown.css';
|
||||
import {
|
||||
InfoWrapKeys,
|
||||
SettlementInfoWrapProps,
|
||||
SettlementPeriodType
|
||||
} from '@/entities/settlement/model/types';
|
||||
} from '../../model/types';
|
||||
|
||||
export const SettlementInfoWrap = ({
|
||||
settlementInfo,
|
||||
show,
|
||||
isOpen,
|
||||
onClickToShowInfo
|
||||
}: SettlementInfoWrapProps) => {
|
||||
|
||||
@@ -28,10 +28,10 @@ export const SettlementInfoWrap = ({
|
||||
className="section-title"
|
||||
onClick={ () => onClickToSetShowInfo() }
|
||||
>
|
||||
정산 정보 <DetailArrow show={ show }></DetailArrow>
|
||||
정산 정보 <SectionTitleArrow isOpen={ isOpen }></SectionTitleArrow>
|
||||
</div>
|
||||
<SlideDown className={'my-dropdown-slidedown'}>
|
||||
{ show &&
|
||||
{ isOpen &&
|
||||
<ul className="kv-list">
|
||||
<li className="kv-row">
|
||||
<span className="k">MID</span>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import moment from 'moment';
|
||||
import { DetailArrow } from '../detail-arrow';
|
||||
import { SectionTitleArrow } from '@/entities/common/ui/section-title-arrow';
|
||||
import SlideDown from 'react-slidedown';
|
||||
import 'react-slidedown/lib/slidedown.css';
|
||||
import {
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
|
||||
export const TransactionInfoWrap = ({
|
||||
transactionInfo,
|
||||
show,
|
||||
isOpen,
|
||||
onClickToShowInfo
|
||||
}: TransactionInfoWrapProps) => {
|
||||
|
||||
@@ -26,10 +26,10 @@ export const TransactionInfoWrap = ({
|
||||
className="section-title"
|
||||
onClick={ () => onClickToSetShowInfo() }
|
||||
>
|
||||
거래 상세 정보 <DetailArrow show={ show }></DetailArrow>
|
||||
거래 상세 정보 <SectionTitleArrow isOpen={ isOpen }></SectionTitleArrow>
|
||||
</div>
|
||||
<SlideDown className={'my-dropdown-slidedown'}>
|
||||
{ show &&
|
||||
{ isOpen &&
|
||||
<ul className="kv-list">
|
||||
<li className="kv-row">
|
||||
<span className="k">주문번호</span>
|
||||
|
||||
Reference in New Issue
Block a user