Edit.cshtml 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525
  1. @model EMIS.ViewModel.CultureplanManage.PlanManagement.PlanApplicationView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @{
  5. ViewBag.Title = "Edit";
  6. var isEnabled = Request["type"] == "detail" ? false : true;
  7. //年级专业
  8. ComboGridOptions cgopGrademajor = new ComboGridOptions
  9. {
  10. TextField = "Name",
  11. ValueField = "GrademajorID",
  12. OnSelect = "queryGrademajor",
  13. IsEnabled = isEnabled,
  14. GridOptions = new DataGridOptions
  15. {
  16. Columns = new List<DataGridColumn>()
  17. {
  18. new LinkButtonColumn { FieldName="Code", HeaderText="年级专业代码", Align=AlignStyle.Center, Width=0.2 },
  19. new BoundFieldColumn { FieldName="Name", HeaderText="年级专业名称", Align=AlignStyle.Center, Width=0.4 }
  20. },
  21. PageSize = 5,
  22. IsCheckOnSelect = true,
  23. DataSourceUrl = Url.Content("~/Grademajor/List"),
  24. IsPagination = true,
  25. IsShowRowNumbers = true,
  26. IsSingleSelect = false
  27. }
  28. };
  29. //课程信息
  30. ComboGridOptions cgopCourse = new ComboGridOptions
  31. {
  32. ID = "CoursematerialID",
  33. TextField = "CourseName",
  34. ValueField = "CoursematerialID",
  35. IsEnabled = isEnabled,
  36. GridOptions = new DataGridOptions
  37. {
  38. Columns = new List<DataGridColumn>()
  39. {
  40. new LinkButtonColumn { FieldName="CourseCode", HeaderText="课程代码", Align=AlignStyle.Center, Width=0.1 },
  41. new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Align=AlignStyle.Center, Width=0.2 },
  42. new BoundFieldColumn { FieldName="IsEnableName", HeaderText="是否启用", Align=AlignStyle.Center, Width=0.1, CustomFormatFun="SetRedColumn" }
  43. },
  44. IsCheckOnSelect = true,
  45. DataSourceUrl = Url.Content("~/Coursematerial/GetEnableAndUseCoursematerialView?coursematerialID=" + Model.CoursematerialID),
  46. IsPagination = true,
  47. IsShowRowNumbers = true,
  48. IsSingleSelect = false
  49. }
  50. };
  51. //教研室
  52. ComboGridOptions cgopDepartment = new ComboGridOptions
  53. {
  54. TextField = "Name",
  55. ValueField = "DepartmentID",
  56. IsEnabled = isEnabled,
  57. GridOptions = new DataGridOptions
  58. {
  59. Columns = new List<DataGridColumn>()
  60. {
  61. new LinkButtonColumn { FieldName="No", HeaderText="教研室代码", Align=AlignStyle.Center, Width=0.1 },
  62. new BoundFieldColumn { FieldName="Name", HeaderText="开课教研室", Align=AlignStyle.Center, Width=0.2 },
  63. new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("CourseCollege"), Align=AlignStyle.Center, Width=0.2 }
  64. },
  65. IsCheckOnSelect = true,
  66. DataSourceUrl = Url.Content("~/Department/List"),
  67. IsPagination = true,
  68. IsShowRowNumbers = true,
  69. IsSingleSelect = false
  70. }
  71. };
  72. //授课方式
  73. ListControlOptions lcoptm = new ListControlOptions
  74. {
  75. ID = "TeachingModeIDList",
  76. Name = "TeachingModeIDList",
  77. TextField = "Name",
  78. ValueField = "Value",
  79. ColumnCount = 4,
  80. IsEnabled = isEnabled,
  81. SelectedValueUrl = @Url.Content("~/PlanApplicationApprove/TeachingModeTypeList?planApplicationID=" + Model.PlanApplicationID)
  82. };
  83. //授课地点
  84. ListControlOptions lcoptp = new ListControlOptions
  85. {
  86. ID = "TeachingPlaceIDList",
  87. Name = "TeachingPlaceIDList",
  88. TextField = "Name",
  89. ValueField = "Value",
  90. ColumnCount = 4,
  91. IsEnabled = isEnabled,
  92. SelectedValueUrl = @Url.Content("~/PlanApplicationApprove/TeachingPlaceList?planApplicationID=" + Model.PlanApplicationID)
  93. };
  94. }
  95. @section scripts{
  96. <script src="~/Scripts/Business/CultureplanManage/PlanApplicationApproveEdit.js" type="text/javascript"></script>
  97. <script type="text/javascript">
  98. var nonSelect = "@DropdownList.SELECT_ALL";
  99. </script>
  100. }
  101. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  102. @using (Ajax.BeginForm(new AjaxOptions
  103. {
  104. OnSuccess = "EMISFunction.FormSuccess",
  105. OnBegin = "EMISFunction.FormSubmit",
  106. OnComplete = "EMISFunction.FormComplete"
  107. }))
  108. {
  109. <div class="p_title">
  110. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;"></div>
  111. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">
  112. @*@if (Request["type"] != "detail")
  113. {
  114. @Html.ContextMenuBar("Edit")
  115. }*@
  116. </div>
  117. </div>
  118. <div class="search_list">
  119. @Html.HiddenFor(x => x.PlanApplicationID)
  120. <table cellpadding="0" cellspacing="0" id="specialtyCourseable">
  121. <tr>
  122. <td style="color: red;">
  123. @Html.LabelFor(x => x.SchoolyearCode):
  124. </td>
  125. <td>
  126. @Html.DropdownListFor((x => x.SchoolyearID), new DropdownListOptions
  127. {
  128. BindType = DropdownListBindType.PleaseSelect,
  129. TextField = "Text",
  130. ValueField = "Value",
  131. IsEnabled = isEnabled,
  132. ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid")
  133. })
  134. </td>
  135. <td style="color:red;">
  136. @Html.LabelFor(x => x.GrademajorName):
  137. </td>
  138. <td>
  139. @Html.ComboGridFor(x => x.GrademajorID, cgopGrademajor)
  140. </td>
  141. </tr>
  142. <tr>
  143. <td>
  144. @Html.LabelFor(x => x.GradeID):
  145. </td>
  146. <td>
  147. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Grade, (x => x.GradeID), new DropdownListOptions() { IsEnabled = false })
  148. </td>
  149. <td>
  150. @Html.LabelFor(x => x.StandardCode):
  151. </td>
  152. <td>
  153. @Html.TextBoxFor(x => x.StandardCode, new TextBoxOptions() { IsEnabled = false })
  154. </td>
  155. </tr>
  156. <tr>
  157. <td>
  158. @Html.LabelFor(x => x.StandardName):
  159. </td>
  160. <td>
  161. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Standard, (x => x.StandardID), new DropdownListOptions() { IsEnabled = false })
  162. </td>
  163. <td>
  164. @Html.LabelFor(x => x.EducationID):
  165. </td>
  166. <td>
  167. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Education, (x => x.EducationID), new DropdownListOptions() { IsEnabled = false })
  168. </td>
  169. </tr>
  170. <tr>
  171. <td>
  172. @Html.LabelFor(x => x.LearningformID):
  173. </td>
  174. <td>
  175. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Learningform, (x => x.LearningformID), new DropdownListOptions() { IsEnabled = false })
  176. </td>
  177. <td>
  178. @Html.LabelFor(x => x.LearnSystem):
  179. </td>
  180. <td>
  181. @Html.TextBoxFor(x => x.LearnSystem, new TextBoxOptions() { IsEnabled = false })
  182. </td>
  183. </tr>
  184. <tr>
  185. <td style="color:red;">
  186. @Html.LabelFor(x => x.CourseName):
  187. </td>
  188. <td>
  189. @Html.ComboGridFor(x => x.CoursematerialID, cgopCourse)
  190. </td>
  191. <td style="color:red;">
  192. @Html.LabelFor(x => x.DepartmentName):
  193. </td>
  194. <td>
  195. @Html.ComboGridFor(x => x.DepartmentID, cgopDepartment)
  196. </td>
  197. </tr>
  198. <tr>
  199. <td>
  200. @Html.LabelFor(x => x.CourseStructureName):
  201. </td>
  202. <td>
  203. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseStructure, x => x.CourseStructureID, new DropdownListOptions() { IsEnabled = isEnabled })
  204. </td>
  205. <td>
  206. @Html.LabelFor(x => x.CourseCategoryName):
  207. </td>
  208. <td>
  209. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseCategory, x => x.CourseCategoryID, new DropdownListOptions() { IsEnabled = isEnabled })
  210. </td>
  211. </tr>
  212. <tr>
  213. <td style="color:red;">
  214. @Html.LabelFor(x => x.CourseTypeName):
  215. </td>
  216. <td>
  217. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseType, x => x.CourseTypeID, new DropdownListOptions() { IsEnabled = isEnabled })
  218. </td>
  219. <td>
  220. @Html.LabelFor(x => x.CourseQualityName):
  221. </td>
  222. <td>
  223. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseQuality, x => x.CourseQualityID, new DropdownListOptions() { IsEnabled = isEnabled })
  224. </td>
  225. </tr>
  226. <tr>
  227. <td colspan="4" style="padding:1px;height:10px;">
  228. <div id="teachingSettingExpander" style="width: 16px; float: left; height: 16px; cursor: pointer;
  229. background: url('../../Content/Bowin.Control.Core/themes/metro-blue/images/tree_icons.png') no-repeat -32px 0;"
  230. onclick="swapTeachingSetting();">
  231. </div>
  232. <div style="float: left;height: 10px; cursor: pointer; color: red;" onclick="swapTeachingSetting();">
  233. 教学设置信息
  234. </div>
  235. </td>
  236. </tr>
  237. <tr>
  238. <td style="color:red;">
  239. @Html.LabelFor(x => x.Credit):
  240. </td>
  241. <td>
  242. @Html.TextBoxFor(x => x.Credit, new TextBoxOptions() { IsEnabled = isEnabled })
  243. </td>
  244. <td style="color:red;">
  245. @Html.LabelFor(x => x.HandleModeName):
  246. </td>
  247. <td>
  248. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_HandleMode, (x => x.HandleModeID), new DropdownListOptions() { IsEnabled = isEnabled })
  249. </td>
  250. </tr>
  251. <tr>
  252. <td>
  253. @Html.LabelFor(x => x.TheoryCourse):
  254. </td>
  255. <td>
  256. @Html.TextBoxFor(x => x.TheoryCourse, new TextBoxOptions() { IsEnabled = isEnabled })
  257. </td>
  258. <td>
  259. @Html.LabelFor(x => x.Practicehours):
  260. </td>
  261. <td>
  262. @Html.TextBoxFor(x => x.Practicehours, new TextBoxOptions() { IsEnabled = isEnabled })
  263. </td>
  264. </tr>
  265. <tr>
  266. <td>
  267. @Html.LabelFor(x => x.Trialhours):
  268. </td>
  269. <td>
  270. @Html.TextBoxFor(x => x.Trialhours, new TextBoxOptions() { IsEnabled = isEnabled })
  271. </td>
  272. <td>
  273. @Html.LabelFor(x => x.Totalhours):
  274. </td>
  275. <td>
  276. @Html.TextBoxFor(x => x.Totalhours, new TextBoxOptions { IsEnabled = false })
  277. </td>
  278. </tr>
  279. <tr>
  280. <td>
  281. @Html.LabelFor(x => x.TheoryWeeklyNum):
  282. </td>
  283. <td>
  284. @Html.TextBoxFor(x => x.TheoryWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
  285. </td>
  286. <td>
  287. @Html.LabelFor(x => x.PracticeWeeklyNum):
  288. </td>
  289. <td>
  290. @Html.TextBoxFor(x => x.PracticeWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
  291. </td>
  292. </tr>
  293. <tr>
  294. <td>
  295. @Html.LabelFor(x => x.TrialWeeklyNum):
  296. </td>
  297. <td>
  298. @Html.TextBoxFor(x => x.TrialWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
  299. </td>
  300. <td>
  301. @Html.LabelFor(x => x.SchoolweeksNum):
  302. </td>
  303. <td>
  304. @Html.TextBoxFor(x => x.SchoolweeksNum, new TextBoxOptions { IsEnabled = false })
  305. </td>
  306. </tr>
  307. <tr>
  308. <td style="color:red;">
  309. @Html.LabelFor(x => x.WeeklyHours):
  310. </td>
  311. <td>
  312. @Html.TextBoxFor(x => x.WeeklyHours, new TextBoxOptions() { IsEnabled = isEnabled })
  313. </td>
  314. <td style="color:red;">
  315. @Html.LabelFor(x => x.WeeklyNum):
  316. </td>
  317. <td>
  318. @Html.TextBoxFor(x => x.WeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
  319. </td>
  320. </tr>
  321. <tr>
  322. <td>
  323. @Html.LabelFor(x => x.StartWeeklyNum):
  324. </td>
  325. <td>
  326. @Html.TextBoxFor(x => x.StartWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
  327. </td>
  328. <td>
  329. @Html.LabelFor(x => x.EndWeeklyNum):
  330. </td>
  331. <td>
  332. @Html.TextBoxFor(x => x.EndWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
  333. </td>
  334. </tr>
  335. <tr>
  336. <td colspan="4" style="padding:1px;height:10px;">
  337. <div id="otherExpander" style="width: 16px; float: left; height: 16px; cursor: pointer;
  338. background: url('../../Content/Bowin.Control.Core/themes/metro-blue/images/tree_icons.png') no-repeat -32px 0;"
  339. onclick="swapother();">
  340. </div>
  341. <div style="float: left;height: 10px; cursor: pointer; color: red;" onclick="swapother();">
  342. 其它信息
  343. </div>
  344. </td>
  345. </tr>
  346. <tr>
  347. <td>
  348. @Html.LabelFor(x => x.IsSpecialtycore):
  349. </td>
  350. <td>
  351. @if (Request["type"] == "detail")
  352. {
  353. @Html.CheckBoxFor(x => x.IsSpecialtycore, new Dictionary<string, object>() { { "disabled", isEnabled } })
  354. }
  355. else
  356. {
  357. @Html.CheckBoxFor(x => x.IsSpecialtycore)
  358. }
  359. </td>
  360. <td>
  361. @Html.LabelFor(x => x.IsCooperation):
  362. </td>
  363. <td>
  364. @if (Request["type"] == "detail")
  365. {
  366. @Html.CheckBoxFor(x => x.IsCooperation, new Dictionary<string, object>() { { "disabled", isEnabled } })
  367. }
  368. else
  369. {
  370. @Html.CheckBoxFor(x => x.IsCooperation)
  371. }
  372. </td>
  373. </tr>
  374. <tr>
  375. <td>
  376. @Html.LabelFor(x => x.IsRequired):
  377. </td>
  378. <td>
  379. @if (Request["type"] == "detail")
  380. {
  381. @Html.CheckBoxFor(x => x.IsRequired, new Dictionary<string, object>() { { "disabled", isEnabled } })
  382. }
  383. else
  384. {
  385. @Html.CheckBoxFor(x => x.IsRequired)
  386. }
  387. </td>
  388. <td>
  389. @Html.LabelFor(x => x.IsElective):
  390. </td>
  391. <td>
  392. @if (Request["type"] == "detail")
  393. {
  394. @Html.CheckBoxFor(x => x.IsElective, new Dictionary<string, object>() { { "disabled", isEnabled } })
  395. }
  396. else
  397. {
  398. @Html.CheckBoxFor(x => x.IsElective)
  399. }
  400. </td>
  401. </tr>
  402. <tr>
  403. <td>
  404. @Html.LabelFor(x => x.IsNetworkCourse):
  405. </td>
  406. <td>
  407. @if (Request["type"] == "detail")
  408. {
  409. @Html.CheckBoxFor(x => x.IsNetworkCourse, new Dictionary<string, object>() { { "disabled", isEnabled } })
  410. }
  411. else
  412. {
  413. @Html.CheckBoxFor(x => x.IsNetworkCourse)
  414. }
  415. </td>
  416. <td>
  417. @Html.LabelFor(x => x.IsMainCourse):
  418. </td>
  419. <td>
  420. @if (Request["type"] == "detail")
  421. {
  422. @Html.CheckBoxFor(x => x.IsMainCourse, new Dictionary<string, object>() { { "disabled", isEnabled } })
  423. }
  424. else
  425. {
  426. @Html.CheckBoxFor(x => x.IsMainCourse)
  427. }
  428. </td>
  429. </tr>
  430. <tr>
  431. <td>
  432. @Html.LabelFor(x => x.IsNeedMaterial):
  433. </td>
  434. <td>
  435. @if (Request["type"] == "detail")
  436. {
  437. @Html.CheckBoxFor(x => x.IsNeedMaterial, new Dictionary<string, object>() { { "disabled", isEnabled } })
  438. }
  439. else
  440. {
  441. @Html.CheckBoxFor(x => x.IsNeedMaterial)
  442. }
  443. </td>
  444. <td>
  445. @Html.LabelFor(x => x.CourseFineID):
  446. </td>
  447. <td>
  448. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseFine, x => x.CourseFineID, new DropdownListOptions() { IsEnabled = isEnabled })
  449. </td>
  450. </tr>
  451. <tr>
  452. <td>
  453. @Html.LabelFor(x => x.PracticeTypeID):
  454. </td>
  455. <td>
  456. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.EM_PracticeType, x => x.PracticeTypeID, new DropdownListOptions() { IsEnabled = isEnabled })
  457. </td>
  458. <td>
  459. @Html.LabelFor(x => x.TeachinglanguageID):
  460. </td>
  461. <td>
  462. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Teachinglanguage, x => x.TeachinglanguageID, new DropdownListOptions() { IsEnabled = isEnabled })
  463. </td>
  464. </tr>
  465. <tr>
  466. <td>
  467. @Html.LabelFor(x => x.ExaminationModeID):
  468. </td>
  469. <td>
  470. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ExaminationMode, x => x.ExaminationModeID, new DropdownListOptions() { IsEnabled = isEnabled })
  471. </td>
  472. <td>
  473. @Html.LabelFor(x=>x.ResultTypeID):
  474. </td>
  475. <td>
  476. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ResultType, (x => x.ResultTypeID), new DropdownListOptions() { IsEnabled = isEnabled })
  477. </td>
  478. </tr>
  479. <tr>
  480. <td>
  481. @Html.LabelFor(x => x.TeachingModeIDList):
  482. </td>
  483. <td colspan="3">
  484. @Html.DictionaryCheckList(EMIS.ViewModel.DictionaryItem.CF_TeachingMode, lcoptm)
  485. </td>
  486. </tr>
  487. <tr>
  488. <td>
  489. @Html.LabelFor(x => x.TeachingPlaceIDList):
  490. </td>
  491. <td colspan="3">
  492. @Html.DictionaryCheckList(EMIS.ViewModel.DictionaryItem.EM_TeachingPlace, lcoptp)
  493. </td>
  494. </tr>
  495. <tr>
  496. <td>
  497. @Html.LabelFor(x => x.Remark):
  498. </td>
  499. <td colspan="3">
  500. @if (Request["type"] == "detail")
  501. {
  502. @Html.TextAreaFor(x => x.Remark, new Dictionary<string, object>
  503. {
  504. { "style", "width: 90%;min-height: 18px" },
  505. { "disabled", "true" }
  506. })
  507. }
  508. else
  509. {
  510. @Html.TextAreaFor(x => x.Remark, new Dictionary<string, object>
  511. {
  512. { "style", "width: 90%;min-height: 18px" }
  513. })
  514. }
  515. </td>
  516. </tr>
  517. </table>
  518. </div>
  519. }
  520. </div>