glebtv-ckeditor 4.4.3.3 → 4.4.3.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ckeditor/version.rb +1 -1
- data/lib/generators/ckeditor/templates/active_record/paperclip/ckeditor/attachment_file.rb +4 -1
- data/lib/generators/ckeditor/templates/active_record/paperclip/ckeditor/picture.rb +5 -2
- data/lib/generators/ckeditor/templates/mongoid/paperclip/ckeditor/attachment_file.rb +5 -1
- data/lib/generators/ckeditor/templates/mongoid/paperclip/ckeditor/picture.rb +5 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d485a8b1df7dc5b6e3bacbb44fbb8a6e4eba3cc5
|
4
|
+
data.tar.gz: 6e664a7958dc53b87415eb1f2bf7475238bc45a8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 48f57823de6c9eaae06c0b1826cea0203a8dea3f007e50bb5cb44820a91aeaea2d1dccc5bf51118b7e155c129d82be75cc27ae84aabe84664b6be114159f645c
|
7
|
+
data.tar.gz: 70a4ccee28ecb77e20bc9fe49a0cd620b9bffe642ed801995284a8f894adb5c9904a50d1f51efb7d1919b27fbc7026340fc0c13404512fb7166c148b712278d9
|
data/lib/ckeditor/version.rb
CHANGED
@@ -2,7 +2,10 @@ class Ckeditor::AttachmentFile < Ckeditor::Asset
|
|
2
2
|
has_attached_file :data,
|
3
3
|
:url => "/ckeditor_assets/attachments/:id/:filename",
|
4
4
|
:path => ":rails_root/public/ckeditor_assets/attachments/:id/:filename"
|
5
|
-
|
5
|
+
|
6
|
+
if respond_to?(:do_not_validate_attachment_file_type)
|
7
|
+
do_not_validate_attachment_file_type :data, if: :data?
|
8
|
+
end
|
6
9
|
validates_attachment_size :data, :less_than => 100.megabytes
|
7
10
|
validates_attachment_presence :data
|
8
11
|
|
@@ -3,8 +3,11 @@ class Ckeditor::Picture < Ckeditor::Asset
|
|
3
3
|
:url => "/ckeditor_assets/pictures/:id/:style_:basename.:extension",
|
4
4
|
:path => ":rails_root/public/ckeditor_assets/pictures/:id/:style_:basename.:extension",
|
5
5
|
:styles => { :content => '800>', :thumb => '118x100#' }
|
6
|
-
|
7
|
-
|
6
|
+
|
7
|
+
if respond_to?(:validates_attachment_content_type)
|
8
|
+
validates_attachment_content_type :data, :content_type => ['image/gif', 'image/jpeg', 'image/jpg', 'image/png'], if: :data?
|
9
|
+
end
|
10
|
+
validates_attachment_size :data, :less_than => 10.megabytes
|
8
11
|
validates_attachment_presence :data
|
9
12
|
|
10
13
|
def url_content
|
@@ -2,7 +2,11 @@ class Ckeditor::AttachmentFile < Ckeditor::Asset
|
|
2
2
|
has_mongoid_attached_file :data,
|
3
3
|
:url => "/ckeditor_assets/attachments/:id/:filename",
|
4
4
|
:path => ":rails_root/public/ckeditor_assets/attachments/:id/:filename"
|
5
|
-
|
5
|
+
|
6
|
+
if respond_to?(:do_not_validate_attachment_file_type)
|
7
|
+
do_not_validate_attachment_file_type :data, if: :data?
|
8
|
+
end
|
9
|
+
|
6
10
|
validates_attachment_size :data, :less_than => 100.megabytes
|
7
11
|
validates_attachment_presence :data
|
8
12
|
|
@@ -3,8 +3,11 @@ class Ckeditor::Picture < Ckeditor::Asset
|
|
3
3
|
:url => "/ckeditor_assets/pictures/:id/:style_:basename.:extension",
|
4
4
|
:path => ":rails_root/public/ckeditor_assets/pictures/:id/:style_:basename.:extension",
|
5
5
|
:styles => { :content => '800>', :thumb => '118x100#' }
|
6
|
-
|
7
|
-
|
6
|
+
|
7
|
+
if respond_to?(:validates_attachment_content_type)
|
8
|
+
validates_attachment_content_type :data, :content_type => ['image/gif', 'image/jpeg', 'image/jpg', 'image/png'], if: :data?
|
9
|
+
end
|
10
|
+
validates_attachment_size :data, :less_than => 10.megabytes
|
8
11
|
validates_attachment_presence :data
|
9
12
|
|
10
13
|
def url_content
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: glebtv-ckeditor
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.4.3.
|
4
|
+
version: 4.4.3.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Igor Galeta
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-10-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|