Approve.cshtml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243
  1. @model EMIS.ViewModel.ScoreManage.LevelScoreManage.LevelScoreView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @{
  5. ViewBag.Title = "Approve";
  6. var isEnable = (Request["levelScoreID"] ?? "") == "";
  7. //学生信息
  8. ComboGridOptions cgopStudent = new ComboGridOptions
  9. {
  10. TextField = "StudentNo",
  11. ValueField = "UserID",
  12. OnSelect = "queryStudent",
  13. IsEnabled = isEnable,
  14. GridOptions = new DataGridOptions
  15. {
  16. Columns = new List<DataGridColumn>()
  17. {
  18. new LinkButtonColumn { FieldName="StudentNo", HeaderText="学号", Width=0.2, Align=AlignStyle.Center },
  19. new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Width=0.08, Align=AlignStyle.Center },
  20. new BoundFieldColumn { FieldName="SexName", HeaderText="性别", Width=0.06, Align=AlignStyle.Center, OrderFieldName="SexID" },
  21. //new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Width=0.1, Align=AlignStyle.Center, OrderFieldName="StandardID", OverflowLength=6 },
  22. new BoundFieldColumn { FieldName="ClassmajorName", HeaderText="班级名称", Width=0.06, Align=AlignStyle.Center, OverflowLength=6 },
  23. //new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Width=0.1, Align=AlignStyle.Center, OverflowLength=6 },
  24. new BoundFieldColumn { FieldName="InSchoolStatusName", HeaderText="在校状态", Width=0.1, Align=AlignStyle.Center, OrderFieldName="InSchoolStatusID", CustomFormatFun="SetRedColumn" }
  25. //new BoundFieldColumn { FieldName="StudentStatusName", HeaderText="学籍状态", Width=0.1, Align=AlignStyle.Center, OrderFieldName="StudentStatus", CustomFormatFun="SetRedColumn" }
  26. },
  27. PageSize = 10,
  28. IsCheckOnSelect = true,
  29. DataSourceUrl = Url.Content("~/Student/StudentBaseInSchoolList?userID=" + Model.UserID),
  30. IsPagination = true,
  31. IsShowRowNumbers = true,
  32. IsSingleSelect = false
  33. }
  34. };
  35. //班级信息
  36. ComboGridOptions cgopClassmajor = new ComboGridOptions
  37. {
  38. TextField = "Name",
  39. ValueField = "ClassmajorID",
  40. IsEnabled = false,
  41. GridOptions = new DataGridOptions
  42. {
  43. Columns = new List<DataGridColumn>()
  44. {
  45. new LinkButtonColumn { FieldName="No", HeaderText="班级编号", Width=0.2, Align=AlignStyle.Center },
  46. new BoundFieldColumn { FieldName="Name", HeaderText="班级名称", Width=0.3, Align=AlignStyle.Center }
  47. },
  48. PageSize = 5,
  49. IsCheckOnSelect = true,
  50. DataSourceUrl = Url.Content("~/Classmajor/List"),
  51. IsPagination = true,
  52. IsShowRowNumbers = true,
  53. IsSingleSelect = false
  54. }
  55. };
  56. //考试科目
  57. ComboGridOptions cgopExaminationSubject = new ComboGridOptions
  58. {
  59. TextField = "Name",
  60. ValueField = "ExaminationSubjectID",
  61. IsEnabled = isEnable,
  62. GridOptions = new DataGridOptions
  63. {
  64. Columns = new List<DataGridColumn>()
  65. {
  66. new LinkButtonColumn { FieldName="Name", HeaderText="考试科目", Width=0.35, Align=AlignStyle.Center }
  67. },
  68. PageSize = 5,
  69. IsCheckOnSelect = true,
  70. DataSourceUrl = Url.Content("~/ExaminationSubject/List"),
  71. IsPagination = true,
  72. IsShowRowNumbers = true,
  73. IsSingleSelect = false
  74. }
  75. };
  76. }
  77. @{
  78. var listAction = ViewBag.ListAction as List<DropdownListItem>;
  79. var defaultAction = listAction.FirstOrDefault(x => true);
  80. var defaultActionValue = (defaultAction == null ? null : defaultAction.Value);
  81. }
  82. @section scripts{
  83. <script src="~/Scripts/Business/ScoreManage/LevelScoreManage/LevelScoreApprove.js" type="text/javascript"></script>
  84. }
  85. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  86. @using (Ajax.BeginForm(new AjaxOptions
  87. {
  88. OnSuccess = "EMISFunction.FormSuccess",
  89. OnBegin = "EMISFunction.FormSubmit",
  90. OnComplete = "EMISFunction.FormComplete"
  91. }))
  92. {
  93. <div class="p_title">
  94. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;"></div>
  95. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Approve")</div>
  96. </div>
  97. <div class="search_list">
  98. @Html.HiddenFor(x => x.LevelScoreID)
  99. <table cellpadding="0" cellspacing="0" id="levelscoretable">
  100. <tr>
  101. <td style="color: red;">
  102. @Html.LabelFor(x => x.StudentNo):
  103. </td>
  104. <td>
  105. @Html.ComboGridFor(x => x.UserID, cgopStudent)
  106. </td>
  107. <td style="color: red;">
  108. @Html.LabelFor(x => x.ExaminationSubjectName):
  109. </td>
  110. <td>
  111. @Html.ComboGridFor(x => x.ExaminationSubjectID, cgopExaminationSubject)
  112. </td>
  113. </tr>
  114. <tr>
  115. <td>
  116. @Html.LabelFor(x => x.Name):
  117. </td>
  118. <td>
  119. @Html.TextBoxFor(x => x.Name, new TextBoxOptions() { IsEnabled = false })
  120. </td>
  121. <td>
  122. @Html.LabelFor(x => x.SexName):
  123. </td>
  124. <td>
  125. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.CF_Sex, (x => x.SexID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  126. </td>
  127. </tr>
  128. <tr>
  129. <td>
  130. @Html.LabelFor(x => x.ClassmajorName):
  131. </td>
  132. <td>
  133. @Html.ComboGridFor(x => x.ClassmajorID, cgopClassmajor)
  134. </td>
  135. <td>
  136. @Html.LabelFor(x => x.InSchoolStatusName):
  137. </td>
  138. <td>
  139. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.CF_InschoolStatus, (x => x.InSchoolStatusID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  140. </td>
  141. </tr>
  142. <tr>
  143. <td>
  144. @Html.LabelFor(x => x.SchoolyearCode):
  145. </td>
  146. <td>
  147. @Html.DropdownListFor((x => x.SchoolyearID), new DropdownListOptions
  148. {
  149. TextField = "Text",
  150. ValueField = "Value",
  151. BindType = DropdownListBindType.PleaseSelect,
  152. IsEnabled = isEnable,
  153. SelectedValue = BaseExtensions.GetCurrentSchoolYearID(),
  154. ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid")
  155. })
  156. </td>
  157. <td style="color: red;">
  158. @Html.LabelFor(x => x.ExaminationDate):
  159. </td>
  160. <td>
  161. @Html.TextBoxFor(x => x.ExaminationDate, new TextBoxOptions() { TextBoxType = TextBoxType.Month, IsEnabled = isEnable })
  162. </td>
  163. </tr>
  164. <tr>
  165. <td>
  166. @Html.LabelFor(x => x.ScoreNo):
  167. </td>
  168. <td>
  169. @Html.TextBoxFor(x => x.ScoreNo, new TextBoxOptions() { IsEnabled = isEnable })
  170. </td>
  171. <td style="color: red;">
  172. @Html.LabelFor(x => x.TotalScore):
  173. </td>
  174. <td>
  175. @Html.TextBoxFor(x => x.TotalScore, new TextBoxOptions() { IsEnabled = isEnable })
  176. </td>
  177. </tr>
  178. <tr>
  179. <td>
  180. @Html.LabelFor(x => x.LevelName):
  181. </td>
  182. <td>
  183. @Html.TextBoxFor(x => x.LevelName, new TextBoxOptions() { IsEnabled = false })
  184. </td>
  185. <td>
  186. @Html.LabelFor(x => x.CreateUserName):
  187. </td>
  188. <td>
  189. @Html.TextBoxFor(x => x.CreateUserName, new TextBoxOptions() { IsEnabled = false })
  190. </td>
  191. </tr>
  192. <tr>
  193. <td>
  194. @Html.LabelFor(x => x.Remark):
  195. </td>
  196. <td colspan="3">
  197. @if (!isEnable)
  198. {
  199. @Html.TextAreaFor(x => x.Remark, new Dictionary<string, object>
  200. {
  201. { "style", "width: 90%;min-height: 45px" },
  202. { "disabled", "true" }
  203. })
  204. }
  205. else
  206. {
  207. @Html.TextAreaFor(x => x.Remark, new Dictionary<string, object> { { "style", "width: 90%;min-height: 45px" } })
  208. }
  209. </td>
  210. </tr>
  211. <tr>
  212. <td style="color: red;">
  213. @Html.LabelFor(x => x.Action):
  214. </td>
  215. <td colspan="3">
  216. @Html.DropdownList(new DropdownListOptions
  217. {
  218. BindType = DropdownListBindType.None,
  219. ID = "ddlAction",
  220. Name = "ddlAction",
  221. ItemList = listAction,
  222. SelectedValue = defaultActionValue
  223. })
  224. </td>
  225. </tr>
  226. <tr>
  227. <td>
  228. @Html.LabelFor(x => x.Comment):
  229. </td>
  230. <td colspan="3">
  231. @Html.TextAreaFor(x => x.Comment, new Dictionary<string, object>
  232. {
  233. { "style", "width: 90%;min-height: 50px" }
  234. })
  235. </td>
  236. </tr>
  237. </table>
  238. </div>
  239. }
  240. </div>