app.119acb80bad09538675f.js 10 KB

12
  1. webpackJsonp([3],{"7u9s":function(t,e){},ENeJ:function(t,e){},NHnr:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});n("j1ja");var a=n("7+uW"),o={render:function(){var t=this.$createElement,e=this._self._c||t;return e("div",{attrs:{id:"app"}},[e("router-view")],1)},staticRenderFns:[]};var i=n("VU/8")({name:"App"},o,!1,function(t){n("7u9s")},null,null).exports,c=n("/ocq");a.default.use(c.a);var r=new c.a({routes:[{path:"/",name:"home",component:function(t){return n.e(0).then(function(){var e=[n("tHxJ")];t.apply(null,e)}.bind(this)).catch(n.oe)}},{path:"/PersonalCenter",name:"PersonalCenter",component:function(t){return n.e(1).then(function(){var e=[n("RYJU")];t.apply(null,e)}.bind(this)).catch(n.oe)}}],scrollBehavior:function(t,e,n){return n||{x:0,y:0}}});r.beforeEach(function(t,e,n){"/StRollBallpage"==t.path&&(t.query.isTrue=!0),n()});var u=r,s=n("NYxO"),d=n("mvHQ"),l=n.n(d),f=(n("gAs1"),{setCache:function(t,e){if(e instanceof Array){var n=l()(e);window.sessionStorage.setItem(t,n)}else window.sessionStorage.setItem(t,e)},getCache:function(t){return window.sessionStorage.getItem(t)},setItem:function(t,e){if(e instanceof Array){var n=l()(e);localStorage.setItem(t,n)}else localStorage.setItem(t,e)},getItem:function(t){return localStorage.getItem(t)},timer:function(t,e,n){setInterval(function(){++e<10&&(e="0"+e),60==e&&(t++,e="00"),n&&n(t,e)},1e3)},bettingFunction:function(t,e,n,a,o,i,c,r,u){var s=!0,d=!1;t.forEach(function(a,o){e.id==a.id&&(n.forEach(function(n){e.id==n.id&&(r&&r(n,!1),t.splice(o,1))}),s=!1)}),s&&(c>=10?d=!0:(t.push(e),t.forEach(function(t){e.id==t.id&&n.forEach(function(t){e.id==t.id&&r&&r(t,!0)})})));var l={title:o,data:t},f=[];1e4!=i?a[i]=l:a?a.length>0&&a.push(l):f.push(l),u&&u(a,f,d)},publicBetMethod:function(t,e,n,a,o,i,c,r,u,s,d,l){var f=!0,g=!0,h=!1;t[a].home_team=i.home,t[a].guest_team=i.guest,t[a].playName=c,t[a].name=r,t[a].match_id=u,t[a].ballId=s;var m={title:e,data:[t[a]]};o.length>0?(o.forEach(function(o){o.title==e&&(o.data.forEach(function(t,e){t.id==n&&(o.data.splice(e,1),g=!1)}),g&&(d>=10?h=!0:o.data.push(t[a])),f=!1)}),f&&(d>=10?h=!0:o.push(m))):o.push(m),l&&l(o,h)},publicBetting:function(t,e,n,a,o,i,c,r,u,s,d,l,f,g,h){var m=!0,p=!0,w=!1;t[a].matchData[o].oddsData[i].home_team=s.home,t[a].matchData[o].oddsData[i].guest_team=s.guest,t[a].matchData[o].oddsData[i].playName=d,t[a].matchData[o].oddsData[i].name=l,t[a].matchData[o].oddsData[i].ballId=f;var E={title:e,data:[t[a].matchData[o].oddsData[i]]};c.length>0?(c.forEach(function(c){c.title==e&&(c.data.forEach(function(t,e){t.id==n&&(c.data.splice(e,1),p=!1)}),p&&(g>=10?w=!0:c.data.push(t[a].matchData[o].oddsData[i])),m=!1)}),m&&(g>=10?w=!0:c.push(E))):c.push(E),h&&h(c,w)},strandPublicBetting:function(t,e,n,a,o,i,c,r,u,s,d,l,f,g,h,m){var p=!0,w=!0,E=!1;t[a].matchData[o].oddsData[i].playName=s,t[a].matchData[o].oddsData[i].home_team=f,t[a].matchData[o].oddsData[i].guest_team=g,t[a].matchData[o].oddsData[i].name=d,t[a].matchData[o].oddsData[i].ballId=l;var y={title:e,data:[t[a].matchData[o].oddsData[i]]};c.length>0?(c.forEach(function(r){r.title==e&&(r.data.forEach(function(t,e){t.id==n&&(r.data.splice(e,1),w=!1)}),w&&(h>=10?E=!0:(c.forEach(function(t){if(t.data.length>0)for(var e=0;e<t.data.length;e++)if(t.data[e].match_id==u){t.data.splice(e,1);break}}),r.data.push(t[a].matchData[o].oddsData[i]))),p=!1)}),p&&(h>=10?E=!0:(c.forEach(function(t){if(t.data.length>0)for(var e=0;e<t.data.length;e++)if(t.data[e].match_id==u){t.data.splice(e,1);break}}),c.push(y)))):c.push(y),m&&m(c,E)},getBettingId:function(t,e,n){t&&t.forEach(function(t,a){t.title==e&&n&&n(t.data,a)})},ajaxTimerFun:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e4,n=setInterval(function(){t&&t(n)},e)},betPlay:function(t,e){var n=0,a=e.length;return n=this.oddsAlgorithm(t,e),function(t){return{title:t+"串1",index:function(t){for(var e=1,n=a;n>a-t;n--)e*=n;return e}(t)/function(t){for(var e=1,n=t;n>1;n--)e*=n;return e}(t),odds:n}}(t)},oddsAlgorithm:function(t,e){var n=[],a=t,o=[];e.forEach(function(t){n.push(t.odds)});for(var i=0;i<Math.pow(2,n.length);i++){for(var c=0,r="",u=0;u<n.length;u++)i>>u&1&&(c++,r+=n[u]+",");if(c==a){var s=r.split(",");s.pop(),o.push(s)}}var d=0;return o.forEach(function(t){var e=1;t.forEach(function(t){e*=1+1*t}),d+=1*e-1}),d},oddsDataUpdate:function(t,e,n,a){"1"==n?(t.forEach(function(t){e.forEach(function(n,a){t.lg_id==n.lg_id&&(t.matchData.forEach(function(t){n.matchData.forEach(function(e,a){t.match_id==e.match_id&&(t.oddsData.forEach(function(t){e.oddsData.forEach(function(n){t.id==n.id&&(t.odds>n.odds?t.change="rising":t.odds<n.odds?t.change="falling":t.change="",e.oddsData.splice(a,1))})}),n.matchData.splice(a,1))})}),e.splice(a,1))})}),a&&a()):"2"==n&&(t.forEach(function(t){e.forEach(function(n,a){t[0].p_code==n[0].p_code&&(t.forEach(function(t){n.forEach(function(e,a){t.id==e.id&&(t.odds>e.odds?t.change="rising":t.odds<e.odds?t.change="falling":t.change="",n.splice(a,1))})}),e.splice(a,1))})}),a&&a())}});a.default.use(s.a);var g={gameRatio:"",activity:"StMorningPlate",ball_code:"zq",paly_code:"concede",controlRouting:"",loading:"",rgShow:!1,macth_id:"",betting:[],passBetting:JSON.parse(f.getItem("passBetting")),bettingType:1,leagueChoose:"",leagueData:[],deleteType:"",token:"",limit:0,passLimit:f.getItem("passLimit"),playAlias:JSON.parse(f.getItem("playAlias"))},h={newGameRatio:function(t,e){t.gameRatio=e},newActivity:function(t,e){t.activity=e},newBallCode:function(t,e){t.ball_code=e},newPaly_code:function(t,e){t.paly_code=e},newControlRouting:function(t,e){t.controlRouting=e},newLoading:function(t,e){t.loading=e},newRgShow:function(t,e){t.rgShow=e},newMacth_id:function(t,e){t.macth_id=e},newBetting:function(t,e){var n=0;e&&e.forEach(function(t){n+=t.data.length}),t.betting=e,t.limit=n},newPassBetting:function(t,e){var n=0;e&&e.forEach(function(t){n+=t.data.length}),t.passBetting=e,f.setItem("passBetting",e),t.passLimit=n,f.setItem("passLimit",n)},newBettingType:function(t,e){t.bettingType=e},newLeagueChoose:function(t,e){t.leagueChoose=e},newLeagueData:function(t,e){t.leagueData=e},newToken:function(t,e){t.token=e,f.setItem("token",e)},newDeleteType:function(t,e){t.deleteType=e},newPassLimit:function(t,e){t.limit=e,f.setItem("passLimit",e)},newPlayAlias:function(t,e){t.playAlias=e,f.setItem("playAlias",e)}},m=new s.a.Store({state:g,getters:{getGameRatio:function(t){return t.gameRatio},getActivity:function(t){return t.activity},getBallCode:function(t){return t.ball_code},getPaly_code:function(t){return t.paly_code},getControlRouting:function(t){return t.controlRouting},getLoading:function(t){return t.loading},getRgShow:function(t){return t.rgShow},getMatchId:function(t){return t.macth_id},getBetting:function(t){return t.betting},getPassBetting:function(t){return t.passBetting},getBettingType:function(t){return t.bettingType},getLeagueChoose:function(t){return t.leagueChoose},getLeagueData:function(t){return t.leagueData},getDeleteType:function(t){return t.deleteType},getToken:function(t){return t.token},getLimit:function(t){return t.limit},getPassLimit:function(t){return t.passLimit},getPlayAlias:function(t){return t.playAlias}},mutations:h,actions:{SETACTIVITY:function(t,e){t.commit("newActivity",e)},SET_BALL_CODE:function(t,e){t.commit("newBallCode",e)},SET_PALY_CODE:function(t,e){t.commit("newPaly_code",e)},SET_CONTROLROUTING:function(t,e){t.commit("newControlRouting",e)},GETLOADING:function(t,e){t.commit("newLoading",e)},GETRGSHOW:function(t,e){t.commit("newRgShow",e)},MACTH_ID:function(t,e){t.commit("newMacth_id",e)},SET_BETTING:function(t,e){t.commit("newBetting",e)},SET_PASSBETTING:function(t,e){t.commit("newPassBetting",e)},SET_BETTINGTYPE:function(t,e){t.commit("newBettingType",e)},SET_LEAGUECHOOSE:function(t,e){t.commit("newLeagueChoose",e)},SET_LEAGUEDATA:function(t,e){t.commit("newLeagueData",e)},DEL_TYPE:function(t,e){t.commit("newDeleteType",e)},SET_TOKEN:function(t,e){t.commit("newToken",e)},SET_PASSLIMIT:function(t,e){t.commit("newPassLimit",e)},GETGAMERATIO:function(t,e){t.commit("newGameRatio",e)},SET_PLAYALIAS:function(t,e){t.commit("newPlayAlias",e)}}}),p=n("r8FW"),w=n.n(p),E=(n("ENeJ"),n("mtWM")),y=n.n(E),v=n("//Fk"),T=n.n(v),D=n("mw3O"),_=n.n(D),A=n("Fd2+");y.a.defaults.baseURL="生产环境",y.a.defaults.timeout=1e4;var S="http://sports.5gogo.com";function b(t){return t=S+t}y.a.defaults.headers.post["Content-Type"]="application/x-www-form-urlencoded;charset=UTF-8",y.a.interceptors.request.use(function(t){var e=m.state.token;return e&&(t.headers.Authorization=e),t},function(t){return T.a.error(t)}),y.a.interceptors.response.use(function(t){return 200===t.status?T.a.resolve(t):T.a.reject(t)},function(t){if(console.log(t.response),t.response){switch(t.response.status){case 401:u.replace({path:"/login",query:{redirect:u.currentRoute.fullPath}});break;case 403:Object(A.a)({message:"登录过期,请重新登录",duration:1e3,forbidClick:!0}),localStorage.removeItem("token"),m.commit("loginSuccess",null),setTimeout(function(){u.replace({path:"/login",query:{redirect:u.currentRoute.fullPath}})},1e3);break;case 404:Object(A.a)({message:"网络请求不存在",duration:1500,forbidClick:!0});break;default:Object(A.a)({message:t.response.data.message,duration:1500,forbidClick:!0})}return T.a.reject(t.response)}});var L={get:function(t,e){return new T.a(function(n,a){y.a.get(b(t),{params:e}).then(function(t){n(t)}).catch(function(t){a(t)})})},post:function(t,e){return new T.a(function(n,a){y.a.post(b(t),_.a.stringify(e)).then(function(t){n(t)}).catch(function(t){a(t)})})}};a.default.use(w.a),a.default.config.productionTip=!1,a.default.prototype.$ports={home:{gameList:"/Sports/MatchListWeb/gameList"},match:{matchData:"/Sports/MatchList/matchData",matchState:"/sports/MatchList/matchState"},rollBall:{},gambling:{matchOdds:"/sports/MatchList/matchOdds",getOddsCode:"/sports/MatchList/getOddsCode"},login:{login:"/api/Account/login",reg:"/api/Account/enroll",getAgent:"/api/Account/getAgent",ProfitAndLossRecord:"/api/UserBuy/moneyRecord",prizeRecord:"/api/UserBuy/prizeRecord",rechargeRecord:"/api/UserBuy/rechargeRecord",bettingRecord:"/api/UserBuy/bettingRecord",resetPassword:"/api/account/resetPassword",ChangePayPassword:"/api/Account/resetPayPassword",loginOut:"/Api/Account/Logout",withdrawalsRecord:"/api/userBuy/moneyOutRecord"},betOrder:{Bet:"/Api/Betorder/Bet"},tvlive:{tvlist:"/Sports/MatchListWeb/getBroadcast"}},a.default.prototype.$http=L,a.default.prototype.$public=f,a.default.prototype.$axios=y.a,new a.default({el:"#app",router:u,store:m,components:{App:i},template:"<App/>"})}},["NHnr"]);
  2. //# sourceMappingURL=app.119acb80bad09538675f.js.map