@model EMIS.ViewModel.CultureplanManage.PlanManagement.SpecialtyPlanView @using EMIS.Web.Controls; @using Bowin.Web.Controls.Mvc; @{ ViewBag.Title = "Edit"; var isEnabled = Request["type"] == "detail" ? false : true; //年级专业 ComboGridOptions cgopGrademajor = new ComboGridOptions { TextField = "Name", ValueField = "GrademajorID", OnSelect = "queryGrademajor", IsEnabled = Request["type"] == "detail" ? false : (Request["type"] == "edit" ? false : true), GridOptions = new DataGridOptions { Columns = new List() { new LinkButtonColumn { FieldName="Code", HeaderText="年级专业代码", Align=AlignStyle.Center, Width=0.2 }, new BoundFieldColumn { FieldName="Name", HeaderText="年级专业名称", Align=AlignStyle.Center, Width=0.4 } }, PageSize = 5, IsCheckOnSelect = true, DataSourceUrl = Url.Content("~/Grademajor/List"), IsPagination = true, IsShowRowNumbers = true, IsSingleSelect = false } }; //课程信息 ComboGridOptions cgopCourse = new ComboGridOptions { ID = "CoursematerialID", TextField = "CourseName", ValueField = "CoursematerialID", IsEnabled = Request["type"] == "detail" ? false : (Request["type"] == "edit" ? false : true), GridOptions = new DataGridOptions { Columns = new List() { new LinkButtonColumn { FieldName="CourseCode", HeaderText="课程代码", Align=AlignStyle.Center, Width=0.1 }, new BoundFieldColumn { FieldName="CourseName", HeaderText="课程名称", Align=AlignStyle.Center, Width=0.2 }, new BoundFieldColumn { FieldName="IsEnableName", HeaderText="是否启用", Align=AlignStyle.Center, Width=0.1, CustomFormatFun="SetRedColumn" } }, IsCheckOnSelect = true, DataSourceUrl = Url.Content("~/Coursematerial/GetEnableAndUseCoursematerialView?coursematerialID=" + Model.CoursematerialID), IsPagination = true, IsShowRowNumbers = true, IsSingleSelect = false } }; //教研室 ComboGridOptions cgopDepartment = new ComboGridOptions { TextField = "Name", ValueField = "DepartmentID", IsEnabled = isEnabled, GridOptions = new DataGridOptions { Columns = new List() { new LinkButtonColumn { FieldName="No", HeaderText="教研室代码", Align=AlignStyle.Center, Width=0.1 }, new BoundFieldColumn { FieldName="Name", HeaderText="开课教研室", Align=AlignStyle.Center, Width=0.2 }, new BoundFieldColumn { FieldName="CollegeName", HeaderText=@EMIS.Utility.RSL.Get("CourseCollege"), Align=AlignStyle.Center, Width=0.2 } }, IsCheckOnSelect = true, DataSourceUrl = Url.Content("~/Department/List"), IsPagination = true, IsShowRowNumbers = true, IsSingleSelect = false } }; //授课方式 ListControlOptions lcoptm = new ListControlOptions { ID = "TeachingModeIDList", Name = "TeachingModeIDList", TextField = "Name", ValueField = "Value", ColumnCount = 4, IsEnabled = isEnabled, SelectedValueUrl = @Url.Content("~/SpecialtyPlan/TeachingModeTypeList?specialtyPlanID=" + Model.SpecialtyPlanID) }; //授课地点 ListControlOptions lcoptp = new ListControlOptions { ID = "TeachingPlaceIDList", Name = "TeachingPlaceIDList", TextField = "Name", ValueField = "Value", ColumnCount = 4, IsEnabled = isEnabled, SelectedValueUrl = @Url.Content("~/SpecialtyPlan/TeachingPlaceList?specialtyPlanID=" + Model.SpecialtyPlanID) }; } @section scripts{ }
@using (Ajax.BeginForm(new AjaxOptions { OnSuccess = "EMISFunction.FormSuccess", OnBegin = "EMISFunction.FormSubmit", OnComplete = "EMISFunction.FormComplete" })) {
@if (Request["type"] != "detail") { @Html.ContextMenuBar("Edit") }
@Html.HiddenFor(x => x.SpecialtyPlanID)
@Html.LabelFor(x => x.SchoolyearCode): @Html.DropdownListFor((x => x.SchoolyearID), new DropdownListOptions { BindType = DropdownListBindType.PleaseSelect, TextField = "Text", ValueField = "Value", IsEnabled = Request["type"] == "detail" ? false : (Request["type"] == "edit" ? false : true), ItemSourceUrl = Url.Content("~/SchoolYear/YearsDropdownListBanid") }) @Html.LabelFor(x => x.GrademajorName): @Html.ComboGridFor(x => x.GrademajorID, cgopGrademajor)
@Html.LabelFor(x => x.GradeID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Grade, (x => x.GradeID), new DropdownListOptions() { IsEnabled = false }) @Html.LabelFor(x => x.StandardCode): @Html.TextBoxFor(x => x.StandardCode, new TextBoxOptions() { IsEnabled = false })
@Html.LabelFor(x => x.StandardName): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Standard, (x => x.StandardID), new DropdownListOptions() { IsEnabled = false }) @Html.LabelFor(x => x.EducationID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Education, (x => x.EducationID), new DropdownListOptions() { IsEnabled = false })
@Html.LabelFor(x => x.LearningformID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Learningform, (x => x.LearningformID), new DropdownListOptions() { IsEnabled = false }) @Html.LabelFor(x => x.LearnSystem): @Html.TextBoxFor(x => x.LearnSystem, new TextBoxOptions() { IsEnabled = false })
@Html.LabelFor(x => x.CourseName): @Html.ComboGridFor(x => x.CoursematerialID, cgopCourse) @Html.LabelFor(x => x.DepartmentName): @Html.ComboGridFor(x => x.DepartmentID, cgopDepartment)
@Html.LabelFor(x => x.CourseStructureName): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseStructure, x => x.CourseStructureID, new DropdownListOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.CourseCategoryName): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseCategory, x => x.CourseCategoryID, new DropdownListOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.CourseTypeName): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseType, x => x.CourseTypeID, new DropdownListOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.CourseQualityName): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseQuality, x => x.CourseQualityID, new DropdownListOptions() { IsEnabled = isEnabled })
教学设置信息
@Html.LabelFor(x => x.Credit): @Html.TextBoxFor(x => x.Credit, new TextBoxOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.HandleModeName): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_HandleMode, (x => x.HandleModeID), new DropdownListOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.TheoryCourse): @Html.TextBoxFor(x => x.TheoryCourse, new TextBoxOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.Practicehours): @Html.TextBoxFor(x => x.Practicehours, new TextBoxOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.Trialhours): @Html.TextBoxFor(x => x.Trialhours, new TextBoxOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.Totalhours): @Html.TextBoxFor(x => x.Totalhours, new TextBoxOptions { IsEnabled = false })
@Html.LabelFor(x => x.TheoryWeeklyNum): @Html.TextBoxFor(x => x.TheoryWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.PracticeWeeklyNum): @Html.TextBoxFor(x => x.PracticeWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.TrialWeeklyNum): @Html.TextBoxFor(x => x.TrialWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.SchoolweeksNum): @Html.TextBoxFor(x => x.SchoolweeksNum, new TextBoxOptions { IsEnabled = false })
@Html.LabelFor(x => x.WeeklyHours): @Html.TextBoxFor(x => x.WeeklyHours, new TextBoxOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.WeeklyNum): @Html.TextBoxFor(x => x.WeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.StartWeeklyNum): @Html.TextBoxFor(x => x.StartWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.EndWeeklyNum): @Html.TextBoxFor(x => x.EndWeeklyNum, new TextBoxOptions() { IsEnabled = isEnabled })
其它信息
@Html.LabelFor(x => x.IsSpecialtycore): @if (Request["type"] == "detail") { @Html.CheckBoxFor(x => x.IsSpecialtycore, new Dictionary() { { "disabled", isEnabled } }) } else { @Html.CheckBoxFor(x => x.IsSpecialtycore) } @Html.LabelFor(x => x.IsCooperation): @if (Request["type"] == "detail") { @Html.CheckBoxFor(x => x.IsCooperation, new Dictionary() { { "disabled", isEnabled } }) } else { @Html.CheckBoxFor(x => x.IsCooperation) }
@Html.LabelFor(x => x.IsRequired): @if (Request["type"] == "detail") { @Html.CheckBoxFor(x => x.IsRequired, new Dictionary() { { "disabled", isEnabled } }) } else { @Html.CheckBoxFor(x => x.IsRequired) } @Html.LabelFor(x => x.IsElective): @if (Request["type"] == "detail") { @Html.CheckBoxFor(x => x.IsElective, new Dictionary() { { "disabled", isEnabled } }) } else { @Html.CheckBoxFor(x => x.IsElective) }
@Html.LabelFor(x => x.IsNetworkCourse): @if (Request["type"] == "detail") { @Html.CheckBoxFor(x => x.IsNetworkCourse, new Dictionary() { { "disabled", isEnabled } }) } else { @Html.CheckBoxFor(x => x.IsNetworkCourse) } @Html.LabelFor(x => x.IsMainCourse): @if (Request["type"] == "detail") { @Html.CheckBoxFor(x => x.IsMainCourse, new Dictionary() { { "disabled", isEnabled } }) } else { @Html.CheckBoxFor(x => x.IsMainCourse) }
@Html.LabelFor(x => x.IsNeedMaterial): @if (Request["type"] == "detail") { @Html.CheckBoxFor(x => x.IsNeedMaterial, new Dictionary() { { "disabled", isEnabled } }) } else { @Html.CheckBoxFor(x => x.IsNeedMaterial) } @Html.LabelFor(x => x.CourseFineID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_CourseFine, x => x.CourseFineID, new DropdownListOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.PracticeTypeID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.EM_PracticeType, x => x.PracticeTypeID, new DropdownListOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.TeachinglanguageID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_Teachinglanguage, x => x.TeachinglanguageID, new DropdownListOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.ExaminationModeID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ExaminationMode, x => x.ExaminationModeID, new DropdownListOptions() { IsEnabled = isEnabled }) @Html.LabelFor(x => x.ResultTypeID): @Html.DictionaryDropDownListFor(EMIS.ViewModel.DictionaryItem.CF_ResultType, (x => x.ResultTypeID), new DropdownListOptions() { IsEnabled = isEnabled })
@Html.LabelFor(x => x.TeachingModeIDList): @Html.DictionaryCheckList(EMIS.ViewModel.DictionaryItem.CF_TeachingMode, lcoptm)
@Html.LabelFor(x => x.TeachingPlaceIDList): @Html.DictionaryCheckList(EMIS.ViewModel.DictionaryItem.EM_TeachingPlace, lcoptp)
@Html.LabelFor(x => x.Remark): @if (Request["type"] == "detail") { @Html.TextAreaFor(x => x.Remark, new Dictionary { { "style", "width: 90%;min-height: 35px" }, { "disabled", "true" } }) } else { @Html.TextAreaFor(x => x.Remark, new Dictionary { { "style", "width: 90%;min-height: 35px" } }) }
}