Skip to content

Commit

Permalink
changed config display for COD
Browse files Browse the repository at this point in the history
  • Loading branch information
abdulwahidsharief committed Dec 30, 2024
1 parent 2b6490c commit 5c413ca
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 2 additions & 0 deletions includes/api/cart.php
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,8 @@ function cartResponse($couponCode){
$prefillData = getPrefillCartData($couponCode);
$response['prefill'] = $prefillData;

$response['config'] = $razorpay->getDisplayConfig();

$response['enable_ga_analytics'] = get_option('woocommerce_razorpay_settings')['enable_1cc_ga_analytics'] === 'yes' ? true : false;
$response['enable_fb_analytics'] = get_option('woocommerce_razorpay_settings')['enable_1cc_fb_analytics'] === 'yes' ? true : false;

Expand Down
5 changes: 1 addition & 4 deletions woo-razorpay.php
Original file line number Diff line number Diff line change
Expand Up @@ -1547,8 +1547,6 @@ public function getDefaultCheckoutArguments($order)

$productinfo = "Order $orderId";

$config = $this->getDisplayConfig();

return array(
'key' => $this->getSetting('key_id'),
'name' => html_entity_decode(get_bloginfo('name'), ENT_QUOTES),
Expand All @@ -1560,8 +1558,7 @@ public function getDefaultCheckoutArguments($order)
),
'order_id' => $razorpayOrderId,
'callback_url' => $callbackUrl,
'prefill' => $this->getCustomerInfo($order),
'config' => $config
'prefill' => $this->getCustomerInfo($order)
);
}

Expand Down

0 comments on commit 5c413ca

Please sign in to comment.