How to evaluate a dynamic number of ion-checkboxes


#1

Dear community,

I have a dynamic list of Strings I iterate with ng-repeat and every String in this list gets a ion-checkbox:
`<ng-repeat=“animal in user.animals”>
{{animal.name}}

` After the list with names an checkboxes I have a button who should handle 2 things: 1. Save the user input (save if a checkbox is clicked or not) 2. If a Checkbox is not clicked do method A or if a checkbox is clicked do Method B

How can I save the user input? Is the local storage the best way?
And how can I pass through the changes of my dynamic list to my Controller? How can I iterate over my checkboxes?

Sorry, a lot of questions. I hope that maybe someone can help.

kind regards