تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
2 الردود
4504 أدوات العرض

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.

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
0
أكتوبر 21
2361
2
يونيو 25
1046
1
مايو 25
1066
2
نوفمبر 24
2238
0
فبراير 24
1401