1
0
Fork 0
This repository has been archived on 2023-03-28. You can view files and clone it, but cannot push or open issues or pull requests.
lpr-partynest/app/forms/application_form.rb

17 lines
355 B
Ruby

# frozen_string_literal: true
class ApplicationForm
include ActiveModel::Model
include ActiveModel::Attributes
include ActiveModel::Validations::Callbacks
include ActiveRecord::AttributeAssignment
def has_attribute?(name)
attributes.key?(name.to_s)
end
def type_for_attribute(name)
self.class.attribute_types[name.to_s]
end
end