Commit fb26fec9 by libai

测试

parent 03261136
Showing with 18 additions and 1 deletions
...@@ -132,6 +132,7 @@ ...@@ -132,6 +132,7 @@
$(function(){ $(function(){
if(localStorage.canvasCode==undefined)window.localStorage.href='../pc.html' if(localStorage.canvasCode==undefined)window.localStorage.href='../pc.html'
var myTopicId var myTopicId
loginGo() loginGo()
TopicInfo() TopicInfo()
getTopics(1,1,sessionStorage.tag,-1,-1,-1) getTopics(1,1,sessionStorage.tag,-1,-1,-1)
...@@ -153,9 +154,24 @@ $(function(){ ...@@ -153,9 +154,24 @@ $(function(){
pageID:localStorage.canvasCode, pageID:localStorage.canvasCode,
topicId:sessionStorage.topicId topicId:sessionStorage.topicId
}, },
async:false,
success:function(msg){ success:function(msg){
console.log('查看帖子详情',msg) console.log('查看帖子详情',msg)
if(msg.code!=1){
return;
}
myTopicId=msg.topic.topicId myTopicId=msg.topic.topicId
if(localStorage.out!=undefined) localStorage.out=localStorage.out+','+myTopicId
else localStorage.out=myTopicId
console.log(localStorage.out.split(","))
if(localStorage.out.split(",").length>30){
var outArr=''
for(var i=0;i<30;i++){
i==29?outArr+=localStorage.out.split(",")[30-i]:outArr+=localStorage.out.split(",")[30-i]+','
}
localStorage.out=outArr
}
var data=msg.topic; var data=msg.topic;
var videoList=JSON.parse(data.content) var videoList=JSON.parse(data.content)
$(".video-content-title").text(videoList.title) $(".video-content-title").text(videoList.title)
...@@ -294,7 +310,8 @@ $(function(){ ...@@ -294,7 +310,8 @@ $(function(){
tag:tagNum, tag:tagNum,
duration:timeNum, duration:timeNum,
sort:sortNum, sort:sortNum,
period:dayNum period:dayNum,
topicId:localStorage.out
}, },
success:function(data){ success:function(data){
console.log('获取帖子',data) console.log('获取帖子',data)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment