Class: ElFinder2::Image
- Defined in:
- app/models/el_finder2/image.rb
Class Method Summary collapse
Methods inherited from File
find_by_path, #path, path_exists?, #path_hash
Methods included from HashUtils
#from_base64url, #to_base64url, #to_path
Class Method Details
.upload_attributes(upload) ⇒ Object
9 10 11 12 13 |
# File 'app/models/el_finder2/image.rb', line 9 def self.upload_attributes(upload) geometry = Paperclip::Geometry.from_file(upload.path) { dimensions: "#{geometry.width.to_i}x#{geometry.height.to_i}" } end |