mirror of
https://github.com/itflow-org/itflow
synced 2026-03-25 06:45:40 +00:00
Stripe - tidy
This commit is contained in:
@@ -25,7 +25,8 @@ if (isset($_GET['stripe_create_pi'])) {
|
|||||||
$url_key = mysqli_real_escape_string($mysqli, $jsonObj['url_key']);
|
$url_key = mysqli_real_escape_string($mysqli, $jsonObj['url_key']);
|
||||||
|
|
||||||
// Query invoice details
|
// Query invoice details
|
||||||
$invoice_sql = mysqli_query($mysqli, "SELECT * FROM invoices
|
$invoice_sql = mysqli_query($mysqli,
|
||||||
|
"SELECT * FROM invoices
|
||||||
LEFT JOIN clients ON invoice_client_id = client_id
|
LEFT JOIN clients ON invoice_client_id = client_id
|
||||||
WHERE invoice_id = $invoice_id
|
WHERE invoice_id = $invoice_id
|
||||||
AND invoice_url_key = '$url_key'
|
AND invoice_url_key = '$url_key'
|
||||||
|
|||||||
@@ -279,12 +279,12 @@ if (isset($_GET['invoice_id'], $_GET['url_key']) && !isset($_GET['payment_intent
|
|||||||
|
|
||||||
// Email Logging
|
// Email Logging
|
||||||
if ($mail === true) {
|
if ($mail === true) {
|
||||||
mysqli_query($mysqli,"INSERT INTO history SET history_status = 'Sent', history_description = 'Emailed Receipt!', history_invoice_id = $invoice_id, company_id = $invoice_company_id");
|
mysqli_query($mysqli, "INSERT INTO history SET history_status = 'Sent', history_description = 'Emailed Receipt!', history_invoice_id = $invoice_id, company_id = $invoice_company_id");
|
||||||
} else {
|
} else {
|
||||||
mysqli_query($mysqli,"INSERT INTO history SET history_status = 'Sent', history_description = 'Email Receipt Failed!', history_invoice_id = $invoice_id, company_id = $invoice_company_id");
|
mysqli_query($mysqli, "INSERT INTO history SET history_status = 'Sent', history_description = 'Email Receipt Failed!', history_invoice_id = $invoice_id, company_id = $invoice_company_id");
|
||||||
|
|
||||||
mysqli_query($mysqli,"INSERT INTO notifications SET notification_type = 'Mail', notification = 'Failed to send email to $contact_email', notification_timestamp = NOW(), company_id = $invoice_company_id");
|
mysqli_query($mysqli, "INSERT INTO notifications SET notification_type = 'Mail', notification = 'Failed to send email to $contact_email', notification_timestamp = NOW(), company_id = $invoice_company_id");
|
||||||
mysqli_query($mysqli,"INSERT INTO logs SET log_type = 'Mail', log_action = 'Error', log_description = 'Failed to send email to $contact_email regarding $subject. $mail', log_ip = '$ip', log_user_agent = '$user_agent', company_id = $invoice_company_id");
|
mysqli_query($mysqli, "INSERT INTO logs SET log_type = 'Mail', log_action = 'Error', log_description = 'Failed to send email to $contact_email regarding $subject. $mail', log_ip = '$ip', log_user_agent = '$user_agent', company_id = $invoice_company_id");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user