2019-12-05 09:05:21 +01:00
|
|
|
module CustomWizardFieldExtension
|
|
|
|
attr_reader :label,
|
|
|
|
:description,
|
|
|
|
:image,
|
|
|
|
:key,
|
|
|
|
:min_length,
|
|
|
|
:file_types,
|
2020-07-16 05:26:56 +02:00
|
|
|
:format,
|
2019-12-05 09:05:21 +01:00
|
|
|
:limit,
|
2020-03-24 10:35:46 +01:00
|
|
|
:property,
|
2020-03-30 08:16:03 +02:00
|
|
|
:content
|
2019-12-05 09:05:21 +01:00
|
|
|
|
|
|
|
def initialize(attrs)
|
2020-04-29 04:28:57 +02:00
|
|
|
super
|
2019-12-05 09:05:21 +01:00
|
|
|
@attrs = attrs || {}
|
|
|
|
@description = attrs[:description]
|
|
|
|
@image = attrs[:image]
|
|
|
|
@key = attrs[:key]
|
|
|
|
@min_length = attrs[:min_length]
|
|
|
|
@file_types = attrs[:file_types]
|
2020-07-16 05:26:56 +02:00
|
|
|
@format = attrs[:format]
|
2019-12-05 09:05:21 +01:00
|
|
|
@limit = attrs[:limit]
|
|
|
|
@property = attrs[:property]
|
2020-03-30 08:16:03 +02:00
|
|
|
@content = attrs[:content]
|
2019-12-05 09:05:21 +01:00
|
|
|
end
|
|
|
|
|
|
|
|
def label
|
2020-08-11 07:43:27 +02:00
|
|
|
@label ||= @attrs[:label]
|
2019-12-05 09:05:21 +01:00
|
|
|
end
|
2020-08-11 07:43:27 +02:00
|
|
|
end
|