Class: Form1010cg::PoaUploader
- Inherits:
-
CarrierWave::Uploader::Base
- Object
- CarrierWave::Uploader::Base
- Form1010cg::PoaUploader
- Includes:
- LogMetrics, SetAWSConfig, UploaderVirusScan
- Defined in:
- app/uploaders/form1010cg/poa_uploader.rb
Constant Summary
Constants included from LogMetrics
Instance Attribute Summary collapse
-
#store_dir ⇒ Object
readonly
Returns the value of attribute store_dir.
Instance Method Summary collapse
- #content_type_allowlist ⇒ Object
- #extension_allowlist ⇒ Object
-
#initialize(form_attachment_guid) ⇒ PoaUploader
constructor
A new instance of PoaUploader.
- #size_range ⇒ Object
Methods included from UploaderVirusScan
Methods included from LogMetrics
Methods included from SetAWSConfig
Constructor Details
#initialize(form_attachment_guid) ⇒ PoaUploader
Returns a new instance of PoaUploader.
13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'app/uploaders/form1010cg/poa_uploader.rb', line 13 def initialize() super set_aws_config( Settings.form_10_10cg.poa.s3.aws_access_key_id, Settings.form_10_10cg.poa.s3.aws_secret_access_key, Settings.form_10_10cg.poa.s3.region, Settings.form_10_10cg.poa.s3.bucket ) @store_dir = end |
Instance Attribute Details
#store_dir ⇒ Object (readonly)
Returns the value of attribute store_dir.
11 12 13 |
# File 'app/uploaders/form1010cg/poa_uploader.rb', line 11 def store_dir @store_dir end |
Instance Method Details
#content_type_allowlist ⇒ Object
30 31 32 |
# File 'app/uploaders/form1010cg/poa_uploader.rb', line 30 def content_type_allowlist %w[image/jpg image/jpeg image/png application/pdf] end |
#extension_allowlist ⇒ Object
26 27 28 |
# File 'app/uploaders/form1010cg/poa_uploader.rb', line 26 def extension_allowlist %w[jpg jpeg png pdf] end |
#size_range ⇒ Object
34 35 36 |
# File 'app/uploaders/form1010cg/poa_uploader.rb', line 34 def size_range 1.byte...10.megabytes end |