I was wondering if it is possible to write a custom editor (StandardEditorProps) that displays multiple input fields dynamically for every query (every series in the dataFrame).
I would need the same form (labels, bunch of select and text input fields) repeated for every query (I need to get the field names of the query resultset).
These values will be then used to render the custom panel plugin.
If I return, in StandardEditorProps, the entire form, then onChange every select input field is updated with the same value and I cant get the value of every input field in the custom panel plugin as only one customEditor is added in the module.tsx.
On the other hand, If I define multiple custom (and others non custom) editors in module.tsx I can get the values in the panel plugin but I cant make N such forms dynamically.
Hope that makes sense.
Does anyone have any suggestions or ideas how achieve that?
Related
I have to create a table with different type of fields like text box , drop-down , toggle button etc.
For eg below fields for 20 rows
Name - textbox
Gender - dropdown
I was thinking of creating a redux form and embed it into a table and repeat it for each rows. Also want to bind data per row.
But not sure how to progress with it. Please help and suggest any other way. Due to certain restriction I could not use available components..so I have to create my own component
I want to make react-select accept values which are not stored in the options array. I'm hoping to use this component to suggest values but also allow users to input their own value and persist it on blur.
In my situation the options represent suggestions which have been defined in the DB, on choosing an option it will auto-populate some other relevant fields.
However I also want to allow the user to define a unique value in the and manually define the other values.
I don't want to feed the unique value in the options array because I do not want the user to see this as a selectable option.
Is this possible with react-select?
If I understand your question correctly, you can totally control what's shown to the user as part of the selectable options, and also you have a dedicated class Select-create-option-placeholder attached to labels of new labels that need to be created (namely aren't part of the array of suggestions).
Based on the "Add-more button (with graceful degradation)" example available in Drupal examples module I have created a form that can add fields dynamically using AJAX, and now i want to add a separate Remove button to each of those fields so that i can remove individual fields (not just the last field).
Decrementing the number of fields and rebuilding the form only removes the last field in the form.
What's the Drupal way of doing this? and what would be the best approach to achieve my requirement?
So each field gets a remove button next to it? In that case, the button simply needs to target the wrapper for that field (surround the field in an easily identifiable div, and set the ajax target for the button to the same). Hint: the button should also be contained within that wrapper so it also disappears when clicked.
I have to implement a wizard, where each step is a single input field.
Everything is wrapped inside an accordion with section headers.
The user, after filling the input and pressing Enter, should navigate the wizard field by field. Only the current field is editable, while the other ones are readonly (the user can anytime change a previously filled input, by clicking it, moving the current pointer to it).
I was wondering what could be the best approach to design this system, considering that the whole wizard structure changes in dependence of different user inputs.
I have found a tutorial using ui-router (http://scotch.io/tutorials/javascript/angularjs-multi-step-form-using-ui-router), with a fixed number of steps, but my requirements are to show the current input edit box inside the accordion, not in a fixed "ui-views" placeholder.
Take a look at https://github.com/JustMaier/angular-autoFields-bootstrap
It's a module that allows you to render forms from Metadata. So essentially, you can change the Metadata you provide dynamically to change the forms.
I have a picklist with three values and a text area that has three values as well, but I would like to correlate one value from the picklist with one value of the text area. Any thoughts as on how I can do this?
If creating a visualforce page is an option, you can do this with a controller extension, or a custom controller. For example, you could override the save() method and have your new save code populate the text for you-- simply create a map of dropdown values to text area content and set the text as desired. It should also be possible to do this without saving by using some of the visualforce built in AJAX hooks: look at the onchange attribute. (Note that last I checked the onchange did not fire properly for lookups, but it may work for dropdowns)
Have a look at the visualforce documentation here: http://www.salesforce.com/us/developer/docs/pages/index.htm