1:修改家族展示续签按钮位置
2:修改购买爵位前,先请求一次接口 3:修改所有CP更改为心动 4:修改挚友,初始获取数据变更成40条 5:未实名认证不能进行歌手认证
This commit is contained in:
@@ -128,7 +128,16 @@ class BosomFriendAdapter(data: MutableList<MultiItemEntity>) : BaseMultiItemQuic
|
||||
|
||||
if (remainingSeconds > 0) {
|
||||
val days = remainingSeconds / (24 * 60 * 60)
|
||||
val hours = (remainingSeconds % (24 * 60 * 60)) / (60 * 60)
|
||||
val remainingHours = (remainingSeconds % (24 * 60 * 60)) / (60 * 60)
|
||||
val hasRemainingMinutes = (remainingSeconds % (60 * 60)) > 0
|
||||
|
||||
val hours = if (days > 0) {
|
||||
remainingHours
|
||||
} else {
|
||||
// 当天数小于等于0时,如果有剩余分钟,则小时数+1
|
||||
if (hasRemainingMinutes) remainingHours + 1 else remainingHours
|
||||
}.coerceAtLeast(1) // 确保至少显示1小时
|
||||
|
||||
val timeText = if (days > 0) {
|
||||
"${days}天${hours}小时"
|
||||
} else {
|
||||
@@ -136,6 +145,7 @@ class BosomFriendAdapter(data: MutableList<MultiItemEntity>) : BaseMultiItemQuic
|
||||
}
|
||||
holder.setText(R.id.tv_cp_num, timeText)
|
||||
}
|
||||
|
||||
} catch (e: NumberFormatException) {
|
||||
// 时间戳格式错误
|
||||
holder.setVisible(R.id.tv_cp_num, false)
|
||||
|
||||
Reference in New Issue
Block a user