View Full Version : Sencha Architect MVC with related models

17 Sep 2012, 8:05 AM
Is there any Sencha Architect and ExtJs4 project as an example that uses related models ? So that would be possible to use as a full reference for people new into the ExtJS 4 framework and Sencha Architect.

All I have found in examples is for Sencha Touch.


17 Sep 2012, 2:11 PM
Have you seen these examples:


18 Sep 2012, 1:09 AM
Hi Scott,

I appreciate your comments and support, and I already did last time you mentioned it in my recent post.

However, as I said, most of them are for Sencha Touch (I guess it works the same for ExtJs4 but still I don't want more confusion with ExtJS4 and Sencha Architect).

Moreover, there are no examples that uses related models with MVC in those examples, except for loanshark that is for Sencha Touch, and one or two more in best case (even the SimpleTask project seems not to have related models, but I did not checkout).

The only one I see is Book Review that is simple but works, unfortunately has no explanation of the code and doesn't use it with complex components.

Also, I can read the code of course, but do you consider a tutorial or documentation of anything (say Qt) putting the source code into an Apache with a title "Example" ?

I will use those examples, but I don't find them very useful to be honest, for someone that pretends to have a full understanding of the ExtJS4 framework specially if you try to use Sencha Architect, since the code in examples and the way Sencha Architect generates the code is usually different even if both are MVC.

I like this quote

" In the face of ambiguity, refuse the temptation to guess.
There should be one-- and preferably only one --obvious way to do it."

I know there is lot of examples of everything, and that there is an effort in the documentation, but I cannot find a structured document to read.

I still have to read and learn more for sure, and probably the API documentation will help but I feel there is basic information that should be found in first place instead of extremely simple examples.

In the list from GIT:

CityBars (Sencha Touch)
Sencha Touch Application built with Sencha Architect
loanshark (Sencha Touch)
Associations using Localstorage
ExtSimpleExamples (Useless when you need more complicated things)
FriendUpdates (Sencha Touch)
Portal (no related models)
BooksReview (has related models but VERY simple, doesn't work with any other advanced component)
TouchFeedViewer (Sencha Touch)
SimpleTasks (not useful)
JogWithFriends (Sencha Touch)
ExtFeedViewer (no related models)
Facebook (I did not open the project)
GeoCongress (Sencha Touch)
NativeContacts (Did not check)


Have you seen these examples:


18 Sep 2012, 4:23 AM
Thank you for the additional information. I am alerting the dev department for SA of this thread so they can comment. Perhaps there is a project they have in the works that can help.


18 Sep 2012, 12:57 PM
Thanks for the feedback; we're aware that people need examples to help guide them through using both Ext JS and Sencha Touch.

If there are specific examples you are looking for (like associations as you have mentioned above), post in the Architect forums here:
What examples would you like to see in Architect 2? (http://www.sencha.com/forum/showthread.php?214277-What-examples-would-you-like-to-see-in-Architect-2)

19 Sep 2012, 7:56 PM
Aaron, I'd like to see a simple Architect 2 example of an application which allows a user to log into Facebook and then showed their profile picture and name. I've searched the forums and found bit and pieces about login to face book but no complete examples of doing it. I found one example which I think you ported from touch to Architect 2 (https://github.com/SenchaArchitect/Facebook) which has a FB login view but does not do anything after putting in a user name and password. I think this type of example would be really useful and would add value to what is already a great tool, I hope you agree.

20 Sep 2012, 3:07 AM
Hi aconran,

We need real world examples for Sencha Architect (not Sencha Touch, Sencha Architect using ExtJS4 for MVC projects).

There is a lot of examples for ExtJS4 using charts,etc. As example is ok, but for documentation for the new people that never used ExtJS before and wants to develop MVVC sites using Sencha Architect is not the best way imho.

All applications with Sencha Architect starts with:

enabled: true



Then you define your controllers, views, models, stores and data.

All (the majority) examples uses the non MVC approach, and since you don't have the Sencha Architect constraints you probably can generate different code for the same application.

For me ExtJS4 has the advantage of the UI widgets, and MVC is a must. Sencha Architect really eases the task of generating the interface and writing boilerplate so you do not have to type all the code every time, but for no MVC project it cannot be used.

I will put a post in the thread as requested.