I want to change sale order lines colour based on selction field
py
decoration_color = fields.Selection([('red', 'red'), ('green', 'green'), ('blue', 'blue'), ('purple', 'purple')])
xml code
expr="//sheet/notebook/page[@name='order_lines']/field[@name='order_line']/tree"
position="attributes">
name="decoration-danger">decoration_color == 'red'
name="decoration-success">decoration_color == 'green'
name="decoration-info">decoration_color == 'blue'
name="decoration-warning">decoration_color == 'purple'
this is changing colours of description,unit price and subtotal only,all the sale order line fields are not changing
Hi,
Follow this forum it shows how to color so lines
https://www.odoo.com/forum/help-1/odoo-10-how-to-colorize-order-lines-171365
Hope it helps you!