diff options
Diffstat (limited to 'app')
| -rw-r--r-- | app/controllers/calendars_controller.rb | 1 | ||||
| -rw-r--r-- | app/helpers/table_builder_helper/url.rb | 6 | ||||
| -rw-r--r-- | app/views/calendars/index.html.slim | 10 | 
3 files changed, 16 insertions, 1 deletions
| diff --git a/app/controllers/calendars_controller.rb b/app/controllers/calendars_controller.rb index 6f1522428..61a62c285 100644 --- a/app/controllers/calendars_controller.rb +++ b/app/controllers/calendars_controller.rb @@ -1,4 +1,5 @@  class CalendarsController < ChouetteController +  include WorkgroupSupport    include PolicyChecker    defaults resource_class: Calendar    before_action :ransack_contains_date, only: [:index] diff --git a/app/helpers/table_builder_helper/url.rb b/app/helpers/table_builder_helper/url.rb index 550b1e9d4..63a559162 100644 --- a/app/helpers/table_builder_helper/url.rb +++ b/app/helpers/table_builder_helper/url.rb @@ -3,7 +3,7 @@ module TableBuilderHelper      def self.polymorphic_url_parts(item, referential, workgroup)        polymorph_url = [] -      unless item.is_a?(Referential) || item.is_a?(ComplianceControlSet) +      unless item.is_a?(Calendar) || item.is_a?(Referential) || item.is_a?(ComplianceControlSet)          if referential            polymorph_url << referential            polymorph_url << item.line if item.respond_to? :line @@ -21,10 +21,14 @@ module TableBuilderHelper          end        else  <<<<<<< HEAD +<<<<<<< HEAD          polymorph_url << item.workgroup if item.respond_to? :workgroup  =======          polymorph_url << item.workgroup if item.is_a?(Calendar)  >>>>>>> First draft for including calendars into workgroup for having appropriate scoping +======= +        polymorph_url << item.workgroup if item.respond_to? :workgroup +>>>>>>> update calendar build_links for table builder          polymorph_url << item        end diff --git a/app/views/calendars/index.html.slim b/app/views/calendars/index.html.slim index a2d6b4731..f7192bc01 100644 --- a/app/views/calendars/index.html.slim +++ b/app/views/calendars/index.html.slim @@ -1,4 +1,14 @@ +<<<<<<< HEAD  - breadcrumb :calendars, workgroup +======= +<<<<<<< HEAD +- breadcrumb :calendars +<<<<<<< HEAD +======= +======= +- breadcrumb :calendars, current_workgroup +>>>>>>> update calendar build_links for table builder +>>>>>>> update calendar build_links for table builder  - content_for :page_header_actions do    - if policy(Calendar).create?      = link_to(t('actions.add'), new_workgroup_calendar_path(current_workgroup), class: 'btn btn-default') | 
