Sha256: ffee17e034f0e4f34c5095d33e72a13f91ac598c39a377ad5d2cb645b275e25b
Contents?: true
Size: 1.54 KB
Versions: 2
Compression:
Stored size: 1.54 KB
Contents
module Docusigner class Envelope < Docusigner::Base module Status CREATED = "created" DELETED = "deleted" SENT = "sent" DELIVERED = "delivered" SIGNED = "signed" COMPLETED = "completed" DECLINED = "declined" VOIDED = "voided" TIMED_OUT = "timedout" AUTHORITATIVE_COPY = "authoritativecopy" TRANSFER_COMPLETED = "transfercompleted" TEMPLATE = "template" CORRECT = "correct" end belongs_to :account has_many :documents has_many :recipients def id attributes["envelopeId"] end def send! update_attribute(:status, Docusigner::Envelope::Status::SENT) end def void!(reason) update_attributes({ :status => Docusigner::Envelope::Status::VOIDED, :voidReason => reason }) end def recipient_url(params = {}) resp = post("views/recipient", prefix_options, params.to_json) self.class.format.decode(resp.body) end def sender_url(params = {}) resp = post("views/sender", prefix_options, params.to_json) self.class.format.decode(resp.body) end def correct_url(params = {}) resp = post("views/correct", prefix_options, params.to_json) self.class.format.decode(resp.body) end # fetch documents - don't use helper b/c we don't want to try to parse as json def documents_combined(params = {}) connection.get(custom_method_element_url("documents/combined", prefix_options.merge(params)), self.class.headers).body end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
docusigner-0.0.4 | lib/docusigner/envelope.rb |
docusigner-0.0.3 | lib/docusigner/envelope.rb |