From 0bd9dcb159b09d2783a5fdd271b817ef344a5654 Mon Sep 17 00:00:00 2001 From: fwb Date: Wed, 4 Sep 2024 09:37:23 +0800 Subject: [PATCH] =?UTF-8?q?'=E6=9B=B4=E6=96=B0=E5=85=B3=E4=BA=8E=E6=88=91?= =?UTF-8?q?=E4=BB=AC'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/user/news.js | 13 ++++-- src/views/message/index.vue | 5 +- .../news/components/newsContentManage.vue | 46 ++++++++++++++++--- src/views/news/index.vue | 5 +- 4 files changed, 57 insertions(+), 12 deletions(-) diff --git a/src/api/user/news.js b/src/api/user/news.js index 400cd2e..634d1f3 100644 --- a/src/api/user/news.js +++ b/src/api/user/news.js @@ -32,9 +32,12 @@ export function queryEssay(category_id) { return request.get(`/api/cms-essay/query?category_id=${category_id}`); } //添加新闻文章 -export function addEssay(params){ - const str = parseParams(params) - return request.post(`/api/cms-essay/add${str}`) +// export function addEssay(params){ +// const str = parseParams(params) +// return request.post(`/api/cms-essay/add${str}`) +// } +export function addEssay(params) { + return request.post(`/api/cms-essay/add`, params); } //删除新闻 export function deleteEssay(ids) { @@ -43,4 +46,8 @@ export function deleteEssay(ids) { //修改新闻 export function editEssay(params) { return request.put(`/api/cms-essay/edit`, params); +} +//根据id查询关于我们文章 +export function queryEssayById(essay_id) { + return request.get(`/api/cms-essay/queryessaybyid?essay_id=${essay_id}`); } \ No newline at end of file diff --git a/src/views/message/index.vue b/src/views/message/index.vue index 64d1fae..acaf206 100644 --- a/src/views/message/index.vue +++ b/src/views/message/index.vue @@ -193,7 +193,10 @@ const sendContent = ()=>{ // 消息事件点击 const handleClick = (item)=> { - // console.log(item) + //查看消息切换已读状态 + if(!item.isRead){ + readMessage(item.id) + } //带查询参数 router.push({ path: '/messageContentList', query: item }) } diff --git a/src/views/news/components/newsContentManage.vue b/src/views/news/components/newsContentManage.vue index 6491380..6e3c29e 100644 --- a/src/views/news/components/newsContentManage.vue +++ b/src/views/news/components/newsContentManage.vue @@ -89,7 +89,7 @@ + + + 关于我们 + + + + + + + + + 提交修改 + \ No newline at end of file diff --git a/src/views/news/index.vue b/src/views/news/index.vue index 1f707e6..1666c0d 100644 --- a/src/views/news/index.vue +++ b/src/views/news/index.vue @@ -10,7 +10,7 @@
  • - {{ item.categoryName }} + {{ item.categoryName }}