formatting

This commit is contained in:
Katie Kroell 2023-05-11 12:04:26 -04:00
parent 05c7e247a7
commit c49217aee6

View file

@ -293,25 +293,24 @@ export default {
async getVehiclesfromPolicyLookup()
{
//call coverage policy lookup if isCoverageEnabled flag enabled
if(this.isCoverageEnabled){
if (this.isCoverageEnabled){
const policyLookupResponse = await this.getPolicyLookupResponse();
if(policyLookupResponse!=null){
if (policyLookupResponse !== null){
var policy = policyLookupResponse.policies?.[0];
if(policy!=null){
if (policy !== null){
//populate policy holder details from policy lookup
this.mainStore.order.customer.address.streetAddress = policy.insureds?.[0]?.address;
this.mainStore.order.customer.address.city=policy.insureds?.[0]?.city;
this.mainStore.order.customer.address.state=policy.insureds?.[0]?.state;
this.mainStore.order.customer.address.zipCode=policy.insureds?.[0]?.zipCode;
this.mainStore.order.customer.address.city = policy.insureds?.[0]?.city;
this.mainStore.order.customer.address.state = policy.insureds?.[0]?.state;
this.mainStore.order.customer.address.zipCode = policy.insureds?.[0]?.zipCode;
this.mainStore.order.customer.firstName = policy.insureds?.[0]?.firstName;
this.mainStore.order.customer.lastName = policy.insureds?.[0]?.lastName;
//populate vehicles
this.vehiclesFound= policy.vehicles;
this.vehiclesFound = policy.vehicles;
}
}
}
}
},
getWelcomePageModelFromStore() {
@ -332,7 +331,7 @@ export default {
computed:{
DamageCauseOptions() {
const damageCauseAnswers = this.getCmsContent("DamageCauseQuestion", "Answers");
const damageCauseAnswersObj ={};
const damageCauseAnswersObj = {};
if(damageCauseAnswers)
{
for (let answer of Object.values(damageCauseAnswers)) {
@ -343,24 +342,22 @@ export default {
}
return damageCauseAnswersObj;
},
DamageGlassOnlyOptions()
{
DamageGlassOnlyOptions() {
return this.getCmsContent("GlassOnlyQuestion", "Answers");
},
DamageGlassOnlyQuestion()
{
DamageGlassOnlyQuestion() {
return this.getCmsContent("GlassOnlyQuestion", "QuestionText");
},
displayDamageCityQuestion(){
displayDamageCityQuestion() {
return !!this.getCmsContent("DamageCityQuestion","QuestionText");
},
displayDamageStateQuestion(){
displayDamageStateQuestion() {
return !!this.getCmsContent("DamageStateQuestion","QuestionText");
},
displayGlassOnlyQuestion(){
displayGlassOnlyQuestion() {
return !!this.getCmsContent("GlassOnlyQuestion","QuestionText");
},
displayPolicyZip(){
displayPolicyZip() {
if (this.mainStore.issConfig.isAuthenticated &&
!!this.mainStore.issConfig.disabledFields.policyZipCode) {
return false;
@ -372,11 +369,10 @@ export default {
getStates() {
return states;
},
isPolicyHolderEnabled()
{
isPolicyHolderEnabled() {
return !!this.mainStore.issConfig.disabledFields.policyNumber;
},
isCoverageEnabled(){
isCoverageEnabled() {
return this.mainStore.issConfig.isCoverageEnabled;
},
},