From 0406942da726c8c170fe393ad81a62e2f13b2c7a Mon Sep 17 00:00:00 2001
From: dyy <807692433@qq.com>
Date: Thu, 9 Jun 2022 17:39:32 +0800
Subject: [PATCH 1/8] =?UTF-8?q?=E3=80=90=E5=9C=A8=E5=86=8C=E8=B5=84?=
=?UTF-8?q?=E4=BA=A7=E6=98=8E=E7=BB=86=E3=80=91=E6=96=B0=E5=A2=9E=E6=88=96?=
=?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=98=BE=E7=A4=BA=E4=B8=BA=E3=80=90=E9=87=91?=
=?UTF-8?q?=E9=9A=85=E7=BC=96=E5=8F=B7=E3=80=91=EF=BC=8C=E6=94=B9=E4=B8=BA?=
=?UTF-8?q?=E3=80=90=E8=B5=84=E4=BA=A7=E7=BC=96=E5=8F=B7=E3=80=91?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml | 2 +-
.../Views/Ass_AssetsInfoItem/FormView.cshtml | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml
index 2e89dc1cb..2698030e8 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml
@@ -38,7 +38,7 @@
*@
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/FormView.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/FormView.cshtml
index 23c6f1cca..809cb2eaa 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/FormView.cshtml
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/FormView.cshtml
@@ -22,7 +22,7 @@
*@
From 39b129b4d6e9e058711234fe0adee4ceeedc3ed5 Mon Sep 17 00:00:00 2001
From: zhangli <1109134334@qq.com>
Date: Fri, 10 Jun 2022 09:39:26 +0800
Subject: [PATCH 2/8] =?UTF-8?q?=E8=87=AA=E5=8A=A8=E7=94=9F=E6=88=90?=
=?UTF-8?q?=E8=80=83=E8=AF=95=E8=AF=BE=E7=A8=8B=E6=8E=92=E8=80=83=E6=97=B6?=
=?UTF-8?q?=E9=97=B4=EF=BC=88=E6=9C=AA=E5=AE=8C=E6=88=90=EF=BC=89?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Controllers/Exam_ExamPlanController.cs | 28 +++++++++--
.../Views/Exam_ExamPlan/Index.js | 15 ++++++
.../Exam_ExamPlanLessonBLL.cs | 20 ++++++++
.../Exam_ExamPlanLessonEntity.cs | 5 ++
.../Exam_ExamPlanLessonIBLL.cs | 2 +
.../Exam_ExamPlanLessonService.cs | 49 +++++++++++++++++++
6 files changed, 114 insertions(+), 5 deletions(-)
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs
index 6e7b8efa4..02954f117 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs
@@ -269,11 +269,11 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
return Success("操作成功!");
}
///
- /// 一键安排班级
- ///
- ///
- ///
- [HttpPost]
+ /// 一键安排班级
+ ///
+ ///
+ ///
+ [HttpPost]
[AjaxOnly]
public ActionResult PlanClassByEPId(string keyValue)
{
@@ -286,6 +286,24 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
exam_ExamPlanClassIBLL.PlanClassByEPId(keyValue);
return Success("操作成功!");
}
+ ///
+ /// 自动生成考试课程排考时间
+ ///
+ ///
+ ///
+ [HttpPost]
+ [AjaxOnly]
+ public ActionResult PlanLessonTimeByEPId(string keyValue)
+ {
+ var count = exam_ExamPlanLessonIBLL.GetListByEPId(keyValue).Count();
+ if (count <= 0)
+ {
+ return Fail("请先安排课程!");
+ }
+ exam_ExamPlanLessonIBLL.PlanLessonTimeByEPId(keyValue);
+ return Success("操作成功!");
+ }
+
#endregion
}
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.js
index 8f43e80d8..913b3239c 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.js
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.js
@@ -190,6 +190,21 @@ var bootstrap = function ($, learun) {
});
}
});
+
+ //自动生成排考时间
+ $('#lr_examlessontime').on('click',
+ function () {
+ var keyValue = $('#gridtable').jfGridValue('EPId');
+ if (learun.checkrow(keyValue)) {
+ learun.layerConfirm('是否确认生成排考时间!', function (res) {
+ if (res) {
+ learun.postForm(top.$.rootUrl + '/EducationalAdministration/Exam_ExamPlan/PlanLessonTimeByEPId', { keyValue: keyValue }, function () {
+ refreshGirdData();
+ });
+ }
+ });
+ }
+ });
},
// 初始化列表
initGird: function () {
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonBLL.cs
index 76c291449..3dd2fe689 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonBLL.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonBLL.cs
@@ -263,6 +263,26 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
}
}
}
+
+ public (bool flag, string msg) PlanLessonTimeByEPId(string EPId)
+ {
+ try
+ {
+ return exam_ExamPlanLessonService.PlanLessonTimeByEPId(EPId);
+ }
+ 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/Exam_ExamPlanLesson/Exam_ExamPlanLessonEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonEntity.cs
index 6cfa48f54..01ff1f76d 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonEntity.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonEntity.cs
@@ -108,6 +108,11 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
public string AcademicYearNo { get; set; }
[NotMapped]
public string Semester { get; set; }
+ ///
+ /// 考试时长
+ ///
+ [NotMapped]
+ public int? ExamLength { get; set; }
#endregion
}
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonIBLL.cs
index 9557074df..051781014 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonIBLL.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonIBLL.cs
@@ -52,6 +52,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
///
实体
void SaveEntity(string keyValue, Exam_ExamPlanLessonEntity entity);
+ (bool flag, string msg) PlanLessonTimeByEPId(string keyValue);
+
(bool flag, string lessonname) IsExamTimeClash(Exam_ExamPlanLessonEntity entity);
#endregion
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonService.cs
index 5c3f6a862..33ddb0c9f 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonService.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonService.cs
@@ -411,6 +411,55 @@ and AcademicYearNo='{exam_ExamPlan.AcademicYearNo}' and Semester='{exam_ExamPlan
}
}
}
+
+ ///
+ /// 自动生成考试课程排考时间
+ ///
+ ///
+ ///
+ public (bool flag, string msg) PlanLessonTimeByEPId(string EPId)
+ {
+ try
+ {
+ /*
+ * 1.查询考试记录是否已安排时间
+ * 2.查询考试课程的考试时长是否大于0
+ * 3.同一时间段内只能一个专业安排一门课程
+ */
+
+ //安排时间数据
+ var EPTimeList = this.BaseRepository("CollegeMIS")
+ .FindList
(x => x.EPId == EPId);
+ if (EPTimeList.Count() <= 0)
+ {
+ return (false, "请先安排考试记录时间!");
+ }
+ //考试课程数据
+ var EPLessonList = this.BaseRepository("CollegeMIS")
+ .FindList($@"select elesson.ExamTime as ExamLength,t.* from Exam_ExamPlanLesson t
+join Exam_ExamLesson elesson on t.LessonNo=elesson.LessonNo
+ where t.EPId='{EPId}'");
+ if (EPLessonList.ToList().Exists(x => x.ExamLength == null || x.ExamLength == 0))
+ {
+ return (false, "请先设置考试课程时长!");
+ }
+
+
+ return (true, "");
+ }
+ catch (Exception ex)
+ {
+ if (ex is ExceptionEx)
+ {
+ throw;
+ }
+ else
+ {
+ throw ExceptionEx.ThrowServiceException(ex);
+ }
+ }
+ }
+
#endregion
}
From 9ca7c13f6bc7c3866576051f3385c0373884105f Mon Sep 17 00:00:00 2001
From: zhangli <1109134334@qq.com>
Date: Fri, 10 Jun 2022 10:00:51 +0800
Subject: [PATCH 3/8] =?UTF-8?q?=E8=80=83=E8=AF=95=E8=AE=B0=E5=BD=95?=
=?UTF-8?q?=E5=AE=89=E6=8E=92=E6=97=B6=E9=97=B4=E6=96=B0=E5=A2=9E=E8=80=83?=
=?UTF-8?q?=E8=AF=95=E6=97=B6=E9=95=BF?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Controllers/Exam_ExamPlanController.cs | 15 ++++++++++++---
.../Exam_ExamPlanTime/Exam_ExamPlanTimeEntity.cs | 5 +++++
2 files changed, 17 insertions(+), 3 deletions(-)
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs
index 02954f117..649203288 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs
@@ -175,7 +175,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
{
if (list.Count <= 0)
{
- return Fail("请安排时间");
+ return Fail("请安排时间!");
}
foreach (var entity in list)
@@ -183,12 +183,21 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
DateTime time;
if (!DateTime.TryParse(entity.ExamTimeStart, out time))
{
- return Fail("结束时间格式不正确!");
+ return Fail("开始时间格式不正确!");
}
if (!DateTime.TryParse(entity.ExamTimeEnd, out time))
{
return Fail("结束时间格式不正确!");
}
+
+ var startTime = Convert.ToDateTime(entity.ExamDate.Value.ToString("yyyy-MM-dd") + " " + entity.ExamTimeStart);
+ var endTime = Convert.ToDateTime(entity.ExamDate.Value.ToString("yyyy-MM-dd") + " " + entity.ExamTimeEnd);
+ if (endTime <= startTime)
+ {
+ return Fail("结束时间必须大于开始时间!");
+ }
+ //考试时长
+ entity.ExamTimeLength = (endTime - startTime).TotalMinutes;
}
exam_ExamPlanIBLL.SavePlanTime(EPId, list);
return Success("保存成功!");
@@ -303,7 +312,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
exam_ExamPlanLessonIBLL.PlanLessonTimeByEPId(keyValue);
return Success("操作成功!");
}
-
+
#endregion
}
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanTime/Exam_ExamPlanTimeEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanTime/Exam_ExamPlanTimeEntity.cs
index 9e0b2009a..157874cb1 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanTime/Exam_ExamPlanTimeEntity.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanTime/Exam_ExamPlanTimeEntity.cs
@@ -40,6 +40,11 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
[Column("EXAMTIMEEND")]
public string ExamTimeEnd { get; set; }
///
+ /// 考试时长
+ ///
+ [Column("EXAMTIMELENGTH")]
+ public double? ExamTimeLength { get; set; }
+ ///
/// 排考名称
///
[Column("EXAMTYPE")]
From 7525f5b4c584bc2107fa278fc78ca72e80e1c938 Mon Sep 17 00:00:00 2001
From: liangkun
Date: Fri, 10 Jun 2022 10:24:34 +0800
Subject: [PATCH 4/8] =?UTF-8?q?=E8=AF=84=E6=95=99api=E5=9C=B0=E5=9D=80?=
=?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=AD=A3=E7=A1=AE?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Learun.Application.WebApi/Modules/EvalApi.cs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/EvalApi.cs b/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/EvalApi.cs
index 5fa59f7ae..8c8f984d6 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/EvalApi.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/EvalApi.cs
@@ -17,7 +17,7 @@ namespace Learun.Application.WebApi.Modules
public class EvalApi : BaseApi
{
public EvalApi()
- : base("/learun/adms/eval")
+ : base("/learun/eval")
{
Get["/paper"] = GetPaper;// 获取组织机构数据映射表
Get["/studentlist"] = GetStudentList;
From 658b1751740594d03b4d2902c02d27aaaaf41902 Mon Sep 17 00:00:00 2001
From: liangkun
Date: Fri, 10 Jun 2022 14:26:44 +0800
Subject: [PATCH 5/8] =?UTF-8?q?=E5=BC=80=E6=94=BE=E6=95=99=E5=B8=88?=
=?UTF-8?q?=E9=80=89=E4=BF=AE=E6=88=90=E7=BB=A9=E5=BD=95=E5=85=A5=E6=8C=89?=
=?UTF-8?q?=E9=92=AE?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../StuScore/InputScoreIndexOfElectiveInTeacher.cshtml | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
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 72044bbf9..f16cdbf5a 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
@@ -86,17 +86,17 @@
- @*
- @*
+
比例设置:
平时成绩占比 0 %,
期中成绩占比 0 %,
@@ -108,7 +108,7 @@
分钟(
秒)
续时
-
*@
+
From d3c60e8025ba75428a6e152893f4643d5ad340d0 Mon Sep 17 00:00:00 2001
From: dyy <807692433@qq.com>
Date: Fri, 10 Jun 2022 15:10:13 +0800
Subject: [PATCH 6/8] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=91?=
=?UTF-8?q?=E7=99=BB=E8=AE=B0=E5=9C=A8=E5=86=8C=E8=B5=84=E4=BA=A7=EF=BC=9A?=
=?UTF-8?q?=E8=B5=84=E4=BA=A7=E6=98=8E=E7=BB=86=E7=BC=96=E5=8F=B7=EF=BC=8C?=
=?UTF-8?q?=E6=9C=80=E5=90=8E=E7=9A=84=E5=BA=8F=E5=8F=B7=E4=B8=BA5?=
=?UTF-8?q?=E4=BD=8D=EF=BC=8C=E4=B8=8D=E8=B6=B3=E7=9A=840=E4=BB=A3?=
=?UTF-8?q?=E6=9B=BF=EF=BC=8C?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Views/Ass_AssetsInfoItem/Form.cshtml | 4 ++--
.../Ass_AssetsInfo/Ass_AssetsInfoService.cs | 14 +++++++-------
.../Ass_AssetsInfoApplyService.cs | 12 ++++++------
3 files changed, 15 insertions(+), 15 deletions(-)
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml
index 2698030e8..83a11a01a 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/AssetManagementSystem/Views/Ass_AssetsInfoItem/Form.cshtml
@@ -42,8 +42,8 @@