Beispiel #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            this.channel_id  = TWRequest.GetQueryInt("channel_id", 1);
            this.category_id = TWRequest.GetQueryInt("category_id");
            this.keywords    = TWRequest.GetQueryString("keywords");
            this.property    = TWRequest.GetQueryString("property");
            this.status      = TWRequest.GetQueryString("status");

            if (channel_id == 0)
            {
                JscriptMsg("頻道參數不正確!", "back");
                return;
            }
            statusSelect.Visible = true;

            this.channel_name = new BLL.channel().GetChannelName(this.channel_id); //取得頻道名稱
            this.pageSize     = GetPageSize(50);                                   //每頁數量
            this.prolistview  = Utils.GetCookie("vip_list_view");                  //顯示方式
            if (!Page.IsPostBack)
            {
                //ChkAdminLevel("channel_" + this.channel_name + "_list", TWEnums.ActionEnum.View.ToString()); //檢查權限
                TreeBind(this.channel_id); //綁定類別
                RptBind(this.channel_id, this.category_id, "id>0" + CombSqlTxt(this.keywords, this.property, this.status), "sort_id,add_time desc,id desc");
            }
        }
Beispiel #2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string _action = TWRequest.GetQueryString("action");

            if (!string.IsNullOrEmpty(_action) && _action == TWEnums.ActionEnum.Edit.ToString())
            {
                this.action = TWEnums.ActionEnum.Edit.ToString();//修改類型
                this.id     = TWRequest.GetQueryInt("id");
                if (this.id == 0)
                {
                    JscriptMsg("傳輸參數不正確!", "back");
                    return;
                }
                if (!new BLL.basic().Exists(this.id))
                {
                    JscriptMsg("資料不存在或已被刪除!", "back");
                    return;
                }
            }
            if (!Page.IsPostBack)
            {
                txtbasic_type.DataSource     = Tea.DBUtility.DbHelperSQL.Query("select * from shop_basic where basic_where='qu' order by basic_sort");
                txtbasic_type.DataTextField  = "basic_label";
                txtbasic_type.DataValueField = "basic_value";
                txtbasic_type.DataBind();
                //ChkAdminLevel("plugin_link", TWEnums.ActionEnum.View.ToString()); //檢查權限
                if (action == TWEnums.ActionEnum.Edit.ToString()) //修改
                {
                    ShowInfo(this.id);
                }
            }
        }
Beispiel #3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        tid = TWRequest.GetQueryInt("tid");
        id  = TWRequest.GetQueryInt("id");
        DataSet ds = Tea.DBUtility.DbHelperSQL.Query("select  * from shop_basic where basic_where='help' order by basic_sort");

        data_type.DataSource = ds;
        data_type.DataBind();
        if (tid == 0)
        {
            if (ds.Tables[0].Rows.Count > 0)
            {
                tid = Utils.StrToInt(ds.Tables[0].Rows[0]["basic_value"].ToString(), 0);
            }
        }
        if (tid > 0)
        {
            sql = "channel_id=1 and category_id=" + tid + " and status=0 and datediff(minute,add_time,getdate())>=0";
        }
        if (id > 0)
        {
            sql = "id=" + id + "";
        }
        data_list.DataSource = Tea.DBUtility.DbHelperSQL.Query("select * from shop_about where " + sql + "  order by sort_id desc,id desc");
        data_list.DataBind();
    }
Beispiel #4
0
    protected void Page_Load(object sender, EventArgs e)
    {
        ChkAdminLevelEdit("user_list", "Edit");
        this.channel_id  = TWRequest.GetQueryInt("channel_id");
        this.category_id = TWRequest.GetQueryInt("category_id");
        this.keywords    = TWRequest.GetQueryString("keywords");
        this.property    = TWRequest.GetQueryString("property");
        this.goods_ids   = TWRequest.GetQueryString("goods_ids");

        if (channel_id == 0)
        {
            JscriptMsg("頻道參數不正確!", "back", "Error");
            return;
        }
        this.channel_name = new Tea.BLL.channel().GetChannelName(this.channel_id); //取得頻道名稱
        this.pageSize     = GetPageSize(50);                                       //每頁數量
        if (!Page.IsPostBack)
        {
            TreeBind(this.channel_id); //綁定類別
            if (!string.IsNullOrEmpty(goods_ids))
            {
                RptBind(this.channel_id, this.category_id, "wheresql='tuan' and brand_id=1" + CombSqlTxt(this.keywords, this.property), "id desc");
            }
            else
            {
                RptBind(this.channel_id, this.category_id, "wheresql='tuan' and brand_id=1" + CombSqlTxt(this.keywords, this.property), "id desc");
            }
        }
    }
Beispiel #5
0
 protected void Page_Load(object sender, EventArgs e)
 {
     this.id = TWRequest.GetQueryInt("id");
     if (this.id == 0)
     {
         JscriptMsg("傳輸參數不正確!", "back");
         return;
     }
     if (!new BLL.orders().Exists(this.id))
     {
         JscriptMsg("記錄不存在或已被刪除!", "back");
         return;
     }
     if (!Page.IsPostBack)
     {
         BLL.express bll2 = new BLL.express();
         DataTable   dt   = bll2.GetList("").Tables[0];
         ddlExpressId.Items.Clear();
         ddlExpressId.Items.Add(new ListItem("請選擇配送方式", ""));
         foreach (DataRow dr in dt.Rows)
         {
             ddlExpressId.Items.Add(new ListItem(dr["title"].ToString(), dr["id"].ToString()));
         }
         //ChkAdminLevel("order_list", TWEnums.ActionEnum.View.ToString()); //檢查許可權
         ShowInfo(this.id);
     }
 }
Beispiel #6
0
    protected void Page_Load(object sender, EventArgs e)
    {
        id = TWRequest.GetQueryInt("id");
        Tea.BLL.orders bll = new Tea.BLL.orders();

        model = bll.GetModel(id);
        if (model.user_id != userModel.id)
        {
            Response.Redirect("order.aspx");
        }
        try
        {
            area = model.area.Split(',')[1].ToString();
            city = model.area.Split(',')[2].ToString();
        }
        catch (Exception eee) { }
        payModel = new Tea.BLL.payment().GetModel(model.payment_id);
        if (payModel == null)
        {
            payModel = new Tea.Model.payment();
        }

        data_cart.DataSource = Tea.DBUtility.DbHelperSQL.Query("select * from shop_order_goods where order_id=" + id + "");
        data_cart.DataBind();

        data_gift.DataSource = Tea.DBUtility.DbHelperSQL.Query("select * from view_order_gift where order_id=" + id + "");
        data_gift.DataBind();
    }
Beispiel #7
0
        protected void Page_Load(object sender, EventArgs e)
        {
            this.channel_id  = TWRequest.GetQueryInt("channel_id");
            this.category_id = TWRequest.GetQueryInt("category_id");
            this.keywords    = TWRequest.GetQueryString("keywords");
            this.property    = TWRequest.GetQueryString("property");
            this.goods_ids   = TWRequest.GetQueryString("goods_ids");

            if (channel_id == 0)
            {
                JscriptMsg("頻道參數不正確!", "back", "Error");
                return;
            }
            this.channel_name = new BLL.channel().GetChannelName(this.channel_id); //取得頻道名稱
            this.pageSize     = GetPageSize(50);                                   //每頁數量
            if (!Page.IsPostBack)
            {
                ////ChkAdminLevel("channel_" + this.channel_name + "_list", DTEnums.ActionEnum.View.ToString()); //檢查權限
                TreeBind(this.channel_id); //綁定類別
                if (!string.IsNullOrEmpty(goods_ids))
                {
                    RptBind(this.channel_id, this.category_id, "id not in(" + goods_ids + ") and brand_id in(1,2,3,5) and yu_lock<1" + CombSqlTxt(this.keywords, this.property), "id desc");
                }
                else
                {
                    RptBind(this.channel_id, this.category_id, "brand_id in(1,2,3,5) and yu_lock<1" + CombSqlTxt(this.keywords, this.property), "id desc");
                }
            }
        }
Beispiel #8
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string _action = TWRequest.GetQueryString("action");

            this.id = TWRequest.GetQueryInt("id");

            if (!string.IsNullOrEmpty(_action) && _action == TWEnums.ActionEnum.Edit.ToString())
            {
                this.action = TWEnums.ActionEnum.Edit.ToString();//修改類型
                if (this.id == 0)
                {
                    JscriptMsg("傳輸參數不正確!", "back");
                    return;
                }
                if (!new BLL.manager_role().Exists(this.id))
                {
                    JscriptMsg("角色不存在或已被刪除!", "back");
                    return;
                }
            }
            if (!Page.IsPostBack)
            {
                //ChkAdminLevel("manager_role", TWEnums.ActionEnum.View.ToString()); //檢查許可權
                RoleTypeBind();                                   //綁定角色類型
                NavBind();                                        //綁定導航
                if (action == TWEnums.ActionEnum.Edit.ToString()) //修改
                {
                    ShowInfo(this.id);
                }
            }
        }
Beispiel #9
0
        private void RptBind(string _strWhere, string _orderby)
        {
            this.page = TWRequest.GetQueryInt("page", 1);
            if (this.status > 0)
            {
                this.ddlStatus.SelectedValue = this.status.ToString();
            }
            if (this.payment_status > 0)
            {
                this.ddlPaymentStatus.SelectedValue = this.payment_status.ToString();
            }
            if (this.express_status > 0)
            {
                this.ddlExpressStatus.SelectedValue = this.express_status.ToString();
            }
            txtKeywords.Text      = this.keywords;
            txtdate.SelectedValue = data;
            txtbegin.Text         = begin;
            txtend.Text           = end;
            Tea.Web.UI.ShopPage bll = new UI.ShopPage();

            this.rptList.DataSource = bll.GetViewList("shop_orders", "", this.pageSize, this.page, _strWhere, _orderby, out this.totalCount);
            this.rptList.DataBind();

            //綁定頁碼
            txtPageNum.Text = this.pageSize.ToString();
            string pageUrl = Utils.CombUrlTxt("order_list.aspx", "status={0}&payment_status={1}&express_status={2}&keywords={3}&page={4}&cid={5}&data={6}&begin={7}&end={8}", this.status.ToString(), this.payment_status.ToString(), this.express_status.ToString(), this.keywords, "__id__", cid.ToString(), data, begin, end);

            PageContent.InnerHtml = Utils.OutPageList(this.pageSize, this.page, this.totalCount, pageUrl, 8);
        }
Beispiel #10
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string _action = TWRequest.GetQueryString("action");

            if (!string.IsNullOrEmpty(_action) && _action == TWEnums.ActionEnum.Edit.ToString())
            {
                this.action = TWEnums.ActionEnum.Edit.ToString();//修改類型
                this.id     = TWRequest.GetQueryInt("id");
                if (this.id == 0)
                {
                    JscriptMsg("傳輸參數不正確!", "back");
                    return;
                }
                if (!new BLL.basic().Exists(this.id))
                {
                    JscriptMsg("資料不存在或已被刪除!", "back");
                    return;
                }
            }
            if (!Page.IsPostBack)
            {
                //ChkAdminLevel("plugin_link", TWEnums.ActionEnum.View.ToString()); //檢查權限
                if (action == TWEnums.ActionEnum.Edit.ToString()) //修改
                {
                    ShowInfo(this.id);
                }
            }
        }
Beispiel #11
0
 protected void Page_Load(object sender, EventArgs e)
 {
     id = TWRequest.GetQueryInt("id", 1);
     if (id != 0)
     {
         model = bll.GetModel(id);
     }
 }
Beispiel #12
0
 protected void Page_Load(object sender, EventArgs e)
 {
     id = TWRequest.GetQueryInt("id");
     if (id != 0)
     {
         weburl = config.weburl;
         model  = bll.GetModel(id);
     }
 }
Beispiel #13
0
    protected void Page_Load(object sender, EventArgs e)
    {
        _users = new Tea.Web.UI.ShopPage().GetUserInfo();
        data_type.DataSource = Tea.DBUtility.DbHelperSQL.Query("select * from shop_article_category where channel_id=7 and call_index='1' order by sort_id desc");
        data_type.DataBind();

        key       = TWRequest.GetQueryString("key");
        this.page = TWRequest.GetQueryInt("page", 1);
        this.tid  = TWRequest.GetQueryInt("tid", 0);
        this.hid  = TWRequest.GetQueryInt("hid", 0);
        this.sort = TWRequest.GetQueryInt("sort", 0);


        if (sort == 1)
        {
            _orderby = "add_time desc,id desc";
        }
        if (sort == 2)
        {
            _orderby = "click desc";
        }
        if (sort == 3)
        {
            _orderby = "market_price,id";
        }
        if (sort == 4)
        {
            _orderby = "market_price desc,id";
        }
        if (tid != 0)
        {
            _sql  = _sql + " and (category_id=" + tid + " or more_type like'%," + tid + ",%')";
            tname = new Tea.BLL.article_category().GetTitle(tid);
            try
            {
                Tea.Model.article_category model = new Tea.BLL.article_category().GetModel(tid);
                title    = model.seo_title;
                keyword  = model.seo_keywords;
                describe = model.seo_description;
            }
            catch (Exception eee) { }
        }
        if (!string.IsNullOrEmpty(key))
        {
            _sql  = _sql + " and title like'%" + key + "%'";
            tname = key;
        }
        Tea.Web.UI.ShopPage bll_view = new Tea.Web.UI.ShopPage();

        data_list.DataSource = bll_view.GetViewList("view_article_product", "", this.pageSize, this.page, _sql, _orderby, out this.totalCount);
        data_list.DataBind();

        string pageUrl = Utils.CombUrlTxt("index.aspx", "tid={0}&key={1}&sort={2}&page={3}", tid.ToString(), key.ToString(), sort.ToString(), "__id__");

        PageContent.InnerHtml = Utils.OutPageListWeb(this.pageSize, this.page, this.totalCount, pageUrl, 8);
    }
Beispiel #14
0
        private void RptBind(int _channel_id, int _category_id, string _strWhere, string _orderby)
        {
            this.page = TWRequest.GetQueryInt("page", 1);
            if (this.category_id > 0)
            {
                this.ddlCategoryId.SelectedValue = _category_id.ToString();
            }
            this.ddlProperty.SelectedValue = this.property;
            this.txtKeywords.Text          = this.keywords;
            if (this.brand_id > 0)
            {
                this.ddlBrandId.SelectedValue = this.brand_id.ToString();
            }
            if (sort > 0)
            {
                this.ddlSort.SelectedValue = this.sort.ToString();

                if (sort == 1)
                {
                    _orderby = "begin_time";
                }
                if (sort == 2)
                {
                    _orderby = "add_time";
                }
                if (sort == 3)
                {
                    _orderby = "id";
                }
            }
            //圖表或清單顯示

            Tea.Web.UI.ShopPage bll = new UI.ShopPage();

            switch (this.prolistview)
            {
            case "Txt":
                this.rptList2.Visible    = false;
                this.rptList1.DataSource = bll.GetViewList("view_article_product", "", this.pageSize, this.page, _strWhere, _orderby, out this.totalCount);
                this.rptList1.DataBind();
                break;

            default:
                this.rptList1.Visible    = false;
                this.rptList2.DataSource = bll.GetViewList("view_article_product", "", this.pageSize, this.page, _strWhere, _orderby, out this.totalCount);
                this.rptList2.DataBind();
                break;
            }
            //綁定頁碼
            txtPageNum.Text = this.pageSize.ToString();
            string pageUrl = Utils.CombUrlTxt("tuan_list.aspx", "channel_id={0}&category_id={1}&keywords={2}&property={3}&brand_id={4}&page={5}&status={6}", _channel_id.ToString(), _category_id.ToString(), this.keywords, this.property, this.brand_id.ToString(), "__id__", status.ToString());

            PageContent.InnerHtml = Utils.OutPageList(this.pageSize, this.page, this.totalCount, pageUrl, 8);
        }
Beispiel #15
0
        protected void bu_no_Click(object sender, EventArgs e)
        {
            id = TWRequest.GetQueryInt("id");
            ChkAdminLevelEdit("order_list", "Edit");
            string order_bao = chang.Text.Trim() + "|" + kuan.Text.Trim() + "|" + gao.Text.Trim() + "|" + txtzhong.Text.Trim();

            new Tea.BLL.orders().UpdateField(id, "express_no='" + express_no.Text.Trim() + "',order_bao='" + order_bao + "',express_id=" + ddlExpressId.SelectedValue + "");

            Response.Write(ljd.function.LocalHint("成功送出", "order_edit.aspx?action=Edit&id=" + id));
            Response.End();
        }
Beispiel #16
0
 protected void Page_Load(object sender, EventArgs e)
 {
     id = TWRequest.GetQueryInt("id");
     if (id != 0)
     {
         weburl = config.weburl;
         weburl = Utils.DelLastChar(weburl, "/");
         model  = bll.GetModel(id);
         data_cart.DataSource = Tea.DBUtility.DbHelperSQL.Query("select * from shop_order_goods where order_id=" + id + "");
         data_cart.DataBind();
     }
 }
Beispiel #17
0
        private void RptBind(string _strWhere, string _orderby)
        {
            this.page             = TWRequest.GetQueryInt("page", 1);
            this.txtKeywords.Text = this.keywords;
            BLL.basic bll = new BLL.basic();
            this.rptList.DataSource = bll.GetList(this.pageSize, this.page, _strWhere, _orderby, out this.totalCount);
            this.rptList.DataBind();
            //綁定頁碼
            txtPageNum.Text = this.pageSize.ToString();
            string pageUrl = Utils.CombUrlTxt("list.aspx", "keywords={0}&page={1}", this.keywords, "__id__");

            PageContent.InnerHtml = Utils.OutPageList(this.pageSize, this.page, this.totalCount, pageUrl, 8);
        }
Beispiel #18
0
 protected void Page_Load(object sender, EventArgs e)
 {
     this.keywords = TWRequest.GetQueryString("keywords");
     Status        = TWRequest.GetQueryInt("Status", -1);
     this.data     = TWRequest.GetQueryString("data");
     this.begin    = TWRequest.GetQueryString("begin");
     this.end      = TWRequest.GetQueryString("end");
     this.pageSize = GetPageSize(50); //每頁數量
     if (!Page.IsPostBack)
     {
         //ChkAdminLevel("plugin_feedback", TWEnums.ActionEnum.View.ToString()); //檢查權限
         RptBind("id>0" + CombSqlTxt(this.keywords, Status, data, begin, end), "add_time desc");
     }
 }
Beispiel #19
0
    protected void Page_Load(object sender, EventArgs e)
    {
        id = TWRequest.GetQueryInt("id");
        if (id != 0)
        {
            model    = bll.GetModel(id);
            title    = model.seo_title;
            keyword  = model.seo_keywords;
            describe = model.seo_description;
            bll.UpdateField(id, "click=click+1");
        }

        data_news.DataSource = new Tea.BLL.basic().GetList(0, "basic_where='news'", "basic_sort");
        data_news.DataBind();
    }
Beispiel #20
0
 protected void Page_Load(object sender, EventArgs e)
 {
     id   = TWRequest.GetQueryInt("id");
     code = TWRequest.GetQueryString("code");
     Tea.Model.users model = bll.GetModel(id);
     if (model.password != code)
     {
         Response.Write(ljd.function.LocalHint("郵箱驗證失敗,請重新驗證", "reg.aspx"));
     }
     else
     {
         model.status = 0;
         bll.Update(model);
     }
 }
Beispiel #21
0
        protected string channel_name = string.Empty; //頻道名稱

        protected void Page_Load(object sender, EventArgs e)
        {
            this.channel_id   = TWRequest.GetQueryInt("channel_id");
            this.channel_name = new BLL.channel().GetChannelName(this.channel_id); //取得頻道名稱
            if (this.channel_id == 0)
            {
                JscriptMsg("頻道參數不正確!", "back");
                return;
            }
            if (!Page.IsPostBack)
            {
                //ChkAdminLevel("channel_" + this.channel_name + "_category", TWEnums.ActionEnum.View.ToString()); //檢查許可權
                RptBind();
            }
        }
Beispiel #22
0
        private void RptBind(string _strWhere, string _orderby)
        {
            this.page        = TWRequest.GetQueryInt("page", 1);
            txtKeywords.Text = this.keywords;

            Tea.Web.UI.ShopPage bll_view = new Tea.Web.UI.ShopPage();
            rptList.DataSource = bll_view.GetViewList("shop_quan", "", this.pageSize, this.page, _strWhere, _orderby, out this.totalCount);
            rptList.DataBind();


            //綁定頁碼
            txtPageNum.Text = this.pageSize.ToString();
            string pageUrl = Utils.CombUrlTxt("user_list.aspx", "keywords={0}&page={1}", this.keywords, "__id__");

            PageContent.InnerHtml = Utils.OutPageList(this.pageSize, this.page, this.totalCount, pageUrl, 8);
        }
Beispiel #23
0
        private void RptBind()
        {
            this.page = TWRequest.GetQueryInt("page", 1);
            //Response.Write(begin+"-"+end);
            if (!string.IsNullOrEmpty(begin))
            {
                ddlYear.SelectedValue = begin;
            }
            if (!string.IsNullOrEmpty(end))
            {
                ddlMonth.SelectedValue = end;
            }

            this.rptList.DataSource = Tea.DBUtility.DbHelperSQL.Query("select * from shop_basic where basic_where='city' and basic_label!='台灣'");
            this.rptList.DataBind();
        }
Beispiel #24
0
        protected void bu_submit_Click(object sender, EventArgs e)
        {
            id = TWRequest.GetQueryInt("id");
            ChkAdminLevelEdit("order_list", "Edit");
            int invoice_taxes = 0;

            if (cbFaPiao.Checked)
            {
                invoice_taxes = 1;
            }


            new Tea.BLL.orders().UpdateField(id, "trade_no='" + trade_no.Text.Trim() + "',invoice_taxes=" + invoice_taxes + "");

            Response.Write(ljd.function.LocalHint("成功送出", "order_edit.aspx?action=Edit&id=" + id));
            Response.End();
        }
Beispiel #25
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string _action = TWRequest.GetQueryString("action");

            if (!string.IsNullOrEmpty(_action) && _action == TWEnums.ActionEnum.Edit.ToString())
            {
                this.action = TWEnums.ActionEnum.Edit.ToString();//修改類型
                this.id     = TWRequest.GetQueryInt("id");
                if (this.id == 0)
                {
                    JscriptMsg("傳輸參數不正確!", "back");
                    return;
                }
                if (!new BLL.gift().Exists(this.id))
                {
                    JscriptMsg("記錄不存在或已被刪除!", "back");
                    return;
                }
            }
            if (!Page.IsPostBack)
            {
                for (int i = 1; i <= 12; i++)
                {
                    if (i < 10)
                    {
                        ddlMonth.Items.Add(new ListItem("0" + i.ToString(), "0" + i.ToString()));
                    }
                    else
                    {
                        ddlMonth.Items.Add(new ListItem(i.ToString(), i.ToString()));
                    }
                }
                int year = System.DateTime.Now.Year;
                for (int i = 2018; i <= year + 1; i++)
                {
                    ddlYear.Items.Add(new ListItem(i.ToString(), i.ToString()));
                }
                //ChkAdminLevel("goods_gift", TWEnums.ActionEnum.View.ToString()); //檢查權限


                if (action == TWEnums.ActionEnum.Edit.ToString()) //修改
                {
                    ShowInfo(this.id);
                }
            }
        }
Beispiel #26
0
    protected void Page_Load(object sender, EventArgs e)
    {
        key       = TWRequest.GetQueryString("key");
        this.page = TWRequest.GetQueryInt("page", 1);

        _sql = _sql + " and quan_where='zhe'";
        Tea.BLL.article bll = new Tea.BLL.article();

        Tea.Web.UI.ShopPage bll_view = new Tea.Web.UI.ShopPage();

        data_list.DataSource = bll_view.GetViewList("shop_quan", "", this.pageSize, this.page, _sql, _orderby, out this.totalCount);
        data_list.DataBind();

        string pageUrl = Utils.CombUrlTxt("quan.aspx", "key={0}&page={1}", key.ToString(), "__id__");

        PageContent.InnerHtml = Utils.OutPageListWeb(this.pageSize, this.page, this.totalCount, pageUrl, 8);
    }
Beispiel #27
0
        protected void Page_Load(object sender, EventArgs e)
        {
            string _action = TWRequest.GetQueryString("action");

            this.channel_id = TWRequest.GetQueryInt("channel_id");
            this.id         = TWRequest.GetQueryInt("id");

            if (this.channel_id == 0)
            {
                JscriptMsg("頻道參數不正確!", "back");
                return;
            }
            this.channel_name = new BLL.channel().GetChannelName(this.channel_id); //取得頻道名稱
            if (!string.IsNullOrEmpty(_action) && _action == TWEnums.ActionEnum.Edit.ToString())
            {
                this.action = TWEnums.ActionEnum.Edit.ToString();//修改類型
                if (this.id == 0)
                {
                    JscriptMsg("傳輸參數不正確!", "back");
                    return;
                }
                if (!new BLL.article_category().Exists(this.id))
                {
                    JscriptMsg("類別不存在或已被刪除!", "back");
                    return;
                }
            }
            if (!Page.IsPostBack)
            {
                //ChkAdminLevel("channel_" + this.channel_name + "_category", TWEnums.ActionEnum.View.ToString()); //檢查許可權
                TreeBind(this.channel_id);                        //綁定類別
                if (action == TWEnums.ActionEnum.Edit.ToString()) //修改
                {
                    ShowInfo(this.id);
                }
                else
                {
                    if (this.id > 0)
                    {
                        this.ddlParentId.SelectedValue = this.id.ToString();
                    }
                }
            }
        }
Beispiel #28
0
 protected void Page_Load(object sender, EventArgs e)
 {
     this.id = TWRequest.GetQueryInt("id");
     if (this.id == 0)
     {
         JscriptMsg("傳輸參數不正確!", "back");
         return;
     }
     if (!new BLL.payment().Exists(this.id))
     {
         JscriptMsg("付款方式不存在或已刪除!", "back");
         return;
     }
     if (!Page.IsPostBack)
     {
         //ChkAdminLevel("order_payment", TWEnums.ActionEnum.View.ToString()); //檢查許可權
         ShowInfo(this.id);
     }
 }
Beispiel #29
0
        private void RptBind(int _channel_id, int _category_id, string _strWhere, string _orderby)
        {
            this.page = TWRequest.GetQueryInt("page", 1);
            if (this.category_id > 0)
            {
                this.ddlCategoryId.SelectedValue = _category_id.ToString();
            }
            this.txtKeywords.Text = this.keywords;
            //圖表或列表顯示
            Tea.Web.UI.ShopPage bll_view = new Tea.Web.UI.ShopPage();
            this.rptList1.DataSource = bll_view.GetViewList("view_goods", "", this.pageSize, this.page, _strWhere, _orderby, out this.totalCount);
            this.rptList1.DataBind();
            //綁定頁碼
            txtPageNum.Text = this.pageSize.ToString();
            string pageUrl = Utils.CombUrlTxt("dialog_group.aspx", "channel_id={0}&category_id={1}&keywords={2}&page={3}&goods_ids={4}",
                                              _channel_id.ToString(), _category_id.ToString(), this.keywords, "__id__", this.goods_ids);

            PageContent.InnerHtml = Utils.OutPageList(this.pageSize, this.page, this.totalCount, pageUrl, 8);
        }
Beispiel #30
0
        //頁面載入事件
        protected void Page_Load(object sender, EventArgs e)
        {
            string _action = TWRequest.GetQueryString("action");

            url = TWRequest.GetQueryString("url");
            if (this.channel_id == 0)
            {
                JscriptMsg("頻道參數不正確!", "back");
                return;
            }
            this.channel_name = new BLL.channel().GetChannelName(this.channel_id); //取得頻道名稱

            //如果是編輯或複製則檢查資料是否存在
            if (_action == TWEnums.ActionEnum.Edit.ToString() || _action == TWEnums.ActionEnum.Copy.ToString())
            {
                this.action = _action;//修改類型
                this.id     = TWRequest.GetQueryInt("id");
                if (this.id == 0)
                {
                    JscriptMsg("傳輸參數不正確!", "back");
                    return;
                }
                if (!new BLL.article().Exists(this.id))
                {
                    JscriptMsg("資訊不存在或已被刪除!", "back");
                    return;
                }
            }
            if (!Page.IsPostBack)
            {
                txtAddTime.Text = System.DateTime.Now.ToString("yyyy-MM-dd");
                //ChkAdminLevel("channel_" + this.channel_name + "_list", TWEnums.ActionEnum.View.ToString()); //檢查許可權

                GroupBind("1=2");          //綁定用戶組
                TreeBind(this.channel_id); //綁定類別


                if (action == TWEnums.ActionEnum.Edit.ToString()) //修改
                {
                    ShowInfo(this.id);
                }
            }
        }