diff --git a/src/components/articlesBox/articlesBox.tsx b/src/components/articlesBox/articlesBox.tsx index 60e4edb..f27a84d 100644 --- a/src/components/articlesBox/articlesBox.tsx +++ b/src/components/articlesBox/articlesBox.tsx @@ -30,6 +30,15 @@ const ArticlesBox: FC = (props) => { articlesEvent.off(data.id) }) + Taro.useDidShow(()=>{ + articlesEvent.recordsOn(data.id, ({view}) => { + setData({ + ...data, + page_view: view + }) + }) + }) + const toArticlePage = () => { Taro.navigateTo({ url: `/pages/preview/brand/article/article?id=${data.id}`