Sha256: 86a33270877957c5ae5b4f51b1311e8c0fd0e741a016744ae70d26ff09b3b094

Contents?: true

Size: 476 Bytes

Versions: 8

Compression:

Stored size: 476 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Budgets
    module Workflows
      # This Workflow allows users to vote in all budgets.
      class All < Base
        # No budget is highlighted for this workflow.
        def highlighted?(_resource)
          false
        end

        # Users can vote in all budgets with this workflow.
        def vote_allowed?(resource, _consider_progress = true)
          !voted?(resource)
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
decidim-budgets-0.23.6 lib/decidim/budgets/workflows/all.rb
decidim-budgets-0.23.5 lib/decidim/budgets/workflows/all.rb
decidim-budgets-0.23.4 lib/decidim/budgets/workflows/all.rb
decidim-budgets-0.23.3 lib/decidim/budgets/workflows/all.rb
decidim-budgets-0.23.2 lib/decidim/budgets/workflows/all.rb
decidim-budgets-0.23.1 lib/decidim/budgets/workflows/all.rb
decidim-budgets-0.23.1.rc1 lib/decidim/budgets/workflows/all.rb
decidim-budgets-0.23.0 lib/decidim/budgets/workflows/all.rb