change journal list json link

This commit is contained in:
Rueshyna 2012-11-19 12:13:05 +08:00 committed by chris
parent d7599f1ccf
commit 703324063e
2 changed files with 2 additions and 21 deletions

View File

@ -969,7 +969,7 @@ var orbitDesktop = function(dom){
bindSecondaryHandlers();
}
$.getJSON("/desktop_publications/getjournals",function(journals){
$.getJSON("/desktop/journal_pages/get_journals_json",function(journals){
journalData = eval(journals);
journalview();
bindHandlers();

View File

@ -3,23 +3,4 @@ class Desktopapp::DesktopAppPublications < Sinatra::Base
get "/desktop/journal_p" do
erb :journal_p
end
get "/desktop/journal_p_list" do
erb :'journal_pages/list'
end
get '/desktop/journal_p_add' do
erb :'journal_pages/add'
end
get '/desktop_publications/getjournals' do
@journals = Journal.all
data = Array.new
@journals.each do |journal|
@papers = journal.papers.all
data << {"title" => journal.title, "papers" => @papers}
end
data.to_json
end
end