Skip to content

Commit

Permalink
Merge branch 'feature/report-allow-only-pdfs' into staging
Browse files Browse the repository at this point in the history
  • Loading branch information
tsubik committed Feb 3, 2025
2 parents a50c230 + ed094dd commit 24c750a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/admin/observation_report.rb
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ def apply_filtering(chain)
f.input :user
f.input :title
f.input :publication_date, as: :date_time_picker, picker_options: {timepicker: false, format: "Y-m-d"}
f.input :attachment, as: :file, hint: f.object&.attachment&.file&.filename
f.input :attachment, as: :file, hint: f.object&.attachment&.file&.filename, input_html: {accept: "application/pdf"}
f.input :observers
end

Expand Down
2 changes: 1 addition & 1 deletion app/uploaders/observation_report_uploader.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

class ObservationReportUploader < ApplicationUploader
def extension_allowlist
%w[pdf doc docx txt csv xml jpg jpeg png exif tiff bmp]
%w[pdf]
end

def filename
Expand Down

0 comments on commit 24c750a

Please sign in to comment.