feat(API): 修改文章ID类型为String并添加CORS配置

将文章ID从Integer类型改为String类型以支持更灵活的ID格式
添加CORS配置类解决跨域问题,允许所有来源访问API
This commit is contained in:
qingfeng1121
2025-10-11 13:32:41 +08:00
parent 470cf71713
commit 299c9a57ec
6 changed files with 996 additions and 5 deletions

View File

@@ -7,7 +7,7 @@ import com.qf.myafterprojecy.pojo.dto.ArticleDto;
import java.util.List;
public interface IArticleService {
ResponseMessage<Article> getArticleById(Integer id);
ResponseMessage<Article> getArticleById(String id);
ResponseMessage<List<Article>> getAllArticles();
ResponseMessage<Article> saveArticle(ArticleDto articleDto);
ResponseMessage<Article> updateArticle(Integer id, ArticleDto articleDto);