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

Hi, I develop under odoo 15. 

I have already created a module of entities "entities" management (Customers, Vondors, Products, ...), and now I am creating an invoincing "invoice" module.


For the moment, in the "invoice" module, I have created a model "invoice_temporary.py" to collect all the data needed for an invoice from the "entities" models.


So now I plan to create the real invoice (which respects the condition of inalterability) from the "invoice_temporary" model.

With this model, I have all the data needed for the real invoice, so I ask here :

"How can I create an inalterable invoice from a simple model ?"

"Should I create the invoice in another way ?"


Thanks in advance, I tried to be as clear as possible,

Hugo


Avatar
Cancelar
Autor

Hi, and thanks for the answer,

For the first link you gave me (the other forum answer), I understand how the function works, but not how to use it. I mean that I don't know where (in which file ?) to put it, I tried to place it in the model itself, but I don't know how to use it after it has been declared.

Could you please help me to know in which file i have to place the function, and then how and where do I call it ?

Thank you

Melhor resposta

Hi Hugo,

Check this existing forum answer : https://www.odoo.com/forum/help-1/create-invoice-by-code-odoo14-190183

And for creating record from odoo code ,refer: https://www.youtube.com/watch?v=Jssb15ADeyg 

Hope this will help you 

Thank you




Avatar
Cancelar
Publicações relacionadas Respostas Visualizações Atividade
0
abr. 23
2034
0
jan. 23
1803
1
jul. 25
550
2
jul. 25
697
1
jul. 25
1751