@using EnVisage.Code @model EnVisage.Models.FiscalCalendarModel @{ ViewBag.Title = Model != null ? "Edit Fiscal Calendar" : "Add Fiscal Calendar"; } @section Scripts { @if (Model != null) { } }
@if (Model != null) { } @using (Html.BeginForm("Edit", "Calendar", FormMethod.Post, new { @class = "panel form-horizontal" })) { @Html.HiddenFor(t=>t.StartDateSettingId) @Html.HiddenFor(t=>t.TypeSettingId) @Html.HiddenFor(t=>t.WeekEndingSettingId) @Html.HiddenFor(t=>t.WeekEndingTypeSettingId) @Html.AntiForgeryToken()
@Html.LabelFor(model => model.Type, new { @class = "col-sm-2 control-label" })
@Html.DropDownListFor(model => model.Type, Utils.GetFiscalCalendarTypes(), new { @class = "form-control" }) @Html.ValidationMessageFor(model => model.Type)
@Html.LabelFor(model => model.CurrentYearStartDate, new { @class = "col-sm-2 control-label" })
@Html.EditorFor(t => t.CurrentYearStartDate) @Html.ValidationMessageFor(model => model.CurrentYearStartDate)
@Html.LabelFor(model => model.WeekEnding, new { @class = "col-sm-2 control-label" })
@Html.DropDownListFor(model => model.WeekEnding, Utils.GetWeekDays(), new { @class = "form-control" }) @Html.ValidationMessageFor(model => model.WeekEnding)
@Html.LabelFor(model => model.WeekEndingType, new { @class = "col-sm-2 control-label" })
@Html.DropDownListFor(model => model.WeekEndingType, Utils.GetWeekEndingTypes(), new { @class = "form-control" }) @Html.ValidationMessageFor(model => model.WeekEndingType)
@Html.LabelFor(model => model.Adjustingperiod, new { @class = "col-sm-2 control-label" })
@Html.CheckBoxFor(model => model.Adjustingperiod)
@Html.ValidationSummary(false, "The fiscal calendar could not be saved due to the following errors:")
}