hypertext link in an email template to an opportunity?

I have successfully created an email template and a workflow so that when someone gets assigned a task, an email gets sent to them that identifies the name of the task and the associated opportunity. Is it possible for either of these pieces of information wtihin email to be a hypertext link to the task or opportunity so that the user doesn’t have to do a search to find them when in SuiteCRM?

More generally, I would love to know if there is a RESTful URL that can be used to point to a particular opportunity.

Thanks,

Bob

You can find similar things in the meeting notification emails, and in the Call notification emails. They have links to the Accept/Reject the call, and to view the meeting. The same goes for record-assignment emails.

Remember that sending a link implies that the user can click it without being logged on, so SuiteCRM can’t always show it.

But if you take a look at that you can probably see what you need to do…

In the Event Invite Template, I see $fp_events_link and $fp_events_link_declined. My goal is to see what other variables might be available to me to create such links, but I couldn’t find a list. When I grep through the source code, I see these referenced in htdocs/install/suite_install/AdvancedOpenEvents.php, but I don’t see them in any other files.

So, I thought maybe they are references to columns in MySQL tables, but I can’t find the SuiteCRM schema. I see a SugarCRM list of tables at http://apidocs.sugarcrm.com/schema/6.5.16/ce/, but no events table.

Can you tell me how to find what the available $link variables are?

Thanks,

Bob

No, there isn’t a schema with multiple events for you to choose from. The Events module is an “Advanced Open” module, that means it’s developed by SalesAgility, it was not present in SugarCRM.

In the Meeting email invites I see links like

http://mydomain.no-ip.org/index.php?module=Meetings&action=DetailView&record=2280703d-df91-5751-fae9-56461d328bfa

This is the standard format for URL’s in SuiteCRM, when you navigate the app you can see how these look like as you move from module to module and between different views. I think you will have better luck trying to construct an URL in this format, it should work for all modules (but only when the user is logged in).

I figured it out. The magic variable name, which I found by digging through source code (again, it would be so nice if there was a list somewhere…) turned out to be $task_id. Including the following in my email template generated a working link in the generated emails to the appropriate SuiteCRM task screen:

<a href="https://our-domain-name.com/index.php?module=Tasks&return_module=Tasks&action=DetailView&record=$task_id">$task_name</a>

For anyone who tries this, if it doesn’t work and you want to go back and edit it, once you get to the template edit screen, pick Source from the Tools menu and edit the actual HTML. There will be a lot of CSS cluttering things up, but you’ll have more control over what’s going on.

Thanks,

Bob

2 Likes