React - two issues on form creation

So I haven't fully tested this but seeing what looks like 2 "interesting" issues with "automatic" creation for forms in react.  For both of these the form was created by dragging a form onto the screen, then dragging an entity from the database tab to the form.

1) if you have items in your data table which are references to another data table.  It creates a get data for this other data table, but limits the number fetched to 50.  If you have over 50 items you did want to display, these will not show up on the dropdown, which leads the to second issue.

2) if you either had null in the ID on the data table item being edited OR if the selected ID was there, but because of item #1 above it is not in the dropdown, when you save, the item in your database will be saved with whatever the first value of the dropdown list is - no matter if you wanted it to be that or not.  The fix for this seems to be going to each of the fetches based on form dropdown items and bumping the max records up high enough to get all of your values AND you have to go to each dropdown on the form and fill something out for "prompt" so that the dropdown has a null item to be selected either by the end user or if the loaded database item has null there.

Rank: #2

Hi Jason,

Thanks for bringing this to attention. I'll see if I can get someone from OutSystems to take a look at it.

Rank: #20

Hi Jason,

Indeed that default can lead to those 2 issues. Please submit that through Service Studio, so it goes into the backlog. We probably should either increase it or make max. records optional. In the meantime a workaround is to create a client variable with maxint and replace all those with it. If you search by 50 in a module and sort the results by Element you might find all the places you might want to do that.

Regarding pagination you are right, pagination is only included by default when dragging entities. If you want to do that with existing aggregates or data actions you'll have to do it manually (and in data actions you'll need to pass startindex into it).

Tiago Simões

Rank: #68

Hi all,

I would also add that the detail screens created via scaffolding should have the MaxRecords set to 1, instead of the default 50, on the GetRecordById query to follow the good practices.