|
|
self.value_justification = False
self.value_computed_justification = False
for move in self:
if not move.is_in:
continue
move.value_justification = move._get_value_data()['description']
computed_value_data = move._get_value_data(ignore_manual_update=True)
if computed_value_data['description'] == move.value_justification:
move.value_computed_justification = False
else:
value = move.company_currency_id.format(computed_value_data['value'])
move.value_computed_justification = self.env._(
'Computed value: %(value)s\n%(description)s',
value=value, description=computed_value_data['description'])
|
|