76 lines
2.4 KiB
C#
76 lines
2.4 KiB
C#
using HL_FristAidPlatform_DataBase;
|
|
using HL_FristAidPlatform_Help;
|
|
using HL_FristAidPlatform_IDataBase;
|
|
using HL_FristAidPlatform_Models;
|
|
|
|
namespace HL_FristAidPlatform_Bussiness
|
|
{
|
|
public class T_Base_ConfigBLL
|
|
{
|
|
private IT_Base_Config IService = new T_Base_ConfigDB();
|
|
|
|
public MessageModel<T_Base_Config> Add(T_Base_Config entity)
|
|
{
|
|
if (IService.Add(entity))
|
|
{
|
|
return new MessageModel<T_Base_Config> { Success = true, Msg = "操作成功" };
|
|
}
|
|
else
|
|
{
|
|
return new MessageModel<T_Base_Config> { Success = false, Msg = "操作失败" };
|
|
}
|
|
}
|
|
|
|
public MessageModel<T_Base_Config> Dels(dynamic[] ids)
|
|
{
|
|
if (IService.Dels(ids))
|
|
{
|
|
return new MessageModel<T_Base_Config> { Success = true, Msg = "操作成功" };
|
|
}
|
|
else
|
|
{
|
|
return new MessageModel<T_Base_Config> { Success = false, Msg = "操作失败" };
|
|
}
|
|
}
|
|
|
|
public MessageModel<T_Base_Config> Update(T_Base_Config entity)
|
|
{
|
|
if (IService.Update(entity))
|
|
{
|
|
return new MessageModel<T_Base_Config> { Success = true, Msg = "操作成功" };
|
|
}
|
|
else
|
|
{
|
|
return new MessageModel<T_Base_Config> { Success = false, Msg = "操作失败" };
|
|
}
|
|
}
|
|
|
|
public T_Base_Config Get(long id)
|
|
{
|
|
return IService.Get(id);
|
|
}
|
|
|
|
/// <summary>
|
|
/// 获取列表
|
|
/// </summary>
|
|
/// <param name="pageIndex">起始页</param>
|
|
/// <param name="pageSize">每页大小</param>
|
|
/// <param name="keyWord">关键词</param>
|
|
/// <param name="isPublic">权限控制-1:全部 0:公有,所有用户都可以更改 1:私有,只有指定用户可以修改</param>
|
|
/// <returns></returns>
|
|
public TableModel<T_Base_ConfigModel> GetPageList(int pageIndex, int pageSize, string keyWord, int isPublic)
|
|
{
|
|
return IService.GetPageList(pageIndex, pageSize, keyWord, isPublic);
|
|
}
|
|
|
|
/// <summary>
|
|
/// 获取列表-无分页
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
public TableModel<T_Base_ConfigModel> GetList()
|
|
{
|
|
return IService.GetList();
|
|
}
|
|
}
|
|
}
|