爆肝,重构框架,你懂得
This commit is contained in:
21
Yi.Framework.Net6/Yi.Framework.Service/Base/BaseService.cs
Normal file
21
Yi.Framework.Net6/Yi.Framework.Service/Base/BaseService.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using Yi.Framework.Common.Attribute;
|
||||
using Yi.Framework.Interface.Base;
|
||||
using Yi.Framework.Repository;
|
||||
|
||||
namespace Yi.Framework.Service.Base
|
||||
{
|
||||
[AppService]
|
||||
public class BaseService<T> : IBaseService<T> where T : class, new()
|
||||
{
|
||||
public IRepository<T> _repository { get; set; }
|
||||
public BaseService(IRepository<T> iRepository)
|
||||
{
|
||||
_repository = iRepository;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user