diff --git a/src/FluentCMS.Api/Controllers/PagesController.cs b/src/FluentCMS.Api/Controllers/PageController.cs similarity index 94% rename from src/FluentCMS.Api/Controllers/PagesController.cs rename to src/FluentCMS.Api/Controllers/PageController.cs index b606be92b..438422e77 100644 --- a/src/FluentCMS.Api/Controllers/PagesController.cs +++ b/src/FluentCMS.Api/Controllers/PageController.cs @@ -6,12 +6,12 @@ namespace FluentCMS.Api.Controllers; -public class PagesController : BaseController +public class PageController : BaseController { private readonly IPageService _pageService; private readonly IMapper _mapper; - public PagesController(IPageService pageService, IMapper mapper) + public PageController(IPageService pageService, IMapper mapper) { _pageService = pageService; _mapper = mapper; diff --git a/src/FluentCMS.Web.UI/Pages/Pages/PageEdit.razor b/src/FluentCMS.Web.UI/Pages/Pages/PageEdit.razor index f577561d5..ee8310a2c 100644 --- a/src/FluentCMS.Web.UI/Pages/Pages/PageEdit.razor +++ b/src/FluentCMS.Web.UI/Pages/Pages/PageEdit.razor @@ -52,7 +52,7 @@ } try { - var response = (await _httpClient.GetFromJsonAsync>($"pages/getById/{Id.Value}"))!; + var response = (await _httpClient.GetFromJsonAsync>($"page/getById/{Id.Value}"))!; if (response.Data != null) { Page = new() @@ -80,7 +80,7 @@ var createCommand = Page; try { - await _httpClient.PostAsJsonAsync($"pages/create", createCommand); + await _httpClient.PostAsJsonAsync($"page/create", createCommand); _navigationManager.NavigateTo($"/admin/pages/{SiteId}"); } catch (Exception) @@ -103,7 +103,7 @@ }; try { - await _httpClient.PutAsJsonAsync($"pages/update", updateCommand); + await _httpClient.PutAsJsonAsync($"page/update", updateCommand); _navigationManager.NavigateTo($"/admin/pages/{updateCommand.SiteId}"); } catch (Exception)