Skouter mortgage estimates. Web application with view written in PHP and Vue, but controller and models in Go.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

146 line
3.3 KiB

  1. <!DOCTYPE html>
  2. <head>
  3. <meta charset='utf-8'>
  4. <meta name="viewport"
  5. content="width=device-width, initial-scale=1, shrink-to-fit=no">
  6. </head>
  7. <body id="pdf-doc">
  8. <div class="disclaimer">
  9. <p>Actual costs may vary from estimates after approval.
  10. Get an official quote before choosing a loan.</p>
  11. </div>
  12. {{template "header" .}}
  13. {{template "comparison" .}}
  14. {{range .Estimate.Loans}}
  15. <div class="break"></div>
  16. <div class="disclaimer">
  17. <p>Actual costs may vary from estimates after approval.
  18. Get an official quote before choosing a loan.</p>
  19. </div>
  20. {{template "header" $}}
  21. <section class="summary">
  22. <h1>{{.Name}}</h1>
  23. <h4>{{.Type.Name}} {{.Term}} Year, {{.Amortization}} rate</h4>
  24. <div>
  25. <div class="entries">
  26. <h4 class="title">Monthly Payment</h4>
  27. <p><span>Loan payment</span> <span>${{dollars .Result.LoanPayment}}</span></p>
  28. <p><span>Mortgage insurance</span> <span>${{dollars .Mi.Premium}}</span></p>
  29. <p><span>Property taxes</span> <span>${{dollars .Tax}}</span></p>
  30. <p><span>Homeowner's insurance</span> <span>${{dollars .Hoi}}</span></p>
  31. <p class="total"><span>Total</span> <span>${{dollars .Result.TotalMonthly}}</span></p>
  32. </div>
  33. <div class="entries">
  34. <h4 class="title">Transaction Details</h4>
  35. <p><span>Down payment</span> <span>${{diff .Amount $.Estimate.Price}}</span></p>
  36. <p><span>Closing costs</span> <span>${{dollars .Result.TotalFees}}</span></p>
  37. <p><span>Credits</span> <span>${{dollars .Result.TotalCredits}}</span></p>
  38. <p class="total"><span>Total</span>
  39. <span>${{dollars .Result.CashToClose}}</span></p>
  40. </div>
  41. </div>
  42. <h2>Closing Costs Breakdown</h2>
  43. <div>
  44. <div class="entries">
  45. <h4 class="title">Fees Paid to Lender</h4>
  46. {{range (sortFees "Lender" .Fees)}}
  47. <p><span>{{.Name}}</span> <span>${{dollars .Amount}}</span></p>
  48. {{end}}
  49. </div>
  50. <div class="entries">
  51. <h4 class="title">Items Required by Lender</h4>
  52. {{range (sortFees "Required" .Fees)}}
  53. <p><span>{{.Name}}</span> <span>${{dollars .Amount}}</span></p>
  54. {{end}}
  55. </div>
  56. <div class="entries">
  57. <h4 class="title">Title Company Fees</h4>
  58. {{range (sortFees "Title" .Fees)}}
  59. <p><span>{{.Name}}</span> <span>${{dollars .Amount}}</span></p>
  60. {{end}}
  61. </div>
  62. <div class="entries">
  63. <h4 class="title">Goverment and Recording Fees</h4>
  64. {{range (sortFees "Government" .Fees)}}
  65. <p><span>{{.Name}}</span> <span>${{dollars .Amount}}</span></p>
  66. {{end}}
  67. </div>
  68. <div class="entries">
  69. <h4 class="title">Other Fees</h4>
  70. {{range (sortFees "Other" .Fees)}}
  71. <p><span>{{.Name}}</span> <span>${{dollars .Amount}}</span></p>
  72. {{end}}
  73. </div>
  74. </div>
  75. </section>
  76. {{end}}
  77. </body>
  78. <style>
  79. .disclaimer {
  80. font-weight: bold;
  81. border-bottom: 1px solid lightgrey;
  82. margin-bottom: 20px;
  83. color: var(--text);
  84. text-align: center;
  85. }
  86. .disclaimer p {
  87. margin: 5px 0;
  88. }
  89. div.break {
  90. page-break-after: always;
  91. }
  92. .summary h1 {
  93. text-align: center;
  94. }
  95. .summary h2 {
  96. text-align: center;
  97. font-size: 20px;
  98. color: #4C555E;
  99. }
  100. .summary h4 {
  101. text-align: center;
  102. font-weight: normal;
  103. margin-bottom: 25px;
  104. }
  105. .summary > div {
  106. display: flex;
  107. flex-flow: wrap;
  108. justify-content: center;
  109. }
  110. .summary .entries {
  111. width: 300px;
  112. margin: 0 10px;
  113. }
  114. .summary .entries h4 {
  115. background: #F5F5F3;
  116. padding: 5px;
  117. }
  118. .summary .entries p {
  119. display: flex;
  120. justify-content: space-between;
  121. border-bottom: 1px solid #F5F5F3;
  122. }
  123. p.total {
  124. font-weight: bold;
  125. }
  126. </style>