AI OnAI Off
Im interested to know this also, I have the following and it results in a simliar error:
[Required] [DojoWidget( WidgetType = "dijit.form.FilteringSelect", SelectionFactoryType = typeof(EnumSelectionFactory<VisitorRegions>))] public VisitorRegions SelectedVisitorRegion { get; set; }
Hi Tobias,
I've made a little progress on this, I can get my drop down to appear now, doesnt seem to be pulling values but thats the next thing for me to fix. Basically, in your selection factory, make sure your using the ISelectionFactory from the visitor groups namespace, not the one in ObjectEditing namespace. That what my problem was.
Cheers,
Adam
Hello! I'm implementing a criterion that should determine if a logged in user is of a specific type. Instances of this criterion should then be created as visitor groups. The criterion should include a dropdown that shows the different types a user can belong to. For example if I create a visitor group with the type "Admin", then the pages that has this visitor group will only be viewable by a user that is Admin. I have two problems with this.
1. When I try to create a visitor group with this criterion I get this exception:
"Cannot create an abstract class. MissingMethodException. Unable to load /EPiServer/Cms/VisitorGroups/CriteriaUI status: 500"
I've chekced some tutorials and, this is how I've implemented it, in my settings file, that inherits from CriterionModelBase:
2. If I just create the type property as a string instead and try it out and add my visitor group to a page, IsMatch runs on every page. This seems weird, I believe it should only run on those pages to which I have added the visitor group? Because if I create two visitor groups one "Admin" and one "Normal" based on this criteria, and add those two to two different pages, both visitor groups' IsMatch method is executed when entering the page with the Admin visitor group, which means that the Normal user will get access to an Admin page.
Help appreciated!
Regards, Tobias