Browse Source

Merge branch '塔里木分支' of http://123.57.209.16:3000/bjquanjiang/DigitalScholl into 塔里木分支

新疆影视学院高职
ndbs 2 years ago
parent
commit
b76a33bc55
6 changed files with 90 additions and 2 deletions
  1. +18
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs
  2. +2
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.cshtml
  3. +15
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.js
  4. +19
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonBLL.cs
  5. +1
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonIBLL.cs
  6. +35
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonService.cs

+ 18
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/Exam_ExamPlanController.cs View File

@@ -357,6 +357,24 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers

return Success("操作成功!");
}

/// <summary>
/// 审核所有考试课程
/// </summary>
/// <param name="keyValue"></param>
/// <returns></returns>
[HttpPost]
[AjaxOnly]
public ActionResult CheckAllPlanLesson(string keyValue)
{
var res = exam_ExamPlanLessonIBLL.CheckAllPlanLesson(keyValue);
if (!res.flag)
{
return Fail(res.str);
}

return Success("操作成功!");
}
#endregion

}


+ 2
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.cshtml View File

@@ -2,7 +2,7 @@
ViewBag.Title = "考试记录表";
Layout = "~/Views/Shared/_Index.cshtml";
}
<div class="lr-layout " >
<div class="lr-layout ">
<div class="lr-layout-center">
<div class="lr-layout-wrap lr-layout-wrap-notitle ">
<div class="lr-layout-tool">
@@ -72,6 +72,7 @@
<li id="lr_examclass"><a><i></i>&nbsp;<span class="lrlt">一键安排班级</span></a></li>
<li id="lr_examroom"><a><i></i>&nbsp;<span class="lrlt">一键安排考场</span></a></li>
<li id="lr_examteacher"><a><i></i>&nbsp;<span class="lrlt">一键安排监考老师</span></a></li>
<li id="lr_checkAll"><a><i></i>&nbsp;<span class="lrlt">一键审核所有考试课程</span></a></li>
</ul>
</div>



+ 15
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/Exam_ExamPlan/Index.js View File

@@ -237,7 +237,21 @@ var bootstrap = function ($, learun) {
});
}
});

//一键审核所有考试课程
$('#lr_checkAll').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/CheckAllPlanLesson', { keyValue: keyValue }, function () {
refreshGirdData();
});
}
});
}
});

//老师时间管理
$('#lr_teacherTimeManage').on('click', function () {


+ 19
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonBLL.cs View File

@@ -340,6 +340,25 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
}
}

public (bool flag, string str) CheckAllPlanLesson(string EPId)
{
try
{
return exam_ExamPlanLessonService.CheckAllPlanLesson(EPId);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}
#endregion

}


+ 1
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonIBLL.cs View File

@@ -57,6 +57,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
(bool flag, string msg) PlanLessonTimeByEPId(string keyValue);
(bool flag, string str) IsAllowSave(Exam_ExamPlanLessonEntity entity);
(bool flag, string lessonname) IsExamTimeClash(Exam_ExamPlanLessonEntity entity);
(bool flag, string str) CheckAllPlanLesson(string keyValue);
#endregion

}


+ 35
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/Exam_ExamPlanLesson/Exam_ExamPlanLessonService.cs View File

@@ -561,6 +561,7 @@ left join CdLessonType ltype on info.LessonTypeId=ltype.LTId
}
}
}

/// <summary>
/// 自动生成考试课程排考时间
/// </summary>
@@ -683,6 +684,40 @@ left join CdLessonType ltype on info.LessonTypeId=ltype.LTId
}
}

/// <summary>
/// 一键审核考试课程
/// </summary>
/// <param name="EPId"></param>
/// <returns></returns>
public (bool flag, string str) CheckAllPlanLesson(string EPId)
{
var db = this.BaseRepository("CollegeMIS");
try
{
db.BeginTrans();
var list = db.FindList<Exam_ExamPlanLessonEntity>($"select * FROM Exam_ExamPlanLesson where epid='{EPId}' and examdate is not null and ExamTime is not null and SeatCount>0 and realstucount>0 and SeatCount>=realstucount");
var EPLIds = string.Join("','", list.Select(x => x.EPLId).ToList());
string sql = $"update Exam_ExamPlanLesson set ELCheckMark='1' where EPLId in ('{EPLIds}')";
db.ExecuteBySql(sql);
//更新排考记录表是否生成字段
string updsql = $"update Exam_ExamPlan set EPGenarate=0 where EPId='{EPId}'";
db.ExecuteBySql(updsql);
db.Commit();
return (true, "");
}
catch (Exception ex)
{
db.Rollback();
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}
#endregion

}


Loading…
Cancel
Save