SSR-488 disable policyzip and lossdate on welcome page
This commit is contained in:
parent
93e502ada8
commit
68a97846be
3 changed files with 11 additions and 1 deletions
|
|
@ -165,6 +165,7 @@ export default {
|
|||
case 'lossdate':
|
||||
// NOTE: May need some date parsing logic in here depending on client.
|
||||
this.mainStore.order.policy.dateOfLoss = value;
|
||||
this.mainStore.issConfig.disabledFields.dateOfLoss = true;
|
||||
break;
|
||||
|
||||
case 'successreturnurl':
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@
|
|||
inputId="policyZipCode"
|
||||
cmsWidgetName="PolicyZipQuestion"
|
||||
isRequired
|
||||
:isDisabled="isPolicyZipEnabled"
|
||||
:validationRules="rules.policyZip" />
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -46,6 +47,7 @@
|
|||
cmsWidgetName="DateOfLossQuestion"
|
||||
inputId="dateOfLossField"
|
||||
isRequired
|
||||
:isDisabled="isDateOfLossEnabled"
|
||||
disableAutoFill
|
||||
:max="new Date().toJSON().slice(0, 10)"
|
||||
:min="'1972-12-01'"
|
||||
|
|
@ -306,6 +308,12 @@ export default {
|
|||
isPolicyHolderEnabled() {
|
||||
return !!this.mainStore.issConfig.disabledFields.policyNumber;
|
||||
},
|
||||
isPolicyZipEnabled() {
|
||||
return !!this.mainStore.issConfig.disabledFields.policyZipCode;
|
||||
},
|
||||
isDateOfLossEnabled() {
|
||||
return !!this.mainStore.issConfig.disabledFields.dateOfLoss;
|
||||
},
|
||||
isCoverageEnabled() {
|
||||
return this.mainStore.issConfig.isCoverageEnabled;
|
||||
},
|
||||
|
|
|
|||
|
|
@ -202,7 +202,8 @@ const getDefaultState = () => ({
|
|||
failureReturnURL: null, // Client URL to return the user to when they encounter an error or bailout and are unable to complete the flow.
|
||||
disabledFields: { // Fields that are disabled and read only if sent over from a client.
|
||||
policyNumber: null,
|
||||
policyZipCode: null
|
||||
policyZipCode: null,
|
||||
dateOfLoss: null
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in a new issue