Now, you can import and export all your dynamic rules easily. Let’s see how it works.
WholesaleX Dynamic Rules Export
You can create and customize wholesale discount rules with WholesaleX dynamic rules easily. Check out the documentation for Dynamic Rules for a better understanding of how it works.
But now you will see two extra buttons at the top of the dynamic rules section: import and export.
Click the “Export” button to download a CSV file containing all the created dynamic rules data and datasets.
Here is a list of all the data that will be exported in the CSV file:
- ID
- Status
- Title
- Type
- Applicable For
- Applicable Users
- Applicable Roles
- Applicable On
- Product In Lists
- Product Not in Lists
- Categories In Lists
- Categories Not in Lists
- Variation In Lists
- Variation Not in Lists
- Product Discount Data
- Cart Discount Data
- Payment Discount Data
- Payment Order Quantity Data
- BOGO Discount Data
- Shipping Rule Data
- Min Order Quantity Data
- Tax Rule Data
- Quantity Based Data
- Extra Charge Data
- Buy X Get Y Data
- Max Order Quantity Data
- Restrict Product Visibility Data
- Conditions Data
- Usages Limit
- Start Date
- End Date
WholesaleX Dynamic Rules Import
Now, let us see how we can import the dynamic rules.
Click the “Import” button to get a popup, where you can:
- Upload CSV
- Update Existing Rules
In the Upload CSV option, you can drag and drop files or click on the link to open File Explorer and select your desired CSV.
In the Update Existing Rules section, you can mark the checkbox only to update the existing rules. And it will only update the existing rules and not add any new ones.
Yes, you can modify the CSV file according to your needs and import that CSV file to update or add dynamic rules.
Customizing the CSV File
We will show you the data and datasets of each field so you can customize your CSV and import it to update the dynamic rules accordingly.
Here are the CSV modifiers you need to know if you want to modify the CSV file. Valid Rule Type Column: product_discount cart_discount payment_discount payment_order_qty buy_x_get_one shipping_rule min_order_qty tax_rule quantity_based extra_charge buy_x_get_y max_order_quantity restrict_product_visibility Rule Status: "yes/no" Applicable For: all_users all_roles specific_users specific_roles Applicable Users : "user_{user_id}" For multiple datasets, use semicolon as separator ( ; ) ex: user_1;user_2 Applicable Roles: "role_id" For multiple datasets, use semicolon as separator ( ; ) ex: user_1;user_2 Product Filter: all_products products_in_list products_not_in_list cat_in_list cat_not_in_list attribute_in_list attribute_not_in_list Product Discount/ Cart Discount: "_discount_type:{value};_discount_amount:{value};_discount_name:{value}" valid discount type: percentage, amount,fixed Payment Discount: "_payment_gateways:{value};_discount_type:{value};_discount_amount:{value};_discount_name:{value} valid payment gateways (gateway id): cod,bacs" Payment Order Quantity: "_payment_gateways:{value};_order_quantity:{value} valid payment gateways (gateway id): cod,bacs" Buy X Get One: "_minimum_purchase_count:{value}" Shipping Rule: "__shipping_zone:{value};_shipping_zone_methods:{value}" ex: __shipping_zone:1;_shipping_zone_methods:3,5,10 Min Order Quantity: "_min_order_qty:{value}" Tax Rule: "_tax_exempted:{value};_tax_class:{value} valid tax exempted: yes/no" ex: _tax_exempted:no;_tax_class:always-tax Quantity Discount Based: “_discount_type:{value},_discount_amount:{value},_min_quantity:{value},_discount_name:{value}; _discount_type:{value},_discount_amount:{value},_min_quantity:{value},_discount_name:{value}” Extra Charge: "_payment_gateways:{value};_charge_type:{value};_charge_amount:{value};_charge_name:{value}" Minimum Order Quantity: "_minimum_purchase_count:{value};_free_item:{value};_free_item_count:{value}" Maximum Order Quantity: "_max_order_qty:{value}"
After uploading your CSV file, click “Continue” to map the CSV fields. You can choose to change the fields according to your needs. You can adjust the following field data with a dropdown for each:
- ID
- Status
- Title
- Type
- Applicable For
- Applicable Users
- Applicable Roles
- Applicable On
- Product In Lists
- Product Not in Lists
- Categories In Lists
- Categories Not in Lists
- Variation In Lists
- Variation Not in Lists
- Product Discount Data
- Cart Discount Data
- Payment Discount Data
- Payment Order Quantity Data
- BOGO Discount Data
- Shipping Rule Data
- Min Order Quantity Data
- Tax Rule Data
- Quantity Based Data
- Extra Charge Data
- Buy X Get Y Data
- Max Order Quantity Data
- Restrict Product Visibility Data
- Conditions Data
- Usages Limit
- Start Date
- End Date
Now click “Run the Importer” to import the data. After the completion, you will see if the data are successfully imported or not. If you have any errors, you can check them by clicking the “View Error Logs” button.
And that is how you can import/export WholesaleX Dynamic Rules easily.