From 85af0972075211182487aa8fb002a1d7cb6bb815 Mon Sep 17 00:00:00 2001 From: puhui999 Date: Fri, 20 Oct 2023 23:11:23 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E7=AB=A0=E8=AF=A6=E6=83=85=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=EF=BC=9A=E6=96=B0=E5=A2=9E=E8=B0=83=E7=94=A8=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E6=B5=8F=E8=A7=88=E9=87=8F=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/promotion/article.js | 7 +++++++ pages/news_details/index.vue | 2 ++ 2 files changed, 9 insertions(+) diff --git a/api/promotion/article.js b/api/promotion/article.js index 85d89193..4dbc9bec 100644 --- a/api/promotion/article.js +++ b/api/promotion/article.js @@ -29,3 +29,10 @@ export function getArticle(id) { noAuth: true // TODO 芋艿:后续要做调整 }); } + +// 增加文章浏览量 +export function addArticleBrowseCount(id) { + return request.put("app-api/promotion/article/add-browse-count?id=" + id, {}, { + noAuth: true // TODO 芋艿:后续要做调整 + }); +} diff --git a/pages/news_details/index.vue b/pages/news_details/index.vue index b653b256..49481a3b 100644 --- a/pages/news_details/index.vue +++ b/pages/news_details/index.vue @@ -114,6 +114,8 @@ } // #endif }); + // 增加文章浏览量 + ArticleApi.addArticleBrowseCount(this.id) }, goodInfo(id) { ProductSpuApi.getSpuDetail(id).then(res=>{