From 37f1a77029edf47c08732b784224da29c73016df Mon Sep 17 00:00:00 2001 From: AnkushMalik Date: Tue, 9 Jan 2018 17:21:14 +0530 Subject: [PATCH 1/2] Change paths of buttons on conference show page Update path of track submission btn to track#new and proposal submission to proposal#new Closes #1813 --- app/views/conferences/_call_for_papers.haml | 2 +- app/views/conferences/_call_for_tracks.haml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/conferences/_call_for_papers.haml b/app/views/conferences/_call_for_papers.haml index 3bf0f295..b47d7118 100644 --- a/app/views/conferences/_call_for_papers.haml +++ b/app/views/conferences/_call_for_papers.haml @@ -23,5 +23,5 @@ left! %p.cta-button = link_to "Submit your proposal now", - conference_program_proposals_path(conference_id), + new_conference_program_proposal_path(conference_id), class: 'btn btn-success btn-lg text-center' diff --git a/app/views/conferences/_call_for_tracks.haml b/app/views/conferences/_call_for_tracks.haml index 7eb80fa6..6d78bd05 100644 --- a/app/views/conferences/_call_for_tracks.haml +++ b/app/views/conferences/_call_for_tracks.haml @@ -15,5 +15,5 @@ left! %p.cta-button = link_to("Submit your request for track", - conference_program_tracks_path(conference_id), + new_conference_program_track_path(conference_id), class: 'btn btn-success btn-lg text-center') From 6a4227caa3f166b0e872dcf4cd9e81a9dad72820 Mon Sep 17 00:00:00 2001 From: AnkushMalik Date: Fri, 12 Jan 2018 17:17:39 +0530 Subject: [PATCH 2/2] Add error msg for null file while Adding Commercial for event Null file error message added for uploading empty file in CommercialsController#mass_upload Closes #1959 --- app/controllers/admin/commercials_controller.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/controllers/admin/commercials_controller.rb b/app/controllers/admin/commercials_controller.rb index 3c694246..5dc23030 100644 --- a/app/controllers/admin/commercials_controller.rb +++ b/app/controllers/admin/commercials_controller.rb @@ -57,7 +57,9 @@ module Admin def mass_upload errors = Commercial.read_file(params[:file]) if params[:file] - if errors.all? { |_k, v| v.blank? } + if !errors + flash[:error] = 'Empty file detected while adding commercials to Event' + elsif errors.all? { |_k, v| v.blank? } flash[:notice] = 'Successfully added commercials.' else errors_text = ''