Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
提交
打开侧边栏
com.pica.cloud.education.frontend
pica.cloud.web-education-admin
提交
095630c5
提交
095630c5
编写于
7月 08, 2020
作者:
bo.dang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
编辑直播回显
上级
f03273bb
变更
2
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
66 行增加
和
35 行删除
+66
-35
create-live.vue
src/views/yqrange/create-live.vue
+64
-35
live-manage.vue
src/views/yqrange/live-manage.vue
+2
-0
未找到文件。
src/views/yqrange/create-live.vue
浏览文件 @
095630c5
...
...
@@ -37,6 +37,19 @@
<span
class=
"word-num"
>
{{
(
formData
.
name
).
replace
(
/
\s
+/g
,
""
).
length
}}
/20
</span>
</el-col>
</el-form-item>
<el-form-item
label=
"是否公开"
prop=
"scope"
>
<el-radio-group
v-model=
"formData.scope"
size=
"small"
@
change=
"changeScope"
>
<el-radio
label=
"1"
>
否(仅限圈内人观看)
</el-radio>
<el-radio
label=
"2"
>
是(任何人可观看)
</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item
label=
"是否收集用户信息"
prop=
"infoCollect"
v-if=
"isCollectShow"
>
<el-radio-group
v-model=
"formData.infoCollect"
size=
"small"
>
<el-radio
label=
"0"
>
否
</el-radio>
<el-radio
label=
"1"
>
是(收集姓名等信息)
</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item
label=
"直播方式"
prop=
"streamType"
>
<el-radio-group
v-model=
"formData.streamType"
size=
"small"
@
change=
"changeStreamType"
>
<el-radio
label=
"1"
:disabled=
"styleEditFlag"
>
网页直播
</el-radio>
...
...
@@ -68,20 +81,6 @@
</el-form-item>
<el-form-item
label=
"是否公开"
prop=
"scope"
>
<el-radio-group
v-model=
"formData.scope"
size=
"small"
@
change=
"changeScope"
>
<el-radio
label=
"1"
>
否(仅限圈内人观看)
</el-radio>
<el-radio
label=
"2"
>
是(任何人可观看)
</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item
label=
"是否收集用户信息"
prop=
"infoCollect"
v-if=
"isCollectShow"
>
<el-radio-group
v-model=
"formData.infoCollect"
size=
"small"
>
<el-radio
label=
"0"
>
否
</el-radio>
<el-radio
label=
"1"
>
是(收集姓名等信息)
</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item
label=
"直播开始时间"
prop=
"openTime"
>
<el-col
:span=
"6"
>
<el-date-picker
...
...
@@ -99,7 +98,7 @@
<el-col
:span=
"12"
>
<div
style=
"color:#666666;font-size:10px;"
>
直播图片可选择仅文字版,仅图片版或文字版+图片版
</div>
<el-input
type=
"textarea"
v-model=
"formData.textContent"
placeholder=
"请输入直播简介"
maxlength=
"300"
rows=
"4"
style=
"width:80%;"
></el-input>
<span
class=
"word-num"
>
{{
(
formData
.
textContent
).
replace
(
/
\s
+/g
,
""
).
length
}}
/300
</span>
<span
class=
"word-num"
>
{{
(
formData
.
textContent
).
replace
(
/
\s
+/g
,
""
).
length
}}
/300
</span>
<div
style=
"color:#666666;font-size:12px;"
>
文字版
</div>
</el-col>
<!--
<el-col
:span=
"12"
class=
"basic-item-icon"
style=
"margin-top:35px;"
>
-->
...
...
@@ -422,6 +421,7 @@
username: ''
}] // 嘉宾
},
introTextNum: 0,
// imgUrl1: '',
imgUrl1More: {},
guestErrFlag: false,
...
...
@@ -561,7 +561,7 @@
}
}).catch((error) => {
this.$message({
message:
error
,
message:
"
请重试
"
,
type: 'error'
});
})
...
...
@@ -799,15 +799,27 @@
// 校验拉流地址
checkpullStream(){
let flag = true;
if(this.pullFlag){
if(this.formData.pullStreamRtmp == ""){
this.$message.warning("
请输入
APP
拉流地址
");
flag = false;
if(this.formData.streamType == "
2
"){
// 公开直播,两个拉流地址都需要
if(this.formData.scope == "
2
"){
if(this.formData.pullStreamRtmp == ""){
this.$message.warning("
请输入
APP
拉流地址
");
flag = false;
}
if(this.formData.pullStreamHttp == ""){
this.$message.warning("
请输入
H5
拉流地址
");
flag = false;
}
}
if(this.formData.pullStreamHttp == ""){
this.$message.warning("
请输入
H5
拉流地址
");
flag = false;
else {
if(this.formData.pullStreamRtmp == "" && this.formData.pullStreamHttp == ""){
this.$message.warning("
请输入
APP
拉流地址或
H5
拉流地址
");
flag = false;
}
}
}
return flag;
},
...
...
@@ -817,8 +829,9 @@
// console.log(this.formData.rtcIntroduces[1].content);
let flag = true;
if(this.formData.textContent == ""
& this.formData.imageContent == ""){
// if(this.formData.textContent == ""
// & this.formData.imageContent == ""){
if(this.formData.rtcIntroduces == null || this.formData.rtcIntroduces.length == 0){
flag = false;
this.$message.error("
直播简介中可选择仅文字版,仅图片版或文字版
+
图片版
");
}
...
...
@@ -986,20 +999,32 @@
this.isCollectShow = true;
}
this.formData.infoCollect = String(this.formData.infoCollect);
this.$set(this.formData, 'textContent', "");
if(this.formData.rtcIntroduces != null){
for(let i=0;i<this.formData.rtcIntroduces.length;i++) {
if(this.formData.rtcIntroduces[i].type == "
1
"){
// this.formData.textContent = this.formData.rtcIntroduces[i].content;
this.$set(this.formData, 'textContent', this.formData.rtcIntroduces[i].content);
break;
}
else if(this.formData.rtcIntroduces[i].type == "
2
"){
// this.formData.imageContent = this.formData.rtcIntroduces[i].content;
this.$set(this.formData, 'imageContent', this.formData.rtcIntroduces[i].content);
}
//
else if(this.formData.rtcIntroduces[i].type == "
2
"){
//
// this.formData.imageContent = this.formData.rtcIntroduces[i].content;
//
this.$set(this.formData, 'imageContent', this.formData.rtcIntroduces[i].content);
//
}
}
}
// (formData.textContent).replace(/
\
s+/g,"").length
// if(this.formData.textContent == ""){
// this.introTextNum = 0;
// }
// else {
// this.introTextNum
// }
// 设置讲师
if(this.formData.lecturers
!= null
){
if(this.formData.lecturers
.length > 0
){
// this.formData.lecturesUserName = this.formData.lecturers[0].username;
// this.formData.lecturesPhone = this.formData.lecturers[0].phone;
this.$set(this.formData, 'lecturesUserName', this.formData.lecturers[0].username);
...
...
@@ -1016,9 +1041,11 @@
}
// 直播简介文字版
// this.formData.rtcIntroduces[0].type = 1;
// this.formData.rtcIntroduces[0].content = this.formData.textContent;
// // 直播简介图片版
if(this.formData.textContent != null && this.formData.textContent != ""){
this.formData.rtcIntroduces.push({type:1,content:this.formData.textContent});
}
// this.formData.rtcIntroduces[0].content = this.formData.textContent;
// 直播简介图片版
// this.formData.rtcIntroduces[1].type = 2;
// this.formData.rtcIntroduces[1].content = this.formData.imageContent;
// 设置讲师
...
...
@@ -1029,8 +1056,10 @@
//
// this.formData.lecturers.push({username: this.formData.lecturesUserName, phone: this.formData.lecturesPhone});
// }
this.formData.lecturers[0].username = this.formData.lecturesUserName;
this.formData.lecturers[0].phone = this.formData.lecturesPhone;
if(this.formData.lecturesUserName){
this.formData.lecturers[0].username = this.formData.lecturesUserName;
this.formData.lecturers[0].phone = this.formData.lecturesPhone;
}
},
complete(formName) {
...
...
src/views/yqrange/live-manage.vue
浏览文件 @
095630c5
...
...
@@ -821,6 +821,8 @@ export default {
liveScope
:
res
.
data
.
pageContents
[
i
].
scope
,
liveStatus
:
res
.
data
.
pageContents
[
i
].
liveStatus
,
streamType
:
res
.
data
.
pageContents
[
i
].
streamType
,
playbackSetFlag
:
res
.
data
.
pageContents
[
i
].
playbackSetFlag
,
canPlayback
:
res
.
data
.
pageContents
[
i
].
canPlayback
,
createTime
:
res
.
data
.
pageContents
[
i
].
createdTime
,
startTime
:
res
.
data
.
pageContents
[
i
].
openTime
,
endTime
:
res
.
data
.
pageContents
[
i
].
endTime
,
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录