|
@@ -9,7 +9,7 @@ Page({
|
|
|
*/
|
|
*/
|
|
|
data: {
|
|
data: {
|
|
|
dataTypes: 0, //0-全部数据 1-单独数据
|
|
dataTypes: 0, //0-全部数据 1-单独数据
|
|
|
- tabsList: ["私域直播", "展会直播", "合作商直播"], //tabs列表
|
|
|
|
|
|
|
+ tabsList: ["我要直播", "合作商直播"], //"展会直播" tabs列表
|
|
|
buttonTabs: ["当前直播", "历史直播"], //按钮tabs
|
|
buttonTabs: ["当前直播", "历史直播"], //按钮tabs
|
|
|
tabsIndex: 0, //tabs下标
|
|
tabsIndex: 0, //tabs下标
|
|
|
accountStatus: -1, //直播账号状态 1-账号正常 2-账号审核中 3-没有账号
|
|
accountStatus: -1, //直播账号状态 1-账号正常 2-账号审核中 3-没有账号
|
|
@@ -25,6 +25,7 @@ Page({
|
|
|
isSy: true, //是否为私域直播
|
|
isSy: true, //是否为私域直播
|
|
|
myShowModel: false, //自定义model
|
|
myShowModel: false, //自定义model
|
|
|
myShowModel2: false, // 真正申请中提示
|
|
myShowModel2: false, // 真正申请中提示
|
|
|
|
|
+ myShowMode3: false,
|
|
|
listRowIndex: -1, //列表选中项
|
|
listRowIndex: -1, //列表选中项
|
|
|
CheckTheType: '当前直播', //查看类型
|
|
CheckTheType: '当前直播', //查看类型
|
|
|
onlineNumber: 0, //实时观看人数
|
|
onlineNumber: 0, //实时观看人数
|
|
@@ -165,14 +166,24 @@ Page({
|
|
|
}) {
|
|
}) {
|
|
|
if (detail == 'true') this.copyTheAddress(this.data.accountMsg.fliveurl_web);
|
|
if (detail == 'true') this.copyTheAddress(this.data.accountMsg.fliveurl_web);
|
|
|
},
|
|
},
|
|
|
|
|
+ showModelCallBack1({
|
|
|
|
|
+ detail
|
|
|
|
|
+ }) {
|
|
|
|
|
+ if (detail == 'true') this.copyTheAddress(this.data.accountMsg.fliveurl_client);
|
|
|
|
|
+ },
|
|
|
/* 显示自定义model */
|
|
/* 显示自定义model */
|
|
|
showMyModel() {
|
|
showMyModel() {
|
|
|
this.setData({
|
|
this.setData({
|
|
|
myShowModel: true
|
|
myShowModel: true
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
|
|
+ showMyMode3() {
|
|
|
|
|
+ this.setData({
|
|
|
|
|
+ myShowMode3: true
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
/* 申请直播账号 */
|
|
/* 申请直播账号 */
|
|
|
- applyForLive() {
|
|
|
|
|
|
|
+ /* applyForLive() {
|
|
|
_Http.basic({
|
|
_Http.basic({
|
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
|
"classname": "customer.live.live",
|
|
"classname": "customer.live.live",
|
|
@@ -193,7 +204,7 @@ Page({
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
- },
|
|
|
|
|
|
|
+ }, */
|
|
|
/* 复制地址 */
|
|
/* 复制地址 */
|
|
|
copyTheAddress(e) {
|
|
copyTheAddress(e) {
|
|
|
const url = (typeof e == "string" || typeof e == String) ? e : e.target.dataset.url;
|
|
const url = (typeof e == "string" || typeof e == String) ? e : e.target.dataset.url;
|
|
@@ -210,7 +221,8 @@ Page({
|
|
|
},
|
|
},
|
|
|
/* 获取直播账号详情 */
|
|
/* 获取直播账号详情 */
|
|
|
getLiveInfo() {
|
|
getLiveInfo() {
|
|
|
- const method = (this.data.tabsIndex == 0) ? 'getSYLiveInfo' : 'getLiveInfo';
|
|
|
|
|
|
|
+ /* const method = (this.data.tabsIndex == 0) ? 'getSYLiveInfo' : 'getLiveInfo'; */
|
|
|
|
|
+ const method = 'getLiveInfo';
|
|
|
_Http.basic({
|
|
_Http.basic({
|
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
|
"classname": "customer.live.live",
|
|
"classname": "customer.live.live",
|
|
@@ -232,7 +244,8 @@ Page({
|
|
|
},
|
|
},
|
|
|
/* 直播场次列表查询 */
|
|
/* 直播场次列表查询 */
|
|
|
getLiveSessionList() {
|
|
getLiveSessionList() {
|
|
|
- const method = (this.data.tabsIndex == 0) ? "getSYLiveSessionList" : "getLiveSessionList"
|
|
|
|
|
|
|
+ /* const method = (this.data.tabsIndex == 0) ? "getSYLiveSessionList" : "getLiveSessionList" */
|
|
|
|
|
+ const method = "getLiveSessionList";
|
|
|
_Http.basic({
|
|
_Http.basic({
|
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
|
"classname": "customer.live.live",
|
|
"classname": "customer.live.live",
|
|
@@ -274,11 +287,13 @@ Page({
|
|
|
showStartTime: this.data.liveSessionList[index].starttime,
|
|
showStartTime: this.data.liveSessionList[index].starttime,
|
|
|
sessionid
|
|
sessionid
|
|
|
})
|
|
})
|
|
|
|
|
+ /* const method = (this.data.tabsIndex == 0) ? "getSYLiveDataCountForSession" : "getLiveDataCountForSession" */
|
|
|
|
|
+ const method = 'getLiveDataCountForSession';
|
|
|
/* 场次详情统计 */
|
|
/* 场次详情统计 */
|
|
|
_Http.basic({
|
|
_Http.basic({
|
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
|
"classname": "customer.live.live",
|
|
"classname": "customer.live.live",
|
|
|
- "method": "getSYLiveDataCountForSession",
|
|
|
|
|
|
|
+ "method": method,
|
|
|
"content": {
|
|
"content": {
|
|
|
"sessionid": sessionid
|
|
"sessionid": sessionid
|
|
|
}
|
|
}
|
|
@@ -301,7 +316,8 @@ Page({
|
|
|
/* 观看用户列表 */
|
|
/* 观看用户列表 */
|
|
|
LiveUserList() {
|
|
LiveUserList() {
|
|
|
/* 用户观看列表 */
|
|
/* 用户观看列表 */
|
|
|
- const method = (this.data.tabsIndex == 0) ? "getSYLiveUserList" : "getLiveUserList";
|
|
|
|
|
|
|
+ /* const method = (this.data.tabsIndex == 0) ? "getSYLiveUserList" : "getLiveUserList"; */
|
|
|
|
|
+ const method = "getLiveUserList";
|
|
|
_Http.basic({
|
|
_Http.basic({
|
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
"accesstoken": wx.getStorageSync('userData').token,
|
|
|
"classname": "customer.live.live",
|
|
"classname": "customer.live.live",
|
|
@@ -391,8 +407,9 @@ Page({
|
|
|
userPageNumber: 1,
|
|
userPageNumber: 1,
|
|
|
userPageTotal: 1
|
|
userPageTotal: 1
|
|
|
});
|
|
});
|
|
|
- if (detail != 2) this.getLiveInfo();
|
|
|
|
|
- if (detail == 2) this.getCooperationAgentsLiveList();
|
|
|
|
|
|
|
+ // if (detail != 2) this.getLiveInfo();
|
|
|
|
|
+ if (detail == 0) this.getLiveInfo();
|
|
|
|
|
+ if (detail == 1) this.getCooperationAgentsLiveList();
|
|
|
},
|
|
},
|
|
|
/* 获取合作商直播列表 */
|
|
/* 获取合作商直播列表 */
|
|
|
getCooperationAgentsLiveList() {
|
|
getCooperationAgentsLiveList() {
|
|
@@ -408,38 +425,38 @@ Page({
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
/* 查看合作商直播 */
|
|
/* 查看合作商直播 */
|
|
|
- toLive(e) {
|
|
|
|
|
- const {
|
|
|
|
|
- index
|
|
|
|
|
- } = e.currentTarget.dataset,
|
|
|
|
|
- data = this.data.partnerLiveList[index];
|
|
|
|
|
- if (data.fisneedauth == 1) {
|
|
|
|
|
- _Http.basic({
|
|
|
|
|
- "accesstoken": wx.getStorageSync('userData').token,
|
|
|
|
|
- "classname": "enterprise.live.live",
|
|
|
|
|
- "method": "liveauthorization",
|
|
|
|
|
- "content": {
|
|
|
|
|
- "tliveid": data.tliveid
|
|
|
|
|
- }
|
|
|
|
|
- }).then(res => {
|
|
|
|
|
- console.log(res)
|
|
|
|
|
- if (res.data != '成功') return wx.showToast({
|
|
|
|
|
- title: '网络错误,请稍后再试',
|
|
|
|
|
|
|
+ /* toLive(e) {
|
|
|
|
|
+ const {
|
|
|
|
|
+ index
|
|
|
|
|
+ } = e.currentTarget.dataset,
|
|
|
|
|
+ data = this.data.partnerLiveList[index];
|
|
|
|
|
+ if (data.fisneedauth == 1) {
|
|
|
|
|
+ _Http.basic({
|
|
|
|
|
+ "accesstoken": wx.getStorageSync('userData').token,
|
|
|
|
|
+ "classname": "enterprise.live.live",
|
|
|
|
|
+ "method": "liveauthorization",
|
|
|
|
|
+ "content": {
|
|
|
|
|
+ "tliveid": data.tliveid
|
|
|
|
|
+ }
|
|
|
|
|
+ }).then(res => {
|
|
|
|
|
+ console.log(res)
|
|
|
|
|
+ if (res.data != '成功') return wx.showToast({
|
|
|
|
|
+ title: '网络错误,请稍后再试',
|
|
|
|
|
+ })
|
|
|
|
|
+ let str = res.msg;
|
|
|
|
|
+ const url = str.slice(0, 8) + '04de51d4c1.' + str.slice(8);
|
|
|
|
|
+ wx.navigateTo({
|
|
|
|
|
+ url: '/pages/webView/index?url=' + encodeURIComponent(url),
|
|
|
|
|
+ })
|
|
|
})
|
|
})
|
|
|
- let str = res.msg;
|
|
|
|
|
|
|
+ } else {
|
|
|
|
|
+ let str = data.fliveshowurl;
|
|
|
const url = str.slice(0, 8) + '04de51d4c1.' + str.slice(8);
|
|
const url = str.slice(0, 8) + '04de51d4c1.' + str.slice(8);
|
|
|
wx.navigateTo({
|
|
wx.navigateTo({
|
|
|
- url: '/pages/webView/index?url=' + encodeURIComponent(url),
|
|
|
|
|
|
|
+ url: '/pages/webView/index?url=' + encodeURIComponent(url)
|
|
|
})
|
|
})
|
|
|
- })
|
|
|
|
|
- } else {
|
|
|
|
|
- let str = data.fliveshowurl;
|
|
|
|
|
- const url = str.slice(0, 8) + '04de51d4c1.' + str.slice(8);
|
|
|
|
|
- wx.navigateTo({
|
|
|
|
|
- url: '/pages/webView/index?url=' + encodeURIComponent(url)
|
|
|
|
|
- })
|
|
|
|
|
- }
|
|
|
|
|
- },
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+ }, */
|
|
|
/**
|
|
/**
|
|
|
* 生命周期函数--监听页面初次渲染完成
|
|
* 生命周期函数--监听页面初次渲染完成
|
|
|
*/
|
|
*/
|