fix: new index
This commit is contained in:
@@ -39,9 +39,6 @@
|
|||||||
<text class="date-year">{{ currentDate.year }}</text>
|
<text class="date-year">{{ currentDate.year }}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<text class="lunar-text"
|
|
||||||
>农历 {{ lunarDate.month }}{{ lunarDate.day }}</text
|
|
||||||
>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="lucky-divider"></view>
|
<view class="lucky-divider"></view>
|
||||||
<view class="lucky-middle">
|
<view class="lucky-middle">
|
||||||
@@ -49,7 +46,9 @@
|
|||||||
<text class="tag-yi">宜 {{ lunarDate.yi.split("、")[0] }}</text>
|
<text class="tag-yi">宜 {{ lunarDate.yi.split("、")[0] }}</text>
|
||||||
<text class="tag-ji">忌 {{ lunarDate.ji.split("、")[0] }}</text>
|
<text class="tag-ji">忌 {{ lunarDate.ji.split("、")[0] }}</text>
|
||||||
</view>
|
</view>
|
||||||
<text class="lucky-color">幸运色:{{ luckyColor }}</text>
|
<text class="lucky-lunar"
|
||||||
|
>农历 {{ lunarDate.month }}{{ lunarDate.day }}</text
|
||||||
|
>
|
||||||
</view>
|
</view>
|
||||||
<button class="lucky-btn" @tap="onOpenLucky">
|
<button class="lucky-btn" @tap="onOpenLucky">
|
||||||
<uni-icons
|
<uni-icons
|
||||||
@@ -174,6 +173,7 @@ import { onShareAppMessage, onShareTimeline, onShow } from "@dcloudio/uni-app";
|
|||||||
import { useUserStore } from "@/stores/user";
|
import { useUserStore } from "@/stores/user";
|
||||||
import { getRankList, watchAdReward } from "@/api/system";
|
import { getRankList, watchAdReward } from "@/api/system";
|
||||||
import { getUserSignInfo, userSignIn } from "@/api/user";
|
import { getUserSignInfo, userSignIn } from "@/api/user";
|
||||||
|
import calendar from "@/utils/lunar";
|
||||||
|
|
||||||
import LoginPopup from "@/components/LoginPopup/LoginPopup.vue";
|
import LoginPopup from "@/components/LoginPopup/LoginPopup.vue";
|
||||||
import LuckyPopup from "@/components/LuckyPopup/LuckyPopup.vue";
|
import LuckyPopup from "@/components/LuckyPopup/LuckyPopup.vue";
|
||||||
@@ -211,7 +211,6 @@ const handleLogin = () => {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
const luckyScore = ref(92);
|
const luckyScore = ref(92);
|
||||||
const luckyColor = ref("如意金");
|
|
||||||
|
|
||||||
const currentDate = computed(() => {
|
const currentDate = computed(() => {
|
||||||
const now = new Date();
|
const now = new Date();
|
||||||
@@ -222,13 +221,17 @@ const currentDate = computed(() => {
|
|||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
// 模拟农历数据
|
// 农历数据
|
||||||
const lunarDate = ref({
|
const lunarDate = computed(() => {
|
||||||
year: "2026",
|
const date = new Date();
|
||||||
month: "正月",
|
const lunar = calendar.solar2lunar(date);
|
||||||
day: "初一",
|
return {
|
||||||
yi: "团聚、访友、祈福",
|
year: lunar.lYear,
|
||||||
ji: "远行、搬家",
|
month: lunar.monthCn,
|
||||||
|
day: lunar.dayCn,
|
||||||
|
yi: "团聚、访友、祈福",
|
||||||
|
ji: "远行、搬家",
|
||||||
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
const sceneList = ref([
|
const sceneList = ref([
|
||||||
@@ -503,14 +506,6 @@ onShareTimeline(() => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.lunar-text {
|
|
||||||
font-size: 22rpx;
|
|
||||||
color: #d81e06;
|
|
||||||
opacity: 0.8;
|
|
||||||
font-weight: 500;
|
|
||||||
letter-spacing: 1rpx;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.lucky-divider {
|
.lucky-divider {
|
||||||
@@ -545,7 +540,7 @@ onShareTimeline(() => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.lucky-color {
|
.lucky-lunar {
|
||||||
font-size: 22rpx;
|
font-size: 22rpx;
|
||||||
color: #999;
|
color: #999;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user