diff options
author | Star Rauchenberger <fefferburbia@gmail.com> | 2023-10-11 11:39:16 -0400 |
---|---|---|
committer | Star Rauchenberger <fefferburbia@gmail.com> | 2023-10-11 11:39:16 -0400 |
commit | 3a628945ade35f3ba351ba90e271608520753174 (patch) | |
tree | 05c496db4cf11aec1e334336858bf3fafff0c9e0 /app/models/ckeditor | |
parent | ffcc44d1a73ae1191e835fa625f2f8a7e3e25bda (diff) | |
download | thoughts-3a628945ade35f3ba351ba90e271608520753174.tar.gz thoughts-3a628945ade35f3ba351ba90e271608520753174.tar.bz2 thoughts-3a628945ade35f3ba351ba90e271608520753174.zip |
Removed ckeditor
Diffstat (limited to 'app/models/ckeditor')
-rw-r--r-- | app/models/ckeditor/asset.rb | 4 | ||||
-rw-r--r-- | app/models/ckeditor/attachment_file.rb | 13 | ||||
-rw-r--r-- | app/models/ckeditor/picture.rb | 14 |
3 files changed, 0 insertions, 31 deletions
diff --git a/app/models/ckeditor/asset.rb b/app/models/ckeditor/asset.rb deleted file mode 100644 index cf636ed..0000000 --- a/app/models/ckeditor/asset.rb +++ /dev/null | |||
@@ -1,4 +0,0 @@ | |||
1 | class Ckeditor::Asset < ActiveRecord::Base | ||
2 | include Ckeditor::Orm::ActiveRecord::AssetBase | ||
3 | include Ckeditor::Backend::Paperclip | ||
4 | end | ||
diff --git a/app/models/ckeditor/attachment_file.rb b/app/models/ckeditor/attachment_file.rb deleted file mode 100644 index fe09132..0000000 --- a/app/models/ckeditor/attachment_file.rb +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | class Ckeditor::AttachmentFile < Ckeditor::Asset | ||
2 | has_attached_file :data, | ||
3 | url: '/uploads/attachments/:id/:filename', | ||
4 | path: ':rails_root/public/uploads/attachments/:id/:filename' | ||
5 | |||
6 | validates_attachment_presence :data | ||
7 | validates_attachment_size :data, less_than: 100.megabytes | ||
8 | do_not_validate_attachment_file_type :data | ||
9 | |||
10 | def url_thumb | ||
11 | @url_thumb ||= Ckeditor::Utils.filethumb(filename) | ||
12 | end | ||
13 | end | ||
diff --git a/app/models/ckeditor/picture.rb b/app/models/ckeditor/picture.rb deleted file mode 100644 index 02aa9b2..0000000 --- a/app/models/ckeditor/picture.rb +++ /dev/null | |||
@@ -1,14 +0,0 @@ | |||
1 | class Ckeditor::Picture < Ckeditor::Asset | ||
2 | has_attached_file :data, | ||
3 | url: '/uploads/pictures/:id/:style_:basename.:extension', | ||
4 | path: ':rails_root/public/uploads/pictures/:id/:style_:basename.:extension', | ||
5 | styles: { content: '800>', thumb: '118x100#' } | ||
6 | |||
7 | validates_attachment_presence :data | ||
8 | validates_attachment_size :data, less_than: 2.megabytes | ||
9 | validates_attachment_content_type :data, content_type: /\Aimage/ | ||
10 | |||
11 | def url_content | ||
12 | url(:content) | ||
13 | end | ||
14 | end | ||