From 323af2c25902c3bfaa039c9345086b3f1564134d Mon Sep 17 00:00:00 2001 From: Tanguy Charlier Date: Fri, 11 Mar 2016 16:49:23 +0100 Subject: [PATCH] [FIX] Doc: Invalid example in compute doc --- doc/reference/orm.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/reference/orm.rst b/doc/reference/orm.rst index 62ef4a3d018..10ac368e950 100644 --- a/doc/reference/orm.rst +++ b/doc/reference/orm.rst @@ -376,9 +376,9 @@ it uses the values of other *fields*, it should specify those fields using def _apply_discount(self): for record in self: # compute actual discount from discount percentage - discount = self.value * self.discount - self.discount_value = discount - self.total = self.value - discount + discount = record.value * record.discount + record.discount_value = discount + record.total = record.value - discount Related fields ''''''''''''''