How to find which user locked a page? | Community
Skip to main content
Level 2
August 24, 2021
Solved

How to find which user locked a page?

  • August 24, 2021
  • 2 replies
  • 1470 views

Hi everyone,

 

I would like to know how to find which user has locked pages in Touch UI (in AEM versions: 6.5 / Cloud Service) using the Query Builder Debugger ( http://localhost:4502/libs/cq/search/content/querydebug.html ).

 

For example, I know that we can find pages that are locked using a query like below:

 

path=/content/sample
property=jcr:content/jcr:lockIsDeep
property.value=true

 

In a similar way, is it possible to get a list of locked pages WITH who locked them?

I managed to find that the property "jcr:lockOwner" has the information.

I tried below, but it seems not working:

 

path=/content/sample
property=jcr:content/jcr:lockOwner

 

Here, if we specify the user name, we can get a limited result:

 

path=/content/sample
property=jcr:content/jcr:lockOwner

property.value=admin

 

In above case, we already know who locked the pages.

Is there a way to thoroughly find multiple users?


Any idea how to achieve this?
Thanks in advance 🙂

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Kishore_Kumar_

Hi @akaria ,

 

To check if jcr:lockOwner property exists in your pages, we can use below query and then we can get the value of it.

 

path=/content/sample
property=jcr:content/jcr:lockOwner
property.operation=exists
p.limit=-1

2 replies

Asutosh_Jena_
Community Advisor
Community Advisor
August 24, 2021

Hi @akaria 

 

You can use the below query to find the list of pages which are locked.

path=/content/we-retail
property=jcr:content/jcr:lockIsDeep
property.value=true

 

Once you find the pages which are locked, you can look for "jcr:lockOwner" property to identify who locked the page.

 

You can use the QueryBuilder API to find get the list of pages and then loop through each of the page with "jcr:lockOwner" to find for multiple pages.

 

Thanks!

Kishore_Kumar_
Kishore_Kumar_Accepted solution
Level 9
August 24, 2021

Hi @akaria ,

 

To check if jcr:lockOwner property exists in your pages, we can use below query and then we can get the value of it.

 

path=/content/sample
property=jcr:content/jcr:lockOwner
property.operation=exists
p.limit=-1