12-06-2016 01:12 PM
Hi,
i need to count user related site's documents.
i have used following url . but it return count of all documents.
Regards
janaka
12-09-2016 04:41 AM
i have used my own service with search.luceneSearch() to get documents from multiple sites. To get user related sites, i have used following existing service
var currentUser = person.properties.userName;
var sites = siteService.listUserSites(currentUser, 0);
after read this sites, i could create PATH and send it to search.luceneSearch()
12-07-2016 09:38 AM
Can you please explan what you consider to be "user related site documents"? Are these all documents that the specific user "owns", has created and/or modified or which are somehow "tagged" for the user?
The URL you have used refers to an internal API / operation which may change between Alfresco versions. Please be aware that it is not recommended to use these kinds of APIs for integration with other applications. That is what CMIS or the public ReST API are for.
12-07-2016 11:25 AM
I have five sites ("ABC", "XYZ".......) which contains documents , then user ("omega") is assigned into two of those sites.
when i am logging to USER ('omega") dashboard, i need to show total count of documents which is stored in above two sites, and need to show meta data of rendered document.
12-07-2016 02:36 PM
As far as I know there is no such api directly.
The best way is to customize your own webscript api ,you can implement your requirement by combining site servcie and StatsService .
Another option is try to use doclist data webscript to get all documents of all sites that a user have permissions ,like this
http://localhost:8080/alfresco/s/slingshot/doclib/doclist/documents/node/alfresco/sites/home?limitRe...
and use totalRecords property. but it has poor performance and by default the max number can't be greater than 1000.
12-09-2016 04:41 AM
i have used my own service with search.luceneSearch() to get documents from multiple sites. To get user related sites, i have used following existing service
var currentUser = person.properties.userName;
var sites = siteService.listUserSites(currentUser, 0);
after read this sites, i could create PATH and send it to search.luceneSearch()
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.