using System; using System.Collections; using System.Configuration; using System.Data; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using DSWeb.EntityDA; using DSWeb.Models; namespace DSWeb.PriceCarrier { public partial class ClientChangePassword : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { } } protected void btLogin_Click(object sender, EventArgs e) { if (tbLOGINNAME.Text.Trim().Equals("") || tbLOGINPASSWORD.Text.Trim().Equals("") || tbLPWNEW.Text.Trim().Equals("") || tbLPWACK.Text.Trim().Equals("")) { Response.Write(""); return; } // T_ALL_DA T_ALL_DA = new T_ALL_DA(); DataSet ds = T_ALL_DA.GetAllSQL("select * from [info_client] where 1=1 and LOGINNAME='" + tbLOGINNAME.Text.Trim() + "' and LOGINPASSWORD='" + tbLOGINPASSWORD.Text.Trim() + "'"); if (ds != null) { if (ds.Tables[0].Rows[0]["ISSTOP"].ToString().Trim().Equals("1")) { Response.Write(""); return; } else { bool bl = T_ALL_DA.GetExecuteSqlCommand("update [info_client] set LOGINNAME='" + tbLPWNEW.Text.Trim() + "',LOGINPASSWORD='" + tbLPWACK.Text.Trim() + "' where GID='" + ds.Tables[0].Rows[0]["GID"].ToString().Trim() + "' and ISSTOP=0"); if (bl) { Response.Write(""); return; } else { Response.Write(""); return; } } } else { Response.Write(""); return; } } } }