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

Good day everyone,

I'm trying to get a list of the related invoices that were create from a sale order.  I noticed this field invoice_ids it seems like an array style where each invoice is stored , but I can't figure the way to extract from there the invoice numbers and store it in a separate char field.


Thanks in advance,

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hi,
The field ‘invoice_ids’ of model ‘sale.order’ represents the ‘account.move’ model records of the corresponding sales order. You can access the invoice number of each invoice using the ‘name’ field of each invoice_ids inside a for loop, in order to avoid singleton error and store inside the required char field.
Regards

อวตาร
ละทิ้ง
ผู้เขียน คำตอบที่ดีที่สุด

Thanks Cybrosy.

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
0
ต.ค. 21
2522
2
มิ.ย. 25
1208
1
พ.ค. 25
1271
2
พ.ย. 24
2397
0
ก.พ. 24
1579