コード例 #1
0
        private void Get_ParameterList(string strSql)
        {
            Chain.BLL.GoodsAllot BLLAllot = new Chain.BLL.GoodsAllot();
            int Counts = this.NetPagerParameter.RecordCount;

            strSql += " and GoodsAllot.AllotOutShopID > 0";
            object obj = strSql;

            strSql = string.Concat(new object[]
            {
                obj,
                " and (GoodsAllot.AllotOutShopID=",
                this._UserShopID,
                " or  GoodsAllot.AllotInShopID=",
                this._UserShopID,
                ")"
            });
            strSql += " and  GoodsAllot.AllotOutShopID = SysShop.ShopID and GoodsAllot.AllotUserID = SysUser.UserID";
            DataTable db = BLLAllot.GetListSP(this.NetPagerParameter.PageSize, this.NetPagerParameter.CurrentPageIndex, out Counts, new string[]
            {
                strSql
            }).Tables[0];

            this.NetPagerParameter.RecordCount    = Counts;
            this.NetPagerParameter.CustomInfoHTML = string.Format("<div class=\"results\"><span>当前第{0}/{1}页 共{2}条记录 每页{3}条</span></div>", new object[]
            {
                this.NetPagerParameter.CurrentPageIndex,
                this.NetPagerParameter.PageCount,
                this.NetPagerParameter.RecordCount,
                this.NetPagerParameter.PageSize
            });
            this.rptGoodsLog.DataSource = db;
            this.rptGoodsLog.DataBind();
            PageBase.BindSerialRepeater(this.rptGoodsLog, this.NetPagerParameter.PageSize * (this.NetPagerParameter.CurrentPageIndex - 1));
        }
コード例 #2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!base.IsPostBack)
     {
         PubFunction.BindShopSelect(1, this.sltOutShopID, true);
         this.sltOutShopID.Value = this._UserShopID.ToString();
         PubFunction.BindShopSelect(this._UserShopID, this.sltInShopID, true);
         this.lblUSer.InnerText         = this._UserName;
         this.spGoodsAccounte.InnerText = this.curParameter.strGoodsAllotPrefix + DateTime.Now.ToString("yyMMddHHmmssffff");
         this.txtCreateTime.Value       = DateTime.Now.ToString();
         if (base.Request.QueryString["Type"] != null)
         {
             int type = Convert.ToInt32(base.Request.QueryString["Type"]);
             if (type == 1)
             {
                 this.sltInShopID.Value = this._UserShopID.ToString();
                 this.sltInShopID.Attributes.Add("disabled", "disabled");
             }
             if (type == 2)
             {
                 this.sltOutShopID.Value = this._UserShopID.ToString();
                 this.sltOutShopID.Attributes.Add("disabled", "disabled");
             }
         }
         if (base.Request.QueryString["AllotID"] != null)
         {
             int AllotID = Convert.ToInt32(base.Request.QueryString["AllotID"]);
             Chain.Model.GoodsAllot modelAllot = new Chain.BLL.GoodsAllot().GetModel(AllotID);
             this.spGoodsAccounte.InnerText = modelAllot.AllotAccount;
             this.txtExRemark.Value         = modelAllot.AllotRemark;
             this.HidAllotID.Value          = AllotID.ToString();
             this.HidExit.Value             = "2";
             this.sltOutShopID.Value        = modelAllot.AllotOutShopID.ToString();
             this.sltOutShopID.Attributes.Add("disabled", "disabled");
             this.sltInShopID.Value = modelAllot.AllotInShopID.ToString();
             this.sltInShopID.Attributes.Add("disabled", "disabled");
         }
     }
 }