Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
raileendr committed Mar 27, 2024
2 parents a74434f + f214faf commit 750216a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions public/demo_documents/doc_1.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
color: darkblue;">Order Processing Division</h2>
<h4>Ordered by {USER_FULLNAME}</h4>
<p style="margin-top:0em; margin-bottom:0em;">Email: {USER_EMAIL}</p>
<p style="margin-top:0em; margin-bottom:0em;">Copy to: {CC_NAME}, {CC_EMAIL}</p>
<p style="margin-top:3em;">
Candy bonbon pastry jujubes lollipop wafer biscuit biscuit. Topping brownie sesame snaps sweet roll pie. Croissant danish biscuit soufflé caramels jujubes jelly. Dragée danish caramels lemon drops dragée. Gummi bears cupcake biscuit tiramisu sugar plum pastry. Dragée gummies applicake pudding liquorice. Donut jujubes oat cake jelly-o. Dessert bear claw chocolate cake gummies lollipop sugar plum ice cream gummies cheesecake.
</p>
Expand Down
12 changes: 12 additions & 0 deletions src/Services/Examples/eSignature/SetDocumentsVisibilityService.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,10 @@ private static function makeEnvelope(
'enforce_signer_visibility' => 'true',
'email_subject' => "Please sign this document set",
'documents' => SetDocumentsVisibilityService::_prepareDocuments(
$signer1Email,
$signer1Name,
$ccEmail,
$ccName,
$docPdf,
$docDocx,
$docHTML,
Expand Down Expand Up @@ -180,6 +184,10 @@ private static function _prepareSigners(
}

private static function _prepareDocuments(
string $signer1Email,
string $signer1Name,
string $ccEmail,
string $ccName,
string $docPdf,
string $docDocx,
string $docHTML,
Expand All @@ -188,6 +196,10 @@ private static function _prepareDocuments(
$contentBytesPdf = file_get_contents($demoPath . $docPdf);
$contentBytesDocx = file_get_contents($demoPath . $docDocx);
$contentBytesHtml = file_get_contents($demoPath . $docHTML);
$contentBytesHtml = str_replace("{USER_EMAIL}", $signer1Email, $contentBytesHtml);
$contentBytesHtml = str_replace("{USER_FULLNAME}", $signer1Name, $contentBytesHtml);
$contentBytesHtml = str_replace("{CC_EMAIL}", $ccEmail, $contentBytesHtml);
$contentBytesHtml = str_replace("{CC_NAME}", $ccName, $contentBytesHtml);

$documentHTML = new Document(
[
Expand Down

0 comments on commit 750216a

Please sign in to comment.