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

for example :

i want to send an email via button
in my_button :
    for rec in self :

rec.send_mail

rec.boolean = True

so if the user want to send an email to many user at the same time so users will use default fuction Partner Mass Mailing.
in default didn't have a rec.bolean = True.


so i want to do something like this :
    each time user send_email :

in xml will automatically trigger boolean in the python via that XML.    ​

The point is i want to make the boolean to true via xml.



Avatar
Discard
Best Answer

YOu can define a button in you XML view. Button on XML, if defined as tyoe=object can call a python function. In this way you can call python code from XML view.

Avatar
Discard
Related Posts Replies Views Activity
1
Apr 23
2270
2
Dec 23
11087
3
Jul 22
20958
3
Nov 21
8196
2
Oct 21
7007