Esempio n. 1
0
        private void MyBind()
        {
            M_UserInfo mu = buser.GetLogin();

            Tlp_DP.DataSource = mbBll.GetTlpDT();
            Tlp_DP.DataBind();
            Tlp_DP.Enabled = false;
            if (Mid > 0)
            {
                M_Design_MBSite mbMod = mbBll.SelReturnModel(Mid);
                if (mbMod.UserID != mu.UserID)
                {
                    function.WriteErrMsg("你无权管理该微站");
                }
                SiteName_T.Text      = mbMod.SiteName;
                SiteImg_Hid.Value    = mbMod.SiteImg;
                Tlp_DP.SelectedValue = mbMod.TlpID.ToString();
                if (!string.IsNullOrEmpty(mbMod.SiteImg))
                {
                    siteimg.Src = mbMod.SiteImg;
                }
                Head_L.Text = Title_L.Text = "修改微站";
            }
            else//新建
            {
                //取消数量限制
                //int mbcount = mbBll.GetSiteCount(mu.UserID);
                //if (mbcount >= SiteConfig.SiteOption.DN_MBSiteCount)
                //{
                //    function.Script(this, "NoMoreSite('你已经拥有了" + mbcount + "个微站,不能再继续创建');");
                //    Save_Btn.Visible = false;
                //}
                M_Design_MBSite mbMod = mbBll.SelModelByTlpID(mu.UserID, TlpID);
                if (mbMod != null)
                {
                    Response.Redirect("/design/mobile/default.aspx?id=" + mbMod.ID);
                }
                Tlp_DP.SelectedValue = TlpID.ToString();
                Head_L.Text          = Title_L.Text = "新建微站";
            }
        }
Esempio n. 2
0
        public void MyBind()
        {
            DataTable tlps = tlpBll.Sel();

            Tlp_DP.DataSource     = tlps;
            Tlp_DP.DataTextField  = "Alias";
            Tlp_DP.DataValueField = "ID";
            Tlp_DP.DataBind();

            DataTable orders = orderBll.Sel();

            Order_DP.DataSource     = orders;
            Order_DP.DataTextField  = "ID";
            Order_DP.DataValueField = "ID";
            Order_DP.DataBind();

            DataTable devs = devBll.Sel();

            RPT.DataSource = devs;
            RPT.DataBind();
        }