Base solution for your next web application
Open Closed

Issue with Feature Management #6663


User avatar
0
aggarwal created

Hi,

I am using v6.7 ASP MVC + JQuery.

I am trying to create a feature as per this documentation.

https://aspnetboilerplate.com/Pages/Documents/Feature-Management#other-feature-properties

        context.Create(
            AppFeatures.SampleSelectionFeature,
            defaultValue: "B",
            displayName: L("Sample selection feature"),
            inputType: new ComboboxInputType(
                new StaticLocalizableComboboxItemSource(
                    new LocalizableComboboxItem("A", L("Selection A")),
                    new LocalizableComboboxItem("B", L("Selection B")),
                    new LocalizableComboboxItem("C", L("Selection C"))
                    )
                )
            );

This appears in the list of the available features when setting up and Edition.

However, after setting up the editions; this does not appear in the Upgrade page.

Please advice.

Regards, Vikas


3 Answer(s)
  • User Avatar
    0
    ryancyq created
    Support Team

    Hi, can you share the screenshot of "Test" when editing its features?

    You can refer to the last screen in https://docs.aspnetzero.com/documents/zero/latest/Development-Guide-Core#edition-management

  • User Avatar
    0
    alexanderpilhar created

    Although I have not tried with with ASP MVC + jQuery, this should be what you want:

    context.Create(
        AppFeatures.SampleSelectionFeature,
        defaultValue: "B",
        displayName: L("Sample selection feature"),
        inputType: new ComboboxInputType(
            new StaticLocalizableComboboxItemSource(
                new LocalizableComboboxItem("A", L("Selection A")),
                new LocalizableComboboxItem("B", L("Selection B")),
                new LocalizableComboboxItem("C", L("Selection C"))
            )
        )
    )[FeatureMetadata.CustomFeatureKey] = new FeatureMetadata
    {
        IsVisibleOnPricingTable = true
    };
    
  • User Avatar
    0
    aggarwal created

    Thanks both.

    Totally missed the visibility setting. It works now.