Last active
August 29, 2015 14:03
-
-
Save ChuckBryan/7ac6adb52a9b2b1d3558 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*Note: if you don't make the model Boolean, you will get errors on Create Actions where you might not initially new up a model.*/ | |
@model Boolean? | |
<label> | |
@Html.CheckBox("", Model.HasValue && Model.Value) @ViewData.ModelMetadata.DisplayName | |
</label> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is my implementation of a boolean editor using the framework that Matt Honeycutt set up for FailTracker that was demonstrated in his Pluralsight Video.