Page 1 of 1

Report or added column

PostPosted:Mon Feb 06, 2017 11:20 pm
by rmichalowski
Hello,

What I want to do is get a list of files in a directory with the notes associated with each file. Having the date uploaded/modified would be nice. Is there any way to get this information?

Thank you

User

Re: Report or added column

PostPosted:Thu Feb 09, 2017 10:21 am
by jllort
First you must create and script what retrieves that information ( unzip the https://wiki.openkm.com/index.php/File:Userslogin.rep and take a look at the script what is into -> is returning a hashmap ).

Basically you must get a list of documents and convert data into map ( take this code as an starting point, take in mind the print etc.. has not sense from report side, it's only for checking from scripting view )
Code: Select all
import com.openkm.api.*;
import com.openkm.bean.*;

for (Document doc : OKMDocument.getInstance().getChildren(null,"/okm:root/somepaht")) {
   // Here get notes
   print(doc.getNodes()+"<br/>");
}

Re: Report or added column

PostPosted:Tue May 24, 2022 7:29 am
by nishant8900
I tried with above example, it wont work. can u share me the whole file. It will be helpful , thanks. :)

Re: Report or added column

PostPosted:Sun May 29, 2022 4:41 pm
by jllort
Did you check the scripting in the administration > scripting feature?
What version of OpenKM do you have installed?