Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
2 Ответы
4748 Представления

Hi people,

I'm very new on ODOO and I need to take care about a small task. I'm ready to learn new things :) who can please help me?


I need to get one value and show it on front-end product template. I've already found how to edit backend, add custom variables and how to add them to frontend. But I didn't find how to get a purchased amout of a individual product and how to show it on front-end product template.


Can someone please help me?

Аватар
Отменить
Автор Лучший ответ

Thanks to all, I have already solved this. I have found a variable "product.sales_count" and this gave a value of purchased products. Is there some reason why not to use this variable?

Thanks

Аватар
Отменить
Лучший ответ

Hello,

normally if you have installed "Purchase" application and bought the concerned product, you can see a smart button ("x Units Purchased") in the product template form.

In odoo 14 (and maybe lower version too) the field name is "purchased_product_qty".

Hope it will help you.

Аватар
Отменить
Related Posts Ответы Просмотры Активность
2
нояб. 22
12424
2
авг. 25
213
2
авг. 25
215
2
авг. 25
420
0
авг. 25
407