Changeset 3164634
- Timestamp:
- 10/08/2024 05:25:49 AM (18 months ago)
- Location:
- connect-plus-for-woocommerce
- Files:
-
- 38 added
- 4 edited
-
tags/1.0.7 (added)
-
tags/1.0.7/README.txt (added)
-
tags/1.0.7/admin (added)
-
tags/1.0.7/admin/cpfw-connect-admin.php (added)
-
tags/1.0.7/admin/css (added)
-
tags/1.0.7/admin/css/cpfw-connect-admin.css (added)
-
tags/1.0.7/admin/index.php (added)
-
tags/1.0.7/admin/js (added)
-
tags/1.0.7/admin/js/cpfw-connect-admin.js (added)
-
tags/1.0.7/admin/partials (added)
-
tags/1.0.7/admin/partials/cpfw-connect-admin-send-btn.php (added)
-
tags/1.0.7/admin/views (added)
-
tags/1.0.7/admin/views/cpfw-connect-admin-settings.php (added)
-
tags/1.0.7/connect-plus-for-woocommerce.php (added)
-
tags/1.0.7/endpoints (added)
-
tags/1.0.7/endpoints/cpfw-connect-ajax-wrapper.php (added)
-
tags/1.0.7/endpoints/cpfw-connect-endpoints.php (added)
-
tags/1.0.7/endpoints/index.php (added)
-
tags/1.0.7/includes (added)
-
tags/1.0.7/includes/cpfw-connect-loader.php (added)
-
tags/1.0.7/includes/cpfw-connect-toggler.php (added)
-
tags/1.0.7/includes/cpfw-connect.php (added)
-
tags/1.0.7/includes/index.php (added)
-
tags/1.0.7/includes/services (added)
-
tags/1.0.7/includes/services/cpfw-connect-api.php (added)
-
tags/1.0.7/index.php (added)
-
tags/1.0.7/languages (added)
-
tags/1.0.7/languages/connect-plus-for-woocommerce.pot (added)
-
tags/1.0.7/public (added)
-
tags/1.0.7/public/cpfw-connect-public.php (added)
-
tags/1.0.7/public/css (added)
-
tags/1.0.7/public/css/cpfw-public.css (added)
-
tags/1.0.7/public/index.php (added)
-
tags/1.0.7/public/js (added)
-
tags/1.0.7/public/js/cpfw-public.js (added)
-
tags/1.0.7/public/partials (added)
-
tags/1.0.7/public/partials/cpfw-public-display.php (added)
-
tags/1.0.7/uninstall.php (added)
-
trunk/README.txt (modified) (1 diff)
-
trunk/connect-plus-for-woocommerce.php (modified) (1 diff)
-
trunk/endpoints/cpfw-connect-ajax-wrapper.php (modified) (1 diff)
-
trunk/includes/services/cpfw-connect-api.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
connect-plus-for-woocommerce/trunk/README.txt
r3163357 r3164634 9 9 Tested up to: 6.6 10 10 11 Stable tag: 1.0. 611 Stable tag: 1.0.7 12 12 13 13 Requires PHP: 7.0 -
connect-plus-for-woocommerce/trunk/connect-plus-for-woocommerce.php
r3163352 r3164634 17 17 * Plugin URI: https://website.olivery.app/ 18 18 * Description: Plugin to help you connect WooCommerce with Connect Plus application 19 * Version: 1.0. 619 * Version: 1.0.7 20 20 * Author: Olivery dev 21 21 * Text Domain: connect-plus-for-woocommerce -
connect-plus-for-woocommerce/trunk/endpoints/cpfw-connect-ajax-wrapper.php
r3163352 r3164634 70 70 }catch(Exception $e){ 71 71 wp_send_json_error([ 72 'message' => esc_html($e->getMessage() , 'connect-plus-for-woocommerce'),73 'error' => esc_html($e->getMessage() , 'connect-plus-for-woocommerce'),72 'message' => esc_html($e->getMessage()), 73 'error' => esc_html($e->getMessage()), 74 74 ]); 75 75 wp_die(); -
connect-plus-for-woocommerce/trunk/includes/services/cpfw-connect-api.php
r3163352 r3164634 127 127 ]; 128 128 } 129 130 131 $cpfw_order_notes = wc_get_order_notes( array( 'order_id' => $cpfw_the_order->get_id() ) ); 132 133 $content_array = array(); 134 135 foreach ($cpfw_order_notes as $note) { 136 $content_array[] = $note->content; // Access content directly from stdClass 137 } 138 129 139 // Add the URL for add orders 130 140 $cpfw_url = "https://api.connect-plus.app/integration/add_orders"; 131 141 132 $cpfw_body = '{ "orders_list": [{142 $cpfw_body ='{ "orders_list": [{ 133 143 "address": "' . ($cpfw_customer_address ?: ' ') . '", 134 144 "customer_mobile": "' . trim($cpfw_customer_phone) . '", 135 "customer_name": "' . sanitize_text_field($cpfw_ customer_name) . '",145 "customer_name": "' . sanitize_text_field($cpfw_the_order->get_formatted_billing_full_name()) . '", 136 146 "area": "' . $cpfw_customer_area . '", 137 "sub_area": "' . sanitize_text_field($cpfw_ customer_address). '",147 "sub_area": "' . sanitize_text_field($cpfw_the_order->get_billing_address_1()). '", 138 148 "country": "' .sanitize_text_field($cpfw_the_order->get_billing_country()) . '", 139 149 "country_code": "", 150 "note": '.wp_json_encode(wp_json_encode($content_array, JSON_UNESCAPED_UNICODE), JSON_UNESCAPED_UNICODE).', 140 151 "order_reference": "' . $cpfw_the_order->get_id() . '", 141 152 "product_info": ' . wp_json_encode(wp_json_encode($cpfw_products_detail, JSON_UNESCAPED_UNICODE), JSON_UNESCAPED_UNICODE) . ', 142 "package_cost": ' . $cpfw_the_order->get_total() . ', 143 "total_cod": ' . $cpfw_the_order->get_total() . ' 153 "package_cost": ' . $cpfw_the_order->get_subtotal() . ', 154 "delivery_fee": "' . intval($cpfw_the_order->get_shipping_total() ?:0). '", 155 "total_cod": "' . intval($cpfw_the_order->get_total() ?: 0) . '", 156 "payment_method": "' . sanitize_text_field($cpfw_the_order->get_payment_method_title()) . '" 157 144 158 }] 145 159 }';
Note: See TracChangeset
for help on using the changeset viewer.