Hello Ivy Team,

I`m building a process for overriding the default email notifications as described here: http://developer.axonivy.com/doc/latest/EngineGuideHtml/administration.html#administration-applicationdefaults

I have a problem to build an URL to the task.

I`m trying this ways, but no luck:

in.task = ivy.wf.findTask(in.notificationTaskId);
in.taskUrl = ivy.html.taskstartref(in.task);
in.taskUrl = ivy.var.FQDN + in.task.getFullRequestPath() + "?taskId=" + in.notificationTaskId.toString();

the URL is valid but the Id of the task is different than in the Task List view.

I`m using version 6.4

Am I doing something wrong or this is a bug in this version ? p.s. it does not work bot on the Designer and on the Server

Best Regards, Yordan

asked 06.04.2017 at 08:30

Stelt0's gravatar image

Stelt0
(suspended)
accept rate: 12%

edited 06.04.2017 at 15:55

Alex%20Suter's gravatar image

Alex Suter ♦♦
3.1k122247


Hello Alex,

Thanks for your reply !

As I mentioned, in the very first part of my question: " I`m building a process for overriding the default email notifications as described here: http://developer.axonivy.com/doc/latest/EngineGuideHtml/administration.html#administration-applicationdefaults "

this means that in.notificationTaskId is provided by the engine. And it is not wrong because the email are sent to the corresponding people and the information I get from the task (name, description, etc..) are accurate.

Yes, the users have access to their tasks. They see them in the task list. But the URLs are different. And they are different by the Id of the task....

how do I get the task Id {data.task.id} ? I don`t see it as a property of ITask in Ivy script step. there is no getId() method. is it different than the id that we are using to query for task by id ? ivy.wf.findTask(in.notificationTaskId);

Best Regards, Yordan

link

answered 06.04.2017 at 17:20

Stelt0's gravatar image

Stelt0
(suspended)
accept rate: 12%

There is no known bug. In this case in.notificationTaskId is wrong? notificationTaskId is the id of the task that is ready to be processed by the user.

Some pitfalls: 1. When you click on the link in the mail, then you go directly to the task. And if there is nothing to do, the task is done, which will redirect you to the task list. And there you may have still some other tasks. But you won't see the notificated task. 2. Do you have the right permissions/roles to see the necessary tasks in the task view?

In the JsfWorkflowUi the url will be build as follows: #{facesContext.externalContext.requestContextPath}/pro/#{data.task.fullRequestPath}?taskId=#{data.task.id}

link

answered 06.04.2017 at 16:14

Alex%20Suter's gravatar image

Alex Suter ♦♦
3.1k122247
accept rate: 84%

edited 06.04.2017 at 16:14

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×68
×34
×4

Asked: 06.04.2017 at 08:30

Seen: 4,212 times

Last updated: 06.04.2017 at 17:20