|
@@ -57,7 +57,7 @@
|
|
|
gameNum:0,
|
|
|
theme_id:2,
|
|
|
fromsource:15,
|
|
|
- oursId:"8801000077",
|
|
|
+ oursId:"8801000079",
|
|
|
othersId:"8801000646",//不用
|
|
|
oursProduct_isVip:0,
|
|
|
othersProduct_isVip:0,
|
|
@@ -104,9 +104,9 @@
|
|
|
case 3:
|
|
|
order(0);
|
|
|
break;
|
|
|
- case 4:
|
|
|
- order(1);
|
|
|
- break;
|
|
|
+ // case 4:
|
|
|
+ // order(1);
|
|
|
+ // break;
|
|
|
default:
|
|
|
break;
|
|
|
}
|
|
@@ -114,18 +114,21 @@
|
|
|
},
|
|
|
onPress:function(){
|
|
|
if((this.event.keyCode == 40 || this.event.keyCode == "DOWN")&& this.prevIndex == 2){
|
|
|
- if(init.othersProduct_isVip == 0){
|
|
|
+ if(init.oursProduct_isVip == 0){
|
|
|
this.reSetClass("page_btn",3);
|
|
|
- }else if(init.oursProduct_isVip == 0 && init.othersProduct_isVip == 1){
|
|
|
- this.reSetClass("page_btn",4);
|
|
|
- }else{
|
|
|
- this.reSetClass("ip_btn",2);
|
|
|
}
|
|
|
- }else if((this.event.keyCode == 39 || this.event.keyCode == "RIGHT")&& this.prevIndex == 3){
|
|
|
- if(init.oursProduct_isVip == 0){
|
|
|
- this.reSetClass("page_btn",4);
|
|
|
+ // else if(init.oursProduct_isVip == 0 && init.othersProduct_isVip == 1){
|
|
|
+ // this.reSetClass("page_btn",4);
|
|
|
+ // }
|
|
|
+ else{
|
|
|
+ this.reSetClass("ip_btn",2);
|
|
|
}
|
|
|
}
|
|
|
+ // else if((this.event.keyCode == 39 || this.event.keyCode == "RIGHT")&& this.prevIndex == 3){
|
|
|
+ // if(init.oursProduct_isVip == 0){
|
|
|
+ // this.reSetClass("page_btn",4);
|
|
|
+ // }
|
|
|
+ // }
|
|
|
// else if((this.event.keyCode == 37 || this.event.keyCode == "LEFT")&& this.prevIndex == 4){
|
|
|
// if(init.othersProduct_isVip == 0){
|
|
|
// this.reSetClass("page_btn",3);
|
|
@@ -136,7 +139,7 @@
|
|
|
ip_btn:{
|
|
|
line:6,
|
|
|
onEnterPress:function(){
|
|
|
- if(init.othersProduct_isVip == 1){
|
|
|
+ if(init.oursProduct_isVip == 1){
|
|
|
fullscreenPlay(videoArr[this.currentIndex]);
|
|
|
}else{
|
|
|
order(0);
|
|
@@ -144,11 +147,13 @@
|
|
|
},
|
|
|
onPress:function(){
|
|
|
if(this.event.keyCode == 38 || this.event.keyCode == "UP"){
|
|
|
- if(init.othersProduct_isVip == 0){
|
|
|
+ if(init.oursProduct_isVip == 0){
|
|
|
this.reSetClass("page_btn",3);
|
|
|
- }else if(init.oursProduct_isVip == 0 && init.othersProduct_isVip == 1){
|
|
|
- this.reSetClass("page_btn",4);
|
|
|
- }else{
|
|
|
+ }
|
|
|
+ // else if(init.oursProduct_isVip == 0 && init.othersProduct_isVip == 1){
|
|
|
+ // this.reSetClass("page_btn",4);
|
|
|
+ // }
|
|
|
+ else{
|
|
|
this.reSetClass("page_btn",2);
|
|
|
}
|
|
|
}
|
|
@@ -196,47 +201,42 @@
|
|
|
|
|
|
|
|
|
function order(idx){
|
|
|
- if(init.gameNum==0 && (init.othersProduct_isVip || init.oursProduct_isVip)){
|
|
|
- S("timeOutPopup");
|
|
|
- main.reSetClass("timeOutBtn");
|
|
|
- }else{
|
|
|
- var pid = init.oursId;
|
|
|
- var mark = "mw_oursBag";
|
|
|
- // if(idx == 1){
|
|
|
- // pid = init.oursId;
|
|
|
- // mark = "mw_othersBag";
|
|
|
- // }
|
|
|
- var orderBack = backUrl+'?'+mark+'='+uid;
|
|
|
- if(version.indexOf("5a.7") || version.indexOf("5a.8")){
|
|
|
- var product_list={
|
|
|
- "product_id":pid,
|
|
|
- "video_name":"",
|
|
|
- "video_type":"",
|
|
|
- "product_type":"2",
|
|
|
- "cat_id":"",
|
|
|
- "channel_id":"",
|
|
|
- }
|
|
|
- window.location.href = "https://hnydorder.yys.mgtv.com:8080/order/index.html?product_list="+JSON.stringify(product_list)+"&exitStr="+escape(orderBack);
|
|
|
- }else{
|
|
|
- var playIntent = {
|
|
|
- package: "com.hunantv.operator",
|
|
|
- action: "mangotv://com.hunantv.operator/order",
|
|
|
- data: "",
|
|
|
- extras: {
|
|
|
- product: {
|
|
|
- "id": pid,
|
|
|
- "time": "",
|
|
|
- "price": "",
|
|
|
- "type": "",
|
|
|
- "name": "",
|
|
|
- "bag": "",
|
|
|
- "back_url":orderBack,
|
|
|
- }
|
|
|
- },
|
|
|
- flags: []
|
|
|
- };
|
|
|
- Webview.sendIntent("startActivity", playIntent);
|
|
|
+ var pid = init.oursId;
|
|
|
+ var mark = "mw_oursBag";
|
|
|
+ // if(idx == 1){
|
|
|
+ // pid = init.oursId;
|
|
|
+ // mark = "mw_othersBag";
|
|
|
+ // }
|
|
|
+ var orderBack = backUrl+'?'+mark+'='+uid;
|
|
|
+ if(version.indexOf("5a.7") || version.indexOf("5a.8")){
|
|
|
+ var product_list={
|
|
|
+ "product_id":pid,
|
|
|
+ "video_name":"",
|
|
|
+ "video_type":"",
|
|
|
+ "product_type":"2",
|
|
|
+ "cat_id":"",
|
|
|
+ "channel_id":"",
|
|
|
}
|
|
|
+ window.location.href = "https://hnydorder.yys.mgtv.com:8080/order/index.html?product_list="+JSON.stringify(product_list)+"&exitStr="+escape(orderBack);
|
|
|
+ }else{
|
|
|
+ var playIntent = {
|
|
|
+ package: "com.hunantv.operator",
|
|
|
+ action: "mangotv://com.hunantv.operator/order",
|
|
|
+ data: "",
|
|
|
+ extras: {
|
|
|
+ product: {
|
|
|
+ "id": pid,
|
|
|
+ "time": "",
|
|
|
+ "price": "",
|
|
|
+ "type": "",
|
|
|
+ "name": "",
|
|
|
+ "bag": "",
|
|
|
+ "back_url":orderBack,
|
|
|
+ }
|
|
|
+ },
|
|
|
+ flags: []
|
|
|
+ };
|
|
|
+ Webview.sendIntent("startActivity", playIntent);
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -390,19 +390,20 @@
|
|
|
G("QRcode").src = res.data.qrcode;
|
|
|
}
|
|
|
})
|
|
|
+
|
|
|
|
|
|
authorization(init.contentcode,uid,usertoken,mac,version,function(res){
|
|
|
if(res.code == 0){
|
|
|
if(res.data.result==0){
|
|
|
init.oursProduct_isVip = 1;
|
|
|
- addClass(G("oursProduct"),'hasOrder');
|
|
|
+ addClass(G("othersProduct"),'hasOrder');
|
|
|
if(!!getStr("mw_oursBag")){
|
|
|
payResult(init.oursProduct_isVip,uid,init.oursId);
|
|
|
}
|
|
|
}else{
|
|
|
init.oursProduct_isVip = 0;
|
|
|
}
|
|
|
- btnInit();
|
|
|
+ // btnInit();
|
|
|
|
|
|
// authorization(init.contentcode1,uid,usertoken,mac,version,function(res){
|
|
|
// if(res.code == 0){
|
|
@@ -420,8 +421,9 @@
|
|
|
}
|
|
|
|
|
|
},function(){
|
|
|
- btnInit();
|
|
|
+ // btnInit();
|
|
|
});
|
|
|
+ btnInit();
|
|
|
smallvodPlay(videoId);
|
|
|
}
|
|
|
function btnInit(){
|
|
@@ -437,6 +439,7 @@
|
|
|
|
|
|
pageInit();
|
|
|
|
|
|
+
|
|
|
window.onunload = function(){
|
|
|
stopPlay();
|
|
|
}
|