123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101 |
- @using EMIS.Web.Controls;
- @using Bowin.Web.Controls.Mvc;
- @{
- ViewBag.Title = "PlanStudentList";
- Guid? specialtyPlanID = new Guid(Request["specialtyPlanID"]);
- //班级信息
- ComboGridOptions cgopClassmajor = new ComboGridOptions
- {
- TextField = "Name",
- ValueField = "ClassmajorID",
- Name = "ClassmajorDropdown",
- ID = "ClassmajorDropdown",
- OnSelect = "reload",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- //new LinkButtonColumn { FieldName="No", HeaderText="班级编号", Align=AlignStyle.Center, Width=0.2 },
- new BoundFieldColumn { FieldName="Name", HeaderText="班级名称", Align=AlignStyle.Center, Width=0.3 }
- },
- PageSize = 5,
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/Classmajor/List"),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- }
- };
- }
- @section scripts{
- <script type="text/javascript">
- var nonSelect = "@DropdownList.SELECT_ALL";
- //刷新
- function reload() {
- $("#dgSpecialtyPlanStudentList").cmsXDataTable("load", $.getDataGridParams("dgSpecialtyPlanStudentList"));
- }
- //设置列颜色为红色
- function SetRedColumn(index, row, value) {
- return " <span style=\"color: red;\">" + value + "</span>";
- }
- //Excel导出
- function SpecialtyPlanStudent_Export() {
- $("#formQuery").submit();
- }
- </script>
- }
- <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
- <form id="formQuery" method="post" action="@Url.Content("~/SpecialtyPlan/PlanStudentListExcel?specialtyPlanID=" + specialtyPlanID)">
- @Html.PositionCondition("SpecialtyPlanStudent")
- <div class="search_keyword">
- <div class="search_input">
- <ul>
- <li class="sn" style="padding-left: 5px;">班级名称:</li>
- <li class="sv">
- @Html.ComboGrid(cgopClassmajor, new Dictionary<string, string> { { "data-condition", "dgSpecialtyPlanStudentList" } })
- </li>
- <li class="sn" style="padding-left: 5px;color:red;">在校状态:</li>
- <li class="sv">
- @Html.DictionaryDropDownList(EMIS.ViewModel.DictionaryItem.CF_INOrOutSchoolStatus, new DropdownListOptions
- {
- ID = "DictionaryInschoolStatus",
- Name = "DictionaryInschoolStatus",
- BindType = DropdownListBindType.SelectAll,
- //SelectedValue = (int)EMIS.ViewModel.CF_INOrOutSchoolStatus.Yes,
- OnSelect = "reload"
- }, new Dictionary<string, string> { { "data-condition", "dgSpecialtyPlanStudentList" } })
- </li>
- </ul>
- </div>
- </div>
- <div class="p_title">
- <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;"></div>
- <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("PlanStudent")</div>
- </div>
- </form>
- <div class="search_list">
- @Html.DataGrid(new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new CheckBoxFieldColumn{ HeaderText="", FieldName="UserID" },
- new BoundFieldColumn { FieldName="LoginID", HeaderText="学号", Align=AlignStyle.Center, Width=0.08 },
- new BoundFieldColumn { FieldName="UserName", HeaderText="姓名", Align=AlignStyle.Center, Width=0.04 },
- new BoundFieldColumn { FieldName="SexName", HeaderText="性别", Align=AlignStyle.Center, OrderFieldName="Sex", Width=0.02 },
- new BoundFieldColumn { FieldName="SchoolyearID", HeaderText="年级", Align=AlignStyle.Center, Width=0.03, CustomFormatFun="SetRedColumn" },
- //new BoundFieldColumn { FieldName="GrademajorName", HeaderText="年级专业名称", Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="ClassmajorName", HeaderText="班级名称", Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="InSchoolStatusName", HeaderText="在校状态", Align=AlignStyle.Center, OrderFieldName="InSchoolStatusID", Width=0.04, CustomFormatFun="SetRedColumn" },
- new BoundFieldColumn { FieldName="StudentStatusName", HeaderText="学籍状态", Align=AlignStyle.Center, OrderFieldName="StudentStatus", Width=0.04 }
- },
- IsPostBack = true,
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/SpecialtyPlan/PlanStudentList?specialtyPlanID=" + specialtyPlanID),
- ID = "dgSpecialtyPlanStudentList",
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- })
- </div>
- </div>
|