Skip to content

Commit c223320

Browse files
committed
fix: drag and drop issue in confirmation detail page
1 parent 1a33bbc commit c223320

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

src/pages/iou/request/step/IOURequestStepConfirmation.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1026,6 +1026,9 @@ function IOURequestStepConfirmation({
10261026
showPreviousTransaction();
10271027
};
10281028

1029+
const shouldEnableDropAndDrop =
1030+
(iouType === CONST.IOU.TYPE.SUBMIT || iouType === CONST.IOU.TYPE.TRACK) && !isPerDiemRequest && (!isMovingTransactionFromTrackExpenseIOUUtils(action) || isPaidGroupPolicy(policy));
1031+
10291032
const shouldShowSmartScanFields =
10301033
!!transaction?.receipt?.isTestDriveReceipt || (isMovingTransactionFromTrackExpense ? transaction?.amount !== 0 : requestType !== CONST.IOU.REQUEST_TYPE.SCAN);
10311034

@@ -1035,7 +1038,10 @@ function IOURequestStepConfirmation({
10351038
testID={IOURequestStepConfirmation.displayName}
10361039
headerGapStyles={isDraggingOver ? [styles.dropWrapper] : []}
10371040
>
1038-
<DragAndDropProvider setIsDraggingOver={setIsDraggingOver}>
1041+
<DragAndDropProvider
1042+
setIsDraggingOver={setIsDraggingOver}
1043+
isDisabled={!shouldEnableDropAndDrop}
1044+
>
10391045
<View style={styles.flex1}>
10401046
<HeaderWithBackButton
10411047
title={headerTitle}

0 commit comments

Comments
 (0)