ClassroomSelect.cshtml 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. @using Bowin.Web.Controls.Mvc;
  2. @using EMIS.Web.Controls;
  3. @{
  4. ComboGridOptions cgopCampus = new ComboGridOptions
  5. {
  6. TextField = "Name",
  7. ValueField = "CampusID",
  8. OnSelect = "QueryCampusComboGridList",
  9. Name = "CampusDropdown",
  10. ID = "CampusDropdown",
  11. GridOptions = new DataGridOptions
  12. {
  13. Columns = new List<DataGridColumn>()
  14. {
  15. new BoundFieldColumn { FieldName="Name", HeaderText=@EMIS.Utility.RSL.Get("CampusName"), Align=AlignStyle.Center }
  16. },
  17. IsCheckOnSelect = true,
  18. DataSourceUrl = Url.Content("~/Campus/List"),
  19. IsPagination = true,
  20. IsShowRowNumbers = true,
  21. IsSingleSelect = false,
  22. }
  23. };
  24. ComboGridOptions cgopCollege = new ComboGridOptions
  25. {
  26. TextField = "Name",
  27. ValueField = "CollegeID",
  28. OnSelect = "QueryCollegeComboGridList",
  29. Name = "CollegeDropdown",
  30. ID = "CollegeDropdown",
  31. GridOptions = new DataGridOptions
  32. {
  33. Columns = new List<DataGridColumn>()
  34. {
  35. new BoundFieldColumn { FieldName="Name", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Align=AlignStyle.Center }
  36. },
  37. IsCheckOnSelect = true,
  38. DataSourceUrl = Url.Content("~/College/ListOnlyCollege"),
  39. IsPagination = true,
  40. IsShowRowNumbers = true,
  41. IsSingleSelect = false,
  42. }
  43. };
  44. ComboGridOptions cgop = new ComboGridOptions
  45. {
  46. TextField = "Name",
  47. ValueField = "BuildingsInfoID",
  48. Name = "BuildingsDropdown",
  49. OnSelect = "QueryBuildingsDropdownList",
  50. GridOptions = new DataGridOptions
  51. {
  52. Columns = new List<DataGridColumn>()
  53. {
  54. new BoundFieldColumn { FieldName="Name", HeaderText="建筑物名称", Width=0.3, Align=AlignStyle.Center }
  55. },
  56. IsCheckOnSelect = true,
  57. DataSourceUrl = Url.Content("~/Buildings/List"),
  58. IsPagination = true,
  59. IsShowRowNumbers = true,
  60. IsSingleSelect = false
  61. }
  62. };
  63. }
  64. @section scripts{
  65. <script src="~/Scripts/Business/Common/ClassroomSelect.js" type="text/javascript"></script>
  66. <script type="text/javascript">
  67. var nonSelect = "@DropdownList.SELECT_ALL";
  68. </script>
  69. }
  70. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  71. <div class="p_title">
  72. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
  73. 教室列表
  74. </div>
  75. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">
  76. <div class="current_navbar toolbar">
  77. <div class="func_info">
  78. <a class="easyui-linkbutton" href="javascript:Classroom_Confirm()" data-options="iconCls:'icon-ok',plain:'true'"
  79. onfocus="this.blur()">选中</a>
  80. </div>
  81. </div>
  82. </div>
  83. </div>
  84. <form id="formQuery" method="post">
  85. @Html.PositionCondition("ClassroomSelect", null)
  86. @Html.Hidden("ClassroomType", Request["ClassroomTypeID"], new Dictionary<string, object> { { "data-condition", "dgClassroomList" } })
  87. @Html.Hidden("IsSpecialDictionaryDropDown", Request["IsAvailable"], new Dictionary<string, object> { { "data-condition", "dgClassroomList" } })
  88. @Html.Hidden("MinSeatCount", Request["MinSeatCount"], new Dictionary<string, object> { { "data-condition", "dgClassroomList" } })
  89. <div class="search_keyword">
  90. <div class="search_input">
  91. <ul>
  92. <li class="sn" style="padding-left: 5px;">@EMIS.Utility.RSL.Get("Campus"):</li>
  93. <li class="sv">
  94. @Html.ComboGrid(cgopCampus, new Dictionary<string, string> { { "data-condition", "dgClassroomList" } })
  95. </li>
  96. <li class="sn" style="padding-left: 5px;">@EMIS.Utility.RSL.Get("College"):</li>
  97. <li class="sv">
  98. @Html.ComboGrid(cgopCollege, new Dictionary<string, string> { { "data-condition", "dgClassroomList" } })
  99. </li>
  100. <li class="sn" style="padding-left: 5px;">所在建筑物:</li>
  101. <li class="sv">
  102. @Html.ComboGrid(cgop, new Dictionary<string, string> { { "data-condition", "dgClassroomList" } })
  103. </li>
  104. @if (Request["IsAvailable"] == "")
  105. {
  106. <li class="sn" style="padding-left: 5px;">是否可用:</li>
  107. <li class="sv">
  108. @Html.DictionaryDropDownList(EMIS.ViewModel.DictionaryItem.CF_GeneralPurpose, new DropdownListOptions { BindType = DropdownListBindType.SelectAll, Name = "IsSpecialDictionaryDropDown", OnSelect = "QueryIsSpecialDropdownList" }, new Dictionary<string, string> { { "data-condition", "dgClassroomList" } })
  109. </li>
  110. }
  111. </ul>
  112. </div>
  113. </div>
  114. </form>
  115. <div class="search_list">
  116. @Html.DataGrid(new DataGridOptions
  117. {
  118. Columns = new List<DataGridColumn>()
  119. {
  120. new CheckBoxFieldColumn{ HeaderText="", FieldName="ClassroomID" },
  121. new BoundFieldColumn { FieldName="Code", HeaderText="教室代码", Align=AlignStyle.Center },
  122. new BoundFieldColumn { FieldName="Name", HeaderText="教室名称", Align=AlignStyle.Center },
  123. new BoundFieldColumn { FieldName="FloorLevel", HeaderText="所在楼层", Align=AlignStyle.Center },
  124. new BoundFieldColumn { FieldName="Totalseating", HeaderText="总座位数", Align=AlignStyle.Center },
  125. new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("College"), Align=AlignStyle.Center },
  126. new BoundFieldColumn { FieldName="IsAvailableName", HeaderText="是否可用", Align=AlignStyle.Center }
  127. },
  128. IsCheckOnSelect = true,
  129. DataSourceUrl = Url.Content("~/Classroom/List?lodaType=1&IsSpecialDictionaryDropDown=1"),
  130. ID = "dgClassroomList",
  131. IsPagination = true,
  132. IsShowRowNumbers = true,
  133. IsSingleSelect = false
  134. })
  135. </div>
  136. </div>