Fix admin route access and backend configuration
- Added /admin redirect to login page in nginx config - Fixed backend server.js route ordering for proper admin handling - Updated authentication middleware and routes - Added user management routes - Configured PostgreSQL integration - Updated environment configuration
This commit is contained in:
41
Sky_Art_shop/Views/Portfolio/Category.cshtml
Normal file
41
Sky_Art_shop/Views/Portfolio/Category.cshtml
Normal file
@@ -0,0 +1,41 @@
|
||||
@model List<SkyArtShop.Models.PortfolioProject>
|
||||
@{
|
||||
var category = ViewBag.Category as SkyArtShop.Models.PortfolioCategory;
|
||||
ViewData["Title"] = category?.Name ?? "Portfolio";
|
||||
}
|
||||
|
||||
<section class="portfolio-hero">
|
||||
<div class="container">
|
||||
<h1>@(category?.Name ?? "Portfolio")</h1>
|
||||
@if (!string.IsNullOrEmpty(category?.Description))
|
||||
{
|
||||
<p class="hero-subtitle">@category.Description</p>
|
||||
}
|
||||
<a href="/portfolio" class="btn btn-secondary">← Back to Portfolio</a>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="shop-products">
|
||||
<div class="container">
|
||||
<div class="projects-grid">
|
||||
@foreach (var project in Model)
|
||||
{
|
||||
<div class="project-card">
|
||||
@if (!string.IsNullOrEmpty(project.FeaturedImage))
|
||||
{
|
||||
<div class="project-image">
|
||||
<img src="@project.FeaturedImage" alt="@project.Title" />
|
||||
</div>
|
||||
}
|
||||
<div class="project-info">
|
||||
<h3>@project.Title</h3>
|
||||
@if (!string.IsNullOrEmpty(project.Description))
|
||||
{
|
||||
<p>@Html.Raw(project.Description)</p>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
35
Sky_Art_shop/Views/Portfolio/Index.cshtml
Normal file
35
Sky_Art_shop/Views/Portfolio/Index.cshtml
Normal file
@@ -0,0 +1,35 @@
|
||||
@model List<SkyArtShop.Models.PortfolioCategory>
|
||||
@{
|
||||
ViewData["Title"] = "Portfolio";
|
||||
}
|
||||
|
||||
<section class="portfolio-hero">
|
||||
<div class="container">
|
||||
<h1>Sky Art Shop Projects</h1>
|
||||
<p class="hero-subtitle">Welcome to our portfolio. Here you'll find a selection of our work. Explore our projects to learn more about what we do.</p>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="portfolio-gallery">
|
||||
<div class="container">
|
||||
<div class="portfolio-grid">
|
||||
@foreach (var category in Model)
|
||||
{
|
||||
<div class="portfolio-category">
|
||||
<a href="/portfolio/category/@category.Slug" class="category-link">
|
||||
<div class="category-image">
|
||||
<img src="@(string.IsNullOrEmpty(category.FeaturedImage) ? "/assets/images/portfolio/default.jpg" : category.FeaturedImage)" alt="@category.Name" />
|
||||
<div class="category-overlay">
|
||||
<h2>@category.Name</h2>
|
||||
@if (!string.IsNullOrEmpty(category.Description))
|
||||
{
|
||||
<p>@category.Description</p>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
Reference in New Issue
Block a user