|
@@ -37,12 +37,14 @@
|
|
|
></svg-icon>
|
|
|
<el-input
|
|
|
v-model="danmuValue"
|
|
|
- :readonly="!isDanmu"
|
|
|
+ :readonly="!isDanmu || !userMessage"
|
|
|
placeholder="输入弹幕"
|
|
|
@blur="danmuValue = danmuValue.trim()"
|
|
|
maxlength="100"
|
|
|
></el-input>
|
|
|
- <a @click="sendMsg" :class="[isDanmu ? 'active' : 'not-active']"
|
|
|
+ <a
|
|
|
+ @click="sendMsg"
|
|
|
+ :class="[isDanmu && userMessage ? 'active' : 'not-active']"
|
|
|
>发送弹幕</a
|
|
|
>
|
|
|
</div>
|
|
@@ -391,12 +393,18 @@ export default {
|
|
|
},
|
|
|
// 添加播放记录
|
|
|
addPlayRecord() {
|
|
|
- let MethodName =
|
|
|
- "/CourseServer/Client/ReadingManager/AddPlayRecord_LBCourseCSItem";
|
|
|
- let data = {
|
|
|
- cs_item_id: this.lessonCatalog[this.lessonIndex].id,
|
|
|
- };
|
|
|
- getLogin(MethodName, data).then(() => {});
|
|
|
+ if (this.userMessage) {
|
|
|
+ let MethodName =
|
|
|
+ "/CourseServer/Client/ReadingManager/AddPlayRecord_LBCourseCSItem";
|
|
|
+ let data = {
|
|
|
+ cs_item_id: this.lessonCatalog[this.lessonIndex].id,
|
|
|
+ };
|
|
|
+ getLogin(MethodName, data)
|
|
|
+ .then(() => {})
|
|
|
+ .catch(() => {
|
|
|
+ this.$message.warning("请先登录");
|
|
|
+ });
|
|
|
+ }
|
|
|
},
|
|
|
// 获取弹幕列表
|
|
|
getBarrageList() {
|