Merge branch 'design_team' of github.com:Rulingcom/orbit into design_team
This commit is contained in:
commit
3beb035101
18 files changed
+803
-182
No files matched your search
+118
-1
@@ -1 +1,118 @@
|
||||
(function(a){function b(b,c){function w(a){if(!(g.ratio>=1)){o.now=Math.min(i[c.axis]-j[c.axis],Math.max(0,o.start+((k?a.pageX:a.pageY)-p.start)));n=o.now*h.ratio;g.obj.css(l,-n);j.obj.css(l,o.now)}return false}function v(b){a(document).unbind("mousemove",w);a(document).unbind("mouseup",v);j.obj.unbind("mouseup",v);document.ontouchmove=j.obj[0].ontouchend=document.ontouchend=null;return false}function u(b){if(!(g.ratio>=1)){var b=b||window.event;var d=b.wheelDelta?b.wheelDelta/120:-b.detail/3;n-=d*c.wheel;n=Math.min(g[c.axis]-f[c.axis],Math.max(0,n));j.obj.css(l,n/h.ratio);g.obj.css(l,-n);b=a.event.fix(b);b.preventDefault()}}function t(b){p.start=k?b.pageX:b.pageY;var c=parseInt(j.obj.css(l));o.start=c=="auto"?0:c;a(document).bind("mousemove",w);document.ontouchmove=function(b){a(document).unbind("mousemove");w(b.touches[0])};a(document).bind("mouseup",v);j.obj.bind("mouseup",v);j.obj[0].ontouchend=document.ontouchend=function(b){a(document).unbind("mouseup");j.obj.unbind("mouseup");v(b.touches[0])};return false}function s(){j.obj.bind("mousedown",t);j.obj[0].ontouchstart=function(a){a.preventDefault();j.obj.unbind("mousedown");t(a.touches[0]);return false};i.obj.bind("mouseup",w);if(c.scroll&&this.addEventListener){e[0].addEventListener("DOMMouseScroll",u,false);e[0].addEventListener("mousewheel",u,false)}else if(c.scroll){e[0].onmousewheel=u}}function r(){j.obj.css(l,n/h.ratio);g.obj.css(l,-n);p["start"]=j.obj.offset()[l];var a=m.toLowerCase();h.obj.css(a,i[c.axis]);i.obj.css(a,i[c.axis]);j.obj.css(a,j[c.axis])}function q(){d.update();s();return d}var d=this;var e=b;var f={obj:a(".viewport",b)};var g={obj:a(".overview",b)};var h={obj:a(".scrollbar",b)};var i={obj:a(".track",h.obj)};var j={obj:a(".thumb",h.obj)};var k=c.axis=="x",l=k?"left":"top",m=k?"Width":"Height";var n,o={start:0,now:0},p={};this.update=function(a){f[c.axis]=f.obj[0]["offset"+m];g[c.axis]=g.obj[0]["scroll"+m];g.ratio=f[c.axis]/g[c.axis];h.obj.toggleClass("disable",g.ratio>=1);i[c.axis]=c.size=="auto"?f[c.axis]:c.size;j[c.axis]=Math.min(i[c.axis],Math.max(0,c.sizethumb=="auto"?i[c.axis]*g.ratio:c.sizethumb));h.ratio=c.sizethumb=="auto"?g[c.axis]/i[c.axis]:(g[c.axis]-f[c.axis])/(i[c.axis]-j[c.axis]);n=a=="relative"&&g.ratio<=1?Math.min(g[c.axis]-f[c.axis],Math.max(0,n)):0;n=a=="bottom"&&g.ratio<=1?g[c.axis]-f[c.axis]:isNaN(parseInt(a))?n:parseInt(a);r()};return q()}a.tiny=a.tiny||{};a.tiny.scrollbar={options:{axis:"y",wheel:40,scroll:true,size:"auto",sizethumb:"auto"}};a.fn.tinyscrollbar=function(c){var c=a.extend({},a.tiny.scrollbar.options,c);this.each(function(){a(this).data("tsb",new b(a(this),c))});return this};a.fn.tinyscrollbar_update=function(b){return a(this).data("tsb").update(b)};})(jQuery)
|
||||
(function(a){
|
||||
function b(b,c){
|
||||
function w(a){
|
||||
if(!(g.ratio>=1)){
|
||||
o.now=Math.min(i[c.axis]-j[c.axis],Math.max(0,o.start+((k?a.pageX:a.pageY)-p.start)));
|
||||
n=o.now*h.ratio;g.obj.css(l,-n);
|
||||
j.obj.css(l,o.now)
|
||||
}
|
||||
return false
|
||||
}
|
||||
function v(b){
|
||||
a(document).unbind("mousemove",w);
|
||||
a(document).unbind("mouseup",v);
|
||||
j.obj.unbind("mouseup",v);
|
||||
document.ontouchmove=j.obj[0].ontouchend=document.ontouchend=null;
|
||||
return false
|
||||
}
|
||||
function u(b){
|
||||
if(!(g.ratio>=1)){
|
||||
var b=b||window.event;
|
||||
var d=b.wheelDelta?b.wheelDelta/120:-b.detail/3;
|
||||
n-=d*c.wheel;
|
||||
n=Math.min(g[c.axis]-f[c.axis],Math.max(0,n));
|
||||
j.obj.css(l,n/h.ratio);
|
||||
g.obj.css(l,-n);
|
||||
b=a.event.fix(b);
|
||||
b.preventDefault()
|
||||
}
|
||||
}
|
||||
function t(b){
|
||||
p.start=k?b.pageX:b.pageY;
|
||||
var c=parseInt(j.obj.css(l));
|
||||
o.start=c=="auto"?0:c;
|
||||
a(document).bind("mousemove",w);
|
||||
document.ontouchmove=function(b){
|
||||
a(document).unbind("mousemove");
|
||||
w(b.touches[0])
|
||||
};
|
||||
a(document).bind("mouseup",v);
|
||||
j.obj.bind("mouseup",v);
|
||||
j.obj[0].ontouchend=document.ontouchend=function(b){
|
||||
a(document).unbind("mouseup");
|
||||
j.obj.unbind("mouseup");
|
||||
v(b.touches[0])
|
||||
};
|
||||
return false
|
||||
}
|
||||
function s(){
|
||||
j.obj.bind("mousedown",t);
|
||||
j.obj[0].ontouchstart=function(a){
|
||||
a.preventDefault();
|
||||
j.obj.unbind("mousedown");
|
||||
t(a.touches[0]);
|
||||
return false
|
||||
};
|
||||
i.obj.bind("mouseup",w);
|
||||
if(c.scroll&&this.addEventListener){
|
||||
e[0].addEventListener("DOMMouseScroll",u,false);
|
||||
e[0].addEventListener("mousewheel",u,false)
|
||||
}else if(c.scroll){
|
||||
e[0].onmousewheel=u
|
||||
}
|
||||
}
|
||||
function r(){
|
||||
j.obj.css(l,n/h.ratio);
|
||||
g.obj.css(l,-n);
|
||||
p["start"]=j.obj.offset()[l];
|
||||
var a=m.toLowerCase();
|
||||
h.obj.css(a,i[c.axis]);
|
||||
i.obj.css(a,i[c.axis]);
|
||||
j.obj.css(a,j[c.axis])
|
||||
}
|
||||
function q(){
|
||||
d.update();
|
||||
s();
|
||||
return d
|
||||
}
|
||||
var d=this;
|
||||
var e=b;
|
||||
var f={obj:a(".viewport",b)};
|
||||
var g={obj:a(".overview",b)};
|
||||
var h={obj:a(".scrollbar",b)};
|
||||
var i={obj:a(".track",h.obj)};
|
||||
var j={obj:a(".thumb",h.obj)};
|
||||
var k=c.axis=="x",
|
||||
l=k?"left":"top",
|
||||
m=k?"Width":"Height";
|
||||
var n,
|
||||
o={start:0,now:0},
|
||||
p={};
|
||||
this.update=function(a){
|
||||
f[c.axis]=f.obj[0]["offset"+m];
|
||||
g[c.axis]=g.obj[0]["scroll"+m];
|
||||
g.ratio=f[c.axis]/g[c.axis];
|
||||
h.obj.toggleClass("disable",g.ratio>=1);
|
||||
i[c.axis]=c.size=="auto"?f[c.axis]:c.size;
|
||||
j[c.axis]=Math.min(i[c.axis],Math.max(0,c.sizethumb=="auto"?i[c.axis]*g.ratio:c.sizethumb));
|
||||
h.ratio=c.sizethumb=="auto"?g[c.axis]/i[c.axis]:(g[c.axis]-f[c.axis])/(i[c.axis]-j[c.axis]);
|
||||
n=a=="relative"&&g.ratio<=1?Math.min(g[c.axis]-f[c.axis],Math.max(0,n)):0;
|
||||
n=a=="bottom"&&g.ratio<=1?g[c.axis]-f[c.axis]:isNaN(parseInt(a))?n:parseInt(a);
|
||||
r()
|
||||
};
|
||||
return q()
|
||||
}
|
||||
a.tiny=a.tiny||{};
|
||||
a.tiny.scrollbar={options:{axis:"y",wheel:40,scroll:true,size:"auto",sizethumb:"auto"}};
|
||||
a.fn.tinyscrollbar=function(c){
|
||||
var c=a.extend({},a.tiny.scrollbar.options,c);
|
||||
this.each(function(){
|
||||
a(this).data("tsb",new b(a(this),c))
|
||||
});
|
||||
return this
|
||||
};
|
||||
a.fn.tinyscrollbar_update=function(b){
|
||||
return a(this).data("tsb").update(b)
|
||||
};
|
||||
})
|
||||
(jQuery)
|
||||
@@ -1,12 +1,23 @@
|
||||
/*sidebar*/
|
||||
|
||||
#back_sidebar {
|
||||
left: 0;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
width: 160px;
|
||||
.nav-list {
|
||||
padding: 0px 0px 100px 5px;
|
||||
}
|
||||
|
||||
.nav-list li {
|
||||
position: relative;
|
||||
}
|
||||
.nav-list ul {
|
||||
margin-left: 10px;
|
||||
}
|
||||
.nav-list ul li {
|
||||
padding: 5px 0;
|
||||
}
|
||||
.nav-list ul li a {
|
||||
font-size: 13px;
|
||||
padding: 3px 0px;
|
||||
display: block;
|
||||
}
|
||||
/*
|
||||
#back_sidebar h1 {
|
||||
background: url(<%= asset_path "h1_bg.png" %>) repeat-x scroll left top transparent;
|
||||
border-bottom: 1px solid #1B1B1B;
|
||||
@@ -106,36 +117,35 @@
|
||||
}
|
||||
#main-sidebar ul ul li a{
|
||||
padding: 10px 0 10px 20px;
|
||||
}*/
|
||||
.with_action:hover .hide {
|
||||
display: block;
|
||||
}
|
||||
#main-sidebar li:hover .quick-edit{
|
||||
display:block;
|
||||
}
|
||||
#main-sidebar .quick-edit{
|
||||
#main-sidebar .quick-edit {
|
||||
background: none repeat scroll 0 0 #FFFFFF;
|
||||
border: 1px solid #DDDDDD;
|
||||
border-radius: 5px 5px 5px 5px;
|
||||
display: none;
|
||||
margin:-3px 0 0 3px;
|
||||
padding: 3px;
|
||||
margin: 0 0 0 3px;
|
||||
padding: 0;
|
||||
z-index:1;
|
||||
position: absolute;
|
||||
left: -3px;
|
||||
width: 70px;
|
||||
}
|
||||
#main-sidebar .quick-edit:after{
|
||||
content: ".";
|
||||
display: block;
|
||||
height: 0;
|
||||
clear: both;
|
||||
visibility: hidden;
|
||||
}
|
||||
#main-sidebar .quick-edit a{
|
||||
#main-sidebar .quick-edit a {
|
||||
display: block;
|
||||
line-height: 22px;
|
||||
border-bottom: medium none;
|
||||
border-radius: 5px 5px 5px 5px;
|
||||
font-size:12px;
|
||||
float: left;
|
||||
margin: 0 3px 0 0;
|
||||
padding: 3px;
|
||||
margin: 0;
|
||||
padding: 3px 5px;
|
||||
}
|
||||
|
||||
#main-sidebar .quick-edit a:hover{
|
||||
background: none repeat scroll 0 0 #EEEEEE;
|
||||
border-bottom:none;
|
||||
#main-sidebar .quick-edit a:first-child {
|
||||
border-radius: 5px 5px 0px 0px;
|
||||
}
|
||||
#main-sidebar .quick-edit a:last-child {
|
||||
border-radius: 0px 0px 5px 5px;
|
||||
}
|
||||
#main-sidebar .quick-edit a:hover {
|
||||
background-color: #DDDDDD;
|
||||
}
|
||||
@@ -632,12 +632,10 @@
|
||||
margin-right: 20px;
|
||||
}
|
||||
.adbanner-action {
|
||||
position: absolute;
|
||||
top: -32px;
|
||||
right: 0;
|
||||
}
|
||||
#bulletin_link_qe form {
|
||||
margin: 0;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
#bulletin_link_qe form {
|
||||
margin: 0;
|
||||
}
|
||||
[class^="icons-"] {
|
||||
display: inline-block;
|
||||
|
||||
@@ -9,18 +9,20 @@ module Admin::ItemHelper
|
||||
when 'Link'
|
||||
dest = admin_link_path(node)
|
||||
end
|
||||
ret << "<ul class='list'>"
|
||||
ret << "<ul>" unless node.parent.nil?
|
||||
ret << "<li>"
|
||||
ret << "<div class='with_action'>"
|
||||
ret << (link_to node.i18n_variable[I18n.locale], dest)
|
||||
ret << "<div class='quick-edit'>"
|
||||
ret << "<div class='quick-edit hide'>"
|
||||
ret << (link_to t('admin.edit'), eval("edit_admin_#{node._type.downcase}_path(node)")) if node._type.eql?('Page')
|
||||
ret << (link_to t('admin.new_page'), new_admin_page_path(:parent_id => node.id), :class => 'new_page') if node._type.eql?('Page')
|
||||
ret << (link_to t('admin.new_link'), new_admin_link_path(:parent_id => node.id), :class => 'new_link') if node._type.eql?('Page')
|
||||
ret << (link_to t(:delete), eval("delete_admin_#{node._type.downcase}_path(node, :authenticity_token => form_authenticity_token)"), :confirm => t('sure?'), :class => 'delete')
|
||||
ret << "</div>"
|
||||
ret << "</li>"
|
||||
ret << "</div>"
|
||||
ret << render_children(node)
|
||||
ret << "</ul>"
|
||||
ret << "</li>"
|
||||
ret << "</ul>" unless node.parent.nil?
|
||||
end
|
||||
ret.html_safe
|
||||
end
|
||||
|
||||
@@ -142,7 +142,6 @@ module ApplicationHelper
|
||||
javascripts = ''
|
||||
unless edit
|
||||
javascripts << "<script type='text/javascript' src='/static/jquery.js'></script>\n"
|
||||
javascripts << "<script type='text/javascript' src='/static/jquery.cycle.all.latest.js'></script>\n"
|
||||
javascripts << "<script type='text/javascript' src='/assets/bootstrap.js'></script>\n"
|
||||
javascripts << "<script type='text/javascript' src='/assets/jquery.tinyscrollbar.min.js'></script>\n"
|
||||
javascripts << "<script type='text/javascript' src='/assets/jquery.isotope.min.js'></script>\n"
|
||||
@@ -150,6 +149,7 @@ module ApplicationHelper
|
||||
javascripts << "<script type='text/javascript' src='/assets/orbit-bar-search.js'></script>\n"
|
||||
javascripts << "<script type='text/javascript' src='/assets/orbit_bar.js'></script>\n"
|
||||
end
|
||||
javascripts << "<script type='text/javascript' src='/static/jquery.cycle.all.latest.js'></script>\n"
|
||||
javascripts << "<script type='text/javascript' src='/static/kernel.js'></script>\n"
|
||||
javascripts << "<script type='text/javascript' src='/assets/event.js'></script>\n"
|
||||
page.design.javascripts.each do |js|
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
</div>
|
||||
<h3>圖片列表</h3>
|
||||
<div class="adbanner-list">
|
||||
<div class="adbanner-action pagination-right">
|
||||
<div class="adbanner-action">
|
||||
<%= link_to t("admin.ad.new_image"),new_admin_ad_banner_ad_image_path(ad_banner_tab) ,:class => "btn btn-primary"%>
|
||||
<%= link_to t("modal.preview"), admin_realtime_preview_ad_banner_path(ad_banner_tab.title) , :class=>'preview_trigger btn btn-success'%>
|
||||
</div>
|
||||
|
||||
@@ -1,3 +1 @@
|
||||
<div id="viewport">
|
||||
<%= render_node_and_children(Item.first(:conditions => {:parent_id => nil})) %>
|
||||
</div>
|
||||
<%= render_node_and_children(Item.first(:conditions => {:parent_id => nil})) %>
|
||||
@@ -16,10 +16,10 @@
|
||||
<span class="help-inline">Please correct the error</span>
|
||||
</div>
|
||||
<div class="control-group clear">
|
||||
<%= link_to t(:forgot_password), new_user_password_path, :class => 'pull-right forgot' %>
|
||||
<%= f.label :password %>
|
||||
<%= f.password_field :password, :placeholder => t(:dots), :style => "width: 330px;" %>
|
||||
<span class="help-inline">Please correct the error</span>
|
||||
<%= link_to t(:forgot_password), new_user_password_path, :class => 'pull-right forgot hide' %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
<a class="dropdown-toggle orbit-bar-member" href="#"><%= t(:login) %></a>
|
||||
<div class="dropdown-menu">
|
||||
<ul class="log">
|
||||
<li class="title"></li>
|
||||
<li class="title hide"></li>
|
||||
|
||||
<%= form_for :user, :url => user_session_path do |f| %>
|
||||
<li>
|
||||
@@ -84,7 +84,7 @@
|
||||
<%= f.password_field :password, :class => 'span2', :placeholder => t(:password), :size => 16 %>
|
||||
</div>
|
||||
</li>
|
||||
<li class="clear">
|
||||
<li class="clear hide">
|
||||
<%= link_to t(:forgot_password), new_user_password_path, :class => 'forgot' %>
|
||||
</li>
|
||||
<li>
|
||||
@@ -94,10 +94,10 @@
|
||||
<span style="display: inline-block;height: 10px;"><%= t(:remember_me) %></span>
|
||||
</label>
|
||||
</li>
|
||||
<li class="divider"><span><%= t(:or_lower) %></span></li>
|
||||
<li class="divider hide"><span><%= t(:or_lower) %></span></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<%= link_to t(:register), new_user_registration_path, :class => 'btn btn-danger register' %>
|
||||
<%#= link_to t(:register), new_user_registration_path, :class => 'btn btn-danger register' %>
|
||||
</div>
|
||||
</li>
|
||||
<% end %>
|
||||
|
||||
Reference in new issue
Block a user