diff --git a/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI_frontend.js.erb b/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI_frontend.js.erb index cd5f7238..a1757aa5 100644 --- a/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI_frontend.js.erb +++ b/vendor/built_in_modules/gallery/app/assets/javascripts/galleryAPI_frontend.js.erb @@ -45,7 +45,7 @@ var galleryAPI = function(){ }else{ var cids = "all"; } - $.getJSON("panel/gallery/front_end/get_albums",{"cid":cids,"tid":tids,"inner":true},function(categories){ + $.getJSON("/panel/gallery/front_end/get_albums",{"cid":cids,"tid":tids,"inner":true},function(categories){ $.each(categories,function(x,category){ $.each(category,function(i,album){ album.description = (album.description?album.description:"<%= I18n.t('gallery.no_description') %>") diff --git a/vendor/built_in_modules/gallery/config/routes.rb b/vendor/built_in_modules/gallery/config/routes.rb index 8795594b..17e259c2 100644 --- a/vendor/built_in_modules/gallery/config/routes.rb +++ b/vendor/built_in_modules/gallery/config/routes.rb @@ -21,35 +21,34 @@ Rails.application.routes.draw do resources :album_images resources :gallery_categories resources :tags - end namespace :front_end do - match "get_albums" => "albums#get_albums" - # match "orbit_galleries" => "orbit_galleries#index" - # match "gallery_category_save" => "orbit_galleries#new_category" - # match "categorylist" => "orbit_galleries#categorylist" - # match "gallery_category_delete" => "orbit_galleries#gallery_category_delete" - # match "add_album" => "orbit_galleries#add_album" - # match "create_album" => "orbit_galleries#create_album" - # match "get_albums" => "orbit_galleries#get_albums" - # match "upload_image" => "orbit_galleries#upload_image" - # match "upload_panel" => "orbit_galleries#upload_panel" - # match "get_images" => "orbit_galleries#get_images" - # match "theater" => "orbit_galleries#theater" - # match "delete_album" => "orbit_galleries#delete_album" - # match "edit_album" => "orbit_galleries#edit_album" - # match "set_cover" => "orbit_galleries#set_cover" - # match "delete_images" => "orbit_galleries#delete_images" - # match "update_album" => "orbit_galleries#update_album" - # match "save_tags" => "orbit_galleries#save_tags" - resources :albums do - member do - get "imgs" - get "theater" - end - end - resources :album_images + match "get_albums" => "albums#get_albums" + match "orbit_galleries" => "orbit_galleries#index" + # match "gallery_category_save" => "orbit_galleries#new_category" + # match "categorylist" => "orbit_galleries#categorylist" + # match "gallery_category_delete" => "orbit_galleries#gallery_category_delete" + # match "add_album" => "orbit_galleries#add_album" + # match "create_album" => "orbit_galleries#create_album" + # match "get_albums" => "orbit_galleries#get_albums" + # match "upload_image" => "orbit_galleries#upload_image" + # match "upload_panel" => "orbit_galleries#upload_panel" + # match "get_images" => "orbit_galleries#get_images" + # match "theater" => "orbit_galleries#theater" + # match "delete_album" => "orbit_galleries#delete_album" + # match "edit_album" => "orbit_galleries#edit_album" + # match "set_cover" => "orbit_galleries#set_cover" + # match "delete_images" => "orbit_galleries#delete_images" + # match "update_album" => "orbit_galleries#update_album" + # match "save_tags" => "orbit_galleries#save_tags" + resources :albums do + member do + get "imgs" + get "theater" + end + end + resources :album_images end - end - end + end + end end