Class: Docusigner::UserSettings
- Defined in:
- lib/docusigner/user_settings.rb
Instance Method Summary collapse
-
#as_json ⇒ Object
the create endpoint requires attributes to be nested under newUsers.
- #load(attributes, remove_root = false) ⇒ Object
- #set(key, value) ⇒ Object
Methods inherited from Base
act_as_user, authorization=, connection, headers, #to_json, token=
Methods included from Multipart::Resource
Instance Method Details
#as_json ⇒ Object
the create endpoint requires attributes to be nested under newUsers
10 11 12 |
# File 'lib/docusigner/user_settings.rb', line 10 def as_json { "userSettings" => user_settings.map(&:as_json) } end |
#load(attributes, remove_root = false) ⇒ Object
14 15 16 |
# File 'lib/docusigner/user_settings.rb', line 14 def load(attributes, remove_root = false) super({:user_settings => attributes}, remove_root) end |
#set(key, value) ⇒ Object
18 19 20 |
# File 'lib/docusigner/user_settings.rb', line 18 def set(key, value) user_settings.detect{|us| key == us.name}.value = value end |