Hi,
I would like to have the process send out email to the task actor when an interactive activity is reached. with the task id in the email when user click the URL, will automatically open that task.
Is there a way to do it by ebase available function or feature?
Thanks,
Xiaoli
interactive activity with email alert.
Moderators: Jon, Steve, Ian, Dave
-
- Ebase User
- Posts: 272
- Joined: Fri Dec 14, 2012 2:55 pm
- Location: Ottawa
-
- Moderator
- Posts: 1342
- Joined: Wed Sep 12, 2007 12:49 pm
This post discusses a similar requirement http://forum.ebasetech.com/forum/viewtopic.php?t=439
Probably the easiest way is to use an assignment handler to send the email - this is just a script so you can use email resources in the usual way. This approach is only possible if you are using custom assignment - as assignment handlers are only invoked to resolve custom assignments. If you know the userid and email address in advance you could pass these into the assignment handler as process attributes. If you are using role based assignment this approach won't work as the userid assigned to the task isn't known at this point.
The assignment handler doesn't have knowledge of the interactive task id so it would be difficult to take the user directly to the task from an email link. You could instead give them a link to a task list and the task you are processing should appear in this list.
Another approach might be to use an escalator but I'm not sure whether the escalator would be called before or after the assignment is performed.
Probably the easiest way is to use an assignment handler to send the email - this is just a script so you can use email resources in the usual way. This approach is only possible if you are using custom assignment - as assignment handlers are only invoked to resolve custom assignments. If you know the userid and email address in advance you could pass these into the assignment handler as process attributes. If you are using role based assignment this approach won't work as the userid assigned to the task isn't known at this point.
The assignment handler doesn't have knowledge of the interactive task id so it would be difficult to take the user directly to the task from an email link. You could instead give them a link to a task list and the task you are processing should appear in this list.
Another approach might be to use an escalator but I'm not sure whether the escalator would be called before or after the assignment is performed.
0 x
-
- Ebase User
- Posts: 272
- Joined: Fri Dec 14, 2012 2:55 pm
- Location: Ottawa
assignment key
Thank you for the thread.
I tried using customer assignment.
However, it failed to take field's value as assignment key.
I set &&approverEdirID to the assignment key. approverEirID is a process field.
However, the workflow assignment service script got "&&approverEdirID" as the WFKEY, not the real value of the process field.
I am not sure where it went wrong.
Thanks for your help
I tried using customer assignment.
However, it failed to take field's value as assignment key.
I set &&approverEdirID to the assignment key. approverEirID is a process field.
However, the workflow assignment service script got "&&approverEdirID" as the WFKEY, not the real value of the process field.
I am not sure where it went wrong.
Thanks for your help
0 x
-
- Moderator
- Posts: 1342
- Joined: Wed Sep 12, 2007 12:49 pm
-
- Moderator
- Posts: 1342
- Joined: Wed Sep 12, 2007 12:49 pm
You need to issue fetchTable to see the data. ATTRIBUTES has two columns: ID and VALUE. You should be able to get the approver process attribute something like this:
Code: Select all
var attrTAB=tables.ATTRIBUTES;
attrTAB.fetchTable();
var row = attrTAB.findRow(attrTAB.ID, "approver");
if (row != -1)
{
attrTAB.setCurrentRow(row);
var approver= attrTAB.VALUE.value;
}
0 x
-
- Ebase User
- Posts: 272
- Joined: Fri Dec 14, 2012 2:55 pm
- Location: Ottawa
Thank you. Got it.
Then I called the following for the assignment to a single user
// how to assign task
tables.USERS.insertRow();
tables.USERS.USERID.value = fields.actorEdirID.value;
tables.USERS.updateTable();
Then I got the exception:
Failed while enacting node: unknown: Form Version not found %_ALIAS_GLOBAL_%:db9ed8e0-bf0f-454c-bd4f-b2bf1df5459a
Then I called the following for the assignment to a single user
// how to assign task
tables.USERS.insertRow();
tables.USERS.USERID.value = fields.actorEdirID.value;
tables.USERS.updateTable();
Then I got the exception:
Failed while enacting node: unknown: Form Version not found %_ALIAS_GLOBAL_%:db9ed8e0-bf0f-454c-bd4f-b2bf1df5459a
0 x
Who is online
Users browsing this forum: No registered users and 6 guests