Developer forum

Forum » Development » Override paragraph rendering

Override paragraph rendering

Martin Grønbekk Moen
Martin Grønbekk Moen
Reply

Im using impersonation, and have a few issues regarding showing correct paragraphs to users.
Consider this scenario.

Im logged in as User A which is representing User B.
Paragraph A is denied for User A but allowed for User B.

When im representing User B as User A im not allowed to see Paragraph A, since im really logged in as User A.
But I would like to see Paragraph A since im currently representing User B which is allowed to see Paragraph A.

I have not found any good solution to this, but Im thinking if I can override the security OnBeforeRender on the paragraph I should be able to solve the issue.

Am I complicating things, are there better solutions to this? Or can someone point me in the direction of how to override the security OnBeforeRender?


Replies

 
Nicolai Pedersen
Reply

Hi Martin

Just change the impersonation method in the control panel, users section in MC/Settings.

See dump.

BR Nicolai

Capture.PNG
 
Martin Grønbekk Moen
Martin Grønbekk Moen
Reply

Well I tried that but it did not work as I expected. Anyway, I can keep testing.
BUT! What if I like to use the permissions based on User A for some paragraphs and User B on other paragraphs, then I need to do some hacking.
Is it possible to override the security OnBeforeRender on the paragraph?

 
Nicolai Pedersen
Reply
This post has been marked as an answer

Hi Martin

No, DW does not support that. That have to be your own custom implementation.

BR Nicolai

Votes for this answer: 1

 

You must be logged in to post in the forum