fix: correct BlogService GetPublishedPagedAsync parameter order
TaxBaik CI/CD / build-and-deploy (push) Failing after 1m25s

Use named parameters for clarity:
- categoryId: null
- ct: ct (cancellation token)

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-07-04 04:48:52 +09:00
parent 8591d93b88
commit a554e1795a
3 changed files with 61 additions and 63 deletions
-49
View File
@@ -1,49 +0,0 @@
using Microsoft.AspNetCore.Mvc.RazorPages;
using TaxBaik.Application.Services;
namespace TaxBaik.Web.Pages;
public class SitemapModel : PageModel
{
private readonly BlogService _blogService;
public List<string> Urls { get; set; } = [];
public SitemapModel(BlogService blogService)
{
_blogService = blogService;
}
public async Task OnGetAsync()
{
// 프로덕션 도메인 기본값 (배포 환경에서 자동 감지 가능)
var baseUrl = $"{Request.Scheme}://{Request.Host.Value}/taxbaik";
// 정적 페이지 (공개 콘텐츠만)
Urls.AddRange(new[]
{
// 홈페이지
$"{baseUrl}",
$"{baseUrl}/about",
$"{baseUrl}/services",
$"{baseUrl}/contact",
$"{baseUrl}/privacy",
$"{baseUrl}/terms",
// 공개 콘텐츠
$"{baseUrl}/blog",
$"{baseUrl}/faq",
$"{baseUrl}/announcement",
$"{baseUrl}/inquiry"
// 제외: /admin (관리자), /portal (고객 포탈)
// robots.txt에서도 disallow
});
// 동적 페이지: 블로그 포스트
var (posts, _) = await _blogService.GetPublishedPagedAsync(1, 1000);
foreach (var post in posts)
{
Urls.Add($"{baseUrl}/blog/{post.Slug}");
}
}
}