View Full Version : localstorage with hasMany, load & remove problem

2 May 2011, 7:12 PM
Hi guys, I'm new to this framework but trying to deal with some localstrage task.

Basically, I have a user and product model and each user would 'hasMany' products, all defined in the models. The adding part is ok when I call user.products().add(id: 1, name: 'a product') but when refreshing the browser and try to load the added storage through user.products().load() the user.products()'s data length is always 0. think is the same cause for not able to remove storage with user.products().remove(user.products().getAt(0))

Any ideas? I've been stuck in this for a while, so thx a lot in advance.