public IActionResult Display(int id) { var blog = _blogRepository.GetBlogById(id); _breadcrumbNavBuilder.CreateForNode("BlogDisplay", new { blogId = id, blogTitle = blog.Title.SetLengthLimit(40) }, this); return(View(blog)); }
public async Task <IActionResult> ManageCustomers() { Predicate <int> selectionCondition = roleNumber => roleNumber == 0; var userList = await GetUserList(selectionCondition); TempData["content"] = "customers"; _breadcrumbNavBuilder.CreateForNode("CPanelCustomersView", new { }, this); return(View("ManageUsers", userList)); }
private void PrepareNavData(int departmentId, string nodeName) { var dep = _departmentRepository.GetDepartmentById(departmentId); _breadcrumbNavBuilder.CreateForNode(nodeName, new { departmentId = dep.Id, departmentName = dep.Name } , this); }
private void PrepareNavData(int categoryId, string nodeName) { var cat = _categoryController.GetCategoryById(categoryId); var dep = _departmentRepository.GetDepartmentById(cat.DepartmentId); _breadcrumbNavBuilder.CreateForNode(nodeName, new { categoryId = cat.Id, categoryName = cat.Name, departmentId = dep.Id, departmentName = dep.Name } , this); }
private void PrepareNavData(int subcategoryId, string nodeName) { // prepare breadcrumb navigation data var subcat = _subcategoryRepository.GetSubcategoryById(subcategoryId); var cat = _categoryRepository.GetCategoryById(subcat.CategoryId); var dep = _departmentRepository.GetDepartmentById(cat.DepartmentId); _breadcrumbNavBuilder.CreateForNode(nodeName, new { subcategoryId = subcat.Id, subcategoryName = subcat.Name, categoryId = cat.Id, categoryName = cat.Name, departmentId = dep.Id, departmentName = dep.Name } , this); }
private void PrepareNavData(int productId, string nodeName) { var prod = _productRepository.GetProductWithItemsById(productId); var subcat = _subcategoryRepository.GetSubcategoryById(prod.SubcategoryId); var cat = _categoryRepository.GetCategoryById(subcat.CategoryId); var dep = _departmentRepository.GetDepartmentById(cat.DepartmentId); _breadcrumbNavBuilder.CreateForNode(nodeName, new { productId = prod.Id, productName = prod.Name.SetLengthLimit(50), subcategoryId = subcat.Id, subcategoryName = subcat.Name, categoryId = cat.Id, categoryName = cat.Name, departmentId = dep.Id, departmentName = dep.Name } , this); }
public IActionResult Index() { _breadcrumbNavBuilder.CreateForNode("ControlPanelIndex", new { }, this); return(View()); }