Skip to Content
Menu
This question has been flagged
1 Reply
4464 Views

Hi,


I want to call a function and perform a action as shown here:


def happy_man():


   notification = {


       'effect': {


           'fadeout': 'slow',


           'message': 'Congratz!',


           'type': 'rainbow_man',


       }


   }

   

   return notification

  

action = happy_man() and records.action_quotation_sent()


But it looks the function does not work. What am I doing wrong?

 
Avatar
Discard
Best Answer

Hi,

Do it like this in the order,


def test_function(self):
records.action_quotation_sent()
action = happy_man()

Thanks

Avatar
Discard
Author

Thanks for your reply. Not sure what you mean. Should I make a separate second function? Or include the action_quatation within the happy_man function?

arrange code to two lines as show in above sample, first execute action_quotation_sent and in next line return the happy_man