跳至內容
選單
此問題已被標幟
2 回覆
6728 瀏覽次數

is it possible to add a minimum amount of purchases to products and variants for purchases on the website? (odoo12)

頭像
捨棄
作者 最佳答案

Impossible because I have different quantities for each product. It is not possible to integrate this information? Because it seems to me that in the part produced one inserts a tariff according to the quantities.

For me it is essential information. It should at least be in the e-commerce after part in the classic life management part is not an obligation. I find it really bad. Can not do something?

頭像
捨棄

As it is not possible by default, you can extend the feature by customization and make it possible :)

作者

how to do? can you give an example?

Example of some customization? You can see a lot of modules in the Odoo store which add new functionalities in the e-commerce, you can refer those modules and see

最佳答案

Hi,

If you are looking at this case, like when you sell your products through the online the customer should purchase a minimum quantity, by default there seems no such option is available.

For the backend sales, there seems some third-party modules are available in the store, but the same cannot be found for the e-commerce. Anyway, you can have a search for it.


A little workaround that you can do is that, activate the developer mode, navigate to Settings -> Technical -> Views, search for Select Quantity, then if you check the view you can see a line like this,

<input type="text" class="form-control quantity" data-min="1" name="add_qty" value="1"/>

You can change this Line as per the need, suppose if you need to set minimum quantity as 3, change the data-min and value to 3 in the above line,

<input type="text" class="form-control quantity" data-min="3" name="add_qty" value="3"/>

This is not flexible as it will be applied for all the products.


Thanks

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
0
7月 24
1142
1
4月 24
2257
0
11月 23
1757
0
6月 24
2234
3
10月 23
8980