public static NotSaleTemplate Parse(int id, IDataProperty property) { var t = new NotSaleTemplate { ID = id }; return(t); }
public override Task LoadAll() { var property = Collection.Resolve("Server/NotSale.img"); property.Children .ToDictionary( c => c.Resolve <int>() ?? 0, c => NotSaleTemplate.Parse(c.Resolve <int>() ?? 0, c) ) .ForEach(kv => Templates.Add(kv.Key, kv.Value)); return(Task.CompletedTask); }