Hello,
I have dynamic enum in my form :
enumValues: async context => {
const currentStatus = await context.getRecord(['santanderLoanRequestStatusCode']);
switch (currentStatus.santanderLoanRequestStatusCode) {
case 'PREVALIDATING':
return ['PREVALIDATED', 'PREVALIDATION_REJECTED'];
case 'LOAN_CONTRACT_SIGNING':
return ['LOAN_CONTRACT_SIGNED', 'LOAN_CONTRACT_SIGNATURE_FAILED'];
case 'PLEDGE_VALIDATING':
return ['PLEDGE_VALIDATED', 'PLEDGE_VALIDATION_REJECTED'];
case 'PLEDGE_VALIDATED':
return ['FUND_RELEASED'];
}
}
Is there any way to associate a display value that is different than the predefined code ?
I have the same question for form fields :
I have this :
{
label: 'numero Dossier',
type: 'String',
isRequired: true,
if: context => context.formValues.Status === 'PREVALIDATED'
},
but if I want to retrieve the value, I need to use the label instead of a code :
context.formValues['numero Dossier'];
Thanks for your help.
David