Hi there,
how can I use 'FolderService.list' if I don't know the root folder id? In my databse it is 5. If I use this (along with the proper sid) I get a nice list of folders with their id, parent id and name. Is it always '5'? Or is there a way to figure that id out?
Another question - 'AuthService.getGroups' delivers only the id, how can I get the name of that group?
Thanks!
Howto use FolderService.list
Moderator: car031
Post
Re: Howto use FolderService.list
By default the root document folder in logicaldoc is 5.
By aware however that FolderService.list will return all the folders children of the folder you request, no matter the level.
We are introducing a new method that will be available shortly called FolderService.listChildren which will return only the children folder of the first level
About the groups you're right, actually there is no way to get the name of a group.
In version 6.0.2 there will be a new web-service called Security that will better manage security-related operations
By aware however that FolderService.list will return all the folders children of the folder you request, no matter the level.
We are introducing a new method that will be available shortly called FolderService.listChildren which will return only the children folder of the first level
About the groups you're right, actually there is no way to get the name of a group.
In version 6.0.2 there will be a new web-service called Security that will better manage security-related operations
Post
Re: Howto use FolderService.list
Ok, my first demo app is done (see attached image). However, I found one 'feature' that I would declare as a bug: FolderService.list returns all folders, regardless of the security set. In my installation, I have several folders that only a certain user has access to (all other groups are removed from the security/access list). That works great in the browser: if I log on as a 'unprivileged' user the folders are simply not there. But using FolderService.list returns all folders for that 'unprivileged' user. It is not a good idea to burden security issues onto the client, that always should be the responsibility of the server.
- Attachments
-
- First Demo-App, using Auth- and Folder-Service
- FolderTree.jpg (18.95 KiB) Viewed 20681 times
Post
Re: Howto use FolderService.list
Hi skydiver,
thank you for reporting, I will pass it to our technical department for testing and if they found positive we will to correct ASAP the problem.
In the future, if you encounter bugs or you have new feature requests for extensions of web-services I recommend you to activate an account in the LogicalDOC Issue Tracking System.
Best regards
Alex
thank you for reporting, I will pass it to our technical department for testing and if they found positive we will to correct ASAP the problem.
In the future, if you encounter bugs or you have new feature requests for extensions of web-services I recommend you to activate an account in the LogicalDOC Issue Tracking System.
Best regards
Alex
Post
Re: Howto use FolderService.list
Ok Enrico,
I reported the problem and they gave me an answer.
The method in question returns all children, regardless of their level, but in order to be efficient returns all children, without checking the read permissions.
This is to have an efficient and fast method to create a tree.
In the next version of logicaldoc 6.0.2 there will be a new method even more efficient listChildren which will list only children at first level checking the read permissions.
Our engineers have confirmed however that this is not an error but merely an omission in the description of the method, this is because the possibility to read or write documents in a folder is checked when I try to execute these operations.
I reported the problem and they gave me an answer.
The method in question returns all children, regardless of their level, but in order to be efficient returns all children, without checking the read permissions.
This is to have an efficient and fast method to create a tree.
In the next version of logicaldoc 6.0.2 there will be a new method even more efficient listChildren which will list only children at first level checking the read permissions.
Our engineers have confirmed however that this is not an error but merely an omission in the description of the method, this is because the possibility to read or write documents in a folder is checked when I try to execute these operations.
Post
Re: Howto use FolderService.list
Hi Alex,
I wasn't really sure if it's a bug or intended.
Best regards,
Enrico
I wasn't really sure if it's a bug or intended.
Best regards,
Enrico
Post
Re: Howto use FolderService.list
Hi Alex,
I don't want to start a discussion about this - since it will be 'fixed' with that new 'listChildren' methode. I just want to throw onto the table, that the idea
Just my two cents
Best regards,
Enrico
I don't want to start a discussion about this - since it will be 'fixed' with that new 'listChildren' methode. I just want to throw onto the table, that the idea
is totally awkward, because actually the opposite is true. In order to write a application that reflects the access permissions - and everything else would not be acceptable by customers – you have to call ‘isReadable’ for every folder. Considering the SOAP-delay – that has a huge negative performance impact.but in order to be efficient returns all children
Just my two cents
Best regards,
Enrico
Post
Re: Howto use FolderService.list
Hi All
Could we find the user's group and permitted folder id on basis of sid.
Regards
Shrikant
Could we find the user's group and permitted folder id on basis of sid.
Regards
Shrikant
Who is online
Users browsing this forum: No registered users and 85 guests