This question has been flagged

Hi,


I want an automatic email to be sent each time a session is closed (and posted) with the Sales Details Report in POS attached. 

I know it can be done through scheduled actions under technical, but I need help with the code. 


Thanks. 

Avatar
Discard
Best Answer

Hello Feryial Mangou,

If you want to send email whenever POS session get closed then you can inherit action_pos_session_closing_control method of pos.session object like this: 

    def action_pos_session_closing_control(self):

         # your code to send email 

         return super(PosSession, self).action_pos_session_closing_control()

Thank you!

Regards,




Email:      odoo@aktivsoftware.com  

Skype: kalpeshmaheshwari

   

Avatar
Discard