Sha256: a87962d680bdfa59eb99e0ed1eb58f1a81940ab33ae9ecd5c51d3f5632a1d3b5
Contents?: true
Size: 759 Bytes
Versions: 7
Compression:
Stored size: 759 Bytes
Contents
class StatsController < ApplicationController include Sufia::SingularSubresourceController include Sufia::Breadcrumbs before_action :build_breadcrumbs, only: [:work, :file] def work @stats = Sufia::WorkUsage.new(params[:id]) end def file @stats = Sufia::FileUsage.new(params[:id]) end protected def add_breadcrumb_for_controller add_breadcrumb I18n.t('sufia.dashboard.my.works'), sufia.dashboard_works_path end def add_breadcrumb_for_action case action_name when 'file'.freeze add_breadcrumb I18n.t("sufia.file_set.browse_view"), main_app.curation_concerns_file_set_path(params["id"]) when 'work'.freeze add_breadcrumb @work.to_s, polymorphic_path(@work) end end end
Version data entries
7 entries across 7 versions & 1 rubygems