增加markdown支持。

This commit is contained in:
2026-07-28 15:51:54 +08:00
parent 98161a2fe8
commit 21be62fa7c
15 changed files with 353 additions and 6 deletions
+3
View File
@@ -76,6 +76,9 @@ func SetupRoutes(r *gin.Engine, cfg interface{}) {
admin.PUT("/posts/:id", handlers.UpdatePost)
admin.DELETE("/posts/:id", handlers.DeletePost)
// Markdown 预览(文章编辑器用)
admin.POST("/markdown/preview", handlers.PreviewMarkdown)
// 分类管理
admin.POST("/categories", handlers.CreateCategory)
admin.PUT("/categories/:id", handlers.UpdateCategory)