Skip to content

Commit

Permalink
Merge pull request #2015 from bcgov/bugfix/TCVP-3099-dispute-updates-…
Browse files Browse the repository at this point in the history
…not-clearing

TCVP-2786 and TCVP-3099: Fix dispute updates not clearing and showing on DCF
  • Loading branch information
karahanb authored Dec 6, 2024
2 parents fcb8208 + 4899291 commit ad6e0c8
Show file tree
Hide file tree
Showing 11 changed files with 729 additions and 713 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ public async Task<Dispute> GetDisputeAsync(GetDisputeOptions options, Cancellati

public async Task<Dispute> UpdateDisputeAsync(long disputeId, ClaimsPrincipal user, string? staffComment, Dispute dispute, CancellationToken cancellationToken)
{
Dispute updatedDispute = await _oracleDataApi.UpdateDisputeAsync(disputeId, dispute, cancellationToken);
Dispute updatedDispute = await _oracleDataApi.UpdateDisputeAsync(disputeId, dispute, true, cancellationToken);

// Publish file history
SaveFileHistoryRecord fileHistoryRecord = Mapper.ToFileHistoryWithNoticeOfDisputeId(
Expand All @@ -164,7 +164,7 @@ public async Task ValidateDisputeAsync(long disputeId, Dispute? dispute, ClaimsP
if (dispute != null)
{
_logger.LogDebug("Saving dispute before validating");
_ = await _oracleDataApi.UpdateDisputeAsync(disputeId, dispute, cancellationToken);
_ = await _oracleDataApi.UpdateDisputeAsync(disputeId, dispute, true, cancellationToken);
}

_logger.LogDebug("Dispute status setting to validated");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public DisputeUpdateRequestAcceptedConsumerTest()
_oracleDataApiService.Setup(_ => _.UpdateDisputeUpdateRequestStatusAsync(1, DisputeUpdateRequestStatus.ACCEPTED, It.IsAny<CancellationToken>())).Returns(Task.FromResult(_updateRequest));
_oracleDataApiService.Setup(_ => _.UpdateDisputeUpdateRequestStatusAsync(1, DisputeUpdateRequestStatus.PENDING, It.IsAny<CancellationToken>())).Returns(Task.FromResult(_updateRequest));
_oracleDataApiService.Setup(_ => _.GetDisputeByIdAsync(1, false, It.IsAny<CancellationToken>())).Returns(Task.FromResult(_dispute));
_oracleDataApiService.Setup(_ => _.UpdateDisputeAsync(1, _dispute, It.IsAny<CancellationToken>())).Returns(Task.FromResult(_dispute));
_oracleDataApiService.Setup(_ => _.UpdateDisputeAsync(1, _dispute, false, It.IsAny<CancellationToken>())).Returns(Task.FromResult(_dispute));
_context = new();
_context.Setup(_ => _.Message).Returns(_message);
_context.Setup(_ => _.CancellationToken).Returns(CancellationToken.None);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public interface IOracleDataApiService
Task<long> SaveDisputeUpdateRequestAsync(string guid, DisputeUpdateRequest body, CancellationToken cancellationToken);
Task<Dispute> SubmitDisputeAsync(long id, CancellationToken cancellationToken);
Task UnassignDisputesAsync(CancellationToken cancellationToken);
Task<Dispute> UpdateDisputeAsync(long id, Dispute body, CancellationToken cancellationToken);
Task<Dispute> UpdateDisputeAsync(long id, Dispute body, bool checkUserAssigned, CancellationToken cancellationToken);
Task<DisputeUpdateRequest> UpdateDisputeUpdateRequestStatusAsync(long id, DisputeUpdateRequestStatus disputeUpdateRequestStatus, CancellationToken cancellationToken);
Task<JJDispute> UpdateJJDisputeAsync(string ticketNumber, bool checkVTCAssigned, JJDispute body, CancellationToken cancellationToken);
Task<JJDispute> UpdateJJDisputeCascadeAsync(string ticketNumber, bool checkVTCAssigned, JJDispute body, CancellationToken cancellationToken);
Expand Down
Loading

0 comments on commit ad6e0c8

Please sign in to comment.