Skip ke Konten
Menu
Pertanyaan ini telah diberikan tanda
2 Replies
3930 Tampilan

How can I update a sale.order field without getting into the write() method?

If I want to change the state of the sale.order without this = write({'state', 'test'}) ?

Thank you

Avatar
Buang
Jawaban Terbai

You can try this:

     self.env['sale.order'].browse(record_to_change_id).state = 'test'

Avatar
Buang
Jawaban Terbai

Hi,

You can give compute method and return value to your field. It will show your value in the field and will not call write method.

Avatar
Buang
Post Terkait Replies Tampilan Aktivitas
0
Okt 22
1878
0
Apr 20
2337
0
Okt 24
189
1
Jul 20
3064
0
Mei 20
3441