Skip to Content
Menú
This question has been flagged
1 Respondre
2002 Vistes

Hi Odoo Mates,

I have a simple question I have make a new field in res.partner

It called pos_conter I want it to pe as the number of the pos order for this customer

So I did this

class ResPartnerInherit(models.Model):
    _inherit =
"res.partner"

   
pos_counter = fields.Integer(string='Pos Order Counter', compute="_compute_pos_order")

   
def _compute_pos_order(self):
       
for rec in self:
            rec.pos_counter = rec.pos_order_count

 

but the pos_order_count is disappear from the customer field

 

And if I remove the code it show up again

 

What did you suggest to solve this problem.

 

Thanks.


Avatar
Descartar
Autor Best Answer

Please any answer or my q is not clear?

Avatar
Descartar
Related Posts Respostes Vistes Activitat
3
d’abr. 25
1401
1
d’ag. 24
2204
3
de maig 24
11589
1
de set. 23
3746
0
d’ag. 23
1819