Merge branch 'H5back' into fgm
This commit is contained in:
commit
7912b37281
|
|
@ -37,6 +37,12 @@ export const getTopNews = (data: any) => {
|
||||||
// 概念标签贴标
|
// 概念标签贴标
|
||||||
export const getTopNewsAll = (data: any) => {
|
export const getTopNewsAll = (data: any) => {
|
||||||
return request.get("/top_news_release_h5_all", data);
|
return request.get("/top_news_release_h5_all", data);
|
||||||
|
// return request.get("/news_release_ratingrank_h5_d", data);
|
||||||
|
};
|
||||||
|
|
||||||
|
// 概念标签贴标 release
|
||||||
|
export const getTopNewsAllRelease = (data: any) => {
|
||||||
|
return request.get("/news_release_ratingrank_h5_d?input_date=" + data.input_date + "&limit_num=10");
|
||||||
};
|
};
|
||||||
|
|
||||||
// 热门行业top10:
|
// 热门行业top10:
|
||||||
|
|
|
||||||
|
|
@ -79,6 +79,7 @@
|
||||||
<view style="background-color: white; padding-top: 40rpx">
|
<view style="background-color: white; padding-top: 40rpx">
|
||||||
<view style="width: 100vw; display: flex; justify-content: space-between; align-items: center">
|
<view style="width: 100vw; display: flex; justify-content: space-between; align-items: center">
|
||||||
<indexMenuTitle title="编辑精选" style="margin-top: 10rpx"></indexMenuTitle>
|
<indexMenuTitle title="编辑精选" style="margin-top: 10rpx"></indexMenuTitle>
|
||||||
|
|
||||||
<view class="r_sreach">
|
<view class="r_sreach">
|
||||||
<!-- <image class="top_bk" src="https://cankao.obs.cn-east-3.myhuaweicloud.com/mini/newmini/top_bg.png"></image> -->
|
<!-- <image class="top_bk" src="https://cankao.obs.cn-east-3.myhuaweicloud.com/mini/newmini/top_bg.png"></image> -->
|
||||||
<!-- <image class="logo_text" src="https://cankao.obs.cn-east-3.myhuaweicloud.com/mini/newmini/logo_text_icon.png"> </image> -->
|
<!-- <image class="logo_text" src="https://cankao.obs.cn-east-3.myhuaweicloud.com/mini/newmini/logo_text_icon.png"> </image> -->
|
||||||
|
|
@ -93,11 +94,41 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
<view style="width: 100%; display: flex; justify-content: flex-end">
|
||||||
|
<view
|
||||||
|
style="
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
margin-right: 15rpx;
|
||||||
|
font-size: 30rpx;
|
||||||
|
gap: 10rpx;
|
||||||
|
margin-top: 10rpx;
|
||||||
|
"
|
||||||
|
@click="showCalendar"
|
||||||
|
>
|
||||||
|
{{ chooseDate.startDate.split(" ")[0] }}
|
||||||
|
<u-icon name="calendar" size="26" style="margin-right: 10rpx"></u-icon>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
<RankList hasTag :newsList="newsList" :needExp="false"></RankList>
|
<RankList hasTag :newsList="newsList" :needExp="false"></RankList>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="logout" @click="loginOut" v-if="Session.get('token')">退出登录</view>
|
<view class="logout" @click="loginOut" v-if="Session.get('token')">退出登录</view>
|
||||||
|
|
||||||
|
<u-calendar
|
||||||
|
:show="calendarShow"
|
||||||
|
min-date="2025-01-01"
|
||||||
|
closeOnClickOverlay
|
||||||
|
:max-date="maxDate"
|
||||||
|
:default-date="chooseDate.startDate"
|
||||||
|
monthNum="24"
|
||||||
|
:key="chooseDate.startDate"
|
||||||
|
@confirm="calendarConfirm"
|
||||||
|
@close="calendarShow = false"
|
||||||
|
>
|
||||||
|
</u-calendar>
|
||||||
|
|
||||||
<LoginPopup
|
<LoginPopup
|
||||||
:show="LoginShow"
|
:show="LoginShow"
|
||||||
@handlePopupClose="handlePopupClose"
|
@handlePopupClose="handlePopupClose"
|
||||||
|
|
@ -133,6 +164,7 @@ import {
|
||||||
getTopConceptPeriod,
|
getTopConceptPeriod,
|
||||||
getTopIndustryPeriod,
|
getTopIndustryPeriod,
|
||||||
getTopSourcePeriod,
|
getTopSourcePeriod,
|
||||||
|
getTopNewsAllRelease,
|
||||||
} from "@/api/newsInfo";
|
} from "@/api/newsInfo";
|
||||||
import countTo from "@/components/count-to/vue-countTo.vue";
|
import countTo from "@/components/count-to/vue-countTo.vue";
|
||||||
import RankList from "@/components/RankList.vue"; // 路径根据实际调整
|
import RankList from "@/components/RankList.vue"; // 路径根据实际调整
|
||||||
|
|
@ -157,6 +189,35 @@ const handleViewAll = () => {
|
||||||
|
|
||||||
const topNum = ref({});
|
const topNum = ref({});
|
||||||
|
|
||||||
|
const d = new Date();
|
||||||
|
const year = d.getFullYear();
|
||||||
|
let month = d.getMonth() + 1;
|
||||||
|
month = month < 10 ? `0${month}` : month;
|
||||||
|
const date = d.getDate();
|
||||||
|
const maxDate = ref(`${year}-${month}-${date} 23:59:59`);
|
||||||
|
const minDate = ref(`${year}-${month}-${date}`);
|
||||||
|
|
||||||
|
const calendarShow = ref(false);
|
||||||
|
|
||||||
|
const chooseDate = reactive({
|
||||||
|
startDate: `${year}-${month}-${date}`,
|
||||||
|
endDate: null,
|
||||||
|
});
|
||||||
|
function showCalendar() {
|
||||||
|
calendarShow.value = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
function calendarConfirm(dateList) {
|
||||||
|
console.log("🚀 ~ calendarConfirm ~ dateList:", dateList);
|
||||||
|
if (dateList && dateList.length > 0) {
|
||||||
|
chooseDate.startDate = dateList[0] + " 00:00:00";
|
||||||
|
chooseDate.endDate = dateList[dateList.length - 1] + " 23:59:59";
|
||||||
|
}
|
||||||
|
getNewsList();
|
||||||
|
calendarShow.value = false;
|
||||||
|
console.log("🚀 ~ calendarConfirm ~ chooseDate:", chooseDate);
|
||||||
|
}
|
||||||
|
|
||||||
// 获取顶部两个统计数据
|
// 获取顶部两个统计数据
|
||||||
async function getTopNum() {
|
async function getTopNum() {
|
||||||
let res1 = await getindustryCount({});
|
let res1 = await getindustryCount({});
|
||||||
|
|
@ -170,7 +231,11 @@ async function getTopNum() {
|
||||||
|
|
||||||
// 概念标签贴标
|
// 概念标签贴标
|
||||||
async function getNewsList() {
|
async function getNewsList() {
|
||||||
newsList.value = await getTopNewsAll({});
|
console.log(`🚀 ~ getNewsList ~ chooseDate.startDate.split(" ")[0]:`, chooseDate.startDate.split(" ")[0]);
|
||||||
|
|
||||||
|
newsList.value = await getTopNewsAllRelease({
|
||||||
|
input_date: chooseDate.startDate.split(" ")[0],
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// 热门行业top10
|
// 热门行业top10
|
||||||
|
|
@ -223,9 +288,9 @@ function onViewAll(type) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const timer = setInterval(() => {
|
// const timer = setInterval(() => {
|
||||||
initData();
|
// initData();
|
||||||
}, 5000);
|
// }, 5000);
|
||||||
|
|
||||||
const LoginShow = ref(false);
|
const LoginShow = ref(false);
|
||||||
const isLoginStatus = ref();
|
const isLoginStatus = ref();
|
||||||
|
|
@ -350,7 +415,9 @@ onMounted(async () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
text {
|
text {
|
||||||
font-family: PingFangSC, PingFang SC;
|
font-family:
|
||||||
|
PingFangSC,
|
||||||
|
PingFang SC;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
color: rgba(255, 255, 255, 0.8);
|
color: rgba(255, 255, 255, 0.8);
|
||||||
|
|
@ -393,7 +460,9 @@ onMounted(async () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
.tag_title {
|
.tag_title {
|
||||||
font-family: PingFangSC, PingFang SC;
|
font-family:
|
||||||
|
PingFangSC,
|
||||||
|
PingFang SC;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
color: #222222;
|
color: #222222;
|
||||||
|
|
@ -401,7 +470,9 @@ onMounted(async () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
.tag_num {
|
.tag_num {
|
||||||
font-family: PingFangSC, PingFang SC;
|
font-family:
|
||||||
|
PingFangSC,
|
||||||
|
PingFang SC;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: 38rpx;
|
font-size: 38rpx;
|
||||||
color: #222222;
|
color: #222222;
|
||||||
|
|
@ -409,7 +480,9 @@ onMounted(async () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
.tag_status {
|
.tag_status {
|
||||||
font-family: PingFangSC, PingFang SC;
|
font-family:
|
||||||
|
PingFangSC,
|
||||||
|
PingFang SC;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-size: 22rpx;
|
font-size: 22rpx;
|
||||||
color: #999999;
|
color: #999999;
|
||||||
|
|
@ -532,7 +605,9 @@ onMounted(async () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
.sreach_text {
|
.sreach_text {
|
||||||
font-family: PingFangSC, PingFang SC;
|
font-family:
|
||||||
|
PingFangSC,
|
||||||
|
PingFang SC;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
color: #999999;
|
color: #999999;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue