This commit is contained in:
kron
2025-07-07 12:51:02 +08:00
parent 9ad65370b5
commit 3e70de349a
3 changed files with 13 additions and 10 deletions

View File

@@ -168,7 +168,7 @@ watch(
}
.level-tag-second {
width: 30px;
width: 25px;
background: #09c504;
}

View File

@@ -52,11 +52,6 @@ onMounted(async () => {
try {
const deviceInfo = uni.getDeviceInfo();
isIos.value = deviceInfo.osName === "ios";
const config = await getAppConfig();
updateConfig(config);
console.log("全局配置:", config);
const rankList = await getRankListAPI();
updateRank(rankList);
const token = uni.getStorageSync("token");
if (token) {
const result = await getHomeData();
@@ -70,8 +65,12 @@ onMounted(async () => {
);
}
}
console.log("首页数据:", result);
}
const config = await getAppConfig();
updateConfig(config);
console.log("全局配置:", config);
const rankList = await getRankListAPI();
updateRank(rankList);
} catch (error) {
console.error("获取配置失败:", error);
}
@@ -100,9 +99,12 @@ const comingSoon = () => {
<text v-if="!user.id">我的弓箭</text>
<text v-if="user.id && !device.deviceId">请绑定设备</text>
<text v-if="user.id && device.deviceId">{{
device.deviceName
}}</text>
<text
v-if="user.id && device.deviceId"
class="truncate"
:style="{ width: '90%', textAlign: 'center' }"
>{{ device.deviceName }}</text
>
<image
src="../static/a2@2x.png"
mode="widthFix"

View File

@@ -89,6 +89,7 @@ export default defineStore("store", {
if (this.user.scores) {
rankInfos.some((r, index) => {
lvlName = rankInfos[index].name;
lvlImage = rankInfos[index].icoin;
if (r.upgrade_scores > this.user.scores) {
if (rankInfos[index - 1]) {
lvlName = rankInfos[index - 1].name;