public void Configuration(IAppBuilder app) { app.CreatePerOwinContext <EMRContext>(() => EMRContext.Create()); app.CreatePerOwinContext <AppUserManager>(AppUserManager.Create); app.UseCookieAuthentication(new CookieAuthenticationOptions { AuthenticationType = DefaultAuthenticationTypes.ApplicationCookie, LoginPath = new PathString("/Login/SignIn"), }); }
public void SetUp() { _context = new EMRContext(_options); _configRepository = new ConfigRepository(_context); _testUser = new User("MauntestMaun"); _testGroup = new Group("MaungroupMaun"); _testGroupNew = new Group("MaungroupMaunNEW"); _featureIds = _context.Features.Where(x => x.DeleteFlag == 0).Take(2).Select(x => x.FeatureID).ToList(); _userIds = _context.Users.Where(x => x.DeleteFlag == 0).Select(x => x.UserId).ToList(); _context.Add(_testUser); _context.Add(_testGroup); _context.SaveChanges(); }
public void Init() { var config = new ConfigurationBuilder() .AddJsonFile("appsettings.json") .Build(); var connectionString = config["connectionStrings:EMRConnection"]; _options = new DbContextOptionsBuilder <EMRContext>() .UseSqlServer(connectionString) .Options; var context = new EMRContext(_options); context.ApplyMigrations(); context.UpdateTranslations(); }
protected BaseRepository(EMRContext context) { Context = context; }
public CommonRepository(IHMSContext context, EMRContext emrContext = null) : base(context) { _context = context; _emrContext = emrContext; }
public KlassRepository(EMRContext context) { db = context; }
public ConfigRepository(EMRContext context) : base(context) { }
public EmrRepository() { _emrContext = new EMRContext(); }
public CrmPersonRepository(EMRContext context) { db = context; }
public PStoreRepository(EMRContext context) : base(context) { }