mirror of
https://github.com/yawaflua/yaflay.ru.git
synced 2025-12-09 20:19:32 +02:00
Fix AdminPanel json
This commit is contained in:
@@ -33,7 +33,8 @@
|
||||
<div id="blogId" style="display:none;">@Model.Id</div>
|
||||
<p align="center"><img src="@Post.ImageUrl" style="width:50vmax;"/></p>
|
||||
<p align="center">@Html.Raw(Post.Text)</p>
|
||||
<h6 align="left">Статья подготовлена <a href="https://discord.com/users/@Post.author.Id">@Post.author.discordNickName</a></h6>
|
||||
string userId = "https://discord.com/users/"+Post.author.Id;
|
||||
<h6 align="left">Статья подготовлена <a href="@userId">@Post.author.discordNickName</a></h6>
|
||||
<div class="container my-5 py-5 bg-dark text-muted">
|
||||
<div class="row d-flex justify-content-center">
|
||||
<div class="col-md-12 col-lg-10">
|
||||
|
||||
@@ -55,6 +55,7 @@ namespace yaflay.ru
|
||||
.AddRazorPagesOptions(options =>
|
||||
{
|
||||
options.Conventions.AddPageRoute("/RobotsTxt", "/Robots.txt");
|
||||
options.Conventions.AddPageRoute("/RobotsTxt", "/robots.txt");
|
||||
options.Conventions.AddPageRoute("/NotFound", "/404");
|
||||
options.Conventions.AddPageRoute("/IternalErrorPage", "/500");
|
||||
options.Conventions.AddPageRoute("/Authorize", "/authorize");
|
||||
@@ -71,6 +72,7 @@ namespace yaflay.ru
|
||||
.AddRazorPagesOptions(options =>
|
||||
{
|
||||
options.Conventions.AddPageRoute("/RobotsTxt", "/Robots.txt");
|
||||
options.Conventions.AddPageRoute("/RobotsTxt", "/robots.txt");
|
||||
options.Conventions.AddPageRoute("/NotFound", "/404");
|
||||
options.Conventions.AddPageRoute("/IternalErrorPage", "/500");
|
||||
options.Conventions.AddPageRoute("/Authorize", "/authorize");
|
||||
@@ -81,7 +83,7 @@ namespace yaflay.ru
|
||||
services.AddCoreAdmin("admin");
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
|
||||
{
|
||||
// Add services to the container.
|
||||
@@ -108,8 +110,6 @@ namespace yaflay.ru
|
||||
endpoints.MapDefaultControllerRoute();
|
||||
endpoints.MapRazorPages();
|
||||
endpoints.MapControllers();
|
||||
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
@@ -12,11 +12,11 @@ function updateAnnotation(value) {
|
||||
function sendArticleData () {
|
||||
let melon = document.cookie.split(';')[0].replace("melon=", "");
|
||||
let body = `{
|
||||
title: ${$("#titleInput").val()},
|
||||
annotation: ${$("#annotationArea").val()},
|
||||
text: ${$("#textArea").val()},
|
||||
image: ${$("#imgInput").val()},
|
||||
author: ${melon}
|
||||
title: "${$("#titleInput").val()}",
|
||||
annotation: "${$("#annotationArea").val()}",
|
||||
text: "${$("#textArea").val()}",
|
||||
image: "${$("#imgInput").val()}",
|
||||
author: "${melon}"
|
||||
}`
|
||||
fetch("/api/Blog", {
|
||||
method: "POST",
|
||||
|
||||
Reference in New Issue
Block a user