Update archive_files_controller.rb
This commit is contained in:
parent
86da89fd24
commit
94028d5eea
|
@ -1,7 +1,11 @@
|
||||||
class Admin::ArchiveFilesController < OrbitAdminController
|
class Admin::ArchiveFilesController < OrbitAdminController
|
||||||
def show
|
def show
|
||||||
module_pages = Page.where(:module => 'archive').collect{|p| p.url}[0]
|
module_pages = Page.where(:module => 'archive').collect{|p| p.url}
|
||||||
redirect_to '/' + I18n.locale.to_s + module_pages
|
if module_pages.length<1
|
||||||
|
render :text => t('archive.no_page').to_s
|
||||||
|
else
|
||||||
|
redirect_to '/' + I18n.locale.to_s + module_pages[0] + '?title=' + params['title'].to_s
|
||||||
|
end
|
||||||
end
|
end
|
||||||
def index
|
def index
|
||||||
if ArchiveSortOrder.count == 0
|
if ArchiveSortOrder.count == 0
|
||||||
|
|
Loading…
Reference in New Issue