Reiterating what Sander is saying, you are referencing one object initially 
in both arrays, but after parsing, you have two separate objects.  You'll 
need to manage this either upon saving or retrieving (or both) to get the 
intended results.

On Monday, February 24, 2014 1:52:22 PM UTC-7, Martin Doktár wrote:
>
> Hi.
>
> I'm trying out angular for the first time and want to accomplish the 
> following:
>
> 1. Multiple todo lists
> 2. Each todo can belong to one or more lists
> 3. Updating a todo belonging to more than one lists, updates the todo in 
> all lists.
> 4. Store and load the lists/todos
>
> I'm trying out different solutions on how to handle multiple lists/todos, 
> but are running into some problems with storing and fetching the todos 
> without loosing each todos singularity. 
>
> For example:
> 1. http://plnkr.co/edit/etSJMWXhwwRoY4jCozP9?p=preview
> 2. Click "Add task to all lists" one or more times
> 3. Edit newly created task/todo and notice both lists updating
> 4. Click Save
> 5. Reload page and try to edit same tasks. Only one list is updated.
>
> I think I understand why this happens, I just don't know enough about 
> angularjs to fix it. I wan't the same behaviour before and after clicking 
> save and reloading.
>
> Any help is much appreciated!
>
> Regards,
> Martin
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to