Commit c66ce156 by Hantao

fix: 修正徽章图片映射逻辑

修复 getBadgeImage 函数中的映射错误,将 badgeImgs 值与正确的 ASSETS 常量对齐。原代码中 case 0 返回 undefined,且映射整体偏移一位,导致显示错误。
parent 1869033b
......@@ -52,14 +52,16 @@ const badgeImgs = ref(0);
const getBadgeImage = () => {
switch (badgeImgs.value) {
case 0:
return ASSETS.badge1;
return;
case 1:
return ASSETS.badge2;
return ASSETS.badge1;
case 2:
return ASSETS.badge3;
return ASSETS.badge2;
case 3:
return ASSETS.badge4;
return ASSETS.badge3;
case 4:
return ASSETS.badge4;
case 5:
return ASSETS.badge5;
default:
return ASSETS.badge1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment