Esempio n. 1
0
    protected void btnDeletet_Click(object sender, EventArgs e)
    {
        Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID, cnKey);
        Js.BLL.Sys.SysComDal sdal = new Js.BLL.Sys.SysComDal(cnKey);
        // Js.BLL.Sys.SysComDal sdal = new Js.BLL.Sys.SysComDal();
        int iReturn = 0;
        for (int i = 0; i < this.GridView1.Rows.Count; i++)
        {
            CheckBox cb = (CheckBox)(this.GridView1.Rows[i].FindControl("cbSelect"));
            if (cb.Checked)
            {
                HyperLink hk = (HyperLink)(this.GridView1.Rows[i].FindControl("HyperLink1"));
                iReturn = sdal.GetBillCanBeEdit(FormID, hk.Text);// "EnterpriseID='" + Session["EnterpriseID"].ToString() + "'");

                if (iReturn == 1)
                    JScript.Instance.ShowMessage(this.updatePanel, hk.Text + Resources.Resource.NotDelete_Checked);
                else if (iReturn == 2)
                    JScript.Instance.ShowMessage(this.updatePanel, hk.Text + Resources.Resource.NotDelete_IsUsed);
                else
                {
                    dal.Delete(hk.Text);//, "EnterpriseID='" + Session["EnterpriseID"].ToString() + "'");
                    dal.DeleteDetail(hk.Text);
                }
            }
        }
        SetBtnEnabled("");
    }
    protected void btnDelete_Click(object sender, EventArgs e)
    {
        Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID);
        string strID = this.ddlRoleID.SelectedValue;
        dal.Delete(strID);

        btnNext_Click(sender, e);
        if (this.ddlRoleID.SelectedValue == strID)
            btnPre_Click(sender, e);
    }
Esempio n. 3
0
    protected void btnDelete_Click(object sender, EventArgs e)
    {
        Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID);
        string strID = this.txtEnterpriseID.Text;
        dal.Delete(strID);

        btnNext_Click(sender, e);
        if (this.txtEnterpriseID.Text == strID)
            btnPre_Click(sender, e);
    }
Esempio n. 4
0
 protected void btnDelete_Click(object sender, EventArgs e)
 {
     Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID, cnKey);
     //Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID);
     string strID = this.txtPersonID.Text;
        // dal.Delete(strID);
     dal.Delete(strID, "EnterpriseID='" + this.txtEnterpriseID.Text + "'");
     btnNext_Click(sender, e);
     if (this.txtPersonID.Text == strID)
         btnPre_Click(sender, e);
 }
Esempio n. 5
0
    protected void btnDelete_Click(object sender, EventArgs e)
    {
        Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID, cnKey);
        //Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID);
        string strID = this.txtStyleID.Text;
        dal.Delete(strID);
        Js.BLL.Label.StyleDal sdal = new Js.BLL.Label.StyleDal(cnKey);
        sdal.DeleteWarehousePagesByStyleID(strID);

        btnNext_Click(sender, e);
        if (this.txtStyleID.Text == strID)
            btnPre_Click(sender, e);
    }
Esempio n. 6
0
 protected void btnDelete_Click(object sender, EventArgs e)
 {
     Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID, cnKey);
     //Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID);
     string strID = this.txtBillID.Text;
     dal.Delete(strID);//, "EnterpriseID='" + this.txtEnterpriseID.Text + "'");
     dal.DeleteDetail(strID);
     btnNext_Click(sender, e);
     if (this.txtBillID.Text == strID)
         btnPre_Click(sender, e);
     if (this.txtBillID.Text == strID)
         Response.Redirect("Orders.aspx?FormID=" + Server.UrlEncode(FormID));
 }
Esempio n. 7
0
 protected void btnDeletet_Click(object sender, EventArgs e)
 {
     Js.BLL.BaseDal dal = new Js.BLL.BaseDal(FormID, cnKey);
     for (int i = 0; i < this.GridView1.Rows.Count; i++)
     {
         CheckBox cb = (CheckBox)(this.GridView1.Rows[i].FindControl("cbSelect"));
         if (cb.Checked)
         {
             HyperLink hk = (HyperLink)(this.GridView1.Rows[i].FindControl("HyperLink1"));
             dal.Delete(hk.Text);
         }
     }
     SetBtnEnabled("");
 }