lib/gooddata/models/profile.rb in gooddata-0.6.52 vs lib/gooddata/models/profile.rb in gooddata-0.6.53
- old
+ new
@@ -24,10 +24,11 @@
'login' => nil,
'phoneNumber' => nil,
'position' => nil,
'timezone' => nil,
'updated' => nil,
+ 'language' => nil,
'links' => {
'projects' => nil,
'self' => nil
},
'email' => nil,
@@ -42,11 +43,12 @@
:login,
:first_name,
:last_name,
:phone,
:position,
- :timezone
+ :timezone,
+ :language
]
PROFILE_PATH = '/gdc/account/profile/%s'
class << self
@@ -154,9 +156,24 @@
#
# @param val [String] Company name to be set
def company=(val)
@dirty ||= company != val
@json['accountSetting']['companyName'] = val
+ end
+
+ # Gets the language
+ #
+ # @return [String] Language
+ def language
+ @json['accountSetting']['language'] || 'en-US'
+ end
+
+ # Set the language
+ #
+ # @param val [String] Language to be set
+ def language=(val)
+ @dirty ||= language != val
+ @json['accountSetting']['language'] = val
end
# Gets the country
#
# @return [String] Country