提交 a73409e4 编写于 作者: chendeli's avatar chendeli

add

上级 ff60f25e
......@@ -23,7 +23,7 @@
</p>
<div class="course-opt">
<span class="opt-info">{{item.showTime == '' ? '' : item.showTime + ' |'}} {{item.joinNum}}人已学</span>
<span :class="item.whetherFavors==2?'opt collect':'opt collected'"@click="collectFun(item.whetherFavors,item.id)">
<span :class="item.whetherFavors==2?'opt collect':'opt collected'"@click="collectFun(item.whetherFavors,item.id,item.name)">
{{item.whetherFavors==2?'收藏':'已收藏'}}
</span>
......@@ -80,6 +80,14 @@ export default {
//跳转
goToPage(item){
this.pageBurialPoin({
menuLevel:1,
menuCode:'m_home',
functionCode:'f_recommend',
actionCode:'c_course',
labelId:item.id,
labelvalue:item.name,
})
let itemData={
"title":item.name,
"imageUrl":"",
......@@ -113,6 +121,13 @@ export default {
//换一批
changeFun(){
this.pageBurialPoin({
menuLevel:1,
menuCode:'m_home',
functionCode:'f_recommend',
actionCode:'c_change',
})
this.clientHeight = document.documentElement.clientHeight+'px';
document.documentElement.scrollTop = document.documentElement.scrollTop - 20;
document.body.scrollTop = document.body.scrollTop - 20;
......@@ -131,7 +146,13 @@ export default {
_this.pageNo += 1;
_this.isLoading = true;
this.loading = true;
//埋点
this.pageBurialPoin({
menuLevel:1,
menuCode:'m_home',
functionCode:'f_recommend',
actionCode:'c_load_more'
})
setTimeout(()=>{
_this.getData('loadMore');
},500)
......@@ -140,7 +161,15 @@ export default {
},
//收藏 取消收藏
collectFun(status,id){
collectFun(status,id,name){
this.pageBurialPoin({
menuLevel:1,
menuCode:'m_home',
functionCode:'f_recommend',
actionCode:'c_collect',
labelId:id,
labelvalue:name,
})
let _this = this,
parm = {
token:this.token,
......@@ -196,12 +225,18 @@ export default {
_this.list = res.data || [];
}
}else{
alert(res.message)
_this.isLoading = false;
_this.noMore = false;
_this.loading = false;
}
_this.clientHeight = 'auto'
_this.isLoading = false;
_this.loading = false;
},function(){
_this.isLoading = false;
_this.noMore = false;
_this.loading = false;
})
}
}
......
......@@ -52,7 +52,8 @@ export default {
let _this = this,
para = {
category: 1,
position:3
position:3,
setEntry: 'headers'
}
this.GET('contents/HomeColumn/Information', para).then(res => {
if(res.code == '000000'){
......
......@@ -39,7 +39,7 @@ export default {
methods: {
goToPage(item){
let url = pageJumpUrl();
console.log(url);
//console.log(url);
let itemData={
"title":item.name,
"imageUrl":"",
......
......@@ -90,6 +90,7 @@ export default {
para = {
pageNo:this.pageNo,
pageSize:this.pageSize,
setEntry: 'headers'
}
this.GET('contents/HomeLecturer/LecturerInformation', para).then(res => {
if(res.code == '000000'){
......
......@@ -81,7 +81,8 @@ export default {
let _this = this,
para = {
category: 1,
position:1
position:1,
setEntry: 'headers'
}
this.GET('contents/HomeColumn/Information', para).then(res => {
if(res.code == '000000'){
......
......@@ -4,7 +4,7 @@
<input type="search" :class="isTransparent?'search-transparent':''" class="input" v-model="searchVal" :placeholder="placeholder" :disabled="disabled" />
<img class="search-img" src='../../images/Group2@2x.png'>
</div>
<div class="header-right">
<div class="header-right" @click="goToPage">
<img class="info" src='../../images/msg1.png'>
<div :class="isMax?'num-max':'num-min'" class="info-count fs10" v-show="isShowMsg">{{count}}</div>
</div>
......@@ -43,7 +43,15 @@ export default {
},
methods: {
goToPage(){
this.pageBurialPoin({
menuLevel:1,
menuCode:'m_home',
functionCode:'f_notification',
actionCode:'c_notification',
})
rocNative.readMessage();
}
},
......@@ -74,6 +82,7 @@ html,body{
width: px2rem(20px);
height: px2rem(20px);
position: relative;
margin-top:px2rem(5px);
img{
width: 100%;
height: 100%;
......
......@@ -49,8 +49,9 @@
//返回
goBack(){
this.$router.back(-1);
//rocNative.backPreviousPage();
rocNative.goBack();
//rocNative.goBack();
},
//分享
......
......@@ -222,8 +222,8 @@ export function pageJumpUrl(){
// test1地址
const baseUrl = 'http://10.177.10.238:10201/' || 'http://test1-sc.yunqueyi.com/'
const apiUrl = 'http://10.177.10.238:10201' || 'http://test1-api.yunqueyi.com/'
const baseUrl = 'http://dev-sc.yunqueyi.com/' || 'http://10.177.10.238:10201/' || 'http://test1-sc.yunqueyi.com/'
const apiUrl = 'http://dev-sc.yunqueyi.com/'||'http://10.177.10.238:10201' || 'http://test1-api.yunqueyi.com/'
// // uat地址
......
......@@ -34,6 +34,27 @@ module.exports = {
}
return ''
},
pageBurialPoin(options){
let opt = {
menuLevel:options.menuLevel || '',
functionCode:options.functionCode || '',
actionCode: options.actionCode || '',
label:options.label || '',
labelId:options.labelId || '',
labelvalue:options.labelvalue || '',
createdTime: options.createdTime || new Date().getTime(),
type: options.type || '',
menuCode: options.menuCode || '',
// menuToCode:options.menuToCode || '',
duration: options.duration || 0,
menuFromCode:options.menuFromCode ||'',
params:options.params || '',
session:options.session || '',
}
console.log(opt);
rocNative.appBuryingPointEntrust(opt)
},
setRouterParm(paramList){
let parm = {};
......
......@@ -37,7 +37,7 @@
return true;
}
if (e.webkit && window.webkit.messageHandlers.rociOS) {
alert(r)
//alert(r)
window.webkit.messageHandlers.rociOS.postMessage(r)
// e.__isIOS = true;
return true;
......
......@@ -22,10 +22,10 @@ import BackTop from '../../components/common/backTop';
export default {
data(){
return {
tittle:'活动掠影',
tittle:'',
list:[],
bgColor:'#fff',
navTitle:'活动掠影',
navTitle:'',
isBorder:true,
isNavFix:true,
id:'1',
......@@ -39,13 +39,23 @@ export default {
BackTop
},
mounted(){
console.log(this.$route.query);
///console.log(this.$route.query);
this.id = this.$route.query.categoryId
this.getTabData();
window.addEventListener('scroll', this.scrollFun);
},
beforeDestroyed(){
window.removeEventListener('scroll', this.scrollFun)
},
methods:{
scrollFun(){
let scrollTop = document.documentElement.scrollTop;
this.isShowBackTop = scrollTop > 0 ? true : false;
// if(scrollTop > 0){
// this.isShowBackTop = true;
// }
},
goToPage(itemData){
let paramList = this.setEventByModuleCode(itemData);
rocNative.dispatchEventByModuleCode({
......@@ -54,16 +64,20 @@ export default {
})
},
//查询tab
getTabData(){
let _this = this,
parm = {
id:_this.id
id:_this.id,
setEntry: 'headers'
}
_this.GET('contents/contentList/tabById',parm).then(function(res){
if(res.code === '000000'){
_this.tabName = res.data.name || '';
_this.navTitle = res.data.name || '';
_this.tabName = _this.tabList[0] || '';
// if(_this.tabList.length>0){
// _this.tabName = _this.tabList[0] || '';
// }
......@@ -79,7 +93,8 @@ export default {
let _this = this,
parm = {
id:_this.id,
tabName : _this.tabName
tabName : _this.tabName,
setEntry: 'headers'
}
// if(_this.tabName != ''){
// parm.tabName = _this.tabName
......@@ -88,10 +103,7 @@ export default {
if(res.code === '000000'){
_this.list = res.data.contentList && res.data.contentList.contentList || [];
let scrollTop = document.documentElement.scrollTop;
if(scrollTop > 0){
_this.isShowBackTop = true;
}
}
})
}
......@@ -113,12 +125,13 @@ export default {
.activity-item{
position: relative;
width: px2rem(345px);
height: px2rem(170px);
/* height: px2rem(170px);*/
margin-top:px2rem(15px);
box-shadow: 0 px2rem(2px) px2rem(6px) RGBA(42, 94, 161, 0.15);
.img{
width: 100%;
height: 100%;
display: block;
}
.time{
position: absolute;
......
此差异已折叠。
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册