header and lines on one webform

header and lines on one webform

I've been tasked with evaluating the feasibility of writing an invoice package in Agile. For this I need to create an input for to allow the user to enter header details and a set of lines, but write the records away at the same time.
I was initially thinking of a header section in an Edit Record widget followed by an editable grid of lines on one form but i cant find any method of creating an editable grid widget.
Second plan was to create a header section in an Edit Record widget followed by a list record widget linking to a list variable with a button to show a create webform that writes back to the list variable on teh parent webform, but i cant see how to link the child form back to the parent's variable.
Can anybody advise on a best practice for this type of input within Agile?
many thanks
Hi Ryan, and welcome to the OutSystems community forums.

I would think that you're thinking too much about the details of the solution, and less on the higher scope. :)

If I got your questions correctly, I think you could easily do that with a Table Records - where each line represents an invoice line - but replacing the expressions with Input widgets (either across the board, or just on the last line).

In the preparation you could retrieve the invoice items, and add an empty item at the last line, which would be used to input the new lines on the invoice.

You could have a button at the end of the line, that would store that record, reload the list with a new empty record at the end, and refresh the Table Records on the screen, using AJAX.

An alternative would be for you to have a Table Records widget displaying all records, and have a popup where you enter the data for the table - and have a "Create", a "Create and New" and a "Cancel" button there, to speed up data insertion (Create and New basically would store, and keep the popup open with empty data).

These are just two solutions which I hope will help.

In your question about the child form/parent variable, you may either store the variable in an action on the child form, and reload it in the parent form - that's the most common way, I think.

One strong recommendation I will have for you is to go through our free online training section by clicking the Academy link on top, and also to go through the How Tos in our website, to help you along the way. If you do them all, I'm sure you'll have a better grasp of the concepts and how things work.

I hope this helps!

Regards, and let us know how it goes.

Paulo Tavares