Developing for Admin

At the very beginning of our journey, back in Chapter 1, Understanding Magento Architecture, we mentioned how Magento consists of different areas. Developing for Magento admin implies developing for the adminhtml area. While the majority of code is applicable across different areas, there are certain subtle differences. Unlike frontend which is mostly built via HTML (.phtml, .html), the Magento adminhtml area is mostly built via UI components which are referenced, stacked, and configured through .xml files. This is not to say that the same components cannot be used both for frontend and admin, because all UI components can be configured for both of these areas; we just need to configure styles manually for components on the frontend.

There are two basic UI components in Magento: listing and form. The rest are secondary components, which serve as extensions of basic components: listingToolbar, columns, filters, column, form, and field.

To get a better understanding of the adminhtml area, we are going to build a Magelicious_Minventory module, using some of these components. The idea behind the module is to provide a custom listing interface for a limited set of users, where they can easily bump up the product stock in certain increments without ever getting access to other areas of the Magento admin.

Our work here will consist of two major parts:

  • Using the listing component
  • Using the form component

To keep things compact, we will use the <MODULE_DIR> to reference the MAGELICIOUS_DIR>/Minventory directory.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.137.221.163