Example #1
0
    public void bind_date(int _id)
    {
        Cms.BLL.C_order_integral   bll   = new Cms.BLL.C_order_integral();
        Cms.Model.C_order_integral model = bll.GetModel(_id);
        ordernum.InnerHtml    = model.order_num;
        updateTime.InnerHtml  = model.updateTime.ToString();
        OrderStatus.InnerHtml = getState(Convert.ToInt32(model.order_status));

        countprice.InnerHtml = model.price_sum.ToString();
        Quantity.InnerHtml   = model.quantity_sum.ToString();


        integral_sum.InnerHtml = model.integral_sum.ToString();

        note.InnerHtml             = model.note.ToString();
        recommended_code.InnerHtml = model.recommended_code.ToString();
        #region 会员信息=====================
        int            struserid = Convert.ToInt32(model.user_id);
        Cms.BLL.C_user blluser   = new Cms.BLL.C_user();
        DataSet        ds2       = blluser.GetList("id=" + struserid);
        if (ds2 != null && ds2.Tables[0].Rows.Count > 0)
        {
            UserName.InnerHtml  = ds2.Tables[0].Rows[0]["username"].ToString();
            userMoney.InnerHtml = Convert.ToDecimal(ds2.Tables[0].Rows[0]["userMoney"]).ToString("0.00");
            userJifen.InnerHtml = ds2.Tables[0].Rows[0]["userscore"].ToString();
        }
        else
        {
            userinfo.InnerHtml = "匿名用户";
        }
        #endregion

        #region 产品信息===========================
        Cms.BLL.C_order_integralsub bllordersub = new Cms.BLL.C_order_integralsub();
        DataSet ds1 = bllordersub.GetList("order_id=" + _id);
        if (ds1 != null && ds1.Tables[0].Rows.Count > 0)
        {
            Repeaterordersub.DataSource = ds1.Tables[0].DefaultView;
            Repeaterordersub.DataBind();
        }
        #endregion

        #region 收货信息===========================

        DataSet ds3 = new Cms.BLL.sc_stores().GetList("id=" + model.storesId);
        if (ds3 != null && ds3.Tables[0].Rows.Count > 0)
        {
            RepAddress.DataSource = ds3.Tables[0].DefaultView;
            RepAddress.DataBind();
        }
        #endregion
    }
Example #2
0
 /// <summary>
 /// 更新一条数据
 /// </summary>
 public bool Update(Cms.Model.C_order_integral model)
 {
     return(dal.Update(model));
 }
Example #3
0
 /// <summary>
 /// 增加一条数据
 /// </summary>
 public int  Add(Cms.Model.C_order_integral model)
 {
     return(dal.Add(model));
 }