arkaan 0.8.7 → 0.8.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/arkaan/account.rb +3 -0
- data/lib/arkaan/campaigns/invitation.rb +7 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fd0b2f1d08fc5e873ce338d61760b36532d9212d
|
4
|
+
data.tar.gz: c6e37ff40994d9ea548dee4c744ec7a5ace725b6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ec08731daaf756787dfa7c98f3cedb54f8f7fe96822463e4d7f67ad666e299bec91ebdc3f840d29ed6d427f13e7cece3755258e349e9fb25a75426de98094724
|
7
|
+
data.tar.gz: 7e76fbf5be189941f8b361c8e6cf7fe283e71f7bc079298d6af4fe328442df79f0728cafed0111678e9b905296db006e84a60451a21bfc7b85e3e881a9f3c274
|
data/lib/arkaan/account.rb
CHANGED
@@ -53,6 +53,9 @@ module Arkaan
|
|
53
53
|
# @!attribute [rw] invitations
|
54
54
|
# @return [Array<Arkaan::Campaigns::Invitation>] the invitations in campaigns you have been issued.
|
55
55
|
has_many :invitations, class_name: 'Arkaan::Campaigns::Invitation', inverse_of: :account
|
56
|
+
# @!attribute [rw] invitations
|
57
|
+
# @return [Array<Arkaan::Campaigns::Invitation>] the invitations you've issued yourself to other players.
|
58
|
+
has_many :created_invitations, class_name: 'Arkaan::Campaigns::Invitation', inverse_of: :creator
|
56
59
|
|
57
60
|
validates :username,
|
58
61
|
presence: {message: 'account.username.blank'},
|
@@ -9,13 +9,19 @@ module Arkaan
|
|
9
9
|
# @!attribute [rw] accepted
|
10
10
|
# @return [Boolean] TRUE if the invitation has been accepted, false otherwise.
|
11
11
|
field :accepted, type: Boolean, default: false
|
12
|
+
# @!attribute [rw] accepted_at
|
13
|
+
# @return [DateTime] the date at which the invitation has been accepted.
|
14
|
+
field :accepted_at, type: DateTime, default: nil
|
12
15
|
|
13
16
|
# @!attribute [rw] account
|
14
17
|
# @return [Arkaan::Account] the account the invitation has been issued to.
|
15
18
|
belongs_to :account, class_name: 'Arkaan::Account', inverse_of: :invitations
|
16
19
|
# @!attribute [rw] campaign
|
17
|
-
#
|
20
|
+
# @return [Arkaan::Campaign] the campaign the invitation has been made in.
|
18
21
|
belongs_to :campaign, class_name: 'Arkaan::Campaign', inverse_of: :invitations
|
22
|
+
# @!attribute [rw] creator
|
23
|
+
# @return [Arkaan::Account] the account creating the invitation.
|
24
|
+
belongs_to :creator, class_name: 'Arkaan::Account', inverse_of: :created_invitations
|
19
25
|
end
|
20
26
|
end
|
21
27
|
end
|