feat(miniClass): 增加补充姓名提示并更新用户显示字段从nickname改为name

- 将多个页面中用户昵称显示字段从 `nickname` 统一改为 `name`
- 优化课程购买提示逻辑,支持多条信息分次提示
- 更新应用版本号至2.0.36
This commit is contained in:
2026-02-05 09:50:57 +08:00
parent 3a1cffacde
commit 0a37b21824
11 changed files with 91 additions and 69 deletions

View File

@@ -236,8 +236,8 @@
</view>
<view class="textItems flex_box">
<text class="txt555"
v-if="item.student.nickname != null && item.student.nickname != ''">
{{item.student.nickname}}
v-if="item.student.name != null && item.student.name != ''">
{{item.student.name}}
</text>
<text v-else>匿名用户</text>
</view>
@@ -286,10 +286,10 @@
<view class="" v-if="tijiaoTitleId == 2 && false" style="margin: 20rpx 0;">
<radio-group @change="radioChange1" class="flex_box">
<view class="" style="margin-right:20rpx ;">
<radio value="0" />全部同学的</label>
<radio value="0" /><label>全部同学的</label>
</view>
<view class="">
<radio value="1" checked="true" />只看我自己的</label>
<radio value="1" checked="true" /><label>只看我自己的</label>
</view>
</radio-group>
</view>
@@ -309,7 +309,7 @@
</view>
<view class="leve3">
<view class="tips flex_box" v-if="item.zhedie">
<!-- <text>发布者{{item.createUser.nickname != null && item.createUser.nickname != '' ? item.createUser.nickname : '匿名用户'}}</text> -->
<!-- <text>发布者{{item.createUser.name != null && item.createUser.name != '' ? item.createUser.name : '匿名用户'}}</text> -->
<text style="" class="date">日期{{item.createTime}}</text>
</view>
<template v-if="tijiaoTitleId == 2 && isHave">
@@ -403,21 +403,21 @@
<view class="item">
<text class="adminName">班长</text>
<view class="personbox" v-if="admins.monitor.user != null">
<text>{{admins.monitor.user.nickname != null && admins.monitor.user.nickname != '' ? admins.monitor.user.nickname : '匿名用户'}}</text>
<text>{{admins.monitor.user.name != null && admins.monitor.user.name != '' ? admins.monitor.user.name : '匿名用户'}}</text>
</view>
<text v-else>暂未设置</text>
</view>
<view class="item">
<text class="adminName">副班长</text>
<view class="personbox" v-if="admins.dmonitor.user != null">
<text>{{admins.dmonitor.user.nickname != null && admins.dmonitor.user.nickname != '' ? admins.dmonitor.user.nickname : '匿名用户'}}</text>
<text>{{admins.dmonitor.user.name != null && admins.dmonitor.user.name != '' ? admins.dmonitor.user.name : '匿名用户'}}</text>
</view>
<text v-else>暂未设置</text>
</view>
<view class="item"><text class="adminName">学习委员</text>
<view class="personbox" v-if="admins.learner.user != null">
<text>{{admins.learner.user.nickname != null && admins.learner.user.nickname != '' ? admins.learner.user.nickname : '匿名用户'}}</text>
<text>{{admins.learner.user.name != null && admins.learner.user.name != '' ? admins.learner.user.name : '匿名用户'}}</text>
</view>
<text v-else>暂未设置</text>
</view>
@@ -425,7 +425,7 @@
<template v-if="admins.scorer.length > 0">
<view class="arryItemSub" v-for="(item,index) in admins.scorer" :key="index">
<template v-if="item.user != null">
<text>{{item.user.nickname != null && item.user.nickname != '' ? item.user.nickname+'' : '匿名用户,'}}</text>
<text>{{item.user.name != null && item.user.name != '' ? item.user.name+'' : '匿名用户,'}}</text>
<!-- <text>({{item.user.tel}}),</text> -->
</template>
</view>
@@ -505,7 +505,9 @@
<text class="small_btn border_radius_10"
v-if="!submitInfo.photo || submitInfo.photo != '' || submitInfo.photo != null"
@click="onPageJump('/pages/mine/userInfo/persData')"
style="display: block; height: 30px;">{{submitInfo.photo && submitInfo.photo != '' && submitInfo.photo != null ? '去修改' : '去上传'}}</text>
style="display: block; height: 30px;"
>
{{submitInfo.photo && submitInfo.photo != '' && submitInfo.photo != null ? '去修改' : '去上传'}}
</text>
</view>
</view>
@@ -963,13 +965,33 @@
.then(async (res) => {
console.log('课程购买情况',res);
if (res.code == 0) {
if (res.msg != '') {
msg = res.msg
var outputStr = await this.convertToHalfWidth(res.msg)
uni.showModal({
title: '提示',
content: `${outputStr}课程没有购买,请尽快购买班级内教学需要的课程,逾期您将被系统自动踢出班级,感谢您的理解和支持`
})
if (res.res && res.res.length > 0) {
const msgArr = res.res
for (const item of msgArr) {
const outputStr = await this.convertToHalfWidth(item)
const isPass = await new Promise(resolve => {
uni.showModal({
title: '提示',
content: `${outputStr}`,
success: (res) => {
if (res.confirm) {
resolve(true)
} else {
resolve(false)
}
}
})
})
if (!isPass) {
break
}
}
// msg = res.msg
// var outputStr = await this.convertToHalfWidth(res.msg)
// uni.showModal({
// title: '提示',
// content: `${outputStr}`
// })
}
}
}).catch(e => {
@@ -2260,7 +2282,7 @@ uni.navigateTo({
color: #999;
}
.date {}
// .date {}
@@ -2688,7 +2710,7 @@ uni.navigateTo({
}
}
.optionsBox {}
// .optionsBox {}
.btn_box_certificate {
margin-top: 70rpx;
@@ -2713,13 +2735,13 @@ uni.navigateTo({
}
.userinfoPup {
.tips {
// .item{justify-content: space-around;}
}
// .tips {
// // .item{justify-content: space-around;}
// }
.small_btn {
color: #55aaff;
border: #55aaff 1px solid;
}
}
</style>
</style>