Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
3834 Zobrazení

I am trying to create sales order, confirm and create regular invoices. I managed to create 
the sale order and confirm it but not able to create regular invoices.
Here's the example of my code:
s = models.execute_kw(db, uid, password, 'sale.order', 'create', [{
'partner_id': 1, 'validity_date': "2021-08-09", 'state': 'sale',
'order_line': [(0, 0, {'product_id': 2, 'product_uom_qty': 2, 'price_unit': 10.00}),
(0, 0, {'product_id': 5, 'product_uom_qty': 4, 'price_unit': 20.00}),
],}])
models.execute_kw(db, uid, password, 'sale.advance.payment.inv', 'create', {
'id': s,
'create_invoices': [{'advance_payment_method': "delivered",}]
})
Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
1
kvě 21
2808
1
dub 24
1555
3
říj 23
7886
1
říj 22
3982
1
zář 21
3180