//new services added for web #region WebAppServices public TransactionStatus ChangePassword(ConsumerChangePasswordBo changepasswordBo) { var transactionStatus = new TransactionStatus(); var consumer = BuiltChangePasswordDomain(changepasswordBo); CemexDb con = new CemexDb(); SqlParameter[] Params = { new SqlParameter("@opReturnValue", SqlDbType.Int), //0 new SqlParameter("@Cons_Id", consumer.Cons_Id), //23 new SqlParameter("@Cons_Pswd", consumer.Curnt_Pswd), //19 new SqlParameter("@New_Pswd", consumer.NewPassword) //23 }; Params[0].Direction = ParameterDirection.Output; //string conStr = ConfigurationManager.ConnectionStrings["conCityOfLongBeach"].ToString(); DataSet ds = SqlHelper.ExecuteDataset(con.GetConnection(), CommandType.StoredProcedure, "proc_Consumer_ChangePassword", Params); ds.Locale = CultureInfo.InvariantCulture; int IsChange = Convert.ToInt32(Params[0].Value); if (IsChange == 1) { transactionStatus.Status = true; } else { transactionStatus.Status = false; } return(transactionStatus); }
private ConsumerChangePassword BuiltChangePasswordDomain(ConsumerChangePasswordBo changepwdBo) { return((ConsumerChangePassword) new ConsumerChangePassword().InjectFrom(changepwdBo)); }