arkaan 1.3.7 → 1.3.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 +7 -0
- 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: a5b492b0df2365956ba0d8709c094dffc1a1a922
|
4
|
+
data.tar.gz: 7e6ac5a42d2dd931e18baff0b91c4d0a341b6e02
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 88cd07c0048788325f5bf15b6bc67555a3e7e2ccb987e506bba33844948014cf94c596c9c3c71d8915303ae36b3dd302e982e73e5b44c853829c09e7fbfe7730
|
7
|
+
data.tar.gz: 85493a95d21d4f87a9107ecbf602bb39fa4f9963f601a33945f4156b1d15de854d8478a4fb09c61e26f14a156cb7205bc27c92454a5282ff9588093230d7febe
|
data/lib/arkaan/account.rb
CHANGED
@@ -5,6 +5,7 @@ module Arkaan
|
|
5
5
|
include Mongoid::Document
|
6
6
|
include Mongoid::Timestamps
|
7
7
|
include ActiveModel::SecurePassword
|
8
|
+
include Arkaan::Concerns::Enumerable
|
8
9
|
|
9
10
|
# @!attribute [rw] username
|
10
11
|
# @return [String] the nickname the user chose at subscription, must be given, unique, and 6 or more characters long.
|
@@ -21,6 +22,12 @@ module Arkaan
|
|
21
22
|
# @!attribute [rw] email
|
22
23
|
# @return [String] the email address of the user, useful to contact them ; it must be given, unique, and have an email format.
|
23
24
|
field :email, type: String
|
25
|
+
# @!attribute [rw] language
|
26
|
+
# @return [Symbol] the language preferred by this user.
|
27
|
+
enum_field :language, [:english, :french], default: :french
|
28
|
+
# @!attribute [rw] gender
|
29
|
+
# @return [Symbol] the way you prefer the application to gender you.
|
30
|
+
enum_field :gender, [:female, :male, :neutral], default: :neutral
|
24
31
|
|
25
32
|
# @!attribute [w] password
|
26
33
|
# @return [String] password, in clear, of the user ; do not attempt to get the value, just set it when changing the password.
|