<%- include('_header-print'); -%>

Burial Site Contract

Contract Type
<%= contract.contractType %>

Burial Site
<% if (contract.burialSiteId) { %> <%= contract.burialSiteName %> <% } else { %> (No Burial Site) <% } %>

Cemetery
<% if (contract.cemeteryId) { %> <%= contract.cemeteryName %> <% } else { %> (No Cemetery) <% } %>

<%= configFunctions.getConfigProperty("aliases.occupancyStartDate") %>
<%= contract.occupancyStartDateString %>

End Date
<%= (contract.occupancyEndDateString === "" ? "(No End Date)" : contract.occupancyEndDateString) %>

<% if (contract.contractFields.length > 0) { %>
<% for (const contractField of contract.contractFields) { %>

<%= contractField.contractTypeField %>
<%= contractField.contractFieldValue || "(No Value)" %>

<% } %>
<% } %>

<%= configFunctions.getConfigProperty("aliases.occupants") %>

<% if (contract.contractOccupants.length === 0) { %>

There are no <%= configFunctions.getConfigProperty("aliases.occupants").toLowerCase() %> associated with this record.

<% } else { %> <% for (const contractInterment of contract.contractInterments) { %> <% } %>
Interment Address
<%= contractInterment.deceasedName %> <%= contractInterment.deceasedAddress1 %>
<% if (contractInterment.deceasedAddress2 && contractInterment.deceasedAddress2 !== "") { %> <%= contractInterment.deceasedAddress2 %>
<% } %> <% if (contractInterment.deceasedCity) { %> <%= contractInterment.deceasedCity %>, <% } %> <%= contractInterment.deceasedProvince %>
<%= contractInterment.deceasedPostalCode %>
<% } %>
<% if (contract.contractComments.length > 0) { %>

Comments

<% for (const contractComment of contract.contractComments) { %> <% } %>
Commentor Comment Date Comment
<%= contractComment.recordCreate_userName %> <%= contractComment.contractCommentDateString %> <%= (contractComment.contractCommentTime === 0 ? "" : contractComment.contractCommentTimeString) %> <%= contractComment.contractComment %>
<% } %>

Fees

<% if (contract.contractFees.length === 0) { %>

There are no fees applied to this <%= configFunctions.getConfigProperty("aliases.occupancy").toLowerCase() %> record.

<% } else { %> <% let feeAmountTotal = 0; let taxAmountTotal = 0; %> <% for (const contractFee of contract.contractFees) { %> <% feeAmountTotal += (contractFee.feeAmount * contractFee.quantity); taxAmountTotal += (contractFee.taxAmount * contractFee.quantity); %> <% if (contractFee.quantity !== 1) { %> <% } %> <% } %>
Fee Unit Cost × Quantity = Total
"> <%= contractFee.feeName %> $<%= contractFee.feeAmount.toFixed(2) %> × <%= contractFee.quantity %> =$<%= (contractFee.feeAmount * contractFee.quantity).toFixed(2) %>
Subtotal $<%= feeAmountTotal.toFixed(2) %>
Tax $<%= taxAmountTotal.toFixed(2) %>
Grand Total $<%= (feeAmountTotal + taxAmountTotal).toFixed(2) %>
<% } %>

Transactions

<% if (contract.contractTransactions.length === 0) { %>

There are no transactions associated with this <%= configFunctions.getConfigProperty("aliases.occupancy").toLowerCase() %> record.

<% } else { %> <% for (const contractTransaction of contract.contractTransactions) { %> <% } %>
Date <%= configFunctions.getConfigProperty("aliases.externalReceiptNumber") %> Amount
<%= contractTransaction.transactionDateString %> <%= contractTransaction.externalReceiptNumber %>
<%= contractTransaction.transactionNote %>
$<%= contractTransaction.transactionAmount.toFixed(2) %>
<% } %>
<%- include('_footer-print'); -%>