PipelineFX Forum

Qube! => Developer Customization => Topic started by: jordan on May 17, 2010, 05:01:50 PM

Title: Is There A Way To Specify A Different Mail Template To Use
Post by: jordan on May 17, 2010, 05:01:50 PM
...depending on the simplecmd chosen for submission? Additionally, if I wanted to access custom variables in my mail file, is there a way in which to set them such that the callback has them?

Thanks,
Jordan
Title: Re: Is There A Way To Specify A Different Mail Template To Use
Post by: jordan on May 17, 2010, 07:16:01 PM
After looking further, I noticed that the Qube Preferences have the path to the mail template explicitly set globally.

So I guess I would either have to override the callback (don't know how to do that), or perhaps have some logic embedded in the mail template to determine which job type it applied to, and then return the appropriate template.

Any help would be appreciated.

Thanks,
Jordan
Title: Re: Is There A Way To Specify A Different Mail Template To Use
Post by: jburk on May 18, 2010, 12:07:57 AM
This has to be done on a more global level, with the mail_job_status_format setting in the supervisor's qb.conf.  The paths are evaluated and only used by the supervisor.

See section 10.2.44 in the Administation manual.

The mail templates have no conditional flow control in them, they're simply full of tokens that are search-and-replace targets.

If you want any finer-grained control, you'll need to dig into the callbacks, and at that point, you're past the functionality of the simpleCmd framework that most of the submission UI's in the QubeGUI->Submit menu use.
Title: Re: Is There A Way To Specify A Different Mail Template To Use
Post by: jordan on May 18, 2010, 01:25:45 PM
Fair enough...so in this case I will need to create my own callback once the job completes successfully to send an email with a specific template.

Thanks,
jordan