List.cshtml 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. @using Bowin.Web.Controls.Mvc;
  2. @using EMIS.Web.Controls;
  3. @{
  4. ViewBag.Title = "List";
  5. //上课类型
  6. ComboGridOptions cgopTeachType = new ComboGridOptions
  7. {
  8. TextField = "ClassName",
  9. ValueField = "ClassGroupingID",
  10. ID = "TeachTypeDropdown",
  11. Name = "TeachTypeDropdown",
  12. OnSelect = "reload",
  13. GridOptions = new DataGridOptions
  14. {
  15. Columns = new List<DataGridColumn>()
  16. {
  17. new BoundFieldColumn { FieldName="ClassName", HeaderText="上课类型", Align=AlignStyle.Center, Width=0.12 }
  18. },
  19. IsCheckOnSelect = true,
  20. DataSourceUrl = Url.Content("~/TeachType/List"),
  21. IsPagination = true,
  22. IsShowRowNumbers = true,
  23. IsSingleSelect = false,
  24. }
  25. };
  26. }
  27. @section scripts{
  28. <script src="~/Scripts/Business/CultureplanManage/Coursematerial.js" type="text/javascript"></script>
  29. <script type="text/javascript">
  30. var nonSelect = "@DropdownList.SELECT_ALL";
  31. </script>
  32. }
  33. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  34. @Html.Position()
  35. <div class="p_SearchTitle">
  36. <div style="float: left; margin-left: 10px; font-size: 12px; line-height: 30px;">
  37. 查询条件</div>
  38. </div>
  39. <form id="formQuery" method="post" action="@Url.Content("~/Coursematerial/Excel")">
  40. @Html.PositionCondition()
  41. <div class="search_keyword">
  42. <div class="search_input">
  43. <ul>
  44. <li class="sn" style="padding-left: 5px;">课程级别:</li>
  45. <li class="sv">
  46. @Html.DictionaryComboGrid(EMIS.ViewModel.DictionaryItem.CF_CourseLevel, DropdownListBindType.SelectAll,
  47. new ComboGridOptions
  48. {
  49. ID = "DictionaryCourseLevel",
  50. Name = "DictionaryCourseLevel",
  51. OnSelect = "reload"
  52. }, new Dictionary<string, string> { { "data-condition", "dgCoursematerialList" } })
  53. </li>
  54. <li class="sn" style="padding-left: 5px;">课程科类:</li>
  55. <li class="sv">
  56. @Html.DictionaryComboGrid(EMIS.ViewModel.DictionaryItem.CF_CourseScience, DropdownListBindType.SelectAll,
  57. new ComboGridOptions
  58. {
  59. ID = "DictionaryCourseScience",
  60. Name = "DictionaryCourseScience",
  61. OnSelect = "reload"
  62. }, new Dictionary<string, string> { { "data-condition", "dgCoursematerialList" } })
  63. </li>
  64. <li class="sn" style="padding-left: 5px;color:red;">上课类型:</li>
  65. <li class="sv">
  66. @Html.ComboGrid(cgopTeachType, new Dictionary<string, string> { { "data-condition", "dgCoursematerialList" } })
  67. </li>
  68. <li class="sn" style="padding-left: 5px;color:red;">是否启用:</li>
  69. <li class="sv">
  70. @Html.DictionaryDropDownList(EMIS.ViewModel.DictionaryItem.CF_GeneralPurpose, new DropdownListOptions
  71. {
  72. ID = "DictionaryIsEnable",
  73. Name = "DictionaryIsEnable",
  74. BindType = DropdownListBindType.SelectAll,
  75. //SelectedValue = (int)EMIS.ViewModel.CF_GeneralPurpose.IsYes,
  76. OnSelect = "reload"
  77. }, new Dictionary<string, string> { { "data-condition", "dgCoursematerialList" } })
  78. </li>
  79. </ul>
  80. </div>
  81. </div>
  82. </form>
  83. <div class="p_title">
  84. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
  85. 课程信息列表</div>
  86. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("List")</div>
  87. </div>
  88. @Html.PositionBatchModify()
  89. <div class="search_list">
  90. @Html.DataGrid(new DataGridOptions
  91. {
  92. Columns = new List<DataGridColumn>()
  93. {
  94. new CheckBoxFieldColumn{ HeaderText="", FieldName="CoursematerialID" },
  95. new LinkButtonColumn { FieldName="CourseCode", HeaderText="课程代码", Align=AlignStyle.Center, Handle="edit", Width=0.06 },
  96. new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Align=AlignStyle.Center, Width=0.1, OverflowLength=15 },
  97. new BoundFieldColumn { FieldName="Abbreviation", HeaderText="课程简称", Align=AlignStyle.Center, Width=0.08, OverflowLength=10 },
  98. new BoundFieldColumn { FieldName="CourseLevelName", HeaderText="课程级别", Align=AlignStyle.Center, OrderFieldName="CourseLevelID", Width=0.04 },
  99. new BoundFieldColumn { FieldName="CourseScienceName", HeaderText="课程科类", Align=AlignStyle.Center, OrderFieldName="CourseScienceID", Width=0.04 },
  100. new LinkButtonColumn { FieldName="ClassName", HeaderText="上课类型", Align=AlignStyle.Center, Handle="editClassGrouping", Width=0.04 },
  101. new BoundFieldColumn { FieldName="IsEnableName", HeaderText="是否启用", Align=AlignStyle.Center, OrderFieldName="IsEnable", Width=0.04, CustomFormatFun="SetRedColumn" },
  102. new BoundFieldColumn { FieldName="Remark", HeaderText="备注", Align=AlignStyle.Center, Width=0.03, OverflowLength=5 }
  103. },
  104. CustomerRowStyleFun = "SetRedGrid",
  105. IsCheckOnSelect = true,
  106. DataSourceUrl = Url.Content("~/Coursematerial/List"),
  107. ID = "dgCoursematerialList",
  108. IsPagination = true,
  109. IsShowRowNumbers = true,
  110. IsSingleSelect = false
  111. })
  112. </div>
  113. </div>