Odoo 10如何计算合作伙伴的债务总额

问题描述 投票:0回答:1

我想计算PARTNER_ID的总债务,他所有的借记卡在每一个他的发票

举个例子:

Accounting\Customer Invoices我有一个

enter image description here

当我点击bbb打开

enter image description here

当我点击的报告,在我的情况Automatski racun

enter image description here

我想在字段中输入Vaš ukupan dugbbb了所有账户的总债务

你能告诉我如何遍历所有PARTNER_ID如。在日记项目因为我试过这种方式来获得一个总bbb债务,但我不知道如何遍历

如果我不够清晰,或者您需要了解更多信息,请让我知道

odoo odoo-10
1个回答
1
投票

这是代码。

@api.onchange('partner_id')
    def set_customer_credit(self):
        self.custom_field = self.partner_id.credit
© www.soinside.com 2019 - 2024. All rights reserved.