Commit 6eecee6c authored by XieZhiXiong's avatar XieZhiXiong

添加是否是采购商判断

parent 6a306d92
......@@ -48,12 +48,17 @@ interface ReturnDetailInfoProps {
* 确认事件
*/
onConfirm?: (id: number, flag: 0 | 1) => Promise<any>;
/**
* 是否是采购商
*/
isPurchaser?: boolean;
};
const ReturnDetailInfo: React.FC<ReturnDetailInfoProps> = ({
dataSource = [],
onRefund,
onConfirm,
isPurchaser = false,
}) => {
const [visibleResult, setVisibleResult] = useState(false);
const [notReceivedLoading, setNotReceivedLoading] = useState(false);
......@@ -251,7 +256,7 @@ const ReturnDetailInfo: React.FC<ReturnDetailInfoProps> = ({
<div className={styles['deliver-item-actions']}>
{
(
!isPurchaser && (
item.outerStatus === REFUND_OUTER_STATUS_NOT_RECEIVED ||
item.innerStatus === REFUND_INNER_STATUS_NO_REFUND ||
item.innerStatus === REFUND_INNER_STATUS_REFUND_FAILED
......@@ -268,7 +273,7 @@ const ReturnDetailInfo: React.FC<ReturnDetailInfoProps> = ({
{item.channel === PAY_CHANNEL_OFFLINE && (
<>
{
(
isPurchaser && (
item.outerStatus === REFUND_OUTER_STATUS_UNCONFIRMED_REFUND ||
item.outerStatus === REFUND_OUTER_STATUS_NOT_RECEIVED
) && (
......
......@@ -405,6 +405,7 @@ const DetailInfo: React.FC<DetailInfoProps> = ({
<ReturnDetailInfo
dataSource={detailInfo && detailInfo.refundList ? detailInfo.refundList : []}
onConfirm={handleConfirm}
isPurchaser
/>
</Suspense>
</Col>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment