Class: Decidim::Proposals::AccessToCollaborativeDraftForm

Inherits:
Form
  • Object
show all
Defined in:
app/forms/decidim/proposals/access_to_collaborative_draft_form.rb

Overview

A form object common to accept and reject actions requesters of Collaborative Drafts.

Instance Method Summary collapse

Instance Method Details

#collaborative_draftObject



18
19
20
# File 'app/forms/decidim/proposals/access_to_collaborative_draft_form.rb', line 18

def collaborative_draft
  @collaborative_draft ||= Decidim::Proposals::CollaborativeDraft.find id if id
end

#requester_userObject



22
23
24
# File 'app/forms/decidim/proposals/access_to_collaborative_draft_form.rb', line 22

def requester_user
  @requester_user ||= Decidim::User.find_by(id: requester_user_id, organization: current_organization) if requester_user_id
end