fixed journal update method
This commit is contained in:
parent
8ebe9abdfe
commit
55dbfd8c4e
|
@ -54,7 +54,7 @@ class Desktop::JournalPagesController < ApplicationController
|
|||
def update
|
||||
params[:writing_journal][:update_user_id] = current_user.id
|
||||
@writing_journal= WritingJournal.find(params[:id])
|
||||
respond_to do |format|
|
||||
|
||||
if @writing_journal.update_attributes(params[:writing_journal])
|
||||
render json: {success: true, msg: "Paper successfully saved!"}.to_json
|
||||
else
|
||||
|
@ -62,7 +62,6 @@ class Desktop::JournalPagesController < ApplicationController
|
|||
render json: {success: false, msg: error_msg}.to_json
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def check_file_type file
|
||||
if not file.nil?
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<li><a href="<%= desktop_journal_pages_path %>" callback-method="list" load="true" class="hh2 w2 hp thmc1 thmtxt xx" onclick='return false;'>List</a></li>
|
||||
<li><a href="<%= new_desktop_journal_page_path %>" custom-load="addpaper" callback-method="addpaper" custom-load="addpaper" class="admtxt hh2 w2 hp xx" onclick='return false;'>Add/Edit</a></li>
|
||||
<li><a href="" class="admtxt hh2 w2 hp" onclick='return false;'>Journals</a></li>
|
||||
<li><a href="<%= new_desktop_co_author_path %>" class="admtxt hh2 w2 hp" callback-method="coauthor" onclick='return false;'>Co-Authors</a></li>
|
||||
<li><a href="<%= new_desktop_co_author_path %>" class="admtxt hh2 w2 hp" callback-method="coauthor" custom-load="coauthor" onclick='return false;'>Co-Authors</a></li>
|
||||
<li><a href="" class="admtxt hh2 w2 hp" onclick='return false;'>Tags & Keywords</a></li>
|
||||
<li><a href="" class="admtxt hh2 w2 hp" onclick='return false;'>Analysis</a></li>
|
||||
<li><a href="" class="admtxt hh2 w2 hp" onclick='return false;'>Import</a></li>
|
||||
|
|
Loading…
Reference in New Issue