cyberwombat
28 Nov 2011, 8:16 AM
My app is basically a viewer for live data from the server in json format. I have some forms that allow me to update the server and all the data needs to be current and dynamic. There is no offline storage of data however I may need to retain the data between card switch (so that it doesn't load new data on every card switch - perhaps on initial one and then with a refresh button - still figuring out how to keep data fresh without polling)
My question is.. I see that I can use stores without models (as per twitter example in dataview docs). So what would be the benefit of using models? I plan on submitting my forms straight to sever for validation so I don't really have a need to use local validation.
Also - it seems that belongsTo associations do not work and frankly I don't think the association concept in ST will be useful for my needs so I am questioning using stores instead of just pulling json data into a list. What would be the pros and cons? It seems easy enough to load json data into a template - would I have issues with list views and disclosures?
As far as my views on associations - I'd also like to hear your inputs. Let's say that I pull messages with related user data - but I only pull some of the user data (i.e ID, name). Since it's broken I don't know what normally happens but would the user data be theoretically stored in the user store? And since its incomplete (id and name only) - what happens when I request that user? will I get an error when I want to print out their email for example since it's not been pulled? And if the store pulls a refreshed user from live sever then what is the point of the association in the first place?
Get my drift? :) I'd love some thoughts towards the matter
Thanks
My question is.. I see that I can use stores without models (as per twitter example in dataview docs). So what would be the benefit of using models? I plan on submitting my forms straight to sever for validation so I don't really have a need to use local validation.
Also - it seems that belongsTo associations do not work and frankly I don't think the association concept in ST will be useful for my needs so I am questioning using stores instead of just pulling json data into a list. What would be the pros and cons? It seems easy enough to load json data into a template - would I have issues with list views and disclosures?
As far as my views on associations - I'd also like to hear your inputs. Let's say that I pull messages with related user data - but I only pull some of the user data (i.e ID, name). Since it's broken I don't know what normally happens but would the user data be theoretically stored in the user store? And since its incomplete (id and name only) - what happens when I request that user? will I get an error when I want to print out their email for example since it's not been pulled? And if the store pulls a refreshed user from live sever then what is the point of the association in the first place?
Get my drift? :) I'd love some thoughts towards the matter
Thanks