-2
上odoo 8我嘗試執行此操作:類型錯誤:「詮釋」對象不是可迭代odoo8
@api.onchange('projetbc_ligne_ids')
def onchange_evalID(self):
self.test= self.projetbc_ligne_ids.produit.id
query = "SELECT sum(quantite) FROM projet_bc_ligne where produit = %s"
self.env.cr.execute(query, (tuple(self.projetbc_ligne_ids.produit.id),))
# self.env.cr.execute("SELECT sum(quantite) FROM projet_bc_ligne where produit = %s",(tuple(self.projetbc_ligne_ids.produit.id),))
self.projetbc_ids.quantite_encoure = self.env.cr.fetchone()[0]
我得到這個錯誤: 類型錯誤:「詮釋」對象不是可迭代
一些想法?