1

Since the latest 2sxc version 10.20+ the property Permissions.UserMayEditContent isn't available anymore. Error message: The name 'Permissions' does not exist in the current context...

I have implemented the use of latest features of 2sxc 10.20+ by entering @inherits ToSic.Sxc.Dnn.RazorComponent as first line into the razor file as explained here.

The docs.2sxc.org Spec still contains an example here. How should this be implemented with the latest 2sxc DNN Module?

Nicolo
  • 215
  • 2
  • 8

1 Answers1

4

The new property is Edit.Enabled. Found it after long searching as a comment within the 2sxc repository and then within the docs here.

Nicolo
  • 215
  • 2
  • 8
  • thx for finding the answer and sorry about the breaking change. Edit.Enabled has been around for about 2 years and we didn't think people would be using the old command. sorry :(. best mark this question as answered. – iJungleBoy Dec 16 '19 at 18:04
  • The example within the documentation [here](https://docs.2sxc.org/specs/js/commands.html) still uses `UserMayEditContent`, same your apps like _app-blog_. That made it tricky :) Thanks @iJungleBoy for the very useful new documentation. – Nicolo Dec 17 '19 at 04:37
  • thanks! just fixed it. We'll also make sure that the old command still works if you're working in the "old" mode which doesn't use @inherits... RazorComponent – iJungleBoy Dec 18 '19 at 09:36