@ticketboothapp/booking 1.2.173 → 1.2.174
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -833,12 +833,6 @@ export function AdminChangeBookingFlow({
|
|
|
833
833
|
latestChangeQuote?.allowedRefundDispositionsByOperationId,
|
|
834
834
|
latestChangeQuote?.removedValueByOperationId,
|
|
835
835
|
]);
|
|
836
|
-
useEffect(() => {
|
|
837
|
-
if (!isProviderDashboardChange || responseRefundDecisionOperations.length === 0) return;
|
|
838
|
-
setRefundDispositionsByOperationId((current) =>
|
|
839
|
-
defaultPendingRefundDispositions(responseRefundDecisionOperations, current),
|
|
840
|
-
);
|
|
841
|
-
}, [isProviderDashboardChange, responseRefundDecisionOperations]);
|
|
842
836
|
const activeRefundDecisionContext = useMemo(() => mergeAdminRefundDecisionContext({
|
|
843
837
|
current: refundDecisionContext,
|
|
844
838
|
selectionKey: refundDecisionSelectionKey,
|
|
@@ -857,9 +851,19 @@ export function AdminChangeBookingFlow({
|
|
|
857
851
|
? responseReturnPriceTreatmentOperations
|
|
858
852
|
: [];
|
|
859
853
|
const activeRefundDispositionsByOperationId = useMemo(() => {
|
|
854
|
+
// Provider changes default discovered refund operations to pending at
|
|
855
|
+
// settlement time. Do not write those response-derived defaults into the
|
|
856
|
+
// explicit input state: doing so changes the request key after the first
|
|
857
|
+
// quote and immediately triggers an identical second quote.
|
|
858
|
+
const dispositionsWithPendingRefundDefaults = isProviderDashboardChange
|
|
859
|
+
? defaultPendingRefundDispositions(
|
|
860
|
+
activeRefundDecisionContext?.operations ?? [],
|
|
861
|
+
refundDispositionsByOperationId,
|
|
862
|
+
)
|
|
863
|
+
: refundDispositionsByOperationId;
|
|
860
864
|
const dispositionsWithReturnPriceDefaults = defaultKeepOriginalReturnPriceDispositions(
|
|
861
865
|
activeReturnPriceTreatmentOperations,
|
|
862
|
-
|
|
866
|
+
dispositionsWithPendingRefundDefaults,
|
|
863
867
|
);
|
|
864
868
|
return selectRefundDispositionsForOperations(
|
|
865
869
|
activeRefundDecisionContext,
|
|
@@ -869,6 +873,7 @@ export function AdminChangeBookingFlow({
|
|
|
869
873
|
}, [
|
|
870
874
|
activeRefundDecisionContext?.operations,
|
|
871
875
|
activeReturnPriceTreatmentOperations,
|
|
876
|
+
isProviderDashboardChange,
|
|
872
877
|
refundDispositionsByOperationId,
|
|
873
878
|
]);
|
|
874
879
|
const handleRefundDispositionChange = useCallback((
|
|
@@ -910,7 +915,9 @@ export function AdminChangeBookingFlow({
|
|
|
910
915
|
adminReverseAdjustmentIds,
|
|
911
916
|
needsAdjustmentDiscovery:
|
|
912
917
|
isProviderDashboardChange && !hasHydratedExistingAdjustments,
|
|
913
|
-
|
|
918
|
+
// Only explicit user inputs belong to quote identity. Automatic provider
|
|
919
|
+
// defaults are derived separately for settlement/submission below.
|
|
920
|
+
refundDispositionsByOperationId,
|
|
914
921
|
useAdminFeAuthoritativeQuote,
|
|
915
922
|
latestChangeQuote,
|
|
916
923
|
setLatestChangeQuote,
|