I have an access database which has one form, asset_information in the source of which some fields are restricted to values in another table ([brand name] and [model name]).
I am trying to write a 'popup' or 'modal' form for the asset information form which will allow users to open a search form for the model or brand, search existing ones and then either select the model or brand or create a new one.
Example:
An user clicks here on the first form,
After that, this form pops up - user searches and clicks in one of the results then clicks 'select model'
That returns the model_id selected by the user from the popup form to the original form.
Googling has not helped much, can anyone point me in the right direction? Should I be using the openargs on the second form, or the first and second form? Or should I be using something else entirely?
Related
I need to use Orbeon Forms to create a form to capture the price from a number of things. I create a form, connect it with database (MySQL), deploy the form, complete the form, and it saves the data correctly in database.
Then my question is: if I complete form_1 and save the data in the database, and later enter to the empty form_1:
Is it possible to load the data entered previously or from the last form completion for form_1?
Is it necessary to have button or any control to take an action?
When you load a page to fill a new form, notice how the URL ends with /new. When you are on that page, and save, notice how the URL changes to /edit/123 (where 123 is a long unique identifier). You can come back to edit the data by loading again this URL.
In practice, this is often done by going to the /summary page for the form, and clicking on the relevant form data you want to edit.
I have a long form that an user has to fill. After the user has clicked submit, I have to show a page with the information the user has filled in the form so that he can check that everything is correct before doing any further processing (i.e., he has to press another submit button or a back button if he detects an error).
Is there an easy way to do this? Is there a better way than creating a new form with hidden values equal to the values submitted in the previous form?
Would it be okay if I just store the information in a session variable and then process it if the user confirms?
You could skin that cat many ways, here's a couple of ideas:
Add a non-mapped confirm input (like a checkbox) to your form. On initial form render with no POST, hide the input. When you get a POST, show the checkbox input & some additional information (please review your data & check to confirm all is OK etc). Don't validate the form or save your data until the confirm input has been checked. You don't need to mess about with hidden fields, the one form will do the job for you.
Save the entity and give it a property e.g. isApproved, that way you can show the data easily & if the user needs to edit, re-use your form. When the user approves the information set isApproved to true. Don't perform any actions on any entities that have isApproved == false. Cons are you then have to manage an isApproved state for an entity.
I have started using Lemoon CMS for a new site, everything is working great with one exception.... Forms. Each time I try to create a New Form i am given the option to Select a Form Template.... however this dropdown is not populated with anything. There is a FormTemplate.aspx file which looks intact, and when I try to view my new page/form I get the message Form "" not found.
Any ideas?!
In order to use forms you need to first create/design a form. You do this under the manage/content types section (/admin/manage/content/default.aspx). There you need to click the "Design form template" link. You can now create your form. Once it is saved you need to create a page in your site that will hold the form. Select your newly created form in the "Select form" dropdown and click Publish.
I work in Yii framework.
There is already done a form to edit person data.
Now we enter data for a contract about a pupil. Entering data about a pupil, we need among other to enter a list of his kins (parents and siblings).
The boss wants to add new items to <select> for a list of persons in the contract form without page reloading (in AJAX). That is he wants just to click "Add" button in the contract form and this button would open a form to enter data about a person (a kin of our pupil).
The question is how to implement it in a good (that is object oriented) way? There are already active forms to enter information about persons. What is the right way to "plug" a callback which updates the <select> in the contract form when we create a new person? Should this callback be called only if we open through the above mentioned "Add" button, or should it scan all open HTML windows and modify all "contract" pages (even if there is opened several contract pages)?
I make a shot to show up how it should work
Using CakePHP I have a page where I have multiple forms. Each form updates a single field on a record. I'm trying to implement a way to submit all the forms through a single "Submit All" button. However, all my solutions so far have been lest than successful.
My first attempt was to create a separate action called editAll in the controller that took an array, but I cannot figure out how to send the data from all the forms to that action without having a hidden form that saves all that data. The second idea was to create some kind of Javascript function that iterated over all the forms to create an array to be sent to the controller's editAll action.
The first implementation did not work, and I couldn't find a reasonable way to implement the second idea.
Basically, I was hoping someone could point me in the direction to submitting multiple forms (or at least the data from multiple forms) at once from a single page.
I assume you don't ALWAYS want to submit them all - if you do, then just make one form. If you're hoping to be able to submit some of them individually, but also be able to submit them all, then you could do something along the lines of this:
Keep all the fields in one form. For each field have a 'submitted' value (1 or 0). If they click the Submit next to an individual field, turn all of the submitted values to 0 except that one, then submit the form.
If they click Submit All, then turn them all to '1' and submit the form.
Then, when you process the data, just strip anything that doesn't have 'submitted' value of 1.
It would still take some work, and you're submitting more data than is necessary, but.... it's an idea.