Plugin Directory

Changeset 2846945


Ignore:
Timestamp:
01/11/2023 06:20:25 PM (3 years ago)
Author:
ascendedcrow
Message:

1.0.19

Location:
shop-2-api/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • shop-2-api/trunk/includes/Base/EnqueueWC.php

    r2825412 r2846945  
    9292                'description' => __('If checked it will sync product to Bol.com', 'woocommerce'),
    9393                'value' => $shop2api_sync_to_bol ? $shop2api_sync_to_bol : 'no'
     94            )
     95        );
     96
     97        // Add EAN Number
     98        $shop2api_ean_number = get_post_meta( $post->ID, 'shop2api_ean_number', true);
     99        woocommerce_wp_text_input(
     100            array(
     101                'id'            => 'shop2api_ean_number',
     102                'wrapper_class' => 'cfwc-custom-field',
     103                'label'         => __('Bol EAN Number', 'woocommerce'),
     104                //'description'   => __( 'An optional EAN Number that you can map on Shop-2-api or use for orders.', 'woocommerce' ),
     105                'value'         => $shop2api_ean_number
    94106            )
    95107        );
     
    162174        $post_id = $product->id;
    163175        $this->shop2api_set_meta_for_post_id($post_id);
    164 
    165 
    166176    }
    167177
     
    198208            }
    199209        }
     210
     211        $shop2api_ean_number = $_POST['shop2api_ean_number'] ?? '';
     212        update_post_meta($post_id, 'shop2api_ean_number', $shop2api_ean_number);
    200213    }
    201214
     
    209222        $woo_checkbox = isset($_POST['shop2api_koopblok_service']) ? 'yes' : 'no';
    210223        update_post_meta($variation_id, 'shop2api_koopblok_service', $woo_checkbox);
     224
     225        $shop2api_ean_number = $_POST['shop2api_ean_number'] ?? '';
     226        update_post_meta($variation_id, 'shop2api_ean_number', $shop2api_ean_number);
    211227    }
    212228
     
    246262        );
    247263        echo wp_kses('</div>', $this->allowed_html);
     264
     265        // Add EAN Number
     266        $shop2api_ean_number = get_post_meta( $variation->ID, 'shop2api_ean_number', true);
     267        woocommerce_wp_text_input(
     268            array(
     269                'id'            => 'shop2api_ean_number',
     270                'wrapper_class' => 'cfwc-custom-field',
     271                'label'         => __('Bol EAN Number', 'woocommerce'),
     272                //'description'   => __( 'An optional EAN Number that you can map on Shop-2-api or use for orders.', 'woocommerce' ),
     273                'value'         => $shop2api_ean_number ? $shop2api_ean_number : ''
     274            )
     275        );
    248276    }
    249277
  • shop-2-api/trunk/readme.txt

    r2832543 r2846945  
    1161161) Small bug fix on removing previous mappings.
    117117
     118= 1.0.19 =
     1191) Added an EAN Number field to the product page
     1202) Extended the EAN Number field to variations
     1213) EAN Numbers can now be split up with a comma, so multiple EAN's can be sent over to Bol.com
     122
    118123== Instructions ==
    1191241) After installing Shop2Api, a new menu item will be available in your WordPress installation, you can continue and click on it and enter you token which was mailed to you.
  • shop-2-api/trunk/shop-2-api.php

    r2832543 r2846945  
    55Plugin URI: https://wordpress.org/plugins/shop-2-api/
    66Description: The plugin Shop2Api will sync products between e-Commerce platforms. The current supported e-Commerce platforms are WooCommerce to Bol.com, and we are working on Amazon, Shopify and others.  We added a koopblok service so that you can check if you lower your price can you get koopblok.
    7 Version: 1.0.18
     7Version: 1.0.19
    88Requires at least: 5.0
    99Requires PHP:      7.2
     
    3434define('SHOP2API_PLUGIN_URL', plugin_dir_url( __FILE__ ));
    3535define('SHOP2API_PLUGIN', plugin_basename( __FILE__ ));
    36 define ('VERSION', '1.0.18');
     36define ('VERSION', '1.0.19');
    3737
    3838// Register items in the project.
Note: See TracChangeset for help on using the changeset viewer.