Esempio n. 1
0
        public int RegisterTournamentBet(TournamentRegistrationModel register)
        {
            oCon.Open();

            oMySQLData.MySqlCommand cmd = new oMySQLData.MySqlCommand("sp_registerusertournamentbet", oCon);
            cmd.CommandType = System.Data.CommandType.StoredProcedure;

            oMySQLData.MySqlParameter userID       = new oMySQLData.MySqlParameter("userID", register.UserID);
            oMySQLData.MySqlParameter tournamentID = new oMySQLData.MySqlParameter("tournamentID", register.TournamentID);
            oMySQLData.MySqlParameter betPoints    = new oMySQLData.MySqlParameter("betPoints", register.TournamentPoints);

            cmd.Parameters.Add(userID);
            cmd.Parameters.Add(tournamentID);
            cmd.Parameters.Add(betPoints);

            int result = 0;

            result = cmd.ExecuteNonQuery();
            oCon.Close();

            return(result);
        }
Esempio n. 2
0
        public dynamic RegistertBet(TournamentRegistrationModel tournamentregister)
        {
            UserBetRepository _repo = new UserBetRepository();

            return(_repo.RegisterTournamentBet(tournamentregister));
        }