๐Ÿงช YSP Simulator - Transaction Log

Payment Gateway Testing Environment

<%= length(@transactions) %> Transactions
<%= if Enum.empty?(@transactions) do %>
๐Ÿ“ญ

No transactions yet

Transactions will appear here when payments are processed through the simulator.

<% else %> <%= for txn <- @transactions do %> <% end %>
Time Txn ID Order No Merchant Amount Card Status OTP Auth Code
<%= if txn.timestamp do %> <%= Calendar.strftime(txn.timestamp, "%H:%M:%S") %>
<%= Calendar.strftime(txn.timestamp, "%Y-%m-%d") %> <% else %> - <% end %>
<%= String.slice(txn.transaction_id, 0, 12) %>... <%= txn.order_no %> <%= txn.merchant_id %> <%= txn.currency %> <%= txn.amount %> <%= String.slice(txn.card_number || "XXXX", 0, 4) %>****<%= String.slice(txn.card_number || "XXXX", -4, 4) %> "approved" "FAILED" -> "failed" _ -> "pending" end }"}> <%= txn.status %> <%= if txn.otp do %> <%= txn.otp %> <%= if txn.otp_attempts > 0 do %>
(<%= txn.otp_attempts %> attempts) <% end %> <% else %> - <% end %>
<%= if Map.get(txn, :auth_code) do %> <%= txn.auth_code %> <% else %> - <% end %>
<% end %>