Esempio n. 1
0
 public ValuesController (cmsContext context) {
     _context = context;
     lstItems = (from a in _context.Article join al in _context.ArticleLanguage on a.ArticleId equals al.FkArticleId
         where al.LangName == "ar"
         select new ArticleData {
             ArticleId = a.ArticleId,
                 ArticleTitle = al.Title,
                 ImagePath = a.ImagePath,
                 published = a.IsPublished
         }).ToList ();
 }
Esempio n. 2
0
        public productTest()
        {
            DbContextOptions <cmsContext> options;
            var builder = new DbContextOptionsBuilder <cmsContext>();

            //builder.UseSqlServer(connectionstr);
            builder.UseInMemoryDatabase(databaseName: "kevsDatabase");
            options = builder.Options;

            _context = new cmsContext(options);

            InitialiseData();
        }
Esempio n. 3
0
 public EntryController()
 {
     this.context = new cmsContext();
     context.Configuration.ProxyCreationEnabled = false;
 }
Esempio n. 4
0
        public SecurityController(cmsContext context, JwtSettings settings)
        {
            _context = context;

            _settings = settings;
        }
Esempio n. 5
0
 public ProductsService(cmsContext context)
 {
     _context = context;
 }
 public ProductController(cmsContext context)
 {
     _context = context;
     //this.configuration = Configuration;
     //this.connectionString = this.configuration.GetConnectionString("kevinangularcms");
 }
Esempio n. 7
0
 public void Dispose()
 {
     _context = null;
 }
Esempio n. 8
0
 public SecurityService(cmsContext context)
 {
     _context = context;
 }
Esempio n. 9
0
 public SecurityManager(cmsContext context, JwtSettings settings)
 {
     _settings = settings;
     _context  = context;
 }