Project Coding guidelines
Basic coding style used in the system will be PSR-2
Do's
- Create reusable function in Model with error handling returns.
- Follow GIT always.
- Git commit should follow standard best practices.
- Always use i18n in All Applications.
- All the methods and actions must be prefixed by comment description.
- While creating Database always use innodb engine, charset as
utf8mb4
and collation asunicode_ci
. - Database fields/variables should be snake_case , method should be camelCase and class name should be StudlyCase.
- In Database all the master table should be prefixed with
core*<table_name>
. - Use SecurityHelper , UploadHelper and StatusHelper Class for Security hash, Uploading files and Status Options respectively.
- Always Export Financial Data in Quotes("") to avoid change of data(Number Format Scientific) in Excel.
Dont's
- Do not write any SQL Query directly in View.
- Do not write long actions in controllers - break down long code in multiple reusable function.