active_scaffold-sequel 0.5.0 → 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
@@ -794,7 +794,7 @@ ActiveScaffold.ActionLink.Abstract = Class.create({
|
|
794
794
|
this.enable();
|
795
795
|
this.adapter.remove();
|
796
796
|
if (this.hide_target) this.target.show();
|
797
|
-
if (ActiveScaffold.config.scroll_on_close) ActiveScaffold.scroll_to(this.target);
|
797
|
+
if (ActiveScaffold.config.scroll_on_close) ActiveScaffold.scroll_to($(this.target.readAttribute('id')));
|
798
798
|
},
|
799
799
|
|
800
800
|
reload: function() {
|
@@ -207,7 +207,7 @@ module ActiveScaffold::DataStructures
|
|
207
207
|
attr_writer :show_blank_record
|
208
208
|
def show_blank_record?(associated)
|
209
209
|
if @show_blank_record
|
210
|
-
return false unless self.association.associated_class.authorized_for?(:crud_type => :create)
|
210
|
+
return false unless self.association.associated_class.respond_to?(:authorized_for?) and self.association.associated_class.authorized_for?(:crud_type => :create)
|
211
211
|
self.plural_association? or (self.singular_association? and associated.blank?)
|
212
212
|
end
|
213
213
|
end
|
@@ -264,7 +264,7 @@ module ActiveScaffold
|
|
264
264
|
|
265
265
|
def column_show_add_new(column, associated, record)
|
266
266
|
value = column.plural_association? || (column.singular_association? and associated.empty?)
|
267
|
-
value = false unless column.association.associated_class.authorized_for?(:crud_type => :create)
|
267
|
+
value = false unless column.association.associated_class.respond_to?(:authorized_for?) and column.association.associated_class.authorized_for?(:crud_type => :create)
|
268
268
|
value
|
269
269
|
end
|
270
270
|
|
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: active_scaffold-sequel
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.5.
|
5
|
+
version: 0.5.1
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Many, see README
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2012-03-
|
13
|
+
date: 2012-03-23 00:00:00 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: shoulda
|