Update journal_papers_controller.rb

This commit is contained in:
chiu 2019-11-01 22:19:37 +08:00
parent 4ec2479d21
commit 208c1b2d9b
1 changed files with 4 additions and 0 deletions

View File

@ -54,8 +54,12 @@ class Admin::JournalPapersController < OrbitMemberController
@journals[key].delete key1
end
end
if @journals[key].length==0
@journals.delete key
end
end
end
end
def index
@writing_journals = JournalPaper.order_by(:year=>'desc').page(params[:page]).per(10)