Pular para o conteúdo
Menu
Esta pergunta foi sinalizada
2 Respostas
4511 Visualizações

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,

Avatar
Cancelar
Melhor resposta

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

Avatar
Cancelar
Autor Melhor resposta

Thanks Cybrosy.

Avatar
Cancelar
Publicações relacionadas Respostas Visualizações Atividade
0
out. 21
2368
2
jun. 25
1048
1
mai. 25
1075
2
nov. 24
2245
0
fev. 24
1404