Sha256: d5af44c8c5d2de7821ab6f924df9b58ce6f367278ccdea875b33e3f71068fc05

Contents?: true

Size: 510 Bytes

Versions: 7

Compression:

Stored size: 510 Bytes

Contents

# frozen_string_literal: true

module Decidim
  class FollowersCell < Decidim::ViewModel
    include Decidim::CellsPaginateHelper
    include Decidim::ApplicationHelper
    include Decidim::Core::Engine.routes.url_helpers
    include Decidim::CardHelper

    def show
      render :show
    end

    def followers
      @followers ||= model.followers.not_blocked.page(params[:page]).per(20)
    end

    def validation_messages
      [t("decidim.followers.no_followers")] if followers.blank?
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
decidim-core-0.28.4 app/cells/decidim/followers_cell.rb
decidim-core-0.28.3 app/cells/decidim/followers_cell.rb
decidim-core-0.28.2 app/cells/decidim/followers_cell.rb
decidim-core-0.28.1 app/cells/decidim/followers_cell.rb
decidim-core-0.28.0 app/cells/decidim/followers_cell.rb
decidim-core-0.28.0.rc5 app/cells/decidim/followers_cell.rb
decidim-core-0.28.0.rc4 app/cells/decidim/followers_cell.rb