【发布时间】:2015-03-16 10:18:25
【问题描述】:
我需要使用 required 属性,所以字段不能为空
<input type="text" class="form-control" id="inputName" required>
在剃刀视图中,更具体地说,在本例中
@Html.EditorFor(model => model.exclure.libelle, new { htmlAttributes = new { @class = "form-control" } })
【问题讨论】:
-
你可以在模型中设置
libelle吗?
标签: asp.net asp.net-mvc twitter-bootstrap razor