ack_rails_admin_jcrop 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a4f0c2fb571d80ca926baf496b823b681c8ddb2a
4
- data.tar.gz: 60d44c3be2f7f01c5f00f7a868306ae31dde55b4
3
+ metadata.gz: 13e72edc6e6ed63c6cd118009e26c277dac8fe6c
4
+ data.tar.gz: 966e0bc8e5c40c4ec6b45412cd0039b66d48e6eb
5
5
  SHA512:
6
- metadata.gz: c68157026b39feca78a3e1bdc75a60bf06e5bda3430bef960960a5a9bcfb677f58b25bd4c7bef22f9be4ff073a438c46c4a9e38702915f3d29c3fd70b4cc002b
7
- data.tar.gz: 3203270f31dec56969c9401dfc7957a229ffe42ed7aec7a48558fca7ffe5d0997b625d94709edfb81b5c5c461a403901602715327938afa066c063df9e50075d
6
+ metadata.gz: ca19b55f93ff61844c28db8f8d62e2151e74b9724af7f407cbbc3127488ac4850c7f5c730ec1fd5c2071cc4976e1ace2fa97e57dd8cda9f33791c229cfe38ca9
7
+ data.tar.gz: 47905ee8778fdd1bb5d6a0924c7d422d6c80081b21606ae2bdc3df60526ba7f98f12ba2008efde6961dad1ebbfafff7313cc72fd1ca610a98ee016fb3d57cfc3
@@ -126,7 +126,7 @@
126
126
  '</div>');
127
127
  widget.dialog.modal({
128
128
  keyboard: true,
129
- backdrop: true,
129
+ backdrop: false,
130
130
  show: true
131
131
  })
132
132
  .on('hidden.bs.modal', function(){
@@ -1,5 +1,17 @@
1
1
  .jcrop_data_value
2
2
  cursor: pointer
3
+ display: inline-block
4
+ &:hover
5
+ font-weight: bold
6
+ &:active
7
+ .title_link_hint
8
+ color: black
9
+ .title_link_hint
10
+ color: blue
11
+ display: inline-block
12
+ border-bottom: 1px solid blue
13
+ margin-bottom: 5px
14
+ line-height: 14px
3
15
 
4
16
  .jcrop_data_value img, .jcrop_type .img-polaroid
5
17
  min-width: 50px
@@ -16,7 +16,10 @@
16
16
 
17
17
  .toggle{style=('display:none;' if file and field.delete_method and form.object.send(field.delete_method) == '1')}
18
18
  - if value = field.pretty_value
19
- .jcrop_data_value= value
19
+ .jcrop_data_value
20
+ .title_link_hint= "Обрезать"
21
+ div
22
+ = value
20
23
  = form.file_field(field.name, field.html_attributes.reverse_merge({data: {fileupload: true, rails_admin_jcrop_options: rails_admin_jcrop_options } }))
21
24
 
22
25
  - url = jcrop_path(model_name: form.object.class.to_param, modal: true, id: form.object.id, field: field.name, fit_image: field.fit_image)
@@ -6,7 +6,7 @@ module RailsAdminJcrop
6
6
  end
7
7
 
8
8
  def crop!(obj, field)
9
- obj.send(field).reprocess! && obj.save
9
+ obj.send(field).reprocess!
10
10
  end
11
11
  end
12
12
  end
@@ -14,12 +14,13 @@ end
14
14
 
15
15
  module Paperclip
16
16
 
17
- module NewClassMethods
17
+ module RailsAdminJcropperMethods
18
18
  def has_attached_file(*args)
19
19
  super
20
20
  self.attachment_definitions.each do |name, options|
21
21
  options[:processors] ||= []
22
22
  options[:processors] << :rails_admin_jcropper
23
+ options[:processors].uniq!
23
24
  end
24
25
  end
25
26
  end
@@ -27,7 +28,7 @@ module Paperclip
27
28
  module ClassMethods
28
29
  def self.extended(base)
29
30
  super
30
- base.send :extend, ::Paperclip::NewClassMethods
31
+ base.send :extend, ::Paperclip::RailsAdminJcropperMethods
31
32
  end
32
33
  end
33
34
 
@@ -1,3 +1,3 @@
1
1
  module RailsAdminJcrop
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ack_rails_admin_jcrop
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - ack43
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-05-12 00:00:00.000000000 Z
12
+ date: 2015-06-05 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails