Odoo Help


Display a custom variable into a view from pricelists

Alessandro D'Armiento
on 8/10/15, 6:43 AM 1,005 views

Hell. I need to show into my wholesale shop a Suggested Retail Price (SRP) float value.
As this example:

http://s16.postimg.org/prh80q0rp/Cattura.png  (Please manually select it and open in another tab since I don't have enaugh Karma Points to put direct links)

This value has to be bound with the pricelist, so it can be different according to the customer in the shop.

I created a custom field "x_retail_suggested_price" into my product.pricelist.item model and correctly added it into my product.pricelist.item.form view, as you can see.


Now my problem is that I'm not able to display it into my Frontend view. I tryied many options like 

<span t-field="product_pricelist_item.x_retail_suggested_price" style="white-space: nowrap;" t-field-options="{ "widget": "monetary", "display_currency": "user_id.partner_id.property_product_pricelist.currency_id" }"> </span>

But everytime QWeb cannot parse it and return me error 500.

As always, thanks for your help

Alessandro D'Armiento
On 8/13/15, 10:54 AM


Here you can see the content of public_product_pricelist_item table into DB,


As you can see, any row contains product_id, pricelist_id and the SRP field I need.
What should I do, is to perform an SQL query that returns the SRP vaule where pricelist_id is equal to pricelist_id associated with the customer (I don't know in which table this is stored) and product_id is equal to the product_id of product template.
Any advice?

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

2 follower(s)


Asked: 8/10/15, 6:43 AM
Seen: 1005 times
Last updated: 8/13/15, 10:54 AM