Edit.cshtml 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. @model EMIS.ViewModel.ScoreManage.MisconductView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @{
  5. ViewBag.Title = "Edit";
  6. ComboGridOptions cgopCourse = new ComboGridOptions
  7. {
  8. TextField = "CourseName",
  9. ValueField = "CoursematerialID",
  10. GridOptions = new DataGridOptions
  11. {
  12. Columns = new List<DataGridColumn>()
  13. {
  14. new LinkButtonColumn { FieldName="CourseCode", HeaderText="课程代码", Width=0.1, Align=AlignStyle.Center },
  15. new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Width=0.3, Align=AlignStyle.Center }
  16. },
  17. IsAutoLoad = (Model.MisconductID != Guid.Empty),
  18. IsCheckOnSelect = true,
  19. DataSourceUrl = Url.Content("~/Misconduct/GetCoursematerial?schoolyearID=" + Model.SchoolyearID + "&userID=" + Model.UserID),
  20. IsPagination = true,
  21. IsShowRowNumbers = true,
  22. IsSingleSelect = false
  23. }
  24. };
  25. ComboGridOptions cgopStudent = new ComboGridOptions
  26. {
  27. TextField = "LoginID",
  28. ValueField = "UserID",
  29. OnSelect = "setName",
  30. GridOptions = new DataGridOptions
  31. {
  32. Columns = new List<DataGridColumn>()
  33. {
  34. new LinkButtonColumn { FieldName="LoginID", HeaderText="学号", Align=AlignStyle.Center },
  35. new BoundFieldColumn { FieldName="UserName", HeaderText="姓名", Align=AlignStyle.Center }
  36. },
  37. IsCheckOnSelect = true,
  38. DataSourceUrl = Url.Content("~/Students/List"),
  39. IsPagination = true,
  40. IsShowRowNumbers = true,
  41. IsSingleSelect = false
  42. }
  43. };
  44. }
  45. @section scripts{
  46. <script src="~/Scripts/Business/ScoreManage/MisconductEdit.js" type="text/javascript"></script>
  47. <script type="text/javascript">
  48. var nonSelect = "@DropdownList.SELECT_ALL";
  49. </script>
  50. }
  51. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  52. @using (Ajax.BeginForm(new AjaxOptions
  53. {
  54. OnSuccess = "EMISFunction.FormSuccess",
  55. OnBegin = "EMISFunction.FormSubmit",
  56. OnComplete = "EMISFunction.FormComplete"
  57. }))
  58. {
  59. <div class="p_title">
  60. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
  61. 违纪名单申请</div>
  62. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Edit")</div>
  63. </div>
  64. <div class="search_list">
  65. <table cellpadding="0" cellspacing="0">
  66. <tr>
  67. <td>@Html.LabelFor(x => x.UserID):</td>
  68. <td>@Html.ComboGridFor(x => x.UserID, cgopStudent)</td>
  69. <td>@Html.LabelFor(x => x.Name):</td>
  70. <td>@Html.DisplayFor(x => x.Name)</td>
  71. </tr>
  72. <tr>
  73. <td>@Html.LabelFor(x => x.SchoolyearID):</td>
  74. <td>@Html.DropdownListFor(x => x.SchoolyearID, new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid"), OnSelect = "queryCoursematerial" })</td>
  75. <td>@Html.LabelFor(x => x.CoursematerialID):
  76. </td>
  77. <td>@Html.ComboGridFor(x => x.CoursematerialID, cgopCourse)
  78. </td>
  79. </tr>
  80. <tr>
  81. <td>@Html.LabelFor(x => x.ExamsCategoryID):
  82. </td>
  83. <td>@Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ExamsCategory, x => x.ExamsCategoryID)
  84. </td>
  85. <td>@Html.LabelFor(x => x.ExamsStateID):
  86. </td>
  87. <td>@Html.DropdownListFor(x => x.ExamsStateID, new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, ItemSourceUrl = Url.Content("~/Misconduct/GetMisconductExamsStateList") })
  88. </td>
  89. </tr>
  90. <tr>
  91. <td>@Html.LabelFor(x => x.Reason):
  92. </td>
  93. <td colspan="3">@Html.TextAreaFor(x => x.Reason, new Dictionary<string, object> { { "style", "width: 98%;" } })
  94. </td>
  95. </tr>
  96. </table>
  97. </div>
  98. }
  99. </div>