@Html.RadioButtonFor(modelItem => item.CheckerApproved, true)
@Html.LabelFor(modelItem => item.CheckerApproved, "Accepted")
@Html.RadioButtonFor(modelItem => item.CheckerApproved, false)
@Html.LabelFor(modelItem => item.CheckerApproved, "Rejected")
What I’m wanting is for some way to make these disabled or readonly when the user isn’t Authenticated.
ie. Enabled when:
HttpContext.Current.User.Identity.IsAuthenticated
Is there an easy way to do this? Would you put them on some sort of panel? Not sure for MVC?
Would you set there enabledability individually for each line?
A more than excellent candidate for a custom helper:
and in your view simply consume the fruits of your labour: