I need to create a module in prestashop 1.7.3 to make available wholesale prices. The main idea: There are 3 types of prices in cart: retail price, small_wholesale price and BIG_wholesale price. I need to add small_wholesale price and big_wholesale price fields to my product and allow admin to add product and set them in prices tab(below retail price). Actually it's easy to create extra database fields in product table what i did, but still don't know what to override to create fields in product creation page, it should look like this.
Related
I am using some custom fileds from advanced custom fields plugin. In the case I want to add a addon product to the variation and sum up the value. I can achieve that only if the product quantity is 1. It is a flat price rather based on quantity.
What I want to achieve is update Cart price and checkout page with the updated price.
I have woocommerce store and I have integration with manufacturer based on JSON, where I'm parsing his JSON and adding his product quantities to woocommerce warehouse.
But additionally I have my own stock of this same products, that's why I need 2 ecommerce warehouses - for manufacturer stock and for my own stock.
I've build those 2 warehouses, where my stock is on separate mysql table than woocommerce, but now I need to add event, that if someone purchase product, the quantity of product will be decreased from my warehouse (external from woocommerce).
How to find woocommerce purchase event, to which I could add function which will decrease my stock product quantity in not woocommerce table?
You could use the woocommerce's 'woocommerce_after_pay_action' hook.
Reference: https://woocommerce.github.io/code-reference/hooks/hooks.html
Add this code in a must-use plugin or in functions.php
function after_purchase_action($order) {
// do something
}
add_action('woocommerce_after_pay_action', 'after_purchase_action', 10, 1 );
I have custom product which is linked to woocommerce products list. I have to add custom weight for that product. I would like to add custom field for particular product in the backend and pull those values in the front end for shipping calculation
For example:
I have template sizes 8*8 = 1KG, 12*12 = 21kg,.... like that i have to add multiple template sizes and i have to show when user selected and 8*8 means the product should pull weight from the backend particular weight. there will not be any additional price for select template sizes
Please advise on this.
i have created a new attribute products (price2) with different price respect standard price of magento.
I have modified view.phtml and catalog view to show price2 if standard price is higher, but i have a problem if add to cart product with price2; the product's price not respect price2 but standard price of magento.
How can resolve this problem? I have think use observer, but i can't communicate price2.
I have a store where i would like to give 20% discount to some products if a specific product is added.
Example:
I have 8 products A,B,C,D,E,F,G,H
and users selects all the products I only want to give discount on A,B,D,E.
How this can be done using shopping cart rule magento?
With Shopping cart price rules you can apply discount for specific products using product's SKU
This link will help (section X% off specific products)