perf: PayPal webhooks: custom_id

webht/payment
Lei OT 1 year ago
parent 04eba4d8c6
commit 5c50297c72

@ -646,6 +646,7 @@ class Index extends CI_Controller {
$pn_txn_id = $post_data->resource->id;
$pn_invoice = '';
$pn_custom = '';
$pn_mc_gross = '';
$pn_mc_currency = '';
$pn_mc_fee = '';
@ -669,6 +670,7 @@ class Index extends CI_Controller {
case 'PAYMENT.CAPTURE.COMPLETED':
$pn_invoice = $post_data->resource->invoice_id;
$pn_custom = $post_data->resource->custom_id;
$pn_mc_gross = $post_data->resource->amount->value;
$pn_mc_currency = $post_data->resource->amount->currency_code;
$pn_payment_status = $post_data->resource->status;
@ -691,6 +693,7 @@ class Index extends CI_Controller {
default: // capture COMPLETED
$pn_invoice = $post_data->resource->invoice_id;
$pn_custom = $post_data->resource->custom_id;
$pn_mc_gross = $post_data->resource->amount->value;
$pn_mc_currency = $post_data->resource->amount->currency_code;
$pn_payment_status = $post_data->resource->status;
@ -712,7 +715,7 @@ class Index extends CI_Controller {
$this->Note_model->save_paypal_note(
$pn_txn_id,
$pn_invoice,
"",
$pn_custom,
$pn_mc_gross,
"",
"",

Loading…
Cancel
Save