Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
3157 มุมมอง

Hello community,

I have a model A which has an one2mny relation with another model B and the later has also an one2many relation with a model C.
I want to use self.update to update the one2many relation in the model A in and onchange method so accordingly update the one2many relation in the model B.
I have managed to update the first one but the second one is not updated here what i have done :
(where line_rsc is a list that should be used to update the second one2many relation)
temp.append((0,0,{
'periode':periode,
'ca':ca,
'loc':loc,
'line_rs':line_rsc,
}))
self.update({
'periode_line':temp
})
อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

You can post all code? Need to see what you do before temp.append

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
1
ม.ค. 16
3726
0
ก.ค. 19
497
0
ก.ค. 19
848
1
ก.ค. 19
585
1
พ.ค. 16
6436