how to remove all yup validations for fields for one particular field select? - forms

i am using Formik with yup and I want to remove all fields validation when a particular value form particular field having dropdown is selected.
I cant be able to find any solution yet. Kindly help me about this

Related

How can you perform form validation at form level (not at field level)?

I know you can use a FormTextField to validate user input at the field level, but say you have First Name and Last Name as fields, and you would like to make sure that at least one of them is filled in.
How can you achieve that ?
Thanks.
I'll share what I did in this scenario. I use TextEditingController for these two fields. And after Form is validated I also check these two fields from controllers and if it matches to the condition then I submit values.If it does not, I show an alert dialog.

Adobe Acrobat form fields are all auto completing

In Acrobat preference I have auto complete turned off.
When I fill in one form field, all of the other form fields are filled in too with the same word?
So if I enter 'hello' into one field all the other form fields on the questionnaire get the value 'hello'.
I copied and pasted the form fields for each question to save time, surely that doesn't mean each form field in the questionnaire is just one form field, or does it?
How can I separate each form field so it can hold its own answer?
I found an answer to my question.
Fields with the same name will automatically get the same value, so each form field needs a different name.
If you create one form field, then right click on the form field in the menu on the right and choose 'place multiple fields', you can then input how many fields you want for the form along with other options. Acrobat then names each form field separately for you.

Symfony2 - Form with a checkbox column

I'm trying to build an HTML table with some data of an entity, and then, add a column with a checkbox for each row, in order to validate if the precious data is valid or not. After user checks or not each checkbox, I have to update the database table with this info.
As when I build the form I don't know exactly how many checkboxes I have, I pass to twing template an array of entities, and then I buid a new input type"checkbox" at last column for each row.
But when I submit my form (POST method), I'm not able to get this info. $request object doesn't have any of the checkboxes nor form reference. $request->request->all() is getting a null value. How can I get fields of a manual form build in a twig template?
Thanks
Now It's working. Thanks a lot ($request->request->all() is getting values now). It's a mistery...

Multiple values for one field

In GXT I want to create a form where a single field can have multiple values. so once one value is provided user should have option enter another value for the same field, similar to how we attach files in an e-mail.. what is the best way to do this?
One way to provide a button with plus symbol in the form. Clicking that button should add a field to the form dynamically. User can use that field to provide another value.
If you are talking about a single control, which can capture multiple values, can you try Multi-Select field like the one explained in this thread?

How to make a field "autocomplete"?

I can't figure out how to make a field autocomplete in ATK.
I guess it has something to do with the type "reference" but still not sure.
Suppose I'm looking for a client name in a "line" type field, then the autocomplete should list me all/topXX matching names.
Scenario 1:
Once I hit [Enter] I'd need all that row from DB loaded in a form fields so I can edit the record.
I guess this requires getting the client ID first then posting to an "edit" page then calling "loadData()" method for that ID and populate fields.
Scenario 2:
I'm assignig a job request to a client. First I find the client then I could store its ID in a hidden field to be posted then.
Any advice?
TIA
I would suggest you to go with 2 forms. First form with a single field, and when field is changed it automatically reloads second form including the parameter.
You will also need an autocomplete field. Autocomplete is somewhat buggy in 4.0, but it have been polished up in 4.1 by using a technique in http://jqueryui.com/demos/autocomplete/#combobox
For use with models and controllers and also dropdown, example is here:
http://codepad.agiletoolkit.org/reloadform
Alternative example:
http://demo.atk4.com/demo.html?t=22
Since 4.1, you can also use autocomplete fields instead of reference:
$form1->addField('autocomplete','user');