Hello,

I thought I could use different views. For instance for a page resource, I
could have presentation.html.jsp, read-only.html.jsp and html.jsp. To use
the presentation view it's all good I cn hard code it in my link has it's
the user that will manually request this view. However, for the read-only
view, it depends on the document status. If it's locked or if the user has
no write privileges, this view should be rendered.

I was thinking to implement a filter that would check these two conditions,
and dynamically add the "read-only" selector to the request if the user is
not allowed to edit the resource.

However, I did not find a way to add a selector to a request using the
Sling API, is it possible somehow to update RequestPathInfo? Like the
"replaceSelectors" parameter of the sling:include tag but in Java code. is
that possible?

Thank you for your help!

Kind regards,
Guillaume

On Wed, Apr 27, 2016 at 4:05 PM, Guillaume Lucazeau <[email protected]>
wrote:

> Hello Bertrand,
>
> Unfortunately I cannot, we don't support anonymous access because from the
> user account depends what "documents" he can see and sometimes edit.
>
> On Wed, Apr 27, 2016 at 4:00 PM, Bertrand Delacretaz <
> [email protected]> wrote:
>
>> Hi,
>>
>> On Wed, Apr 27, 2016 at 11:16 AM, Guillaume Lucazeau
>> <[email protected]> wrote:
>> > ...My application is supposed to have a "presentation mode" that
>> disables
>> > editing capabilities on content....
>>
>> Can't you use access control for that?
>>
>> For example give read only access to the anonymous user and read/write
>> to logged in content authors.
>>
>> -Bertrand
>>
>
>

Reply via email to