activeadmin 3.5.1 → 3.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/lib/active_admin/resource_controller/data_access.rb +8 -3
- data/lib/active_admin/router.rb +1 -1
- data/lib/active_admin/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: be95e31901e8d39cce8d91294688462aab2b0de748a1e42ab78225a80cf3691c
|
|
4
|
+
data.tar.gz: 627f265f8ff2cafbae08e8e620e6a838c724c60bb3ac1d25327485587cade73f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 7a4382f75f12aa918e5a027e9f56244b9b957fc1efcce1b20faae4005406c90f328857d96ba828a9b5b4f55e364d31a529fcb8c626eeece5a95b7458eab6a795
|
|
7
|
+
data.tar.gz: 8f52969b691a64f6ebe7a8401fe8a5f39fc3cb745bd73b5754f6071583fd450a9d2cd4568cc64f7ae51aa536eba10e57173dffbb9c1d554137cf7d423a3ac9db
|
data/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## 3.5.2 [☰](https://github.com/activeadmin/activeadmin/compare/v3.5.1..v3.5.2)
|
|
6
|
+
|
|
7
|
+
### Bug Fixes
|
|
8
|
+
|
|
9
|
+
* Backport run update_resource inside a transaction to avoid autosaving relationships through assign_attributes when the record is invalid [#9064] by [@mgrunberg] and [@deivid-rodriguez]
|
|
10
|
+
|
|
5
11
|
## 3.5.1 [☰](https://github.com/activeadmin/activeadmin/compare/v3.5.0..v3.5.1)
|
|
6
12
|
|
|
7
13
|
### Bug Fixes
|
|
@@ -1010,6 +1016,7 @@ Please check [0-6-stable] for previous changes.
|
|
|
1010
1016
|
[#8964]: https://github.com/activeadmin/activeadmin/pull/8964
|
|
1011
1017
|
[#8965]: https://github.com/activeadmin/activeadmin/pull/8965
|
|
1012
1018
|
[#8978]: https://github.com/activeadmin/activeadmin/pull/8978
|
|
1019
|
+
[#9064]: https://github.com/activeadmin/activeadmin/pull/9064
|
|
1013
1020
|
|
|
1014
1021
|
[@1000ship]: https://github.com/1000ship
|
|
1015
1022
|
[@5t111111]: https://github.com/5t111111
|
|
@@ -168,11 +168,16 @@ module ActiveAdmin
|
|
|
168
168
|
#
|
|
169
169
|
# @return [void]
|
|
170
170
|
def update_resource(object, attributes)
|
|
171
|
-
|
|
171
|
+
status = nil
|
|
172
|
+
ActiveRecord::Base.transaction do
|
|
173
|
+
object = assign_attributes(object, attributes)
|
|
172
174
|
|
|
173
|
-
|
|
174
|
-
|
|
175
|
+
run_update_callbacks object do
|
|
176
|
+
status = save_resource(object)
|
|
177
|
+
raise ActiveRecord::Rollback unless status
|
|
178
|
+
end
|
|
175
179
|
end
|
|
180
|
+
status
|
|
176
181
|
end
|
|
177
182
|
|
|
178
183
|
# Destroys an object from the database and calls appropriate callbacks.
|
data/lib/active_admin/router.rb
CHANGED
|
@@ -68,7 +68,7 @@ module ActiveAdmin
|
|
|
68
68
|
router.get "/#{page}", to: "#{page}#index"
|
|
69
69
|
config.page_actions.each do |action|
|
|
70
70
|
Array.wrap(action.http_verb).each do |verb|
|
|
71
|
-
build_route(verb, "/#{page}/#{action.name}"
|
|
71
|
+
build_route(verb, "/#{page}/#{action.name}", to: "#{page}##{action.name}")
|
|
72
72
|
end
|
|
73
73
|
end
|
|
74
74
|
end
|
data/lib/active_admin/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: activeadmin
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.5.
|
|
4
|
+
version: 3.5.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Charles Maresh
|
|
@@ -527,7 +527,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
527
527
|
- !ruby/object:Gem::Version
|
|
528
528
|
version: '0'
|
|
529
529
|
requirements: []
|
|
530
|
-
rubygems_version:
|
|
530
|
+
rubygems_version: 3.6.9
|
|
531
531
|
specification_version: 4
|
|
532
532
|
summary: Active Admin is a Ruby on Rails plugin for generating administration style
|
|
533
533
|
interfaces. It abstracts common business application patterns to make it simple
|