auditor 2.3.1 → 2.3.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -74,6 +74,10 @@ The audited_changes column automatically serializes the changes of any model att
74
74
  # Associate the audit records with a related model, which becomes the owner
75
75
  audit(:update, :on => :book)
76
76
 
77
+ # Associate the audit records with a related model, multiple levels up.
78
+ # Here, we're auditing a great-grandchild where :parent will be the owner. Order is important.
79
+ audit(:update, :on => [:grandchild, :child, :parent])
80
+
77
81
  = Make Auditing Important
78
82
 
79
83
  There's an alternate form of specifying your audit requirements that will cause the create, find, update, or destroy to fail if for some reason the audit record cannot be saved to the database. Instead of calling audit, call audit! instead.
@@ -14,7 +14,7 @@ class Audit < ActiveRecord::Base
14
14
  default_scope order(:version, :created_at)
15
15
  scope :modifying, lambda {
16
16
  where( [
17
- 'audited_changes is not ? and audited_changes != ?',
17
+ 'audited_changes is not ? and audited_changes not like ?',
18
18
  nil, # ActiveRecord 3.0
19
19
  nil.to_yaml # ActiveRecord 3.1
20
20
  ] )
@@ -1,3 +1,3 @@
1
1
  module Auditor
2
- VERSION = "2.3.1"
2
+ VERSION = "2.3.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: auditor
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.1
4
+ version: 2.3.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-06-07 00:00:00.000000000Z
12
+ date: 2012-09-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activerecord
16
- requirement: &70163354396440 !ruby/object:Gem::Requirement
16
+ requirement: !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ~>
@@ -21,29 +21,44 @@ dependencies:
21
21
  version: '3.0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *70163354396440
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ~>
28
+ - !ruby/object:Gem::Version
29
+ version: '3.0'
25
30
  - !ruby/object:Gem::Dependency
26
31
  name: rspec
27
- requirement: &70163354395940 !ruby/object:Gem::Requirement
32
+ requirement: !ruby/object:Gem::Requirement
28
33
  none: false
29
34
  requirements:
30
- - - =
35
+ - - '='
31
36
  - !ruby/object:Gem::Version
32
37
  version: 2.5.0
33
38
  type: :development
34
39
  prerelease: false
35
- version_requirements: *70163354395940
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - '='
44
+ - !ruby/object:Gem::Version
45
+ version: 2.5.0
36
46
  - !ruby/object:Gem::Dependency
37
47
  name: sqlite3-ruby
38
- requirement: &70163354395460 !ruby/object:Gem::Requirement
48
+ requirement: !ruby/object:Gem::Requirement
39
49
  none: false
40
50
  requirements:
41
- - - =
51
+ - - '='
42
52
  - !ruby/object:Gem::Version
43
53
  version: 1.3.3
44
54
  type: :development
45
55
  prerelease: false
46
- version_requirements: *70163354395460
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - '='
60
+ - !ruby/object:Gem::Version
61
+ version: 1.3.3
47
62
  description: Auditor allows you to declaratively specify what CRUD operations should
48
63
  be audited and save the audit data to the database.
49
64
  email:
@@ -100,7 +115,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
100
115
  version: '0'
101
116
  requirements: []
102
117
  rubyforge_project:
103
- rubygems_version: 1.8.10
118
+ rubygems_version: 1.8.23
104
119
  signing_key:
105
120
  specification_version: 3
106
121
  summary: Rails 3 plugin for auditing access to your ActiveRecord model objects