Retain form values on save - extjs

I have a basic form with URL and Title fields. I want to retain the form values when the form is closed so on reopening of form the saved values gets updated to the fields. I know I can store these values in database and retrieve them, but is there any other way to do it?

Related

How do we set the entire form data as a hidden input field value in reactJS (using react-json-schema-forms, react-admin)

We are using JSON Schema to Form library to embed a form inside a reactJS page.
We want to set the form (generated from JSON schema) data into a input hidden value to be used later on to pass to a service to save the form value in the database.
e.g.
See the formData highlighted in the image below attached. this needs to be set as a value to passed to save in the database column
enter image description here

Reinitialize redux form state from saved state

I am creating a dynamic form where users can add fields and then later someone else can add data to them.
i have successfully saved the whole form state into a database,
now i need to load the whole state into the form
i am not trying to load the initial values from the state. the from does not have any fields etc. i am trying to load all those from the database
but i am unable to figure out how.
can any one help me

Coldfusion 9 - Checkbox values from form to replace parameter value/s

Very new to coldfusion. So I have a a form outputs values from DB into checkboxes.
<cfoutput query="Offices">
<label><input type="checkbox" value="#offices#" name="Offices">#offices#</label>
</cfoutput>
and when a user selects more than one checkbox it passes multiple parameters into URL which looks like this:
offices.cfm?Offices=A&Offices=B&Offices=C
I am trying to prevent multiple of the same parameters being passed so I want it to return like:
offices.cfm?Offices=A,B,C&...
I am really struggling to figure this out. Help is appreciated.
(Summary from comments, just to close out this thread ...)
True, but that is just how the parameters are transmitted in the url. Per the html specs, when using method GET, the browser builds a builds a big string of name/value pairs for all (successful) form fields. Then appends them to the url as the query string:
Submit the encoded form data set
If the method is "get" and the action is an HTTP URI, the user agent takes the value of action, appends a ? to it,
then appends the form data set, encoded using the "application/x-www-form-urlencoded" content type.
form data set
A form data set is a sequence of control-name/current-value pairs constructed from successful controls
However, it does not matter that the field name appears multiple times in the URL. If you dump the #URL# scope, you will see that CF has already parsed those values into a single CSV list for you. That list can be accessed using the variable name URL.Offices.

asp mvc, best solution to store user input data before it will be saved to database

for example i've got a form with some input fields(every form and it's inputs with validation rules are stored in database).
Every input got it's own OnChange() which posts json (i.e. new value, input element name, ...) to controller for validation, if validation passes the new value must be saved somewhere until user clicks submit button, which will save all data to database table.
And here i'd like to ask, what this special place between ui and database can be ?
p.s.
also if user closes browser/form the next time he'll come back i need to ask him if he would like to start from an empty form or fill form with values he previously entered there.
Thank You !
Cookies or intermediary database table would work for this case.
for an intermediary database like that, you could use something like MongoDB, it is really easy to get it started, you just work with the classes you have, don't need to setup any schema, you just save the objects
http://www.mongodb.org/display/DOCS/CSharp+Driver+Tutorial
If you are submitting the entire form at the end, why can't you just store the values at that time? Is this a multi-page form(s)? Why not allow the database records to be partially filled? You could always add a bit column to mark the record as complete or incomplete. This would be much simpler than duplicating your table structure.

Is it possible in Quickbase to create a URL to an Add Record page which partially fills in fields on the form?

I have a Quickbase app with a form for adding records. On an intranet page, I have a link to the add record form. When a user clicks on that link, Quickbase opens the add record form. However, I would like to supply values for some of the fields on the form as parameters in the URL.
I am aware of API_AddRecord, but as I understand it, that can only be used for completely filling in all required fields and saving the record. The disprec parameter can be used to see the record, but doesn't keep the record in add mode without committing the record.
What I need to do, is to fill in a couple of the fields, but keep the record in add mode, allowing the user to fill in a couple more fields. The URLs on the intranet page are actually generated in a grid, so there are some fields that are already known then the user clicks on the link, and I don't want the user to have to type them in again.
Can this be done? Thanks for your input.
Sure. Folks do this all the time. Use a=API_GenAddRecordForm&_fid_1="foo"&_fid_2="bar" where the number are the Field IDs of the fields you want to fill out, and "foo" and "bar" are the values you want to fill in.

Resources