Sha256: c5384585b8ea5a3c88c7adf3d60c79e6df38681ff3f10861d2b675b81b461de6

Contents?: true

Size: 457 Bytes

Versions: 2

Compression:

Stored size: 457 Bytes

Contents

module RailsVoter
  module ApplicationHelper
    def embed_ballot_form(id)
      content_tag(:div, nil) do
        content_tag(
          :iframe,
          nil,
          src: rails_voter.vote_election_path(id),
        )
      end
    end

    def embed_voting_result(id)
      content_tag(:div, nil) do
        content_tag(
          :iframe,
          nil,
          src: rails_voter.show_result_election_path(id),
        )
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rails_voter-0.2.1 app/helpers/rails_voter/application_helper.rb
rails_voter-0.2.0 app/helpers/rails_voter/application_helper.rb