45 lines
1.1 KiB
C#
45 lines
1.1 KiB
C#
using Humanizer;
|
|
using Microsoft.AspNetCore.Mvc;
|
|
using Microsoft.AspNetCore.Mvc.RazorPages;
|
|
//using Microsoft.EntityFrameworkCore;
|
|
using MTG_CollectionVerwaltung.Data.MTGCollection;
|
|
using MTG_CollectionVerwaltung.Helpers;
|
|
//using static Microsoft.EntityFrameworkCore.DbLoggerCategory;
|
|
using static System.Net.WebRequestMethods;
|
|
|
|
namespace MTG_CollectionVerwaltung.Pages
|
|
{
|
|
public class IndexModel : PageModel
|
|
{
|
|
private readonly ILogger<IndexModel> _logger;
|
|
|
|
private readonly MTGContext _context;
|
|
|
|
public IndexModel(ILogger<IndexModel> logger, MTGContext mTGContext)
|
|
{
|
|
_logger = logger;
|
|
_context = mTGContext;
|
|
}
|
|
|
|
public void OnGet()
|
|
{
|
|
|
|
}
|
|
|
|
public IActionResult OnPostDecks(string searchInput)
|
|
{
|
|
return Page();
|
|
}
|
|
|
|
public IActionResult OnPostCards(string searchInput)
|
|
{
|
|
//var cards = CardSearcher.SearchCards(_context, searchInput);
|
|
|
|
return RedirectToPage("/Cards/Search", new { Searchquerry = searchInput });
|
|
}
|
|
|
|
|
|
|
|
}
|
|
}
|