List.cshtml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224
  1. @using Bowin.Web.Controls.Mvc;
  2. @using EMIS.Web.Controls;
  3. @{
  4. ViewBag.Title = "List";
  5. //校区
  6. ComboGridOptions cgopCampus = new ComboGridOptions
  7. {
  8. TextField = "Name",
  9. ValueField = "CampusID",
  10. ID = "CampusDropdown",
  11. Name = "CampusDropdown",
  12. OnSelect = "queryCampus",
  13. GridOptions = new DataGridOptions
  14. {
  15. Columns = new List<DataGridColumn>()
  16. {
  17. //new LinkButtonColumn { FieldName="No", HeaderText=@EMIS.Utility.RSL.Get("CampusCode"), Align=AlignStyle.Center, Width=0.1 },
  18. new BoundFieldColumn { FieldName="Name", HeaderText=@EMIS.Utility.RSL.Get("CampusName"), Align=AlignStyle.Center, Width=0.12 }
  19. },
  20. IsCheckOnSelect = true,
  21. DataSourceUrl = Url.Content("~/Campus/List"),
  22. IsPagination = true,
  23. IsShowRowNumbers = true,
  24. IsSingleSelect = false,
  25. }
  26. };
  27. ////院系所
  28. //ComboGridOptions cgopCollege = new ComboGridOptions
  29. //{
  30. // TextField = "Name",
  31. // ValueField = "CollegeID",
  32. // ID = "CollegeDropdown",
  33. // Name = "CollegeDropdown",
  34. // OnSelect = "reload",
  35. // GridOptions = new DataGridOptions
  36. // {
  37. // Columns = new List<DataGridColumn>()
  38. // {
  39. // //new LinkButtonColumn { FieldName="No", HeaderText=@EMIS.Utility.RSL.Get("CollegeCode"), Align=AlignStyle.Center, Width=0.1 },
  40. // new BoundFieldColumn { FieldName="Name", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Align=AlignStyle.Center, Width=0.2 }
  41. // },
  42. // IsCheckOnSelect = true,
  43. // //DataSourceUrl = Url.Content("~/College/ListOnlyCollege"),
  44. // DataSourceUrl = Url.Content("~/College/ListWithoutRange"),
  45. // IsPagination = true,
  46. // IsShowRowNumbers = true,
  47. // IsSingleSelect = false,
  48. // }
  49. //};
  50. //建筑信息
  51. ComboGridOptions cgopBuildings = new ComboGridOptions
  52. {
  53. TextField = "Name",
  54. ValueField = "BuildingsInfoID",
  55. ID = "BuildingsDropdown",
  56. Name = "BuildingsDropdown",
  57. OnSelect = "reload",
  58. GridOptions = new DataGridOptions
  59. {
  60. Columns = new List<DataGridColumn>()
  61. {
  62. new LinkButtonColumn { FieldName="Code", HeaderText="建筑编号", Align=AlignStyle.Center, Width=0.1 },
  63. new BoundFieldColumn { FieldName="Name", HeaderText="建筑名称", Align=AlignStyle.Center, Width=0.1 }
  64. },
  65. IsCheckOnSelect = true,
  66. DataSourceUrl = Url.Content("~/Buildings/list"),
  67. IsPagination = true,
  68. IsShowRowNumbers = true,
  69. IsSingleSelect = false
  70. }
  71. };
  72. //教室信息
  73. ComboGridOptions cgopClassroomName = new ComboGridOptions
  74. {
  75. TextField = "Name",
  76. ValueField = "Name",
  77. ID = "ClassroomNameDropdown",
  78. Name = "ClassroomNameDropdown",
  79. OnSelect = "reload",
  80. GridOptions = new DataGridOptions
  81. {
  82. Columns = new List<DataGridColumn>()
  83. {
  84. //new LinkButtonColumn { FieldName="Code", HeaderText="教室编号", Align=AlignStyle.Center, Width=0.1 },
  85. new BoundFieldColumn { FieldName="Name", HeaderText="教室名称", Align=AlignStyle.Center, Width=0.1 }
  86. },
  87. IsCheckOnSelect = true,
  88. DataSourceUrl = Url.Content("~/Classroom/List"),
  89. IsPagination = true,
  90. IsShowRowNumbers = true,
  91. IsSingleSelect = false,
  92. }
  93. };
  94. }
  95. @section scripts{
  96. <script src="~/Scripts/Business/SchedulingManage/SchedulingSettings/ClassroomReserve.js" type="text/javascript"></script>
  97. <script type="text/javascript">
  98. var nonSelect = "@DropdownList.SELECT_ALL";
  99. </script>
  100. }
  101. <div class="easyui-panel" data-options="border:false,fit:true" style="position:relative;">
  102. @Html.Position()
  103. <div class="p_SearchTitle">
  104. <div style="float: left; margin-left: 10px; font-size: 12px; line-height: 30px;">
  105. 查询条件</div>
  106. </div>
  107. <form id="formQuery" method="post" action="@Url.Content("~/ClassroomReserve/Excel")">
  108. @Html.PositionCondition()
  109. <div class="search_keyword">
  110. <div class="search_input">
  111. <ul>
  112. <li class="sn" style="padding-left: 5px;">@EMIS.Utility.RSL.Get("Campus"):</li>
  113. <li class="sv">
  114. @Html.ComboGrid(cgopCampus, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  115. </li>
  116. <li class="sn" style="padding-left: 5px;">所在建筑:</li>
  117. <li class="sv">
  118. @Html.ComboGrid(cgopBuildings, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  119. </li>
  120. <li class="sn" style="padding-left: 5px;">教室名称:</li>
  121. <li class="sv">
  122. @Html.ComboGrid(cgopClassroomName, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  123. </li>
  124. </ul>
  125. <ul>
  126. @*<li class="sn" style="padding-left: 5px;color:red;">@EMIS.Utility.RSL.Get("College"):</li>
  127. <li class="sv">
  128. @Html.ComboGrid(cgopCollege, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  129. </li>*@
  130. <li class="sn" style="padding-left: 5px;">教室类型:</li>
  131. <li class="sv">
  132. @Html.DictionaryComboGrid(EMIS.ViewModel.DictionaryItem.CF_ClassroomType, DropdownListBindType.SelectAll,
  133. new ComboGridOptions
  134. {
  135. ID = "ClassroomTypeDictionary",
  136. Name = "ClassroomTypeDictionary",
  137. OnSelect = "reload"
  138. }, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  139. </li>
  140. <li class="sn" style="padding-left: 5px;color:red;">多班教学:</li>
  141. <li class="sv">
  142. @Html.DictionaryDropDownList(EMIS.ViewModel.DictionaryItem.CF_GeneralPurpose, new DropdownListOptions()
  143. {
  144. BindType = DropdownListBindType.SelectAll,
  145. ID = "IsConcurrentUseDropdown",
  146. Name = "IsConcurrentUseDropdown",
  147. OnSelect = "reload"
  148. }, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  149. </li>
  150. @*<li class="sn" style="padding-left: 5px;color:red;">是否预留:</li>
  151. <li class="sv">
  152. @Html.DictionaryDropDownList(EMIS.ViewModel.DictionaryItem.CF_GeneralPurpose, new DropdownListOptions()
  153. {
  154. BindType = DropdownListBindType.SelectAll,
  155. ID = "IsReserveDropdown",
  156. Name = "IsReserveDropdown",
  157. OnSelect = "reload"
  158. }, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  159. </li>*@
  160. <li class="sn" style="padding-left: 5px;color:red;">是否可用:</li>
  161. <li class="sv">
  162. @Html.DictionaryDropDownList(EMIS.ViewModel.DictionaryItem.CF_GeneralPurpose, new DropdownListOptions()
  163. {
  164. BindType = DropdownListBindType.SelectAll,
  165. ID = "IsAvailableDropdown",
  166. Name = "IsAvailableDropdown",
  167. OnSelect = "reload"
  168. }, new Dictionary<string, string> { { "data-condition", "dgClassroomReserveList" } })
  169. </li>
  170. @*<li class="sn" style="padding-left: 20px;"><a href="javascript:void(0)" class="easyui-linkbutton"
  171. data-options="iconCls:'icon-search'" onclick="reload();">查询</a>
  172. </li>*@
  173. </ul>
  174. </div>
  175. </div>
  176. </form>
  177. <div class="p_title">
  178. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
  179. 教室预留信息列表</div>
  180. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("List")</div>
  181. </div>
  182. @*@Html.PositionBatchModify()*@
  183. <div class="search_list">
  184. @Html.DataGrid(new DataGridOptions
  185. {
  186. Columns = new List<DataGridColumn>()
  187. {
  188. new CheckBoxFieldColumn{ HeaderText="", FieldName="ClassroomID" },
  189. new LinkButtonColumn { FieldName="ClassroomCode", HeaderText="教室编号", Align=AlignStyle.Center, Handle="edit", Width=0.1 },
  190. new BoundFieldColumn { FieldName="ClassroomName", HeaderText="教室名称", Align=AlignStyle.Center, Width=0.1 },
  191. new BoundFieldColumn { FieldName="BuildingsInfoName", HeaderText="建筑名称", Align=AlignStyle.Center, Width=0.06, OverflowLength=6 },
  192. new BoundFieldColumn { FieldName="CampusName", HeaderText=@EMIS.Utility.RSL.Get("Campus"), Align=AlignStyle.Center, Width=0.06, OverflowLength=6 },
  193. new BoundFieldColumn { FieldName="ClassroomTypeName", HeaderText="教室类型", Align=AlignStyle.Center, OrderFieldName="", Width=0.08, OverflowLength=10 },
  194. new BoundFieldColumn { FieldName="RoomUseName", HeaderText="房间用途", Align=AlignStyle.Center, OrderFieldName="RoomUseID", Width=0.05, OverflowLength=6 },
  195. //new BoundFieldColumn { FieldName="FloorLevel", HeaderText="所在楼层", Align=AlignStyle.Center, Width=0.04 },
  196. //new BoundFieldColumn { FieldName="RowCout", HeaderText="行数", Align=AlignStyle.Center, Width=0.02 },
  197. //new BoundFieldColumn { FieldName="ColumnCount", HeaderText="列数", Align=AlignStyle.Center, Width=0.02 },
  198. new BoundFieldColumn { FieldName="Totalseating", HeaderText="总座位数", Align=AlignStyle.Center, Width=0.04 },
  199. new BoundFieldColumn { FieldName="Effectiveseating", HeaderText="有效座位数", Align=AlignStyle.Center, Width=0.05 },
  200. //new BoundFieldColumn { FieldName="Examinationseating", HeaderText="考试座位数", Align=AlignStyle.Center, Width=0.05 },
  201. //new BoundFieldColumn { FieldName="CollegeCode", HeaderText=@EMIS.Utility.RSL.Get("CollegeCode"), Align=AlignStyle.Center, Width=0.05, CustomFormatFun="SetRedColumn" },
  202. //new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("College"), Align=AlignStyle.Center, Width=0.06, OverflowLength=6, CustomFormatFun="SetRedColumn" },
  203. //new BoundFieldColumn { FieldName="CollegeCampusName", HeaderText=@EMIS.Utility.RSL.Get("Campus"), Align=AlignStyle.Center, Width=0.06, OverflowLength=6, CustomFormatFun="SetRedColumn" },
  204. new BoundFieldColumn { FieldName="IsConcurrentUseName", HeaderText="多班教学", Align=AlignStyle.Center, OrderFieldName="IsConcurrentUse", Width=0.04, CustomFormatFun="SetRedColumn" },
  205. new BoundFieldColumn { FieldName="IsReserveName", HeaderText="是否预留", Align=AlignStyle.Center, OrderFieldName="IsReserve", Width=0.04, CustomFormatFun="SetRedColumn" },
  206. new LinkButtonColumn { FieldName="ScheduleCollegeCount", HeaderText="排课院系", Align=AlignStyle.Center, Handle="editScheduleCollege", Width=0.04 },
  207. new BoundFieldColumn { FieldName="IsAvailableName", HeaderText="是否可用", Align=AlignStyle.Center, OrderFieldName="IsAvailable", Width=0.04, CustomFormatFun="SetRedColumn" },
  208. new BoundFieldColumn { FieldName="CreateUserName", HeaderText="创建人", Align=AlignStyle.Center, Width=0.05 }
  209. },
  210. CustomerRowStyleFun = "SetRedGrid",
  211. IsCheckOnSelect = true,
  212. DataSourceUrl = Url.Content("~/ClassroomReserve/List"),
  213. ID = "dgClassroomReserveList",
  214. IsPagination = true,
  215. IsShowRowNumbers = true,
  216. IsSingleSelect = false
  217. })
  218. </div>
  219. </div>