Ejemplo n.º 1
0
 protected void UnFilter_Click(object sender, EventArgs e)
 {
     ControlClass.ResetControlValues(pnView);
     LoadFilterNewsNameAutocomplete();
     Common.PageHelper.LoadDropDownListFilterActive(ddlFilterActive);
     BindGrid();
 }
Ejemplo n.º 2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!IsPostBack)
     {
         dt = ConfigService.Config_GetByAll();
         if (dt.Rows.Count > 0)
         {
             Insert                = false;
             Id                    = dt.Rows[0]["Id"].ToString();
             txtMail_Smtp.Text     = dt.Rows[0]["Mail_Smtp"].ToString();
             txtMail_Port.Text     = dt.Rows[0]["Mail_Port"].ToString();
             txtMail_Info.Text     = dt.Rows[0]["Mail_Info"].ToString();
             txtMail_Password.Text = dt.Rows[0]["Mail_Password"].ToString();
             txtMail_Noreply.Text  = dt.Rows[0]["Mail_Noreply"].ToString();
             fckContent.Value      = dt.Rows[0]["Contact"].ToString();
             fckCopyright.Value    = dt.Rows[0]["Copyright"].ToString();
             txtTitle.Text         = dt.Rows[0]["Title"].ToString();
             txtDescription.Text   = dt.Rows[0]["Description"].ToString();
             txtKeyword.Text       = dt.Rows[0]["Keyword"].ToString();
         }
         else
         {
             Insert = true;
             ControlClass.ResetControlValues(this);
         }
     }
 }
Ejemplo n.º 3
0
 protected void btnThem_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     pnShow.Visible   = false;
     ControlClass.ResetControlValues(pnUpdate);
     Insert = true;
 }
Ejemplo n.º 4
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(pnUpdate);
     pnView.Visible = false;
     Insert         = true;
 }
Ejemplo n.º 5
0
 protected void lbtAddB_Click(object sender, EventArgs e)
 {
     txtUsername.ReadOnly = false;
     pnUpdate.Visible     = true;
     ControlClass.ResetControlValues(pnUpdate);
     pnView.Visible = false;
     _insert        = true;
 }
Ejemplo n.º 6
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(this);
     PageHelper.LoadDropDownListLanguage(ddlLanguage);
     pnView.Visible = false;
     Insert         = true;
 }
Ejemplo n.º 7
0
 protected void lbtAddB_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(pnUpdate);
     pnView.Visible = false;
     ViewFilm();
     _insert = true;
 }
Ejemplo n.º 8
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(this);
     LoadDropDownBoxProduct();
     pnView.Visible = false;
     Insert         = true;
 }
Ejemplo n.º 9
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     ltrPass.Text = "Mật Khẩu";
     ControlClass.ResetControlValues(this);
     txtDate.Text      = DateTimeClass.ConvertDateTime(DateTime.Now, "MM/dd/yyyy");
     pnUpdate.Visible  = true;
     chkActive.Checked = true;
     pnView.Visible    = false;
 }
Ejemplo n.º 10
0
		protected void AddButton_Click(object sender, EventArgs e)
		{
			pnUpdate.Visible = true;
			ControlClass.ResetControlValues(this);
			SqlDataProvider sql = new SqlDataProvider();
			txtOrd.Text = (Int16.Parse(sql.GetMaxOrd("GroupImage", Level)) + 1).ToString();
			pnView.Visible = false;
			Insert = true;
		}
Ejemplo n.º 11
0
 protected void UnFilter_Click(object sender, EventArgs e)
 {
     ControlClass.ResetControlValues(pnUpdate);
     LoadFilterCinemaDropDownList();
     LoadFilterFilmDropDownList();
     ViewCinema();
     ViewFilm();
     Common.PageHelper.LoadDropDownListFilterActive(ddlFilterActive);
     BindGrid();
 }
Ejemplo n.º 12
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(this);
     //LoadDropDownListPage();
     PageHelper.LoadDropDownListTarget(ddlTarget);
     PageHelper.LoadDropDownListPosition(ddlPosition);
     pnView.Visible = false;
     Insert         = true;
 }
Ejemplo n.º 13
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(this);
     LoadGroupNewsDropDownList();
     PageHelper.LoadDropDownListLanguage(ddlLanguage);
     txtDate.Text   = DateTimeClass.ConvertDateTime(DateTime.Now, "dd/MM/yyyy hh:mm:ss tt");
     pnView.Visible = false;
     Insert         = true;
 }
Ejemplo n.º 14
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(this);
     LoadDropDownListGroupProduct();
     LoadCheckBoxChude();
     pnView.Visible        = false;
     pnUpdatePrice.Visible = false;
     Insert = true;
     Id     = StringClass.RandomString(10);
 }
Ejemplo n.º 15
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(this);
     ddlPosition.SelectedValue = anh;
     chkActive.Checked         = true;
     pnView.Visible            = false;
     ddlPosition.Text          = "";
     //pathImage = "";
     imgImage.ImageUrl = "";
     //imgImagesamll.ImageUrl = "";
 }
Ejemplo n.º 16
0
 protected void AddButton_Click(object sender, EventArgs e)
 {
     pnUpdate.Visible = true;
     ControlClass.ResetControlValues(pnUpdate);
     txtName.Focus();
     txtOrd.Text = (Int16.Parse(sql.GetMaxOrd("Page", Level)) + 1).ToString();
     PageHelper.LoadDropDownListPagePosition(ddlPosition);
     PageHelper.LoadDropDownListTarget(ddlTarget);
     PageHelper.LoadDropDownListPageType(ddlType);
     PageHelper.LoadDropDownListLanguage(ddlLanguage);
     LoadDropDownListPageLinkType();
     LoadDropDownListPageLink();
     pnView.Visible = false;
     Insert         = true;
 }
Ejemplo n.º 17
0
        private void query()
        {
            if (Request.QueryString["add"] != null || Request.QueryString["subId"] != null)
            {
                ControlClass.ResetControlValues(this);
                txtMod_style.Text       = "";
                ddlParent.SelectedValue = "0";
                ddltype.SelectedValue   = "";
                pnUpdate.Visible        = true;
                chkStatus.Checked       = true;
            }
            if (Request.QueryString["subId"] != null)
            {
                txtSubId.Text           = Request.QueryString["subId"].ToString();
                ddlParent.SelectedValue = txtSubId.Text;
                ddlParent.Enabled       = false;
                txtLevel.Text           = tanglevel(txtSubId.Text);
                txtLevel.Enabled        = false;
            }
            if (Request.QueryString["editId"] != null)
            {
                txtId.Text = Request.QueryString["editId"].ToString();
                List <Data.Mod> listE = ModBUS.Mod_GetById(txtId.Text);
                txtMod_Name.Text  = listE[0].Mod_Name;
                txtMod_Code.Text  = listE[0].Mod_Code;
                chkHot.Checked    = listE[0].Mod_Hot == "1" || listE[0].Mod_Hot == "True";
                chkStatus.Checked = listE[0].Mod_Status == "1" || listE[0].Mod_Status == "True";
                chk_Same.Checked  = listE[0].Mod_Same == "1" || listE[0].Mod_Same == "True";

                if (chk_Same.Checked == true)
                {
                    txtMod_Tag.Visible = true;
                    txtMod_Tag.Text    = listE[0].Mod_Tag;
                }

                txtMod_Img.Text         = listE[0].Mod_Img;
                txtMod_Key.Text         = listE[0].Mod_Key;
                txtMod_Meta.Text        = listE[0].Mod_Meta;
                txtMod_Pos.Text         = listE[0].Mod_Pos;
                txtMod_style.Text       = listE[0].Mod_style;
                txtMod_Title.Text       = listE[0].Mod_Title;
                txtMod_Url.Text         = listE[0].Mod_Url;
                txtLevel.Text           = listE[0].Mod_Level;
                fckContentDetail.Text   = listE[0].Mod_Content;
                fckIntro.Text           = listE[0].Mod_Intro;
                ddlParent.SelectedValue = listE[0].Mod_Parent;
                ddltype.SelectedValue   = listE[0].Modtype_ID;
                txtLevel.Text           = listE[0].Mod_Level;
                pnUpdate.Visible        = true;
            }
            if (Request.QueryString["deleteId"] != null)
            {
                deleteId = Request.QueryString["deleteId"].ToString();
                sql.ExecuteNonQuery("Delete from [Mod]  Where Id='" + deleteId + "'");
                List <Data.Mod> list = ModBUS.Mod_GetByTop("", "Mod_Parent=" + deleteId + "", "");
                if (list.Count > 0)
                {
                    ModBUS.Mod_Delete(deleteId);
                    sql.ExecuteNonQuery("Delete from [Mod]  Where Mod_Parent='" + deleteId + "'");
                }
                Response.Redirect("/Admins/Mod.aspx");
            }

            if (Request.QueryString["activeId"] != null)
            {
                activeId = Request.QueryString["activeId"].ToString();
                List <Data.Mod> list = ModBUS.Mod_GetById(activeId);
                if (list.Count > 0)
                {
                    if (list[0].Mod_Status == "True")
                    {
                        sql.ExecuteNonQuery("Update [Mod] set Mod_Status='False'  Where Id=" + activeId + "");
                    }
                    else
                    {
                        sql.ExecuteNonQuery("Update [Mod] set Mod_Status='True'  Where Id=" + activeId + "");
                    }
                }
                Response.Redirect("/Admins/Mod.aspx");
            }
        }