From 87a65a93fa630a470675a6cf509169222de5a4ab Mon Sep 17 00:00:00 2001 From: chiu Date: Wed, 14 Aug 2019 14:14:53 +0800 Subject: [PATCH] Update personal_conferences_controller.rb --- app/controllers/personal_conferences_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/personal_conferences_controller.rb b/app/controllers/personal_conferences_controller.rb index e6569ad..769f429 100644 --- a/app/controllers/personal_conferences_controller.rb +++ b/app/controllers/personal_conferences_controller.rb @@ -33,7 +33,7 @@ class PersonalConferencesController < ApplicationController when "paper_levels" writing_conferences_show = writing_conferences_temp.select {|value| value.conference_paper_levels.collect{|x| x.title}.join(', ').to_s.include? params[:keywords]} when "paper_types" - writing_conferences_show = writing_conferences_temp.select {|value| value.conference_paper_levels.collect{|x| x.title}.join(', ').to_s.include? params[:keywords]} + writing_conferences_show = writing_conferences_temp.select {|value| value.conference_paper_types.collect{|x| x.title}.join(', ').to_s.include? params[:keywords]} when "period" writing_conferences_show = writing_conferences_temp.select {|value| value.duration.include? params[:keywords]} when "publication_date" @@ -68,7 +68,7 @@ class PersonalConferencesController < ApplicationController when "paper_levels" t << {"value" => ( !writing_conference.conference_paper_levels.blank? ? "(#{writing_conference.conference_paper_levels.collect{|x| x.title}.join(', ')})" : nil)} when "paper_types" - t << {"value" => ( !writing_conference.conference_paper_levels.blank? ? "(#{writing_conference.conference_paper_levels.collect{|x| x.title}.join(', ')})" : nil)} + t << {"value" => ( !writing_conference.conference_paper_types.blank? ? "(#{writing_conference.conference_paper_types.collect{|x| x.title}.join(', ')})" : nil)} when "publication_date" t << {"value" => (writing_conference.send(fs).strftime("%Y/%m") rescue "")} when "author_type"