Exemplo n.º 1
0
        protected void BindData()
        {
            if (Session["GrocId"] != null)
            {
                int GrocerId = int.Parse(Session["GrocId"].ToString());
                using (dbDatabaseDataDataContext db = new dbDatabaseDataDataContext())
                {
                    int CustOrderId = int.Parse(Request.QueryString["CusterOrderId"]);
                    var data        = (from s in db.SPListOdr(CustOrderId, GrocerId)
                                       // where s.flag != "Accept"
                                       select new
                    {
                        // s.CustFullName,
                        s.GrocerId,
                        s.CustomerId,
                        s.CustmerOdrId,
                        //s.ConfirmOdrID,
                        //s.Address,
                        //  s.MobileNo,
                        //   s.EmailId,
                        // s.Delivery_Date,
                        //  s.Toatal_price
                        s.cartID,
                        s.productDtl,
                        s.productPkgQty,
                        s.Quantity,
                        s.ItemName,
                        s.OfferRate,
                        s.Total,
                        s.MRP
                    }).Distinct().ToList();



                    if (data.Count != 0)
                    {
                        gvCordersList.DataSource = data;
                        gvCordersList.DataBind();
                    }
                    else
                    {
                        lblnorecordfound.Visible = true;
                    }
                }
            }
        }