Sha256: 5d52f2d0e875977174357f62a1b7acfe72eaf9d0242c3bf626bd837ab7b5556c
Contents?: true
Size: 422 Bytes
Versions: 10
Compression:
Stored size: 422 Bytes
Contents
# frozen_string_literal: true module Ckeditor class AttachmentFileUploader < Shrine plugin :validation_helpers Attacher.validate do validate_max_size 100.megabytes end end class AttachmentFile < Ckeditor::Asset include AttachmentFileUploader.attachment(:data) validates :data, presence: true def url_thumb @url_thumb ||= Ckeditor::Utils.filethumb(filename) end end end
Version data entries
10 entries across 7 versions & 2 rubygems