function Users() { $this->sql_builder = new SQLQBuilder(); $this->dbConnection = new DMLFunctions(); $tmpSysConf = new sysConf(); $this->employeeIdLength = $tmpSysConf->getEmployeeIdLength(); }
function ReportGenerator() { $this->criteria = array(); $this->field = array(); $sysConfObj = new sysConf(); $this->employeeIdLength = $sysConfObj->getEmployeeIdLength(); }
public function __construct() { $emptyMarker = ReportField::EMPTY_MARKER; $ageQuery = "IF(STRCMP(DATE_FORMAT(hs_hr_employee.`emp_birthday`, CONCAT(YEAR(hs_hr_employee.`emp_birthday`), '-%m-%d')), '0-00-00'), " . "DATE_FORMAT(hs_hr_employee.`emp_birthday`, CONCAT(YEAR(hs_hr_employee.`emp_birthday`), '-%m-%d')), " . "'{$emptyMarker}')"; $sevicePeriodQuery = "IF(STRCMP(DATE_FORMAT(hs_hr_employee.`joined_date`, CONCAT(YEAR(hs_hr_employee.`joined_date`), '-%m-%d')), '0-00-00'), " . "DATE_FORMAT(hs_hr_employee.`joined_date`, CONCAT(YEAR(hs_hr_employee.`joined_date`), '-%m-%d')), " . "'{$emptyMarker}')"; $this->selectionFieldMap = array('EMPNO' => new ReportField('emp_number'), 'EMPFIRSTNAME' => new ReportField('emp_firstname'), 'EMPLASTNAME' => new ReportField('emp_lastname'), 'ADDRESS1' => new ReportField(array('emp_street1', 'emp_street2', 'city_code', 'provin_code', 'coun_code', 'emp_zipcode'), ReportField::COMPOSITE_VALUE), 'TELENO' => new ReportField('emp_hm_telephone'), 'AGE' => new ReportField($ageQuery, ReportField::DIRECT_QUERY), 'REPORTTO' => new ReportField("{CONCAT_WS(' ', eee.`emp_firstname`, eee.`emp_lastname`)}", ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_reportto', 'erep_sub_emp_number', 'emp_number', new JoinTable('hs_hr_employee', 'emp_number', 'erep_sup_emp_number', 'hs_hr_emp_reportto', 'eee')), 'REPORTINGMETHOD' => new ReportField("{hs_hr_emp_reportto.`erep_reporting_mode`}", ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_reportto', 'erep_sub_emp_number', 'emp_number'), 'JOBTITLE' => new ReportField('jobtit_name', ReportField::SINGLE_REFERENCE, 'hs_hr_job_title', 'jobtit_code', 'job_title_code'), 'SERPIR' => new ReportField($sevicePeriodQuery, ReportField::DIRECT_QUERY), 'SUBDIVISION' => new ReportField('title', ReportField::SINGLE_REFERENCE, 'hs_hr_compstructtree', 'id', 'work_station'), 'QUL' => new ReportField("{CONCAT_WS(' - ', hs_hr_education.`edu_uni`, hs_hr_education.`edu_deg`)}", ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_education', 'emp_number', 'emp_number', new JoinTable('hs_hr_education', 'edu_code', 'edu_code', 'hs_hr_emp_education')), 'YEAROFPASSING' => new ReportField("{IF(STRCMP(YEAR(`edu_end_date`), '0'), YEAR(`edu_end_date`), '{$emptyMarker}')}", ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_education', 'emp_number', 'emp_number'), 'EMPSTATUS' => new ReportField('estat_name', ReportField::MULTIPLE_REFERENCE, 'hs_hr_empstat', 'estat_code', 'emp_status'), 'PAYGRD' => new ReportField('sal_grd_name', ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_basicsalary', 'emp_number', 'emp_number', new JoinTable('hs_pr_salary_grade', 'sal_grd_code', 'sal_grd_code', 'hs_hr_emp_basicsalary')), 'LANGUAGES' => new ReportField('lang_name', ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_language', 'emp_number', 'emp_number', new JoinTable('hs_hr_language', 'lang_code', 'lang_code', 'hs_hr_emp_language')), 'SKILLS' => new ReportField('skill_name', ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_skill', 'emp_number', 'emp_number', new JoinTable('hs_hr_skill', 'skill_code', 'skill_code', 'hs_hr_emp_skill')), 'CONTRACT' => new ReportField("{CONCAT(DATE(`econ_extend_start_date`), ' - ', DATE(`econ_extend_end_date`))}", ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_contract_extend', 'emp_number', 'emp_number'), 'WORKEXPERIENCE' => new ReportField("{CONCAT(`eexp_employer`, ' - ', `eexp_jobtit`, ' - ',(YEAR(`eexp_to_date`)-YEAR(`eexp_from_date`)), ' Years',' - ',(MONTH(`eexp_to_date`)-MONTH(`eexp_from_date`)),' Months')}", ReportField::MULTIPLE_REFERENCE, 'hs_hr_emp_work_experience', 'emp_number', 'emp_number')); $this->criteria = array(); $this->field = array(); $sysConfObj = new sysConf(); $this->employeeIdLength = $sysConfObj->getEmployeeIdLength(); }
function EmpInfo() { $sysConfObj = new sysConf(); $this->employeeIdLength = $sysConfObj->getEmployeeIdLength(); }
function Login() { $tmpSysConf = new sysConf(); $this->employeeIdLength = $tmpSysConf->getEmployeeIdLength(); }
case Timesheet::TIMESHEET_STATUS_SUBMITTED: $statusStr = $lang_Time_Timesheet_Status_Submitted; break; case Timesheet::TIMESHEET_STATUS_APPROVED: $statusStr = $lang_Time_Timesheet_Status_Approved; break; case Timesheet::TIMESHEET_STATUS_REJECTED: $statusStr = $lang_Time_Timesheet_Status_Rejected; break; } $startDate = strtotime($timesheet->getStartDate() . " 00:00:00"); $endDate = strtotime($timesheet->getEndDate() . " 23:59:59"); $startDatePrint = LocaleUtil::getInstance()->formatDateTime(date("Y-m-d H:i", $startDate)); $endDatePrint = LocaleUtil::getInstance()->formatDateTime(date("Y-m-d H:i", $endDate)); $row = 0; $sysConf = new sysConf(); $dateFormat = LocaleUtil::convertToXpDateFormat($sysConf->getDateFormat()); $timeFormat = LocaleUtil::convertToXpDateFormat($sysConf->getTimeFormat()); ?> <style type="text/css"> .tableTopLeft { background: none; } .tableTopMiddle { background: none; } .tableTopRight { background: none; } .tableMiddleLeft { background: none;
/** * Constructor * * Serializes the object * */ public function __construct() { $confObj = new EmailConfiguration(); $this->mailType = $confObj->getMailType(); if ($this->mailType == 'smtp') { $config = array(); $authType = $confObj->getSmtpAuth(); if ($authType != EmailConfiguration::EMAILCONFIGURATION_SMTP_AUTH_NONE) { $config['auth'] = strtolower($authType); $config['username'] = trim($confObj->getSmtpUser()); $config['password'] = trim($confObj->getSmtpPass()); } $security = $confObj->getSmtpSecurity(); if ($security != EmailConfiguration::EMAILCONFIGURATION_SMTP_SECURITY_NONE) { $config['ssl'] = strtolower($security); } $config['port'] = trim($confObj->getSmtpPort()); $transport = new Zend_Mail_Transport_Smtp($confObj->getSmtpHost(), $config); } else { if ($this->mailType = 'sendmail') { $transport = new Zend_Mail_Transport_Sendmail(); } } Zend_Mail::setDefaultTransport($transport); $this->mailer = new Zend_Mail(); $this->mailer->setFrom($confObj->getMailAddress(), "OrangeHRM"); $sysConfObj = new sysConf(); $this->employeeIdLength = $sysConfObj->getEmployeeIdLength(); }
/** * Returns the theme directory * @return Theme directory */ public static function getTheme() { // Look in request variables if (isset($_REQUEST['styleSheet']) && !empty($_REQUEST['styleSheet'])) { $requestParam = $_REQUEST['styleSheet']; // If found, validate $themePath = ROOT_PATH . '/themes/' . $requestParam; if (file_exists($themePath)) { return $requestParam; } } // Look in session if (isset($_SESSION['styleSheet']) && !empty($_SESSION['styleSheet'])) { return $_SESSION['styleSheet']; } // If not found yet, look in sysConf.php $sysConf = new sysConf(); $sysConfSetting = $sysConf->getStyleSheet(); if (!empty($sysConfSetting)) { return $sysConfSetting; } // If still not found, use default beyondT return 'beyondT'; }
* Copyright (C) 2006 OrangeHRM Inc., http://www.orangehrm.com * * OrangeHRM is free software; you can redistribute it and/or modify it under the terms of * the GNU General Public License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * OrangeHRM is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * See the GNU General Public License for more details. * * You should have received a copy of the GNU General Public License along with this program; * if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, * Boston, MA 02110-1301, USA * */ $sysConf = new sysConf(); include 'yui.php'; ?> <script type="text/javascript" src="<?php echo $_SESSION['WPATH']; ?> /scripts/time.js"></script> <script type="text/javascript" src="<?php echo $_SESSION['WPATH']; ?> /scripts/calendar/calendar.js"></script> <script type="text/javascript"> YAHOO.namespace("OrangeHRM.time"); YAHOO.OrangeHRM.calendar.format = '<?php
public function showPunchView($messageType = null, $message = null) { $attendanceObj = new AttendanceRecord(); $records['attRecord'] = $attendanceObj->fetchRecords($_SESSION['empID'], null, null, AttendanceRecord::STATUS_ACTIVE, AttendanceRecord::DB_FIELD_PUNCHIN_TIME, 'DESC', '0, 1', true); $records['editMode'] = Config::getAttendanceEmpChangeTime(); $records['empId'] = $_SESSION['empID']; $timeStampDiff = ($_SESSION['userTimeZoneOffset'] - round(date('Z') / 3600, 1)) * 3600; $records['currentDate'] = date('Y-m-d', time() + $timeStampDiff); $records['currentTime'] = date('H:i', time() + $timeStampDiff); $records['messageType'] = $messageType; $records['message'] = $message; $sysConfObj = new sysConf(); $records['timeInputHint'] = $sysConfObj->getTimeInputHint(); $path = "/templates/time/punchView.php"; $template = new TemplateMerger($records, $path); $template->display(); }
/** * Should editing of sendmail path * @static * @return bool */ public static function allowSendmailPathEdit() { $allow = false; $sysConf = new sysConf(); /* Allow editing if from localhost or we have allowed editing from outside localhost */ if ($sysConf->allowSendmailPathEdit() && (CommonFunctions::isRequestFromLocalhost() || !$sysConf->sendmailPathEditOnlyFromLocalHost())) { $allow = true; } return $allow; }