You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
5.9 KiB
HTML

<div id="select_server_box"> <style> /*注意事项*/ .xg-attention{ color: #19b1ea; line-height: 0.5rem; font-size: 0.3rem; padding: 0.3rem 0.4rem; background-color: #d6f0fa; } /*商品信息模块*/ .game-info{ padding: 0.52rem 0.4rem; background-color: #fff; line-height: 1rem; } .game-info-left{ display: block; float: left; margin-right: 0.4rem; } .game-info-img{ display: block; width: 1rem; height: 1rem; border-radius: 5px; } .game-info-right{ overflow: hidden; } .game-info-name{ overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 0.4rem; color: #282828; font-weight: bold; } /*支付方式模块*/ .select-small-number{ background-color: #fff; } .select-small-number .select-small-number-desc{ font-size: 0.34rem; color: #565656; padding-left: 0.36rem; line-height: 0.78rem; background-color: #f2f2f2; } .select-small-number-list{ list-style: none; font-size: 0.34rem; line-height: 1.32rem; color: #565656; padding: 0 0.36rem; } .select-small-number-item{ border-bottom: 1px solid #f2f2f2; padding-left: 0.9rem; background: url("__IMG__/trade1/btn_normal_weixuan@3x.png") no-repeat left center / 0.5rem 0.5rem; } .select-small-number-item.active{ background-image: url("__IMG__/trade1/btn_selected_xuanzhong@3x.png"); } </style><div style="max-width:640px;width:100%;margin:0 auto;"><header class="header"> <a class="xg-back" id="jsselectserver" href="javascript:;"></a> <h1 class="xg-title">选择区服</h1></header><div style="line-height:1.1rem;">&nbsp;</div><main class="xg-main2" style="position:relative;max-width:640px;margin:0 auto;"> <div class="xg-container2"> <!--注意事项 begin--> <div class="xg-attention"> <p>注意事项:提交出售后,该小号将会进行冻结,无法登录。小号卖出后,该小号其他区服的角色将一并出售。</p> </div> <!--end 注意事项--> <empty name="game"> <div class="no_data"> <div class="nodata_content"> <img class="nogame_img" src="__IMG__/trade1/icon_normal_game@3x.png" alt="" height="" width=""> <p class="nodata_txt">暂无游戏,逛逛其他地方吧~</p> </div> </div> <else /> <!--游戏基本信息 begin--> <div class="game-info clf"> <img class="game-info-left game-info-img" src="<notempty name='game.icon_url'>{$game.icon_url}<else />__IMG__/trade1/pic_shangpin@3x.png</notempty>" width="216" height="216" alt=""> <div class="game-info-right"> <p class="game-info-name">{$game.game_name}</p> </div> </div> <!--end 游戏基本信息--> <!--选择小号 begin--> <div class="select-small-number"> <p class="select-small-number-desc">选择区服</p> <ul class="select-small-number-list"> <!--给li添加active类名表示选中的状态--> <volist name="serverdata" id="vo"> <li class="select-small-number-item jsssni" data-id="{$vo.server_id}" onclick="select_server(this,{$vo.server_id},'{$vo.server_name}');"> <span class="way-type">{$vo.server_name}</span> </li> </volist> </ul> </div> <!--end 选择小号--> </empty> </div></main><footer class="footer" id="comfirm_server"> <!-- 在class左后面添加xg-btn-disabled是未有选中的样式 --> <input type="hidden" name="game_id" value="{$game.game_id}"> <div class="input_data_box2"> <input type="hidden" name="server_id" value="" > <input type="hidden" name="server_name" value="" > </div> <button type="button" class="xg-btn xg-btn-submit xg-btn-primary xg-btn-disabled" id="readandsell">请阅读注意事项,并确认出售</button></footer><div class="popmsg2 pop-dialog"></div><notempty name="game"><script> function select_server(e,id,account) { $(e).addClass('active').siblings().removeClass('active'); $('#comfirm_server input[name="server_id"]').val(id); $('#comfirm_server input[name="server_name"]').val(account); $('#readandsell').removeClass('xg-btn-disabled'); } $(function() { if($('#comfirm_sell .input_data_box').length>0) { if($('#comfirm_server input[name="game_id"]').val() == $('#comfirm_sell input[name="game_id"]').val()) { var sid = $('#comfirm_sell input[name="server_id"]').val(); $('.jsssni').each(function(i,n) { var that = $(n); if(that.attr('data-id') == sid) { select_server(n,sid,that.find('.way-type').text()); } }); } } var popmsg2 = $('.popmsg2').pop(); $('#jsselectserver').click(function() { var p = $('.popwin').fadeOut(200); setTimeout(function(){p.find('#select_server_box').remove();},210); return false; }); $('#readandsell').click(function() { var that = $(this),p = that.closest('#comfirm_server'); if(!$.trim(p.find('input[name="server_id"]').val())) {popmsg2.msg('请选择区服');return false;} if(!$.trim(p.find('input[name="server_name"]').val())) {popmsg2.msg('请选择区服');return false;} var html = p.find('.input_data_box2').clone(); $('#comfirm_sell .input_data_box2').remove(); $('#comfirm_sell').append(html); $('#jssell_server').find('.gray_txt').addClass('xh_selected').text(p.find('input[name="server_name"]').val()); var pop = $('.popwin').fadeOut(200); setTimeout(function(){pop.find('#select_server_box').remove();},210); return false; }); });</script></notempty></div></div>