Repeated HTTP patch requests, depending on checkboxes

I built a database (Airtable) for our sports club with keys like “name”, “birthday”, “last-present”, etc.
In the Appgyver UI I use a repeated container with items and all of them works fine.

In that container is also an icon wich acts like a checkbox, to mark each person as present that day and I could send a HTTP patch request to the DB to change the “last-present” value to the actual date.

The problem here is, if I checkmark the wrong person, the request is send immediately and there is no way to go back to the old date in the DB.
So my idea is to create a button, which sends all these requests when pressed, so the user can check/uncheck each person until all are correct.

The question now is, how to run through all of these entries in the UI, looking for the checked icons and sending the patch requests for them to the DB.
How can the logic element “HTTP request” be combined with a “repeat” function to go through all elements?

thanks in advance

Thats tricky,but try adding a textfield in your container and hide It. Now set the logic like Ths…

Remember that the checkbox returns true or false…
Now… On component tap(checkbox) ,if the checkbox is true(checked), set hidden textfield content as the old date, then update dB with new date. If the checkbox is false(unchecked ) , then update BD with date from the the hidden textfield.

The hidden textfield will only update on componenttap and the checkbox returns true, and It will be updated with the old date only…
However :joy:
If you update your fields and close the page, you won’t get the old days back…I’ve never done it before, but I hope it works

The other thing you Can in your dB, have you your last present field, store a collection of present days and save each created records with the current date as custom keys and store a date in Ths records . Now If a record with the current dates as key does not exist create new, if the record with the current date as key exists delete it. Now in app gyver, display the last record insert

Using a hidden text field as a local variable… nice
So I can set the content of that text field with the “set component property” logic element, but how can I read it out again? There is no get element for that.

When I try to look for that content with a dialog element, I can bind the dialog message with another components property, I can see that hidden text field, but I’m not able to use the content (shown unavailable).

With a formula, I can use “self.value”, but how can I access the content or value of a different component?

I have not done it before ,but let me try, I’ll tell you If manage to get something

change the text field to input field, you’ll be able to use input field value