formatting
This commit is contained in:
parent
05c7e247a7
commit
c49217aee6
1 changed files with 17 additions and 21 deletions
|
|
@ -293,25 +293,24 @@ export default {
|
||||||
async getVehiclesfromPolicyLookup()
|
async getVehiclesfromPolicyLookup()
|
||||||
{
|
{
|
||||||
//call coverage policy lookup if isCoverageEnabled flag enabled
|
//call coverage policy lookup if isCoverageEnabled flag enabled
|
||||||
if(this.isCoverageEnabled){
|
if (this.isCoverageEnabled){
|
||||||
const policyLookupResponse = await this.getPolicyLookupResponse();
|
const policyLookupResponse = await this.getPolicyLookupResponse();
|
||||||
if(policyLookupResponse!=null){
|
if (policyLookupResponse !== null){
|
||||||
var policy = policyLookupResponse.policies?.[0];
|
var policy = policyLookupResponse.policies?.[0];
|
||||||
if(policy!=null){
|
if (policy !== null){
|
||||||
//populate policy holder details from policy lookup
|
//populate policy holder details from policy lookup
|
||||||
this.mainStore.order.customer.address.streetAddress = policy.insureds?.[0]?.address;
|
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.city = policy.insureds?.[0]?.city;
|
||||||
this.mainStore.order.customer.address.state=policy.insureds?.[0]?.state;
|
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.zipCode = policy.insureds?.[0]?.zipCode;
|
||||||
this.mainStore.order.customer.firstName = policy.insureds?.[0]?.firstName;
|
this.mainStore.order.customer.firstName = policy.insureds?.[0]?.firstName;
|
||||||
this.mainStore.order.customer.lastName = policy.insureds?.[0]?.lastName;
|
this.mainStore.order.customer.lastName = policy.insureds?.[0]?.lastName;
|
||||||
|
|
||||||
//populate vehicles
|
//populate vehicles
|
||||||
this.vehiclesFound= policy.vehicles;
|
this.vehiclesFound = policy.vehicles;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
getWelcomePageModelFromStore() {
|
getWelcomePageModelFromStore() {
|
||||||
|
|
@ -332,7 +331,7 @@ export default {
|
||||||
computed:{
|
computed:{
|
||||||
DamageCauseOptions() {
|
DamageCauseOptions() {
|
||||||
const damageCauseAnswers = this.getCmsContent("DamageCauseQuestion", "Answers");
|
const damageCauseAnswers = this.getCmsContent("DamageCauseQuestion", "Answers");
|
||||||
const damageCauseAnswersObj ={};
|
const damageCauseAnswersObj = {};
|
||||||
if(damageCauseAnswers)
|
if(damageCauseAnswers)
|
||||||
{
|
{
|
||||||
for (let answer of Object.values(damageCauseAnswers)) {
|
for (let answer of Object.values(damageCauseAnswers)) {
|
||||||
|
|
@ -343,24 +342,22 @@ export default {
|
||||||
}
|
}
|
||||||
return damageCauseAnswersObj;
|
return damageCauseAnswersObj;
|
||||||
},
|
},
|
||||||
DamageGlassOnlyOptions()
|
DamageGlassOnlyOptions() {
|
||||||
{
|
|
||||||
return this.getCmsContent("GlassOnlyQuestion", "Answers");
|
return this.getCmsContent("GlassOnlyQuestion", "Answers");
|
||||||
},
|
},
|
||||||
DamageGlassOnlyQuestion()
|
DamageGlassOnlyQuestion() {
|
||||||
{
|
|
||||||
return this.getCmsContent("GlassOnlyQuestion", "QuestionText");
|
return this.getCmsContent("GlassOnlyQuestion", "QuestionText");
|
||||||
},
|
},
|
||||||
displayDamageCityQuestion(){
|
displayDamageCityQuestion() {
|
||||||
return !!this.getCmsContent("DamageCityQuestion","QuestionText");
|
return !!this.getCmsContent("DamageCityQuestion","QuestionText");
|
||||||
},
|
},
|
||||||
displayDamageStateQuestion(){
|
displayDamageStateQuestion() {
|
||||||
return !!this.getCmsContent("DamageStateQuestion","QuestionText");
|
return !!this.getCmsContent("DamageStateQuestion","QuestionText");
|
||||||
},
|
},
|
||||||
displayGlassOnlyQuestion(){
|
displayGlassOnlyQuestion() {
|
||||||
return !!this.getCmsContent("GlassOnlyQuestion","QuestionText");
|
return !!this.getCmsContent("GlassOnlyQuestion","QuestionText");
|
||||||
},
|
},
|
||||||
displayPolicyZip(){
|
displayPolicyZip() {
|
||||||
if (this.mainStore.issConfig.isAuthenticated &&
|
if (this.mainStore.issConfig.isAuthenticated &&
|
||||||
!!this.mainStore.issConfig.disabledFields.policyZipCode) {
|
!!this.mainStore.issConfig.disabledFields.policyZipCode) {
|
||||||
return false;
|
return false;
|
||||||
|
|
@ -372,11 +369,10 @@ export default {
|
||||||
getStates() {
|
getStates() {
|
||||||
return states;
|
return states;
|
||||||
},
|
},
|
||||||
isPolicyHolderEnabled()
|
isPolicyHolderEnabled() {
|
||||||
{
|
|
||||||
return !!this.mainStore.issConfig.disabledFields.policyNumber;
|
return !!this.mainStore.issConfig.disabledFields.policyNumber;
|
||||||
},
|
},
|
||||||
isCoverageEnabled(){
|
isCoverageEnabled() {
|
||||||
return this.mainStore.issConfig.isCoverageEnabled;
|
return this.mainStore.issConfig.isCoverageEnabled;
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue