static Setting() { shop2Entities db = new shop2Entities(); if (Value == null) { Value = new Dictionary <string, string>(); var _settings = db.oc_setting.Where(r => r.store_id == 1).ToList(); foreach (var _setting in _settings) { Value.Add(_setting.key, _setting.value); } } db.Dispose(); }
public HomeController() { db = new shop2Entities(); }
public ReviewController() { db = new Data.shop2Entities(); }
public AccountController() { db = new shop2Entities(); }
public ManufacturerController() { db = new shop2Entities(); }
public ProductController() { db = new shop2Entities(); }
public ProductController() { db = new shop2Entities(); db.Database.Log = s => System.Diagnostics.Debug.WriteLine(s); }