优化仓储、Service
This commit is contained in:
@@ -1,11 +1,8 @@
|
||||
using Infrastructure;
|
||||
using Infrastructure.Attribute;
|
||||
using SqlSugar;
|
||||
using System.Collections.Generic;
|
||||
using ZR.Model.Models;
|
||||
using ZR.Model.System;
|
||||
using ZR.Repository;
|
||||
using ZR.Repository.System;
|
||||
using ZR.Service.System.IService;
|
||||
|
||||
namespace ZR.Service.System
|
||||
@@ -19,12 +16,6 @@ namespace ZR.Service.System
|
||||
[AppService(ServiceType = typeof(ISysNoticeService), ServiceLifetime = LifeTime.Transient)]
|
||||
public class SysNoticeService : BaseService<SysNotice>, ISysNoticeService
|
||||
{
|
||||
private readonly SysNoticeRepository _SysNoticerepository;
|
||||
public SysNoticeService(SysNoticeRepository repository)
|
||||
{
|
||||
_SysNoticerepository = repository;
|
||||
}
|
||||
|
||||
#region 业务逻辑代码
|
||||
|
||||
/// <summary>
|
||||
@@ -38,7 +29,7 @@ namespace ZR.Service.System
|
||||
|
||||
//搜索条件查询语法参考Sqlsugar
|
||||
predicate = predicate.And(m => m.Status == "0");
|
||||
return _SysNoticerepository.GetList(predicate.ToExpression());
|
||||
return GetList(predicate.ToExpression());
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
Reference in New Issue
Block a user