答案 0 :(得分:0)
如果您需要在仪表板中使用此值,则在仪表板模型中添加计算字段,并在那里计算所有未清发票,并将其添加到仪表板中
答案 1 :(得分:0)
#You first need to get the open invoices
open_invoices = self.env['account.invoice'].search([('state','=','open')])
#then get invoice lines
invoice_lines = open_invoices.mapped('line_ids')