2023情人节:购买后刷新,修改我的cp样式
This commit is contained in:
@@ -900,20 +900,32 @@ body {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
}
|
||||
.mycpBox .mycp_in ul li b,
|
||||
.mycpBox .mycp_in ul li b {
|
||||
width: 1.8rem;
|
||||
height: 0.4rem;
|
||||
text-align: center;
|
||||
color: #AE2B5C;
|
||||
font-size: 0.32rem;
|
||||
margin-bottom: 0.2666666667rem;
|
||||
}
|
||||
.mycpBox .mycp_in ul li .cpValue {
|
||||
width: 2.4rem;
|
||||
height: 0.4rem;
|
||||
text-align: center;
|
||||
}
|
||||
.mycpBox .mycp_in ul li span {
|
||||
width: 1.2rem;
|
||||
height: 0.4rem;
|
||||
text-align: center;
|
||||
line-height: 0.4rem;
|
||||
color: #AE2B5C;
|
||||
font-size: 0.32rem;
|
||||
margin-bottom: 0.2666666667rem;
|
||||
}
|
||||
.mycpBox .mycp_in ul li .waitpass {
|
||||
width: 1rem;
|
||||
height: 0.4rem;
|
||||
background-color: #FF63D0;
|
||||
border-radius: 0.2rem;
|
||||
color: #ffffff;
|
||||
text-align: center;
|
||||
line-height: 0.4rem;
|
||||
}
|
||||
.mycpBox .mycp_in ul li .pass {
|
||||
color: #FE28B0;
|
||||
|
@@ -1022,21 +1022,34 @@ body {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
|
||||
b,
|
||||
b {
|
||||
width: 1.8rem;
|
||||
height: px2rem(30, );
|
||||
text-align: center;
|
||||
color: #AE2B5C;
|
||||
font-size: px2rem(24, );
|
||||
margin-bottom: px2rem(20, );
|
||||
}
|
||||
.cpValue {
|
||||
width: 2.4rem;
|
||||
height: px2rem(30, );
|
||||
text-align: center;
|
||||
}
|
||||
span {
|
||||
width: 1.2rem;
|
||||
height: px2rem(30, );
|
||||
text-align: center;
|
||||
line-height: px2rem(30, );
|
||||
color: #AE2B5C;
|
||||
font-size: px2rem(24, );
|
||||
margin-bottom: px2rem(20, );
|
||||
}
|
||||
|
||||
.waitpass {
|
||||
width: 1rem;
|
||||
height: px2rem(30, );
|
||||
background-color: #FF63D0;
|
||||
border-radius: px2rem(15, );
|
||||
color: #ffffff;
|
||||
text-align: center;
|
||||
line-height: px2rem(30, );
|
||||
|
||||
}
|
||||
|
||||
.pass {
|
||||
|
@@ -92,7 +92,7 @@
|
||||
<div class="petition_title"></div>
|
||||
<div class="petition-wrap">
|
||||
<div class="myticket">
|
||||
<span>我的情簽: <e>999,999,999</e></span>
|
||||
<span>我的情簽: <e></e></span>
|
||||
<div class="charge">兌換記錄</div>
|
||||
</div>
|
||||
<div class="subheard">贈送情人節限定禮物,送出一個禮物可得對應數量的「幸運情簽」,且可增加CP間的情緣值,情簽可兌換特權或抽獎喲~</div>
|
||||
@@ -257,18 +257,18 @@
|
||||
<ul class="box">
|
||||
<li>
|
||||
<b>CP1的昵称...</b>
|
||||
<b>170011703</b>
|
||||
<b class="cpValue">170011703</b>
|
||||
<span class="pass">已缔结</span>
|
||||
</li>
|
||||
<li>
|
||||
<b>CP1的昵称...</b>
|
||||
<b>170011703</b>
|
||||
<span class="waitpass" inviterUid="2346">通过</span>
|
||||
<b class="cpValue">170011703</b>
|
||||
<span class="waitpass" inviterUid="2346">可通过</span>
|
||||
</li>
|
||||
<li>
|
||||
<b>Cp1的昵称...</b>
|
||||
<b>170011703</b>
|
||||
<span class="canpass">可通过</span>
|
||||
<b class="cpValue">170011703</b>
|
||||
<span class="canpass">待通过</span>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="tips">暫無更多記錄~</div>
|
||||
|
@@ -176,8 +176,8 @@ function myCpList() {
|
||||
cpList = `
|
||||
<li>
|
||||
<b>${res.nick.length > 5 ? res.nick.slice(0, 5) + '...' : res.nick}</b>
|
||||
<b>${res.cpValue}</b>
|
||||
<span inviterUid="${res.uid}" class='${res.status == 0 ? "waitpass" : res.status == 1 ? "canpass" : "pass"}'>${res.status == 0 ? "通過" : res.status == 1 ? "可通過" : "已締結"}</span>
|
||||
<b class="cpValue">${res.cpValue}</b>
|
||||
<span inviterUid="${res.uid}" class='${res.status == 0 ? "canpass" : res.status == 1 ? "waitpass" : "pass"}'>${res.status == 0 ? "待通過" : res.status == 1 ? "可通過" : "已締結"}</span>
|
||||
</li>
|
||||
`
|
||||
})
|
||||
@@ -356,21 +356,31 @@ function buy(id, num) {
|
||||
data: { id, num },
|
||||
success(res) {
|
||||
if (res.code === 200) {
|
||||
if (id == 1) {
|
||||
toastMsg('購買成功,禮券已放進背包,快送給你心意的TA吧~')
|
||||
canGet = true
|
||||
} else if (id == 6) {
|
||||
$('.gx .gx_in .box li img').attr('src', res, data.icon)
|
||||
$('.gx .gx_in .box li span').attr('src', res, data.name)
|
||||
$('.gx .gx_in .tips').html(`*情人节限定5位靓号:52XXX(XXX为随机数字,一组为2个靓号,<br>联系客服领取:LINE: pekoyuyin)`)
|
||||
$('.gx').show()
|
||||
} else {
|
||||
$('.gx .gx_in .box li img').attr('src', res, data.icon)
|
||||
$('.gx .gx_in .box li span').attr('src', res, data.name)
|
||||
$('.gx .gx_in .tips').html(`奖励将自动发放到装扮中心,快去展示自己吧~`)
|
||||
$('.gx').show()
|
||||
if (res.data.prop) {
|
||||
if (res.data.prop.type == 1) {
|
||||
$('.letter-wrap .letter p e').html(res.data.remain)
|
||||
toastMsg('購買成功,信物已放進背包,快送給你心儀的TA吧~')
|
||||
canGet = true
|
||||
} else if (res.data.prop.type == 6) {
|
||||
$('.petition-wrap .myticket span e').html(res.data.remain)
|
||||
$('.gx .gx_in .box li img').attr('src', res.data.prop.icon)
|
||||
$('.gx .gx_in .box li span').attr('src', res.data.name)
|
||||
$('.gx .gx_in .tips').html(`*情人節限定5位靚號:52XXX(XXX為隨機數字,一組為2個靚號,<br>聯系客服領取:LINE: pekoyuyin)`)
|
||||
$('.gx').show()
|
||||
|
||||
} else {
|
||||
$('.petition-wrap .myticket span e').html(res.data.remain)
|
||||
|
||||
$('.gx .gx_in .box li img').attr('src', res.data.icon)
|
||||
$('.gx .gx_in .box li span').attr('src', res.data.name)
|
||||
$('.gx .gx_in .tips').html(`獎勵將自動發放到裝扮中心,快去展示自己吧~`)
|
||||
$('.gx').show()
|
||||
}
|
||||
} else {
|
||||
toastMsg(res.message)
|
||||
canGet = true
|
||||
}
|
||||
|
||||
hideLoading(layerIndex)
|
||||
} else if (res.code == 31005) {
|
||||
$('.tishiBox').show()
|
||||
@@ -416,7 +426,7 @@ function getRank() {
|
||||
$(`.rank-wrap .list .no${index + 1} .txbox1 img`).attr('src', res.inviterAvatar);
|
||||
$(`.rank-wrap .list .no${index + 1} .txbox1`).attr('uid', res.inviterUid);
|
||||
$(`.rank-wrap .list .no${index + 1} .nick1`).html(res.inviterNick.length > 5 ? res.inviterNick.slice(0, 5) + '...' : res.inviterNick);
|
||||
$(`.rank-wrap .list .no${index + 1} .txbox2 img`).attr('src', res.inviterAvatar);
|
||||
$(`.rank-wrap .list .no${index + 1} .txbox2 img`).attr('src', res.inviteeAvatar);
|
||||
$(`.rank-wrap .list .no${index + 1} .txbox2`).attr('uid', res.inviteeUid);
|
||||
$(`.rank-wrap .list .no${index + 1} .nick2`).html(res.inviteeNick.length > 5 ? res.inviteeNick.slice(0, 5) + '...' : res.inviteeNick);
|
||||
$(`.rank-wrap .list .no${index + 1} .score b`).html(`${res.cpValue > 10000 ? (Math.floor(res.cpValue / 1000) / 10).toFixed(1) + 'w' : res.cpValue}`);
|
||||
@@ -431,7 +441,7 @@ function getRank() {
|
||||
<img src="${res.inviterAvatar}" uid="${res.inviterUid}" class="tx" alt="">
|
||||
</div>
|
||||
<div class="txbox2" uid="${res.inviteeUid}">
|
||||
<img src="${res.inviteeAvatar}" uid="${res.inviterUid}" class="tx" alt="">
|
||||
<img src="${res.inviteeAvatar}" uid="${res.inviteeUid}" class="tx" alt="">
|
||||
</div>
|
||||
<div class="nick1">${res.inviterNick}</div>
|
||||
<div class="nick2">${res.inviteeNick}</div>
|
||||
@@ -451,12 +461,14 @@ function getRank() {
|
||||
}
|
||||
|
||||
// 自己排名
|
||||
// $('.rank-wrap .myRank .num').html(res.data.meRank.ranking == 0 ? '未上榜' : res.data.meRank.ranking);
|
||||
// $('.rank-wrap .myRank .txbox1 img').attr('src', res.data.meRank.inviterAvatar);
|
||||
// $('.rank-wrap .myRank .txbox2 img').attr('src', res.data.meRank.inviteeAvatar);
|
||||
// $('.rank-wrap .myRank .nick1').text(res.data.meRank.inviterNick.length > 5 ? res.data.meRank.inviterNick.slice(0, 5) + '...' : res.data.meRank.inviterNick)
|
||||
// $('.rank-wrap .myRank .nick2').text(res.data.meRank.inviteeNick.length > 5 ? res.data.meRank.inviteeNick.slice(0, 5) + '...' : res.data.meRank.inviteeNick)
|
||||
// $('.rank-wrap .myRank .score').html(`${res.data.meRank.cpValue > 10000 ? (Math.floor(res.data.meRank.cpValue / 1000) / 10).toFixed(1) + 'w' : res.data.meRank.cpValue}`);
|
||||
if (res.data.meRank) {
|
||||
$('.rank-wrap .myRank .num').html(res.data.meRank.ranking == 0 ? '未上榜' : res.data.meRank.ranking);
|
||||
$('.rank-wrap .myRank .txbox1 img').attr('src', res.data.meRank.inviterAvatar);
|
||||
$('.rank-wrap .myRank .txbox2 img').attr('src', res.data.meRank.inviteeAvatar);
|
||||
$('.rank-wrap .myRank .nick1').text(res.data.meRank.inviterNick.length > 5 ? res.data.meRank.inviterNick.slice(0, 5) + '...' : res.data.meRank.inviterNick)
|
||||
$('.rank-wrap .myRank .nick2').text(res.data.meRank.inviteeNick.length > 5 ? res.data.meRank.inviteeNick.slice(0, 5) + '...' : res.data.meRank.inviteeNick)
|
||||
$('.rank-wrap .myRank .score').html(`${res.data.meRank.cpValue > 10000 ? (Math.floor(res.data.meRank.cpValue / 1000) / 10).toFixed(1) + 'w' : res.data.meRank.cpValue}`);
|
||||
}
|
||||
hideLoading(layerIndex)
|
||||
|
||||
$('.rank-wrap .list ul li').on('click', '.txbox1,.txbox2', function () {
|
||||
@@ -466,7 +478,7 @@ function getRank() {
|
||||
openPerson(uid)
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
} else {
|
||||
toastMsg(res.message)
|
||||
hideLoading(layerIndex)
|
||||
|
Reference in New Issue
Block a user