Giter Club home page Giter Club logo

Comments (9)

MattisOlsson avatar MattisOlsson commented on July 16, 2024 1

Oh, I see it has been changed. But previously, it wasn't possible to select sub categories (even though they are allowed) if the categories on the first level was always hidden because they were not matching allowed types.

I might add a setting for this in the future, but default will always be like it currently is.

from epicategories.

MattisOlsson avatar MattisOlsson commented on July 16, 2024 1

It turned out to be an easy fix so I added this setting. See updated README for details. I just uploaded version 1.2.11 to the Episerver feed so it will be available in the next few days. Closing this issue now.

from epicategories.

MattisOlsson avatar MattisOlsson commented on July 16, 2024

Hi!

This is weird since nothing regarding this has been changed between these versions. I will take a look at this. Did you also upgrade Episerver in relation to this?

from epicategories.

MattisOlsson avatar MattisOlsson commented on July 16, 2024

Hello again.

Are you sure this has worked in earlier versions? This is the code in the CategoriesAttribute:

https://github.com/Geta/EpiCategories/blob/master/src/EpiCategories/DataAnnotations/CategoriesAttribute.cs#L36

However, I will add support for the AllowedTypesAttribute and create a new release. I'll let you know when it's published.

from epicategories.

boat-gaurav-bhatia avatar boat-gaurav-bhatia commented on July 16, 2024

@MattisOlsson Yes, it worked with the earlier version.
We upgraded the following packages:
Episerver.CMS from 11.12.0 to 11.15.0
Episerver.CMS.UI from 11.23.0 to 11.24.0

from epicategories.

MattisOlsson avatar MattisOlsson commented on July 16, 2024

I can't reproduce this. Just to make things clear: The category selector shows all category types, but only the AllowedTypes are selectable (with a checkbox to left of the label), provided that the "IsSelectable" property is set to true. This is the way default Episerver selectors work as well. They show everything, but you can only select the allowed types. Because it might be possible to have an allowed category nested somewhere.

I don't see any checkbox at all in your screenshots, are you sure you can select any of them? :)

I will investigate if I can easily add a css class to those nodes so they are a bit grayed out (disabled).

from epicategories.

boat-gaurav-bhatia avatar boat-gaurav-bhatia commented on July 16, 2024

The category selector shows all category types and provides checkbox only for the allowed types, not for the other types.

But for the better user experience, Is it possible to show only allowed category types & hide the other categories from the category selection popup like in version 1.2.6?
Instead of adding a class to grey out, can you add Hide class to hide the disabled categories from the selection?

from epicategories.

MattisOlsson avatar MattisOlsson commented on July 16, 2024

I can't imagine how it could ever have worked like you say in 1.2.6, maybe because of differences in Episerver perhaps, since this has not been changed in the package.

Unfortunately, I don't want to hide disabled categories because there might be children to those categories which are actually allowed.

from epicategories.

boat-gaurav-bhatia avatar boat-gaurav-bhatia commented on July 16, 2024

Wow! that was quick. Thanks for the fix @MattisOlsson

from epicategories.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.