I have a two sets of Enums to generate list of radio button list. 1) To generate labels of available features and 2) To generate fix set of values as radio buttons. How to bind such radio button values to model in order to post them to controller? My UI would be something like below:
Available Features:
PublicAPI
Enabled Disabled
PrivateAPI
Enabled Disabled
Authentication
Enabled Disabled
Below is my model:
public enum Features
{
PublicAPI = 1,
PrivateAPI,
Authentication
}
public enum FeatureState
{
Enabled,
Disabled,
}
public class MyModel
{
public Dictionary<Features, FeatureState> FeatureSettings{ get; set; }
}