Before we get our hands on the MVC architecture, we will create a sample application. As this application is a simple sample (and as it is small), we will declare everything in a single JavaScript file. Then, we will learn how to migrate this app to the Ext MVC pattern.
Our sample application looks like the following:
It is a data grid with some book information, and when we click on a grid row, we will see more information about the book in the details panel below the grid.
Let's try to list everything we need to build this sample app:
First, we need a model where we will declare all the book fields
Then, we need a store to load the book information and populate the grid
As we need to populate a data grid, we also need to implement one
For the details panel, we need to implement a panel
And to display the book details, we need a template
We need to implement the listener, so that when the user clicks on a row of the grid, the app will update...