Ray's fix

This commit is contained in:
Christophe Vilayphiou 2012-05-02 16:20:59 +08:00
parent bda21baed2
commit 92a53c1b27
6 changed files with 27 additions and 28 deletions
app
assets
views/layouts
vendor/built_in_modules
announcement/app/views/panel/announcement/back_end/bulletins
news/app/views/panel/news/back_end/news_bulletins

View File

@ -1,6 +1,5 @@
var viewportwidth, var viewportwidth,
viewportheight; viewportheight;
console.log($(window).height())
function resize() { function resize() {
viewportheight=$(window).height(); viewportheight=$(window).height();
viewportwidth=$(window).width(); viewportwidth=$(window).width();
@ -17,7 +16,6 @@ $(document).ready(function(){
$(document).on('click', '.privacy', function() { $(document).on('click', '.privacy', function() {
console.log($(this).val());
switch ($(this).val()) { switch ($(this).val()) {
case 'true': case 'true':
$(this).parents('.controls').children('.select-role').slideUp(300); $(this).parents('.controls').children('.select-role').slideUp(300);
@ -53,15 +51,12 @@ $(document).ready(function(){
$orbitBar = $('#orbit-bar').height(), $orbitBar = $('#orbit-bar').height(),
$mainSidebar = $('#main-sidebar').width()+5, $mainSidebar = $('#main-sidebar').width()+5,
$formActionPadding = parseInt($('.form-fixed').css("padding-left"))+parseInt($('.form-fixed').css("padding-right")); $formActionPadding = parseInt($('.form-fixed').css("padding-left"))+parseInt($('.form-fixed').css("padding-right"));
console.log($orbitBar);
console.log("ready"+$(window).height());
$('#main-sidebar').css("height", viewportheight-$orbitBar); $('#main-sidebar').css("height", viewportheight-$orbitBar);
$('#main-sidebar .viewport').css("height", viewportheight-$orbitBar); $('#main-sidebar .viewport').css("height", viewportheight-$orbitBar);
$('#post-body').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget); $('#post-body').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget);
$('.post-title').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget-16); $('.post-title').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget-16);
$('#main-wrap .subnav').css("width", viewportwidth-$mainWrapMarginLeft); $('#main-wrap .subnav').css("width", viewportwidth-$mainWrapMarginLeft);
$('.form-fixed').css("width", viewportwidth-$mainWrapMarginLeft-$formActionPadding); $('.form-fixed').css("width", viewportwidth-$mainWrapMarginLeft-$formActionPadding);
$('#bulletin_pagination').css("width", viewportwidth-$mainSidebar);
$('#main-sidebar').tinyscrollbar({size:(viewportheight-$orbitBar-4)}); $('#main-sidebar').tinyscrollbar({size:(viewportheight-$orbitBar-4)});
$('.detal-list').tinyscrollbar(); $('.detal-list').tinyscrollbar();
mainTablePosition(); mainTablePosition();
@ -82,14 +77,12 @@ $(window).resize(function(){
$orbitBar = $('#orbit-bar').height(), $orbitBar = $('#orbit-bar').height(),
$mainSidebar = $('#main-sidebar').width()+5, $mainSidebar = $('#main-sidebar').width()+5,
$formActionPadding = parseInt($('.form-fixed').css("padding-left"))+parseInt($('.form-fixed').css("padding-right")); $formActionPadding = parseInt($('.form-fixed').css("padding-left"))+parseInt($('.form-fixed').css("padding-right"));
console.log(viewportheight);
$('#main-sidebar').css("height", viewportheight-$orbitBar); $('#main-sidebar').css("height", viewportheight-$orbitBar);
$('#main-sidebar .viewport').css("height", viewportheight-$orbitBar); $('#main-sidebar .viewport').css("height", viewportheight-$orbitBar);
$('#post-body').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget); $('#post-body').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget);
$('.post-title').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget-16); $('.post-title').css("width", viewportwidth-$mainWrapMarginLeft-$subWiget-16);
$('#main-wrap .subnav').css("width", viewportwidth-$mainWrapMarginLeft); $('#main-wrap .subnav').css("width", viewportwidth-$mainWrapMarginLeft);
$('.form-fixed').css("width", viewportwidth-$mainWrapMarginLeft-$formActionPadding); $('.form-fixed').css("width", viewportwidth-$mainWrapMarginLeft-$formActionPadding);
$('#bulletin_pagination').css("width", viewportwidth-$mainSidebar);
$('#main-sidebar').tinyscrollbar({size:(viewportheight-$orbitBar-4)}); $('#main-sidebar').tinyscrollbar({size:(viewportheight-$orbitBar-4)});
mainTablePosition(); mainTablePosition();
}); });
@ -118,5 +111,4 @@ $(window).scroll(function () {
$(".table-label").css({left:$winLeft*-1} ); $(".table-label").css({left:$winLeft*-1} );
//$(".table-label").css({left:$mainWrapMarginLeft+($winLeft*-1)} ); //$(".table-label").css({left:$mainWrapMarginLeft+($winLeft*-1)} );
//$("#main-wrap > .subnav").css({width:$subnavWidth+($winLeft)} ); //$("#main-wrap > .subnav").css({width:$subnavWidth+($winLeft)} );
//console.log($mainWrapMarginLeft+($winLeft*-1)+5);
}); });

View File

@ -2701,8 +2701,11 @@ button.btn.small, input[type="submit"].btn.small {
.pagination .current{ .pagination .current{
border-left-width: 1px; border-left-width: 1px;
} }
.pagination a {
background-color: #FFFFFF;
}
.pagination a:hover, .pagination .active a { .pagination a:hover, .pagination .active a {
background-color: #f5f5f5; background-color: #e8e8e8;
} }
.pagination .active a { .pagination .active a {
color: #999999; color: #999999;

View File

@ -70,9 +70,8 @@
} }
.main-list .label-td:hover { .main-list .label-td:hover {
height: auto; height: auto;
text-align: center;
padding: 5px 5px 8px; padding: 5px 5px 8px;
left: -6px; left: -40px;
top: -6px; top: -6px;
border: 1px solid rgba(0, 0, 0, 0.2); border: 1px solid rgba(0, 0, 0, 0.2);
box-shadow: 0px 5px 10px rgba(0,0,0,0.2); box-shadow: 0px 5px 10px rgba(0,0,0,0.2);
@ -82,6 +81,7 @@
-webkit-border-radius: 3px; -webkit-border-radius: 3px;
-moz-border-radius: 3px; -moz-border-radius: 3px;
z-index: 5; z-index: 5;
width: 200px;
} }
.qe-edit-div .table-condensed { .qe-edit-div .table-condensed {
background-color: #F2F2F2; background-color: #F2F2F2;
@ -188,10 +188,16 @@ legend {
} }
.form-fixed { .form-fixed {
position: fixed; position: fixed;
margin-bottom: 0; margin: 0;
padding: 10px;
bottom: 0; bottom: 0;
z-index: 10; z-index: 2;
}
.form-fixed .btn {
margin-top: 4px;
} }
.paginationFixed { .paginationFixed {
margin-bottom: 25px; }
.paginationFixed .pagination {
margin-top: 0 !important;
} }

View File

@ -14,7 +14,7 @@
</head> </head>
<body> <body>
<%= render 'layouts/orbit_bar' %> <%= render 'layouts/orbit_bar' %>
<nav id="main-sidebar" class="my_scroll"> <div id="main-sidebar" class="my_scroll">
<div class="scrollbar"> <div class="scrollbar">
<div class="track"> <div class="track">
<div class="thumb"> <div class="thumb">
@ -29,7 +29,7 @@
</ul> </ul>
</div> </div>
</div> </div>
</nav> </div>
<div id="main-wrap"> <div id="main-wrap">
<%= yield %> <%= yield %>
</div> </div>

View File

@ -5,9 +5,12 @@
</table> </table>
<% end %> <% end %>
<div class="form-actions form-fixed pagination-right">
<%= link_to content_tag(:i, nil, :class => 'icon-plus icon-white') + t('admin.add'), new_panel_announcement_back_end_bulletin_path, :class => 'btn btn-primary pull-right' %>
<div id="bulletin_pagination" class="paginationFixed"> <div id="bulletin_pagination" class="paginationFixed">
<%= paginate @bulletins, :params => {:direction => params[:direction], :sort => params[:sort], :filter => @filter, :new_filter => nil, :sort_options => params[:sort_options]} %> <%= paginate @bulletins, :params => {:direction => params[:direction], :sort => params[:sort], :filter => @filter, :new_filter => nil, :sort_options => params[:sort_options]} %>
</div> </div>
</div>
<div id="bulletin_link_qe"> <div id="bulletin_link_qe">
<div id="modal-link" class="modal fade"> <div id="modal-link" class="modal fade">
@ -15,10 +18,6 @@
</div> </div>
</div> </div>
<div class="form-actions form-fixed pagination-right">
<%= link_to content_tag(:i, nil, :class => 'icon-plus icon-white') + t('admin.add'), new_panel_announcement_back_end_bulletin_path, :class => 'btn btn-primary' %>
</div>
<% content_for :page_specific_javascript do %> <% content_for :page_specific_javascript do %>
<%= javascript_include_tag "bulletin_form" %> <%= javascript_include_tag "bulletin_form" %>
<% end %> <% end %>

View File

@ -5,9 +5,12 @@
</table> </table>
<% end %> <% end %>
<div id="news_bulletin_pagination"> <div class="form-actions form-fixed pagination-right">
<%= link_to content_tag(:i, nil, :class => 'icon-plus icon-white') + t('admin.add'), new_panel_news_back_end_news_bulletin_path, :class => 'btn btn-primary' %>
<div id="news_bulletin_pagination" class="paginationFixed">
<%= paginate @news_bulletins, :params => {:direction => params[:direction], :sort => params[:sort], :filter => @filter, :new_filter => nil, :sort_options => params[:sort_options]} %> <%= paginate @news_bulletins, :params => {:direction => params[:direction], :sort => params[:sort], :filter => @filter, :new_filter => nil, :sort_options => params[:sort_options]} %>
</div> </div>
</div>
<div id="news_bulletin_link_qe"> <div id="news_bulletin_link_qe">
<div id="modal-link" class="modal fade"> <div id="modal-link" class="modal fade">
@ -21,10 +24,6 @@
</div> </div>
</div> </div>
<div class="form-actions">
<%= link_to content_tag(:i, nil, :class => 'icon-plus icon-white') + t('admin.add'), new_panel_news_back_end_news_bulletin_path, :class => 'btn btn-primary' %>
</div>
<% content_for :page_specific_javascript do %> <% content_for :page_specific_javascript do %>
<%= javascript_include_tag "news_bulletin_form" %> <%= javascript_include_tag "news_bulletin_form" %>
<% end %> <% end %>