fix: 统一新闻来源显示并添加手机号参数

修改多处组件将新闻来源统一显示为"中国证券报"
在获取文章详情API中添加可选phone参数
移除调试用的console.log语句
This commit is contained in:
34701892@qq.com 2026-01-05 20:45:20 +08:00
parent 763053ad6d
commit e763c82dce
4 changed files with 7 additions and 7 deletions

View File

@ -7,10 +7,9 @@ import request from "@/utils/index";
* @returns
*/
export const fetchArticleDetail = (data: any) => {
return request.get(`/news/detail/${data.id}`);
return request.get(`/news/detail/${data.id}?phone=${data?.phone || null}`);
};
/**
*
* @param data
@ -33,7 +32,7 @@ export const fetchArticleFavorate = (data: any) => {
// 热门行业
export const getListByTagIndustry = (data: any) => {
console.log("🚀 ~ getListByTagIndustry ~ data:", data)
console.log("🚀 ~ getListByTagIndustry ~ data:", data);
return request.get("/news/list/industry", { name: data.name });
};

View File

@ -27,7 +27,7 @@
<view :class="['news-meta', isLogin ? '' : 'mohu']">
<view style="display: flex; justify-content: space-between; width: 100%">
<view style="display: flex">
<text class="source">{{ item.source }}</text>
<text class="source">中国证券报</text>
<text class="time">{{ dayjs(item.publish_time).format("YYYY-MM-DD HH:MM:ss") }}</text>
</view>

View File

@ -8,7 +8,8 @@
<view class="author">
<view class="name">
<text class="text">来源:</text>
<text class="text">{{ isDomestic ? "中国证券报" : props.data.tag }}</text>
<!-- <text class="text">{{ isDomestic ? "中国证券报" : props.data.tag }}</text> -->
<text class="text">中国证券报</text>
</view>
<view class="name" v-if="props.data.editor">

View File

@ -114,7 +114,7 @@ onLoad(async (option: any) => {
newType.value = option.type || 14;
const res = await fetchArticleDetail({
id: option.id,
// id: 763,
phone: option?.phone || null,
});
if (res.code === 200) {