Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
T
techbook
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
front-end-dev
techbook
Commits
3a9d4cf2
Commit
3a9d4cf2
authored
Jul 09, 2020
by
zhangyanni
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
92bfa037
d2f73d6f
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
275 additions
and
12 deletions
+275
-12
en.js
src/common/lang/en.js
+17
-0
zh.js
src/common/lang/zh.js
+17
-0
router.js
src/router.js
+5
-0
eventdetail.vue
src/views/findeventpage/eventdetail.vue
+56
-7
eventlive.vue
src/views/findeventpage/eventlive.vue
+29
-0
eventpage.vue
src/views/findeventpage/eventpage.vue
+40
-2
index.vue
src/views/index/pages/index.vue
+30
-0
api.js
src/views/publishactivity/api/api.js
+10
-0
proactivity.vue
src/views/publishactivity/proactivity.vue
+38
-3
pubactivities.vue
src/views/publishactivity/pubactivities.vue
+33
-0
No files found.
src/common/lang/en.js
View file @
3a9d4cf2
...
...
@@ -2021,6 +2021,23 @@ module.exports = {
activearea
:
'Active area'
,
},
//直播
livedata
:{
setlive
:
"Live broadcast settings"
,
islive
:
"Live broadcast or not"
,
viewrights
:
"Viewing rights"
,
required
:
'Registration required'
,
norequired
:
'No registration is required'
,
on
:
'on'
,
off
:
'off'
,
plcustomer
:
'Please contact customer service for live address'
,
plvhall
:
'Please enter the vhall key or live address link'
,
pushinformation
:
'Push information'
,
start
:
'Start'
,
finish
:
'Finish'
,
register
:
'Please register first'
,
},
//行业报告
industryjson
:{
share1
:
'Share to WeChat Moments'
,
...
...
src/common/lang/zh.js
View file @
3a9d4cf2
...
...
@@ -2121,6 +2121,23 @@ module.exports = {
activearea
:
'活动区域'
,
},
//直播
livedata
:{
setlive
:
"直播设置"
,
islive
:
"是否开放直播"
,
viewrights
:
"观看权限"
,
required
:
'需报名'
,
norequired
:
'不需要报名'
,
on
:
'支持'
,
off
:
'不支持'
,
plcustomer
:
'直播地址请联系客服获取'
,
plvhall
:
'请输入微吼key或直播地址链接'
,
pushinformation
:
'开播提醒'
,
start
:
'开播'
,
finish
:
'关闭直播'
,
register
:
'请先报名'
,
},
//行业报告
industryjson
:{
share1
:
'分享到微信朋友圈'
,
...
...
src/router.js
View file @
3a9d4cf2
...
...
@@ -200,6 +200,11 @@ const router = new Router({
component
:
resolve
=>
require
([
'views/findeventpage/eventdetail.vue'
],
resolve
).
catch
(
routerUtils
.
catchImport
),
meta
:
{
title
:
'活动详情'
}
},
{
path
:
'/eventlive'
,
component
:
resolve
=>
require
([
'views/findeventpage/eventlive.vue'
],
resolve
).
catch
(
routerUtils
.
catchImport
),
meta
:
{
title
:
'活动直播'
}
},
{
path
:
'/eventsuccess'
,
component
:
resolve
=>
require
([
'views/findeventpage/eventsuccess.vue'
],
resolve
).
catch
(
routerUtils
.
catchImport
),
...
...
src/views/findeventpage/eventdetail.vue
View file @
3a9d4cf2
...
...
@@ -27,12 +27,31 @@
<div
class=
"gendisplay citystr"
v-if=
"eventdata.channelType == 3"
>
<p><i
class=
"iconfont icon-dingwei"
></i>
{{
eventdata
.
channelAddress
}}
</p>
</div>
<div
v-if=
"userInfo&&userInfo.empId!=eventdata.createdBy||!userInfo"
style=
"text-align: center;"
>
<el-button
type=
"primary"
round
style=
"width:240px;"
v-if=
"eventdata.activityState==2&&!eventdata.isApply"
@
click=
"handleApply(eventdata)"
>
{{
$t
(
'activityInfo.freeApply'
)
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:240px;"
disabled
v-if=
"eventdata.channelType!=4&&eventdata.activityState==2&&eventdata.isApply"
>
{{
$t
(
"activityInfo.hasApply"
)
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:240px;"
v-if=
"eventdata.channelType==4&&eventdata.activityState==2&&eventdata.isApply"
@
click=
"handleToSuccess"
>
{{
$t
(
"commonTitle.vipLookTitle"
)
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:240px;"
disabled
v-if=
"eventdata.activityState>2"
>
{{
eventdata
.
activityState
==
4
?
$t
(
"activityInfo.hasFilled"
):
eventdata
.
activityState
==
3
?
$t
(
"activityInfo.applyEnd"
):
eventdata
.
activityState
==
5
?
$t
(
"activityInfo.activityEnd"
):
""
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:240px;"
v-if=
"eventdata.activityState==1"
>
{{
$t
(
"activityInfo.activityNoBegin"
)
}}
</el-button>
<div
style=
"text-align: center;"
>
<span
v-if=
"userInfo&&userInfo.empId!=eventdata.createdBy||!userInfo"
>
<el-button
type=
"primary"
round
style=
"width:130px;"
v-if=
"eventdata.activityState==2&&!eventdata.isApply"
@
click=
"handleApply(eventdata)"
>
{{
$t
(
'activityInfo.freeApply'
)
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:130px;"
disabled
v-if=
"eventdata.channelType!=4&&eventdata.activityState==2&&eventdata.isApply"
>
{{
$t
(
"activityInfo.hasApply"
)
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:130px;"
v-if=
"eventdata.channelType==4&&eventdata.activityState==2&&eventdata.isApply"
@
click=
"handleToSuccess"
>
{{
$t
(
"commonTitle.vipLookTitle"
)
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:160px;"
disabled
v-if=
"eventdata.activityState>2"
>
{{
eventdata
.
activityState
==
4
?
$t
(
"activityInfo.hasFilled"
):
eventdata
.
activityState
==
3
?
$t
(
"activityInfo.applyEnd"
):
eventdata
.
activityState
==
5
?
$t
(
"activityInfo.activityEnd"
):
""
}}
</el-button>
<el-button
type=
"primary"
round
style=
"width:160px;"
v-if=
"eventdata.activityState==1"
>
{{
$t
(
"activityInfo.activityNoBegin"
)
}}
</el-button>
</span>
<span
style=
"margin-left: 15px;"
v-if=
"eventdata.hasLive == 1"
@
click=
"openeventlive(eventdata)"
>
<el-button
v-if=
"eventdata.baseLive.liveState==0"
type=
"primary"
round
style=
"width: 130px;font-size: 14px;"
>
<i
class=
"iconfont icon-zhibo"
style=
"font-size: 14px;"
></i>
{{
$t
(
'activityInfo.liveNotStart'
)
}}
</el-button>
<el-button
v-if=
"eventdata.baseLive.liveState==1"
type=
"warning"
round
style=
"width: 130px;font-size: 14px;"
>
<i
class=
"iconfont icon-zhibo"
style=
"font-size: 14px;"
></i>
{{
$t
(
'activityInfo.living'
)
}}
</el-button>
<el-button
v-if=
"eventdata.baseLive.liveState==2&&eventdata.baseLive.liveBack == 0"
type=
"primary"
round
style=
"width: 130px;font-size: 14px;"
>
<i
class=
"iconfont icon-zhibo"
style=
"font-size: 14px;"
></i>
{{
$t
(
'activityInfo.liveBack'
)
}}
</el-button>
<el-button
v-if=
"eventdata.baseLive.liveState==2&&eventdata.baseLive.liveBack == 1"
type=
"info"
round
style=
"width: 130px;font-size: 14px;"
>
{{
$t
(
'activityInfo.liveHasEnd'
)
}}
</el-button>
</span>
</div>
<div
v-if=
"eventdata.activityState!=5"
@
click=
"handleReturn"
style=
"color:#3F3F53;text-align: center;line-height: 60px;cursor: pointer;"
>
<i
class=
"iconfont icon-fenxiang"
style=
"margin-right: 10px;"
></i>
{{
$t
(
'activityInfo.shareButton'
)
}}
...
...
@@ -62,6 +81,10 @@
<qrCmpt
:url=
"url"
@
sendVisible=
"isVueQrVisible"
></qrCmpt>
</div>
<!-- 快速登录-->
<expertVisible
ref=
"login"
:registerType=
"64"
></expertVisible>
<signupbar
:tabName=
"activeName"
:detailInfo=
"eventdata"
:secondStepInfo=
"secondStepInfo"
@
cancelVisible=
"cancelVisible"
:applyVisible=
"applyVisible"
v-if=
"applyVisible"
></signupbar>
</div>
</
template
>
...
...
@@ -70,6 +93,7 @@
import
api
from
"./api/api"
;
import
signupbar
from
"./signupbar"
;
import
qrCmpt
from
"../../components/common/qrcodeCmpt"
;
import
expertVisible
from
"../../components/login/quicklogin"
;
export
default
{
name
:
"eventdetail"
,
data
()
{
...
...
@@ -88,7 +112,7 @@
}
},
components
:{
signupbar
,
qrCmpt
signupbar
,
qrCmpt
,
expertVisible
},
beforeRouteEnter
(
to
,
from
,
next
)
{
next
(
vm
=>
{
// 这里的vm指的就是vue实例,可以用来当做this使用
...
...
@@ -101,6 +125,31 @@
},
methods
:{
//打开直播
openeventlive
(
row
){
if
(
row
.
baseLive
.
liveState
!=
0
){
if
(
!
this
.
publicFun
.
getCookie
(
"userInfo"
)){
this
.
$refs
.
login
.
isexpertVisible
();
return
}
let
liveUrl
=
row
.
baseLive
.
liveUrl
.
substring
(
row
.
baseLive
.
liveUrl
.
lastIndexOf
(
'/'
)
+
1
);
if
(
this
.
userInfo
&&
this
.
userInfo
.
empId
==
row
.
createdBy
){
if
(
row
.
baseLive
.
liveState
==
1
||
row
.
baseLive
.
liveBack
==
0
){
window
.
open
(
this
.
publicFun
.
getCurrentHrefEnv
()
+
"#/eventlive?id="
+
liveUrl
);
}
}
else
{
if
(
row
.
baseLive
.
livePowers
==
0
&&
row
.
activityState
==
2
&&!
row
.
isApply
){
this
.
$message
.
error
(
this
.
$t
(
'activityInfo.applyFirst'
));
}
else
if
(
row
.
baseLive
.
livePowers
==
0
&&
row
.
activityState
==
5
&&!
row
.
isApply
){
this
.
$message
.
error
(
this
.
$t
(
'activityInfo.applyEndTitle'
));
}
else
{
if
(
row
.
baseLive
.
liveState
==
1
||
row
.
baseLive
.
liveState
==
2
&&
row
.
baseLive
.
liveBack
==
0
){
window
.
open
(
this
.
publicFun
.
getCurrentHrefEnv
()
+
"#/eventlive?id="
+
liveUrl
);
}
}
}
}
},
//二维码
isVueQrVisible
(
data
){
this
.
vueQrVisible
=
data
;
...
...
src/views/findeventpage/eventlive.vue
0 → 100644
View file @
3a9d4cf2
<
template
>
<div
style=
"padding-top: 60px;"
>
<iframe
name =
"child"
id =
"child"
src=
"live.html"
frameborder=
"0"
scrolling=
"no"
style=
"position:related;top: 2.8px;left: 0px;width: 100%;height: 100vh;border: medium none;"
></iframe>
</div>
</
template
>
<
script
>
window
.
onload
=
function
(){
var
_iftameBody
=
document
.
getElementById
(
'child'
).
contentWindow
.
document
.
getElementsByTagName
(
"body"
)[
0
];
var
_iframe
=
document
.
getElementById
(
'child'
).
contentWindow
.
document
.
getElementsByTagName
(
"iframe"
)[
0
];
//get iframe下的id
_iframe
.
src
=
"live.html?id="
+
this
.
$route
.
query
.
disId
;
_iframe
.
style
.
width
=
"100%"
;
//修改样式
_iframe
.
style
.
height
=
"calc(100vh - 30px)"
;
//修改样式
_iftameBody
.
style
.
margin
=
0
;
};
export
default
{
name
:
"live"
,
beforeDestroy
()
{
// 在组件生命周期结束的时候销毁。
document
.
getElementsByTagName
(
"body"
)[
0
].
style
.
overflow
=
"auto"
;
},
mounted
()
{
document
.
getElementsByTagName
(
"body"
)[
0
].
style
.
overflow
=
"hidden"
;
}
};
</
script
>
<
style
scoped
>
</
style
>
\ No newline at end of file
src/views/findeventpage/eventpage.vue
View file @
3a9d4cf2
...
...
@@ -10,7 +10,15 @@
<p
class=
"content_img"
@
click=
"$router.push(
{path:'/eventdetail',query:{id:item.channelId,ismyevent:0}})">
<span
class=
"indeximgInfo"
style=
"border-radius: 0;background-size: cover;"
:style=
"
{backgroundImage:'url('+(item.channelPic?item.channelPic:'')+')'}">
</span>
</p>
<p
class=
"ellipsisFont2"
style=
"height: 40px;"
@
click=
"$router.push(
{path:'/eventdetail',query:{id:item.channelId,ismyevent:0}})">
{{
item
.
channelTitle
}}
</p>
<p
class=
"ellipsisFont2"
style=
"height: 40px;"
>
<span
v-if=
"item.hasLive == 1"
@
click=
"openeventlive(item)"
style=
"display: inline-block;background: #5d78ff;padding: 0 10px 0 30px;color: #FFFFFF;font-size: 12px;position: relative;border-radius: 3px;"
>
<i
class=
"iconfont icon-zhibo"
style=
"font-size: 16px;position: absolute;left: 8px;top: 0px;"
></i>
{{
item
.
baseLive
.
liveState
==
0
?
$t
(
'activityInfo.liveTitle'
):
item
.
baseLive
.
liveState
==
1
?
$t
(
'activityInfo.living'
):
$t
(
'activityInfo.liveTitle'
)
}}
</span>
<span
@
click=
"$router.push(
{path:'/eventdetail',query:{id:item.channelId,ismyevent:0}})">
{{
item
.
channelTitle
}}
</span>
</p>
<p
class=
"ellipsisFont1"
@
click=
"$router.push(
{path:'/eventdetail',query:{id:item.channelId,ismyevent:0}})">
{{
$t
(
'activityInfo.timeZone'
)
}}
:
{{
item
.
versionType
==
0
?
$t
(
'pubactivities.beijingtime'
):
item
.
timeZoneName
}}
</p>
<span
@
click=
"$router.push(
{path:'/eventdetail',query:{id:item.channelId,ismyevent:0}})">
{{
item
.
channelStartTime
}}
-
{{
item
.
channelEndTime
}}
</span>
<span
@
click=
"$router.push(
{path:'/eventdetail',query:{id:item.channelId,ismyevent:0}})">
<i
style=
"font-size: 12px;"
v-if=
"item.channelCityStr"
class=
"iconfont icon-dingwei"
></i>
{{
item
.
channelCityStr
}}
</span>
...
...
@@ -49,6 +57,9 @@
</div>
<signupbar
:detailInfo=
"detailInfo"
:tabName=
"activeName"
:secondStepInfo=
"secondStepInfo"
@
cancelVisible=
"cancelVisible"
:applyVisible=
"applyVisible"
v-if=
"applyVisible"
></signupbar>
<!-- 快速登录-->
<expertVisible
ref=
"login"
:registerType=
"64"
></expertVisible>
</div>
</
template
>
...
...
@@ -56,6 +67,7 @@
import
api
from
"./api/api"
;
import
signupbar
from
"./signupbar"
;
import
regionChoice
from
"../../components/index/regionchoice"
;
import
expertVisible
from
"../../components/login/quicklogin"
;
export
default
{
name
:
"eventpage"
,
data
()
{
...
...
@@ -79,7 +91,8 @@
},
components
:{
regionChoice
,
signupbar
signupbar
,
expertVisible
},
computed
:
{
...
...
@@ -94,6 +107,31 @@
handleSizeChange
(
val
)
{
this
.
searchs
.
pageSize
=
val
;
},
//打开直播
openeventlive
(
row
){
if
(
row
.
baseLive
.
liveState
!=
0
){
if
(
!
this
.
publicFun
.
getCookie
(
"userInfo"
)){
this
.
$refs
.
login
.
isexpertVisible
();
return
}
let
liveUrl
=
row
.
baseLive
.
liveUrl
.
substring
(
row
.
baseLive
.
liveUrl
.
lastIndexOf
(
'/'
)
+
1
);
if
(
this
.
userInfo
&&
this
.
userInfo
.
empId
==
row
.
createdBy
){
if
(
row
.
baseLive
.
liveState
==
1
||
row
.
baseLive
.
liveBack
==
0
){
window
.
open
(
this
.
publicFun
.
getCurrentHrefEnv
()
+
"#/eventlive?id="
+
liveUrl
);
}
}
else
{
if
(
row
.
baseLive
.
livePowers
==
0
&&
row
.
activityState
==
2
&&
row
.
isJoin
==
2
){
this
.
$message
.
error
(
this
.
$t
(
'activityInfo.applyFirst'
));
}
else
if
(
row
.
baseLive
.
livePowers
==
0
&&
row
.
activityState
==
5
&&
row
.
isJoin
==
2
){
this
.
$message
.
error
(
this
.
$t
(
'activityInfo.applyEndTitle'
));
}
else
{
if
(
row
.
baseLive
.
liveState
==
1
){
window
.
open
(
this
.
publicFun
.
getCurrentHrefEnv
()
+
"#/eventlive?id="
+
liveUrl
);
}
}
}
}
},
resourcesdata
(){
let
keyName
=
'&keyName='
+
this
.
searchs
.
keyName
;
let
channelCity
=
'&channelCity='
+
this
.
searchs
.
channelCity
;
...
...
src/views/index/pages/index.vue
View file @
3a9d4cf2
...
...
@@ -183,6 +183,12 @@
<span
v-if=
"item.activityState == 3"
>
{{
$t
(
'activityInfo.applyEnd'
)
}}
</span>
<span
style=
"color: #FF5D5D"
v-if=
"item.activityState == 4&&item.isJoin==2"
>
{{
$t
(
'activityInfo.hasFilled'
)
}}
</span>
<span
style=
"color: #9197B4"
v-if=
"item.activityState == 5&&item.isJoin==2"
>
{{
$t
(
'activityInfo.activityEnd'
)
}}
</span>
<span
style=
"margin-left: 15px;"
v-if=
"item.hasLive == 1"
@
click=
"openeventlive(item)"
>
<el-button
type=
"primary"
round
size=
"mini"
style=
"width: 110px;font-size: 14px;"
>
<i
class=
"iconfont icon-zhibo"
style=
"font-size: 14px;"
></i>
{{
item
.
baseLive
.
liveState
==
0
?
$t
(
'activityInfo.liveTitle'
):
item
.
baseLive
.
liveState
==
1
?
$t
(
'activityInfo.living'
):
$t
(
'activityInfo.liveTitle'
)
}}
</el-button>
</span>
</p>
</div>
</div>
...
...
@@ -593,6 +599,30 @@
};
},
methods
:
{
//打开直播
openeventlive
(
row
){
if
(
row
.
baseLive
.
liveState
!=
0
){
if
(
!
this
.
publicFun
.
getCookie
(
"userInfo"
)){
this
.
$refs
.
login
.
isexpertVisible
();
return
}
if
(
this
.
userInfo
&&
this
.
userInfo
.
empId
==
row
.
createdBy
){
if
(
row
.
baseLive
.
liveState
==
1
||
row
.
baseLive
.
liveBack
==
0
){
window
.
open
(
this
.
publicFun
.
getCurrentHrefEnv
()
+
"#/eventlive?id="
+
liveUrl
);
}
}
else
{
if
(
row
.
baseLive
.
livePowers
==
0
&&
row
.
activityState
==
2
&&
row
.
isJoin
==
2
){
this
.
$message
.
error
(
this
.
$t
(
'activityInfo.applyFirst'
));
}
else
if
(
row
.
baseLive
.
livePowers
==
0
&&
row
.
activityState
==
5
&&
row
.
isJoin
==
2
){
this
.
$message
.
error
(
this
.
$t
(
'activityInfo.applyEndTitle'
));
}
else
{
if
(
row
.
baseLive
.
liveState
==
1
||
row
.
baseLive
.
liveBack
==
0
){
window
.
open
(
this
.
publicFun
.
getCurrentHrefEnv
()
+
"#/eventlive?id="
+
liveUrl
);
}
}
}
}
},
//文章详情
gocontentdetail
(
row
)
{
globalMsg
.
$emit
(
'maiDianFunc'
,
({
type
:
'report-article-index'
,
articleId
:
row
.
contentId
}));
...
...
src/views/publishactivity/api/api.js
View file @
3a9d4cf2
...
...
@@ -51,6 +51,16 @@ export default {
return
api
.
fetchLoadingPostex
(
'/base/activity/exportApplyList'
,
params
);
},
//直播状态切换
processLiveState
(
id
,
state
)
{
return
api
.
fetchGet
(
'/base/activity/processLiveState?channelId='
+
id
+
'&liveState='
+
state
);
},
//直播通知
callLiveMessage
(
id
)
{
return
api
.
fetchGet
(
'/base/activity/callLiveMessage?channelId='
+
id
);
},
//时区
getTimeZoneList
(
)
{
return
api
.
fetchGet
(
'/base/time/getTimeZoneList'
);
...
...
src/views/publishactivity/proactivity.vue
View file @
3a9d4cf2
...
...
@@ -147,9 +147,28 @@
</div>
</div>
<div
class=
"btodiv"
>
<p>
直播设置
</p>
<p>
{{$t('livedata.setlive')}}
</p>
<div
style=
"margin-top: 20px"
>
添加直播
<el-form
:inline=
"true"
label-width=
"180px"
:model=
"formData"
:rules=
"rulesInfo"
ref=
"formData"
class=
"contnetform180"
>
<el-form-item
:label=
"$t('livedata.islive')+':'"
style=
"width: 100%;"
>
<el-radio
@
change=
"ishasLive(formData.hasLive)"
v-model=
"formData.hasLive"
:label=
"0"
>
否
</el-radio>
<el-radio
@
change=
"ishasLive(formData.hasLive)"
v-model=
"formData.hasLive"
:label=
"1"
>
是
</el-radio>
</el-form-item>
<div
v-if=
"formData.hasLive == 1"
>
<el-form-item
:label=
"$t('livedata.viewrights')+':'"
style=
"width: 100%;"
>
<el-radio
v-model=
"formData.baseLive.livePowers"
:label=
"0"
>
{{$t('livedata.required')}}
</el-radio>
<el-radio
v-model=
"formData.baseLive.livePowers"
:label=
"1"
>
{{$t('livedata.norequired')}}
</el-radio>
</el-form-item>
<el-form-item
:label=
"$t('activityInfo.liveBack')+':'"
style=
"width: 100%;"
>
<el-radio
v-model=
"formData.baseLive.liveBack"
:label=
"0"
>
{{$t('livedata.on')}}
</el-radio>
<el-radio
v-model=
"formData.baseLive.liveBack"
:label=
"1"
>
{{$t('livedata.off')}}
</el-radio>
</el-form-item>
<el-form-item
:label=
"$t('Otherjson.activitytitle')+':'"
prop=
"baseLive.liveUrl"
style=
"width: 100%;"
>
<p>
{{$t('livedata.plcustomer')}}
</p>
<el-input
v-model=
"formData.baseLive.liveUrl"
maxlength=
"100"
:placeholder=
"$t('livedata.plvhall')"
style=
"width: 450px;height: 40px"
></el-input>
</el-form-item>
</div>
</el-form>
</div>
</div>
<div
v-if=
"formData.channelState!=2&&formData.channelState!=3"
>
...
...
@@ -329,6 +348,7 @@
channelProvince
:
[{
required
:
true
,
message
:
this
.
$t
(
'pubactivities.plarea'
),
trigger
:
'change'
}],
personMax
:
[{
required
:
true
,
message
:
this
.
$t
(
'pubactivities.plmaxnum'
),
trigger
:
'blur'
}],
channelAddress
:
[{
required
:
true
,
message
:
this
.
$t
(
'pubactivities.pleventaddress'
),
trigger
:
'blur'
}],
'baseLive.liveUrl'
:[{
required
:
true
,
message
:
this
.
$t
(
'pubactivities.pleventaddress'
),
trigger
:
'blur'
}],
},
contactsform
:{
fieldType
:
2
...
...
@@ -342,7 +362,13 @@
channelPic
:
''
,
personMax
:
500
,
versionType
:
0
,
channelIntroduction
:
''
channelIntroduction
:
''
,
hasLive
:
0
,
baseLive
:{
livePowers
:
0
,
liveBack
:
0
,
liveUrl
:
''
,
},
},
isShowErrorText2
:
false
,
inputValue
:
''
,
//添加小标签
...
...
@@ -593,6 +619,15 @@
}
});
},
ishasLive
(
val
){
if
(
val
==
0
){
this
.
formData
.
baseLive
=
{
livePowers
:
0
,
liveBack
:
0
,
liveUrl
:
''
,
}
}
},
subpublishActivity
(){
this
.
$refs
.
formData
.
validate
((
valid
)
=>
{
if
(
valid
)
{
...
...
src/views/publishactivity/pubactivities.vue
View file @
3a9d4cf2
...
...
@@ -66,6 +66,12 @@
<el-button
v-if=
"scope.row.channelState == 3"
type=
"text"
@
click=
"urlclk(scope.row)"
>
{{
$t
(
'pubactivities.share'
)
}}
</el-button>
<el-button
v-if=
"scope.row.hasLive == 1&&scope.row.channelState != 4"
type=
"text"
@
click=
"messageclk(scope.row)"
>
开播提醒
</el-button>
<el-button
v-if=
"scope.row.hasLive == 1&&scope.row.liveState!=3&&scope.row.channelState != 4"
type=
"text"
@
click=
"getprocessLiveState(scope.row)"
>
{{
scope
.
row
.
liveState
==
0
?
'开播'
:
scope
.
row
.
liveState
==
1
?
'关闭直播'
:
''
}}
</el-button>
</
template
>
</el-table-column>
<
template
slot=
"empty"
>
...
...
@@ -161,6 +167,33 @@
this
.
cur_page
=
1
;
this
.
getpublishActivityList
();
},
//开播提醒
messageclk
(
row
){
api
.
callLiveMessage
(
row
.
channelId
).
then
(
response
=>
{
if
(
response
.
code
==
0
)
{
this
.
getpublishActivityList
();
}
else
{
this
.
$message
.
error
(
response
.
msgCode
);
}
})
.
catch
(
error
=>
{
console
.
log
(
"提交出错"
);
return
false
;
});
},
getprocessLiveState
(
row
){
api
.
processLiveState
(
row
.
channelId
,
row
.
liveState
==
0
?
1
:
2
).
then
(
response
=>
{
if
(
response
.
code
==
0
)
{
this
.
getpublishActivityList
();
}
else
{
this
.
$message
.
error
(
response
.
msgCode
);
}
})
.
catch
(
error
=>
{
console
.
log
(
"提交出错"
);
return
false
;
});
},
getpublishActivityList
(){
let
params
=
{
pagination
:
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment