Merge branch 'gallery_orbit' of github.com:Rulingcom/orbit into gallery_orbit
Conflicts: app/views/layouts/_side_bar.html.erb config/mongoid.yml vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI.js.erb vendor/built_in_modules/gallery/app/assets/stylesheets/gallery.css
This commit is contained in:
commit
68aed18956
|
@ -9,7 +9,6 @@ defaults: &defaults
|
|||
development:
|
||||
<<: *defaults
|
||||
database: prototype_r4_development
|
||||
|
||||
test:
|
||||
<<: *defaults
|
||||
database: prototype_r4_test
|
||||
|
|
|
@ -180,12 +180,43 @@ var galleryAPI = function(){
|
|||
var $tag_panel = $('#tag_panel'),
|
||||
tag_panel_position = 0;
|
||||
|
||||
var headarea = '<a class="bt-back btn pull-left" title="<%= I18n.t("gallery.back_to_albums") %>" href="orbit_gallery"><i class="icon-arrow-left icon-black"></i><%= I18n.t("gallery.back_to_albums") %></a> ';
|
||||
headarea+='<a class="bt-add btn btn-primary pull-right" title="<%= I18n.t("gallery.add_images") %>" href="images" onclick="return false;"><i class="icon-plus icon-white"></i><%= I18n.t("gallery.add_images") %></a> ';
|
||||
headarea+='<a class="bt-del btn btn-primary pull-right" title="<%= I18n.t("gallery.del_album") %>" href="delete" onclick="return false;"><i class="icon-trash icon-white"></i><%= I18n.t("gallery.del_album") %></a> ';
|
||||
headarea+='<a class="bt-edit btn btn-primary pull-right" title="<%= I18n.t("gallery.edit") %>" href="orbit_gallery?edit='+id+'" ><i class="icon-pencil icon-white"></i><%= I18n.t("gallery.edit") %></a>';
|
||||
headarea+='<a class="bt-tag btn btn-primary pull-right" title="<%= I18n.t("gallery.album_tag") %>" href="" ><i class="icon-tag icon-white"></i><%= I18n.t("gallery.album_tag") %></a>';
|
||||
headarea = $(headarea);
|
||||
if( $tag_panel.css('right') == '0px' ){
|
||||
tag_panel_position = -200;
|
||||
}
|
||||
$tag_panel.animate({'right':tag_panel_position}, 300);
|
||||
|
||||
g.albumArea
|
||||
.delay(200)
|
||||
.animate({'margin-right':tag_panel_position+200},300);
|
||||
return false;
|
||||
});
|
||||
g.albumArea.find("#tag_search_box").keyup(function(e){
|
||||
sval = $(this).val();
|
||||
if(sval == "<%= I18n.t('gallery.search_tags') %>")
|
||||
sval = "";
|
||||
sval = sval.replace(/(^\s*)|(\s*$)/g,'');
|
||||
if(sval){
|
||||
var re1 = new RegExp("^[\u4E00-\uFA29]*$"); //Chinese character range
|
||||
var re2 = new RegExp("^[\uE7C7-\uE7F3]*$");
|
||||
if ((re1.test(sval) && (re2.test(sval)))){
|
||||
$("ul#gallery_tag_list li span:not(:contains("+sval+"))").parent().slideUp();
|
||||
}else{
|
||||
$("ul#gallery_tag_list li span:not(:containsi("+sval+"))").parent().slideUp();
|
||||
}
|
||||
}else{
|
||||
$("ul#gallery_tag_list li").slideDown();
|
||||
}
|
||||
})
|
||||
g.albumArea.find("#tag_panel button.bt-save").click(function(){
|
||||
g.saveTags(id,g.loadArea);
|
||||
})
|
||||
g.albumArea.find(".rghead .rgfn a.bt-add").click(function(){
|
||||
showUploadPanel();
|
||||
})
|
||||
g.albumArea.find(".rghead .rgfn a.bt-del").click(function(){
|
||||
g.deleteAlbum(id);
|
||||
})
|
||||
})
|
||||
var uploadpanel = $('<div id="upload_panel_holder"><div class="rgfn"><a class="bt-cls btn btn-primary pull-right" title="Close" href="" onclick="return false;"><i class="icon-remove icon-white"></i>Close Panel</a></div></div>');
|
||||
var frame = $('<iframe id="upload_panel" width="100%" scrolling="no" height="200" frameborder="0" src="upload_panel"></iframe>');
|
||||
uploadpanel.find("a.bt-cls").click(function(){
|
||||
|
|
|
@ -29,10 +29,10 @@ body.fullscreen, .fullscreen #container, .fullscreen #container2, .fullscreen #m
|
|||
.rgp textarea { overflow: auto; }
|
||||
.rg a, .rgp a {
|
||||
text-decoration: none;
|
||||
/*color: #555;*/
|
||||
outline: none;
|
||||
}
|
||||
/*.rg a:hover { color: #333; }*/
|
||||
.rg a:hover { }
|
||||
|
||||
.rg img { display: block; border: none; width: 120px; height: 90px; }
|
||||
|
||||
.rgmask { background: #000; width: 100%; position: fixed; top: 0; left: 0; }
|
||||
|
|
Loading…
Reference in New Issue