Edit.cshtml 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357
  1. @model EMIS.ViewModel.EvaluationManage.StudentEvaluation.EvaluationStudentSettingScoreView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @{
  5. ViewBag.Title = "Edit";
  6. var isEnable = Request["type"] == "detail" ? false : true;
  7. //院系所
  8. ComboGridOptions cgopCollege = new ComboGridOptions
  9. {
  10. ID = "CollegeID",
  11. TextField = "Name",
  12. ValueField = "CollegeID",
  13. IsEnabled = false,
  14. GridOptions = new DataGridOptions
  15. {
  16. Columns = new List<DataGridColumn>()
  17. {
  18. //new LinkButtonColumn { FieldName="No", HeaderText=@EMIS.Utility.RSL.Get("CollegeCode"), Align=AlignStyle.Center, Width=0.1 },
  19. new BoundFieldColumn { FieldName="Name", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Align=AlignStyle.Center, Width=0.2 }
  20. },
  21. PageSize = 5,
  22. IsCheckOnSelect = true,
  23. DataSourceUrl = Url.Content("~/College/ListOnlyCollege"),
  24. IsPagination = true,
  25. IsShowRowNumbers = true,
  26. IsSingleSelect = false,
  27. }
  28. };
  29. //教研室
  30. ComboGridOptions cgopDepartment = new ComboGridOptions
  31. {
  32. ID = "DepartmentID",
  33. TextField = "Name",
  34. ValueField = "DepartmentID",
  35. IsEnabled = false,
  36. GridOptions = new DataGridOptions
  37. {
  38. Columns = new List<DataGridColumn>()
  39. {
  40. new LinkButtonColumn { FieldName="No", HeaderText="教研室代码", Align=AlignStyle.Center, Width=0.1 },
  41. new BoundFieldColumn { FieldName="Name", HeaderText="开课教研室", Align=AlignStyle.Center, Width=0.2 },
  42. new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("CourseCollege"), Align=AlignStyle.Center, Width=0.2 }
  43. },
  44. PageSize = 5,
  45. IsCheckOnSelect = true,
  46. DataSourceUrl = Url.Content("~/Department/List"),
  47. IsPagination = true,
  48. IsShowRowNumbers = true,
  49. IsSingleSelect = false
  50. }
  51. };
  52. //课程信息
  53. ComboGridOptions cgopCourse = new ComboGridOptions
  54. {
  55. ID = "CoursematerialID",
  56. TextField = "CourseName",
  57. ValueField = "CoursematerialID",
  58. IsEnabled = false,
  59. GridOptions = new DataGridOptions
  60. {
  61. Columns = new List<DataGridColumn>()
  62. {
  63. new LinkButtonColumn { FieldName="CourseCode", HeaderText="课程代码", Align=AlignStyle.Center, Width=0.1 },
  64. new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Align=AlignStyle.Center, Width=0.2 },
  65. new BoundFieldColumn { FieldName="IsEnableName", HeaderText="是否启用", Align=AlignStyle.Center, Width=0.1, CustomFormatFun="SetRedColumn" }
  66. },
  67. PageSize = 5,
  68. IsCheckOnSelect = true,
  69. DataSourceUrl = Url.Content("~/Coursematerial/GetEnableAndUseCoursematerialView?coursematerialID=" + Model.CoursematerialID),
  70. IsPagination = true,
  71. IsShowRowNumbers = true,
  72. IsSingleSelect = false
  73. }
  74. };
  75. //任课教师
  76. ComboGridOptions cgopStaff = new ComboGridOptions
  77. {
  78. TextField = "Name",
  79. ValueField = "UserID",
  80. IsEnabled = false,
  81. GridOptions = new DataGridOptions
  82. {
  83. Columns = new List<DataGridColumn>()
  84. {
  85. new LinkButtonColumn { FieldName="StaffCode", HeaderText="教师工号", Align=AlignStyle.Center ,Width=0.1 },
  86. new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Align=AlignStyle.Center ,Width=0.1 }
  87. },
  88. PageSize = 5,
  89. IsCheckOnSelect = true,
  90. DataSourceUrl = Url.Content("~/Staff/List"),
  91. IsPagination = true,
  92. IsShowRowNumbers = true,
  93. IsSingleSelect = false
  94. }
  95. };
  96. //参评类型
  97. ComboGridOptions cgopEvaluationParticipateType = new ComboGridOptions
  98. {
  99. TextField = "ParticipateTypeName",
  100. ValueField = "EvaluationParticipateTypeID",
  101. OnSelect = "queryEvaluationParticipateType",
  102. IsEnabled = false,
  103. GridOptions = new DataGridOptions
  104. {
  105. Columns = new List<DataGridColumn>()
  106. {
  107. new BoundFieldColumn { FieldName="ParticipateTypeName", HeaderText="参评类型", Align=AlignStyle.Center, Width=0.1, OrderFieldName="ParticipateTypeID" },
  108. new BoundFieldColumn { FieldName="IsStudentName", HeaderText="学生用", Align=AlignStyle.Center, Width=0.08, OrderFieldName="IsStudent", CustomFormatFun="SetRedColumn"}
  109. },
  110. PageSize = 5,
  111. IsCheckOnSelect = true,
  112. DataSourceUrl = Url.Content("~/EvaluationParticipateType/List"),
  113. IsPagination = true,
  114. IsShowRowNumbers = true,
  115. IsSingleSelect = false
  116. }
  117. };
  118. //评价表名
  119. ComboGridOptions cgopEvaluationTable = new ComboGridOptions
  120. {
  121. TextField = "Name",
  122. ValueField = "EvaluationTableID",
  123. OnSelect = "queryEvaluationTable",
  124. IsEnabled = false,
  125. GridOptions = new DataGridOptions
  126. {
  127. Columns = new List<DataGridColumn>()
  128. {
  129. new BoundFieldColumn { FieldName="Code", HeaderText="编号", Align=AlignStyle.Center, Width=0.1 },
  130. new BoundFieldColumn { FieldName="Name", HeaderText="评价表名", Align=AlignStyle.Center, Width=0.25 },
  131. //new BoundFieldColumn { FieldName="ParticipateTypeName", HeaderText="参评类型", Align=AlignStyle.Center, Width=0.12, OrderFieldName="ParticipateTypeID" },
  132. //new BoundFieldColumn { FieldName="IsStudentName", HeaderText="学生用", Align=AlignStyle.Center, Width=0.1, OrderFieldName="IsStudent", CustomFormatFun="SetRedColumn" },
  133. new BoundFieldColumn { FieldName="EvaluationTypeName", HeaderText="评价类型", Align=AlignStyle.Center, Width=0.1 },
  134. new BoundFieldColumn { FieldName="IsEnabledName", HeaderText="是否启用", Align=AlignStyle.Center, Width=0.1, OrderFieldName="IsEnabled", CustomFormatFun="SetRedColumn" }
  135. },
  136. PageSize = 5,
  137. IsCheckOnSelect = true,
  138. DataSourceUrl = Url.Content("~/EvaluationTable/GetEvaluationTableEnabledAndUseList?evaluationTableID=" + Model.EvaluationTableID),
  139. IsPagination = true,
  140. IsShowRowNumbers = true,
  141. IsSingleSelect = false
  142. }
  143. };
  144. }
  145. @section scripts{
  146. <script src="~/Scripts/Business/EvaluationManage/StudentEvaluation/EvaluationStudentSettingScoreEdit.js" type="text/javascript"></script>
  147. <script type="text/javascript">
  148. var nonSelect = "@DropdownList.SELECT_ALL";
  149. </script>
  150. }
  151. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  152. @using (Ajax.BeginForm(new AjaxOptions
  153. {
  154. OnSuccess = "EMISFunction.FormSuccess",
  155. OnBegin = "EMISFunction.FormSubmit",
  156. OnComplete = "EMISFunction.FormComplete"
  157. }))
  158. {
  159. <div class="p_title">
  160. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;"></div>
  161. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">
  162. @if (Request["type"] != "detail")
  163. {
  164. @Html.ContextMenuBar("Edit")
  165. }
  166. </div>
  167. </div>
  168. <div class="search_list">
  169. @Html.HiddenFor(x => x.EvaluationStudentSettingScoreID)
  170. @Html.HiddenFor(x => x.EvaluationStudentSettingID)
  171. @Html.HiddenFor(x => x.EducationMissionClassID)
  172. <table cellpadding="0" cellspacing="0" id="evaluationstudentsettingtable">
  173. <tr>
  174. <td style="color:red;">
  175. @Html.LabelFor(x => x.MissionClassName):
  176. </td>
  177. <td colspan="3">
  178. @Html.TextBoxFor(x => x.MissionClassName, new TextBoxOptions() { IsEnabled = false }, new Dictionary<string, string> { { "style", "width:92%;" } })
  179. </td>
  180. </tr>
  181. <tr>
  182. <td>
  183. @Html.LabelFor(x => x.SchoolyearCode):
  184. </td>
  185. <td>
  186. @Html.DropdownListFor((x => x.SchoolyearID), new DropdownListOptions
  187. {
  188. BindType = DropdownListBindType.PleaseSelect,
  189. TextField = "Text",
  190. ValueField = "Value",
  191. IsEnabled = false,
  192. ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid")
  193. })
  194. </td>
  195. <td>
  196. @Html.LabelFor(x => x.CollegeName):
  197. </td>
  198. <td>
  199. @Html.ComboGridFor(x => x.CollegeID, cgopCollege)
  200. </td>
  201. </tr>
  202. <tr>
  203. <td style="color:red;">
  204. @Html.LabelFor(x => x.CourseName):
  205. </td>
  206. <td>
  207. @Html.ComboGridFor(x => x.CoursematerialID, cgopCourse)
  208. </td>
  209. <td style="color:red;">
  210. @Html.LabelFor(x => x.DepartmentName):
  211. </td>
  212. <td>
  213. @Html.ComboGridFor(x => x.DepartmentID, cgopDepartment)
  214. </td>
  215. </tr>
  216. <tr>
  217. <td>
  218. @Html.LabelFor(x => x.CourseStructureName):
  219. </td>
  220. <td>
  221. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseStructure, x => x.CourseStructureID, new DropdownListOptions() { IsEnabled = false })
  222. </td>
  223. <td>
  224. @Html.LabelFor(x => x.CourseCategoryName):
  225. </td>
  226. <td>
  227. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseCategory, x => x.CourseCategoryID, new DropdownListOptions() { IsEnabled = false })
  228. </td>
  229. </tr>
  230. <tr>
  231. <td style="color:red;">
  232. @Html.LabelFor(x => x.CourseTypeName):
  233. </td>
  234. <td>
  235. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseType, x => x.CourseTypeID, new DropdownListOptions() { IsEnabled = false })
  236. </td>
  237. <td>
  238. @Html.LabelFor(x => x.CourseQualityName):
  239. </td>
  240. <td>
  241. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseQuality, x => x.CourseQualityID, new DropdownListOptions() { IsEnabled = false })
  242. </td>
  243. </tr>
  244. <tr>
  245. <td>
  246. @Html.LabelFor(x => x.Credit):
  247. </td>
  248. <td>
  249. @*@Html.TextBoxFor(x => x.Credit, new Dictionary<string, object> { { "readOnly", "true" } })*@
  250. @Html.TextBoxFor(x => x.Credit, new TextBoxOptions() { IsEnabled = false })
  251. </td>
  252. <td>
  253. @Html.LabelFor(x => x.HandleModeID):
  254. </td>
  255. <td>
  256. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.CF_HandleMode, (x => x.HandleModeID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  257. </td>
  258. </tr>
  259. <tr>
  260. <td style="color:red;">
  261. @Html.LabelFor(x => x.TeachingModeID):
  262. </td>
  263. <td>
  264. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.CF_TeachingMode, (x => x.TeachingModeID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  265. </td>
  266. <td>
  267. @Html.LabelFor(x => x.MissionClassStatus):
  268. </td>
  269. <td>
  270. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.EM_EducationMissionClassStatus, (x => x.MissionClassStatus), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  271. </td>
  272. </tr>
  273. <tr>
  274. <td>
  275. @Html.LabelFor(x => x.ParticipateTypeName):
  276. </td>
  277. <td>
  278. @Html.ComboGridFor(x => x.EvaluationParticipateTypeID, cgopEvaluationParticipateType)
  279. </td>
  280. <td style="color:red;">
  281. @Html.LabelFor(x => x.EvaluationTableName):
  282. </td>
  283. <td>
  284. @Html.ComboGridFor(x => x.EvaluationTableID, cgopEvaluationTable)
  285. </td>
  286. </tr>
  287. <tr>
  288. <td style="color:red;">
  289. @Html.LabelFor(x => x.StaffName):
  290. </td>
  291. <td>
  292. @Html.ComboGridFor(x => x.UserID, cgopStaff)
  293. </td>
  294. <td style="color:red;">
  295. @Html.LabelFor(x => x.TeachingMethodID):
  296. </td>
  297. <td>
  298. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.EM_TeachingMethod, (x => x.TeachingMethodID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  299. </td>
  300. </tr>
  301. <tr>
  302. <td>
  303. @Html.LabelFor(x => x.ParticipateCount):
  304. </td>
  305. <td>
  306. @Html.TextBoxFor(x => x.ParticipateCount, new TextBoxOptions() { IsEnabled = false })
  307. </td>
  308. <td>
  309. @Html.LabelFor(x => x.ValidityParticipateCount):
  310. </td>
  311. <td>
  312. @Html.TextBoxFor(x => x.ValidityParticipateCount, new TextBoxOptions() { IsEnabled = false })
  313. </td>
  314. </tr>
  315. <tr>
  316. <td>
  317. @Html.LabelFor(x => x.ValidityParticipateRate):
  318. </td>
  319. <td>
  320. @Html.TextBoxFor(x => x.ValidityParticipateRate, new TextBoxOptions() { IsEnabled = false })
  321. </td>
  322. <td>
  323. @Html.LabelFor(x => x.TotalScore):
  324. </td>
  325. <td>
  326. @Html.TextBoxFor(x => x.TotalScore, new TextBoxOptions() { IsEnabled = isEnable })
  327. </td>
  328. </tr>
  329. <tr>
  330. <td>
  331. @Html.LabelFor(x => x.Remark):
  332. </td>
  333. <td colspan="3">
  334. @if (!isEnable)
  335. {
  336. @Html.TextAreaFor(x => x.Remark, new Dictionary<string, object>
  337. {
  338. { "style", "width: 90%;min-height: 60px" },
  339. { "disabled", "true" }
  340. })
  341. }
  342. else
  343. {
  344. @Html.TextAreaFor(x => x.Remark, new Dictionary<string, object> { { "style", "width: 90%;min-height: 60px" } })
  345. }
  346. </td>
  347. </tr>
  348. </table>
  349. </div>
  350. }
  351. </div>