public DataTable GetLogin(frmLoginModel model) { try { DbCommand dbcommand = database.GetStoredPocCommand("SP_GetLogin"); database.AddInParameter(dbcommand, "@Password", DbType.String, model.Password); dt = database.ExecuteDataTable(dbcommand); return(dt); } catch (Exception) { throw; } }
public int InsertLogDetails(frmLoginModel model) { try { DbCommand dbcommand = database.GetStoredPocCommand("SP_InsertLogDetails"); database.AddInParameter(dbcommand, "@Password", DbType.String, model.Password); database.AddInParameter(dbcommand, "@Status", DbType.String, model.Status); database.AddInParameter(dbcommand, "@UserName", DbType.String, model.UserName); result = Convert.ToInt32(database.ExecuteScalar(dbcommand)); return(result); } catch (Exception) { throw; } }