Example #1
0
    public void SkipProduct()
    {
        L_ProductInfo pinfo = new longyuan_productinfo().GetProduct(productID);

        txtProNumber.Text      = pinfo.Pronumber;
        txtProductName.Text    = pinfo.ProductName;
        ddlLeavl.SelectedIndex = pinfo.ProductCategoryID;
        imgPhoto.ImageUrl      = "~/photo/" + pinfo.ProductImage;
        txtPrice.Text          = pinfo.Price.ToString().Replace(".0000", "");
        txtCurrentPrince.Text  = pinfo.CurrentPrice.ToString().Replace(".0000", "");
        txtMenberPrince.Text   = pinfo.MenberPrince.ToString().Replace(".0000", "");
        txtPoductStore.Text    = pinfo.ProducStore.ToString();
        this.ddlDanWei.ClearSelection();
        ddlDanWei.Items.FindByValue(pinfo.Danwei).Selected = true;
        this.ddlFreightType.ClearSelection();
        ddlFreightType.Items.FindByValue(pinfo.FreightType).Selected = true;
        txtFreight.Text = pinfo.Freight.ToString().Replace(".0000", "");
        ddlQQList.Items.FindByValue("934532778").Selected = true;
        if (pinfo.Iscommend == 0)
        {
            rbDesc.Checked  = false;
            rbDesc2.Checked = true;
        }
        else
        {
            rbDesc.Checked  = true;
            rbDesc2.Checked = false;
        }
        ddlRemainDay.Items.FindByValue(pinfo.RemainDay.ToString()).Selected = true;
        txtContent.Text    = pinfo.ProductDesc;
        ViewState["photo"] = "noimage.gif";
    }
Example #2
0
    private IList BindIsComnendRepeater(int IsType, int topNum)
    {
        IList  il;
        string CacheName = "cachByClassIDData_" + IsType;

        if (HttpContext.Current.Cache[CacheName] == null)
        {
            il = new longyuan_productinfo().GetIndexBindProductShow(Convert.ToInt16(IsType), " top " + topNum + " ");
            HttpContext.Current.Cache.Add(CacheName, il, null, DateTime.MaxValue, new TimeSpan(0, 3, 0, 0, 0), System.Web.Caching.CacheItemPriority.Normal, null);
        }
        il = (IList)HttpContext.Current.Cache.Get(CacheName);
        return(il);
    }
Example #3
0
    private void BindIsCommendhotShopping()
    {
        IList  il;
        string CacheName = "cachIscommentHotProduct";

        if (HttpContext.Current.Cache[CacheName] == null)
        {
            il = new longyuan_productinfo().GetIndexBindHottuiJian(0, 1, "top 10");
            HttpContext.Current.Cache.Add(CacheName, il, null, DateTime.MaxValue, new TimeSpan(0, 3, 0, 0, 0), System.Web.Caching.CacheItemPriority.Normal, null);
        }
        il = (IList)HttpContext.Current.Cache.Get(CacheName);
        if (il.Count > 0)
        {
            rpIsBindHot.DataSource = il;
            rpIsBindHot.DataBind();
        }
    }