Edit.cshtml 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. @model EMIS.ViewModel.PaymentManage.WorktimeAdjustmentView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @{
  5. ViewBag.Title = "Edit";
  6. ComboGridOptions optCourse = new ComboGridOptions
  7. {
  8. TextField = "CourseName",
  9. ValueField = "CoursematerialID",
  10. OnSelect = "queryMissionClass",
  11. GridOptions = new DataGridOptions
  12. {
  13. Columns = new List<DataGridColumn>()
  14. {
  15. new BoundFieldColumn { FieldName="CourseCode", HeaderText="课程代码", Align=AlignStyle.Center, Width=0.12 },
  16. new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Align=AlignStyle.Center, Width=0.2 }
  17. },
  18. IsAutoLoad = false,
  19. OnLoadSuccessFun = "queryMissionClass",
  20. IsCheckOnSelect = true,
  21. DataSourceUrl = Url.Content("~/Coursematerial/ListForDropdown"),
  22. IsPagination = true,
  23. IsShowRowNumbers = true,
  24. IsSingleSelect = false,
  25. }
  26. };
  27. ComboGridOptions optMissionClass = new ComboGridOptions
  28. {
  29. TextField = "Name",
  30. ValueField = "EducationMissionClassID",
  31. PanelWidth = 350,
  32. GridOptions = new DataGridOptions
  33. {
  34. Columns = new List<DataGridColumn>()
  35. {
  36. new BoundFieldColumn { FieldName="Name", HeaderText="任务班名称", Align=AlignStyle.Center }
  37. },
  38. IsCheckOnSelect = true,
  39. DataSourceUrl = Url.Content("~/WorktimeAdjustment/GetEducationMissionClass"),
  40. IsPagination = true,
  41. IsShowRowNumbers = true,
  42. IsSingleSelect = false,
  43. }
  44. };
  45. ComboGridOptions optUser = new ComboGridOptions
  46. {
  47. TextField = "Name",
  48. ValueField = "UserID",
  49. OnSelect = "queryMissionClass",
  50. GridOptions = new DataGridOptions
  51. {
  52. Columns = new List<DataGridColumn>()
  53. {
  54. new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Align=AlignStyle.Center, Width=0.2 }
  55. },
  56. OnLoadSuccessFun = "queryMissionClass",
  57. IsCheckOnSelect = true,
  58. DataSourceUrl = Url.Content("~/Staff/List"),
  59. IsPagination = true,
  60. IsShowRowNumbers = true,
  61. IsSingleSelect = false,
  62. }
  63. };
  64. ComboGridOptions optStandard = new ComboGridOptions
  65. {
  66. TextField = "StandardName",
  67. ValueField = "StandardID",
  68. OnSelect = "queryMissionClass",
  69. GridOptions = new DataGridOptions
  70. {
  71. Columns = new List<DataGridColumn>()
  72. {
  73. new BoundFieldColumn { FieldName="StandardCode", HeaderText="专业代码", Align=AlignStyle.Center, Width=0.1 },
  74. new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Align=AlignStyle.Center, Width=0.2 }
  75. },
  76. IsAutoLoad = false,
  77. OnLoadSuccessFun = "queryCourse",
  78. IsCheckOnSelect = true,
  79. DataSourceUrl = Url.Content("~/Grademajor/StandardBindComboGridOptions"),
  80. IsPagination = true,
  81. IsShowRowNumbers = true,
  82. IsSingleSelect = false,
  83. }
  84. };
  85. }
  86. @section scripts{
  87. <script src="~/Scripts/Business/PaymentManage/WorktimeAdjustmentEdit.js" type="text/javascript"></script>
  88. <script type="text/javascript">
  89. var nonSelect = "@DropdownList.PLEASE_SELECT";
  90. </script>
  91. }
  92. @using (Ajax.BeginForm(new AjaxOptions
  93. {
  94. OnSuccess = "EMISFunction.FormSuccess",
  95. OnBegin = "EMISFunction.FormSubmit",
  96. OnComplete = "EMISFunction.FormComplete"
  97. }))
  98. {
  99. <div class="p_title">
  100. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
  101. 工作量调整
  102. </div>
  103. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Edit")</div>
  104. </div>
  105. <div class="search_list">
  106. <table cellpadding="0" cellspacing="0">
  107. <tr>
  108. <td>@Html.LabelFor(x => x.SchoolyearID):
  109. </td>
  110. <td>@Html.DropdownListFor((x => x.SchoolyearID), new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid"), OnSelect = "queryMissionClass", OnLoadSuccess = "queryMissionClass" })
  111. </td>
  112. <td>@Html.LabelFor(x => x.WorktimeAdjustmentTypeID):
  113. </td>
  114. <td>@Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.TP_WorktimeAdjustmentType, (x => x.WorktimeAdjustmentTypeID), new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect })
  115. </td>
  116. </tr>
  117. <tr>
  118. <td>@Html.LabelFor(x => x.AdjustDate):
  119. </td>
  120. <td>@Html.TextBoxFor(x => x.AdjustDate, new TextBoxOptions { TextBoxType = TextBoxType.Date, OnChange = "adjustDateChanged" })
  121. </td>
  122. <td>@Html.LabelFor(x => x.UserID):
  123. </td>
  124. <td>@Html.ComboGridFor(x => x.UserID, optUser)
  125. </td>
  126. </tr>
  127. <tr>
  128. <td>@Html.LabelFor(x => x.CollegeID):
  129. </td>
  130. <td>@Html.DropdownListFor(x => x.CollegeID, new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, ItemSourceUrl = Url.Content("~/College/CollegeDropdownListBanids"), OnLoadSuccess = "queryStandard", OnSelect = "queryStandard" })
  131. </td>
  132. <td>@Html.LabelFor(x => x.GradeYearID):
  133. </td>
  134. <td>@Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Grade, (x => x.GradeYearID), new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, OnLoadSuccess = "queryStandard", OnSelect = "queryStandard" })
  135. </td>
  136. </tr>
  137. <tr>
  138. <td>@Html.LabelFor(x => x.StandardID):
  139. </td>
  140. <td>@Html.ComboGridFor(x => x.StandardID, optStandard)
  141. </td>
  142. <td>@Html.LabelFor(x => x.CoursematerialID):
  143. </td>
  144. <td>@Html.ComboGridFor(x => x.CoursematerialID, optCourse)
  145. </td>
  146. </tr>
  147. <tr>
  148. <td>@Html.LabelFor(x => x.EducationMissionClassID):
  149. </td>
  150. <td>@Html.ComboGridFor(x => x.EducationMissionClassID, optMissionClass)
  151. </td>
  152. <td>@Html.LabelFor(x => x.Worktime):
  153. </td>
  154. <td>@Html.TextBoxFor(x => x.Worktime)
  155. </td>
  156. </tr>
  157. </table>
  158. </div>
  159. }