123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422 |
- @model EMIS.ViewModel.ScoreManage.FinalExaminationView
- @using EMIS.Web.Controls;
- @using Bowin.Web.Controls.Mvc;
- @{
- ViewBag.Title = "Edit";
- //判断新增或修改来选择提交后的处理方法
- var OnSuccess = "EMISFunction.FormSuccessNoClose";
- ComboGridOptions cgopdepartment = new ComboGridOptions
- {
- TextField = "Name",
- ValueField = "DepartmentID",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- //new LinkButtonColumn { FieldName="No", HeaderText="教研室代码", Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="Name", HeaderText="教研室名称", Align=AlignStyle.Center, Width=0.3 }
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/Department/ListGridResultSet"),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- }
- };
- ComboGridOptions cgopcollege = new ComboGridOptions
- {
- TextField = "Name",
- ValueField = "CollegeID",
- //OnSelect = "QueryCollegeComboGridList",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- //new LinkButtonColumn { FieldName="No", HeaderText=@EMIS.Utility.RSL.Get("CollegeCode"), Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="Name", HeaderText=@EMIS.Utility.RSL.Get("CollegeName"), Align=AlignStyle.Center, Width=0.3 }
- },
- //OnLoadSuccessFun = "queryClass",
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/College/ListOnlyCollege"),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- }
- };
-
- ComboGridOptions cgopClassmajor = new ComboGridOptions
- {
- TextField = "Name",
- ValueField = "ClassmajorID",
- OnSelect = "QueryComboGridClassmajor",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new BoundFieldColumn { FieldName="No", HeaderText="班级编号", Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="Name", HeaderText="班级名称", Align=AlignStyle.Center, Width=0.3 }
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/Classmajor/List"),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- }
- };
- ComboGridOptions cgopEnableCourse = new ComboGridOptions
- {
- TextField = "CourseName",
- ValueField = "CoursematerialID",
- OnSelect = "QueryComboGridCourse",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new LinkButtonColumn { FieldName="CourseCode", HeaderText="课程代码", Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Align=AlignStyle.Center, Width=0.3 }
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/Coursematerial/GetIsEnableCoursematerialView"),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- }
- };
- ComboGridOptions cgopEnableAndUseCourse = new ComboGridOptions
- {
- TextField = "CourseName",
- ValueField = "CoursematerialID",
- OnSelect = "QueryComboGridCourse",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new LinkButtonColumn { FieldName="CourseCode", HeaderText="课程代码", Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Align=AlignStyle.Center, Width=0.3 }
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/Coursematerial/GetEnableAndUseCoursematerialView?coursematerialID="+Model.CoursematerialID),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- }
- };
- ComboGridOptions cgopUser = new ComboGridOptions
- {
- TextField = "Name",
- ValueField = "UserID",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new LinkButtonColumn { FieldName="StaffCode", HeaderText="教职工号", Align=AlignStyle.Center, Width=0.1 },
- new BoundFieldColumn { FieldName="Name", HeaderText="姓名", Align=AlignStyle.Center, Width=0.12 }
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/Staff/GetAllStaffDataBind"),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- }
- };
-
- ComboGridOptions cgopStandard = new ComboGridOptions
- {
- TextField = "StandardName",
- ValueField = "StandardID",
- GridOptions = new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new BoundFieldColumn { FieldName="StandardName", HeaderText="专业名称", Align=AlignStyle.Center, Width=0.1 }
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/Grademajor/StandardBindComboGridOptions"),
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false,
- IsShowHeader = false
- }
- };
- }
- @section scripts{
- <script src="~/Scripts/Business/ScoreManage/FinalExaminationEdit.js" type="text/javascript"></script>
- <script type="text/javascript">
- var nonSelect = "@DropdownList.SELECT_ALL";
- function LoginIDColor(index, row, value) {
- if (row.IsDifferentDynamic == true) {
- return " <span style=\"color:red;\">" + value + "</span>";
- }
- else {
- return value
- }
- }
- function UserNameColor(index, row, value) {
- if (row.IsDifferentDynamic == true) {
- return " <span style=\"color:red;\">" + value + "</span>";
- }
- else {
- return value
- }
- }
- function SexNameColor(index, row, value) {
- if (row.IsDifferentDynamic == true) {
- return " <span style=\"color:red;\">" + value + "</span>";
- }
- else {
- return value
- }
- }
- function StudentStatusNameColor(index, row, value) {
- if (row.IsDifferentDynamic == true) {
- return " <span style=\"color:red;\">" + value + "</span>";
- }
- else {
- return value
- }
- }
- function InSchoolStatusNameColor(index, row, value) {
- if (row.IsDifferentDynamic == true) {
- return " <span style=\"color:red;\">" + value + "</span>";
- }
- else {
- return value
- }
- }
- function CoursematerialNameColor(index, row, value) {
- if (row.IsDifferentDynamic == true) {
- return " <span style=\"color:red;\">" + value + "</span>";
- }
- else {
- return value
- }
- }
- function ClassmajorNameColor(index, row, value) {
- if (row.IsDifferentDynamic == true) {
- return " <span style=\"color:red;\">" + value + "</span>";
- }
- else {
- return value
- }
- }
- </script>
- }
- <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
- @if (Request["aType"] == "update")
- {
- OnSuccess = "EMISFunction.FormSuccess";
- }
- @using (Ajax.BeginForm(new AjaxOptions
- {
- //保存后不关闭
- OnSuccess = OnSuccess,
- //OnSuccess = "EMISFunction.FormSuccess",
- OnBegin = "EMISFunction.FormSubmit",
- OnComplete = "EMISFunction.FormComplete"
- }))
-
- {
- @Html.Hidden("hid_ExamsCategory")
- <div class="p_title">
- @*<div style="float: left; margin-left: 10px; line-height: 30px; font-size: 12px;">
- 期末设定信息</div>*@
- @if (Request["isView"] != "1")
- {
- <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Edit")</div>
- }
- </div>
- <div class="search_list">
- @Html.HiddenFor(x => x.FinalExaminationID)
- @Html.HiddenFor(x => x.ClassID)
- <table cellpadding="0" cellspacing="0" id="FinalExaminationtable">
- <tr>
- <td>
- @Html.LabelFor(x => x.ClassName):
- </td>
- <td colspan="3">
- @Html.TextBoxFor(x => x.ClassName, new Dictionary<string, object> { { "style", "width:85%;" } })
- </td>
- </tr>
- <tr>
- <td>
- @Html.LabelFor(x => x.SchoolyearID):
- </td>
- <td>
- @Html.DropdownListFor(x => x.SchoolyearID, new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid") })
- </td>
- <td>
- @Html.LabelFor(x => x.CollegeID):
- </td>
- <td>
- @Html.ComboGridFor(x => x.CollegeID, cgopcollege)
- </td>
- </tr>
- <tr>
- <td>
- @Html.LabelFor(x => x.GradeYearID):
- </td>
- <td>
- @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Grade, x => x.GradeYearID, new DropdownListOptions { OnLoadSuccess = "queryClass", OnSelect = "selectGrade" })
- </td>
- <td>
- @Html.LabelFor(x => x.StandardName):
- </td>
- <td>
- @Html.ComboGridFor(x => x.StandardID, cgopStandard)
- </td>
- </tr>
- <tr>
- <td>@Html.LabelFor(x => x.ClassmajorName):
- </td>
- <td colspan="3">@Html.TextBoxFor(x => x.ClassmajorName, new Dictionary<string, object> { { "style", "width:45%;" } })
- <button onclick="FinalExamination_ClassmajorAdd()" type="button" title="...">...</button>
- </td>
- </tr>
- <tr>
- @if (Model.FinalExaminationID == null)
- {
- <td>
- @Html.LabelFor(x => x.CoursematerialID):
- </td>
- <td>
- @Html.ComboGridFor(x => x.CoursematerialID, cgopEnableCourse)
- </td>
- }
- else
- {
- <td>
- @Html.LabelFor(x => x.CoursematerialID):
- </td>
- <td>
- @Html.ComboGridFor(x => x.CoursematerialID, cgopEnableAndUseCourse)
- </td>
- }
- <td>
- @Html.LabelFor(x => x.CourseTypeID):
- </td>
- <td>
- @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseType, x => x.CourseTypeID)
- </td>
- </tr>
-
- <tr>
- <td>
- @Html.LabelFor(x => x.ExamsCategoryID):
- </td>
- <td>
- @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ExamsCategory, x => x.ExamsCategoryID, new DropdownListOptions { OnSelect = "QueryExamsCategory" })
- </td>
- <td>
- @Html.LabelFor(x => x.DepartmentID):
- </td>
- <td>
- @Html.ComboGridFor(x => x.DepartmentID, cgopdepartment)
- </td>
- </tr>
- <tr>
- <td>@Html.LabelFor(x => x.ResultTypeID)
- </td>
- <td>@Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ResultType, (x => x.ResultTypeID))
- </td>
- <td>@Html.LabelFor(x => x.Credit):
- </td>
- <td>@Html.TextBoxFor(x => x.Credit)
- </td>
- </tr>
- <tr>
- <td>@Html.LabelFor(x => x.ExaminationModeID):
- </td>
- <td>@Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ExaminationMode, (x => x.ExaminationModeID))
- </td>
- <td>
- @Html.LabelFor(x => x.ExamsDatetime):
- </td>
- <td>
- @Html.TextBoxFor(x => x.ExamsDatetime, new TextBoxOptions { TextBoxType = TextBoxType.Date })
- </td>
- </tr>
- @*<tr>
- <td>
- @Html.LabelFor(x => x.IsEntry):
- </td>
- <td>
- @if (Model.IsEntry == true)
- {
- @Html.CheckBoxFor(x => x.IsEntry, new Dictionary<string, object> { { "disabled", "true" } })
- }
- else
- {
- @Html.CheckBoxFor(x => x.IsEntry)
- }
- </td>
- </tr>*@
- <tr>
- <td>
- @Html.LabelFor(x => x.EntryDeadlineTime):
- </td>
- <td>
- @Html.TextBoxFor(x => x.EntryDeadlineTime, new TextBoxOptions { TextBoxType = TextBoxType.Date })
- </td>
- <td>
- @Html.LabelFor(x => x.CreatorUserName):
- </td>
- <td>
- @Html.ComboGridFor(x => x.CreatorUserID, cgopUser)
- </td>
- </tr>
- <tr>
- <td>
- @Html.LabelFor(x => x.isAutoAdd):
- </td>
- <td >
- @Html.CheckBoxFor(x => x.isAutoAdd)
- </td>
- <td>
- @Html.LabelFor(x => x.TotalHours):
- </td>
- <td>
- @Html.TextBoxFor(x => x.TotalHours)
- </td>
- </tr>
- @*<tr>
- <td rowspan="2">
- <label>学生名单:</label>
- </td>
- <td colspan="3">
- <div style="line-height: 30px; font-size: 12px; text-align: left;">@Html.ContextMenuBar("Settings")</div>
- </td>
- </tr>
- <tr>
- <td colspan="3">
- <div style="width: 100%; height: 250px; overflow: scroll; scrollbar-arrow-color:#ffffff; scrollbar-highlight-color:#ffffff; scrollbar-3dlight-color:#70807d; scrollbar-shadow-color:#ffffff; scrollbar-darkshadow-color:#70807d; scrollbar-track-color:#ffffff">
- @Html.DataGrid(new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new CheckBoxFieldColumn { FieldName="UserID" },
- new BoundFieldColumn { FieldName="LoginID", HeaderText="学号", Align=AlignStyle.Center, CustomFormatFun = "LoginIDColor",Width=0.08 },
- new BoundFieldColumn { FieldName="UserName", HeaderText="姓名", Align=AlignStyle.Center, CustomFormatFun = "UserNameColor",Width=0.04 },
- new BoundFieldColumn { FieldName="SexName", HeaderText="性别", Align=AlignStyle.Center, CustomFormatFun = "SexNameColor",Width=0.03 },
- new BoundFieldColumn { FieldName="CoursematerialName", HeaderText="课程名称", Align=AlignStyle.Center, CustomFormatFun = "CoursematerialNameColor",Width=0.1 },
- new BoundFieldColumn { FieldName="ClassmajorName", HeaderText="班级名称", Align=AlignStyle.Center, CustomFormatFun = "ClassmajorNameColor",Width=0.1 },
- new BoundFieldColumn { FieldName="InSchoolStatusName", HeaderText="在校状态", Align=AlignStyle.Center, CustomFormatFun = "InSchoolStatusNameColor",Width=0.04 },
- new BoundFieldColumn { FieldName="StudentStatusName", HeaderText="学籍状态", Align=AlignStyle.Center, CustomFormatFun = "StudentStatusNameColor",Width=0.04 },
- new BoundFieldColumn { FieldName="IsDifferentDynamic", HeaderText="是否异动申请", Align=AlignStyle.Center, IsHidden = true }
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/FinalExamination/FinalExaminationStudentList?finalExaminationID=" + Model.FinalExaminationID),
- IsPostBack = true,
- ID = "dgStudentList",
- IsPagination = false,
- IsShowRowNumbers = true,
- IsSingleSelect = false
- })
- </div>
- </td>
- </tr>*@
- </table>
- </div>
- }
- </div>
|