Magento 2 Training : Unit 6 – Lesson A Before create the template file, we have to create routes, and controller of our module. Our block will have new methods, and our templates will be dynamical ! File : routes.xml
Practical : Create grid, forms and controllers for Job object
Magento 2 Training : Practical 1 Before begin this practical, you must read previous lessons of the training Specifications You have to do the same things we did for departments on the last two parts. Our jobs grid will have
Delete and massActions on Magento 2 admin
Magento 2 Training : Unit 5 – Lesson C The 2 last controllers to create are : – delete – massDelete Let’s go ! Delete controller creation Create the file : app/code/Maxime/Jobs/Controller/Adminhtml/Department/Delete.php Put this code inside : <?php namespace Maxime\Jobs\Controller\Adminhtml\Department;
Layouts and forms on Magento 2 admin
Magento 2 Training : Unit 5 – Lesson B Admin layout creation We have to create a layout before create the form : app/code/Maxime/Jobs/view/adminhtml/layout/jobs_department_edit.xml Put this little content : <?xml version=”1.0″?> <page xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xsi:noNamespaceSchemaLocation=”urn:magento:framework:View/Layout/etc/page_configuration.xsd”> <update handle=”editor”/> <body> <referenceContainer name=”content”> <block
Adding and Edition controllers on Magento 2 admin
Magento 2 Training : Unit 5 – Lesson A We will create 3 controllers in order to add/edit an element : – NewAction – Edit – Save The “New” controller is named “NewAction” because “new” is a PHP keyword. Our
Add massactions and paging on adminhtml grid
Magento 2 Training : Unit 4 – Lesson E Create massActions on adminhtml grid with Magento 2 We will add the massactions button. For department, we will add “mass delete”, which will delete all checked lines. Open our XML file
Filters creation on adminhtml grid with Magento 2
Magento 2 Training : Unit 4 – Lesson D Add filters on a adminhtml grid On this grid, we will have 2 filters : – ID – Name These filters are added on our XML after the node <container name=”columns_controls”>
Checkboxes, bookmarks and actions on adminhtml grid
Magento 2 Training : Unit 4 – Lesson C Checkboxes and Bookmarks I think you saw the “Bookmarks” button (With the eye icon and the text “Default view”) You can choose, filters, sort and columns to display, and save the
Create adminhtml grid with Magento 2
Magento 2 Training : Unit 4 – Lesson B Now, the file we will modify is the uiComponent : app/code/Maxime/Jobs/view/adminhtml/ui_component/jobs_department_listing.xml Add an “Add new” button We well create a new button at the top of our page in order to
Create an uiComponent with Magento 2
Magento 2 Training : Unit 4 – Lesson A Layout declaration To create page content, we must declare it in a layout. Remember, the layout’s name is associated with the controller. Our action is jobs/department, so our layout name is