From f101a160f05d4fb3333dabc96cc09656dd814318 Mon Sep 17 00:00:00 2001 From: ndbs Date: Fri, 8 Jul 2022 17:59:29 +0800 Subject: [PATCH 01/14] =?UTF-8?q?=E6=95=99=E5=8A=A1---=E6=A0=A1=E5=8E=86?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/SchoolCalendarController.cs | 84 ++++++++- .../Views/SchoolCalendar/Form.cshtml | 10 +- .../Views/SchoolCalendar/Form.js | 19 +- .../Views/SchoolCalendar/ScheduleIndex.cshtml | 166 ++++++++++++++++++ .../Learun.Application.Web.csproj | 1 + .../SchoolCalendar/SchoolCalendarBLL.cs | 42 +++++ .../SchoolCalendar/SchoolCalendarIBLL.cs | 13 ++ .../SchoolCalendar/SchoolCalendarService.cs | 44 ++++- 8 files changed, 369 insertions(+), 10 deletions(-) create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/ScheduleIndex.cshtml diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/SchoolCalendarController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/SchoolCalendarController.cs index 249f1d643..34773c06e 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/SchoolCalendarController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/SchoolCalendarController.cs @@ -3,6 +3,7 @@ using System.Data; using Learun.Application.TwoDevelopment.EducationalAdministration; using System.Web.Mvc; using System.Collections.Generic; +using System.Collections; namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { @@ -26,7 +27,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult Index() { - return View(); + return View(); } /// /// 表单页 @@ -35,7 +36,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult Form() { - return View(); + return View(); + } + + /// + /// 主页面 + /// + /// + [HttpGet] + public ActionResult ScheduleIndex() + { + return View(); } #endregion @@ -62,6 +73,29 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers }; return Success(jsonData); } + + /// + /// 获取日程数据 + /// + /// + [HttpGet] + public ActionResult GetListForSchedule() + { + var userInfo = LoginUserInfo.Get(); + List data = new List(); + foreach (SchoolCalendarEntity entity in schoolCalendarIBLL.GetList()) + { + Hashtable ht = new Hashtable(); + ht["id"] = entity.ID; + ht["academicYearNo"] = "【" + entity.AcademicYearNo + "】"; + ht["title"] = entity.Content; + ht["end"] = (entity.EndTime.ToDate().ToString("yyyy-MM-dd") + " " + entity.EndTime.ToString().Substring(0, 2) + ":" + entity.EndTime.ToString().Substring(2, 2)).ToDate().ToString("yyyy-MM-dd HH:mm:ss"); + ht["start"] = (entity.StartTime.ToDate().ToString("yyyy-MM-dd") + " " + entity.StartTime.ToString().Substring(0, 2) + ":" + entity.StartTime.ToString().Substring(2, 2)).ToDate().ToString("yyyy-MM-dd HH:mm:ss"); + ht["allDay"] = false; + data.Add(ht); + } + return ToJsonResult(data); + } /// /// 获取页面显示列表数据 /// @@ -82,8 +116,9 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [AjaxOnly] public ActionResult GetFormData(string keyValue) { - var SchoolCalendarData = schoolCalendarIBLL.GetSchoolCalendarEntity( keyValue ); - var jsonData = new { + var SchoolCalendarData = schoolCalendarIBLL.GetSchoolCalendarEntity(keyValue); + var jsonData = new + { SchoolCalendar = SchoolCalendarData, }; return Success(jsonData); @@ -114,11 +149,48 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [AjaxOnly] public ActionResult SaveForm(string keyValue, string strEntity) { - UserInfo userInfo = LoginUserInfo.Get(); SchoolCalendarEntity entity = strEntity.ToObject(); - schoolCalendarIBLL.SaveEntity(userInfo,keyValue,entity); + UserInfo userInfo = LoginUserInfo.Get(); + SchoolCalendarEntity entity = strEntity.ToObject(); + //根据学年和学期查询 + var model = schoolCalendarIBLL.GetSchoolCalendarEntityByNo(entity.AcademicYearNo, entity.Semester); + if (string.IsNullOrEmpty(keyValue)) + { + if (model != null) + { + return Fail("当前学期已存在!"); + } + } + else + { + if (model != null && model.ID != keyValue) + { + return Fail("当前学期已存在!"); + } + } + schoolCalendarIBLL.SaveEntity(userInfo, keyValue, entity); return Success("保存成功!"); } #endregion + #region 扩展数据 + /// + /// 学年 + /// + /// + [HttpGet] + public ActionResult GenerateNearByAcademic() + { + return Success(Learun.Util.WebHelper.GenerateNearByAcademic()); + } + /// + /// 学期 + /// + /// + [HttpGet] + public ActionResult GenerateNearBySemeter() + { + return Success(Learun.Util.WebHelper.GenerateNearBySemeter()); + } + #endregion } } diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.cshtml index 2fd75c575..f4aa3e788 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.cshtml @@ -3,13 +3,21 @@ Layout = "~/Views/Shared/_Form.cshtml"; }
-
+ @*
学年
学期
+
*@ +
+
学年*
+
+
+
+
学期*
+
开始日期
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.js index 3b28a6b2d..f08799931 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/Form.js @@ -15,8 +15,22 @@ var bootstrap = function ($, learun) { page.initData(); }, bind: function () { - $("#Semester").lrDataItemSelect({ code: 'Semester' }); - + //学年 + $('#AcademicYearNo').lrselect({ + placeholder: "请选择学年", + allowSearch: true, + url: top.$.rootUrl + '/EducationalAdministration/SchoolCalendar/GenerateNearByAcademic', + value: 'value', + text: 'text' + }); + //学期 + $('#Semester').lrselect({ + placeholder: "请选择学年", + allowSearch: true, + url: top.$.rootUrl + '/EducationalAdministration/SchoolCalendar/GenerateNearBySemeter', + value: 'value', + text: 'text' + }); }, initData: function () { if (!!keyValue) { @@ -46,6 +60,7 @@ var bootstrap = function ($, learun) { if (!!callBack) { callBack(); } + learun.frameTab.currentIframe().location.reload(); }); }; page.init(); diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/ScheduleIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/ScheduleIndex.cshtml new file mode 100644 index 000000000..fa709950c --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/SchoolCalendar/ScheduleIndex.cshtml @@ -0,0 +1,166 @@ + + + + + + 日程管理 + + + + + @Html.AppendCssFile( + "/Views/LR_Content/style/lr-common.css", + "/Views/LR_Content/style/lr-iframe-index.css" + ) + + + + +
+
+
+ + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj index e114e09c3..395933261 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj @@ -7910,6 +7910,7 @@ + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarBLL.cs index 8567cd653..95a729b81 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarBLL.cs @@ -90,6 +90,48 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } } } + /// + /// 获取列表 + /// + /// 返回列表 + public IEnumerable GetList() + { + try + { + return schoolCalendarService.GetList(); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + + public SchoolCalendarEntity GetSchoolCalendarEntityByNo(string academicYearNo, string semester) + { + try + { + return schoolCalendarService.GetSchoolCalendarEntityByNo(academicYearNo, semester); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } #endregion diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarIBLL.cs index a17ed9417..aab3e4d2b 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarIBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarIBLL.cs @@ -34,6 +34,19 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// /// SchoolCalendarEntity GetSchoolCalendarEntity(string keyValue); + + /// + /// 获取列表 + /// + /// 返回列表 + IEnumerable GetList(); + + /// + /// 根据学年获取SchoolCalendar表实体数据 + /// 主键 + /// + /// + SchoolCalendarEntity GetSchoolCalendarEntityByNo(string academicYearNo, string semester); #endregion #region 提交数据 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarService.cs index 2ba4e5aff..261668567 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/SchoolCalendar/SchoolCalendarService.cs @@ -142,6 +142,48 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } } + /// + /// 获取列表 + /// + /// 返回列表 + public IEnumerable GetList() + { + try + { + return this.BaseRepository().FindList(); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + throw; + else + throw ExceptionEx.ThrowServiceException(ex); + } + } + /// + /// 获取SchoolCalendar表实体数据 + /// 主键 + /// + /// + public SchoolCalendarEntity GetSchoolCalendarEntityByNo(string academicYearNo, string semester) + { + try + { + return this.BaseRepository().FindEntity(x => x.AcademicYearNo == academicYearNo && x.Semester == semester); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + #endregion #region 提交数据 @@ -204,6 +246,6 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } #endregion - + } } From 2efbdd5506414e585348cd09518db53adcee9f7f Mon Sep 17 00:00:00 2001 From: dyy <807692433@qq.com> Date: Fri, 8 Jul 2022 18:12:48 +0800 Subject: [PATCH 02/14] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=91?= =?UTF-8?q?=E6=96=B0=E7=94=9F=E9=A2=86=E5=8F=96=E7=94=A8=E5=93=81=EF=BC=9A?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=A2=86=E5=86=9B=E8=AE=AD=E6=9C=8D=E8=A3=85?= =?UTF-8?q?=EF=BC=8C=E9=A2=86=E5=BA=8A=E4=B8=8A=E7=94=A8=E5=93=81=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/StuInfoFreshController.cs | 22 +++++ .../Views/StuInfoFresh/GetKeyIndex.cshtml | 17 +++- .../Views/StuInfoFresh/GetKeyIndex.js | 87 +++++++++++++++++++ .../StuInfoFresh/StuInfoFreshBLL.cs | 48 ++++++++++ .../StuInfoFresh/StuInfoFreshEntity.cs | 26 ++++++ .../StuInfoFresh/StuInfoFreshIBLL.cs | 14 +++ .../StuInfoFresh/StuInfoFreshService.cs | 60 +++++++++++++ 7 files changed, 270 insertions(+), 4 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs index 593a5d8b6..b287f0901 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs @@ -577,6 +577,28 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers return Success("操作成功"); } /// + ///领取军训服装 + /// + /// + [HttpPost] + [AjaxOnly] + public ActionResult IsGetMiliClothes(string keyValue, string status) + { + stuInfoFreshIBLL.IsGetMiliClothes(keyValue, status); + return Success("操作成功"); + } + /// + ///领取床上用品 + /// + /// + [HttpPost] + [AjaxOnly] + public ActionResult IsGetBedding(string keyValue, string status) + { + stuInfoFreshIBLL.IsGetBedding(keyValue, status); + return Success("操作成功"); + } + /// ///缴费 /// /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.cshtml index 11fe2af88..6926d314f 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.cshtml @@ -37,10 +37,19 @@
 删除宿舍信息 diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.js index 729f8ccc6..abcefa69a 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/GetKeyIndex.js @@ -153,6 +153,79 @@ var bootstrap = function ($, learun) { }); } }); + + // 领军训服装 + $('#lr_getMiliClothes').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('ID'); + selectedRow = $('#gridtable').jfGridGet('rowdata'); + if (learun.checkrow(keyValue)) { + if (selectedRow.GetMiliClothesStatus == "1") { + learun.alert.warning("当前新生已领取军训服装!"); + return; + } + learun.layerConfirm('是否确认领取军训服装!', function (res) { + if (res) { + learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetMiliClothes', { keyValue: keyValue, status: 1 }, function () { + refreshGirdData(); + }); + } + }); + } + }); + // 设置未领军训服装 + $('#lr_cancelGetMiliClothes').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('ID'); + selectedRow = $('#gridtable').jfGridGet('rowdata'); + if (learun.checkrow(keyValue)) { + if (selectedRow.GetMiliClothesStatus != "1") { + learun.alert.warning("当前新生暂未领取军训服装!"); + return; + } + learun.layerConfirm('是否设置新生未领取军训服装!', function (res) { + if (res) { + learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetMiliClothes', { keyValue: keyValue, status: 0 }, function () { + refreshGirdData(); + }); + } + }); + } + }); + // 领床上用品 + $('#lr_getBedding').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('ID'); + selectedRow = $('#gridtable').jfGridGet('rowdata'); + if (learun.checkrow(keyValue)) { + if (selectedRow.GetBeddingStatus == "1") { + learun.alert.warning("当前新生已领取床上用品!"); + return; + } + learun.layerConfirm('是否确认领取床上用品!', function (res) { + if (res) { + learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetBedding', { keyValue: keyValue, status: 1 }, function () { + refreshGirdData(); + }); + } + }); + } + }); + // 设置未领床上用品 + $('#lr_cancelGetBedding').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('ID'); + selectedRow = $('#gridtable').jfGridGet('rowdata'); + if (learun.checkrow(keyValue)) { + if (selectedRow.GetBeddingStatus != "1") { + learun.alert.warning("当前新生暂未领取床上用品!"); + return; + } + learun.layerConfirm('是否设置新生未领取床上用品!', function (res) { + if (res) { + learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetBedding', { keyValue: keyValue, status: 0 }, function () { + refreshGirdData(); + }); + } + }); + } + }); }, initGird: function () { $('#gridtable').lrAuthorizeJfGrid({ @@ -209,6 +282,20 @@ var bootstrap = function ($, learun) { } }, { label: '领取校园卡时间', name: 'GetCardDate', width: 130, align: "left" }, + + { + label: '领军训服装状态', name: 'GetMiliClothesStatus', width: 100, align: "left", formatter: function (value) { + return value == 1 ? "已领取" : "未领取"; + } + }, + { label: '领军训服装时间', name: 'GetMiliClothesDate', width: 130, align: "left" }, + + { + label: '领床上用品状态', name: 'GetBeddingStatus', width: 100, align: "left", formatter: function (value) { + return value == 1 ? "已领取" : "未领取"; + } + }, + { label: '领床上用品时间', name: 'GetBeddingDate', width: 130, align: "left" }, { label: '系', name: 'DeptNo', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { learun.clientdata.getAsync('custmerData', { diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshBLL.cs index f0d81fed9..896041c8b 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshBLL.cs @@ -600,6 +600,54 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } } + /// + /// 领取军训服装 + /// 主键 + /// + /// + public void IsGetMiliClothes(string keyValue, string status) + { + try + { + stuInfoFreshService.IsGetMiliClothes(keyValue, status); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + /// + /// 领取床上用品 + /// 主键 + /// + /// + public void IsGetBedding(string keyValue, string status) + { + try + { + stuInfoFreshService.IsGetBedding(keyValue, status); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + /// /// 缴费 /// 主键 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshEntity.cs index 0f076d9da..d9fa427fd 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshEntity.cs @@ -644,6 +644,32 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// [Column("BANKNO")] public string BankNo { get; set; } + + /// + /// 领军训服装时间 + /// + /// + [Column("GETMILICLOTHESDATE")] + public DateTime? GetMiliClothesDate { get; set; } + /// + /// 领军训服装状态 + /// + /// + [Column("GETMILICLOTHESSTATUS")] + public string GetMiliClothesStatus { get; set; } + + /// + /// 领床上用品时间 + /// + /// + [Column("GETBEDDINGDATE")] + public DateTime? GetBeddingDate { get; set; } + /// + /// 领床上用品状态 + /// + /// + [Column("GETBEDDINGSTATUS")] + public string GetBeddingStatus { get; set; } #endregion #region 扩展操作 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshIBLL.cs index 46f4460ce..ed30b2e7e 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshIBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshIBLL.cs @@ -166,6 +166,20 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// void IsGetCard(string keyValue, string status); + /// + /// 领取军训服装 + /// 主键 + /// + /// + void IsGetMiliClothes(string keyValue, string status); + + /// + /// 领取床上用品 + /// 主键 + /// + /// + void IsGetBedding(string keyValue, string status); + /// /// 缴费 /// 主键 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshService.cs index 64b293b98..d2f057ceb 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoFresh/StuInfoFreshService.cs @@ -1104,6 +1104,66 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } } + /// + /// 领取军训服装 + /// 主键 + /// + /// + public void IsGetMiliClothes(string keyValue, string status) + { + try + { + if (status == "1")//领取 + { + this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetMiliClothesStatus='1',GetMiliClothesDate='" + DateTime.Now + "' where ID='" + keyValue + "' "); + } + else + { + this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetMiliClothesStatus='0',GetMiliClothesDate=null where ID='" + keyValue + "' "); + } + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + /// + /// 领取床上用品 + /// 主键 + /// + /// + public void IsGetBedding(string keyValue, string status) + { + try + { + if (status == "1")//领取 + { + this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetBeddingStatus='1',GetBeddingDate='" + DateTime.Now + "' where ID='" + keyValue + "' "); + } + else + { + this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetBeddingStatus='0',GetBeddingDate=null where ID='" + keyValue + "' "); + } + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } /// /// 缴费 /// 主键 From c5ffa080e11a23a91542cf80a1dc4462ada67a52 Mon Sep 17 00:00:00 2001 From: dyy <807692433@qq.com> Date: Mon, 11 Jul 2022 10:51:25 +0800 Subject: [PATCH 03/14] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=91?= =?UTF-8?q?=E6=96=B0=E7=94=9F=E4=BF=A1=E6=81=AF=E7=BB=9F=E8=AE=A1=EF=BC=9A?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=A2=86=E5=86=9B=E8=AE=AD=E6=9C=8D=E8=A3=85?= =?UTF-8?q?=E3=80=81=E9=A2=86=E5=BA=8A=E4=B8=8A=E7=94=A8=E5=93=81=E4=BA=BA?= =?UTF-8?q?=E6=95=B0=EF=BC=9B=E6=96=B0=E7=94=9F=E4=BF=A1=E6=81=AF=E7=8F=AD?= =?UTF-8?q?=E7=BA=A7=E7=BB=9F=E8=AE=A1=EF=BC=9A=E5=A2=9E=E5=8A=A0=E7=8F=AD?= =?UTF-8?q?=E7=BA=A7=E6=90=9C=E7=B4=A2=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/StuInfoFreshController.cs | 16 ++++++++++++++-- .../StuInfoFresh/StatisticClassIndex.cshtml | 3 +++ .../Views/StuInfoFresh/StatisticClassIndex.js | 15 +++++++++++---- .../Views/StuInfoFresh/StatisticIndex.js | 6 +++++- 4 files changed, 33 insertions(+), 7 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs index b287f0901..ffe6bdecd 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs @@ -1099,7 +1099,9 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers GetKeyNum = x.Count(y => y.GetKeyStatus == "1"), GetCardNum = x.Count(y => y.GetCardStatus == "1"), CollectFileNum = x.Count(y => y.CollectFileStatus == "1"), - LoanNum = x.Count(y => y.StudentLoanStatus == "1") + LoanNum = x.Count(y => y.StudentLoanStatus == "1"), + GetMiliClothesNum = x.Count(y => y.GetMiliClothesStatus == "1"), + GetBeddingNum = x.Count(y => y.GetBeddingStatus == "1") }).OrderBy(x => x.MajorNo); //var aa = new StatisticModel @@ -1143,7 +1145,9 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers GetKeyNum = x.Count(y => y.GetKeyStatus == "1"), GetCardNum = x.Count(y => y.GetCardStatus == "1"), CollectFileNum = x.Count(y => y.CollectFileStatus == "1"), - LoanNum = x.Count(y => y.StudentLoanStatus == "1") + LoanNum = x.Count(y => y.StudentLoanStatus == "1"), + GetMiliClothesNum = x.Count(y => y.GetMiliClothesStatus == "1"), + GetBeddingNum = x.Count(y => y.GetBeddingStatus == "1") }).OrderBy(x => x.MajorNo).ThenBy(x => x.ClassNo); return Success(list); } @@ -1186,6 +1190,14 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers /// 贷款人数 /// public int LoanNum { get; set; } + /// + /// 已领取军训服装人数 + /// + public int GetMiliClothesNum { get; set; } + /// + /// 已领取床上用品人数 + /// + public int GetBeddingNum { get; set; } } /// /// 获取列表数据 diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.cshtml index 713285640..263d3170c 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.cshtml @@ -20,6 +20,9 @@
+
+
+
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js index 78d35159f..739f40fff 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js @@ -8,6 +8,7 @@ var selectedRow; var refreshGirdData; var bootstrap = function ($, learun) { "use strict"; + var ClassNo = ""; var page = { init: function () { page.initGird(); @@ -22,7 +23,9 @@ var bootstrap = function ($, learun) { learun.alert.warning("请选择年级!"); return; } - page.search({ Grade: Grade }); + ClassNo = $('#ClassNo').lrselectGet(); + + page.search({ Grade: Grade, ClassNo: ClassNo }); }); // 刷新 $('#lr_refresh').on('click', function () { @@ -41,9 +44,11 @@ var bootstrap = function ($, learun) { text: 'text' }); $('#Grade').lrselectSet(Grade); + //班级 + $('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' }); }, initGird: function () { - $('#gridtable').lrAuthorizeJfGrid({ + $('#gridtable').jfGrid({ url: top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/GetStatisticListOfClass', headData: [ { label: '年级', name: 'Grade', width: 80, align: "left" }, @@ -58,14 +63,16 @@ var bootstrap = function ($, learun) { { label: '贷款人数', name: 'LoanNum', width: 100, align: "left", statistics: true }, { label: '已领取钥匙人数', name: 'GetKeyNum', width: 100, align: "left", statistics: true }, { label: '已领取校园卡人数', name: 'GetCardNum', width: 120, align: "left", statistics: true }, - { label: '已收取档案人数', name: 'CollectFileNum', width: 100, align: "left", statistics: true }, + { label: '已收取档案人数', name: 'CollectFileNum', width: 100, align: "left", statistics: true }, + { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left" }, + { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left" }, ], mainId: 'MajorNo', isPage: false, sidx: 'MajorNo,ClassNo', sord: 'asc', }); - page.search({ Grade: Grade }); + page.search({ Grade: Grade, ClassNo: ClassNo }); }, search: function (param) { param = param || {}; diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js index 0312eeed9..e6e2a2631 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js @@ -43,7 +43,7 @@ var bootstrap = function ($, learun) { $('#Grade').lrselectSet(Grade); }, initGird: function () { - $('#gridtable').lrAuthorizeJfGrid({ + $('#gridtable').jfGrid({ url: top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/GetStatisticList', headData: [ { label: '年级', name: 'Grade', width: 80, align: "left" }, @@ -57,6 +57,8 @@ var bootstrap = function ($, learun) { { label: '已领取钥匙人数', name: 'GetKeyNum', width: 100, align: "left", statistics: true }, { label: '已领取校园卡人数', name: 'GetCardNum', width: 120, align: "left", statistics: true }, { label: '已收取档案人数', name: 'CollectFileNum', width: 100, align: "left", statistics: true }, + { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left" }, + { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left" }, ], mainId: 'MajorNo', isPage: false, @@ -78,6 +80,8 @@ var bootstrap = function ($, learun) { { label: '已领取钥匙人数', name: 'GetKeyNum', width: 100, align: "left" }, { label: '已领取校园卡人数', name: 'GetCardNum', width: 120, align: "left" }, { label: '已收取档案人数', name: 'CollectFileNum', width: 100, align: "left" }, + { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left" }, + { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left" }, ], mainId: 'ClassNo', isPage: false, From 9a0f3c6eb65b38edf3347b2f3a84d27d981f8318 Mon Sep 17 00:00:00 2001 From: ndbs Date: Mon, 11 Jul 2022 11:12:38 +0800 Subject: [PATCH 04/14] =?UTF-8?q?=E5=AE=BF=E8=88=8D=E7=AE=A1=E7=90=86---?= =?UTF-8?q?=E6=8C=89=E5=B9=B4=E7=BA=A7=E6=B8=85=E7=A9=BA=E5=AE=BF=E8=88=8D?= =?UTF-8?q?=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/AccommodationController.cs | 20 +++++++++++ .../Views/Accommodation/ClearForm.cshtml | 11 ++++++ .../Views/Accommodation/ClearForm.js | 36 +++++++++++++++++++ .../Accommodation/IndexDistribution.cshtml | 1 + .../Views/Accommodation/IndexDistribution.js | 14 +++++++- .../Learun.Application.Web.csproj | 2 ++ .../Accommodation/AccommodationBLL.cs | 25 +++++++++++++ .../Accommodation/AccommodationIBLL.cs | 3 ++ .../Accommodation/AccommodationService.cs | 21 +++++++++++ 9 files changed, 132 insertions(+), 1 deletion(-) create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.cshtml create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.js diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Controllers/AccommodationController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Controllers/AccommodationController.cs index 24e3ad8cf..210baddb4 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Controllers/AccommodationController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Controllers/AccommodationController.cs @@ -208,7 +208,17 @@ namespace Learun.Application.Web.Areas.LogisticsManagement.Controllers return View(); } + /// + /// 分类管理 + /// + /// + [HttpGet] + public ActionResult ClearForm() + { + return View(); + } + #endregion #region 获取数据 @@ -521,6 +531,16 @@ namespace Learun.Application.Web.Areas.LogisticsManagement.Controllers return Success("同步成功"); } + /// + /// 按条件清空 + /// + /// + public ActionResult StudentClear(string Grade) + { + accommodationIBLL.ClearEntity(Grade); + return Success("清空成功"); + } + #endregion } diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.cshtml new file mode 100644 index 000000000..100f49f0c --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.cshtml @@ -0,0 +1,11 @@ +@{ + ViewBag.Title = "开课计划"; + Layout = "~/Views/Shared/_Form.cshtml"; +} +
+
+
年级*
+
+
+
+@Html.AppendJsFile("/Areas/LogisticsManagement/Views/Accommodation/ClearForm.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.js new file mode 100644 index 000000000..5493999b8 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/ClearForm.js @@ -0,0 +1,36 @@ +/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) + * Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + * 创建人:超级管理员 + * 日 期:2021-11-29 11:43 + * 描 述:开课计划 + */ +var acceptClick; +var keyValue = request('keyValue'); +var bootstrap = function ($, learun) { + "use strict"; + var page = { + init: function () { + $('.lr-form-wrap').lrscroll(); + page.bind(); + }, + bind: function () { + $('#Grade').lrselect({ + url: top.$.rootUrl + '/EducationalAdministration/ClassInfo/GenerateNearByYear', + value: 'value', + text: 'text' + }); + } + }; + // 保存数据 + acceptClick = function (callBack) { + if (!$('body').lrValidform()) { + return false; + } + var postData = $('#form').lrGetFormData(); + var Grade = postData.Grade; + learun.postForm(top.$.rootUrl + '/LogisticsManagement/Accommodation/StudentClear', { Grade: Grade }, function () { + learun.frameTab.currentIframe().refreshGirdData() + }); + }; + page.init(); +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.cshtml index 2b92a19cb..262f931ab 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.cshtml @@ -80,6 +80,7 @@  分配系  分配专业班级  分配宿舍 +  按年级清空  打印
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.js index 71a969a6d..5f5a65ac7 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Accommodation/IndexDistribution.js @@ -315,7 +315,19 @@ var bootstrap = function ($, learun) { } }); }); - + //清空 + $("#lr_Clear").on("click", function () { + learun.layerForm({ + id: 'form', + title: '按年级清空', + url: top.$.rootUrl + '/LogisticsManagement/Accommodation/ClearForm', + width: 400, + height: 300, + callBack: function (id) { + return top[id].acceptClick(); + } + }); + }); }, //初始化左侧树 initTree: function () { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj index 395933261..58e7f2d18 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj @@ -1335,6 +1335,7 @@ + @@ -7911,6 +7912,7 @@ + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs index 41bda8acd..3252d1a1e 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs @@ -830,6 +830,31 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement } } + + + /// + /// 清空实体数据 + /// 主键 + /// + /// + public void ClearEntity(string Grade) + { + try + { + accommodationService.ClearEntity(Grade); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } #endregion } diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationIBLL.cs index 2050f1292..03621abf6 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationIBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationIBLL.cs @@ -106,6 +106,9 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement object GetFloorList(string parentID); object GetRoomList(string parentID); object GetBedList(string parentID); + + void ClearEntity(string Grade); + #endregion } diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs index ade272d6d..6eed65103 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs @@ -1866,6 +1866,27 @@ where ID='{ParentID}' } } + /// + /// 按年级清空 + /// + public void ClearEntity(string Grade) + { + try + { + BaseRepository("CollegeMIS").ExecuteBySql($"delete from Acc_DormitoryBuild where StudentID in(select StuNo from StuInfoBasic where Grade ='{Grade}')"); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } #endregion 提交数据 } } \ No newline at end of file From 3f52acad31c752a3b733c46d5f70bd2af4d240a0 Mon Sep 17 00:00:00 2001 From: ndbs Date: Mon, 11 Jul 2022 11:27:40 +0800 Subject: [PATCH 05/14] =?UTF-8?q?=E6=99=9A=E5=BD=92=E8=A7=84=E5=88=99?= =?UTF-8?q?=E9=AA=8C=E8=AF=81=E5=A4=B1=E8=B4=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../EducationalAdministration/Views/StuInfoBasic/Form.cshtml | 2 +- .../LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoBasic/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoBasic/Form.cshtml index a862ec705..603539df8 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoBasic/Form.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoBasic/Form.cshtml @@ -113,7 +113,7 @@
是否单亲
-
+
父亲姓名
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml index 100ee31f8..f83b61a94 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml @@ -13,14 +13,14 @@
推送班主任*
-
+
推送时间点*
-
启用*
+
启用*
From fad4edb1401ffea333fe844e81823fe218ce23a2 Mon Sep 17 00:00:00 2001 From: dyy <807692433@qq.com> Date: Mon, 11 Jul 2022 15:23:28 +0800 Subject: [PATCH 06/14] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=91?= =?UTF-8?q?=E5=AD=A6=E7=94=9F=E8=AF=84=E6=95=99=E6=83=85=E5=86=B5=E3=80=81?= =?UTF-8?q?=E6=95=99=E5=B8=88=E8=A2=AB=E8=AF=84=E6=83=85=E5=86=B5=E3=80=81?= =?UTF-8?q?=E5=AD=A6=E5=AD=90=E5=9C=A8=E7=BA=BF-=E7=BD=91=E4=B8=8A?= =?UTF-8?q?=E8=AF=84=E6=95=99=E6=96=B0=EF=BC=9A=E4=B8=8D=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=80=80=E5=AD=A6=E3=80=81=E4=BC=91=E5=AD=A6=E7=9A=84=E5=AD=A6?= =?UTF-8?q?=E7=94=9F=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StuInfoBasic/StuInfoBasicEntity.cs | 2 +- .../StuInfoBasicChange/StuInfoBasicChangeService.cs | 4 ++-- .../EvaluationTeach/Eval_Main/Eval_MainService.cs | 4 +++- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasic/StuInfoBasicEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasic/StuInfoBasicEntity.cs index 1ccbf3288..9ea4d92c7 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasic/StuInfoBasicEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasic/StuInfoBasicEntity.cs @@ -459,7 +459,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration [Column("STUDYMODALITY")] public string StudyModality { get; set; } /// - /// 学籍异动状态 + /// 学籍异动状态(异动类型为退学、休学时值为1) /// /// [Column("CHANGESTATUS")] diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasicChange/StuInfoBasicChangeService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasicChange/StuInfoBasicChangeService.cs index a3e3e0ede..c592dc5ae 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasicChange/StuInfoBasicChangeService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuInfoBasicChange/StuInfoBasicChangeService.cs @@ -210,13 +210,13 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration var classInfoEntity = db.FindEntity(x => x.ClassNo == entity.ClassNo); if (classInfoEntity != null) { - db.ExecuteBySql($"update StuInfoBasic set DeptNo='{entity.DeptNo}',MajorNo='{entity.MajorNo}',ClassNo='{entity.ClassNo}',Grade='{classInfoEntity.Grade}' where StuNo='{entity.StuNo}' "); + db.ExecuteBySql($"update StuInfoBasic set DeptNo='{entity.DeptNo}',MajorNo='{entity.MajorNo}',ClassNo='{entity.ClassNo}',Grade='{classInfoEntity.Grade}',MoveType =null,MoveStatus=null where StuNo='{entity.StuNo}' "); } } else if (entity.StuChangeType == "04" || entity.StuChangeType == "05") //退学、休学 { //改信息;显示成绩; - db.ExecuteBySql($"update StuInfoBasic set ChangeStatus=null where StuNo='{entity.StuNo}' "); + db.ExecuteBySql($"update StuInfoBasic set ChangeStatus=null,MoveType =null,MoveStatus=null where StuNo='{entity.StuNo}' "); } //修改状态 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EvaluationTeach/Eval_Main/Eval_MainService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EvaluationTeach/Eval_Main/Eval_MainService.cs index 31d48d134..85120d8fa 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EvaluationTeach/Eval_Main/Eval_MainService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EvaluationTeach/Eval_Main/Eval_MainService.cs @@ -72,7 +72,7 @@ namespace Learun.Application.TwoDevelopment.EvaluationTeach var queryParam = queryJson.ToJObject(); var strSql = new StringBuilder(); strSql.Append("select aa.*,bb.UID,cc.EmpName,dd.LessonName from (select a.LessonNo,a.EmpNo,a.AcademicYearNo,a.Semester,b.VID,a.StuNo from " + misdbname + ".dbo.StuSelectLessonList a "); - strSql.Append("left join Eval_Main b on a.AcademicYearNo=b.AcademicYearNo and a.Semester=b.Semester where b.Status=1 and a.StuNo='" + queryParam["StuNo"] + "') aa "); + strSql.Append("left join Eval_Main b on a.AcademicYearNo=b.AcademicYearNo and a.Semester=b.Semester where b.Status=1 and a.StuNo='" + queryParam["StuNo"] + "' and a.StuNo not in (select StuNo from " + misdbname + ".dbo.StuInfoBasic where ChangeStatus=1) ) aa "); strSql.Append("left join (select distinct b.EmpNo, b.LessonNo, b.UID from Eval_Question a left join Eval_QuestionResult b on a.QID=b.QID) bb on aa.EmpNo=bb.EmpNo and aa.LessonNo=bb.LessonNo and aa.StuNo=bb.UID "); strSql.Append("left join " + misdbname + ".dbo.EmpInfo cc on aa.EmpNo=cc.EmpNo left join " + misdbname + ".dbo.LessonInfo dd on aa.LessonNo = dd.LessonNo "); if (pagination != null) @@ -365,6 +365,7 @@ from " + misdbname + @".dbo.StuSelectLessonList a left join Eval_Main b on a.AcademicYearNo=b.AcademicYearNo and a.Semester=b.Semester where b.Status=1 and b.VID='" + queryParam["VID"] + @"' and a.StuNo is not null and a.StuNo <> '' +and a.StuNo not in (select StuNo from " + misdbname + @".dbo.StuInfoBasic where ChangeStatus=1) ) aa left join ( @@ -524,6 +525,7 @@ from " + misdbname + @".dbo.StuSelectLessonList a left join Eval_Main b on a.AcademicYearNo=b.AcademicYearNo and a.Semester=b.Semester where b.Status=1 and b.VID='" + queryParam["VID"] + @"' and a.StuNo is not null and a.StuNo <> '' +and a.StuNo not in (select StuNo from " + misdbname + @".dbo.StuInfoBasic where ChangeStatus=1) group by a.LessonNo,a.EmpNo,a.LessonName ) ss left join From 3b8b5f6fd2e3f6af7a9d9bdfb84217c1b54f99c9 Mon Sep 17 00:00:00 2001 From: ndbs Date: Tue, 12 Jul 2022 10:33:24 +0800 Subject: [PATCH 07/14] =?UTF-8?q?=E5=AE=BF=E8=88=8D=E7=AE=A1=E7=90=86--?= =?UTF-8?q?=E5=AD=A6=E7=94=9F=E8=B0=83=E5=AE=BF=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Acc_DormitoryChangeController.cs | 158 +++++++ .../Views/Acc_DormitoryChange/Form.cshtml | 47 +++ .../Views/Acc_DormitoryChange/Form.js | 191 +++++++++ .../Views/Acc_DormitoryChange/Index.cshtml | 54 +++ .../Views/Acc_DormitoryChange/Index.js | 389 ++++++++++++++++++ .../Learun.Application.Web.csproj | 7 + .../XmlConfig/ioc.config | 6 +- .../Acc_DormitoryChangeMap.cs | 29 ++ .../Learun.Application.Mapping.csproj | 1 + .../Acc_DormitoryChangeBLL.cs | 193 +++++++++ .../Acc_DormitoryChangeEntity.cs | 156 +++++++ .../Acc_DormitoryChangeIBLL.cs | 64 +++ .../Acc_DormitoryChangeService.cs | 272 ++++++++++++ .../Learun.Application.TwoDevelopment.csproj | 4 + .../Learun.Application.WorkFlow.csproj | 1 + .../NodeMethod/Acc_DormitoryChangeMethod.cs | 28 ++ 16 files changed, 1598 insertions(+), 2 deletions(-) create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Acc_DormitoryChangeController.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.cshtml create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.js create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.cshtml create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.js create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/EducationalAdministration/Acc_DormitoryChangeMap.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeBLL.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeEntity.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeIBLL.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeService.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/Acc_DormitoryChangeMethod.cs diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Acc_DormitoryChangeController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Acc_DormitoryChangeController.cs new file mode 100644 index 000000000..d3e7b596e --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Acc_DormitoryChangeController.cs @@ -0,0 +1,158 @@ +using Learun.Util; +using System.Data; +using Learun.Application.TwoDevelopment.EducationalAdministration; +using System.Web.Mvc; +using Learun.Application.TwoDevelopment.LR_CodeDemo; +using System.Collections.Generic; +using Learun.Application.Base.SystemModule; + +namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-07-11 14:34 + /// 描 述:宿舍调换申请 + /// + public class Acc_DormitoryChangeController : MvcControllerBase + { + private Acc_DormitoryChangeIBLL acc_DormitoryChangeIBLL = new Acc_DormitoryChangeBLL(); + private CodeRuleIBLL codeRuleIBLL = new CodeRuleBLL(); + + #region 视图功能 + + /// + /// 主页面 + /// + /// + [HttpGet] + public ActionResult Index() + { + return View(); + } + /// + /// 表单页 + /// + /// + [HttpGet] + public ActionResult Form() + { + return View(); + } + /// + /// 表单页 + /// + /// + [HttpGet] + public ActionResult FormView() + { + return View(); + } + + #endregion + + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 分页参数 + /// 查询参数 + /// + [HttpGet] + [AjaxOnly] + public ActionResult GetPageList(string pagination, string queryJson) + { + Pagination paginationobj = pagination.ToObject(); + var data = acc_DormitoryChangeIBLL.GetPageList(paginationobj, queryJson); + var jsonData = new + { + rows = data, + total = paginationobj.total, + page = paginationobj.page, + records = paginationobj.records + }; + return Success(jsonData); + } + /// + /// 获取表单数据 + /// + /// 主键 + /// + [HttpGet] + [AjaxOnly] + public ActionResult GetFormData(string keyValue) + { + var Acc_DormitoryChangeData = acc_DormitoryChangeIBLL.GetAcc_DormitoryChangeEntity(keyValue); + var jsonData = new + { + Acc_DormitoryChange = Acc_DormitoryChangeData, + }; + return Success(jsonData); + } + /// + /// 获取表单数据 + /// + /// 流程实例主键 + /// + [HttpGet] + [AjaxOnly] + public ActionResult GetFormDataByProcessId(string processId) + { + var Acc_DormitoryChangeData = acc_DormitoryChangeIBLL.GetEntityByProcessId(processId); + var jsonData = new + { + Acc_DormitoryChange = Acc_DormitoryChangeData, + }; + return Success(jsonData); + } + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + /// + [HttpPost] + [AjaxOnly] + public ActionResult DeleteForm(string keyValue) + { + acc_DormitoryChangeIBLL.DeleteEntity(keyValue); + return Success("删除成功!"); + } + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + /// + [HttpPost] + [ValidateAntiForgeryToken] + [AjaxOnly] + public ActionResult SaveForm(string keyValue, string strEntity) + { + Acc_DormitoryChangeEntity entity = strEntity.ToObject(); + if (entity.HisDormitory == entity.Dormitory && entity.HisUnit == entity.Unit && entity.HisFloor == entity.Floor + && entity.HisRId == entity.RId) + { + return Fail("新宿舍请勿选择与旧宿舍一致"); + } + acc_DormitoryChangeIBLL.SaveEntity(keyValue, entity); + return Success("保存成功!"); + } + + [HttpPost] + [AjaxOnly] + public ActionResult SubmitForm(string status, string processId, string keyValue) + { + acc_DormitoryChangeIBLL.SubmitEntity(status, processId, keyValue); + return Success("提交成功!"); + } + + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.cshtml new file mode 100644 index 000000000..75d386c7d --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.cshtml @@ -0,0 +1,47 @@ +@{ + ViewBag.Title = "宿舍调换申请"; + Layout = "~/Views/Shared/_Form.cshtml"; +} +
+
+
宿舍楼*
+
+
+
+
新宿舍楼*
+
+
+
+
单元*
+
+
+
+
新单元*
+
+
+
+
楼层*
+
+
+
+
新楼层*
+
+
+
+
宿舍*
+
+
+
+
新宿舍*
+
+
+
+
原因*
+ +
+
+
备注
+ +
+
+@Html.AppendJsFile("/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.js new file mode 100644 index 000000000..ead64884b --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Form.js @@ -0,0 +1,191 @@ +/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) + * Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + * 创建人:超级管理员 + * 日 期:2022-07-11 14:34 + * 描 述:宿舍调换申请 + */ +var acceptClick; +var keyValue = request('keyValue'); +// 设置权限 +var setAuthorize; +// 设置表单数据 +var setFormData; +// 验证数据是否填写完整 +var validForm; +// 保存数据 +var save; +var bootstrap = function ($, learun) { + "use strict"; + // 设置权限 + setAuthorize = function (data) { + if (!!data) { + for (var field in data) { + if (data[field].isLook != 1) {// 如果没有查看权限就直接移除 + $('#' + data[field].fieldId).parent().remove(); + } + else { + if (data[field].isEdit != 1) { + $('#' + data[field].fieldId).attr('disabled', 'disabled'); + if ($('#' + data[field].fieldId).hasClass('lrUploader-wrap')) { + $('#' + data[field].fieldId).css({ 'padding-right': '58px' }); + $('#' + data[field].fieldId).find('.btn-success').remove(); + } + } + } + } + } + }; + var page = { + init: function () { + $('.lr-form-wrap').lrscroll(); + page.bind(); + page.initData(); + }, + bind: function () { + $('#HisDormitory').lrDataSourceSelect({ + code: 'Acc_DormitoryData', value: 'id', text: 'name', select: function (item) { + if (item) { + $('#HisUnit').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: 'Acc_UnitData', strWhere: "ParentID='" + item.id + "' order by name" } + }); + } + } + }); + $('#HisUnit').lrselect({ + text: 'name', + value: 'id', + select: function (item) { + if (item) { + $('#HisFloor').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: 'Acc_FloorData', strWhere: "ParentID='" + item.id + "' order by name" } + }); + } + } + }); + $('#HisFloor').lrselect({ + text: 'name', + value: 'id', + select: function (item) { + if (item) { + $('#HisRId').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: 'Acc_RoomData', strWhere: "ParentID='" + item.id + "' order by name" } + }); + } + } + }); + + $('#HisRId').lrselect({ + text: 'name', + value: 'id', + allowSearch: true + }) + $('#Dormitory').lrDataSourceSelect({ + code: 'Acc_DormitoryData', value: 'id', text: 'name', select: function (item) { + if (item) { + $('#Unit').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: 'Acc_UnitData', strWhere: "ParentID='" + item.id + "' order by name" } + }); + } + } + }); + $('#Unit').lrselect({ + text: 'name', + value: 'id', + select: function (item) { + if (item) { + $('#Floor').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: 'Acc_FloorData', strWhere: "ParentID='" + item.id + "' order by name" } + }); + } + } + }); + $('#Floor').lrselect({ + text: 'name', + value: 'id', + select: function (item) { + if (item) { + $('#RId').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: 'Acc_RoomData', strWhere: "ParentID='" + item.id + "' order by name" } + }); + } + } + }); + + $('#RId').lrselect({ + text: 'name', + value: 'id', + allowSearch: true + }) + + }, + initData: function () { + if (!!keyValue) { + $.lrSetForm(top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/GetFormData?keyValue=' + keyValue, function (data) { + for (var id in data) { + if (!!data[id].length && data[id].length > 0) { + $('#' + id).jfGridSet('refreshdata', data[id]); + } + else { + $('[data-table="' + id + '"]').lrSetFormData(data[id]); + } + } + }); + } + } + }; + // 设置表单数据 + setFormData = function (processId, param, callback) { + if (!!processId) { + $.lrSetForm(top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/GetFormDataByProcessId?processId=' + processId, function (data) { + for (var id in data) { + if (!!data[id] && data[id].length > 0) { + $('#' + id).jfGridSet('refreshdata', data[id]); + } + else { + if (id == 'Acc_DormitoryChange' && data[id]) { + keyValue = data[id].ID; + } + $('[data-table="' + id + '"]').lrSetFormData(data[id]); + } + } + }); + } + callback && callback(); + } + // 验证数据是否填写完整 + validForm = function () { + if (!$('body').lrValidform()) { + return false; + } + return true; + }; + // 保存数据 + save = function (processId, callBack, i) { + //判断是否是学生 + var IdentityName = learun.clientdata.get(['userinfo']).Description; + if (IdentityName != "学生") { + learun.alert.warning("当前提交者非学生!!!"); + return false; + } + var formData = $('#form').lrGetFormData(); + if (!!processId) { + formData.ProcessId = processId; + } + var postData = { + strEntity: JSON.stringify(formData) + }; + $.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/SaveForm?keyValue=' + keyValue, postData, function (res) { + // 保存成功后才回调 + if (!!callBack) { + callBack(res, i); + } + }); + }; + page.init(); +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.cshtml new file mode 100644 index 000000000..3fd418a45 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.cshtml @@ -0,0 +1,54 @@ +@{ + ViewBag.Title = "宿舍调换申请"; + Layout = "~/Views/Shared/_Index.cshtml"; +} +
+
+
+
+
+
+
+
+
+
学号
+ +
+
+
姓名
+ +
+
+
系部
+
+
+
+
专业
+
+
+
+
班级
+
+
+
+
+
+
+
+
+ +
+ +
+
+
+
+
+
+@Html.AppendJsFile("/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.js new file mode 100644 index 000000000..67c96f85e --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Acc_DormitoryChange/Index.js @@ -0,0 +1,389 @@ +/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) + * Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + * 创建人:超级管理员 + * 日 期:2022-07-11 14:34 + * 描 述:宿舍调换申请 + */ +var refreshGirdData; +var bootstrap = function ($, learun) { + "use strict"; + var processId = ''; + var page = { + init: function () { + page.initGird(); + page.bind(); + }, + bind: function () { + $('#multiple_condition_query').lrMultipleQuery(function (queryJson) { + page.search(queryJson); + }, 220, 400); + // 刷新 + $('#lr_refresh').on('click', function () { + location.reload(); + }); + $('#DeptNo').lrselect({ + value: "deptno", + text: "deptname", + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo', + select: function (item) { + if (item) { + $('#MajorNo').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: "CdMajorInfo", strWhere: "DeptNo='" + item.deptno + "'" } + }); + } + else { + $('#MajorNo').lrselectRefresh({ + url: "", + data: [] + }); + } + $('#ClassNo').lrselectRefresh({ + url: "", + data: [] + }); + } + }); + $('#MajorNo').lrselect({ + value: "majorno", + text: "majorname", + select: function (item) { + if (item) { + $('#ClassNo').lrselectRefresh({ + url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', + param: { code: "bjsj", strWhere: "DeptNo='" + item.deptno + "' and majorno='" + item.majorno + "'" } + }); + } + + } + }); + + + $('#MajorNo').on("click", + function () { + var data = $('#DeptNo').lrselectGet(); + if (!data) { + learun.alert.error('请先选择系'); + } + }); + $('#ClassNo').on("click", + function () { + var data1 = $('#DeptNo').lrselectGet(); + var data2 = $('#MajorNo').lrselectGet(); + if (!data1 || !data2) { + learun.alert.error('请先选择系和专业'); + } + }); + + $('#ClassNo').lrselect({ + value: "classno", + text: "classname" + }); + // 新增 + $('#lr_add').on('click', function () { + learun.layerForm({ + id: 'form', + title: '新增', + url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/Form', + width: 600, + height: 450, + callBack: function (id) { + var res = false; + // 验证数据 + res = top[id].validForm(); + // 保存数据 + if (res) { + res = top[id].save('', function () { + page.search(); + }); + } + return res; + } + }); + }); + // 编辑 + $('#lr_edit').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('ID'); + if (learun.checkrow(keyValue)) { + var CheckStatus = $('#gridtable').jfGridValue('Status'); + if (CheckStatus != "0") { + learun.alert.warning("当前项已提交!"); + return false; + } + learun.layerForm({ + id: 'form', + title: '编辑', + url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/Form?keyValue=' + keyValue, + width: 600, + height: 450, + callBack: function (id) { + var res = false; + // 验证数据 + res = top[id].validForm(); + // 保存数据 + if (res) { + res = top[id].save('', function () { + page.search(); + }); + } + return res; + } + }); + } + }); + // 删除 + $('#lr_delete').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('ID'); + if (learun.checkrow(keyValue)) { + var CheckStatus = $('#gridtable').jfGridValue('Status'); + if (CheckStatus != "0") { + learun.alert.warning("当前项已提交!"); + return false; + } + learun.layerConfirm('是否确认删除该项!', function (res) { + if (res) { + learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/DeleteForm', { keyValue: keyValue }, function () { + refreshGirdData(); + }); + } + }); + } + }); + //  查看 + $('#lr_view').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('Id'); + if (learun.checkrow(keyValue)) { + learun.layerForm({ + id: 'formview', + title: '查看', + url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/FormView?keyValue=' + keyValue, + width: 1000, + height: 800, + btn: null + }); + } + }); + //  提交 + $('#lr_submit').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('ID'); + if (learun.checkrow(keyValue)) { + var CheckStatus = $('#gridtable').jfGridValue('Status'); + if (CheckStatus != "0") { + learun.alert.warning("当前项已提交!"); + return false; + } + learun.layerConfirm('是否确认提交该项!', function (res) { + if (res) { + processId = learun.newGuid(); + learun.postForm(top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/SubmitForm', { keyValue: keyValue, status: "1", processId: processId }, function (res) { + refreshGirdData(res, {}); + }); + + } + }); + } + }); + }, + // 初始化列表 + initGird: function () { + $('#gridtable').jfGrid({ + url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/GetPageList', + headData: [ + { label: "学号", name: "StuNo", width: 100, align: "left" }, + { label: "姓名", name: "StuName", width: 100, align: "left" }, + { + label: "系所", name: "DeptNo", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdDeptInfo', + key: value, + keyId: 'deptno', + callback: function (_data) { + callback(_data['deptname']); + } + }); + } + }, + { + label: "专业", name: "MajorNo", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdMajorInfo', + key: value, + keyId: 'majorno', + callback: function (_data) { + callback(_data['majorname']); + } + }); + } + }, + { + label: "班级", name: "ClassNo", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj', + key: value, + keyId: 'classno', + callback: function (_data) { + callback(_data['classname']); + } + }); + } + }, + { label: "原因", name: "Reason", width: 100, align: "left" }, + { + label: "性别", name: "Sex", width: 100, align: "left", + formatter: function (cellvalue) { + return cellvalue == true ? "男" : "女"; + } + }, + { + label: "原宿舍楼", name: "HisDormitory", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_DormitoryData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "原单元", name: "Unit", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_UnitData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "原楼层", name: "Floor", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_FloorData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "原宿舍", name: "RId", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_RoomData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "新宿舍楼", name: "Dormitory", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_DormitoryData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "新单元", name: "Unit", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_UnitData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "新楼层", name: "Floor", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_FloorData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "新宿舍", name: "RId", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_RoomData', + key: value, + keyId: 'id', + callback: function (_data) { + callback(_data['name']); + } + }); + } + }, + { + label: "审批状态", name: "Status", width: 100, align: "center", + formatter: function (cellvalue, row) { + if (cellvalue == 0) { + return '草稿'; + } if (cellvalue == 1) { + return '审批中'; + } else if (cellvalue == 2) { + return '同意'; + } else if (cellvalue == 3) { + return '不同意'; + } + } + }, + { label: "备注", name: "Remark", width: 100, align: "left" }, + ], + mainId: 'ID', + sidx: 'CreateTime', + sord: 'desc', + isPage: true + }); + page.search(); + }, + search: function (param) { + param = param || {}; + $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); + } + }; + refreshGirdData = function (res, postData) { + if (!!res) { + if (res.code == 200) { + // 发起流程 + var postData = { + schemeCode: 'DorChange',// 填写流程对应模板编号 + processId: processId, + level: '1', + }; + learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) { + learun.loading(false); + }); + } + page.search(); + } + }; + page.init(); +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj index 58e7f2d18..d8023669d 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj @@ -839,6 +839,7 @@ + @@ -949,6 +950,7 @@ + @@ -6586,6 +6588,10 @@ + + + + @@ -7913,6 +7919,7 @@ + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config b/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config index 2f1f612c2..f51265c4d 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config @@ -6,7 +6,7 @@ - + @@ -37,6 +37,7 @@ + @@ -85,7 +86,8 @@ - + + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/EducationalAdministration/Acc_DormitoryChangeMap.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/EducationalAdministration/Acc_DormitoryChangeMap.cs new file mode 100644 index 000000000..fdb84f501 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/EducationalAdministration/Acc_DormitoryChangeMap.cs @@ -0,0 +1,29 @@ +using Learun.Application.TwoDevelopment.EducationalAdministration; +using System.Data.Entity.ModelConfiguration; + +namespace Learun.Application.Mapping +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-07-11 14:34 + /// 描 述:宿舍调换申请 + /// + public class Acc_DormitoryChangeMap : EntityTypeConfiguration + { + public Acc_DormitoryChangeMap() + { + #region 表、主键 + //表 + this.ToTable("ACC_DORMITORYCHANGE"); + //主键 + this.HasKey(t => t.ID); + #endregion + + #region 配置关系 + #endregion + } + } +} + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj index 364b1bba1..dc086b634 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj @@ -593,6 +593,7 @@ + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeBLL.cs new file mode 100644 index 000000000..e20fe62f5 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeBLL.cs @@ -0,0 +1,193 @@ +using Learun.Util; +using System; +using System.Data; +using System.Collections.Generic; + +namespace Learun.Application.TwoDevelopment.EducationalAdministration +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-07-11 14:34 + /// 描 述:宿舍调换申请 + /// + public class Acc_DormitoryChangeBLL : Acc_DormitoryChangeIBLL + { + private Acc_DormitoryChangeService acc_DormitoryChangeService = new Acc_DormitoryChangeService(); + + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 分页参数 + /// 查询参数 + /// + public IEnumerable GetPageList(Pagination pagination, string queryJson) + { + try + { + return acc_DormitoryChangeService.GetPageList(pagination, queryJson); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + /// + /// 获取Acc_DormitoryChange表实体数据 + /// + /// 主键 + /// + public Acc_DormitoryChangeEntity GetAcc_DormitoryChangeEntity(string keyValue) + { + try + { + return acc_DormitoryChangeService.GetAcc_DormitoryChangeEntity(keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + /// + /// 获取主表实体数据 + /// + /// 流程实例ID + /// + public Acc_DormitoryChangeEntity GetEntityByProcessId(string processId) + { + try + { + return acc_DormitoryChangeService.GetEntityByProcessId(processId); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + public void DeleteEntity(string keyValue) + { + try + { + acc_DormitoryChangeService.DeleteEntity(keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + public void SaveEntity(string keyValue, Acc_DormitoryChangeEntity entity) + { + try + { + acc_DormitoryChangeService.SaveEntity(keyValue, entity); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + public void SubmitEntity(string status, string processId, string keyValue) + { + try + { + acc_DormitoryChangeService.SubmitEntity(status, processId, keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + /// + /// 审核实体数据 + /// + /// 主键 + public void ChangeStatusByProcessId(string status, string processId) + { + try + { + acc_DormitoryChangeService.ChangeStatusByProcessId(status, processId); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeEntity.cs new file mode 100644 index 000000000..e41eb063d --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeEntity.cs @@ -0,0 +1,156 @@ +using Learun.Util; +using System; +using System.ComponentModel.DataAnnotations.Schema; + +namespace Learun.Application.TwoDevelopment.EducationalAdministration +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-07-11 14:34 + /// 描 述:宿舍调换申请 + /// + public class Acc_DormitoryChangeEntity + { + #region 实体成员 + /// + /// ID + /// + [Column("ID")] + public string ID { get; set; } + /// + /// StuNo + /// + [Column("STUNO")] + public string StuNo { get; set; } + /// + /// StuName + /// + [Column("STUNAME")] + public string StuName { get; set; } + /// + /// Sex + /// + [Column("SEX")] + public bool? Sex { get; set; } + /// + /// Grade + /// + [Column("GRADE")] + public string Grade { get; set; } + /// + /// ClassNo + /// + [Column("CLASSNO")] + public string ClassNo { get; set; } + /// + /// MajorNo + /// + [Column("MAJORNO")] + public string MajorNo { get; set; } + /// + /// DeptNo + /// + [Column("DEPTNO")] + public string DeptNo { get; set; } + /// + /// F_School + /// + [Column("F_SCHOOL")] + public string F_School { get; set; } + /// + /// Remark + /// + [Column("REMARK")] + public string Remark { get; set; } + /// + /// CreateTime + /// + [Column("CREATETIME")] + public DateTime? CreateTime { get; set; } + /// + /// ProcessId + /// + [Column("PROCESSID")] + public string ProcessId { get; set; } + /// + /// 宿舍楼 + /// + [Column("DORMITORY")] + public string Dormitory { get; set; } + /// + /// 单元 + /// + [Column("UNIT")] + public string Unit { get; set; } + /// + /// Floor + /// + [Column("FLOOR")] + public string Floor { get; set; } + /// + /// RId + /// + [Column("RID")] + public string RId { get; set; } + /// + /// Reason + /// + [Column("REASON")] + public string Reason { get; set; } + /// + /// HisDormitory + /// + [Column("HISDORMITORY")] + public string HisDormitory { get; set; } + /// + /// HisUnit + /// + [Column("HISUNIT")] + public string HisUnit { get; set; } + /// + /// HisFloor + /// + [Column("HISFLOOR")] + public string HisFloor { get; set; } + /// + /// HisRId + /// + [Column("HISRID")] + public string HisRId { get; set; } + /// + /// 状态 + /// + [Column("STATUS")] + public int? Status { get; set; } + + /// + /// CheckTime + /// + [Column("CHECKTIME")] + public DateTime? CheckTime { get; set; } + #endregion + + #region 扩展操作 + /// + /// 新增调用 + /// + public void Create() + { + this.ID = Guid.NewGuid().ToString(); + } + /// + /// 编辑调用 + /// + /// + public void Modify(string keyValue) + { + this.ID = keyValue; + } + #endregion + #region 扩展字段 + #endregion + } +} + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeIBLL.cs new file mode 100644 index 000000000..4cc68c580 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeIBLL.cs @@ -0,0 +1,64 @@ +using Learun.Util; +using System.Data; +using System.Collections.Generic; + +namespace Learun.Application.TwoDevelopment.EducationalAdministration +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-07-11 14:34 + /// 描 述:宿舍调换申请 + /// + public interface Acc_DormitoryChangeIBLL + { + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 分页参数 + /// 查询参数 + /// + IEnumerable GetPageList(Pagination pagination, string queryJson); + /// + /// 获取Acc_DormitoryChange表实体数据 + /// + /// 主键 + /// + Acc_DormitoryChangeEntity GetAcc_DormitoryChangeEntity(string keyValue); + /// + /// 获取主表实体数据 + /// + /// 流程实例ID + /// + Acc_DormitoryChangeEntity GetEntityByProcessId(string processId); + + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + void DeleteEntity(string keyValue); + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + void SaveEntity(string keyValue, Acc_DormitoryChangeEntity entity); + + void SubmitEntity(string status, string processId, string keyValue); + + /// + /// 审核实体数据 + /// + /// 主键 + void ChangeStatusByProcessId(string status, string processId); + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeService.cs new file mode 100644 index 000000000..595457a53 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Acc_DormitoryChange/Acc_DormitoryChangeService.cs @@ -0,0 +1,272 @@ +using Dapper; +using Learun.DataBase.Repository; +using Learun.Util; +using System; +using System.Collections.Generic; +using System.Data; +using System.Linq; +using System.Text; + +namespace Learun.Application.TwoDevelopment.EducationalAdministration +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-07-11 14:34 + /// 描 述:宿舍调换申请 + /// + public class Acc_DormitoryChangeService : RepositoryFactory + { + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 分页参数 + /// 查询参数 + /// + public IEnumerable GetPageList(Pagination pagination, string queryJson) + { + try + { + var strSql = new StringBuilder(); + strSql.Append("SELECT "); + strSql.Append(@" * "); + strSql.Append(" FROM Acc_DormitoryChange t "); + strSql.Append(" WHERE 1=1 "); + var queryParam = queryJson.ToJObject(); + // 虚拟参数 + var dp = new DynamicParameters(new { }); + if (!queryParam["StuNo"].IsEmpty()) + { + dp.Add("StuNo", queryParam["StuNo"].ToString(), DbType.String); + strSql.Append(" AND t.StuNo like @StuNo "); + } + if (!queryParam["StuName"].IsEmpty()) + { + dp.Add("StuName", "%" + queryParam["StuName"].ToString() + "%", DbType.String); + strSql.Append(" AND t.StuName Like @StuName "); + } + if (!queryParam["DeptNo"].IsEmpty()) + { + dp.Add("DeptNo", "" + queryParam["DeptNo"].ToString() + "", DbType.String); + strSql.Append(" AND t.DeptNo=@DeptNo "); + } + if (!queryParam["MajorNo"].IsEmpty()) + { + dp.Add("MajorNo", "" + queryParam["MajorNo"].ToString() + "", DbType.String); + strSql.Append(" AND t.MajorNo=@MajorNo "); + } + if (!queryParam["ClassNo"].IsEmpty()) + { + dp.Add("ClassNo", "" + queryParam["ClassNo"].ToString() + "", DbType.String); + strSql.Append(" AND t.ClassNo=@ClassNo "); + } + if (!queryParam["Grade"].IsEmpty()) + { + dp.Add("Grade", "" + queryParam["Grade"].ToString() + "", DbType.String); + strSql.Append(" AND t.Grade=@Grade "); + } + return this.BaseRepository("CollegeMIS").FindList(strSql.ToString(), dp, pagination); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + /// + /// 获取Acc_DormitoryChange表实体数据 + /// + /// 主键 + /// + public Acc_DormitoryChangeEntity GetAcc_DormitoryChangeEntity(string keyValue) + { + try + { + return this.BaseRepository("CollegeMIS").FindEntity(keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + /// + /// 获取主表实体数据 + /// + /// 流程实例ID + /// + public Acc_DormitoryChangeEntity GetEntityByProcessId(string processId) + { + try + { + return this.BaseRepository("CollegeMIS").FindEntity(t => t.ProcessId == processId); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + public void DeleteEntity(string keyValue) + { + try + { + this.BaseRepository("CollegeMIS").Delete(t => t.ID == keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + /// + public void SaveEntity(string keyValue, Acc_DormitoryChangeEntity entity) + { + entity.Status = 0; + try + { + if (!string.IsNullOrEmpty(keyValue)) + { + entity.Modify(keyValue); + this.BaseRepository("CollegeMIS").Update(entity); + } + else + { + var UserList = LoginUserInfo.Get(); + if (UserList.Description == "学生") + { + var StuList = this.BaseRepository("CollegeMIS").FindList().FirstOrDefault(x => x.StuNo == UserList.account); + entity.F_School = StuList.F_SchoolId; + entity.DeptNo = StuList.DeptNo; + entity.MajorNo = StuList.MajorNo; + entity.ClassNo = StuList.ClassNo; + entity.Grade = StuList.Grade; + entity.Sex = StuList.GenderNo; + entity.StuName = StuList.StuName; entity.CreateTime = DateTime.Now; + entity.StuNo = StuList.StuNo; + } + entity.Create(); + this.BaseRepository("CollegeMIS").Insert(entity); + } + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + /// + public void SubmitEntity(string status, string processId, string keyValue) + { + try + { + try + { + this.BaseRepository("CollegeMIS").ExecuteBySql("update Acc_DormitoryChange set Status='" + status + "',ProcessId='" + processId + "' where Id='" + keyValue + "' "); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + /// + /// 审核实体数据 + /// + /// 主键 + public void ChangeStatusByProcessId(string status, string processId) + { + try + { + this.BaseRepository("CollegeMIS").ExecuteBySql("update Acc_DormitoryChange set Status='" + status + "',CheckTime='" + DateTime.Now + "' where ProcessId='" + processId + "' "); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj index b0dc69e9d..d588fcac9 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj @@ -1802,6 +1802,10 @@ + + + + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Learun.Application.WorkFlow.csproj b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Learun.Application.WorkFlow.csproj index 4f82fc4c6..37cc98ba7 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Learun.Application.WorkFlow.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Learun.Application.WorkFlow.csproj @@ -101,6 +101,7 @@ + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/Acc_DormitoryChangeMethod.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/Acc_DormitoryChangeMethod.cs new file mode 100644 index 000000000..5dee61203 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/Acc_DormitoryChangeMethod.cs @@ -0,0 +1,28 @@ +using Learun.Application.TwoDevelopment.PersonnelManagement; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Learun.Application.TwoDevelopment.EducationalAdministration; + +namespace Learun.Application.WorkFlow +{ + public class Acc_DormitoryChangeMethod : IWorkFlowMethod + { + Acc_DormitoryChangeIBLL acc_DormitoryChangeIBLL = new Acc_DormitoryChangeBLL(); + + + public void Execute(WfMethodParameter parameter) + { + if (parameter.code == "agree") + { + acc_DormitoryChangeIBLL.ChangeStatusByProcessId("2", parameter.processId); + } + else + { + acc_DormitoryChangeIBLL.ChangeStatusByProcessId("3", parameter.processId); + } + } + } +} From 83fdb96aadfc3ac9f434374c0c30be5b21d9fbf3 Mon Sep 17 00:00:00 2001 From: ndbs Date: Tue, 12 Jul 2022 10:47:47 +0800 Subject: [PATCH 08/14] --- .../Learun.Application.Web/Learun.Application.Web.csproj | 2 -- 1 file changed, 2 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj index d8023669d..1e451c5a7 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj @@ -950,7 +950,6 @@ - @@ -7919,7 +7918,6 @@ - From f60427797e9c8d44bc9031aea02b7ed86e5761c7 Mon Sep 17 00:00:00 2001 From: dyy <807692433@qq.com> Date: Tue, 12 Jul 2022 12:16:18 +0800 Subject: [PATCH 09/14] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=91?= =?UTF-8?q?=E6=88=90=E7=BB=A9=E5=BD=95=E5=85=A5=EF=BC=9A=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=20=E2=80=9C=E6=95=99=E5=AD=A6=E5=B7=A5=E4=BD=9C=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E2=80=9D=20=E4=B8=AD=E5=AF=B9=E5=BA=94=E5=B7=A5?= =?UTF-8?q?=E4=BD=9C=E5=90=8D=E7=A7=B0=E7=9A=84=E6=88=AA=E6=AD=A2=E6=97=B6?= =?UTF-8?q?=E9=97=B4=E7=9A=84=E9=99=90=E5=88=B6=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/StuScoreController.cs | 46 +++++++++++++++++++ .../Controllers/StuScoreNotPassController.cs | 23 ++++++++++ .../StuScoreNotPassTwoController.cs | 23 ++++++++++ .../Views/StuScore/InputScoreIndex.cshtml | 17 +++++-- .../Views/StuScore/InputScoreIndex.js | 5 ++ .../StuScore/InputScoreIndexInTeacher.cshtml | 6 +++ .../StuScore/InputScoreIndexInTeacher.js | 5 ++ .../StuScore/InputScoreIndexOfElective.cshtml | 6 +++ .../StuScore/InputScoreIndexOfElective.js | 5 ++ .../InputScoreIndexOfElectiveInTeacher.cshtml | 6 +++ .../InputScoreIndexOfElectiveInTeacher.js | 5 ++ .../StuScoreNotPass/InputScoreIndex.cshtml | 6 +++ .../Views/StuScoreNotPass/InputScoreIndex.js | 5 ++ .../InputScoreIndexInTeacher.cshtml | 6 +++ .../InputScoreIndexInTeacher.js | 5 ++ .../StuScoreNotPassTwo/InputScoreIndex.cshtml | 6 +++ .../StuScoreNotPassTwo/InputScoreIndex.js | 5 ++ .../InputScoreIndexInTeacher.cshtml | 6 +++ .../InputScoreIndexInTeacher.js | 5 ++ .../EADateArrange/EADateArrangeBLL.cs | 24 ++++++++++ .../EADateArrange/EADateArrangeIBLL.cs | 7 +++ .../EADateArrange/EADateArrangeService.cs | 28 ++++++++++- 22 files changed, 243 insertions(+), 7 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreController.cs index 2e67b4fe8..7a2712595 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreController.cs @@ -26,6 +26,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers private StuInfoBasicIBLL stuInfoBasicIBLL = new StuInfoBasicBLL(); private CdMajorIBLL cdMajorIBLL = new CdMajorBLL(); private UserIBLL userIBLL = new UserBLL(); + private EADateArrangeIBLL eADateArrangeIBLL = new EADateArrangeBLL(); #region 视图功能 @@ -115,6 +116,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndex() { + //获取“教学工作安排”中“成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// @@ -124,6 +136,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndexInTeacher() { + //获取“教学工作安排”中“成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// @@ -133,6 +156,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndexOfElective() { + //获取“教学工作安排”中“成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("选修成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// @@ -142,6 +176,18 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndexOfElectiveInTeacher() { + + //获取“教学工作安排”中“成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("选修成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassController.cs index fcc02a6f5..5f526cd91 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassController.cs @@ -22,6 +22,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { private StuScoreNotPassIBLL stuScoreNotPassIBLL = new StuScoreNotPassBLL(); private UserIBLL userIBLL = new UserBLL(); + private EADateArrangeIBLL eADateArrangeIBLL = new EADateArrangeBLL(); #region 视图功能 @@ -51,6 +52,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndex() { + //获取“教学工作安排”中“补考成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("补考成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// @@ -60,6 +72,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndexInTeacher() { + //获取“教学工作安排”中“补考成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("补考成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassTwoController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassTwoController.cs index 72c661d26..280e52877 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassTwoController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuScoreNotPassTwoController.cs @@ -22,6 +22,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers { private StuScoreNotPassTwoIBLL stuScoreNotPassTwoIBLL = new StuScoreNotPassTwoBLL(); private UserIBLL userIBLL = new UserBLL(); + private EADateArrangeIBLL eADateArrangeIBLL = new EADateArrangeBLL(); #region 视图功能 @@ -50,6 +51,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndex() { + //获取“教学工作安排”中“重考成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("重考成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// @@ -59,6 +71,17 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers [HttpGet] public ActionResult InputScoreIndexInTeacher() { + //获取“教学工作安排”中“重考成绩录入”的记录 + var entity = eADateArrangeIBLL.GetEADateArrangeEntityByName("重考成绩录入"); + if (entity != null && entity.CheckMark == "1" && DateTime.Now > entity.MakeDate && DateTime.Now < entity.EndDate) + { + ViewBag.CanInputFlag = true;//可以录入成绩标识 + } + else + { + ViewBag.CanInputFlag = false; + } + return View(); } /// diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.cshtml index e53f22674..0849abbec 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.cshtml @@ -38,10 +38,11 @@ float: right; padding-right: 30px; } - .scaleRow .tipBox{ - display:inline-block; - color:#ff0000; - margin-left:10px; + + .scaleRow .tipBox { + display: inline-block; + color: #ff0000; + margin-left: 10px; } #addMinutesBtn { @@ -83,7 +84,7 @@
- @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.js") + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.js index ee305c6b6..30a4ef6a1 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndex.js @@ -600,6 +600,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.cshtml index 922eab34b..c078d06d9 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.cshtml @@ -113,3 +113,9 @@ @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.js") + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.js index e53eaac59..851764860 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexInTeacher.js @@ -604,6 +604,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.cshtml index 838f6b268..50ee94099 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.cshtml @@ -115,3 +115,9 @@ @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.js") + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.js index 923a9124f..2f35b232d 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElective.js @@ -618,6 +618,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是选修成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.cshtml index f16cdbf5a..bdac8e261 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.cshtml @@ -115,3 +115,9 @@ @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.js") + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.js index 3f6cd6dde..03324f4ab 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScore/InputScoreIndexOfElectiveInTeacher.js @@ -621,6 +621,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是选修成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.cshtml index 87d030286..6afa7e061 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.cshtml @@ -108,3 +108,9 @@ @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.js") + \ No newline at end of file diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.js index 4df256987..9e288d4bb 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndex.js @@ -520,6 +520,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是补考成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.cshtml index 0fb324a54..77eb1de49 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.cshtml @@ -108,3 +108,9 @@ @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.js") + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.js index 64cef8866..8d5a344a3 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPass/InputScoreIndexInTeacher.js @@ -483,6 +483,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是补考成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.cshtml index 1992775db..38f4e6943 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.cshtml @@ -110,3 +110,9 @@ @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.js") + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.js index f8d6a9440..01fee5a19 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndex.js @@ -483,6 +483,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是重考成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.cshtml index 76bbc6e7f..77982bdda 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.cshtml @@ -108,3 +108,9 @@ @Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.js") + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.js index f8d6a9440..01fee5a19 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuScoreNotPassTwo/InputScoreIndexInTeacher.js @@ -483,6 +483,11 @@ var bootstrap = function ($, learun) { } }; judgeSelect = function () { + if (CanInputFlag != "True") { + top.learun.layerConfirm('当前时间不是重考成绩录入时间!', function (res) { }); + return false; + } + var $content = $('body').find('.lr-layout-tool-left'); var query = $content.lrGetFormData(); if (query.F_SchoolId == null || query.F_SchoolId == "") { diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeBLL.cs index a7bb901a7..0ae99fb95 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeBLL.cs @@ -66,6 +66,30 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } } + /// + /// 获取EADateArrange表实体数据 + /// 工作名称 + /// + /// + public EADateArrangeEntity GetEADateArrangeEntityByName(string name) + { + try + { + return eADateArrangeService.GetEADateArrangeEntityByName(name); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + #endregion #region 提交数据 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeIBLL.cs index 9df573967..92cc2f76a 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeIBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeIBLL.cs @@ -27,6 +27,13 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration /// /// EADateArrangeEntity GetEADateArrangeEntity(string keyValue); + + /// + /// 获取EADateArrange表实体数据 + /// 工作名称 + /// + /// + EADateArrangeEntity GetEADateArrangeEntityByName(string name); #endregion #region 提交数据 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeService.cs index 3350aba60..d971f95c6 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeService.cs @@ -107,6 +107,30 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration } } + /// + /// 获取EADateArrange表实体数据 + /// 工作名称 + /// + /// + public EADateArrangeEntity GetEADateArrangeEntityByName(string name) + { + try + { + return this.BaseRepository("CollegeMIS").FindEntity(x => x.WorkName == name); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + #endregion #region 提交数据 @@ -339,7 +363,7 @@ where s.lessonsortno='1' ) as bb where bb.EmpNo not in (select a.EmpNo from EmpReportCard a where a.AcademicYearNo=bb.AcademicYearNo and a.Semester=bb.Semester and a.LessonNo=bb.LessonNo and a.ClassNo=bb.ClassNo and a.LessonSortNo=bb.LessonSortNo and a.LessonSortNo='1' and a.F_SchoolId=bb.F_SchoolId -and a.Academicyearno='" + entity.AcademicYearNo + "' and a.Semester='" + entity.Semester + "') and bb.AcademicYearNo='" + entity.AcademicYearNo + "' and bb.Semester='" + entity.Semester + "' and bb.F_SchoolId='"+entity.F_SchoolId+"' order by bb.EmpNo"; +and a.Academicyearno='" + entity.AcademicYearNo + "' and a.Semester='" + entity.Semester + "') and bb.AcademicYearNo='" + entity.AcademicYearNo + "' and bb.Semester='" + entity.Semester + "' and bb.F_SchoolId='" + entity.F_SchoolId + "' order by bb.EmpNo"; BaseRepository("CollegeMIS").ExecuteBySql(sql3); } //选修课 @@ -374,7 +398,7 @@ where s.lessonsortno='2' ) as bb where bb.EmpNo not in (select a.EmpNo from EmpReportCard a where a.AcademicYearNo=bb.AcademicYearNo and a.Semester=bb.Semester and a.LessonNo=bb.LessonNo and a.LessonSection=bb.LessonSection and a.ClassRoomNo=bb.ClassRoomNo and a.LessonSortNo=bb.LessonSortNo and a.LessonSortNo='2' and a.F_SchoolId=bb.F_SchoolId -and a.Academicyearno='" + entity.AcademicYearNo + "' and a.Semester='" + entity.Semester + "') and bb.AcademicYearNo='" + entity.AcademicYearNo + "' and bb.Semester='" + entity.Semester + "' and bb.F_SchoolId='"+entity.F_SchoolId+"' order by bb.EmpNo"; +and a.Academicyearno='" + entity.AcademicYearNo + "' and a.Semester='" + entity.Semester + "') and bb.AcademicYearNo='" + entity.AcademicYearNo + "' and bb.Semester='" + entity.Semester + "' and bb.F_SchoolId='" + entity.F_SchoolId + "' order by bb.EmpNo"; BaseRepository("CollegeMIS").ExecuteBySql(sql3OfElective); } } From a0264ce764493b944fceba74e44cb441106be8a7 Mon Sep 17 00:00:00 2001 From: ndbs Date: Tue, 12 Jul 2022 14:36:19 +0800 Subject: [PATCH 10/14] =?UTF-8?q?=E5=AE=BF=E8=88=8D=E6=99=9A=E5=BD=92?= =?UTF-8?q?=E8=A7=84=E5=88=99--=E6=A0=A1=E6=A3=80=E5=A4=B1=E8=B4=A5=20?= =?UTF-8?q?=E6=8E=A8=E9=80=81=E4=BA=BA=E5=A4=9A=E9=80=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml | 6 +++--- .../LogisticsManagement/Views/Acc_DormitoryRule/Index.js | 4 ++-- .../Views/LR_Content/script/lr-form.js | 3 +++ 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml index f83b61a94..eeb4020c9 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml @@ -13,15 +13,15 @@
推送班主任*
-
+
推送时间点*
-
启用*
-
+
启用*
+
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js index 4b81ce7c9..022ec6ca4 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js @@ -71,7 +71,7 @@ var bootstrap = function ($, learun) { headData: [ { label: "晚归时间", name: "LateReturnTime", width: 100, align: "left" }, { - label: "推送人", name: "PushUser", width: 200, align: "left", + label: "推送人", name: "PushUser", width: 400, align: "left", formatterAsync: function (callback, value, row, op, $cell) { if (value.indexOf(',') != -1) { var content = ''; @@ -83,7 +83,7 @@ var bootstrap = function ($, learun) { key: timearr[i], keyId: 'f_userid', callback: function (_data) { - content += _data['f_realname']; + content += _data['f_realname'] + ","; } }); } diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-form.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-form.js index ad6311067..7841b1175 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-form.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-form.js @@ -460,6 +460,9 @@ if (!op.code) { return $(this); } + if (!!op.type) { + dfop.type = op.type; + } var $select = $(this).lrselect(dfop); learun.clientdata.getAllAsync('sourceData', { From a9d5514343680bba6550b18a8e13768a439cf127 Mon Sep 17 00:00:00 2001 From: ndbs Date: Tue, 12 Jul 2022 15:35:36 +0800 Subject: [PATCH 11/14] =?UTF-8?q?=E5=BD=92=E5=AE=BF=E7=BB=9F=E8=AE=A1?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E9=87=8D=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Accommodation/AccommodationBLL.cs | 62 +++++++++++++++++-- .../Accommodation/AccommodationService.cs | 40 ++++++++++++ 2 files changed, 98 insertions(+), 4 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs index 3252d1a1e..cfa96ee63 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationBLL.cs @@ -311,11 +311,66 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement } } + //public List GetDept() + //{ + // try + // { + // return accommodationService.GetSelectData("").Select(x => new Acc_DormitoryBuildEntity { Dept = x.Dept, DeptName = x.DeptName }).Distinct().ToList(); + // } + // catch (Exception ex) + // { + // if (ex is ExceptionEx) + // { + // throw; + // } + // else + // { + // throw ExceptionEx.ThrowBusinessException(ex); + // } + // } + //} + //public List GetMajor(string strWhere) + //{ + // try + // { + // return accommodationService.GetSelectData(strWhere).Select(x => new Acc_DormitoryBuildEntity { Major = x.Major, MajorName = x.MajorName }).Distinct().ToList(); + // } + // catch (Exception ex) + // { + // if (ex is ExceptionEx) + // { + // throw; + // } + // else + // { + // throw ExceptionEx.ThrowBusinessException(ex); + // } + // } + //} + //public List GetClass(string strWhere) + //{ + // try + // { + // return accommodationService.GetSelectData(strWhere).Select(x => new Acc_DormitoryBuildEntity { Class = x.Class, ClassName = x.ClassName }).Distinct().ToList(); + // } + // catch (Exception ex) + // { + // if (ex is ExceptionEx) + // { + // throw; + // } + // else + // { + // throw ExceptionEx.ThrowBusinessException(ex); + // } + // } + //} + public List GetDept() { try { - return accommodationService.GetSelectData("").Select(x => new Acc_DormitoryBuildEntity { Dept = x.Dept, DeptName = x.DeptName }).Distinct().ToList(); + return accommodationService.GetDeptOrMajorOrClass("").Select(x => new Acc_DormitoryBuildEntity { Dept = x.Dept, DeptName = x.DeptName }).Distinct().ToList(); } catch (Exception ex) { @@ -333,7 +388,7 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement { try { - return accommodationService.GetSelectData(strWhere).Select(x => new Acc_DormitoryBuildEntity { Major = x.Major, MajorName = x.MajorName }).Distinct().ToList(); + return accommodationService.GetDeptOrMajorOrClass(strWhere).Select(x => new Acc_DormitoryBuildEntity { Major = x.Major, MajorName = x.MajorName }).Distinct().ToList(); } catch (Exception ex) { @@ -351,7 +406,7 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement { try { - return accommodationService.GetSelectData(strWhere).Select(x => new Acc_DormitoryBuildEntity { Class = x.Class, ClassName = x.ClassName }).Distinct().ToList(); + return accommodationService.GetDeptOrMajorOrClass(strWhere).Select(x => new Acc_DormitoryBuildEntity { Class = x.Class, ClassName = x.ClassName }).Distinct().ToList(); } catch (Exception ex) { @@ -365,7 +420,6 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement } } } - /// /// 获取左侧树形数据 /// diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs index 6eed65103..05b5b1f0e 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Accommodation/AccommodationService.cs @@ -1887,6 +1887,46 @@ where ID='{ParentID}' } } } + + + public List GetDeptOrMajorOrClass(string strWhere) + { + try + { + string sql1 = " select distinct dept,d.DeptName from Acc_DormitoryBuild t join CdDept d on t.dept=d.deptno"; + string sql2 = " select distinct major,m.MajorName from Acc_DormitoryBuild t join CdMajor m on t.major=m.majorno"; + string sql3 = " select distinct class,c.ClassName from Acc_DormitoryBuild t join ClassInfo c on t.class=c.classno"; + string sql = @" where t.ID in ( + select parentid from[dbo].[Acc_DormitoryBuild] where BuildType = '5' and(studentid is not null and len(studentid) > 0) + )"; + if (string.IsNullOrEmpty(strWhere)) + { + sql = sql1 + sql; + } + else if (strWhere.Contains("deptno")) + { + sql = sql2 + sql + " and " + strWhere; + } + else if (strWhere.Contains("majorno")) + { + sql = sql3 + sql + " and " + strWhere; + } + return this.BaseRepository("CollegeMIS").FindList(sql).ToList(); + + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + #endregion 提交数据 } } \ No newline at end of file From 3f2f2947f5ece7c5cfcc74a5abd4c942d2a536f9 Mon Sep 17 00:00:00 2001 From: ndbs Date: Tue, 12 Jul 2022 16:07:47 +0800 Subject: [PATCH 12/14] =?UTF-8?q?=E5=AE=BF=E8=88=8D=E6=99=9A=E5=BD=92?= =?UTF-8?q?=E8=A7=84=E5=88=99--=E6=B7=BB=E5=8A=A0=E8=BE=85=E5=AF=BC?= =?UTF-8?q?=E5=91=98=E5=92=8C=E4=BF=9D=E5=8D=AB=E5=A4=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Views/Acc_DormitoryRule/Form.cshtml | 18 ++++++++++---- .../Views/Acc_DormitoryRule/Form.js | 9 +++++++ .../Views/Acc_DormitoryRule/Index.js | 24 +++++++++++++++++++ .../Acc_DormitoryRuleEntity.cs | 13 +++++++++- .../Acc_DormitoryRuleService.cs | 5 ++++ 5 files changed, 63 insertions(+), 6 deletions(-) diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml index eeb4020c9..5e7a175f9 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.cshtml @@ -11,17 +11,25 @@
推送人*
-
+
推送班主任*
-
-
推送时间点*
- +
+
推送辅导员*
+
-
+
+
推送保卫处*
+
+
+
启用*
+
+
推送时间点*
+ +
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.js index 2dab9f792..4dcf7d09e 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Form.js @@ -27,6 +27,15 @@ var bootstrap = function ($, learun) { type: 'radio', code: 'YesOrNoInt', }); + $('#CoachTeach').lrRadioCheckbox({ + type: 'radio', + code: 'YesOrNoInt', + }); + $('#Defend').lrRadioCheckbox({ + type: 'radio', + code: 'YesOrNoInt', + }); + }, initData: function () { if (!!keyValue) { diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js index 022ec6ca4..0a1045d87 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LogisticsManagement/Views/Acc_DormitoryRule/Index.js @@ -113,6 +113,30 @@ var bootstrap = function ($, learun) { }); } }, + { + label: "推送辅导员", name: "CoachTeach", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('dataItem', { + key: value, + code: 'YesOrNoInt', + callback: function (_data) { + callback(_data.text); + } + }); + } + }, + { + label: "推送保卫处", name: "Defend", width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('dataItem', { + key: value, + code: 'YesOrNoInt', + callback: function (_data) { + callback(_data.text); + } + }); + } + }, { label: "推送时间点", name: "PushHour", width: 100, align: "left" }, { label: "启用", name: "IsEnable", width: 100, align: "left", diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs index 351f0e912..7af6a9117 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs @@ -11,7 +11,7 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement /// 日 期:2022-03-14 12:05 /// 描 述:宿舍晚归规则 ///
- public class Acc_DormitoryRuleEntity + public class Acc_DormitoryRuleEntity { #region 实体成员 /// @@ -64,6 +64,17 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement /// [Column("UPDATEUSERID")] public string UpdateUserId { get; set; } + /// + /// + /// + [Column("COACHTEACH")] + public int? CoachTeach { get; set; } + /// + /// + /// + [Column("DEFEND")] + public int? Defend { get; set; } + #endregion #region 扩展操作 diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs index 751c2f837..d285ddf19 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs @@ -138,14 +138,19 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement { try { + var loInfo = LoginUserInfo.Get(); if (!string.IsNullOrEmpty(keyValue)) { + entity.UpdateTime = DateTime.Now; + entity.UpdateUserId = loInfo.account; entity.Modify(keyValue); this.BaseRepository("CollegeMIS").Update(entity); } else { entity.Create(); + entity.CreateTime = DateTime.Now; + entity.CreateUserId = loInfo.account; this.BaseRepository("CollegeMIS").Insert(entity); } } From 3137569cecf0bc064924020bb64cd3b096a1cc3c Mon Sep 17 00:00:00 2001 From: dyy <807692433@qq.com> Date: Tue, 12 Jul 2022 17:34:30 +0800 Subject: [PATCH 13/14] =?UTF-8?q?=E3=80=90=E5=A2=9E=E5=8A=A0=E3=80=91?= =?UTF-8?q?=E6=8B=9B=E7=94=9F=E4=BF=A1=E6=81=AF=E7=AE=A1=E7=90=86=EF=BC=9A?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E2=80=9C=E7=94=9F=E6=BA=90=E5=9C=B0=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E7=BB=9F=E8=AE=A1=E2=80=9D=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/StuInfoFreshController.cs | 44 +++++++++ .../Views/StuInfoFresh/StatisticClassIndex.js | 4 +- .../Views/StuInfoFresh/StatisticIndex.js | 4 +- .../StuInfoFresh/StatisticsProvince.cshtml | 36 ++++++++ .../Views/StuInfoFresh/StatisticsProvince.js | 89 +++++++++++++++++++ .../Learun.Application.Web.csproj | 2 + 6 files changed, 175 insertions(+), 4 deletions(-) create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.cshtml create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.js diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs index ffe6bdecd..13614c3f9 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/StuInfoFreshController.cs @@ -282,6 +282,15 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers ViewBag.Grade = academic.AcademicYearShort.Substring(0, 2); return View(); } + /// + /// 生源地信息统计 + /// + /// + [HttpGet] + public ActionResult StatisticsProvince() + { + return View(); + } #endregion #region 获取数据 @@ -1198,6 +1207,14 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers /// 已领取床上用品人数 /// public int GetBeddingNum { get; set; } + /// + /// 生源地 + /// + public string Province { get; set; } + /// + /// 疆内 + /// + public string City { get; set; } } /// /// 获取列表数据 @@ -1260,6 +1277,33 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers } + /// + /// 获取列表数据 + /// + /// + [HttpGet] + [AjaxOnly] + public ActionResult GetStatisticProvince(string queryJson) + { + var data = stuInfoFreshIBLL.GetList2(queryJson); + var list = data.Where(x => !string.IsNullOrEmpty(x.Province) && !string.IsNullOrEmpty(x.City)).GroupBy(x => new { x.Province, x.City }).Select(x => new StatisticModel + { + Province = x.Key.Province, + City = x.Key.City, + TotalNum = x.Count(), + InfoNum = x.Count(y => y.IsStudentEdit == true), + RegisterNum = x.Count(y => y.RegisterStatus == "1"), + PayFeeNum = x.Count(y => y.PayFeeStatus == "1" || y.OnsitePayFeeStatus == "1"), + GetKeyNum = x.Count(y => y.GetKeyStatus == "1"), + GetCardNum = x.Count(y => y.GetCardStatus == "1"), + CollectFileNum = x.Count(y => y.CollectFileStatus == "1"), + LoanNum = x.Count(y => y.StudentLoanStatus == "1"), + GetMiliClothesNum = x.Count(y => y.GetMiliClothesStatus == "1"), + GetBeddingNum = x.Count(y => y.GetBeddingStatus == "1") + }).OrderBy(x => x.Province).ThenBy(x => x.City); + return Success(list); + } + #endregion #region 上传图片 diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js index 739f40fff..aa1287f6e 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticClassIndex.js @@ -64,8 +64,8 @@ var bootstrap = function ($, learun) { { label: '已领取钥匙人数', name: 'GetKeyNum', width: 100, align: "left", statistics: true }, { label: '已领取校园卡人数', name: 'GetCardNum', width: 120, align: "left", statistics: true }, { label: '已收取档案人数', name: 'CollectFileNum', width: 100, align: "left", statistics: true }, - { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left" }, - { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left" }, + { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left", statistics: true }, + { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left", statistics: true }, ], mainId: 'MajorNo', isPage: false, diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js index e6e2a2631..05db9d05e 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticIndex.js @@ -57,8 +57,8 @@ var bootstrap = function ($, learun) { { label: '已领取钥匙人数', name: 'GetKeyNum', width: 100, align: "left", statistics: true }, { label: '已领取校园卡人数', name: 'GetCardNum', width: 120, align: "left", statistics: true }, { label: '已收取档案人数', name: 'CollectFileNum', width: 100, align: "left", statistics: true }, - { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left" }, - { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left" }, + { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left", statistics: true }, + { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left", statistics: true }, ], mainId: 'MajorNo', isPage: false, diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.cshtml new file mode 100644 index 000000000..bc36bec4c --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.cshtml @@ -0,0 +1,36 @@ +@{ + ViewBag.Title = "新生信息统计"; + Layout = "~/Views/Shared/_Index.cshtml"; +} + +
+
+
+
+
+ + @*
+
+
+
+  查询 +
*@ +
+
+
+ +
+
+ +
+
+
+
+
+
+
+@Html.AppendJsFile("/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.js new file mode 100644 index 000000000..d79f2be73 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuInfoFresh/StatisticsProvince.js @@ -0,0 +1,89 @@ +/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn) + * Copyright (c) 2013-2018 北京泉江科技有限公司 + * 创建人:超级管理员 + * 日 期:2019-08-08 17:21 + * 描 述:新生信息统计 + */ +var selectedRow; +var refreshGirdData; +var bootstrap = function ($, learun) { + "use strict"; + var page = { + init: function () { + page.initGird(); + page.bind(); + }, + bind: function () { + // 查询 + $('#btn_Search').on('click', function () { + var Grade = $('#Grade').lrselectGet(); + if (Grade == null || Grade == "") { + learun.alert.warning("请选择年级!"); + return; + } + page.search({ Grade: Grade }); + }); + // 刷新 + $('#lr_refresh').on('click', function () { + location.reload(); + }); + + + }, + initGird: function () { + $('#gridtable').lrAuthorizeJfGrid({ + url: top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/GetStatisticProvince', + headData: [ + { + label: '生源地', name: 'Province', width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_PROVINCE', + key: value, + keyId: 'pcode', + callback: function (_data) { + callback(_data['pname']); + } + }); + } + }, + { + label: '疆内', name: 'City', width: 100, align: "left", + formatterAsync: function (callback, value, row, op, $cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_CITY', + key: value, + keyId: 'ccode', + callback: function (_data) { + callback(_data['cname']); + } + }); + } + }, + { label: '总人数', name: 'TotalNum', width: 100, align: "left", statistics: true }, + { label: '已完善个人信息人数', name: 'InfoNum', width: 130, align: "left", statistics: true }, + { label: '已报到人数', name: 'RegisterNum', width: 100, align: "left", statistics: true }, + { label: '已缴费人数', name: 'PayFeeNum', width: 100, align: "left", statistics: true }, + { label: '贷款人数', name: 'LoanNum', width: 100, align: "left", statistics: true }, + { label: '已领取钥匙人数', name: 'GetKeyNum', width: 100, align: "left", statistics: true }, + { label: '已领取校园卡人数', name: 'GetCardNum', width: 120, align: "left", statistics: true }, + { label: '已收取档案人数', name: 'CollectFileNum', width: 100, align: "left", statistics: true }, + { label: '已领取军训服装人数', name: 'GetMiliClothesNum', width: 120, align: "left", statistics: true }, + { label: '已领取床上用品人数', name: 'GetBeddingNum', width: 120, align: "left", statistics: true }, + ], + mainId: 'City', + isPage: false, + sidx: 'Province,City', + }); + page.search(); + }, + search: function (param) { + param = param || {}; + $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); + } + }; + refreshGirdData = function () { + page.search(); + }; + page.init(); +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj index 1e451c5a7..afe1fd893 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj @@ -1101,6 +1101,7 @@ + @@ -7918,6 +7919,7 @@ + From 494295bc4c49b38389f17b90fd878b641bf9881f Mon Sep 17 00:00:00 2001 From: ndbs Date: Wed, 13 Jul 2022 12:26:17 +0800 Subject: [PATCH 14/14] =?UTF-8?q?=E6=99=9A=E5=BD=92=E8=A7=84=E5=88=99?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=20=E4=BF=9D=E5=8D=AB=E5=A4=84=E4=BF=A1?= =?UTF-8?q?=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs | 5 +++++ .../Acc_DormitoryRule/Acc_DormitoryRuleService.cs | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs index 7af6a9117..d7cd70906 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleEntity.cs @@ -74,6 +74,11 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement ///
[Column("DEFEND")] public int? Defend { get; set; } + /// + /// + /// + [Column("DEFENDID")] + public string DefendId { get; set; } #endregion diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs index d285ddf19..e5148edfb 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LogisticsManagement/Acc_DormitoryRule/Acc_DormitoryRuleService.cs @@ -1,4 +1,5 @@ using Dapper; +using Learun.Application.Organization; using Learun.DataBase.Repository; using Learun.Util; using System; @@ -151,6 +152,11 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement entity.Create(); entity.CreateTime = DateTime.Now; entity.CreateUserId = loInfo.account; + var NewID = this.BaseRepository().FindEntity(x => x.F_FullName == "保卫处").F_DepartmentId; + if (NewID != null && entity.Defend == 1) + { + entity.DefendId = NewID; + } this.BaseRepository("CollegeMIS").Insert(entity); } }