List.cshtml 2.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. @using Bowin.Web.Controls.Mvc;
  2. @using EMISOnline.Entities;
  3. @using EMISOnline.Web.Controls;
  4. @{
  5. ViewBag.Title = "List";
  6. }
  7. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  8. @Html.Position()
  9. <div class="p_SearchTitle">
  10. <div style="float: left; margin-left: 10px; font-size: 12px; line-height: 30px;">
  11. 查询条件</div>
  12. </div>
  13. @using (Html.BeginForm("", "", FormMethod.Post, new { id = "fm" }))
  14. {
  15. <div class="search_keyword">
  16. <div class="search_input">
  17. <ul>
  18. <li class="sn" style="padding-left: 5px;">院系代码:</li>
  19. <li class="sv">
  20. @Html.TextBox("CollegeNo")
  21. </li>
  22. <li class="sn" style="padding-left: 5px;">院系名称:</li>
  23. <li class="sv">
  24. @Html.TextBox("CollegeName")
  25. </li>
  26. <li>
  27. @Html.Button(new ButtonOptions() { ID = "btnSearch", Text = "查 询" })
  28. </li>
  29. </ul>
  30. </div>
  31. </div>
  32. }
  33. @* <div class="p_title">
  34. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
  35. 学生信息</div>
  36. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">
  37. </div>
  38. </div>*@
  39. <div class="search_list">
  40. @Html.DataGrid(new DataGridOptions
  41. {
  42. Columns = new List<DataGridColumn>()
  43. {
  44. new CheckBoxFieldColumn{ HeaderText="", FieldName="CollegeID"},
  45. new BoundFieldColumn { FieldName="No", HeaderText="院系代码", Align=AlignStyle.Center },
  46. new BoundFieldColumn { FieldName="Name", HeaderText="院系名称", Align=AlignStyle.Center },
  47. new BoundFieldColumn { FieldName="SimpleName", HeaderText="院系简称", Align=AlignStyle.Center },
  48. new BoundFieldColumn { FieldName="CampusName", HeaderText="所属校区", Align=AlignStyle.Center }
  49. //new BoundFieldColumn { FieldName="CreateTime", HeaderText="建立时间", Align=AlignStyle.Center,Formatter=Formatter.LongDate },
  50. },
  51. IsCheckOnSelect = true,
  52. DataSourceUrl = Url.Content("~/College/List"),
  53. ID = "dgList",
  54. IsPagination = true,
  55. IsShowRowNumbers = true,
  56. IsSingleSelect = false,
  57. IsVerticalExpand = true,
  58. IsAutoHeight = false,
  59. PageSize = 15
  60. })
  61. </div>
  62. </div>
  63. <script type="text/javascript">
  64. $(function () {
  65. $("#btnSearch").click(function () {
  66. loadGrid();
  67. });
  68. });
  69. function loadGrid() {
  70. var queryForm = $("#fm").getFormData();
  71. $("#dgList").cmsXDataTable("load", queryForm);
  72. }
  73. </script>