示例#1
0
    public void BindOrder()
    {
        User bll = new User();

        if (Session["CommodityimagesName"] != null)
        {
            FormViewOrder.DataSource = bll.GetUserDataByName(Session["CommodityimagesName"].ToString());
            FormViewOrder.DataBind();
        }
    }
示例#2
0
    protected void ButtonPay_Click(object sender, EventArgs e)
    {
        string    txtModel     = ((DropDownList)FormViewOrder.FindControl("PostSelect")).SelectedItem.Text.ToString();
        string    txtId        = ((Label)FormViewOrderData.FindControl("LaOrder")).Text.Trim().ToString();
        string    txtPost      = ((TextBox)FormViewOrder.FindControl("UserPost")).Text.Trim().ToString();
        string    txtAdress    = ((TextBox)FormViewOrder.FindControl("Adress")).Text.Trim().ToString();
        string    txtPhone     = ((TextBox)FormViewOrder.FindControl("Phone")).Text.Trim().ToString();
        string    txtPhonetele = ((TextBox)FormViewOrder.FindControl("Phonetele")).Text.Trim().ToString();
        Order     bll          = new Order();
        OrderInfo orderInfo    = new OrderInfo(txtId, txtModel, txtAdress, int.Parse(txtPost), txtPhone, Int64.Parse(txtPhonetele));
        int       rows         = bll.UpdateDataOrder(orderInfo, txtId);

        if (rows > 0)
        {
            BindOrderData();
            Response.Redirect("PayNow.aspx?oid=" + txtId);
        }
    }