예제 #1
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,PlayerRole,Price")] KolkataKnightRider kolkataKnightRider)
        {
            if (ModelState.IsValid)
            {
                _context.Add(kolkataKnightRider);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(kolkataKnightRider));
        }
예제 #2
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,PlayerRole,Price")] MumbaiIndian mumbaiIndian)
        {
            if (ModelState.IsValid)
            {
                _context.Add(mumbaiIndian);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(mumbaiIndian));
        }
예제 #3
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,PlayerRole,Price")] SunRisesHyderabad sunRisesHyderabad)
        {
            if (ModelState.IsValid)
            {
                _context.Add(sunRisesHyderabad);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(sunRisesHyderabad));
        }
예제 #4
0
        public async Task <IActionResult> Create([Bind("MatchId,Team1,Team2,Result")] Match match)
        {
            if (ModelState.IsValid)
            {
                _context.Add(match);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(match));
        }
예제 #5
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,Matches,Catches")] TopFielder topFielder)
        {
            if (ModelState.IsValid)
            {
                _context.Add(topFielder);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(topFielder));
        }
예제 #6
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,PlayerRole,Price")] KingsXipunjab kingsXipunjab)
        {
            if (ModelState.IsValid)
            {
                _context.Add(kingsXipunjab);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(kingsXipunjab));
        }
예제 #7
0
        public async Task <IActionResult> Create([Bind("TeamId,Teams,Matches,Won,Lost,Tied,Points,Nrr,Nrrposition")] PointsTable pointsTable)
        {
            if (ModelState.IsValid)
            {
                _context.Add(pointsTable);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(pointsTable));
        }
예제 #8
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,Innings,Runs")] TopBatsmen topBatsmen)
        {
            if (ModelState.IsValid)
            {
                _context.Add(topBatsmen);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(topBatsmen));
        }
예제 #9
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,PlayerRole,Price")] ChennaiSuperKing chennaiSuperKing)
        {
            if (ModelState.IsValid)
            {
                _context.Add(chennaiSuperKing);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(chennaiSuperKing));
        }
예제 #10
0
        public async Task <IActionResult> Create([Bind("PlayerId,Player,PlayerRole,Price")] RoyalChallengersBanglore royalChallengersBanglore)
        {
            if (ModelState.IsValid)
            {
                _context.Add(royalChallengersBanglore);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(royalChallengersBanglore));
        }