跳至内容
菜单
此问题已终结
5359 查看

class SaleAdvancePaymentInv(models.TransientModel):

    _inherit = "sale.advance.payment.inv"

    @api.multi

    def _create_invoice(self, order, so_line, amount):

        inv_obj = super(SaleAdvancePaymentInv, self)._create_invoice(order, so_line, amount)

        inv_obj.write({'service_id':order.service_id.id})

This is my code.service id does from from sale order to invoice through invoiceable lines.

But when I use downpayment the service id is passed to invoice.

What is the reason behind this.?
How to pass the values through the invoiceable line?


        

形象
丢弃
编写者

service id does not pass from sale order to invoice through invoiceable line

invoiceable lines are created when you confirm an order. You can check the function when a sale order is confirmed and make necessary changes.

编写者

thanks amal for info

相关帖文 回复 查看 活动
1
7月 18
3484
2
10月 17
5658
1
3月 15
3531
1
4月 23
7480
1
6月 21
2061