added openwa failure notifications
This commit is contained in:
@@ -80,7 +80,7 @@ public class GatewayPaymentHandler implements HandlerInterface {
|
||||
transactionService.save(transaction);
|
||||
}
|
||||
|
||||
if(transaction.getPaymentStatus().equals(Status.FAILED)) {
|
||||
if(Status.FAILED.equals(transaction.getPaymentStatus())) {
|
||||
notificationService.sendWA(waPhone, String.format(
|
||||
"Payment failed: Transaction: %s, Customer message: %s, System message: %s",
|
||||
transaction.getId(), transaction.getErrorMessage(), transaction.getSystemErrorMessage()));
|
||||
|
||||
@@ -91,7 +91,7 @@ public class IntegrationHandler implements HandlerInterface {
|
||||
|
||||
transaction.setIntegrationStatus(transaction.getStatus());
|
||||
|
||||
if(!transaction.getIntegrationStatus().equals(Status.SUCCESS)) {
|
||||
if(!Status.SUCCESS.equals(transaction.getIntegrationStatus())) {
|
||||
notificationService.sendWA(waPhone, String.format(
|
||||
"Integration failed: Transaction %s, Customer message: %s, System message: %s",
|
||||
transaction.getId(), transaction.getErrorMessage(), transaction.getSystemErrorMessage()));
|
||||
|
||||
Reference in New Issue
Block a user