Cancel.cshtml 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221
  1. @model EMIS.ViewModel.StudentManage.StudentProfile.StudentEncourageView
  2. @using EMIS.Web.Controls;
  3. @using Bowin.Web.Controls.Mvc;
  4. @{
  5. ViewBag.Title = "Cancel";
  6. var isEnable = (Request["studentEncourageID"] ?? "") == "";
  7. //学生信息
  8. ComboGridOptions cgopStudent = new ComboGridOptions
  9. {
  10. TextField = "StudentNo",
  11. ValueField = "UserID",
  12. OnSelect = "queryStudent",
  13. IsEnabled = isEnable,
  14. GridOptions = new DataGridOptions
  15. {
  16. Columns = new List<DataGridColumn>()
  17. {
  18. new LinkButtonColumn { FieldName="StudentNo", HeaderText="学号", Width=0.2, Align=AlignStyle.Center },
  19. new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Width=0.08, Align=AlignStyle.Center },
  20. new BoundFieldColumn { FieldName="SexName", HeaderText="性别", Width=0.06, Align=AlignStyle.Center, OrderFieldName="SexID" },
  21. //new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Width=0.1, Align=AlignStyle.Center, OrderFieldName="StandardID", OverflowLength=6 },
  22. new BoundFieldColumn { FieldName="ClassmajorName", HeaderText="班级名称", Width=0.06, Align=AlignStyle.Center, OverflowLength=6 },
  23. //new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Width=0.1, Align=AlignStyle.Center, OverflowLength=6 },
  24. new BoundFieldColumn { FieldName="InSchoolStatusName", HeaderText="在校状态", Width=0.1, Align=AlignStyle.Center, OrderFieldName="InSchoolStatusID", CustomFormatFun="SetRedColumn" }
  25. //new BoundFieldColumn { FieldName="StudentStatusName", HeaderText="学籍状态", Width=0.1, Align=AlignStyle.Center, OrderFieldName="StudentStatus", CustomFormatFun="SetRedColumn" }
  26. },
  27. PageSize = 10,
  28. IsCheckOnSelect = true,
  29. DataSourceUrl = Url.Content("~/Student/StudentBaseInSchoolList?userID=" + Model.UserID),
  30. IsPagination = true,
  31. IsShowRowNumbers = true,
  32. IsSingleSelect = false
  33. }
  34. };
  35. //班级信息
  36. ComboGridOptions cgopClassmajor = new ComboGridOptions
  37. {
  38. TextField = "Name",
  39. ValueField = "ClassmajorID",
  40. IsEnabled = false,
  41. GridOptions = new DataGridOptions
  42. {
  43. Columns = new List<DataGridColumn>()
  44. {
  45. new LinkButtonColumn { FieldName="No", HeaderText="班级编号", Width=0.2, Align=AlignStyle.Center },
  46. new BoundFieldColumn { FieldName="Name", HeaderText="班级名称", Width=0.3, Align=AlignStyle.Center }
  47. },
  48. PageSize = 5,
  49. IsCheckOnSelect = true,
  50. DataSourceUrl = Url.Content("~/Classmajor/List"),
  51. IsPagination = true,
  52. IsShowRowNumbers = true,
  53. IsSingleSelect = false
  54. }
  55. };
  56. }
  57. @section scripts{
  58. <script src="~/Scripts/Business/StudentManage/StudentProfile/StudentEncourageCancel.js" type="text/javascript"></script>
  59. }
  60. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  61. @using (Ajax.BeginForm(new AjaxOptions
  62. {
  63. OnSuccess = "EMISFunction.FormSuccess",
  64. OnBegin = "EMISFunction.FormSubmit",
  65. OnComplete = "EMISFunction.FormComplete"
  66. }))
  67. {
  68. <div class="p_title">
  69. <div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;"></div>
  70. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Cancel")</div>
  71. </div>
  72. <div class="search_list">
  73. @Html.HiddenFor(x => x.StudentEncourageID)
  74. <table cellpadding="0" cellspacing="0" id="studentEncouragetable">
  75. <tr>
  76. <td style="color: red;">
  77. @Html.LabelFor(x => x.SchoolyearCode):
  78. </td>
  79. <td>
  80. @Html.DropdownListFor((x => x.SchoolyearID), new DropdownListOptions
  81. {
  82. TextField = "Text",
  83. ValueField = "Value",
  84. BindType = DropdownListBindType.PleaseSelect,
  85. IsEnabled = false,
  86. SelectedValue = BaseExtensions.GetCurrentSchoolYearID(),
  87. ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid")
  88. })
  89. </td>
  90. <td style="color: red;">
  91. @Html.LabelFor(x => x.StudentNo):
  92. </td>
  93. <td>
  94. @Html.ComboGridFor(x => x.UserID, cgopStudent)
  95. </td>
  96. </tr>
  97. <tr>
  98. <td>
  99. @Html.LabelFor(x => x.Name):
  100. </td>
  101. <td>
  102. @Html.TextBoxFor(x => x.Name, new TextBoxOptions() { IsEnabled = false })
  103. </td>
  104. <td>
  105. @Html.LabelFor(x => x.SexName):
  106. </td>
  107. <td>
  108. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.CF_Sex, (x => x.SexID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  109. </td>
  110. </tr>
  111. <tr>
  112. <td>
  113. @Html.LabelFor(x => x.ClassmajorName):
  114. </td>
  115. <td>
  116. @Html.ComboGridFor(x => x.ClassmajorID, cgopClassmajor)
  117. </td>
  118. <td>
  119. @Html.LabelFor(x => x.InSchoolStatusName):
  120. </td>
  121. <td>
  122. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.CF_InschoolStatus, (x => x.InSchoolStatusID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = false })
  123. </td>
  124. </tr>
  125. <tr>
  126. <td style="color: red;">
  127. @Html.LabelFor(x => x.EncourageName):
  128. </td>
  129. <td>
  130. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.EM_EncourageName, (x => x.EncourageNameID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = isEnable })
  131. </td>
  132. <td>
  133. @Html.LabelFor(x => x.EncourageTypeName):
  134. </td>
  135. <td>
  136. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.EM_EncourageType, (x => x.EncourageTypeID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = isEnable })
  137. </td>
  138. </tr>
  139. <tr>
  140. <td>
  141. @Html.LabelFor(x => x.EncourageLevelName):
  142. </td>
  143. <td>
  144. @Html.DictionaryComboGridFor(EMIS.ViewModel.DictionaryItem.EM_EncourageLevel, (x => x.EncourageLevelID), DropdownListBindType.PleaseSelect, new ComboGridOptions() { IsEnabled = isEnable })
  145. </td>
  146. <td>
  147. @Html.LabelFor(x => x.DocNo):
  148. </td>
  149. <td>
  150. @Html.TextBoxFor(x => x.DocNo, new TextBoxOptions() { IsEnabled = isEnable })
  151. </td>
  152. </tr>
  153. <tr>
  154. <td>
  155. @Html.LabelFor(x => x.Unit):
  156. </td>
  157. <td colspan="3">
  158. @if (!isEnable)
  159. {
  160. @Html.TextBoxFor(x => x.Unit, new Dictionary<string, object>
  161. {
  162. { "style", "width: 90%;min-height: 20px" },
  163. { "disabled", "true" }
  164. })
  165. }
  166. else
  167. {
  168. @Html.TextBoxFor(x => x.Unit, new Dictionary<string, object> { { "style", "width: 90%;min-height: 20px" } })
  169. }
  170. </td>
  171. </tr>
  172. <tr>
  173. <td>
  174. @Html.LabelFor(x => x.EncourageDate):
  175. </td>
  176. <td>
  177. @Html.TextBoxFor(x => x.EncourageDate, new TextBoxOptions() { TextBoxType = TextBoxType.Date, IsEnabled = isEnable })
  178. </td>
  179. <td>
  180. @Html.LabelFor(x => x.Amount):
  181. </td>
  182. <td>
  183. @Html.TextBoxFor(x => x.Amount, new TextBoxOptions() { IsEnabled = isEnable })
  184. </td>
  185. </tr>
  186. <tr>
  187. <td>
  188. @Html.LabelFor(x => x.Reason):
  189. </td>
  190. <td colspan="3">
  191. @if (!isEnable)
  192. {
  193. @Html.TextAreaFor(x => x.Reason, new Dictionary<string, object>
  194. {
  195. { "style", "width: 90%;min-height: 45px" },
  196. { "disabled", "true" }
  197. })
  198. }
  199. else
  200. {
  201. @Html.TextAreaFor(x => x.Reason, new Dictionary<string, object> { { "style", "width: 90%;min-height: 45px" } })
  202. }
  203. </td>
  204. </tr>
  205. <tr>
  206. <td>
  207. @Html.LabelFor(x => x.Comment):
  208. </td>
  209. <td colspan="3">
  210. @Html.TextAreaFor(x => x.Comment, new Dictionary<string, object>
  211. {
  212. { "style", "width: 90%;min-height: 50px" }
  213. })
  214. </td>
  215. </tr>
  216. </table>
  217. </div>
  218. }
  219. </div>