Site Tools


Hotfix release available: 2024-02-06a "Kaos". upgrade now! [55.1] (what's this?)
New release available: 2024-02-06 "Kaos". upgrade now! [55] (what's this?)
Hotfix release available: 2023-04-04a "Jack Jackrum". upgrade now! [54.1] (what's this?)
New release available: 2023-04-04 "Jack Jackrum". upgrade now! [54] (what's this?)
Hotfix release available: 2022-07-31b "Igor". upgrade now! [53.1] (what's this?)
Hotfix release available: 2022-07-31a "Igor". upgrade now! [53] (what's this?)
New release available: 2022-07-31 "Igor". upgrade now! [52.2] (what's this?)
New release candidate 2 available: rc2022-06-26 "Igor". upgrade now! [52.1] (what's this?)
New release candidate available: 2022-06-26 "Igor". upgrade now! [52] (what's this?)
Hotfix release available: 2020-07-29a "Hogfather". upgrade now! [51.4] (what's this?)
internal:dev_w:codingstds

1. Introduction

1.1. Scope

The scope of this document is to provide guidelines for file naming convention, coding standards, release artifact standards that need to be followed by ExpertusONE team. Following are the list of topics covered:

  • Understanding the Requirements.
  • Planning the activity.
  • Reduce the QA test cycles.
  • Communicating with the team.
  • File naming conventions.
  • Folder naming conventions.
  • Version maintenance.
  • Emails subject.
  • Drafting Emails.
  • Release email conventions.
  • Coding standards.
  • Database table naming conventions.

1.2. Intended Audience

The intended audience of this document is ExpertusONE Development, QA and Deployment teams.

2. Standards & Conventions

2.1 Naming conventions for non-code based files

For all the files other than source files (viz..sql, .php, .inc, .sh, .js), should follow the following naming convention

<Project Name>_<Document Type>_<Release / Ticket #>_<Title or brief description>_<optional Date in mmddyyyy format>_<Version>

Following are the possible document types that can be used during naming of a file:

Document Type Abbreviation
Technical Design Document TDD
Functional Design Document FDD
Build Verification Test Case BVT
Test Results TR
Test Case TC
Root Cause Analysis RCA
Report REP
Supporting Documents SD
Other Documents DOC
Project Plan PLN
Release Notes REL

Following are few sample file names for reference:

Document Type Example
Supporting Doc EXPERTUSONE_SD_Evolution_Bydate_SyncUp_Issue_V1_0.doc
Report EXPERTUSONE_REP_LP_ActiveCourseTagging_V1_3.xls
EXPERTUSONE_REP_CertificationFeed_07012010_V1_0.xls
Tech Design Doc EXPERTUSONE_TDD_ContentTracking_V1_1.doc

Note: In the file name, make sure there are no white spaces in the file names.

2.2. Naming conventions for Code based files

For code based files, following are the naming conventions

<Project Name>_<FileName>

File Type Example
JS exp_sp_core.js
PHP printdetails.php
INC sp_acslms.inc
MODULE exp_sp_featuredlearning.module
INFO exp_sp_featuredlearning.info
SH sp_pdb_process.sh
SQL Ref section 3.4

2.3. Folder naming conventions

Various folders that are created should be in the following format:

  • Release Folder in CVS should be like - v3.0.0.0.
  • FTP Folder should be like - <date>_ExpertusONE_v3.0.0.0.
  • For tickets, it should be like - Ticke#123456.

3. Coding Standards Following sections provide detailed information about various standards that need to be followed during creation/editing of source files.

  • File header maintenance
  • Change header maintenance
  • Change tags

3.1. File Header Information

JavaScript, PHP, INC, Sql File & DB Objects File Header Format

For user interface related files like JavaScript and PHP files and database objects like Procedures, Functions and Views, the following File header format should be used.

/*——————————————————————————
*@class or PHP name: < class or php file name>
*@author(s): <Author Name>
*@version: $Revision: $
*@date: <Created Date>
*@description: <Description>
——————————————————————————-
Modified By Modified On Change Description
——————————————————————————*/

Working example for the same is as below

/*——————————————————————————
*@class or PHP Name: Pre-Requisite Service
*@author(s): Tejus Pratap
*@version: $Revision: $
*@date: 04/04/2009
*@description: Displays the learning path window and starts rendering.
——————————————————————————–
Modified By Modified On Change Description
*——————————————————————————-*/

Shell Script Files (SH Files) File Header Format

For Shell script files (SH files), the file and change header is as follows,

################################################################################
#File: <File name>
#Author: <Author name>
#Version: $Revision: $
#Date: <Created Date>
#Title: <Title>
# Description: <Brief description about the shell script>
#################################################################################
# Modified By Modified On Change Description
#################################################################################

Working example for the same is as below

################################################################################
# File: importdb
# Author: Gokulakrishna E
# Version: $Revision: $
# Date: 04/27/2010
# Title: EXPERTUSONE - Database import script
# Description: imports the EXPERTUSONE production dump from ftp
#################################################################################
# Modified By Modified On Change Description
#################################################################################

3.2. Change Header Information

The change header should be mentioned for files which are getting modified for tickets after the initial version. The change header should proceed immediately after the file header.

JavaScript, PHP, INC, Sql File & DB Objects Change Header Format

/*————————————————————————————————
Modified By Modified On Change Description
————————————————————————————————–
<Modifier Name> <Modified date> <description of change done>
—————————————————————————————————*/

Working example for the same is as below

/*————————————————————————————————
Modified By Modified On Change Description
————————————————————————————————-
Gokulakrishna 0/17/2010 Release 48(added industry list box)
————————————————————————————————–*/

Shell Script Files (SH Files) Change Header Format

################################################################################
# Modified By Modified On Change Description
# <Modifier Name> <Modified date> <description of change done>
################################################################################*/

Working example for the same is as below

################################################################################
# Modified By Modified On Change Description
# Gokulakrishna 04/28/2010 Added comments to file
################################################################################*/

3.3. Change Tags Information

The change tags should be included all places where the existing code is modified for a requirement/ticket or change. Please note that the reference which is used in the change tag should be referred in the change header information.

101 / / Start Ticket#<ticketed/CR/SOW Name>
102 …………
103 ……………
110 / / End Ticket#<ticketid/CR/SOW Name>

Working example for the same is as below

1. <?php
2. / / Start Ticket#42345
3. if(lpsummaryGraph!=null)
4. {
5. lpsummaryGraph.abort();
6. }
7. / / End Ticket#42345

3.4. Database Object Naming Convention

For database objects, the following naming conventions need to be followed:

Object Type Naming Convention Example
Table slt_<action>_<name> slt_ins_ref_mapping
slt_sel_ref_mapping
slt_upd_ref_mapping
slt_del_ref_mapping
Procedure slp_<action>_<name> slp_ins_pcode
slp_upd_pcode
Function slf_<name> slf_get_param_value
Index sli_<name> sli_usr_name
View slv_<name> slv_twelveweek_report
Trigger slr_<name> slr_users

4. Project Related Email Communication

4.1. Email subject

The email subject is mandatory for all project emails and should be of the following format when u are sending,

<projectname>:<tractname>-<title / brief description> <optional date in mm/dd format>

Type Sample
Release Email EXPERTUSONE : v3.0.0.0 Release
Weekly Status Report EXPERTUSONE : Weekly Status Report for week ending 7/3
Others EXPERTUSONE : RCA for Ticket#12345

4.2. Checklist before sending an Email

Before hitting the send button of any project related emails, please ensure the following checklist are met:

  • Spell checking by hitting F7 (function key)
  • Self review of the content if its internal to Expertus team
  • Peer review if the email is sent directly to the Client
  • Check for grammatical errors
internal/dev_w/codingstds.txt · Last modified: 2022/06/14 10:16 (external edit)