|
|
@@ -29,16 +29,26 @@ fill="currentColor" class="bi bi-plus" viewBox="0 0 16 16"> <path d="M8 4a.5.5 0 |
|
|
|
</section> |
|
|
|
|
|
|
|
<section class="form inputs"> |
|
|
|
|
|
|
|
<div class="hint"> |
|
|
|
<img class="icon" src="/assets/image/icon/question-circle.svg" alt=""> |
|
|
|
<div class="tooltip"> |
|
|
|
<p>Assumes borrower is not self employed, not bankrupt in the past 7 |
|
|
|
years, a citizen, and intends to occupy the property.</p> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
<h3>Borrower</h3> |
|
|
|
<label>Number of Borrowers</label> |
|
|
|
<input :value="loans[sel].borrowers" |
|
|
|
@input="(e) => loans.forEach(l => l.borrowers = strip(e))"> |
|
|
|
<label>Credit Score</label> |
|
|
|
<input :value="loans[sel].creditScore" |
|
|
|
@input="(e) => loans[sel].creditScore = strip(e)"> |
|
|
|
@input="(e) => loans.forEach(l => l.creditScore = strip(e))"> |
|
|
|
<label>Monthly Income ($)</label> |
|
|
|
<input :value="loans[sel].mIncome" |
|
|
|
@input="(e) => loans[sel].mIncome = strip(e)"> |
|
|
|
@input="(e) => loans.forEach(l => l.mIncome = strip(e))"> |
|
|
|
|
|
|
|
</section> |
|
|
|
|
|
|
|
<section class="radios form"> |
|
|
@@ -150,13 +160,16 @@ function setAmount(e) { |
|
|
|
loan.ltv = Math.round(amount / loan.price * 100) |
|
|
|
} |
|
|
|
|
|
|
|
// Updates the property price for all loans |
|
|
|
function setPrice(e) { |
|
|
|
let loan = this.loans[this.sel] |
|
|
|
let value = strip(e) |
|
|
|
|
|
|
|
loan.price = value |
|
|
|
this.loans.forEach(l => { |
|
|
|
l.price = value |
|
|
|
l.amount = Math.round(l.ltv / 100 * value) |
|
|
|
}) |
|
|
|
|
|
|
|
e.target.value = value |
|
|
|
loan.amount = Math.round(loan.ltv / 100 * value) |
|
|
|
} |
|
|
|
|
|
|
|
function setDti(e) { |
|
|
|