PR changes
This commit is contained in:
parent
beeeed8778
commit
63c5999261
3 changed files with 9 additions and 5 deletions
|
|
@ -144,7 +144,7 @@ export default {
|
|||
if (this.educatorEndorsement) {
|
||||
this.questionAnswersArray.push({
|
||||
questionNum: 1,
|
||||
endorsement: endorsementOptions.EDUCATOR,
|
||||
endorsementName: endorsementOptions.EDUCATOR,
|
||||
questionText: this.schoolPropertyQuestionText,
|
||||
selectedAnswer: this.schoolPropertyAnswer
|
||||
});
|
||||
|
|
@ -152,7 +152,7 @@ export default {
|
|||
if (this.parkingGuardEndorsement) {
|
||||
this.questionAnswersArray.push({
|
||||
questionNum: 2,
|
||||
endorsement: endorsementOptions.PARKING_GUARD,
|
||||
endorsementName: endorsementOptions.PARKING_GUARD,
|
||||
questionText: this.parkingLotQuestionText,
|
||||
selectedAnswer: this.parkingLotAnswer
|
||||
});
|
||||
|
|
|
|||
|
|
@ -510,8 +510,12 @@ export const useMainStore = defineStore({
|
|||
getFinalDeductible() {
|
||||
const endorsementAnswersForPayload = [];
|
||||
const endorsementAnswers = this.order.policy.endorsementQuestionAnswers;
|
||||
if (endorsementAnswers && endorsementAnswers[0]?.selectedAnswer === 'Yes') {
|
||||
endorsementAnswersForPayload.push(this.order.policy.endorsementQuestionAnswers[0].endorsement);
|
||||
if (endorsementAnswers) {
|
||||
endorsementAnswers.forEach((endorsement) => {
|
||||
if (endorsement.selectedAnswer === 'Yes') {
|
||||
endorsementAnswersForPayload.push(endorsement.endorsementName);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
|
|
|
|||
|
|
@ -1759,7 +1759,7 @@ describe('Store', () => {
|
|||
});
|
||||
});
|
||||
describe('unsuccessful api call', () => {
|
||||
it.only('api call throws exception', async () => {
|
||||
it('api call throws exception', async () => {
|
||||
// Arrange
|
||||
expect.assertions(2);
|
||||
const error = 'final deductible error';
|
||||
|
|
|
|||
Loading…
Reference in a new issue