mirror of https://github.com/itflow-org/itflow
No need for a sql delete on recurring payments when deleting a saved payment method as SQL cascadely deletes the recurring payment if saved payment method is deleted
This commit is contained in:
parent
93f4ea51fd
commit
307d9892b2
|
|
@ -58,8 +58,7 @@ if (isset($_GET['delete_saved_payment'])) {
|
|||
// Remove payment method from ITFlow
|
||||
mysqli_query($mysqli, "DELETE FROM client_saved_payment_methods WHERE saved_payment_id = $saved_payment_id");
|
||||
|
||||
// Remove All Associted Auto Payment Methods on recurring invoices
|
||||
mysqli_query($mysqli, "DELETE FROM recurring_payments WHERE recurring_payment_saved_payment_id = $saved_payment_id");
|
||||
// SQL Cascade delete will Remove All Associated Auto Payment Methods on recurring invoices in the recurring payments table.
|
||||
|
||||
// Logging & Redirect
|
||||
logAction("Payment Provider", "Update", "$session_name deleted saved payment method $saved_payment_description (PM: $payment_method)", $client_id);
|
||||
|
|
|
|||
Loading…
Reference in New Issue