allow to delegate

This commit is contained in:
Pete Matsyburka
2026-03-27 12:56:52 +02:00
parent c23eca0ade
commit 3eb0b8a89f
23 changed files with 454 additions and 85 deletions
+1
View File
@@ -30,6 +30,7 @@ class AccountConfig < ApplicationRecord
ALLOW_TYPED_SIGNATURE = 'allow_typed_signature'
ALLOW_TO_RESUBMIT = 'allow_to_resubmit'
ALLOW_TO_DECLINE_KEY = 'allow_to_decline'
ALLOW_TO_DELEGATE_KEY = 'allow_to_delegate'
ALLOW_TO_PARTIAL_DOWNLOAD_KEY = 'allow_to_partial_download'
SUBMITTER_REMINDERS = 'submitter_reminders'
ENFORCE_SIGNING_ORDER_KEY = 'enforce_signing_order'
+1
View File
@@ -64,6 +64,7 @@ class SubmissionEvent < ApplicationRecord
invite_party: 'invite_party',
complete_form: 'complete_form',
decline_form: 'decline_form',
delegate_form: 'delegate_form',
api_complete_form: 'api_complete_form'
}, scope: false
+1
View File
@@ -44,6 +44,7 @@ class Submitter < ApplicationRecord
belongs_to :account
has_one :template, through: :submission
has_one :search_entry, as: :record, inverse_of: :record, dependent: :destroy if SearchEntry.table_exists?
has_many :submitter_versions, dependent: :destroy
attribute :values, :string, default: -> { {} }
attribute :preferences, :string, default: -> { {} }
+27
View File
@@ -0,0 +1,27 @@
# frozen_string_literal: true
# == Schema Information
#
# Table name: submitter_versions
#
# id :bigint not null, primary key
# email :string
# name :string
# phone :string
# slug :string not null
# created_at :datetime not null
# updated_at :datetime not null
# submitter_id :bigint not null
#
# Indexes
#
# index_submitter_versions_on_slug (slug)
# index_submitter_versions_on_submitter_id (submitter_id)
#
# Foreign Keys
#
# fk_rails_... (submitter_id => submitters.id)
#
class SubmitterVersion < ApplicationRecord
belongs_to :submitter
end