protected void Page_Load(object sender, EventArgs e) { if (!base.IsPostBack) { PubFunction.BindCustomFieldSelect(this._UserShopID, this.sltCustomField, true, 2); PubFunction.BindShopSelect(this._UserShopID, this.sltShop, this._UserShopID, this._UserShopID != 1); this.GetGoodsList(this.QueryCondition()); Chain.Model.SysShop modelShop = new Chain.BLL.SysShop().GetModel(this._UserShopID); int count = new Chain.BLL.SysShop().GetRecordCount("ShopID>0 and ShopType=3 and IsMain=0"); if (modelShop.IsMain && count > 0) { this.btnCopy.Visible = true; } else { this.btnCopy.Visible = false; } } }