Blocks are assigned to categories (via IContentBlockDefinition.CategoryIds), and I assume categories without any blocks will not appear in the backoffice. So if you add the id of that new category to one of the block definitions it should work.
Well obviously ContentBlocks does not have a constant that belongs to your new category :-) Those are simply the GUIDs of the builtin categories. Our code cannot contain a compile time constant for a category that was added on runtime. Just put the id (the Guid) there of the category you just created.
New category
Hi,
I am trying to add a new category. I am using a slightly changed version of your example.cs.
So far i have done this, but it dosnt show up in ' Perplex.ContentBlocks.Constants.Categories.' i still only see Headers and Content.
Blocks are assigned to categories (via
IContentBlockDefinition.CategoryIds
), and I assume categories without any blocks will not appear in the backoffice. So if you add the id of that new category to one of the block definitions it should work.Hi,
Yes, but i cant choose my new Category. Must be missing something.
Well obviously ContentBlocks does not have a constant that belongs to your new category :-) Those are simply the GUIDs of the builtin categories. Our code cannot contain a compile time constant for a category that was added on runtime. Just put the id (the Guid) there of the category you just created.
Yes, got it, thanks
is working on a reply...