@model EMIS.ViewModel.DepartmentView @using EMIS.Web.Controls; @using Bowin.Web.Controls.Mvc; @{ ViewBag.Title = "Edit"; //院系所 ComboGridOptions cgopCollege = new ComboGridOptions { TextField = "Name", ValueField = "CollegeID", GridOptions = new DataGridOptions { Columns = new List() { new LinkButtonColumn { FieldName="No", HeaderText=@EMIS.Utility.RSL.Get("CollegeCode"), Align=AlignStyle.Center, Width=0.1 }, new BoundFieldColumn { FieldName="Name", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Align=AlignStyle.Center, Width=0.3 }, new BoundFieldColumn { FieldName="CampusName", HeaderText=@EMIS.Utility.RSL.Get("CampusName"), Align=AlignStyle.Center, Width=0.3 } }, PageSize = 5, IsCheckOnSelect = true, DataSourceUrl = Url.Content("~/College/ListOnlyCollege"), IsPagination = true, IsShowRowNumbers = true, IsSingleSelect = false } }; ComboGridOptions cgopDirector = new ComboGridOptions { TextField = "Name", ValueField = "UserID", GridOptions = new DataGridOptions { Columns = new List() { new LinkButtonColumn { FieldName="StaffCode", HeaderText="教职工号", Align=AlignStyle.Center ,Width=0.1 }, new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Align=AlignStyle.Center ,Width=0.1 }, new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Align=AlignStyle.Center ,Width=0.2 } }, PageSize = 5, IsCheckOnSelect = true, DataSourceUrl = Url.Content("~/Staff/List"), IsPagination = true, IsShowRowNumbers = true, IsSingleSelect = false } }; ComboGridOptions cgopDeputy = new ComboGridOptions { TextField = "Name", ValueField = "UserID", GridOptions = new DataGridOptions { Columns = new List() { new LinkButtonColumn { FieldName="StaffCode", HeaderText="教职工号", Align=AlignStyle.Center ,Width=0.1 }, new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Align=AlignStyle.Center ,Width=0.1 }, new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Align=AlignStyle.Center ,Width=0.2 } }, PageSize = 5, IsCheckOnSelect = true, DataSourceUrl = Url.Content("~/Staff/List"), IsPagination = true, IsShowRowNumbers = true, IsSingleSelect = false } }; } @section scripts{ }
@using (Ajax.BeginForm(new AjaxOptions { OnSuccess = "EMISFunction.FormSuccess", OnBegin = "EMISFunction.FormSubmit", OnComplete = "EMISFunction.FormComplete" })) {
@if (ViewBag.Type != "1")//控制列表进入、屏蔽按钮权限 { @Html.ContextMenuBar("Edit") }
@Html.HiddenFor(x => x.DepartmentID)
@Html.LabelFor(x => x.No): @Html.TextBoxFor(x => x.No) @Html.LabelFor(x => x.Name): @Html.TextBoxFor(x => x.Name)
@Html.LabelFor(x => x.SimpleName): @Html.TextBoxFor(x => x.SimpleName) @Html.LabelFor(x => x.EnglishName): @Html.TextBoxFor(x => x.EnglishName)
@Html.LabelFor(x => x.CollegeName): @Html.ComboGridFor(x => x.CollegeID, cgopCollege) @Html.LabelFor(x => x.FoundDate): @Html.TextBoxFor(x => x.FoundDate, new TextBoxOptions() { TextBoxType = TextBoxType.Date })
@Html.LabelFor(x => x.DirectorName): @Html.ComboGridFor(x => x.DirectorID, cgopDirector) @Html.LabelFor(x => x.DeputyDirectorName): @Html.ComboGridFor(x => x.DeputyDirectorID, cgopDeputy)
@Html.LabelFor(x => x.Remark): @Html.TextAreaFor(x => x.Remark, new Dictionary { { "style", "width: 90%;min-height: 60px" } })
}