Commit 6ada2c23 authored by 黄奎's avatar 黄奎

页面修改

parent 58b29509
......@@ -23,9 +23,9 @@ namespace Edu.Module.Duty
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public List<RB_Duty_Item_ViewModel> GetDutyItemRepository(RB_Duty_Item_ViewModel query)
public List<RB_Duty_Item_ViewModel> GetDutyItemListExtModule(RB_Duty_Item_ViewModel query)
{
return dutyItemRepository.GetDutyItemRepository(query);
return dutyItemRepository.GetDutyItemListExtRepository(query);
}
/// <summary>
......@@ -42,8 +42,6 @@ namespace Edu.Module.Duty
return dutyItemRepository.Update(fileds, new WhereHelper(nameof(RB_Duty_Item_ViewModel.Id), Id));
}
/// <summary>
/// 新增/修改值班事项信息
/// </summary>
......@@ -64,7 +62,7 @@ namespace Edu.Module.Duty
{ nameof(RB_Duty_Item_ViewModel.Shifts),model.Shifts},
{ nameof(RB_Duty_Item_ViewModel.ItemSchools),model.ItemSchools},
{ nameof(RB_Duty_Item_ViewModel.UpdateBy),model.UpdateBy},
{ nameof(RB_Duty_Item_ViewModel.UpdateTime),model.UpdateTime},
{ nameof(RB_Duty_Item_ViewModel.UpdateTime),model.UpdateTime},
};
return dutyItemRepository.Update(fileds, new WhereHelper(nameof(RB_Duty_Item_ViewModel.Id), model.Id));
}
......@@ -115,7 +113,6 @@ namespace Edu.Module.Duty
return list;
}
/// <summary>
/// 获取值班设置列表
/// </summary>
......@@ -126,7 +123,6 @@ namespace Edu.Module.Duty
return dutyConfigRepository.GetDutyConfigList(query);
}
/// <summary>
/// 删除值班设置
/// </summary>
......@@ -141,8 +137,6 @@ namespace Edu.Module.Duty
return dutyConfigRepository.Update(fileds, new WhereHelper(nameof(RB_Duty_Config_ViewModel.Id), Id));
}
/// <summary>
/// 新增/修改班次信息
/// </summary>
......@@ -163,7 +157,8 @@ namespace Edu.Module.Duty
{ nameof(RB_Duty_Config_ViewModel.MachineCode),model.MachineCode},
{ nameof(RB_Duty_Config_ViewModel.School_Id),model.School_Id},
{ nameof(RB_Duty_Config_ViewModel.UpdateBy),model.UpdateBy},
{ nameof(RB_Duty_Config_ViewModel.UpdateTime),model.UpdateTime},
{ nameof(RB_Duty_Config_ViewModel.UpdateTime),model.UpdateTime},
{ nameof(RB_Duty_Config_ViewModel.SendEmployeeIds),model.SendEmployeeIds},
};
return dutyConfigRepository.Update(fileds, new WhereHelper(nameof(RB_Duty_Config_ViewModel.Id), model.Id));
}
......@@ -177,28 +172,21 @@ namespace Edu.Module.Duty
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public List<RB_Duty_Frequency_ViewModel> GetDutyFrequencyRepository(RB_Duty_Frequency_ViewModel query)
public List<RB_Duty_Frequency_ViewModel> GetDutyFrequencyModule(RB_Duty_Frequency_ViewModel query)
{
var list = dutyFrequencyRepository.GetDutyFrequencyRepository(query);
return list;
return dutyFrequencyRepository.GetDutyFrequencyRepository(query);
}
/// <summary>
/// 获取班次设置列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public List<RB_Duty_Frequency_ViewModel> GetDutyFrequencyBySchoolIds(int Group_Id, string SchoolIds)
public List<RB_Duty_Frequency_ViewModel> GetDutyFrequencyBySchoolIdsModule(int Group_Id, string SchoolIds)
{
return dutyFrequencyRepository.GetDutyFrequencyBySchoolIds(Group_Id, SchoolIds);
return dutyFrequencyRepository.GetDutyFrequencyBySchoolIdsRepository(Group_Id, SchoolIds);
}
/// <summary>
/// 删除班次
/// </summary>
......@@ -213,14 +201,12 @@ namespace Edu.Module.Duty
return dutyFrequencyRepository.Update(fileds, new WhereHelper(nameof(RB_Duty_Frequency_ViewModel.Id), Id));
}
/// <summary>
/// 新增/修改班次信息
/// </summary>
/// <param name="model"></param>
/// <returns></returns>
public bool SetFrequencyModel(RB_Duty_Frequency_ViewModel model)
public bool SetFrequencyModule(RB_Duty_Frequency_ViewModel model)
{
if (model.Id == 0)
{
......@@ -235,7 +221,7 @@ namespace Edu.Module.Duty
{ nameof(RB_Duty_Frequency_ViewModel.EndTime),model.EndTime},
{ nameof(RB_Duty_Frequency_ViewModel.School_Ids),model.School_Ids},
{ nameof(RB_Duty_Frequency_ViewModel.UpdateBy),model.UpdateBy},
{ nameof(RB_Duty_Frequency_ViewModel.UpdateTime),model.UpdateTime},
{ nameof(RB_Duty_Frequency_ViewModel.UpdateTime),model.UpdateTime},
};
return dutyFrequencyRepository.Update(fileds, new WhereHelper(nameof(RB_Duty_Frequency_ViewModel.Id), model.Id));
}
......
......@@ -45,7 +45,7 @@ namespace Edu.Repository.Duty
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public List<RB_Duty_Frequency_ViewModel> GetDutyFrequencyBySchoolIds(int Group_Id, string SchoolIds)
public List<RB_Duty_Frequency_ViewModel> GetDutyFrequencyBySchoolIdsRepository(int Group_Id, string SchoolIds)
{
StringBuilder builder = new StringBuilder();
builder.AppendFormat(@" SELECT * from rb_duty_frequency where `Status`=0");
......
......@@ -151,7 +151,7 @@ namespace Edu.WebApi.Controllers.Duty
{
Group_Id = base.UserInfo.Group_Id,
};
var list = dutyModule.GetDutyItemRepository(query);
var list = dutyModule.GetDutyItemListExtModule(query);
foreach (var item in list)
{
if (item.CreateBy > 0)
......@@ -173,7 +173,6 @@ namespace Edu.WebApi.Controllers.Duty
{
var query = new RB_Duty_Item_ViewModel()
{
Group_Id = base.UserInfo.Group_Id,
Id = base.ParmJObj.GetInt("Id"),
};
......@@ -181,7 +180,7 @@ namespace Edu.WebApi.Controllers.Duty
{
return ApiResult.Failed("请传入值班事项Id");
}
var model = dutyModule.GetDutyItemRepository(query).FirstOrDefault();
var model = dutyModule.GetDutyItemListExtModule(query).FirstOrDefault();
if (model == null || model.Id <= 0)
{
return ApiResult.Failed("数据不存在");
......@@ -282,7 +281,7 @@ namespace Edu.WebApi.Controllers.Duty
public ApiResult GetDutyFrequencyBySchoolIds()
{
var SchoolIds = base.ParmJObj.GetStringValue("SchoolIds");
var list = dutyModule.GetDutyFrequencyBySchoolIds(base.UserInfo.Group_Id, SchoolIds);
var list = dutyModule.GetDutyFrequencyBySchoolIdsModule(base.UserInfo.Group_Id, SchoolIds);
var result = list.Select(x => new
{
x.Id,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment