Re: Gift Card Number issue

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Re: Gift Card Number issue

Jacques Le Roux
Administrator
Hi All,

I had a deeper look at this.

I was ready to add a call to a new isFinAccountCode() method from UtilValidate.isGiftCard(). This method could have returned  true,
if
the "number" is a finAccountCode, the finAccountTypeId is GIFTCERT_ACCOUNT and the statusId is FNACT_ACTIVE.
But obviously this is not a place to make a call to the Entity Engine for a FinAccount Entity of the Accounting Application
component.
So I wonder if we should not better make this check in the validateSurveyResponseInline simple-method (in SurveyServices.xml) just
before
    <if-validate-method field-name="${answerFieldName}" method="isGiftCard">
to bypass this line if the code is of type FinAccount

WDYT ?

thanks

Jacques

PS : Do someone knows if the pin is tested somewhere (using finAccountPin for instance)? I did not search yet. It seems that its
presence only is tested (requiredField in SurveyServices.xml). Should we add a test ?

>Hi,
>
> I get something weird. In eCommerce, when I want to refill a previously created gift cart using the "number" sent (SLNX75HCT9WO) I
> get the message "The question [Gift Card Number:] requires a valid gift-card number." I had a look into the validation method
> called (isGiftCard) and I can see that the "'number" generated can't pass the validation. Anybody an idea about that, before I
> create a Jira issue and look for a solution ?
>
> If you want to test, you must apply the commit 606625 on trunk before.
>
> Thanks
>
> Jacques