generalRecord.html 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657
  1. <!doctype html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8" />
  5. <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7,chrome=1" />
  6. <title>战绩总览</title>
  7. <meta name="description" content="" />
  8. <meta name="keywords" content="" />
  9. <link rel="stylesheet" href="css/morris.css" />
  10. <link rel="stylesheet" href="css/personal.css" />
  11. <!--[if gt IE 6]><!-->
  12. <!--<script type="text/javascript">
  13. !function(t){t.loadScript(["http://szhuodong.duowan.com/feq/lolbox/yy-f2e-header-lolbox.min"])}(function(){function t(t){var e=n(t);document.write(e)}function n(t){for(var n,r="",c=0;n=t[c];c++)r+=e(n);return r}function e(t){var n=[unescape("%3Cscript%20type%3D%22text/javascript%22%20src%3D%22"),"",unescape("%22%3E%3C/script%3E")],e=new Date;return e.setSeconds(0),e.setMilliseconds(0),e=e.getTime(),t+="?t_="+e,n[1]=t,n.join("")}return{loadScript:function(n){n&&n.length&&n instanceof Array&&t(n)}}}())
  14. </script>-->
  15. <!--<![endif]-->
  16. <!--[if IE 7]>
  17. <style>
  18. .hero-nav,.blacklist{behavior: url(js/PIE.htc);}
  19. </style>
  20. <![endif]-->
  21. <script>var playerMostUsedHero = null,jiathis_config;</script>
  22. </head>
  23. <body style="overflow:hidden;" scroll="no">
  24. <div class="personal-nav-wrap"> <div class="mod-tabs-hd coll-2">
  25. <ul class="mod-tabs-trigger J_nav" id="modeTabs">
  26. <li class="stat-sign" stat-sign="common" stat-desc="常规模式" data-name="historyRecord">
  27. <a href="javascript:;">战斗记录</a>
  28. </li>
  29. <li class="selected stat-sign" stat-sign="zonghe" stat-desc="综合统计" data-name="generalRecord">
  30. <a href="javascript:;">战绩总览</a>
  31. </li>
  32. <!--<li class="stat-sign" stat-sign="2015" stat-desc="stat-desc" data-name="goodAt">
  33. <a href="javascript:;">擅长领域</a>
  34. </li>
  35. <li class="stat-sign" data-name="achievement">
  36. <a href="javascript:;">个人称号</a>
  37. </li>-->
  38. </ul>
  39. <div class="common-page__control clearfix">
  40. <a href="javascript:;" class="common-page__goBack"></a>
  41. <a href="javascript:;" class="common-page__reflash"></a>
  42. </div>
  43. </div>
  44. </div>
  45. <div class="box personal" style="width:600px;padding:15px;">
  46. <div class="no-data-tip hide">
  47. <img src="img/clothes-commit-fail.png">
  48. <p></p>
  49. </div>
  50. <div class="box-bd clearfix">
  51. <div class="intro b-bottom" id="personalInfo">
  52. </div>
  53. <div class="mod-tabs clearfix personal-tabs">
  54. <div class="mod-tabs-bd fighting-history__view"></div>
  55. </div>
  56. </div>
  57. <!-- 广告位(下文有js从这里拿节点数据) -->
  58. <!-- <div class="ad-module" style="display: none;"><script type="text/javascript" src="http://gt.yy.com/api/g?loc=xinbanlola3"></script></div> -->
  59. <script id="flagTemp" type="text/template">
  60. <%
  61. var flagClass = '', flagMsg = '';
  62. var largestNum = data.continuousNum;
  63. if(data.statCode == 0) {//败
  64. if(largestNum >= 10) {
  65. flagClass = "flag flag4";
  66. flagMsg = "连跪衰神";
  67. } else {
  68. flagClass = "flag flag2";
  69. flagMsg = translateToCh(largestNum) + "连败";
  70. }
  71. } else {//胜
  72. if(largestNum >= 10) {
  73. flagClass = "flag flag3";
  74. flagMsg = "连胜王者";
  75. } else {
  76. flagClass = "flag flag1";
  77. flagMsg = translateToCh(largestNum) + "连胜";
  78. }
  79. }
  80. function translateToCh(num) {
  81. var chname;
  82. if(num < 3) return;
  83. switch(num) {
  84. case 3: chname = "三";break;
  85. case 4: chname = "四";break;
  86. case 5: chname = "五";break;
  87. case 6: chname = "六";break;
  88. case 7: chname = "七";break;
  89. case 8: chname = "八";break;
  90. case 9: chname = "九";break;
  91. };
  92. return chname;
  93. }
  94. %>
  95. <span class="<%=flagClass%>"><i></i><%=flagMsg%></span>
  96. </script>
  97. <!-- 用户信息渲染模板 -->
  98. <script id="personalInfoTemp" type="text/template">
  99. <%
  100. var level = data.level;
  101. var zdlData = data.tier_rank;
  102. var global = data.global;
  103. var tier = zdlData.tier;
  104. var duanwei = tier.name_cn;
  105. var url = (data.focus == "0") ? (global.aUrl + "addFocus") : (global.aUrl + "removeFocus");
  106. var tierName;
  107. if (zdlData && zdlData['tier'] && zdlData['tier']['const'] > 0) {
  108. tierName = zdlData['tier']['name_cn'] + ' ' + zdlData['rank']['name'];
  109. } else {
  110. tierName = '-';
  111. }
  112. %>
  113. <div class="info">
  114. <div class="avatar">
  115. <a href="<%=global.href%>" class="stat-sign" stat-sign="stand" stat-desc="点击/战绩页">
  116. <img src="<%=data.url_img%>" />
  117. </a><div class="p_level"><%=level%></div>
  118. <img src="img/achievement/placeholder.png" class="userMedal">
  119. </div>
  120. <div class="text">
  121. <div class="name-info clearfix">
  122. <a class="name" href="javascript:;" title="<%=data.pn%>"><%=data.pn%></a>
  123. <span class="name-info__nameServer">(<%=data.game_zone.alias%>)</span>
  124. <span class="userInfo-common__focus <%=data.isSelf ? 'hide' : ''%>">
  125. <%if(data.followed) {%>
  126. <a class="attention already" data-action="removeFocus"></a>
  127. <%} else {%>
  128. <a class="attention" data-action="addFocus"></a>
  129. <%} %>
  130. </span>
  131. </div>
  132. <div class="more-info"">
  133. <span><%=tierName%></span>
  134. <span class="line-small"></span>
  135. <span>点赞 <%=data.like%></span>
  136. <span class="line-small"></span>
  137. <span class="blacklist-content2">
  138. <label>拉黑 <%=data.unlike%></label>
  139. </span>
  140. <!-- <span class="blacklist">隐藏拉黑</span> -->
  141. </div>
  142. </div>
  143. </div>
  144. <!-- 段位信息 -->
  145. <%
  146. if(tier){
  147. %>
  148. <div class="duan-wei clearfix">
  149. <img src="img/user-common__fighting.png">
  150. <p class="duan-wei-msg"><%=data.box_score%></p>
  151. </div>
  152. <%}%>
  153. <!-- 常用英雄列表 -->
  154. <div class="user-hero__box">
  155. <div class="user-hero__header clearfix">
  156. <h3>常用英雄</h3>
  157. <!-- 更多常用英雄URL -->
  158. <%
  159. var moreHeroURL = ['championsStat.html?serverName=', data.game_zone.server_name, '&playerName=', data.pn, '&userId=', data.user_id, '&gameZone=', data.game_zone.pinyin].join('');
  160. var historyRecordURL = ['historyRecord.html?serverName=', data.game_zone.server_name, '&playerName=', data.pn, '&userId=', data.user_id, '&gameZone=', data.game_zone.pinyin].join('');
  161. %>
  162. <a href="<%= moreHeroURL %>">更多》</a>
  163. </div>
  164. <ul class="user-hero__list clearfix">
  165. <%
  166. var heroListData = data.champion_performance_list.slice(0,5);
  167. _.each(heroListData, function(item, i){
  168. %>
  169. <li>
  170. <a href="<%= historyRecordURL %>&championId=<%= item.champion.id %>">
  171. <img src="<%= item.champion.url_img['40x40'] %>">
  172. <div class="user-hero__mask"></div>
  173. <div class="user-hero__info">
  174. <p class="user-hero__info--title">胜率</p>
  175. <p><%= item.win_rate %>%</p>
  176. <div class="user-hero__info--tips">
  177. <p>最近场次: <%= item.times %></p>
  178. </div>
  179. </div>
  180. </a>
  181. </li>
  182. <% }); %>
  183. </ul>
  184. </div>
  185. </script>
  186. <script id="kdaTemp" type="text/template">
  187. <%
  188. //场均KDA
  189. var statKda = data.stat_kda;
  190. console.log(statKda)
  191. var honor = statKda.best_kill_in_cn;
  192. //KDA中 胜负场及胜率
  193. var winNum = statKda.total_win;
  194. var loseNum = statKda.total_lose;
  195. var rate = winNum / (winNum + loseNum) * 100;
  196. //设置打野浮窗颜色
  197. var colorsArr = ['#fbb28f','#cea9d7','#fa9f9f','#80c989','#9dc7eb'], setColors = [], setData = [], i=0;
  198. var statPosition = data.stat_position;
  199. if(statPosition.total_game != 0) {
  200. for(var key in statPosition) {
  201. var value = statPosition[key];
  202. if(key != 'total_game' && value != 0) {
  203. var keyTxt = '';
  204. switch(key) {
  205. case 'adc': keyTxt = 'ADC';break;
  206. case 'jungler': keyTxt = '打野';break;
  207. case 'mid': keyTxt = '中单';break;
  208. case 'support': keyTxt = '辅助';break;
  209. case 'top': keyTxt = '上单';break;
  210. };
  211. setData.push({
  212. value: value,
  213. label: keyTxt
  214. });
  215. setColors.push(colorsArr[i++]);
  216. }
  217. }
  218. }
  219. //打野为0时的处理
  220. var daYeClass = statPosition.total_game != 0 ? 'hide' : '';
  221. %>
  222. <div class="arrow-hover-wrap daye-hover">
  223. <i class="avatar-arrow"></i>
  224. <p>近7天召唤师峡谷排位赛与匹配赛使用英雄统计:</p>
  225. <div class="arrow-hover-content">
  226. <div class="da-ye-types">
  227. <%
  228. _.each(setData, function(item, i) {
  229. %>
  230. <a><i style="background-color:<%=setColors[i]%>"></i><%=item.label%></a>
  231. <%});%>
  232. </div>
  233. </div>
  234. </div>
  235. <div class="arrow-hover-wrap kda-hover">
  236. <i class="avatar-arrow"></i>
  237. <div class="arrow-hover-top">
  238. <div class="win-lost">
  239. <p><%=winNum%>胜 / <%=loseNum%>负</p>
  240. <div class="win-line">
  241. <em style="width:<%=rate%>%;"></em>
  242. </div>
  243. </div>
  244. </div>
  245. <p>最近20场召唤师峡谷排位赛与匹配赛的数据表现:</p>
  246. <div class="arrow-hover-content">
  247. <div class="da-ye-types">
  248. <a>击杀(K): <span style="color:#408bcb;"><%=statKda.total_k%></span></a>
  249. <a>死亡(D): <span style="color:#408bcb;"><%=statKda.total_d%></span></a>
  250. <a>助攻(A): <span style="color:#408bcb;"><%=statKda.total_a%></span></a>
  251. </div>
  252. <div class="formula">
  253. 计算公式:(K+A)/D*3
  254. </div>
  255. </div>
  256. </div>
  257. <div class="arrow-hover-wrap kill-hover">
  258. <i class="avatar-arrow"></i>
  259. <p>最近<span style="color:#408bcb;"><%=statKda.total_game%></span>场荣誉成就</p>
  260. <div class="arrow-hover-content">
  261. <div class="da-ye-types">
  262. <a>三杀 <span style="color:#408bcb;"><%=statKda.total_kill3%></span>次</a>
  263. <a>四杀 <span style="color:#408bcb;"><%=statKda.total_kill4%></span>次</a>
  264. <a>五杀 <span style="color:#408bcb;"><%=statKda.total_kill5%></span>次</a>
  265. <a>超神 <span style="color:#408bcb;"><%=statKda.total_brilliant_largest_killing_spree%></span>次</a>
  266. </div>
  267. </div>
  268. <p>自定义成就不显示</p>
  269. </div>
  270. <ul>
  271. <li class="da-ye2 <%=daYeClass%>">
  272. <div class="percent2">
  273. <h2>0</h2>
  274. </div>
  275. </li>
  276. <li class="kda-li">
  277. <p>近<%=statKda.total_game%>场均KDA</p>
  278. <div class="percent2">
  279. <h2><%=statKda.average_kda%></h2>
  280. <p><%=statKda.average_k%>/<%=statKda.average_d%>/<%=statKda.average_a%></p>
  281. </div>
  282. </li>
  283. <li class="kill-li">
  284. <p>近<%=statKda.total_game%>场荣誉</p>
  285. <div class="percent2">
  286. <h2><%=honor ? honor : '无'%></h2>
  287. </div>
  288. </li>
  289. </ul>
  290. </script>
  291. <!-- 最近比赛渲染模板 -->
  292. <script id="historyTemp" type="text/template">
  293. <%_.each(data, function(item) {
  294. var winClass = item.battle_result ? "" : "red";
  295. var resultName = item.battle_result ? "胜利" : "失败";
  296. var champion = item.champion;
  297. // 比赛时间转换
  298. var localTime = moment.utc(item.created).toDate();
  299. localTime = moment(localTime).format('YYYY-MM-DD HH:mm:ss');
  300. var timeArr = localTime.split(' ');
  301. var monDayArr = timeArr[0].split('-');
  302. var hourMinArr = timeArr[1].split(':');
  303. var time = monDayArr[1] + '-' + monDayArr[2] + ' ' + hourMinArr[0] + ':' + hourMinArr[1];
  304. %>
  305. <li class="clearfix history_li">
  306. <img src="http://img.lolbox.duowan.com/champions/<%=champion.name%>_40x40.jpg" title="<%=champion.title%>">
  307. <div class="history_info">
  308. <p class="type"><%=item.game_type.name_cn%></p>
  309. <p class="time"><%=time%></p>
  310. </div>
  311. <div class="result <%=winClass%>"><%=resultName%></div>
  312. </li>
  313. <%});%>
  314. </script>
  315. <!-- 常用英雄渲染模板 -->
  316. <script id="commonHeroTemp" type="text/template">
  317. <%
  318. var sn = data.game_zone.server_name;
  319. var pn = data.pn;
  320. var baseUrl = data.heroWindowUrl;
  321. // var data = data.mostUsedHeros;
  322. var userId = data.user_id;
  323. var gameZone = data.game_zone.pinyin;
  324. var keyDatas = data.champion_performance_list, data_len = keyDatas.length;
  325. var commonHeroUrl = 'championsStat.html?serverName='+encodeURI(sn)+'&playerName='+encodeURI(pn)+'&userId='+userId + '&gameZone='+gameZone;
  326. %>
  327. <a class="hero-tip stat-sign" href="<%=commonHeroUrl%>" stat-sign="click/more hero" stat-desc="点击/更多常用英雄">
  328. <span>常用英雄</span>
  329. </a>
  330. <ul class="mod-pic clearfix" id="commonHero">
  331. <%
  332. _.each(keyDatas, function(item, i) {
  333. var firstClass = i === 0 ? "first" : "";
  334. var champion = item.champion;
  335. var championId = champion.id;
  336. var href = 'recordlist.html?serverName='+sn+'&playerName='+pn+'&hero='+champion.name +'&userId='+userId+'&gameZone=' + gameZone + '&championId=' + championId;
  337. %>
  338. <li class="mod-pic-li <%=firstClass%>">
  339. <a class="core" href="<%=href%>">
  340. <img class="core-img" src="http://img.lolbox.duowan.com/champions/<%=champion.name%>.jpg">
  341. <p>胜率:<%=item.win_rate%>%</p>
  342. </a>
  343. </li>
  344. <%});
  345. %>
  346. </ul>
  347. </script>
  348. <!-- 近20场比赛 -->
  349. <script id="echarts-tpl" type="text/template">
  350. <div class="mod-tabs-content no-phone-card">
  351. <div class="mod-top clearfix">
  352. <div class="clearfix da-ye-bd">
  353. <div class="recent-game-wrap fl">
  354. <div class="charts-round-wrap composite-rate">
  355. <h3 class="charts-title">综合胜率</h3>
  356. <div id="compositeRateContainer" class="charts-wrap"></div>
  357. <div class="round-mask">
  358. <!--<h3>综合胜率</h3>
  359. <p><%=data.stat_perf.kda.average_win_rate%>%</p>-->
  360. <h3><%=data.stat_perf.kda.average_win_rate%>%</h3>
  361. </div>
  362. <div class="charts-more">
  363. <h3>&nbsp;</h3>
  364. <p>
  365. <span class="col-l">场均击杀</span>
  366. <span class="col-r"><%=data.stat_perf.kda.average_k%></span>
  367. </p>
  368. <p>
  369. <span class="col-l">场均死亡</span>
  370. <span class="col-r"><%=data.stat_perf.kda.average_d%></span>
  371. </p>
  372. <p>
  373. <span class="col-l">场均助攻</span>
  374. <span class="col-r"><%=data.stat_perf.kda.average_a%></span>
  375. </p>
  376. </div>
  377. </div>
  378. </div>
  379. <div class="split-line one"></div>
  380. <%
  381. // 确定位置和对应的胜率
  382. var userPosition = data.stat_perf.position_perf.position_priority[0] || 'adc';
  383. var userPositonName = {'adc': '输出', 'support': '辅助', 'jungler': '打野'}; // 位置映射关系表
  384. var totalWinRate = (data.stat_perf.position_perf.win_rate_adc + data.stat_perf.position_perf.win_rate_support + data.stat_perf.position_perf.win_rate_jungler);
  385. var positionWinRate = data.stat_perf.position_perf['win_rate_'+userPosition]|| 0;
  386. // 各个位置总胜场计算
  387. var TotalWin = {};
  388. TotalWin.totalWinNum_adc = parseInt(data.stat_perf.position_perf.win_adc) + parseInt(data.stat_perf.position_perf.lose_adc);
  389. TotalWin.totalWinNum_support = parseInt(data.stat_perf.position_perf.win_support) + parseInt(data.stat_perf.position_perf.lose_support);
  390. TotalWin.totalWinNum_jungler = parseInt(data.stat_perf.position_perf.win_jungler) + parseInt(data.stat_perf.position_perf.lose_jungler);
  391. var currentPositionWinNum = TotalWin['totalWinNum_'+userPosition]
  392. // 数据构造
  393. var Position = data.stat_perf.position_perf;
  394. var Database = {
  395. // 饼图名字关系表
  396. t_chart__name: {
  397. 'jungler': {'name1': '参团率', 'name2': '小龙率', 'name3': 'GANK率'},
  398. 'adc': {'name1': '存活率', 'name2': '参团率', 'name3': '输出率'},
  399. 'support': {'name1': '存活率', 'name2': '参团率', 'name3': '视野率'}
  400. },
  401. // 概率关系表
  402. t_chart_rate: {
  403. 'jungler': {'rate1': Position.rate_assists_jungler, 'rate2': Position.rate_dragon_killed_jungler || 0, 'rate3': Position.rate_gank_jungler},
  404. 'adc': {'rate1': Position.rate_keep_alive_adc, 'rate2': Position.rate_assists_adc, 'rate3': Position.rate_damage_adc},
  405. 'support': {'rate1': Position.rate_keep_alive_support, 'rate2': Position.rate_assists_support, 'rate3': Position.rate_vision_support}
  406. }
  407. }
  408. %>
  409. <div class="jungle-area-wrap fl">
  410. <div class="charts-round-wrap jungle-area">
  411. <h3 class="charts-title">战斗力构成</h3>
  412. <div id="jungleAreaContainer" class="charts-wrap"></div>
  413. <div class="round-mask" title="最近使用<%=userPositonName[userPosition]%>:<%=currentPositionWinNum%>场">
  414. <!--<h3><%=userPositonName[userPosition]%>胜率</h3>
  415. <p class="data-userPosition"><%=positionWinRate.toFixed(1)%>%</p>-->
  416. <h3 class="data-userPosition" data-percent="<%= data.box_score / 20000 * 100 %>"><%=data.box_score%></h3>
  417. </div>
  418. <div class="charts-more best-position__data">
  419. <h3><a href="http://lol.duowan.com/1611/343923769188.html" target="_blank" style="color: red;font-weight:400;">战斗力波动公告</a></h3>
  420. <p>
  421. <span class="col-l">基础分</span>
  422. <span class="col-r"><%=data.elo_score%></span>
  423. </p>
  424. <p>
  425. <span class="col-l">胜率分</span>
  426. <span class="col-r"><%=data.win_ratio_score%></span>
  427. </p>
  428. <p>
  429. <span class="col-l">胜场分</span>
  430. <span class="col-r"><%=data.win_battle_score%></span>
  431. </p>
  432. </div>
  433. </div>
  434. </div>
  435. </div>
  436. </div>
  437. <div class="mod-bottom">
  438. <div class="right-part">
  439. <div class="right-hd">
  440. <h2>最近比赛</h2>
  441. <span class="first-win">
  442. <span id="firstMsg" class="first-msg"></span>
  443. <div class="first-win-hover hide">
  444. <i class="avatar-arrow"></i>
  445. <span id="firstTime" class="first-time">额外奖励倒计时:<span class="f-time"></span></span>
  446. </div>
  447. </span>
  448. <span id="flag"></span>
  449. <a id="moreGameResult" class="more" style="padding-right:5px;">更多<i></i></a>
  450. </div>
  451. <div class="right-bd">
  452. <ul id="history">
  453. </ul>
  454. </div>
  455. </div>
  456. <%
  457. // 比赛信息表格数据重组 - by zengfukun@foxmail.com
  458. //---------------------
  459. // 经典对战
  460. var class_total = data.total_win_normal + data.total_lose_normal;
  461. var class_winRate = parseInt((data.total_win_normal / class_total)*100) || 0;
  462. //极地大乱斗
  463. var aram_total = data.total_win_aram + data.total_lose_aram;
  464. var aram_winRate = parseInt((data.total_win_aram / aram_total)*100) || 0;
  465. //人机
  466. var bot_total = data.total_win_bot + data.total_lose_bot;
  467. var bot_winRate = parseInt((data.total_win_bot / bot_total)*100) || 0;
  468. //S7排位赛
  469. var S7_total = data.formatted_ranked_history.s7.lo + data.formatted_ranked_history.s7.w;
  470. var S7_winRate = parseInt((data.formatted_ranked_history.s7.w / S7_total)*100) || 0;
  471. //S6排位赛
  472. var S6_total = data.formatted_ranked_history.s6.lo + data.formatted_ranked_history.s6.w;
  473. var S6_winRate = parseInt((data.formatted_ranked_history.s6.w / S6_total)*100) || 0;
  474. //S5排位赛
  475. if ( data.formatted_ranked_history.s5 ){
  476. var S5_total = data.formatted_ranked_history.s5.lo + data.formatted_ranked_history.s5.w;
  477. var S5_winRate = parseInt((data.formatted_ranked_history.s5.w / S5_total)*100) || 0;
  478. }
  479. //S4排位赛
  480. if ( data.formatted_ranked_history.s4 ){
  481. var S4_total = data.formatted_ranked_history.s4.lo + data.formatted_ranked_history.s4.w;
  482. var S4_winRate = parseInt((data.formatted_ranked_history.s4.w / S4_total)*100) || 0;
  483. }
  484. %>
  485. <div class="left-part clearfix">
  486. <div class="p-table">
  487. <div class="table-history">
  488. <table>
  489. <thead>
  490. <tr>
  491. <th width="70">比赛类型</th>
  492. <th width="50">总场次</th>
  493. <th width="50">胜率</th>
  494. <th width="50">胜场</th>
  495. <th width="50">负场</th>
  496. <th width="50">段位</th>
  497. <th class="last" width="50">胜点</th>
  498. </tr>
  499. </thead>
  500. <tbody>
  501. <tr>
  502. <td width="70">匹配</td>
  503. <td width="50"><%=class_total%></td>
  504. <td width="50"><%=class_winRate%>%</td>
  505. <td class="table-win" width="50"><%=data.total_win_normal%></td>
  506. <td class="table-lose" width="50"><%=data.total_lose_normal%></td>
  507. <td width="50">--</td>
  508. <td class="last" width="50">--</td>
  509. </tr>
  510. <tr class="<% if ( data.formatted_ranked_history.s5 ) { %>table-history__lastseason<%}%>">
  511. <td width="70" class="toggle-s4-s5">S7排位赛<% if ( data.formatted_ranked_history.s7 ) { %><i class="table-arrow"></i><%}%></td>
  512. <td width="50"><%=S7_total%></td>
  513. <td width="50"><%=S7_winRate%>%</td>
  514. <td class="table-win" width="50"><%=data.formatted_ranked_history.s7.w%></td>
  515. <td class="table-lose" width="50"><%=data.formatted_ranked_history.s7.lo%></td>
  516. <%
  517. // 段位计算
  518. var zdlData = data.tier_rank;
  519. var tierName;
  520. if (zdlData && zdlData['tier'] && zdlData['tier']['const'] > 0) {
  521. tierName = zdlData['tier']['name_cn'];
  522. if ( zdlData['tier']['const'] < 6 ){
  523. tierName += ' ' + zdlData['rank']['name'];
  524. }
  525. } else {
  526. tierName = '-';
  527. }
  528. %>
  529. <td width="50"><%=tierName%></td>
  530. <td class="last" width="50"><%=data.tier_rank.league_points%></td>
  531. </tr>
  532. <% if ( data.formatted_ranked_history.s6 ){ %>
  533. <tr class="s4-s5">
  534. <td width="70">S6排位赛</td>
  535. <td width="50"><%=S6_total%></td>
  536. <td width="50"><%=S6_winRate%></td>
  537. <td class="table-win" width="50"><%=data.formatted_ranked_history.s6.w%></td>
  538. <td class="table-lose" width="50"><%=data.formatted_ranked_history.s6.lo%></td>
  539. <td width="50">--</td>
  540. <td class="last" width="50">--</td>
  541. </tr>
  542. <% } %>
  543. <% if ( data.formatted_ranked_history.s5 ){ %>
  544. <tr class="s4-s5">
  545. <td width="70">S5排位赛</td>
  546. <td width="50"><%=S5_total%></td>
  547. <td width="50"><%=S5_winRate%></td>
  548. <td class="table-win" width="50"><%=data.formatted_ranked_history.s5.w%></td>
  549. <td class="table-lose" width="50"><%=data.formatted_ranked_history.s5.lo%></td>
  550. <td width="50">--</td>
  551. <td class="last" width="50">--</td>
  552. </tr>
  553. <% } %>
  554. <tr>
  555. <td width="70">大乱斗</td>
  556. <td width="50"><%=aram_total%></td>
  557. <td width="50"><%=aram_winRate%>%</td>
  558. <td class="table-win" width="50"><%=data.total_win_aram%></td>
  559. <td class="table-lose" width="50"><%=data.total_lose_aram%></td>
  560. <td width="50">--</td>
  561. <td class="last" width="50">--</td>
  562. </tr>
  563. <tr>
  564. <td width="70">人机</td>
  565. <td width="50"><%=bot_total%></td>
  566. <td width="50"><%=bot_winRate%>%</td>
  567. <td class="table-win" width="50"><%=data.total_win_bot%></td>
  568. <td class="table-lose" width="50"><%=data.total_lose_bot%></td>
  569. <td width="50">--</td>
  570. <td class="last" width="50">--</td>
  571. </tr>
  572. </tbody>
  573. </table>
  574. </div>
  575. </div>
  576. <!-- <div class="record-ad__wrap"></div> -->
  577. </div>
  578. </div>
  579. </div>
  580. </script>
  581. <script src="js/jquery-1.11.1.min.js"></script>
  582. <script src="js/jquery-migrate-1.2.1.min.js"></script>
  583. <script src="js/highcharts.js"></script>
  584. <script src="js/jquery.nicescroll.min.js"></script>
  585. <script src="js/jquery.cookie.js"></script>
  586. <script src="js/underscore.js"></script>
  587. <!--<script type="text/javascript" src="http://sz.duowan.com/s/ya/ya.1.3.1-min.js"></script>-->
  588. <!--广告位统计-->
  589. <!--<script src="http://sz.duowan.com/resource/adstat.1.0.0.js"></script>-->
  590. <script src="js/moment.min.js"></script>
  591. <!--<script src="js/new_stat.js"></script>-->
  592. <script src="js/personal_v3.0.js"></script>
  593. <script type="text/javascript">
  594. $(function() {
  595. new Personal('tab1');
  596. });
  597. </script>
  598. <!--海度统计-->
  599. <script type="text/javascript">_hiido_no=0;_hiido_wid=["lbox"];</script>
  600. <script src="http://www.duowan.com/duowan.js" type="text/javascript"></script>
  601. <!--百度统计-->
  602. <script>
  603. var _hmt = _hmt || [];
  604. (function() {
  605. var hm = document.createElement("script");
  606. hm.src = "//hm.baidu.com/hm.js?72772dda37b1e926733138415981abcf";
  607. var s = document.getElementsByTagName("script")[0];
  608. s.parentNode.insertBefore(hm, s);
  609. })();
  610. </script>
  611. <!--[if gt IE 6]><!-->
  612. <!--<script type="text/javascript">
  613. window.onerror = function(a,b,c){ return true};!function(t){t.loadScript(["http://szhuodong.duowan.com/feq/lolbox/yy-f2e-lolbox.min"])}(function(){function t(e,a){var n=a[e];if(n){e++;var o=document.createElement("script");o.type="text/javascript",o.setAttribute("async","async"),o.onload=o.onreadystatechange=function(){return o.readyState&&"complete"!==o.readyState&&"loaded"!==o.readyState?!1:(o.onload=o.onreadystatechange=null,void t(e,a))};var c=new Date;c.setSeconds(0),c.setMilliseconds(0),c=c.getTime(),o.async=!0,o.src=n+"?_="+c,document.getElementsByTagName("head")[0].appendChild(o)}}return{loadScript:function(e){e&&e.length&&e instanceof Array&&t(0,e)}}}());
  614. </script>-->
  615. <!--<![endif]-->
  616. </body>
  617. </html>