@@ -39,7 +39,6 @@ namespace Learun.Application.Organization | |||
if (list == null) | |||
{ | |||
list = (List<DepartmentEntity>)departmentService.GetList(companyId); | |||
cache.Write<List<DepartmentEntity>>(cacheKey + companyId, list, CacheId.department); | |||
} | |||
return list; | |||
} | |||
@@ -82,7 +82,7 @@ var bootstrap = function ($, learun) { | |||
text: 'text' | |||
}); | |||
//课程 | |||
$('#LessonNo').lrDataSourceSelect({ code: 'LessonInfo', value: 'lessonid', text: 'lessonname' }); | |||
$('#LessonNo').lrDataSourceSelect({ code: 'LessonInfo', value: 'lessonno', text: 'lessonname', placeholder:'请选择课程' }); | |||
}, | |||
initGird: function () { | |||
$('#gridtable').lrAuthorizeJfGrid({ | |||
@@ -78,8 +78,8 @@ var bootstrap = function ($, learun) { | |||
headData: [ | |||
{ label: '学年', name: 'AcademicYearNo', width: 80, align: "left" }, | |||
{ label: '学期', name: 'Semester', width: 80, align: "left" }, | |||
{ label: '考试开始时间', name: 'StartDate', width: 100, align: "left" }, | |||
{ label: '考试结束时间', name: 'EndDate', width: 100, align: "left" }, | |||
{ label: '考试日期', name: 'ExamDate', width: 100, align: "left" }, | |||
{ label: '考试时间', name: 'ExamTime', width: 100, align: "left" }, | |||
{ label: '课程编号', name: 'LessonNo', width: 100, align: "left" }, | |||
{ label: '课程名称', name: 'LessonName', width: 200, align: "left" }, | |||
{ label: '监考教师编号', name: 'EmpNo', width: 100, align: "left" }, | |||
@@ -130,6 +130,8 @@ | |||
<add key="ExamScoreAPI" value="http://123.57.209.16:12203/jeeplus/app/stuScore" /> | |||
<!--排考接口2021新--> | |||
<add key="ArrangeExamAPINew" value="http://pk.bjquanjiang.com/app/paikao/obligatory" /> | |||
<!--排考明细接口2021新--> | |||
<add key="ArrangeExamItemAPINew" value="http://pk.bjquanjiang.com/app/paikao/getpaikao" /> | |||
<!--考试系统学生端--> | |||
<add key="kaoshisystemurl" value="http://ks.bjquanjiang.com/RereClientConnector" /> | |||
<!--批量生成学生帐号时默认的角色Id--> | |||
@@ -0,0 +1,28 @@ | |||
using Learun.Application.TwoDevelopment.EducationalAdministration; | |||
using System.Data.Entity.ModelConfiguration; | |||
namespace Learun.Application.Mapping | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-12-09 14:27 | |||
/// 描 述:排考明细 | |||
/// </summary> | |||
public class ArrangeExamTermItemNewMap : EntityTypeConfiguration<ArrangeExamTermItemNewEntity> | |||
{ | |||
public ArrangeExamTermItemNewMap() | |||
{ | |||
#region 表、主键 | |||
//表 | |||
this.ToTable("ARRANGEEXAMTERMITEMNEW"); | |||
//主键 | |||
this.HasKey(t => t.Id); | |||
#endregion | |||
#region 配置关系 | |||
#endregion | |||
} | |||
} | |||
} |
@@ -67,6 +67,7 @@ | |||
<Compile Include="AssetManagementSystem\Ass_PurchaseItemApplyMap.cs" /> | |||
<Compile Include="AssetManagementSystem\Ass_ScrapItemMap.cs" /> | |||
<Compile Include="AssetManagementSystem\Ass_ScrapMap.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeExamTermItemNewMap.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeLessonSyncMap.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeLessonTermAttemperMap.cs" /> | |||
<Compile Include="EducationalAdministration\Book_borrowinfoMap.cs" /> | |||
@@ -190,6 +190,11 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
#region 扩展数据 | |||
/// <summary> | |||
/// 2021新排考接口 | |||
/// </summary> | |||
/// <param name="entity"></param> | |||
/// <returns></returns> | |||
public async Task<bool> AsyncArrangeExamDataNew(ArrangeLessonTermEntity entity) | |||
{ | |||
bool result = false; | |||
@@ -207,7 +212,9 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
var lessonData = this.BaseRepository("CollegeMIS").FindList<LessonInfoEntity>().ToList(); | |||
HttpContent httpContent = new StringContent("{\"school\":\"" + entity.F_SchoolId + "\",\"year\":\"" + entity.AcademicYearNo + "\",\"number\":\"" + entity.Semester + "\"}"); | |||
httpContent.Headers.ContentType = new System.Net.Http.Headers.MediaTypeHeaderValue("application/json"); | |||
var apiData = await Client.PostAsync(Config.GetValue("ArrangeExamAPINew"), httpContent).Result.Content.ReadAsStringAsync(); | |||
var apiData = await Client.PostAsync(Config.GetValue("ArrangeExamAPINew"), httpContent).Result.Content.ReadAsStringAsync(); | |||
//明细接口 | |||
Client.PostAsync(Config.GetValue("ArrangeExamItemAPINew"), httpContent); | |||
if (!string.IsNullOrEmpty(apiData)) | |||
{ | |||
var data = JsonConvert.DeserializeObject<ArrangeExamRoot>(apiData); | |||
@@ -0,0 +1,148 @@ | |||
using Learun.Util; | |||
using System; | |||
using System.Data; | |||
using System.Collections.Generic; | |||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-12-09 14:27 | |||
/// 描 述:排考明细 | |||
/// </summary> | |||
public class ArrangeExamTermItemNewBLL : ArrangeExamTermItemNewIBLL | |||
{ | |||
private ArrangeExamTermItemNewService arrangeExamTermItemNewService = new ArrangeExamTermItemNewService(); | |||
#region 获取数据 | |||
/// <summary> | |||
/// 获取列表数据 | |||
/// </summary> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ArrangeExamTermItemNewEntity> GetList(string queryJson) | |||
{ | |||
try | |||
{ | |||
return arrangeExamTermItemNewService.GetList(queryJson); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取列表分页数据 | |||
/// </summary> | |||
/// <param name="pagination">分页参数</param> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ArrangeExamTermItemNewEntity> GetPageList(Pagination pagination, string queryJson) | |||
{ | |||
try | |||
{ | |||
return arrangeExamTermItemNewService.GetPageList(pagination, queryJson); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
public ArrangeExamTermItemNewEntity GetEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
return arrangeExamTermItemNewService.GetEntity(keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
#region 提交数据 | |||
/// <summary> | |||
/// 删除实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DeleteEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
arrangeExamTermItemNewService.DeleteEntity(keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 保存实体数据(新增、修改) | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="entity">实体</param> | |||
public void SaveEntity(string keyValue, ArrangeExamTermItemNewEntity entity) | |||
{ | |||
try | |||
{ | |||
arrangeExamTermItemNewService.SaveEntity(keyValue, entity); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowBusinessException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
} | |||
} |
@@ -0,0 +1,139 @@ | |||
using Learun.Util; | |||
using System; | |||
using System.ComponentModel.DataAnnotations.Schema; | |||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-12-09 14:27 | |||
/// 描 述:排考明细 | |||
/// </summary> | |||
public class ArrangeExamTermItemNewEntity | |||
{ | |||
#region 实体成员 | |||
/// <summary> | |||
/// Id | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("ID")] | |||
public string Id { get; set; } | |||
/// <summary> | |||
/// AcademicYearNo | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("ACADEMICYEARNO")] | |||
public string AcademicYearNo { get; set; } | |||
/// <summary> | |||
/// Semester | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("SEMESTER")] | |||
public string Semester { get; set; } | |||
/// <summary> | |||
/// ExamDate | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("EXAMDATE")] | |||
public DateTime? ExamDate { get; set; } | |||
/// <summary> | |||
/// ExamTime | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("EXAMTIME")] | |||
public string ExamTime { get; set; } | |||
/// <summary> | |||
/// ClassNo | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CLASSNO")] | |||
public string ClassNo { get; set; } | |||
/// <summary> | |||
/// ClassName | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CLASSNAME")] | |||
public string ClassName { get; set; } | |||
/// <summary> | |||
/// LessonNo | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("LESSONNO")] | |||
public string LessonNo { get; set; } | |||
/// <summary> | |||
/// LessonName | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("LESSONNAME")] | |||
public string LessonName { get; set; } | |||
/// <summary> | |||
/// EmpNo | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("EMPNO")] | |||
public string EmpNo { get; set; } | |||
/// <summary> | |||
/// EmpName | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("EMPNAME")] | |||
public string EmpName { get; set; } | |||
/// <summary> | |||
/// ClassRoomNo | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CLASSROOMNO")] | |||
public string ClassRoomNo { get; set; } | |||
/// <summary> | |||
/// ClassRoomName | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("CLASSROOMNAME")] | |||
public string ClassRoomName { get; set; } | |||
/// <summary> | |||
/// F_SchoolId | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("F_SCHOOLID")] | |||
public string F_SchoolId { get; set; } | |||
/// <summary> | |||
/// SitNumber | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("SITNUMBER")] | |||
public string SitNumber { get; set; } | |||
/// <summary> | |||
/// StuNo | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("STUNO")] | |||
public string StuNo { get; set; } | |||
/// <summary> | |||
/// StuName | |||
/// </summary> | |||
/// <returns></returns> | |||
[Column("STUNAME")] | |||
public string StuName { get; set; } | |||
#endregion | |||
#region 扩展操作 | |||
/// <summary> | |||
/// 新增调用 | |||
/// </summary> | |||
public void Create() | |||
{ | |||
this.Id = Guid.NewGuid().ToString(); | |||
} | |||
/// <summary> | |||
/// 编辑调用 | |||
/// </summary> | |||
/// <param name="keyValue"></param> | |||
public void Modify(string keyValue) | |||
{ | |||
this.Id = keyValue; | |||
} | |||
#endregion | |||
} | |||
} |
@@ -0,0 +1,55 @@ | |||
using Learun.Util; | |||
using System.Data; | |||
using System.Collections.Generic; | |||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-12-09 14:27 | |||
/// 描 述:排考明细 | |||
/// </summary> | |||
public interface ArrangeExamTermItemNewIBLL | |||
{ | |||
#region 获取数据 | |||
/// <summary> | |||
/// 获取列表数据 | |||
/// </summary> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
IEnumerable<ArrangeExamTermItemNewEntity> GetList(string queryJson); | |||
/// <summary> | |||
/// 获取列表分页数据 | |||
/// </summary> | |||
/// <param name="pagination">分页参数</param> | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
IEnumerable<ArrangeExamTermItemNewEntity> GetPageList(Pagination pagination, string queryJson); | |||
/// <summary> | |||
/// 获取实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
ArrangeExamTermItemNewEntity GetEntity(string keyValue); | |||
#endregion | |||
#region 提交数据 | |||
/// <summary> | |||
/// 删除实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
void DeleteEntity(string keyValue); | |||
/// <summary> | |||
/// 保存实体数据(新增、修改) | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="entity">实体</param> | |||
void SaveEntity(string keyValue, ArrangeExamTermItemNewEntity entity); | |||
#endregion | |||
} | |||
} |
@@ -0,0 +1,235 @@ | |||
using Dapper; | |||
using Learun.DataBase.Repository; | |||
using Learun.Util; | |||
using System; | |||
using System.Collections.Generic; | |||
using System.Data; | |||
using System.Text; | |||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
{ | |||
/// <summary> | |||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||
/// 创 建:超级管理员 | |||
/// 日 期:2021-12-09 14:27 | |||
/// 描 述:排考明细 | |||
/// </summary> | |||
public class ArrangeExamTermItemNewService : RepositoryFactory | |||
{ | |||
#region 构造函数和属性 | |||
private string fieldSql; | |||
/// <summary> | |||
/// 构造方法 | |||
/// </summary> | |||
public ArrangeExamTermItemNewService() | |||
{ | |||
fieldSql = @" | |||
t.Id, | |||
t.AcademicYearNo, | |||
t.Semester, | |||
t.ExamDate, | |||
t.ExamTime, | |||
t.ClassNo, | |||
t.ClassName, | |||
t.LessonNo, | |||
t.LessonName, | |||
t.EmpNo, | |||
t.EmpName, | |||
t.ClassRoomNo, | |||
t.ClassRoomName, | |||
t.F_SchoolId, | |||
t.SitNumber, | |||
t.StuNo, | |||
t.StuName | |||
"; | |||
} | |||
#endregion | |||
#region 获取数据 | |||
/// <summary> | |||
/// 获取列表数据 | |||
/// </summary> | |||
/// <param name="queryJson">条件参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ArrangeExamTermItemNewEntity> GetList(string queryJson) | |||
{ | |||
try | |||
{ | |||
//参考写法 | |||
//var queryParam = queryJson.ToJObject(); | |||
// 虚拟参数 | |||
//var dp = new DynamicParameters(new { }); | |||
//dp.Add("startTime", queryParam["StartTime"].ToDate(), DbType.DateTime); | |||
var strSql = new StringBuilder(); | |||
strSql.Append("SELECT "); | |||
strSql.Append(fieldSql); | |||
strSql.Append(" FROM ArrangeExamTermItemNew t "); | |||
return this.BaseRepository("CollegeMIS").FindList<ArrangeExamTermItemNewEntity>(strSql.ToString()); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取列表分页数据 | |||
/// </summary> | |||
/// <param name="pagination">分页参数</param> | |||
/// <param name="queryJson">条件参数</param> | |||
/// <returns></returns> | |||
public IEnumerable<ArrangeExamTermItemNewEntity> GetPageList(Pagination pagination, string queryJson) | |||
{ | |||
try | |||
{ | |||
var strSql = new StringBuilder(); | |||
strSql.Append("SELECT "); | |||
strSql.Append(fieldSql); | |||
strSql.Append(" FROM ArrangeExamTermItemNew t where 1=1 "); | |||
var queryParam = queryJson.ToJObject(); | |||
if (!queryParam["AcademicYearNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.AcademicYearNo='" + queryParam["AcademicYearNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["Semester"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.Semester='" + queryParam["Semester"].ToString() + "' "); | |||
} | |||
if (!queryParam["LessonNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.LessonNo='" + queryParam["LessonNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["ClassNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.ClassNo='" + queryParam["ClassNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["StuNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.StuNo='" + queryParam["StuNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["EmpNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.EmpNo='" + queryParam["EmpNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["ClassRoomNo"].IsEmpty()) | |||
{ | |||
strSql.Append(" and t.ClassRoomNo='" + queryParam["ClassRoomNo"].ToString() + "' "); | |||
} | |||
if (!queryParam["StartTime"].IsEmpty() && !queryParam["EndTime"].IsEmpty()) | |||
{ | |||
strSql.Append(" AND ( ExamDate >= '" + queryParam["StartTime"].ToString() + "' AND ExamDate <= '" + queryParam["StartTime"].ToString() + "' ) "); | |||
} | |||
return this.BaseRepository("CollegeMIS").FindList<ArrangeExamTermItemNewEntity>(strSql.ToString(),null,pagination); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 获取实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
/// <returns></returns> | |||
public ArrangeExamTermItemNewEntity GetEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
return this.BaseRepository("CollegeMIS").FindEntity<ArrangeExamTermItemNewEntity>(keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
#region 提交数据 | |||
/// <summary> | |||
/// 删除实体数据 | |||
/// </summary> | |||
/// <param name="keyValue">主键</param> | |||
public void DeleteEntity(string keyValue) | |||
{ | |||
try | |||
{ | |||
this.BaseRepository("CollegeMIS").Delete<ArrangeExamTermItemNewEntity>(t => t.Id == keyValue); | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
/// <summary> | |||
/// 保存实体数据(新增、修改) | |||
/// <param name="keyValue">主键</param> | |||
/// <param name="entity">实体</param> | |||
/// </summary> | |||
public void SaveEntity(string keyValue, ArrangeExamTermItemNewEntity entity) | |||
{ | |||
try | |||
{ | |||
if (!string.IsNullOrEmpty(keyValue)) | |||
{ | |||
entity.Modify(keyValue); | |||
this.BaseRepository("CollegeMIS").Update(entity); | |||
} | |||
else | |||
{ | |||
entity.Create(); | |||
this.BaseRepository("CollegeMIS").Insert(entity); | |||
} | |||
} | |||
catch (Exception ex) | |||
{ | |||
if (ex is ExceptionEx) | |||
{ | |||
throw; | |||
} | |||
else | |||
{ | |||
throw ExceptionEx.ThrowServiceException(ex); | |||
} | |||
} | |||
} | |||
#endregion | |||
} | |||
} |
@@ -67,7 +67,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
} | |||
} | |||
public IEnumerable<ArrangeExamTermNewEntity> GetItemPageList(Pagination pagination, string queryJson) | |||
public IEnumerable<ArrangeExamTermItemNewEntity> GetItemPageList(Pagination pagination, string queryJson) | |||
{ | |||
try | |||
{ | |||
@@ -102,11 +102,17 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
/// <summary> | |||
/// 座位编号 | |||
/// </summary> | |||
[NotMapped] | |||
public string SitNumber { get; set; } | |||
[NotMapped] | |||
public string StuNo { get; set; } | |||
[NotMapped] | |||
public string StuName { get; set; } | |||
[NotMapped] | |||
public string StartDate { get; set; } | |||
[NotMapped] | |||
public string EndDate { get; set; } | |||
[NotMapped] | |||
public string Teacher { get; set; } | |||
#endregion | |||
@@ -28,7 +28,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
/// <param name="queryJson">查询参数</param> | |||
/// <returns></returns> | |||
IEnumerable<ArrangeExamTermNewEntity> GetPageList(Pagination pagination, string queryJson); | |||
IEnumerable<ArrangeExamTermNewEntity> GetItemPageList(Pagination pagination, string queryJson); | |||
IEnumerable<ArrangeExamTermItemNewEntity> GetItemPageList(Pagination pagination, string queryJson); | |||
/// <summary> | |||
/// 获取实体数据 | |||
/// </summary> | |||
@@ -78,7 +78,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
var strSql = new StringBuilder(); | |||
strSql.Append("SELECT "); | |||
strSql.Append(fieldSql); | |||
strSql.Append(" FROM ArrangeExamTermNew t "); | |||
strSql.Append(" FROM ArrangeExamTermNew t where 1=1 "); | |||
var queryParam = queryJson.ToJObject(); | |||
var dp = new DynamicParameters(new { }); | |||
if (!queryParam["AcademicYearNo"].IsEmpty()) | |||
@@ -137,7 +137,7 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||
/// <param name="pagination"></param> | |||
/// <param name="queryJson"></param> | |||
/// <returns></returns> | |||
public IEnumerable<ArrangeExamTermNewEntity> GetItemPageList(Pagination pagination, string queryJson) | |||
public IEnumerable<ArrangeExamTermItemNewEntity> GetItemPageList(Pagination pagination, string queryJson) | |||
{ | |||
try | |||
{ | |||
@@ -180,21 +180,8 @@ where a.student is not null and a.currid is not null) t where 1=1 "); | |||
{ | |||
strSql.Append(" AND ( StartDate >= '" + queryParam["StartTime"].ToString() + "' AND StartDate <= '" + queryParam["StartTime"].ToString() + "' ) "); | |||
} | |||
var teacherlist = BaseRepository("paikeDbString").FindList<dynamic>("select name,id,number from tb_teacher"); | |||
var list= this.BaseRepository("paikeDbString").FindList<ArrangeExamTermNewEntity>(strSql.ToString(), null, pagination); | |||
foreach (var item in list) | |||
{ | |||
if (!string.IsNullOrEmpty(item.Teacher)) | |||
{ | |||
foreach (var teacheritem in item.Teacher.Split(',')) | |||
{ | |||
item.EmpNo +=teacherlist.FirstOrDefault(m=>m.id==teacheritem)?.number +","; | |||
item.EmpName += teacherlist.FirstOrDefault(m => m.id == teacheritem)?.name + ","; | |||
} | |||
} | |||
} | |||
return list; | |||
return this.BaseRepository("paikeDbString").FindList<ArrangeExamTermItemNewEntity>(strSql.ToString(), null, pagination); | |||
} | |||
catch (Exception ex) | |||
{ | |||
@@ -91,6 +91,10 @@ | |||
<Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemEntity.cs" /> | |||
<Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemIBLL.cs" /> | |||
<Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemService.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeExamTermItemNew\ArrangeExamTermItemNewBLL.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeExamTermItemNew\ArrangeExamTermItemNewEntity.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeExamTermItemNew\ArrangeExamTermItemNewIBLL.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeExamTermItemNew\ArrangeExamTermItemNewService.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeLessonSync\ArrangeLessonSyncBLL.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeLessonSync\ArrangeLessonSyncEntity.cs" /> | |||
<Compile Include="EducationalAdministration\ArrangeLessonSync\ArrangeLessonSyncIBLL.cs" /> | |||