0

Using the Sencha Architect, I am facing the following problem in Sencha Touch 2: I can define models, read them from a JSONp proxy, no problem, but how can I define a model which itself contains an array of another model?

The data is loaded fine, but the array of "sub"models is just a plain JS object, I cannot use any getters for instance. There is no link with the Ext Model definition...

Thanks for the help

1 Answer 1

1

First of all, make sure to define the relations between models using associations. Define getters and setters on the associations where needed. Then, load the data using a store which is referring to you top-level model. Call the getters of associated data on the store once loaded.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.