示例#1
0
 public RepositoryBase(AmsDbContext context)
 {
     lock (context)
     {
         dbContext = context;
         dbSet     = context.Set <T>();
     }
 }
示例#2
0
 public AmsDbContext Init()
 {
     return(dbContext ?? (dbContext = new AmsDbContext()));
 }
示例#3
0
 public UnitOfWork(AmsDbContext context)
 {
     this.context = context;
 }
示例#4
0
 public UnitOfWork()
 {
     this.context = new AmsDbContext();
 }