|
@@ -55,13 +55,13 @@
|
|
|
</div>
|
|
|
|
|
|
<div id="prizePopup" class="popup">
|
|
|
- <!-- <img id="prizeImg" src="" alt="" /> -->
|
|
|
- <p id="ptizeName"></p>
|
|
|
+ <img id="prizeImg" src="" alt="" style="position: absolute;left: 515px;top: 180px;"/>
|
|
|
+ <p id="ptizeName" style="text-align: center;width: 180px;height: 50px;line-height: 50px;position: absolute;left: 554px;top: 457px;color: #dd002b;font-size: 25px;font-weight: bold;"></p>
|
|
|
<div class="prizeBtn cancel"></div>
|
|
|
<div class="prizeBtn toExchange"></div>
|
|
|
</div>
|
|
|
<div id="exchangePopup" class="popup">
|
|
|
- <!-- <img id="myPrize" src="" alt="" /> -->
|
|
|
+ <img id="myPrize" src="" alt="" style="position: absolute;left: 330px;top: 260px;" />
|
|
|
<div id="phone"></div>
|
|
|
<ul id="keyBoard">
|
|
|
<li class="phoneNum">1</li>
|
|
@@ -105,7 +105,7 @@
|
|
|
<div class="awardBtn toAward"></div>
|
|
|
</div>
|
|
|
<div id="markDownPopup" class="popup">
|
|
|
- <div class="markDownBtn"></div>
|
|
|
+ <div class="markDownBtn confirm"></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -153,6 +153,7 @@
|
|
|
focusItem:"page_btn",
|
|
|
}
|
|
|
|
|
|
+ var listM = 0;
|
|
|
var heguiItem = "";
|
|
|
var changeOrwin = "";
|
|
|
var rulesPopup = false;
|
|
@@ -233,7 +234,7 @@
|
|
|
if(res.code==0){
|
|
|
if (res.data.my_prizes[0]) {
|
|
|
G("myAward").innerText = res.data.my_prizes[0].prize_name;
|
|
|
- // G("myPrize").src = res.data.my_prizes[0].show_image;
|
|
|
+ G("myPrize").src = res.data.my_prizes[0].show_image;
|
|
|
G("myPhone").innerText = res.data.my_prizes[0].user_phone;
|
|
|
}
|
|
|
if (res.data.user_phone) {
|
|
@@ -307,13 +308,13 @@
|
|
|
up:["ip_btn",2],
|
|
|
onEnterPress:function(){
|
|
|
if(!this.current.getAttribute("data-mark")){
|
|
|
- var idx = this.currentIndex>3?this.currentIndex-4:this.currentIndex;
|
|
|
- fullscreenPlay(mengwaMediaArr[idx],numArr[idx]);
|
|
|
+ // var idx = this.currentIndex>3?this.currentIndex-4:this.currentIndex;
|
|
|
+ fullscreenPlay(this.current.getAttribute("data-media"),this.current.getAttribute("data-num"));
|
|
|
}else{
|
|
|
- vote(uid,voteArr[this.currentIndex-4],function(res){
|
|
|
+ vote(uid,this.current.getAttribute("data-mengbao"),function(res){
|
|
|
if(res.code == 0){
|
|
|
G("number").innerHTML = res.data.num;
|
|
|
- G("vote"+(main.currentIndex-4)).innerHTML = G("vote"+(main.currentIndex-4)).innerHTML*1+1;
|
|
|
+ G("vote"+(main.current.getAttribute("data-mark"))).innerHTML = G("vote"+(main.current.getAttribute("data-mark"))).innerHTML*1+1;
|
|
|
tips("投票成功");
|
|
|
getPrizeNum(uid,function(res){
|
|
|
if(res.code==0){
|
|
@@ -334,6 +335,22 @@
|
|
|
}
|
|
|
},
|
|
|
onPress:function(){
|
|
|
+ if(this.event.keyCode == 40 || this.event.keyCode == "DOWN"){
|
|
|
+ if(this.prevIndex+4>=this.hotbtn.length){
|
|
|
+ if(this.prevIndex == this.hotbtn.length-1) return;
|
|
|
+ if(this.prevIndex == this.hotbtn.length-2){
|
|
|
+ this.reSetClass("voteBtn",this.hotbtn.length-1);
|
|
|
+ }else{
|
|
|
+ this.reSetClass("voteBtn",this.hotbtn.length-1-listM);
|
|
|
+ }
|
|
|
+ }else if(!!this.prev.getAttribute("data-mark") && !!this.hotbtn[this.prevIndex+4].getAttribute("data-mark")){
|
|
|
+ this.reSetClass("voteBtn",this.hotbtn.length-2);
|
|
|
+ }
|
|
|
+ }else if(this.event.keyCode == 38 || this.event.keyCode == "UP"){
|
|
|
+ if(this.prev.getAttribute("data-key")){
|
|
|
+ this.reSetClass("voteBtn",this.prevIndex-listM);
|
|
|
+ }
|
|
|
+ }
|
|
|
if(!this.current.getAttribute("data-mark")){
|
|
|
var h = document.getElementsByClassName("voteTxt")[0].offsetHeight+document.getElementsByClassName("voteLi")[0].offsetHeight+20
|
|
|
G("scrollCont").style.top = - 770-(parseInt(this.currentIndex/4/2)*h) + "px";
|
|
@@ -368,9 +385,9 @@
|
|
|
if(res.data.yes.prize_status=="none"){
|
|
|
nowin("nowin");
|
|
|
}else if(res.data.yes.prize_status=="real"){//中奖
|
|
|
- // G("prizeImg").src = res.data.yes.prize_img;
|
|
|
+ G("prizeImg").src = res.data.yes.prize_img;
|
|
|
G("ptizeName").innerHTML = res.data.yes.prize_name;
|
|
|
- // G("myPrize").src = res.data.yes.prize_img;
|
|
|
+ G("myPrize").src = res.data.yes.prize_img;
|
|
|
S("prizePopup");
|
|
|
main.reSetClass("prizeBtn",1);
|
|
|
}
|
|
@@ -522,7 +539,7 @@
|
|
|
1:[0,-1,0,0],
|
|
|
// 2:[0,0,0,0],
|
|
|
onEnterPress:function(){
|
|
|
- if(this.currentIndex==2){
|
|
|
+ if(this.currentIndex==1){
|
|
|
H("unWinToyPopup");
|
|
|
this.reSetClass("voteBtn");
|
|
|
}else{
|
|
@@ -686,15 +703,15 @@
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- function toZhuanti(idx){
|
|
|
- var exitStr = escape(backUrl);
|
|
|
- var url = '';
|
|
|
+ function toZhuanti(index){
|
|
|
+ // var exitStr = escape(backUrl);
|
|
|
+ // var url = '';
|
|
|
if(index==0){
|
|
|
- fullscreenPlay("00000001000000000002000000120684")
|
|
|
+ fullscreenPlay("00000001000000000025000000326508")
|
|
|
}else if(index==1){
|
|
|
- fullscreenPlay("00000001000000000014000000387305")
|
|
|
+ fullscreenPlay("00000001000000000032000000221170")
|
|
|
}else if(index==2){
|
|
|
- fullscreenPlay("00000001000000000029000000278889")
|
|
|
+ fullscreenPlay("00000001000000000028000000428043")
|
|
|
}
|
|
|
// window.location.href = url;
|
|
|
}
|
|
@@ -729,7 +746,7 @@
|
|
|
G("unWinToyPopup").style.background = "url('./img/page_07.png') no-repeat center";
|
|
|
}
|
|
|
S("unWinToyPopup");
|
|
|
- main.reSetClass("unWinToyBtn",2);
|
|
|
+ main.reSetClass("unWinToyBtn");
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -918,6 +935,7 @@
|
|
|
act_id:init.act_id,
|
|
|
uid: uid,
|
|
|
is_vip: init.is_vip,
|
|
|
+ limit:100,
|
|
|
},
|
|
|
success: function (res) {
|
|
|
fn && fn(res);
|
|
@@ -971,6 +989,7 @@
|
|
|
act_id:init.act_id,
|
|
|
uid: uid,
|
|
|
is_vip: init.is_vip,
|
|
|
+ test:1,
|
|
|
},
|
|
|
success: function (res) {
|
|
|
fn && fn(res);
|
|
@@ -980,13 +999,14 @@
|
|
|
})
|
|
|
}
|
|
|
|
|
|
- function fullscreenPlay(mid) {
|
|
|
+ function fullscreenPlay(mid,idx) {
|
|
|
+ idx = idx*1-1 || 0;
|
|
|
var playIntent = {
|
|
|
package : "com.hunantv.operator",
|
|
|
action: "mangotv://com.hunantv.operator/player/vod",
|
|
|
data:"",
|
|
|
extras: {
|
|
|
- "video_index": 0,
|
|
|
+ "video_index": idx,
|
|
|
"media_asset_id": mid, //媒资包
|
|
|
},
|
|
|
flags: []
|
|
@@ -1035,7 +1055,6 @@
|
|
|
if(G("phone").innerHTML.length>10) return;
|
|
|
var key = this.event.keyCode;
|
|
|
try {
|
|
|
- Webview.setInputTypeTextFlag("true");
|
|
|
if (key >= 0 && key <= 9) {
|
|
|
G("phone").innerText += key;
|
|
|
}
|
|
@@ -1062,16 +1081,26 @@
|
|
|
getMengbaoList(uid,function(res){
|
|
|
if(res.code==0){
|
|
|
var _html="",_li="",_span="";
|
|
|
+ listM = res.data.length%4;
|
|
|
var _len = res.data.length%4==0?res.data.length/4:parseInt(res.data.length/4)+1;
|
|
|
for(var i=0;i<_len;i++){
|
|
|
mengwaMediaArr.push(res.data[i].media_id);
|
|
|
- numArr.push(res.data[i].media_id);
|
|
|
- voteArr.push(res.data[i].media_num);
|
|
|
+ numArr.push(res.data[i].media_num);
|
|
|
+ voteArr.push(res.data[i].mengbao_id);
|
|
|
_li="";_span="";
|
|
|
for(var j=0;j<4;j++){
|
|
|
- if(i*4+j>=res.data.length) return;
|
|
|
- _li+= '<li class="voteLi"><div class="u_img voteBtn"><img src="'+res.data[i*4+j].image+'" alt="" /><i id="vote'+(i*4+j)+'">'+res.data[i*4+j].score+'</i></div><div class="u_msg">'+res.data[i*4+j].name+' '+res.data[i*4+j].age+'</div></li>';
|
|
|
- _span += '<span class="voteBtn voteTxt" data-mark="1"><i>投你一票</i></span>';
|
|
|
+ if(i*4+j<res.data.length){
|
|
|
+ _li+= '<li class="voteLi"><div class="u_img voteBtn" data-media="'+res.data[i*4+j].media_id+'" data-num="'+res.data[i*4+j].media_num+'"><img src="'+res.data[i*4+j].image+'" alt="" /><i id="vote'+(i*4+j)+'">'+res.data[i*4+j].score+'</i></div><div class="u_msg">'+res.data[i*4+j].name+' '+res.data[i*4+j].age+'岁</div></li>';
|
|
|
+ if(i==_len-1&&res.data.length%4!=0){
|
|
|
+ _span += '<span class="voteBtn voteTxt" data-mark="'+(i*4+j)+'" data-key="1" data-mengbao="'+res.data[i*4+j].mengbao_id+'"><i>投你一票</i></span>';
|
|
|
+ }else{
|
|
|
+ _span += '<span class="voteBtn voteTxt" data-mark="'+(i*4+j)+'" data-mengbao="'+res.data[i*4+j].mengbao_id+'"><i>投你一票</i></span>';
|
|
|
+ }
|
|
|
+
|
|
|
+ }else if(i*4+j>=res.data.length&&(i*4+j)<res.data.length+(4-(res.data.length%4))){
|
|
|
+ _li+= '<li class="voteLi" style="width: 239px;height: 200px;"></li>';
|
|
|
+ _span += '<span class="blacktxt"><i></i></span>';
|
|
|
+ }
|
|
|
}
|
|
|
_html += (_li + _span);
|
|
|
}
|
|
@@ -1126,10 +1155,7 @@
|
|
|
}
|
|
|
|
|
|
function juge(){
|
|
|
- if(init.isYearVip){
|
|
|
- init.is_vip = 2;
|
|
|
- }
|
|
|
- else if(init.othersProduct_isVip || init.oursProduct_isVip || init.allProduce_isVip){
|
|
|
+ if(init.othersProduct_isVip || init.oursProduct_isVip){
|
|
|
init.is_vip = 1;
|
|
|
}
|
|
|
else if(init.othersProduct_isVip==0 && init.oursProduct_isVip==0){
|