本文整理汇总了PHP中Default_Model_Users::getBGstatus方法的典型用法代码示例。如果您正苦于以下问题:PHP Default_Model_Users::getBGstatus方法的具体用法?PHP Default_Model_Users::getBGstatus怎么用?PHP Default_Model_Users::getBGstatus使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Default_Model_Users
的用法示例。
在下文中一共展示了Default_Model_Users::getBGstatus方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: employeedetails
public function employeedetails($emparr, $conText, $userId)
{
$session = new Zend_Auth_Storage_Session();
$data = $session->read();
$loggedinuser = $data['id'];
$group_id = $data['group_id'];
$empdata = '';
$employeetabsStr = '';
$empdata = '<div class="ml-alert-1-success" id="empdetailsmsgdiv" style="display:none;">';
$empdata .= '<div class="style-1-icon success" style="display:block;"></div>';
$empdata .= '<div id="successtext"></div>';
$empdata .= '</div>';
$empdata .= '<div class="all-bg-ctrl">';
$employeeModal = new Default_Model_Employee();
$employessunderEmpId = $employeeModal->getEmployeesUnderRM($userId);
if (!empty($employessunderEmpId)) {
$empdata .= '<input type="hidden" value="true" id="hasteam" name="hasteam" />';
} else {
$empdata .= '<input type="hidden" value="false" id="hasteam" name="hasteam" />';
}
if ($conText == 'edit' || $conText == 'view') {
//If the user has BG status as "Yet to start" then we should enable the link....
$usersModel = new Default_Model_Users();
$bgstatusArr = $usersModel->getBGstatus($userId);
if (!empty($bgstatusArr) && isset($bgstatusArr) && $bgstatusArr[0]['group_id'] != MANAGEMENT_GROUP) {
if ($bgstatusArr[0]['isactive'] == 1) {
$empdata .= '<div id="hrbgchecklink" style="display:none;" class="action-to-page"><a href="' . BASE_URL . '/empscreening/checkscreeningstatus/empid/' . $userId . '">Send for background checks</a></div>';
}
}
}
if ($conText != 'mydetails') {
$empdata .= '<div class="back-to-page"><input type="button" value="Back" name="Back" onclick="gobacktocontroller(\'' . $conText . '\');"></div>';
}
$empdata .= '<div class="emp-screen-view">';
$empdata .= '<div class="display-img-div" id="displayimg" >';
$empdata .= '<div class="employee-pic-emp">';
if ($emparr['profileimg'] != '') {
$empdata .= '<img id="userImage" src="' . BASE_URL . "/public/uploads/profile/" . $emparr['profileimg'] . '" onerror="this.src=\'' . BASE_URL . '/public/media/images/default-profile-pic.jpg\'"/>';
} else {
$empdata .= '<img id="userImage" src="' . BASE_URL . '/public/media/images/employee-deafult-pic.jpg" />';
}
if ($conText != 'mydetails') {
if ($group_id == HR_GROUP || $loggedinuser == SUPERADMIN || $group_id == MANAGEMENT_GROUP) {
$sel_act = $sel_dact = "";
if ($emparr['isactive'] < 2 && $emparr['emptemplock'] == 0) {
if ($emparr['isactive'] == 1) {
$sel_act = "selected";
} else {
if ($emparr['isactive'] == 0) {
$sel_dact = "selected";
}
}
$empdata .= '<p class="field switch"><label class="cb-enable ' . $sel_act . '"><span>Active</span></label><label class="cb-disable ' . $sel_dact . '"><span>Inactive</span></label> </p>';
if ($sel_act == "selected") {
$empdata .= "\n\t\t\t\t\t\t\t\t\t<script type='text/javascript' language='javascript'>\n\t\t\t\t\t\t\t\t\t\t\$('.cb-disable').click(function(){ \n\t\t\t\t\t\t\t\t\t\t\tmakeActiveInactive('inactive','" . $emparr['id'] . "');\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t</script> ";
} else {
if ($sel_dact == "selected") {
$empdata .= "\n\t\t\t\t\t\t\t\t\t<script type='text/javascript' language='javascript'>\n\t\t\t\t\t\t\t\t\t\t\$('.cb-enable').click(function(){ \n\t\t\t\t\t\t\t\t\t\t\tmakeActiveInactive('active','" . $emparr['id'] . "');\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t</script> ";
}
}
} else {
if ($emparr['isactive'] < 2 && $emparr['emptemplock'] == 1) {
$sel_dact = "selected";
$sel_act = "";
$empdata .= '<p class="field switch"><label class="cb-enable ' . $sel_act . '"><span>Active</span></label><label class="cb-disable ' . $sel_dact . '"><span>Inactive</span></label> </p>';
$empdata .= "\n\t\t\t\t\t\t\t\t<script type='text/javascript' language='javascript'>\n\t\t\t\t\t\t\t\t\t\$('.cb-enable').click(function(){ \n\t\t\t\t\t\t\t\t\t\tmakeActiveInactive('active','" . $emparr['id'] . "');\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t</script> \n\t\t\t\t\t\t\t\t";
} else {
$sel_dact = "selected";
$sel_act = "";
$empdata .= '<p class="field switch"><label class="cb-enable ' . $sel_act . '"><span>Active</span></label><label class="cb-disable ' . $sel_dact . '"><span>Inactive</span></label> </p>';
$empdata .= "\n\t\t\t\t\t\t\t\t<script type='text/javascript' language='javascript'>\n\t\t\t\t\t\t\t\t\t\$('.cb-enable,.cb-disable').click(function(){ \n\t\t\t\t\t\t\t\t\t\tmakeActiveInactive('other','" . $emparr['isactive'] . "');\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t</script> \n\t\t\t\t\t\t\t\t";
}
}
}
}
$empdata .= '</div>';
$empdata .= '<div id="loaderimg" style="display:none; clear:both; margin:0 auto; text-align: center; width:100%;"><img src="' . BASE_URL . "/public/media/images/loaderwhite_21X21.gif" . '" style="width:21px; height: 21px; float: none; "/>';
$empdata .= '</div>';
$empdata .= '</div>';
$empdata .= '<div id="personalDetailsDiv">';
if ($emparr['is_orghead'] == '1') {
$headicon = '<img src="' . BASE_URL . "/public/media/images/org-head.png" . '" class="org-head-icon" />';
} else {
$headicon = '';
}
if (isset($emparr['active_prefix']) && isset($emparr['prefix']) && $emparr['active_prefix'] == 1 && $emparr['prefix'] != '') {
$empdata .= '<p><b>Employee Name <i>:</i></b><span class="emp-name-span bold-text">' . $emparr['prefix'] . '. ' . $emparr['userfullname'] . '</span>' . $headicon . '</p>';
} else {
$empdata .= '<p><b>Employee Name <i>:</i></b><span class="emp-name-span bold-text">' . $emparr['userfullname'] . '</span>' . $headicon . '</p>';
}
$empdata .= '<p><b>Employee Id <i>:</i></b><span class="emp-name-span" id ="spanempid">' . $emparr['employeeId'] . '</span></p>';
$empdata .= '<p><b>Email Id <i>:</i></b><span><a href="javascript:void(0)">' . $emparr['emailaddress'] . '</a></span></p>';
if ($emparr['contactnumber'] != '') {
$empdata .= '<p><b>Contact Number <i>:</i></b>';
$empdata .= '<span id="contactnospan" >' . $emparr['contactnumber'] . '</span>';
if ($group_id == HR_GROUP || $loggedinuser == SUPERADMIN || $loggedinuser == $userId || $group_id == MANAGER_GROUP) {
$empdata .= '<span class="number-edit"><input type="button" value="Update" id="editcontactnumber" name="Edit Number" onclick="opencontactnumberpopup(\'' . $emparr['id'] . '\',\'edit\',\'' . $emparr['contactnumber'] . '\');">';
$empdata .= '</span>';
}
$empdata .= '</p>';
//.........这里部分代码省略.........
示例2: checkscreeningstatusAction
public function checkscreeningstatusAction()
{
$candid = $this->getRequest()->getParam('candid');
$empid = $this->getRequest()->getParam('empid');
$empscreeningModel = new Default_Model_Empscreening();
$personalData = '';
$addressData = '';
$companyData = '';
if (isset($candid) && $candid != '') {
$candidateModel = new Default_Model_Candidatedetails();
$status = $candidateModel->getcandidateData($candid);
if ($status['backgroundchk_status'] == 'Yet to start') {
$this->_redirect('empscreening/add/candid/' . $candid);
} else {
$this->_redirect('empscreening/edit/id/' . $candid . '-2');
}
} elseif (isset($empid) && $empid != '') {
$usersModel = new Default_Model_Users();
$bgstatusArr = $usersModel->getBGstatus($empid);
if ($bgstatusArr[0]['backgroundchk_status'] == 'Yet to start' || $bgstatusArr[0]['backgroundchk_status'] == 'Not Applicable') {
$this->_redirect('empscreening/add/empid/' . $empid);
} else {
$this->_redirect('empscreening/edit/id/' . $empid . '-1');
}
}
}