Browse Source

Merge pull request #7 from NRKirby/small-fix

Use camel case method parameters
main
Steve Smith 9 years ago
committed by GitHub
parent
commit
52bd7bc932
  1. 8
      src/Web/Controllers/CatalogController.cs

8
src/Web/Controllers/CatalogController.cs

@ -29,18 +29,18 @@ namespace Microsoft.eShopWeb.Controllers
}
// GET: /<controller>/
public async Task<IActionResult> Index(int? BrandFilterApplied, int? TypesFilterApplied, int? page)
public async Task<IActionResult> Index(int? brandFilterApplied, int? typesFilterApplied, int? page)
{
var itemsPage = 10;
var catalog = await _catalogService.GetCatalogItems(page ?? 0, itemsPage, BrandFilterApplied, TypesFilterApplied);
var catalog = await _catalogService.GetCatalogItems(page ?? 0, itemsPage, brandFilterApplied, typesFilterApplied);
var vm = new CatalogIndex()
{
CatalogItems = catalog.Data,
Brands = await _catalogService.GetBrands(),
Types = await _catalogService.GetTypes(),
BrandFilterApplied = BrandFilterApplied ?? 0,
TypesFilterApplied = TypesFilterApplied ?? 0,
BrandFilterApplied = brandFilterApplied ?? 0,
TypesFilterApplied = typesFilterApplied ?? 0,
PaginationInfo = new PaginationInfo()
{
ActualPage = page ?? 0,

Loading…
Cancel
Save