Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
2 Ответы
2232 Представления

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
1400
0
мая 24
26
1
апр. 24
4821
0
мар. 24
1702
0
мар. 24
1725