Implement role authorization

This commit is contained in:
Stella Rouzi 2014-08-12 11:51:59 +03:00
parent 6755328c4c
commit e2fb434dc7
122 changed files with 1386 additions and 751 deletions

View file

@ -31,9 +31,9 @@
= link_to "View Conference", conference_path(conference.short_title), :class =>"btn btn-default"
- if conference.registration_open?
- if conference.user_registered?(current_user)
= link_to "Modify Registration", register_conference_path(conference.short_title), :class =>"btn btn-default"
= link_to "Modify Registration", conference_register_path(conference.short_title), :class =>"btn btn-default"
- else
= link_to "Register", register_conference_path(conference.short_title), :class =>"btn btn-success"
= link_to "Register", conference_register_path(conference.short_title), :class =>"btn btn-success"
= link_to "Schedule", conference_schedule_path(conference.short_title), :class =>"btn btn-default" if conference.call_for_papers and conference.call_for_papers.schedule_public
- if !current_user.nil? && current_user.proposal_count(conference) > 0
= link_to "View My Proposals", conference_proposal_index_path(conference.short_title), :class =>"btn btn-default"

View file

@ -2,4 +2,4 @@
.col-md-12.page-header
%h2.text-center Upcoming Conferences
- @current.each do |conference|
= render :partial => "conference_details", :locals => {:conference => conference}
= render :partial => "conference_details", :locals => {:conference => conference}