Sha256: 18dccc803bde404f021a43a9dbc4e916b458872940afa1c2cf53a78d26aaaf9e

Contents?: true

Size: 483 Bytes

Versions: 22

Compression:

Stored size: 483 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module ContentBlocks
    class StatsCell < Decidim::ViewModel
      def stats
        @stats ||= HomeStatsPresenter.new(organization: current_organization)
      end

      private

      def cache_hash
        hash = []
        hash.push(I18n.locale)
        hash.push(current_organization.cache_key)
        hash.join(Decidim.cache_key_separator)
      end

      def cache_expiry_time
        10.minutes
      end
    end
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
decidim-core-0.27.9 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.29.0 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.28.3 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.8 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.29.0.rc4 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.29.0.rc3 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.29.0.rc2 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.29.0.rc1 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.28.2 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.7 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.28.1 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.6 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.28.0 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.5 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.28.0.rc5 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.28.0.rc4 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.4 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.3 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.2 app/cells/decidim/content_blocks/stats_cell.rb
decidim-core-0.27.1 app/cells/decidim/content_blocks/stats_cell.rb