@
using (Ajax.BeginForm(ajaxopts))
{
@
Html.LabelFor(model => model.comment.FileId, htmlAttributes: new { @
class = "control-label col-md-2" })
<input class="form-control text-box single-line" data-val="true" data-val-number="The field FileId must be a number." data-val-required="FileId 字段是必需的。" id="FileId" name="FileId" type="number"
value="@ViewBag.FileId" />
@
Html.LabelFor(model => model.comment.CreateDate, htmlAttributes: new { @
class = "control-label col-md-2" })
<input class="form-control text-box single-line" data-val="true" data-val-date="The field CreateDate must be a date." data-val-required="CreateDate 字段是必需的。" id="CreateDate" name="CreateDate" type="datetime"
value="@DateTime.Now.ToString()" />
@
Html.LabelFor(model => model.comment.UserId, htmlAttributes: new { @
class = "control-label col-md-2" })
<input class="form-control text-box single-line" id="UserId" name="UserId" type="text"
value="@User.Identity.Name.ToString()" />
@
Html.Validati onMessageFor(model => model.comment.UserId, "", new { @
class = "text-danger" })
@
Html.LabelFor(model => model.comment.review, htmlAttributes: new { @
class = "control-label col-md-2" })
@
Html.EditorFor(model => model.comment.review, new { htmlAttributes = new { @
class = "form-control" } })
<input type="submit" value="Create" class="btn btn-default" />
}
</div>
<div id="loading" style="display:none">
<p>正在提交服务器。。。</p>
</div>