cancel
Showing results for 
Search instead for 
Did you mean: 

Order mytasks dynamically by priority

jakepens71
Champ in-the-making
Champ in-the-making
Hello,

I am trying to figure out what i would need to customize to order the myTasks page by priority automatically when a user goes to their mytasks page.

What i would like is to order it by high priority down to low priority.

Has anyone done this before? If anyone has any ideas i would really like to hear them.

I have seen in the alfresco.war file there is a java file which is called TaskInstanceget and it uses a comparator to compare tasks by workflow in ascending order.

I am going to try to modify that with a number comparator based off of workflow priority, but that is the only thing that i can think of to change.

Any help is greatly appreciated.

Thanks!
4 REPLIES 4

mitpatoliya
Star Collaborator
Star Collaborator
Yes, what you are thinking is the way to go. Just override that java class and implement your own comparator.
Other option is to filter tasks in ftl before rendering (if you are good at javascript Smiley Wink)

swathirajan
Champ in-the-making
Champ in-the-making
I have a suggestion…
The priority is a non mandatory field.
Default one is medium.

If you are planning to sort the tasks by priority, then make it as an mandatory field.
So that, people gives the priority responsibly…

When all the tasks are listed in medium priority, there is no meaning in sort ( This happens when people do not give preference to priority)

I edited the java file but i am having trouble figuring out how to deploy it into a war file (from eclipse) in order to put it into my alfresco server to try it out. Any ideas?

mitpatoliya
Star Collaborator
Star Collaborator
You can simply create a jar file by using export as jar functionality of eclipse and place that jar under <TOMCAT_HOME>/webapps/alfresco/WEB-INF/lib
Also you need to replace entry of orinal class in context file with your new class.
Getting started

Tags


Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.