protected void InitQuery(vCartItemProductInfoQuery query) { query.OnLoadDelegate = this.OnQueryLoaded; if (!query.es2.HasConnection) { query.es2.Connection = ((IEntity)this).Connection; } }
public List <vCartItemProductInfo> GetCartItemsWithProductInfo() { if (this.Id.HasValue) { vCartItemProductInfoQuery q = new vCartItemProductInfoQuery(); q.Where(q.CartId == this.Id.Value); q.OrderBy(q.CreatedOn.Ascending); vCartItemProductInfoCollection collection = new vCartItemProductInfoCollection(); collection.Load(q); return(collection.ToList()); } return(new List <vCartItemProductInfo>()); }
public bool Load(vCartItemProductInfoQuery query) { this.query = query; InitQuery(this.query); return(Query.Load()); }