Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
1 Відповісти
4159 Переглядів

Hello Dears,.


I want when quotation status be Cancel the Customer i select in the quotation will be deactivate automatically 

Аватар
Відмінити
Найкраща відповідь

Hi,

You can make the customer inactive by super the function of the cancel button.

class SaleOrderInherit(models.Model):
_inherit = 'sale.order'

@api.multi
def action_cancel(self, vals):
self.partner_id.active = False
res = super(SaleOrderInherit, self).action_cancel()
return res


Thanks

Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
Sales quotation Вирішено
2
бер. 24
2674
5
трав. 20
3865
1
бер. 15
5017
1
бер. 15
4112
2
лип. 25
1453