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

Hi,

I want to use an automated action which changes the state of my CRM opportunity automatically to a 'won' status when I validate the (sales)quotation which is related to the opportunity. can someone give me some advice?

Thanks in advance for your answer

Thijs


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

Hi,

For changing the state of CRM opportunity automatically to a 'won' status when validating the (sales)quotation, First Inherit the sale.order model. Then super the function action_confirm. 

def action_confirm(self):
              res = super(SalesOrderInherit, self).action_confirm()
              if self.opportunity_id:
                      self.opportunity_id.action_set_won_rainbowman()
             return res

Regards

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


There is opportunity_id field.

Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
0
вер. 24
1443
0
трав. 24
26
1
квіт. 24
4875
0
бер. 24
1747
0
бер. 24
1752