Edit.cshtml 9.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225
  1. @model EMIS.ViewModel.DQPSystem.SOCTemplateView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @using EMIS.ViewModel;
  5. @{
  6. ViewBag.Title = "Edit";
  7. ComboGridOptions cgopFacultymajor = new ComboGridOptions
  8. {
  9. TextField = "Name",
  10. ValueField = "FacultymajorID",
  11. Name = "FacultymajorComboGrid",
  12. ID = "FacultymajorComboGrid",
  13. GridOptions = new DataGridOptions
  14. {
  15. Columns = new List<DataGridColumn>()
  16. {
  17. new BoundFieldColumn { FieldName="Code", HeaderText="院系专业编号", Align=AlignStyle.Center },
  18. new BoundFieldColumn { FieldName="Name", HeaderText="院系专业名称", Align=AlignStyle.Center }
  19. },
  20. IsCheckOnSelect = true,
  21. DataSourceUrl = Url.Content("~/Facultymajor/List"),
  22. IsPagination = true,
  23. IsShowRowNumbers = true,
  24. IsSingleSelect = false,
  25. IsShowHeader = false
  26. }
  27. };
  28. ComboGridOptions cgopCourse = new ComboGridOptions
  29. {
  30. TextField = "CourseName",
  31. ValueField = "CoursematerialID",
  32. Name = "CoursematerialIDDropdownGridBo",
  33. ID = "CoursematerialIDDropdownGridBo",
  34. GridOptions = new DataGridOptions
  35. {
  36. Columns = new List<DataGridColumn>()
  37. {
  38. new BoundFieldColumn { FieldName="CourseCode", HeaderText="课程代码", Width=0.1, Align=AlignStyle.Center },
  39. new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Width=0.3, Align=AlignStyle.Center }
  40. },
  41. IsCheckOnSelect = true,
  42. DataSourceUrl = Url.Content("~/Coursematerial/ListForDropdown"),
  43. IsPagination = true,
  44. IsShowRowNumbers = true,
  45. IsSingleSelect = false
  46. }
  47. };
  48. //开课教研室
  49. ComboGridOptions cgopDepartment = new ComboGridOptions
  50. {
  51. ID = "DepartmentDropdown",
  52. Name = "DepartmentDropdown",
  53. TextField = "Name",
  54. ValueField = "DepartmentID",
  55. GridOptions = new DataGridOptions
  56. {
  57. Columns = new List<DataGridColumn>()
  58. {
  59. //new LinkButtonColumn { FieldName="No", HeaderText="教研室代码", Align=AlignStyle.Center, Width=0.1 },
  60. new BoundFieldColumn { FieldName="Name", HeaderText="教研室名称", Align=AlignStyle.Center, Width=0.2 }
  61. },
  62. //IsAutoLoad = false,
  63. IsCheckOnSelect = true,
  64. DataSourceUrl = Url.Content("~/Department/List"),
  65. IsPagination = true,
  66. IsShowRowNumbers = true,
  67. IsSingleSelect = false,
  68. }
  69. };
  70. ComboGridOptions cgopStandard = new ComboGridOptions
  71. {
  72. TextField = "StandardName",
  73. ValueField = "StandardID",
  74. Name = "StandardDictionaryDropDown",
  75. ID = "StandardDictionaryDropDown",
  76. IsEnabled = false,
  77. GridOptions = new DataGridOptions
  78. {
  79. Columns = new List<DataGridColumn>()
  80. {
  81. new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Align=AlignStyle.Center }
  82. },
  83. IsCheckOnSelect = true,
  84. DataSourceUrl = Url.Content("~/Grademajor/StandardBindComboGridOptions"),
  85. IsPagination = true,
  86. IsShowRowNumbers = true,
  87. IsSingleSelect = false,
  88. }
  89. };
  90. ComboGridOptions cgopStandardCan = new ComboGridOptions
  91. {
  92. TextField = "StandardName",
  93. ValueField = "StandardID",
  94. Name = "StandardDictionaryDropDown",
  95. ID = "StandardDictionaryDropDown",
  96. GridOptions = new DataGridOptions
  97. {
  98. Columns = new List<DataGridColumn>()
  99. {
  100. new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Align=AlignStyle.Center }
  101. },
  102. IsCheckOnSelect = true,
  103. DataSourceUrl = Url.Content("~/Grademajor/StandardBindComboGridOptions"),
  104. IsPagination = true,
  105. IsShowRowNumbers = true,
  106. IsSingleSelect = false,
  107. }
  108. };
  109. }
  110. @section scripts{
  111. <script src="~/Scripts/Business/DQPSystem/SOCTemplateEdit.js" type="text/javascript"></script>
  112. }
  113. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  114. @using (Ajax.BeginForm(new AjaxOptions { OnSuccess = "EMISFunction.FormSuccess", OnBegin = "EMISFunction.FormSubmit", OnComplete = "EMISFunction.FormComplete" }))
  115. {
  116. <div class="p_title">
  117. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Setting")</div>
  118. </div>
  119. <div class="search_list">
  120. @Html.Hidden("hid_ActionsType")
  121. @Html.HiddenFor(x => x.SOCTemplateID)
  122. <table cellpadding="0" cellspacing="0" id="departmenttable">
  123. <tr>
  124. <td>
  125. @Html.LabelFor(x => x.StandardName):
  126. </td>
  127. <td>
  128. @if (Model.SOCTemplateID == null || Model.SOCTemplateID == Guid.Empty)
  129. {
  130. @Html.ComboGridFor(x => x.StandardID, cgopStandardCan)
  131. }
  132. else
  133. {
  134. @Html.ComboGridFor(x => x.StandardID, cgopStandard)
  135. }
  136. </td>
  137. <td>
  138. @Html.LabelFor(x => x.FacultymajorName):
  139. </td>
  140. <td>
  141. @Html.ComboGridFor(x => x.FacultymajorID, cgopFacultymajor)
  142. </td>
  143. <td>
  144. @Html.LabelFor(x => x.CourseName):
  145. </td>
  146. <td>
  147. @Html.ComboGridFor(x => x.CoursematerialID, cgopCourse)
  148. </td>
  149. </tr>
  150. <tr>
  151. <td>
  152. @Html.LabelFor(x => x.CreditStr):
  153. </td>
  154. <td>
  155. @Html.TextBoxFor(x => x.Credit)
  156. </td>
  157. <td>
  158. @Html.LabelFor(x => x.SchoolyearNumName):
  159. </td>
  160. <td>
  161. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_SchoolyearNum, x => x.SchoolyearNumID)
  162. </td>
  163. <td>
  164. @Html.LabelFor(x => x.SchoolcodeName):
  165. </td>
  166. <td>
  167. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Semester, x => x.SchoolcodeID)
  168. </td>
  169. </tr>
  170. <tr>
  171. <td>
  172. @Html.LabelFor(x => x.DepartmentName):
  173. </td>
  174. <td>
  175. @Html.ComboGridFor(x => x.DepartmentID, cgopDepartment)
  176. </td>
  177. <td>
  178. @Html.LabelFor(x => x.HandleModeID):
  179. </td>
  180. <td>
  181. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_HandleMode, x => x.HandleModeID)
  182. </td>
  183. <td>
  184. @Html.LabelFor(x => x.IsEnableName):
  185. </td>
  186. <td>
  187. @Html.CheckBoxFor(x => x.IsEnable)
  188. </td>
  189. </tr>
  190. <tr>
  191. <td>
  192. @Html.Label("SOC设置"):
  193. </td>
  194. <td colspan="5">
  195. @Html.ContextMenuBar("Edit-SOCTemplateDetailGrid")
  196. @Html.DataGrid(new DataGridOptions
  197. {
  198. Columns = new List<DataGridColumn>()
  199. {
  200. new CheckBoxFieldColumn{ HeaderText="", FieldName="SOCTemplateItemID" },
  201. new TextBoxColumn { FieldName="Name", HeaderText="成果名称", Align=AlignStyle.Center, Width=80 },
  202. new TextBoxColumn { FieldName="Credit", HeaderText="成果学分", Align=AlignStyle.Center, Width=60 },
  203. new TextBoxColumn { FieldName="Weight", HeaderText="成果权重", Align=AlignStyle.Center, Width=60 },
  204. new TextBoxColumn { FieldName="Description", IsMultiLine=true, HeaderText="成果描述", Align=AlignStyle.Center, Width=320 },
  205. new BoundFieldColumn { FieldName="AttachmentName", HeaderText="附件说明", Align=AlignStyle.Center, Width=120 },
  206. new CheckButtonColumn { FieldName="IsGroup", HeaderText="是否分组", Align=AlignStyle.Center, Width=60 },
  207. },
  208. IsCheckOnSelect = true,
  209. DataSourceUrl = Url.Content("~/SOCTemplate/TemplateDetail?templateID=" + Request.Params["templateID"]),
  210. ID = "dgSOCTemplateDetailList",
  211. IsPagination = true,
  212. IsPostBack = true,
  213. IsShowRowNumbers = true,
  214. IsSingleSelect = false,
  215. MaxHeight = 180
  216. })
  217. </td>
  218. </tr>
  219. </table>
  220. </div>
  221. }
  222. </div>