small fix for empty title

This commit is contained in:
Harry Bomrah 2017-12-26 14:49:22 +08:00
parent 78eb25a3ca
commit ce280fe922
1 changed files with 1 additions and 1 deletions

View File

@ -1,7 +1,7 @@
class PersonalHonorsController < ApplicationController class PersonalHonorsController < ApplicationController
def index def index
params = OrbitHelper.params params = OrbitHelper.params
honors = Honor.where(:award_name.ne => nil, :award_name.ne => "").sort_for_frontend.page(OrbitHelper.params[:page_no]).per(OrbitHelper.page_data_count) honors = Honor.where(:award_name.ne => nil).or(:award_name.ne => "").sort_for_frontend.page(OrbitHelper.params[:page_no]).per(OrbitHelper.page_data_count)
fields_to_show = Page.where(:page_id => params[:page_id]).first.custom_array_field rescue [] fields_to_show = Page.where(:page_id => params[:page_id]).first.custom_array_field rescue []
if fields_to_show.blank? if fields_to_show.blank?