Update personal_journals_controller.rb

This commit is contained in:
chiu 2019-08-15 09:26:11 +08:00
parent f617ef9e8e
commit 53c228622f
1 changed files with 3 additions and 3 deletions

View File

@ -25,9 +25,9 @@ class PersonalJournalsController < ApplicationController
] ]
end end
if params[:selectbox] !=nil if params[:selectbox] !=nil
journal_papers = JournalPaper.where(:is_hidden=>false) journal_papers_temp = JournalPaper.where(:is_hidden=>false).sort_by{ |tp| [-tp[:year].to_i,-tp[:publication_date].to_i] }
journal_papers_count = journal_papers.count #journal_papers_count = journal_papers.count
journal_papers_temp = journal_papers.take(journal_papers_count).sort_by{ |tp| [-tp[:year].to_i,-tp[:publication_date].to_i] } #journal_papers_temp = journal_papers.take(journal_papers_count).sort_by{ |tp| [-tp[:year].to_i,-tp[:publication_date].to_i] }
case params[:selectbox] case params[:selectbox]
when "paper_title","default" when "paper_title","default"
if page.custom_string_field == "table" if page.custom_string_field == "table"