From 3f1ab7f7f65fe665f6977f94899c763cc1ef1faf Mon Sep 17 00:00:00 2001
From: 李凌 <344137771@qq.com>
Date: Tue, 02 Jun 2026 15:56:14 +0800
Subject: [PATCH] 1
---
src/views/homePage/index.vue | 49 ++++++++++++++++++++++++++++++++++++++++++-------
1 files changed, 42 insertions(+), 7 deletions(-)
diff --git a/src/views/homePage/index.vue b/src/views/homePage/index.vue
index 55cacfe..9537265 100644
--- a/src/views/homePage/index.vue
+++ b/src/views/homePage/index.vue
@@ -32,7 +32,7 @@
</div>
<!-- 新闻 -->
- <van-notice-bar class="font-26 mt-10 index_notice" background="#333" :scrollable="false" wrapable
+ <!-- <van-notice-bar class="font-26 mt-10 index_notice" background="#333" :scrollable="false" wrapable
color="#333333">
<van-swipe vertical class="notice-swipe" :autoplay="2000" :show-indicators="false">
<van-swipe-item v-for="item in announceList" :key="item.id" @click="toAnnounceDetail(item.uuid)">
@@ -45,7 +45,7 @@
</div>
</van-swipe-item>
</van-swipe>
- </van-notice-bar>
+ </van-notice-bar> -->
<!-- <div class="flex justify-between mt-10">
<van-swipe class="home_swipe_1" :autoplay="2000">
@@ -81,6 +81,19 @@
<div id="cryptos" class="pt-10">
<list-quatation :listData="qList" :tabShow="false" :tabActive="2" />
</div>
+
+ <van-popup v-model:show="item.showPopUp" style="border-radius:10px;" :close-on-click-overlay="false"
+ v-for="item in popupNewsList" :key="item.id">
+ <div class="w-350 p-20 box-border popup_news">
+ <div class="font-700 text-center font-28 textColor">{{ item.title }}</div>
+ <div class="flex justify-center mt-30" v-if="item.imgUrl"><img :src="`${item.imgUrl}`"
+ class="w-200 h-200" alt="" /></div>
+ <div class="py-10 textColor content-title" v-html="item.content"></div>
+ <van-button color="#1194F7" class="w-full h-40 rounded-full" type="info" @click="closePopNotice(item)">
+ {{ $t('我知道了') }}
+ </van-button>
+ </div>
+ </van-popup>
</div>
</template>
@@ -109,13 +122,14 @@
// { key: 1, name: t('跟单'), icon: new URL('@/assets/imgs/home/home_1.png', import.meta.url) },
// { key: 3, name: `C2C ${t('交易')}`, icon: new URL('@/assets/imgs/home/home_3.png', import.meta.url) },
// { key: 4, name: t('邀请好友'), icon: new URL('@/assets/imgs/home/home_4.png', import.meta.url) },
- // { key: 5, name: t('合约'), icon: new URL('@/assets/imgs/home/home_5.png', import.meta.url), path: '/trade/index' },
- // { key: 6, name: t('现货'), icon: new URL('@/assets/imgs/home/home_5.png', import.meta.url), path: '/cryptos/trade/btcusdt' },
- { key: 2, name: t('储值'), icon: new URL('@/assets/imgs/home/home_2.png', import.meta.url), path: '/cryptos/recharge/rechargeList?isForeign=true' },
+ { key: 5, name: t('合约'), icon: new URL('@/assets/imgs/home/home_5.png', import.meta.url), path: '/trade/index' },
+ { key: 6, name: t('现货'), icon: new URL('@/assets/imgs/home/home_7.png', import.meta.url), path: '/cryptos/trade/btcusdt' },
+ { key: 2, name: t('recharge'), icon: new URL('@/assets/imgs/home/home_2.png', import.meta.url), path: '/cryptos/recharge/rechargeList?isForeign=true' },
// { key: 7, name: t('提现'), icon: new URL('@/assets/imgs/home/home_6.png', import.meta.url), path: '/exchange/withdraw-usdt' }
{ key: 7, name: t('提现'), icon: new URL('@/assets/imgs/home/home_6.png', import.meta.url), path: '/cryptos/Withdraw/withdrawPage' },
// { key: 8, name: t('卡券中心'), icon: new URL('@/assets/imgs/home/home_7.png', import.meta.url) },
- // { key: 9, name: t('闪兑'), icon: new URL('@/assets/imgs/home/home_8.png', import.meta.url), path: '/cryptos/exchangePage' },
+ { key: 9, name: t('闪兑'), icon: new URL('@/assets/imgs/home/home_8.png', import.meta.url), path: '/cryptos/exchangePage' },
+ { key: 16, name: t('理财'), icon: new URL('@/assets/imgs/home/home_1.png', import.meta.url), path: '/cryptos/fund' },
// { key: 9, name: t('划转'), icon: new URL('@/assets/imgs/home/home_8.png', import.meta.url), path: '/my/transfer' },
// { key: 10, name: t('更多'), icon: new URL('@/assets/imgs/home/home_9.png', import.meta.url) },
@@ -123,7 +137,7 @@
// { key: 12, name: "C2C", icon: new URL('@/assets/imgs/home/home_1.png', import.meta.url), path: '/wantBuy' },
// { key: 13, name: t('质押'), icon: new URL('@/assets/imgs/home/home_1.png', import.meta.url), path: '' },
{ key: 14, name: t('onLineService'), icon: new URL('@/assets/imgs/home/home_10.png', import.meta.url), path: '/customerService' },
- { key: 15, name: 'DXCM PDF', icon: new URL('@/assets/imgs/home/home_1.png', import.meta.url), path: 'https://www.dexm-whitepaper.com/' },
+ { key: 15, name: t('矿机'), icon: new URL('@/assets/imgs/home/home_1.png', import.meta.url), path: '/cryptos/machine' },
]
// 获取公告数据
@@ -133,6 +147,24 @@
}).then(res => {
announceList.value = res
})
+
+// 获取弹出新闻
+const popupNewsList = ref([])
+_getPopupNews({
+ language: useI18n().locale.value,
+}).then(res => {
+ if (res && res.length > 0) {
+ let list = res
+ list.forEach(item => {
+ item.showPopUp = true
+ })
+ popupNewsList.value = list
+ }
+})
+// 关闭弹窗新闻
+const closePopNotice = (item) => {
+ item.showPopUp = false
+}
// 跳转公告详情
const toAnnounceDetail = (announceId) => {
@@ -244,6 +276,9 @@
$tab-c: #888;
$inp-c: #999;
$crd-b: #f7f7f7;
+ .popup_news{
+ font-size: 1.8rem;
+ }
.index_notice {
height: 100px;
--
Gitblit v1.9.3