unidom-action 0.5 → 0.6
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9f8bec376bcc390b5796cf01122788c31da3f316
|
4
|
+
data.tar.gz: ace6b5c24f66effcffdc48219e51dee4e7040c29
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dffdd6b3aae58f2e1eaac6017c1c0d275963c77acaba13e3fcd9970b41cbb99d51bc6965e011dbcea6925f57257b43c2e9b29eacc2b6d7d0b768f2d639a12597
|
7
|
+
data.tar.gz: e9262d99f4a584ff96d5f6fd0c8607b3b840973c453d53bf6ff9c551eedb8c0b007c2ae347114cfe0a09541c3e1fc2f87cf8b4fadc4809bec91e9e60737dbc16
|
data/README.md
CHANGED
@@ -63,7 +63,9 @@ obsolescence = Unidom::Action::Obsolescence.create! obsolescer_visitor: user, ob
|
|
63
63
|
```ruby
|
64
64
|
include Unidom::Action::Concerns::AsActed
|
65
65
|
include Unidom::Action::Concerns::AsObsolesced
|
66
|
+
include Unidom::Action::Concerns::AsObsolescerParty
|
66
67
|
include Unidom::Action::Concerns::AsStateSubject
|
68
|
+
include Unidom::Action::Concerns::AsStateTransitorParty
|
67
69
|
```
|
68
70
|
|
69
71
|
### As Acted concern
|
@@ -76,7 +78,17 @@ The As Acted concern do the following tasks for the includer automatically:
|
|
76
78
|
The As Obsolesced concern do the following tasks for the includer automatically:
|
77
79
|
1. Define the has_many :obsolescings macro as: ``has_many :obsolescings, class_name: 'Unidom::Action::Obsolescing', as: :obsolesced``
|
78
80
|
|
81
|
+
### As Obsolescer Party concern
|
82
|
+
|
83
|
+
The As Obsolescer Party concern do the following tasks for the includer automatically:
|
84
|
+
1. Define the has_many :obsolesced_obsolescings macro as: ``has_many :obsolesced_obsolescings, class_name: 'Unidom::Action::Obsolescing', as: :obsolescer_party``
|
85
|
+
|
79
86
|
### As State Subject concern
|
80
87
|
|
81
88
|
The As State Subject concern do the following tasks for the includer automatically:
|
82
89
|
1. Define the has_many :state_transitions macro as: ``has_many :state_transitions, class_name: 'Unidom::Action::StateTransition', as: :subject``
|
90
|
+
|
91
|
+
### As State Transitor Party concern
|
92
|
+
|
93
|
+
The As State Transitor Party concern do the following tasks for the includer automatically:
|
94
|
+
1. Define the has_many :transited_state_transitions macro as: ``has_many :transited_state_transitions, class_name: 'Unidom::Action::StateTransition', as: :transitor_party``
|
@@ -0,0 +1,14 @@
|
|
1
|
+
module Unidom::Action::Concerns::AsObsolescerParty
|
2
|
+
|
3
|
+
extend ActiveSupport::Concern
|
4
|
+
|
5
|
+
included do |includer|
|
6
|
+
|
7
|
+
has_many :obsolesced_obsolescings, class_name: 'Unidom::Action::Obsolescing', as: :obsolescer_party
|
8
|
+
|
9
|
+
end
|
10
|
+
|
11
|
+
module ClassMethods
|
12
|
+
end
|
13
|
+
|
14
|
+
end
|
@@ -0,0 +1,14 @@
|
|
1
|
+
module Unidom::Action::Concerns::AsStateTransitorParty
|
2
|
+
|
3
|
+
extend ActiveSupport::Concern
|
4
|
+
|
5
|
+
included do |includer|
|
6
|
+
|
7
|
+
has_many :transited_state_transitions, class_name: 'Unidom::Action::StateTransition', as: :transitor_party
|
8
|
+
|
9
|
+
end
|
10
|
+
|
11
|
+
module ClassMethods
|
12
|
+
end
|
13
|
+
|
14
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: unidom-action
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.6'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Topbit Du
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-10-
|
11
|
+
date: 2016-10-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: unidom-common
|
@@ -47,7 +47,9 @@ files:
|
|
47
47
|
- app/models/unidom/action/application_record.rb
|
48
48
|
- app/models/unidom/action/concerns/as_acted.rb
|
49
49
|
- app/models/unidom/action/concerns/as_obsolesced.rb
|
50
|
+
- app/models/unidom/action/concerns/as_obsolescer_party.rb
|
50
51
|
- app/models/unidom/action/concerns/as_state_subject.rb
|
52
|
+
- app/models/unidom/action/concerns/as_state_transitor_party.rb
|
51
53
|
- app/models/unidom/action/obsolescing.rb
|
52
54
|
- app/models/unidom/action/reason.rb
|
53
55
|
- app/models/unidom/action/state_transition.rb
|