diff --git a/config/mongoid.yml b/config/mongoid.yml index 0f5d06c4..0b1bf1bc 100644 --- a/config/mongoid.yml +++ b/config/mongoid.yml @@ -9,7 +9,6 @@ defaults: &defaults development: <<: *defaults database: prototype_r4_development - test: <<: *defaults database: prototype_r4_test diff --git a/vendor/built_in_modules/gallery/app/assets/javascripts/gallery/.gitkeep b/vendor/built_in_modules/gallery/app/assets/javascripts/gallery/.gitkeep new file mode 100644 index 00000000..e69de29b diff --git a/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI.js.erb b/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI.js.erb index 7b801874..288de296 100644 --- a/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI.js.erb +++ b/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI.js.erb @@ -180,12 +180,43 @@ var galleryAPI = function(){ var $tag_panel = $('#tag_panel'), tag_panel_position = 0; - var headarea = '" href="orbit_gallery"><%= I18n.t("gallery.back_to_albums") %> '; - headarea+='" href="images" onclick="return false;"><%= I18n.t("gallery.add_images") %> '; - headarea+='" href="delete" onclick="return false;"><%= I18n.t("gallery.del_album") %> '; - headarea+='" href="orbit_gallery?edit='+id+'" ><%= I18n.t("gallery.edit") %>'; - headarea+='" href="" ><%= I18n.t("gallery.album_tag") %>'; - 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 = $('
Close Panel
'); var frame = $(''); uploadpanel.find("a.bt-cls").click(function(){ diff --git a/vendor/built_in_modules/gallery/app/assets/stylesheets/gallery.css b/vendor/built_in_modules/gallery/app/assets/stylesheets/gallery.css index 3a54dc3f..88916e00 100755 --- a/vendor/built_in_modules/gallery/app/assets/stylesheets/gallery.css +++ b/vendor/built_in_modules/gallery/app/assets/stylesheets/gallery.css @@ -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; }