Przeglądaj źródła

Merge branch '怀来职教中心中职' of http://123.57.209.16:3000/bjquanjiang/DigitalScholl into 怀来职教中心中职

怀来职教中心中职
ndbs 1 rok temu
rodzic
commit
9a0e0e6883
5 zmienionych plików z 64 dodań i 3 usunięć
  1. +14
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/TeacherPlanCheckController.cs
  2. +3
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeacherPlanCheck/Index.cshtml
  3. +5
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeacherPlanCheck/Index.js
  4. +37
    -1
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeService.cs
  5. +5
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/TeacherPlanCheck/TeacherPlanCheckService.cs

+ 14
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/TeacherPlanCheckController.cs Wyświetl plik

@@ -1,5 +1,6 @@
using Learun.Application.TwoDevelopment.EducationalAdministration;
using Learun.Util;
using System;
using System.Data;
using System.Web.Mvc;

@@ -15,6 +16,7 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
public class TeacherPlanCheckController : MvcControllerBase
{
private TeacherPlanCheckIBLL teacherPlanCheckIBLL = new TeacherPlanCheckBLL();
private EADateArrangeIBLL eADateArrangeIBLL = new EADateArrangeBLL();

#region 视图功能

@@ -25,7 +27,18 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers
[HttpGet]
public ActionResult Index()
{
return View();
//获取“教学工作安排”中“教学教案检查打分”的记录
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();
}
/// <summary>
/// 表单页


+ 3
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeacherPlanCheck/Index.cshtml Wyświetl plik

@@ -36,3 +36,6 @@
</div>
</div>
@Html.AppendJsFile("/Areas/EducationalAdministration/Views/TeacherPlanCheck/Index.js")
<script>
var CanInputFlag = "@ViewBag.CanInputFlag";
</script>

+ 5
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/TeacherPlanCheck/Index.js Wyświetl plik

@@ -59,8 +59,12 @@ var bootstrap = function ($, learun) {
location.reload();
});

// 编辑
// 打分
$('#lr_edit').on('click', function () {
if (CanInputFlag != "True") {
top.learun.layerConfirm('当前时间不是打分时间!', function (res) { });
return false;
}
var keyValue = $('#gridtable').jfGridValue('EmpId');
selectedRow = $('#gridtable').jfGridGet('rowdata');
if (learun.checkrow(keyValue)) {


+ 37
- 1
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/EADateArrange/EADateArrangeService.cs Wyświetl plik

@@ -321,6 +321,43 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
}
}
}

/// <summary>
/// 增加工作安排
/// </summary>
/// <param name="workName">工作名称</param>
public void AddWork(string workName)
{
try
{
var yearAndSemester = Common.GetSemesterAndYear();
if (!string.IsNullOrEmpty(workName))
{
//判断是否存在
var model = this.BaseRepository("CollegeMIS").FindEntity<EADateArrangeEntity>(x => x.WorkName == workName);
if (model == null)
{
//不存在的话写入一条
var strSql = new StringBuilder();
strSql.Append($@"insert into EADateArrange(dm, WorkName, MakeDate, AcademicYearNo, Semester, EndDate, CheckMark, WhoArrange)
values((select Max(CONVERT(int, dm)) + 1 from EADateArrange),'{workName}' , GETDATE(), '{yearAndSemester.AcademicYearShort}', '{yearAndSemester.Semester}', DATEADD(month, 1, GETDATE()), 0, '超级管理员') ");
this.BaseRepository("CollegeMIS").ExecuteBySql(strSql.ToString());
}
}
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

/// <summary>
@@ -532,6 +569,5 @@ and a.Academicyearno='" + entity.AcademicYearNo + "' and a.Semester='" + entity.
}
}


}
}

+ 5
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/TeacherPlanCheck/TeacherPlanCheckService.cs Wyświetl plik

@@ -17,6 +17,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
/// </summary>
public class TeacherPlanCheckService : RepositoryFactory
{
private EADateArrangeService eADateArrangeService = new EADateArrangeService();

#region 构造函数和属性

private string fieldSql;
@@ -105,6 +107,9 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
try
{
//“教学工作安排”表增加“教学教案检查打分”项
eADateArrangeService.AddWork("教学教案检查打分");

//学年、学期
var yearAndSemester = Common.GetSemesterAndYear();
var year = yearAndSemester.AcademicYearShort;


Ładowanie…
Anuluj
Zapisz