Create New Module for Laravel CRUD – CMS – Sximo 5 LTS PHP Script


How to create New Module for Laravel CRUD – CMS – Sximo 5 LTS PHP Script

 

Go to : Control Panel -> Code Builder


In Sximo 5.1 LTS , we have added 3 option of CRUD .

  • CRUD Module This is fully CRUD functionality
  • Blank Module This is only generate complete blank template files
  • Report Module Used this for generate report without CRUD

Creating your first module


Before you create module , you have to create table for module you will build . this app doest have feature to create table database , so you need phpmyadmin or other mysql tools for creating table

Step 1

Copy table schema for employee into your phpmyadmin and run query

CREATE TABLE `employee` (

`EmployeeId` int(11) NOT NULL AUTO_INCREMENT,

`LastName` varchar(20) CHARACTER SET utf8 NOT NULL,

`FirstName` varchar(20) CHARACTER SET utf8 NOT NULL,

`ReportsTo` int(11) DEFAULT NULL,

`BirthDate` date DEFAULT NULL,

`HireDate` date DEFAULT NULL,

`Phone` varchar(24) CHARACTER SET utf8 DEFAULT NULL,

`Email` varchar(60) CHARACTER SET utf8 DEFAULT NULL,

`Foto` varchar(100) DEFAULT NULL,

`Status` enum(‘0′,’1’) DEFAULT NULL,

PRIMARY KEY (`EmployeeId`),

KEY `IFK_EmployeeReportsTo` (`ReportsTo`)

) ENGINE=MyISAM AUTO_INCREMENT=24 DEFAULT CHARSET=latin1;

 

Insert sample Data

INSERT INTO `employee` (`EmployeeId`, `LastName`, `FirstName`, `ReportsTo`, `BirthDate`, `HireDate`, `Phone`, `Email`, `Foto`, `Status`) VALUES
(16, 'Zabbaleta', 'Montero', 0, '0000-00-00', '0000-00-00', '010939948', '[email protected]', NULL, '0'),
(20, 'Bandford', 'zee', 19, '2015-03-13', '2015-02-24', '010939948', '[email protected]', NULL, '1'),
(21, 'Marchisio', 'lucas', 16, '1987-07-30', '2007-01-01', '010939948', '[email protected]', NULL, '1'),
(17, 'Tevez', 'Leo', 5, '2012-12-12', '0000-00-00', '000000', '[email protected]', '', '1'),
(23, 'Pepe', 'Steve', 0, '2014-04-24', '2014-04-24', '1 (780) 836-9987', '[email protected]', '', '0'),
(7, 'Alberto', 'Robert', 0, '2014-04-24', '2014-04-24', '+1 (403) 456-9986', '[email protected]', '', '0'),
(14, 'Franchis', 'zoo', 1, '2015-01-08', '2015-01-14', '010939948', '[email protected]', '', '1'),
(19, 'Aguero', 'kimono', 3, '0000-00-00', '0000-00-00', '123123123', '[email protected]', NULL, '1');
	

Now fill create new module form using following info

  • Module Name / Title : Employee
  • Module Note : View All Employee Data
  • Template : Full CRUD .
  • Class Controller : employee.
  • Table Master : employee.
  • Select SQL statement: Check Auto SQL
  • Click Button Submit

If you not getting any error , its should be redirecting you to module manager page

From list installed module, click button gear dropdown and click view module. You should see you module grid with complete function !.

YOU’RE AWESOME!! creating module in one step less than a minutes

 

Laravel CRUD – CMS – Sximo 5 LTS PHP Script Download

 

Have any Question or Comment?

Leave a Reply

Your email address will not be published. Required fields are marked *