-
MoniteurescaladeDemandé le 8 décembre 2024 à 12:44
Bonjour, dans mon formulaire d'inscription à une activité du club, j'ai intégré un élément demandant au client de mentionner la valeur de son chèque-cadeau. Je souhaiterais toutefois que le montant ne soit pas supérieur au prix de cette activité. Comment puis-je faire sachant que le prix de l'activité est intégré via un fichier excell fourni à jotform ? En effet, le montant total est ensuite calculé sous cette forme : prix de base - réduction étudiant - valeur du chèque-cadeau
J'ai pensé à ajouter une condition tenant compte du montant total mais je n'y suis pas parvenue.
-
Silvano Jotform SupportRépondu le 8 décembre 2024 à 13:20
Hi Moniteurescalade,
Thanks for reaching out to Jotform Support. Our French Support agents are busy helping other Jotform users right now, so I'll try to help you in English using Google Translate, but you can reply in whichever language you feel comfortable using. Or, if you'd rather have support in French, let us know and we can have them do that. But, it might take a while until they're available again.
Now, coming back to your question, if you can change the Base Price, Student Discount and Value of the Gift Voucher short text field to a Number field, this will be possible as Number Field supports Greater Than, Equal To and Lesser Than conditions. By then, you can hide the other fields once the Gift Voucher amount is greater than the Base Price field and show an error message using a Paragraph field. If this works with you, let us know so we can provide you a sample setup.
Once we hear back from you, we'll be able to help you with this.
-
MoniteurescaladeRépondu le 8 décembre 2024 à 13:40
Merci pour votre réponse. Les éléments prix de base et réduction sont intégrées automatiquement via une logique du fichier excell. C'est la raison pour laquelle ils ne sont pas en champ numérique. Est-ce possible de les modifier sans tout perturber ? J'ai ensuite plusieurs éléments de paiement qui dépendent de ces champs.
Le champ valeur du chèque-cadeau ne peut quant à lui être défini en avance et est encodé par la personne remplissant le formulaire. Ce champ ne s'affiche que si la personne a répondu "oui" à la question précédente, à savoir "avez-vous reçu un bon-cadeau".
Ensuite, le champ suivant "montant total" calcule le montant total à payer : prix de base - participation volontaire éventuelle (pour certaines activités seulement) - réduction étudiant - chèque cadeau
-
Kris Ann Jotform SupportRépondu le 8 décembre 2024 à 16:02
Hi Moniteurescalade,
I’ll need a bit of time to look into this. I’ll get back to you as soon as I can.
Thanks for your patience, we appreciate it.
-
Myla Jotform SupportRépondu le 9 décembre 2024 à 04:56
Hi Moniteurescalade,
My colleague Kris Ann is working on your concern. She'll get back to you as soon as she has a solution for this.
We really appreciate your patience and understanding while we look into this.
-
Kris Ann Jotform SupportRépondu le 9 décembre 2024 à 22:36
Hi Moniteurescalade,
I want to let you know that I am still working out a solution to meet your requirements. I’ll get back to you as soon as I can.
-
Kris Ann Jotform SupportRépondu le 10 décembre 2024 à 19:08
Hi Moniteurescalade,
To meet your requirements, You can add a Form Calculation widget on the form that will calculate the price, even when the value is under 0. And set a conditional logic using Update/Calculate Field element that if it's more than 0, it copies the value to the price Calculation Widget. But like my colleague Silvano suggested, you will need to change the Short Text fields to Number Fields. Check out my Demo Form to see if it works for you. Let me show you how to set that up:
1. In Form Builder, click on the Add Element button and select Number element and use it for the Base Price, Voluntary Participation, Student Reduction and Gift Voucher fields.
3. For the first Form Calculation widget that calculates the Base Price - Voluntary - Student - Voucher, click on the Wand Icon and set this recommended calculation:
4. For the Final Price Form Calculation widget, just leave it blank.
5. Click on the Settings Tab at the top, then go to the Conditions Tab on the left side panel.
6. Select Update/Calculate Field from the options.
7. Set the recommended condition below:
If that’s not exactly what you’re looking for, can you explain a bit more so I can help you better?
Give it a try and let us know if you need any other help.
-
MoniteurescaladeRépondu le 21 décembre 2024 à 10:15
Bonjour,
je vous remercie pour votre réponse très claire.
Toutefois, je pense que j'ai un problème mais je ne trouve pas lequel. En effet, dans la case calcul (et donc total), c'est la formule qui apparait, et non le résultat.
Pouvez-vous m'aider svp ? Merci
-
Frédéric Jotform SupportRépondu le 21 décembre 2024 à 10:38
Bonjour Moniteurescalade,
En effet, ceci provient du fait que, dans le widget Calculatrice de formulaire pour le champ Calcul du prix (maqué), le symbole '-' pour la soustraction n'est pas compris comme un e opération mathématique, mais comment un caractère quelconque, ce qui est indiqué par le fond gris. Pour que ce symbole soit interprété comme une opération mathématique, il doit apparaitre sur un fond noir, en cliquant simplement dessus, comme ci-dessous:
La légende située sous le pad numérique vous indique le code couleur associé aux modes d'interprétation des caractères, selon le type de calcul que l'on veut effectuer, mathématique ou manipulation de chaînes de caractères. Vous pouvez aussi consulter ce guide, Comment effectuer des calculs dans votre formulaire à l'aide d'un widget.
Faites un essai et dites-nous comment ça se passe.
-
MoniteurescaladeRépondu le 21 décembre 2024 à 11:17
Parfait merci. Bon weekend