@model EnVisage.Models.WorkWeekModel
@{
ViewBag.Title = Model != null ? "Edit " + Model.Name : "Add Work Week";
}
@using (Ajax.BeginForm("Edit", "WorkWeek", new AjaxOptions { HttpMethod = "Post", OnBegin = "blockUI", OnSuccess = "onSuccess", OnFailure = "onFailure(xhr)", OnComplete = "unblockUI" }, new { id = "editWWForm" }))
{
@Html.AntiForgeryToken()
@Html.HiddenFor(t => t.Id)
@Html.HiddenFor(t => t.IsSystem)
@Html.HiddenFor(t => t.IsDefault)
Reminder: This Work Week will be set as default for all new created resources
@Html.LabelFor(model => model.Name, new { @class = "control-label" })
@Html.TextBoxFor(model => model.Name, new { @class = "form-control" })
@Html.ValidationMessageFor(model => model.Name)
@Html.CheckBoxFor(model => model.Monday)
@Html.LabelFor(model => model.Monday, new { @class = "control-label" })
@Html.CheckBoxFor(model => model.Tuesday)
@Html.LabelFor(model => model.Tuesday, new { @class = "control-label" })
@Html.CheckBoxFor(model => model.Wednesday)
@Html.LabelFor(model => model.Wednesday, new { @class = "control-label" })
@Html.CheckBoxFor(model => model.Thursday)
@Html.LabelFor(model => model.Thursday, new { @class = "control-label" })
@Html.CheckBoxFor(model => model.Friday)
@Html.LabelFor(model => model.Friday, new { @class = "control-label" })
@Html.CheckBoxFor(model => model.Saturday)
@Html.LabelFor(model => model.Saturday, new { @class = "control-label" })
@Html.CheckBoxFor(model => model.Sunday)
@Html.LabelFor(model => model.Sunday, new { @class = "control-label" })
@Html.ValidationSummary(false, "The Work Week could not be saved due to the following errors:")
}