Пример #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            var context = new DatabaseDataContext(Config.Database.ConnectionString);
            Product = new CacheProduct(context.Products.First());

            Json = Common.Serializing.Json.Deserialise<JsonPage>(File.ReadAllText(@"C:\Work\Webshop\Web\static\data\product\100.001.json"));
        }
Пример #2
0
 public CacheVariant(Variant data, JsonPage json)
 {
     this.data = data;
     this.json = json;
 }
Пример #3
0
 public CachePage(Page data, JsonPage json)
 {
     this.data = data;
     this.json = json;
 }
Пример #4
0
 public CacheProduct(Product data, JsonPage json)
 {
     this.data = data;
     this.json = json;
     this.variants.AddRange(product.Variants.Select(c => new CacheVariant(c, json)));
 }