Validation of custom fields

Functionality discussions and feature requests

Moderators: hugo, alexandre, rmvanarkel

Post Reply
cycloshost
Posts: 578
Joined: Mon Jan 30, 2012 8:12 am
Contact:

Validation of custom fields

Post by cycloshost »

Hi,

in the payment page of one of our transaction types we need two extra custom fields with the type Decimal number: salary and hours.

We need to perform a validation that ensures that the amount of the transfer is equal to salary multiplied by hours. We saw in the wiki that this is possible using a java class:
http://project.cyclos.org/wiki/index.ph ... tom_fields

Can someone show us an example to start with or recommend us a tutorial on building a class like this? Is it possible to perform tis calculation? The field amount is already in cyclos and the two other fields, namely salary and hours would be custom.

Do we need to insert the validation class in both custom fields?

Can we link the pair of custom fields to other transactions?

Thanks!
cycloshost.com
Cyclos administration and hosting
Post Reply