Page 1 of 1

Search for which workflows are using which files

PostPosted:Thu Apr 13, 2017 5:15 pm
by alexwgordon
Hi All,

Is there a way to search for all the workflow instances that are using a given file? Currently the workflow dashboard doesn't show what the file in the workflow is without clicking into the workflow and I need to delete the workflows that use that file in order to delete/update the file. Is there like a database query or something? Thanks!

Re: Search for which workflows are using which files

PostPosted:Sat Apr 15, 2017 7:33 am
by jllort
You want to know for an specific document what workflows are running ? or for the whole repository what documents are running a workflow ?

Re: Search for which workflows are using which files

PostPosted:Tue Jun 27, 2017 2:54 pm
by alexwgordon
I figured out a way to create a note and/or comment with the workflow process instance which let's me find the workflow in the Admin panel with this:
Code: Select all
Long myProcInst = executionContext.getProcessInstance().getId();
executionContext.getToken().addComment("The Workflow Instance is " + myProcInst.toString());
But is there a way to dynamically change the name of a task node in a workflow? We discussed changing the dashboard itself here: viewtopic.php?f=4&t=21094

But I struggled a lot in my attempts there with no success. I think if I could just have a workflow task name that dynamically changed to include the document name that could potentially be an easier implementation? Not even sure if that is possible. Thanks!

Re: Search for which workflows are using which files

PostPosted:Mon Jul 03, 2017 9:23 am
by pavila
Take a look a this page https://docs.openkm.com/kcenter/view/ok ... sions.html and make use of the Workflow Document Info extension which will show the workflows related to a given document.

Tell me if this matches your requirement.

Re: Search for which workflows are using which files

PostPosted:Wed Jul 05, 2017 5:57 pm
by alexwgordon
Hi Pavila,

I don't believe this is what I'm looking for. It doesn't seem to provide me any additional information. Basically what I'm attempting to do is make it so the user who has a task or many tasks in most cases, the ability to see which file their task is associate with, WITHOUT having to click on "Process Instance" or "Data" section in the task to see what it is.

Ideally I could show the document name somewhere where the green arrow is in the attached image, so users can quickly click on the correct task without clicking through the list.

Hopefully that makes sense. Thanks!
Screen Shot 2017-07-05 at 10.53.35.png
Screen Shot 2017-07-05 at 10.53.35.png (79.76 KiB) Viewed 3980 times

Re: Search for which workflows are using which files

PostPosted:Wed Jul 05, 2017 7:41 pm
by pavila
Then you have to modify the OpenKM source code. Anyway I don't why it's a problem to click in the "Process Instance" item.

The only "cheaper" option is to create a JSP which making use of the Workflow API list the information you want. Right now I'm not sure if OpenKM Community has an extension which may embed a JSP in a new tab. Take a look at https://docs.openkm.com/kcenter/view/ok ... nd-ui.html

Regards.

Re: Search for which workflows are using which files

PostPosted:Thu Jul 06, 2017 2:48 pm
by alexwgordon
Sure, with only a few tasks it's no problem to just click through the list and figure out which doc you're looking for, but it can be a problem if someone has 50+ tasks and is looking for a specific file, even 10-20 tasks is not ideal and is a bit time consuming (especially if that person is my boss looking for a file :? )

So looks like a JSP would not quite be what I'm looking for. What I'd really like is just to create either another column in the task list for the document name or have the task node change dynamically with the document name included. Any hints on getting something like that implemented? Thanks again Pavila

Re: Search for which workflows are using which files

PostPosted:Sat Jul 08, 2017 10:49 am
by jllort
Do you have JAVA skills and development environment ( just this weeks we have realease a new version based in virtual machine, OVA file ). In case you want to modify the source code, we can share with you some clues about it ( really these changes are yet done in professional edition and I remember 1-2 months ago another user who wanted something similar and I shared from that post some clues about how doing it, sorry but I do not remember exactly the post ).

Take a look here:
viewtopic.php?f=4&t=21094&p=44187&hilit ... ent#p44187