[MAGNOLIA-2554] read-only user on author-system should always be in preview mode Created: 14/Jan/09  Updated: 04/Aug/15  Resolved: 04/Aug/15

Status: Closed
Project: Magnolia
Component/s: admininterface
Affects Version/s: 3.6.3
Fix Version/s: None

Type: Bug Priority: Minor
Reporter: Wolfgang Habicht Assignee: Philipp Bärfuss
Resolution: Outdated Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

any environment


Attachments: Text File AdminOnly_3.java.patch     Text File AdminOnly_4.java.patch     Text File PublicOnly_3.java.patch     Text File PublicOnly_4.java.patch    
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:

 Description   

Precondition:

  • User has read-only access for page /abc
  • User logs in to admin console
  • User opens page /abc

--> the page /abc is displayed and cannot be edited (correct)

Problem:

  • the user is in admin mode / "edit" mode (NOT preview mode)

Correction:

  • a read-only page should always be viewed in preview mode (that is admin mode / preview mode)

Reproduction/Verification:

  • create a user with read-only access for page /abc
  • include the following .jsp-snipplet in a paragraph on that page
     
    <cms:publicOnly><p>public or preview mode</p></cms:publicOnly>
    <cms:adminOnly><p>edit mode</p></cms:adminOnly>
    

Background:

  • the layout of some pages may differ between edit and preview mode; therefore I can use the tags publicOnly and adminOnly
  • a 'design reviewer' should have access to prepared (=not yet published) pages, but not be able to change them himself --> read-only access


 Comments   
Comment by Magnolia International [ 14/Jan/09 ]

Hi Wolfgang. Thanks for the detailed report !
Is this an issue for the publicOnly/adminOnly tags only, or are you saying you also get, for instance, the edit bars, the main bar, etc ?

Comment by Wolfgang Habicht [ 14/Jan/09 ]

Hi Gregory

The edit bars/main bar do not appear, so it is about pubilcOnly and adminOnly only.
(and with no main bar there is also no button to change to preview mode; a workaround would be to add ?mgnlPreview=true to the URL by the user)

Normally (= publicOnly/adminOnly tags are not used) you can just leave the edit/main bars away and the page still looks ok, that's probably why this issue was not reported yet.

Comment by Philippe Marschall [ 26/Jan/09 ]

Attached a patch against 3.6.3 and one against 4.

Comment by Philippe Marschall [ 26/Jan/09 ]

Actually the AdminOnly tag need the inverse. Patch attached.

The boolean logic is not straight forward so it should definitely be checked by somebody else.

Comment by Michael Mühlebach [ 04/Aug/15 ]

We're closing this issue as outdated as it was reported for 4.4.x or earlier versions which are no longer supported. Don't hesitate to reopen or create a new ticket in case this is still relevant and you'll experience it on 4.5.x or later versions.

Generated at Mon Feb 12 03:37:50 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.