Details.cshtml 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469
  1. @model EMIS.ViewModel.SelectCourse.ExecutableFreeSelectionCouseView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @{
  5. ViewBag.Title = "Details";
  6. ComboGridOptions cgopDepartment = new ComboGridOptions
  7. {
  8. TextField = "Name",
  9. ValueField = "DepartmentID",
  10. GridOptions = new DataGridOptions
  11. {
  12. Columns = new List<DataGridColumn>()
  13. {
  14. new BoundFieldColumn { FieldName="Name", HeaderText="教研室名称", Align=AlignStyle.Center, Width=0.3 }
  15. //new LinkButtonColumn { FieldName="No", HeaderText="教研室代码", Align=AlignStyle.Center, Width=0.1 }
  16. //new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("College"), Align=AlignStyle.Center, Width=0.3 }
  17. },
  18. IsCheckOnSelect = true,
  19. DataSourceUrl = Url.Content("~/Department/List"),
  20. IsPagination = true,
  21. IsShowRowNumbers = true,
  22. IsSingleSelect = false
  23. }
  24. };
  25. ComboGridOptions cgop = new ComboGridOptions
  26. {
  27. TextField = "Name",
  28. ValueField = "ClassroomID",
  29. GridOptions = new DataGridOptions
  30. {
  31. Columns = new List<DataGridColumn>()
  32. {
  33. new LinkButtonColumn { FieldName="Code", HeaderText="教室代码", Align=AlignStyle.Center, Width=0.1 },
  34. new BoundFieldColumn { FieldName="Name", HeaderText="教室名称", Align=AlignStyle.Center, Width=0.12 },
  35. new BoundFieldColumn { FieldName="ClassroomTypeName", HeaderText="教室类型", Align=AlignStyle.Center, Width=0.12 },
  36. new BoundFieldColumn { FieldName="Totalseating", HeaderText="总座位数", Align=AlignStyle.Center, Width=0.1 },
  37. },
  38. IsCheckOnSelect = true,
  39. // DataSourceUrl = Url.Content("~/CollegeClassroom/ClassroomListComboGrid?collegeID=" + Model.CollegeID),
  40. DataSourceUrl = Url.Content("~/Classroom/List"),//去除院系条件
  41. IsPagination = true,
  42. IsShowRowNumbers = true,
  43. IsSingleSelect = false
  44. }
  45. };
  46. ComboGridOptions cgopCoursesTime = new ComboGridOptions
  47. {
  48. TextField = "TimesSegmentName",
  49. ValueField = "CoursesTimeID",
  50. GridOptions = new DataGridOptions
  51. {
  52. Columns = new List<DataGridColumn>()
  53. {
  54. new CheckBoxFieldColumn{ HeaderText="", FieldName="CoursesTimeID"},
  55. new BoundFieldColumn { FieldName="Times", HeaderText="节次", Align=AlignStyle.Center, Width=0.02 },
  56. new BoundFieldColumn { FieldName="TimesSegmentName", HeaderText="时间段", Align=AlignStyle.Center, Width=0.04 },
  57. new BoundFieldColumn { FieldName="StartDate", HeaderText="开始时间", CustomFormatFun="formatStartTime", Align=AlignStyle.Center, Width=0.05 },
  58. new BoundFieldColumn { FieldName="EndDate", HeaderText="结束时间", CustomFormatFun="formatEndTime", Align=AlignStyle.Center, Width=0.05 }
  59. },
  60. IsCheckOnSelect = true,
  61. // DataSourceUrl = Url.Content("~/CollegeClassroom/ClassroomListComboGrid?collegeID=" + Model.CollegeID),
  62. DataSourceUrl = Url.Content("~/CoursesTime/List"),//去除院系条件
  63. IsPagination = true,
  64. IsShowRowNumbers = true,
  65. IsSingleSelect = false
  66. }
  67. };
  68. ListControlOptions lcop = new ListControlOptions
  69. {
  70. Name = "TeachingModeID",
  71. TextField = "Name",
  72. ValueField = "Value",
  73. ColumnCount = 4,
  74. SelectedValueUrl = @Url.Content("~/ExecutableFreeSelectionCouse/TeachingModeType?ExecutableFreeSelectionCouseID=" + Model.ExecutableFreeSelectionCouseID)
  75. };
  76. ListControlOptions lcopGrade = new ListControlOptions
  77. {
  78. Name = "GradeYear",
  79. TextField = "Name",
  80. ValueField = "Value",
  81. ColumnCount = 4,
  82. SelectedValueUrl = @Url.Content("~/ExecutableFreeSelectionCouse/GradeYear?ExecutableFreeSelectionCouseID=" + Model.ExecutableFreeSelectionCouseID)
  83. };
  84. }
  85. @section scripts{
  86. <script src="~/Scripts/Business/SelectCourseManage/ExecutableFreeSelectionCouseEdit.js"
  87. type="text/javascript">
  88. </script>
  89. <script type="text/javascript">
  90. $(function () {
  91. $("#Credit").val(parseFloat($("#Credit").val()).toFixed(1));
  92. setStartEndWeeklyNum();
  93. });
  94. function setStartEndWeeklyNum() {
  95. if ($("#StartWeeklyNum").val() != "" && $("#EndWeeklyNum").val() != "")
  96. $("#StartEndWeeklyNum").val($("#StartWeeklyNum").val() + "-" + $("#EndWeeklyNum").val());
  97. }
  98. //function reload() { }
  99. </script>
  100. }
  101. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  102. @using (Ajax.BeginForm(new AjaxOptions { HttpMethod = "Post", OnSuccess = "EMISFunction.FormSuccess" }))
  103. {
  104. <div class="p_title">
  105. @*<div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
  106. 任选设定信息</div>*@
  107. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">
  108. </div>
  109. </div>
  110. <div class="search_list">
  111. @Html.HiddenFor(x => x.ExecutableFreeSelectionCouseID)
  112. <table cellpadding="0" cellspacing="0">
  113. <tr>
  114. <td>
  115. @Html.LabelFor(x => x.DefaultClassName):
  116. </td>
  117. <td colspan="3">
  118. @Html.TextBoxFor(x => x.DefaultClassName, new Dictionary<string, object> { { "style", "width:85%;" } })
  119. </td>
  120. </tr>
  121. <tr>
  122. <td>
  123. @Html.LabelFor(x => x.SchoolyearCode):
  124. </td>
  125. <td>
  126. @Html.TextBoxFor(x => x.SchoolyearCode, new TextBoxOptions { IsEnabled = false })
  127. </td>
  128. <td>
  129. @Html.LabelFor(x => x.CourseName):
  130. </td>
  131. <td>
  132. @Html.TextBoxFor(x => x.CourseName, new TextBoxOptions { IsEnabled = false })
  133. </td>
  134. </tr>
  135. <tr>
  136. <td>
  137. @Html.LabelFor(x => x.CourseTypeID):
  138. </td>
  139. <td>
  140. @Html.TextBoxFor(x => x.CourseTypeName, new TextBoxOptions { IsEnabled = false })
  141. </td>
  142. <td>
  143. @Html.LabelFor(x => x.DepartmentName):
  144. </td>
  145. <td>
  146. @Html.TextBoxFor(x => x.DepartmentName, new TextBoxOptions { IsEnabled = false })
  147. </td>
  148. </tr>
  149. <tr>
  150. <td>
  151. @Html.LabelFor(x => x.CourseStructureID):
  152. </td>
  153. <td>
  154. @Html.TextBoxFor(x => x.CourseStructureName, new TextBoxOptions { IsEnabled = false })
  155. </td>
  156. <td>
  157. @Html.LabelFor(x => x.CourseCategoryID):
  158. </td>
  159. <td>
  160. @Html.TextBoxFor(x => x.CourseCategoryName, new TextBoxOptions { IsEnabled = false })
  161. </td>
  162. </tr>
  163. <tr>
  164. <td>
  165. @Html.LabelFor(x => x.CourseQualityID):
  166. </td>
  167. <td>
  168. @Html.TextBoxFor(x => x.CourseQualityName, new TextBoxOptions { IsEnabled = false })
  169. </td>
  170. <td>
  171. @Html.LabelFor(x => x.TeachinglanguageID):
  172. </td>
  173. <td>
  174. @Html.TextBoxFor(x => x.TeachinglanguageName, new TextBoxOptions { IsEnabled = false })
  175. </td>
  176. </tr>
  177. <tr>
  178. <td>
  179. @Html.LabelFor(x => x.ExaminationModeID):
  180. </td>
  181. <td>
  182. @Html.TextBoxFor(x => x.ExaminationModeName, new TextBoxOptions { IsEnabled = false })
  183. </td>
  184. <td>@Html.LabelFor(x=>x.ResultTypeID)
  185. </td>
  186. <td>@Html.TextBoxFor(x => x.ResultTypeName, new TextBoxOptions { IsEnabled = false })
  187. </td>
  188. </tr>
  189. @*<tr>
  190. <td>@Html.LabelFor(x => x.SchoolyearNumID):
  191. </td>
  192. <td>@Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_SchoolyearNum, x => x.SchoolyearNumID, null, new Dictionary<string, string> { { "disabled", "disabled" } })
  193. </td>
  194. <td>@Html.LabelFor(x => x.SchoolcodeID):
  195. </td>
  196. <td>@Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Semester, x => x.SchoolcodeID, null, new Dictionary<string, string> { { "disabled", "disabled" } })
  197. </td>
  198. </tr>*@
  199. <tr>
  200. <td>
  201. @Html.LabelFor(x => x.PracticeTypeID):
  202. </td>
  203. <td>
  204. @Html.TextBoxFor(x => x.PracticeTypeName, new TextBoxOptions { IsEnabled = false })
  205. </td>
  206. <td>
  207. @Html.LabelFor(x => x.IsNeedMaterial):
  208. </td>
  209. <td>
  210. @Html.CheckBoxFor(x => x.IsNeedMaterial)
  211. </td>
  212. </tr>
  213. <tr>
  214. <td>
  215. @Html.LabelFor(x => x.HandleModeID):
  216. </td>
  217. <td>
  218. @Html.TextBoxFor(x => x.HandleModeName, new TextBoxOptions { IsEnabled = false })
  219. </td>
  220. <td>
  221. @Html.LabelFor(x => x.PeopleNumlower):
  222. </td>
  223. <td>
  224. @Html.TextBoxFor(x => x.PeopleNumlower, new TextBoxOptions { IsEnabled = false })
  225. </td>
  226. </tr>
  227. <tr>
  228. <td>
  229. @Html.LabelFor(x => x.Credit):
  230. </td>
  231. <td>
  232. @Html.TextBoxFor(x => x.Credit, new TextBoxOptions { IsEnabled = false })
  233. </td>
  234. <td>
  235. @Html.LabelFor(x => x.PeopleNumlimit):
  236. </td>
  237. <td>
  238. @Html.TextBoxFor(x => x.PeopleNumlimit, new TextBoxOptions { IsEnabled = false })
  239. </td>
  240. </tr>
  241. <tr>
  242. <td>
  243. @Html.LabelFor(x => x.TheoryCourse):
  244. </td>
  245. <td>
  246. @Html.TextBoxFor(x => x.TheoryCourse, new TextBoxOptions { IsEnabled = false })
  247. </td>
  248. <td>
  249. @Html.LabelFor(x => x.Practicehours):
  250. </td>
  251. <td>
  252. @Html.TextBoxFor(x => x.Practicehours, new TextBoxOptions { IsEnabled = false })
  253. </td>
  254. </tr>
  255. <tr>
  256. <td>
  257. @Html.LabelFor(x => x.Trialhours):
  258. </td>
  259. <td>
  260. @Html.TextBoxFor(x => x.Trialhours, new TextBoxOptions { IsEnabled = false })
  261. </td>
  262. <td>
  263. @Html.LabelFor(x => x.Totalhours):
  264. </td>
  265. <td>
  266. @Html.TextBoxFor(x => x.Totalhours, new TextBoxOptions { IsEnabled = false })
  267. </td>
  268. </tr>
  269. <tr>
  270. <td colspan="4">
  271. <div id="weekExpander" style="width: 16px; float: left; height: 16px; cursor: pointer;
  272. background: url('../../Content/Bowin.Control.Core/themes/metro-blue/images/tree_icons.png') no-repeat -50px 0;"
  273. onclick="swapWeekSettings();">
  274. </div>
  275. <div style="float: left; cursor: pointer; color: red;" onclick="swapWeekSettings();">
  276. 上课周次信息
  277. </div>
  278. </td>
  279. </tr>
  280. <tr style="display: ">
  281. <td>@Html.LabelFor(x => x.TheoryWeeklyNum):
  282. </td>
  283. <td>@Html.TextBoxFor(x => x.TheoryWeeklyNum, new TextBoxOptions { IsEnabled = false })
  284. </td>
  285. <td>@Html.LabelFor(x => x.PracticeWeeklyNum):
  286. </td>
  287. <td>@Html.TextBoxFor(x => x.PracticeWeeklyNum, new TextBoxOptions { IsEnabled = false })
  288. </td>
  289. </tr>
  290. <tr style="display: ">
  291. <td>@Html.LabelFor(x => x.TrialWeeklyNum):
  292. </td>
  293. <td>@Html.TextBoxFor(x => x.TrialWeeklyNum, new TextBoxOptions { IsEnabled = false })
  294. </td>
  295. <td>@Html.LabelFor(x => x.SchoolweeksNum):
  296. </td>
  297. <td>@Html.TextBoxFor(x => x.SchoolweeksNum, new TextBoxOptions { IsEnabled = false })
  298. </td>
  299. </tr>
  300. <tr style="display: ">
  301. <td>@Html.LabelFor(x => x.StartWeeklyNum):
  302. </td>
  303. <td>@Html.TextBoxFor(x => x.StartWeeklyNum, new TextBoxOptions { IsEnabled = false })
  304. </td>
  305. <td>@Html.LabelFor(x => x.EndWeeklyNum):
  306. </td>
  307. <td>@Html.TextBoxFor(x => x.EndWeeklyNum, new TextBoxOptions { IsEnabled = false })
  308. </td>
  309. </tr>
  310. <tr style="display: ">
  311. <td>@Html.LabelFor(x => x.WeeklyHours):
  312. </td>
  313. <td>@Html.TextBoxFor(x => x.WeeklyHours, new TextBoxOptions { IsEnabled = false })
  314. </td>
  315. <td>@Html.LabelFor(x => x.WeeklyNum):
  316. </td>
  317. <td>@Html.TextBoxFor(x => x.WeeklyNum, new TextBoxOptions { IsEnabled = false })
  318. </td>
  319. </tr>
  320. @*<tr>
  321. <td>
  322. @Html.LabelFor(x => x.Weekday):
  323. </td>
  324. <td>
  325. @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.ES_WeekDay, (x => x.Weekday))
  326. </td>
  327. <td>
  328. @Html.LabelFor(x => x.CoursesTimeID):
  329. </td>
  330. <td>
  331. @Html.ComboGridFor(x => x.CoursesTimeID, cgopCoursesTime)
  332. </td>
  333. </tr> *@
  334. <tr>
  335. <td>
  336. @Html.LabelFor(x => x.StartEndWeeklyNum):
  337. </td>
  338. <td>
  339. @Html.TextBoxFor(x => x.StartEndWeeklyNum, new TextBoxOptions { IsEnabled = false })
  340. </td>
  341. <td>
  342. @Html.LabelFor(x => x.ClassroomName):
  343. </td>
  344. <td>
  345. @Html.TextBoxFor(x => x.ClassroomName, new TextBoxOptions { IsEnabled = false })
  346. </td>
  347. </tr>
  348. <tr>
  349. <td>
  350. @Html.LabelFor(x => x.Scheduling):
  351. </td>
  352. <td colspan="3">
  353. @*@Html.ContextMenuBar("Edit-SchedulingGrid")*@
  354. @Html.DataGrid(new DataGridOptions
  355. {
  356. Columns = new List<DataGridColumn>()
  357. {
  358. new CheckBoxFieldColumn { FieldName="ExecutableFreeSelectionCouseSchedulingID" },
  359. new DictionaryDropdownListColumn { HeaderText="授课星期", FieldName="Weekday", DictionaryType=EMIS.ViewModel.DictionaryItem.ES_WeekDay,Width=80 },
  360. new TriggerBoxColumn { HeaderText="节次", FieldName="CoursesTimeID", TextFieldName="Times", TargetTextFieldName="Times", TargetFieldName="CoursesTimeID", TriggerHandle="",Width=80 },
  361. //new DictionaryDropdownListColumn { HeaderText="教室类型", FieldName="ClassroomTypeID", DictionaryType=EMIS.ViewModel.DictionaryItem.CF_ClassroomType,Width=80 },
  362. //new TriggerBoxColumn { HeaderText="教室", FieldName="ClassroomID", TextFieldName="ClassroomName", TargetTextFieldName="Name", TargetFieldName="ClassroomID", TriggerHandle="selectClassroom",Width=80 }
  363. },
  364. PageSize = 5,
  365. IsPostBack = true,
  366. IsCheckOnSelect = true,
  367. DataSourceUrl = Url.Content("~/ExecutableFreeSelectionCouse/GetSchedulingViewList?ExecutableFreeSelectionCouseID=" + Model.ExecutableFreeSelectionCouseID),
  368. ID = "dgSchedulingList",
  369. //OnLoadSuccessFun = "SetTotalView",
  370. IsPagination = true,
  371. IsShowRowNumbers = true,
  372. IsSingleSelect = false,
  373. MaxHeight = 110
  374. })
  375. </td>
  376. </tr>
  377. <tr>
  378. <td>
  379. @Html.LabelFor(x => x.GradeYear):
  380. </td>
  381. <td colspan="3">
  382. @Html.DictionaryCheckList(EMIS.ViewModel.DictionaryItem.CF_SchoolyearNum, lcopGrade)
  383. </td>
  384. </tr>
  385. <tr>
  386. <td>
  387. @Html.LabelFor(x => x.SpecialtyID):
  388. </td>
  389. <td colspan="3">
  390. @*@Html.ContextMenuBar("Edit-SpecialtyGrid")*@
  391. @Html.DataGrid(new DataGridOptions
  392. {
  393. Columns = new List<DataGridColumn>()
  394. {
  395. new CheckBoxFieldColumn{ HeaderText="", FieldName="SpecialtyID" },
  396. new BoundFieldColumn { FieldName="Code", HeaderText="专业代码", Align=AlignStyle.Center, Width=0.04 },
  397. new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Align=AlignStyle.Center, Width=0.1 },
  398. new BoundFieldColumn { FieldName="LearnSystem", HeaderText="学制", Align=AlignStyle.Center, Width=0.03 },
  399. new BoundFieldColumn { FieldName="EducationName", HeaderText=EMIS.Utility.RSL.Get("EducationID"), Align=AlignStyle.Center, Width=0.04 },
  400. new BoundFieldColumn { FieldName="LearningformName", HeaderText="学习形式", Align=AlignStyle.Center, Width=0.04 }
  401. //new BoundFieldColumn { FieldName="ScienceclassName", HeaderText="专业科类", Align=AlignStyle.Center, Width=0.04 },
  402. //new BoundFieldColumn { FieldName="PropertyName", HeaderText="专业属性", Align=AlignStyle.Center, Width=0.04 },
  403. //new BoundFieldColumn { FieldName="StandardTitleName", HeaderText="专业称号", Align=AlignStyle.Center, Width=0.04 },
  404. //new BoundFieldColumn { FieldName="StandardLevelName", HeaderText="称号级别", Align=AlignStyle.Center, Width=0.04 }
  405. },
  406. PageSize =20,
  407. IsCheckOnSelect = true,
  408. DataSourceUrl = Url.Content("~/ExecutableFreeSelectionCouse/SpecialtyList?ExecutableFreeSelectionCouseID=" + Request["ExecutableFreeSelectionCouseID"]),
  409. IsPostBack = true,
  410. ID = "dgSpecialtyList",
  411. IsPagination = true,
  412. IsShowRowNumbers = true,
  413. IsSingleSelect = false
  414. })
  415. </td>
  416. </tr>
  417. <tr>
  418. <td>@Html.LabelFor(x => x.Teachers):
  419. </td>
  420. <td colspan="3">
  421. @* @Html.ContextMenuBar("Edit-TeacherGrid")*@
  422. @Html.DataGrid(new DataGridOptions
  423. {
  424. Columns = new List<DataGridColumn>()
  425. {
  426. new CheckBoxFieldColumn { FieldName="UserID" },
  427. new BoundFieldColumn { FieldName="LoginID", HeaderText="教职工号", Align=AlignStyle.Center, Width=0.04 },
  428. new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Align=AlignStyle.Center, Width=0.04 },
  429. new DictionaryDropdownListColumn { FieldName="TeachingMethod", HeaderText="任课方式", Align=AlignStyle.Center, Width=0.04,
  430. DictionaryType = EMIS.ViewModel.DictionaryItem.EM_TeachingMethod }
  431. },
  432. PageSize = 3,
  433. IsCheckOnSelect = true,
  434. DataSourceUrl = Url.Content("~/ExecutableFreeSelectionCouse/TeacherList?ExecutableFreeSelectionCouseID=" + Request["ExecutableFreeSelectionCouseID"]),
  435. IsPostBack = true,
  436. ID = "dgTeacherList",
  437. IsPagination = true,
  438. IsShowRowNumbers = true,
  439. IsSingleSelect = false,
  440. MaxHeight = 65
  441. })
  442. </td>
  443. </tr>
  444. <tr>
  445. <td>
  446. @Html.LabelFor(x => x.TeachingModeID):
  447. </td>
  448. <td colspan="3">
  449. @Html.DictionaryCheckList(EMIS.ViewModel.DictionaryItem.CF_TeachingMode, lcop)
  450. </td>
  451. </tr>
  452. <tr>
  453. <td>
  454. @Html.LabelFor(x => x.Remarks):
  455. </td>
  456. <td colspan="3">
  457. @Html.TextAreaFor(x => x.Remarks, new Dictionary<string, object> { { "style", "width:85%;" } })
  458. </td>
  459. </tr>
  460. </table>
  461. </div>
  462. }
  463. </div>