Book Image

Mastering ExtJS - Second Edition

By : Loiane Avancini
Book Image

Mastering ExtJS - Second Edition

By: Loiane Avancini

Overview of this book

Table of Contents (19 chapters)
Mastering Ext JS Second Edition
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

The database model – groups, menus, and permissions


We have already created the user and groups tables. To store the information of the menu and its options and also the permission that each group has, we need to create two more tables: the menu and permissions tables, as shown by the following screenshot:

On the menu table, we will store all the menu information. As each option of the menu table will be a node of a TreePanel, we will store the information in a way that represents a TreePanel. So, we have an id field to identify the node, a text field as the text that is going to be displayed on the node (in our case, we will store the attribute of the translations file since we are using a multilingual capability), iconCls representing the css class that will be used to display the icon for each node, className representing the alias (xtype) of the class that we are going to instantiate dynamically and open at the central tab panel of the application, and finally the menu_id field representing...