Commit 4829d24e authored by Mac's avatar Mac

样式

parent c130abc2
...@@ -208,7 +208,26 @@ ...@@ -208,7 +208,26 @@
//年会首页菜单 //年会首页菜单
proxy.on("getMenus", function (data){ proxy.on("getMenus", function (data){
console.log(data) console.log(data)
MenusList = data MenusList = data;
for(var i=0;i<data.length;i++){
if(data[i].Id==1 ){
if(data[i].Status==1){
$('#activity').css('display','flex')
$('#activity2').css('display','none')
$('#activity3').css('display','none')
}
}else if(data[i].Id==2 ){
if(data[i].Status==1){
$('#activity').css('display','none')
$('#activity2').css('display','flex')
$('#activity3').css('display','none')
}
}else if(data[i].Id==4 && data[i].Status==1){
$('#activity2').css('display','none')
$('#activity').css('display','none')
$('#activity3').css('display','flex')
}
}
$(".menu_view").remove() $(".menu_view").remove()
var html=""; var html="";
$.each(data, function(i,v) { $.each(data, function(i,v) {
......
...@@ -421,16 +421,19 @@ ...@@ -421,16 +421,19 @@
$(".rank_i").empty() $(".rank_i").empty()
var html = '' var html = ''
$.each(data, function(i,v) {//这里的函数参数是键值对的形式,k代表键名,v代表值 $.each(data, function(i,v) {//这里的函数参数是键值对的形式,k代表键名,v代表值
html+='<div class="rank_item">\n' + if(i<10){
' <div class="rank_itemL">\n' + html+='<div class="rank_item">\n' +
' <div class="rank_num">'+(i+1)+'</div>\n' + ' <div class="rank_itemL">\n' +
' <p>'+data[i].n+'</p>\n' + ' <div class="rank_num">'+(i+1)+'</div>\n' +
' </div>\n' + ' <p>'+data[i].n+'</p>\n' +
' <div class="rank_itemR">\n' + ' </div>\n' +
' <div class="shuxi"></div>\n' + ' <div class="rank_itemR">\n' +
' <p>'+data[i].s+'</p>\n' + ' <div class="shuxi"></div>\n' +
' </div>\n' + ' <p>'+data[i].s+'</p>\n' +
' </div>' ' </div>\n' +
' </div>'
}
}); });
$(".rank_i").append(html); $(".rank_i").append(html);
}; };
......
...@@ -69,7 +69,7 @@ ...@@ -69,7 +69,7 @@
<span class="rank_myTop" id="myTop"></span>&nbsp;&nbsp; <span class="rank_myTop" id="myTop"></span>&nbsp;&nbsp;
</p> </p>
</div> </div>
<div class="rank" id="rankBox" style="height: 29rem;"></div> <div class="rank" id="rankBox" style="height: 36rem;"></div>
</div> </div>
</div> </div>
</div> </div>
...@@ -145,8 +145,11 @@ ...@@ -145,8 +145,11 @@
var html='' var html=''
if(d && d.length>0){ if(d && d.length>0){
for (var i=0;i<d.length;i++) { for (var i=0;i<d.length;i++) {
html+='<div class="rank-row"><span class="rank-num num'+(i+1)+'">'+(i>2?i+"":"")+'</span><img src="'+d[i].p+'"/>' if(i<10){
html+='<span class="rank-name">'+d[i].n+'</span><span class="rank-score">'+d[i].s+'</span></div>' html+='<div class="rank-row"><span class="rank-num num'+(i+1)+'">'+(i>2?i+1:"")+'</span><img src="'+d[i].p+'"/>'
html+='<span class="rank-name">'+d[i].n+'</span><span class="rank-score">'+d[i].s+'</span></div>'
}
} }
} }
$("#rankBox").html(html); $("#rankBox").html(html);
......
...@@ -314,12 +314,12 @@ body { ...@@ -314,12 +314,12 @@ body {
background: url(../img/money/rank_list_dec.png) no-repeat center; background: url(../img/money/rank_list_dec.png) no-repeat center;
background-size: contain; background-size: contain;
position: absolute; position: absolute;
top: -89px; top: -100px;
left: 0; left: 0;
} }
.rank_list_ranking { .rank_list_ranking {
padding-top: 70px; padding-top: 50px;
width: 100%; width: 100%;
margin: 10px auto 0; margin: 10px auto 0;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment