List.cshtml 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  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("CollegeName")
  21. </li>
  22. <li class="sn" style="padding-left: 5px;">专业:</li>
  23. <li class="sv">
  24. @Html.TextBox("StandardName")
  25. </li>
  26. <li class="sn" style="padding-left: 5px;">培养层次:</li>
  27. <li class="sv">
  28. @Html.DropdownList(new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, ItemSourceUrl = Url.Content("~/Common/DictionaryDropDown?dictionaryCode=CF_Education"), ID = "EducationID", Name = "EducationID", OnSelect = "loadGrid" }, new Dictionary<string, string> { { "data-condition", "dgList" } })
  29. </li>
  30. <li class="sn" style="padding-left: 5px;">学习形式:</li>
  31. <li class="sv">
  32. @Html.DropdownList(new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, ItemSourceUrl = Url.Content("~/Common/DictionaryDropDown?dictionaryCode=CF_Learningform"), ID = "LearningformID", Name = "LearningformID", OnSelect = "loadGrid" }, new Dictionary<string, string> { { "data-condition", "dgList" } })
  33. </li>
  34. <li>
  35. @Html.Button(new ButtonOptions() { ID = "btnSearch", Text = "查 询" })
  36. </li>
  37. </ul>
  38. </div>
  39. </div>
  40. }
  41. <div class="search_list">
  42. @Html.DataGrid(new DataGridOptions
  43. {
  44. Columns = new List<DataGridColumn>()
  45. {
  46. new CheckBoxFieldColumn{ HeaderText="", FieldName="FacultymajorID"},
  47. new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Align=AlignStyle.Center},
  48. new BoundFieldColumn { FieldName="LearnSystem", HeaderText="学制", Align=AlignStyle.Center },
  49. new BoundFieldColumn { FieldName="EducationName", HeaderText="培养层次", Align=AlignStyle.Center},
  50. new BoundFieldColumn { FieldName="LearningformName", HeaderText="学习形式", Align=AlignStyle.Center , },
  51. new BoundFieldColumn { FieldName="CollegeName", HeaderText="院系所", Align=AlignStyle.Center},
  52. },
  53. IsCheckOnSelect = true,
  54. DataSourceUrl = Url.Content("~/Grademajor/List"),
  55. ID = "dgList",
  56. IsPagination = true,
  57. IsShowRowNumbers = true,
  58. IsSingleSelect = false,
  59. IsVerticalExpand = true,
  60. IsAutoHeight = false,
  61. PageSize = 15
  62. })
  63. </div>
  64. </div>
  65. <script type="text/javascript">
  66. $(function () {
  67. $("#btnSearch").click(function () {
  68. loadGrid();
  69. });
  70. });
  71. function loadGrid() {
  72. var queryForm = $("#fm").getFormData();
  73. $("#dgList").cmsXDataTable("load", queryForm);
  74. }
  75. </script>