Class: Universign::TransactionSigner
- Defined in:
- lib/universign/transaction_signer.rb
Instance Attribute Summary collapse
-
#callbacks ⇒ Object
Returns the value of attribute callbacks.
-
#phone_number ⇒ Object
Returns the value of attribute phone_number.
-
#signature ⇒ Object
Returns the value of attribute signature.
Attributes inherited from Signer
Instance Method Summary collapse
-
#birtdate=(data) ⇒ Object
This signer’s birth date.
- #cancel_url=(data) ⇒ Object
-
#email=(data) ⇒ Object
This signer’s e-mail address.
- #fail_url=(data) ⇒ Object
-
#identification_type=(data) ⇒ Object
Which authentication type will be used when a signer will attempt to sign.
-
#initialize(options = {}) ⇒ TransactionSigner
constructor
A new instance of TransactionSigner.
-
#organization=(data) ⇒ Object
This signer’s organization.
-
#role=(data) ⇒ Object
The role of this transaction actor.
-
#signature_field=(data) ⇒ Object
A description of a visible PDF signature field.
-
#success_url=(data) ⇒ Object
The url to where the signer will be redirected, after the signatures are completed.
Methods inherited from Signer
#first_name, #first_name=, from_data, #last_name, #last_name=
Constructor Details
#initialize(options = {}) ⇒ TransactionSigner
Returns a new instance of TransactionSigner.
5 6 7 8 9 10 11 |
# File 'lib/universign/transaction_signer.rb', line 5 def initialize( = {}) super() .each do |key, value| send("#{key}=", value) end end |
Instance Attribute Details
#callbacks ⇒ Object
Returns the value of attribute callbacks.
3 4 5 |
# File 'lib/universign/transaction_signer.rb', line 3 def callbacks @callbacks end |
#phone_number ⇒ Object
Returns the value of attribute phone_number.
3 4 5 |
# File 'lib/universign/transaction_signer.rb', line 3 def phone_number @phone_number end |
#signature ⇒ Object
Returns the value of attribute signature.
3 4 5 |
# File 'lib/universign/transaction_signer.rb', line 3 def signature @signature end |
Instance Method Details
#birtdate=(data) ⇒ Object
This signer’s birth date. This is an option for the certified signature
71 72 73 74 |
# File 'lib/universign/transaction_signer.rb', line 71 def birtdate=(data) @birthdate = data params[:birthDate] = data end |
#cancel_url=(data) ⇒ Object
84 85 86 87 |
# File 'lib/universign/transaction_signer.rb', line 84 def cancel_url=(data) @cancel_url = data params[:cancelURL] = data end |
#email=(data) ⇒ Object
This signer’s e-mail address
24 25 26 27 |
# File 'lib/universign/transaction_signer.rb', line 24 def email=(data) @email = data params[:emailAddress] = data end |
#fail_url=(data) ⇒ Object
89 90 91 92 |
# File 'lib/universign/transaction_signer.rb', line 89 def fail_url=(data) @fail_url = data params[:failURL] = data end |
#identification_type=(data) ⇒ Object
Which authentication type will be used when a signer will attempt to sign.
The available values are : | Type | Description | |:——-:|:——————————————————————————————————————————————————————————–:| | ‘none` | The signer won’t be asked an authentication code when signing | | `email` | The signer will be sent a authentication code by e-mail. Using this option implies that this signer has a valid email property set, otherwise, an exception is thrown | | `sms` | The signer will be sent a authentication code by sms. Using this option implies that this signer has a valid `phone_number` property set, in other cases, an exception is thrown |
102 103 104 105 |
# File 'lib/universign/transaction_signer.rb', line 102 def identification_type=(data) @identification_type = data params[:identificationType] = data end |
#organization=(data) ⇒ Object
This signer’s organization
16 17 18 19 |
# File 'lib/universign/transaction_signer.rb', line 16 def organization=(data) @organization = data params[:organisation] = data end |
#role=(data) ⇒ Object
The role of this transaction actor
| Role | Description | |:———-:|:—————————————————————————————-:| | ‘signer` | (default) This actor is a signer and he will be able to view the documents and sign them | | `observer` | This actor is an observer and he will be able only to view the documents |
48 49 50 51 |
# File 'lib/universign/transaction_signer.rb', line 48 def role=(data) @role = data params[:role] = data end |
#signature_field=(data) ⇒ Object
A description of a visible PDF signature field. If none provided, no signature field will be produced on the signed document
58 59 60 61 62 63 64 65 |
# File 'lib/universign/transaction_signer.rb', line 58 def signature_field=(data) if !data.instance_of?(Universign::SignatureField) raise 'BadSignatureFieldType' # TODO: create custom Exception end @signature_field = data params[:signatureField] = data.params end |
#success_url=(data) ⇒ Object
The url to where the signer will be redirected, after the signatures are completed. If it is null it takes the value of Universign::Transaction#success_url If it is also null, it takes the default Universign success URL
79 80 81 82 |
# File 'lib/universign/transaction_signer.rb', line 79 def success_url=(data) @success_url = data params[:successURL] = data end |