update code resolved conflict
This commit is contained in:
@@ -33,6 +33,7 @@ import com.billpaymentservice.bbps.dto.response.ComplaintHistoryStatusResponse;
|
||||
import com.billpaymentservice.bbps.dto.response.PlanResponse;
|
||||
import com.billpaymentservice.bbps.dto.response.TicketCheckStatusResponse;
|
||||
import com.billpaymentservice.bbps.dto.response.ViewAllComplaintsTicketsResponse;
|
||||
import com.billpaymentservice.bbps.dto.response.ViewAllComplaintsResponse;
|
||||
import com.billpaymentservice.bbps.dto.response.ViewComplainByIdResponse;
|
||||
import com.billpaymentservice.bbps.entites.AdditionalInfoPlans;
|
||||
import com.billpaymentservice.bbps.entites.AmountOptionByBillerId;
|
||||
@@ -616,10 +617,30 @@ public class BillerMapperHelper {
|
||||
return "SUCCESS";
|
||||
}
|
||||
|
||||
public String saveAllComplaints(ViewAllComplaintsResponse responseWrapper, String reqId, String txnId) {
|
||||
|
||||
ModelMapper mapper = new ModelMapper();
|
||||
mapper.getConfiguration().setMatchingStrategy(MatchingStrategies.STRICT);
|
||||
|
||||
// Map list → ComplaintStatusDetails list
|
||||
List<ComplaintStatusDetails> entityList = responseWrapper.getComplaintsList().stream()
|
||||
.map(c -> mapper.map(c, ComplaintStatusDetails.class)).collect(Collectors.toList());
|
||||
|
||||
// Set extra fields
|
||||
for (ComplaintStatusDetails entity : entityList) {
|
||||
entity.setReqId(reqId);
|
||||
entity.setTxnId(txnId);
|
||||
}
|
||||
|
||||
// Save to repository
|
||||
complainDetailRepository.saveAll(entityList);
|
||||
|
||||
return "SUCCESS";
|
||||
}
|
||||
|
||||
// Payment Data Service Impl
|
||||
public ClientReqIdResponse storeClientReqIdResponse(ClientReqIdResponse responseWrapper, String reqId,
|
||||
String txnId) {
|
||||
|
||||
// 1. Save Parent (bill_id is PK)
|
||||
CheckClientStatusReqId parent = new CheckClientStatusReqId();
|
||||
parent.setBillId(responseWrapper.getBillId());
|
||||
|
||||
Reference in New Issue
Block a user