Exemplo n.º 1
0
 public function __construct($siteID, $parameters)
 {
     /* Pager configuration. */
     $this->_tableWidth = 915;
     $this->_defaultAlphabeticalSortBy = 'lastName';
     $this->ajaxMode = false;
     $this->showExportCheckboxes = true;
     //BOXES WILL NOT APPEAR UNLESS SQL ROW exportID IS RETURNED!
     $this->showActionArea = true;
     $this->showChooseColumnsBox = true;
     $this->allowResizing = true;
     $this->dateCriterion = '';
     if (isset($parameters['period']) && !empty($parameters['period'])) {
         $this->dateCriterion .= ' AND activity.date_created >= ' . $parameters['period'] . ' ';
     } else {
         if (isset($parameters['startDate']) && !empty($parameters['startDate'])) {
             $this->dateCriterion .= ' AND activity.date_created >= \'' . $parameters['startDate'] . '\' ';
         }
         if (isset($parameters['endDate']) && !empty($parameters['endDate'])) {
             $this->dateCriterion .= ' AND activity.date_created <= \'' . $parameters['endDate'] . '\' ';
         }
     }
     $this->defaultSortBy = 'dateCreatedSort';
     $this->defaultSortDirection = 'DESC';
     $this->_defaultColumns = array(array('name' => 'Date', 'width' => 110), array('name' => 'First Name', 'width' => 85), array('name' => 'Last Name', 'width' => 75), array('name' => 'Regarding', 'width' => 125), array('name' => 'Activity', 'width' => 65), array('name' => 'Notes', 'width' => 240), array('name' => 'Entered By', 'width' => 60));
     $this->_db = DatabaseConnection::getInstance();
     $this->_siteID = $siteID;
     $this->_assignedCriterion = "";
     $this->_dataItemIDColumn = 'company.company_id';
     $this->_classColumns = array('Date' => array('pagerRender' => 'return $rsData[\'dateCreated\'];', 'sortableColumn' => 'dateCreatedSort', 'pagerWidth' => 110, 'pagerOptional' => true, 'alphaNavigation' => true, 'filterHaving' => 'dateCreated'), 'First Name' => array('pagerRender' => 'if ($rsData[\'dataItemType\']==' . DATA_ITEM_CANDIDATE . ') {$ret = \'<img src="images/mru/candidate.gif" height="12" alt="" />\';} else if ($rsData[\'dataItemType\']==' . DATA_ITEM_CONTACT . ') {$ret = \'<img src="images/mru/contact.gif" height="12">\';} else {$ret = \'<img src="images/mru/blank.gif">\';} if ($rsData[\'isHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; if ($rsData[\'dataItemType\']==' . DATA_ITEM_CANDIDATE . ') {return $ret.\'&nbsp;<a href="' . CATSUtility::getIndexName() . '?m=candidates&amp;a=show&amp;candidateID=\'.$rsData[\'dataItemID\'].\'" class="\'.$className.\'" title="\'.htmlspecialchars(InfoString::make($rsData[\'dataItemType\'],$rsData[\'dataItemID\'],$rsData[\'siteID\'])).\'">\'.htmlspecialchars($rsData[\'firstName\']).\'</a>\';} else {return  $ret.\'&nbsp;<a href="' . CATSUtility::getIndexName() . '?m=contacts&amp;a=show&amp;contactID=\'.$rsData[\'dataItemID\'].\'" class="\'.$className.\'" title="\'.htmlspecialchars(InfoString::make($rsData[\'dataItemType\'],$rsData[\'dataItemID\'],$rsData[\'siteID\'])).\'">\'.htmlspecialchars($rsData[\'firstName\']).\'</a>\';}', 'sortableColumn' => 'firstName', 'pagerWidth' => 85, 'pagerOptional' => false, 'alphaNavigation' => true, 'filterHaving' => 'firstName'), 'Last Name' => array('pagerRender' => 'if ($rsData[\'isHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; if ($rsData[\'dataItemType\']==' . DATA_ITEM_CANDIDATE . ') {return \'<a href="' . CATSUtility::getIndexName() . '?m=candidates&amp;a=show&amp;candidateID=\'.$rsData[\'dataItemID\'].\'" class="\'.$className.\'" title="\'.htmlspecialchars(InfoString::make($rsData[\'dataItemType\'],$rsData[\'dataItemID\'],$rsData[\'siteID\'])).\'"> \'.htmlspecialchars($rsData[\'lastName\']).\'</a>\';} else {return \'<a href="' . CATSUtility::getIndexName() . '?m=contacts&amp;a=show&amp;contactID=\'.$rsData[\'dataItemID\'].\'" class="\'.$className.\'" title="\'.htmlspecialchars(InfoString::make($rsData[\'dataItemType\'],$rsData[\'dataItemID\'],$rsData[\'siteID\'])).\'"> \'.htmlspecialchars($rsData[\'lastName\']).\'</a>\';}', 'sortableColumn' => 'lastName', 'pagerWidth' => 75, 'pagerOptional' => false, 'alphaNavigation' => true, 'filterHaving' => 'lastName'), 'Regarding' => array('pagerRender' => 'if ($rsData[\'jobIsHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; if ($rsData[\'companyIsHot\'] == 1) $companyClassName =  \'jobLinkHot\'; else $companyClassName = \'jobLinkCold\';  if ($rsData[\'regardingJobTitle\'] == \'\') {$ret = \'General\'; } else {$ret = \'<a href="' . CATSUtility::getIndexName() . '?m=joborders&amp;a=show&amp;jobOrderID=\'.$rsData[\'jobOrderID\'].\'" class="\'.$className.\'">\'.htmlspecialchars($rsData[\'regardingJobTitle\']).\'</a>\'; if($rsData[\'regardingCompanyName\'] != \'\') {$ret .= \' <a href="' . CATSUtility::getIndexName() . '?m=companies&amp;a=show&amp;companyID=\'.$rsData[\'companyID\'].\'" class="\'.$companyClassName.\'">(\'.htmlspecialchars($rsData[\'regardingCompanyName\']).\')\';}} return $ret;', 'sortableColumn' => 'regarding', 'pagerWidth' => 125, 'pagerOptional' => true, 'alphaNavigation' => true, 'filterHaving' => 'regarding'), 'Activity' => array('pagerRender' => '$ret = $rsData[\'typeDescription\']; return $ret;', 'sortableColumn' => 'typeDescription', 'pagerWidth' => 65, 'pagerOptional' => true, 'alphaNavigation' => true, 'filter' => 'activity_type.short_description'), 'Notes' => array('pagerRender' => 'return $rsData[\'notes\'];', 'sortableColumn' => 'notes', 'pagerWidth' => 240, 'pagerOptional' => true, 'alphaNavigation' => true, 'filterHaving' => 'notes'), 'Entered By' => array('pagerRender' => 'return StringUtility::makeInitialName($rsData[\'enteredByFirstName\'], $rsData[\'enteredByLastName\'], false, LAST_NAME_MAXLEN);', 'exportRender' => 'return $rsData[\'enteredByFirstName\'] . " " .$rsData[\'enteredByLastName\'];', 'sortableColumn' => 'enteredBySort', 'pagerWidth' => 60, 'alphaNavigation' => true, 'filter' => 'CONCAT(entered_by_user.last_name, entered_by_user.first_name)'));
     parent::__construct("activity:ActivityDataGrid", $parameters);
 }
Exemplo n.º 2
0
 /**
  * Generates HTML code for export forms / menus.
  *
  * @param flag data item type being exported
  * @param string comma-separated list of data item IDs
  * @param integer number of pixles right the export box should be displayed
  * @return array containing parts of html code for the export form.
  */
 public static function getForm($dataItemType, $IDs, $popUpOffset = 35, $linkOffset = 5)
 {
     $indexName = CATSUtility::getIndexName();
     /* Build form header. */
     $header = '<form name="selectedObjects" action="' . $indexName . '" method="get">' . "\n" . '<input type="hidden" name="m" value="export" />' . "\n" . '<input type="hidden" name="onlySelected" value="true" />' . "\n" . '<input type="hidden" name="dataItemType" value="' . $dataItemType . '" />' . "\n";
     /* Build form menu. */
     $allRecordsURL = sprintf('%s?m=export&amp;a=export&amp;dataItemType=%s', $indexName, $dataItemType);
     if ($_REQUEST["m"] == "candidates") {
         $objSearchDS = new SearchDataStructure($_REQUEST["m"]);
         $objSearchDS->loadFromURL();
         $_SESSION["AUIEO"]["CANDIDATS"]["SearchDS"] = $objSearchDS;
         $allRecordsJoborderURL = sprintf('%s?m=candidates&a=considerForJobSearch&candidateID=SearchDS', $indexName);
     }
     $currentPageURL = sprintf('%s?m=export&amp;a=export&amp;dataItemType=%s&amp;ids=%s', $indexName, $dataItemType, $IDs);
     if ($_REQUEST["m"] == "candidates") {
         $arrID = explode(",", $IDs);
         foreach ($arrID as $ind => $id) {
             $arrID[$ind] = "candidateID[]=" . trim($id);
         }
         $candidateIDs = implode("&", $arrID);
         $currentPageJoborderURL = sprintf('%s?m=candidates&a=considerForJobSearch&%s', $indexName, $candidateIDs);
     }
     $menu = '<div style="float: left; margin-left: 4px; margin-right: ' . $linkOffset . 'px;">' . '<form name="selectAll" action="#">' . '<input type="checkbox" name="allBox" title="Select All" onclick="toggleChecksAll();" />' . '</form>' . '</div>' . '<a href="#" id="exportBoxLink" onclick="showBox(\'ExportBox\'); return false;">Export</a> | <a href="#" id="deleteBoxLink" onclick="deleteSelected(); return false;">Delete</a>';
     if ($_REQUEST["m"] == "candidates") {
         $menu = $menu . ' | <a href="#" id="addToJoborderBoxLink" onclick="showBox(\'JoborderBox\'); return false;">Add to joborder</a>';
     }
     $menu = $menu . '<br />' . '<div class="exportPopup" id="ExportBox" align="left" onmouseover="showBox(\'ExportBox\');" onmouseout="hideBox(\'ExportBox\');">' . '<a href="' . $allRecordsURL . '">Export All Records</a><br />' . '<a href="' . $currentPageURL . '">Export Current Page</a><br />' . '<a href="#" onclick="checkSelected(); return false;">Export Selected Records</a>' . '</div>';
     if ($_REQUEST["m"] == "candidates") {
         $menu = $menu . '
                 <div class="exportPopup" id="JoborderBox" align="left" onmouseover="showBox(\'JoborderBox\');" onmouseout="hideBox(\'JoborderBox\');">' . '<a href="javascript:void(0);" onclick="showPopWin(\'' . $allRecordsJoborderURL . '\', 750, 390, null); return false;">All Records</a><br />' . '<a href="javascript:void(0);" onclick="showPopWin(\'' . $allRecordsJoborderURL . '\', 750, 390, null); return false;">Current Page</a><br />' . '<a href="#" onclick="checkSelected(); return false;">Selected Records</a>' . '</div>';
     }
     $footer = '</form>';
     return array('header' => $header, 'footer' => $footer, 'menu' => $menu);
 }
Exemplo n.º 3
0
 public function __construct()
 {
     parent::__construct();
     $this->_authenticationRequired = true;
     $this->_moduleDirectory = 'lists';
     $this->_moduleName = 'lists';
     $this->_moduleTabText = 'Lists';
     $this->_subTabs = array('Show Lists' => CATSUtility::getIndexName() . '?m=lists');
 }
Exemplo n.º 4
0
 public function __construct()
 {
     parent::__construct();
     $this->_authenticationRequired = true;
     $this->_moduleDirectory = 'joborders';
     $this->_moduleName = 'joborders';
     $this->_moduleTabText = 'Job Orders';
     $this->_subTabs = array('Add Job Order' => 'javascript:void(0);*js=showPopWin(\'' . CATSUtility::getIndexName() . '?m=joborders&amp;a=addJobOrderPopup\', 400, 250, null);*al=' . ACCESS_LEVEL_EDIT, 'Search Job Orders' => CATSUtility::getIndexName() . '?m=joborders&amp;a=search');
 }
Exemplo n.º 5
0
 public function __construct()
 {
     parent::__construct();
     $this->_authenticationRequired = true;
     $this->_moduleDirectory = 'contacts';
     $this->_moduleName = 'contacts';
     $this->_moduleTabText = 'Contacts';
     $this->_subTabs = array('Add Contact' => CATSUtility::getIndexName() . '?m=contacts&amp;a=add*al=' . ACCESS_LEVEL_EDIT, 'Search Contacts' => CATSUtility::getIndexName() . '?m=contacts&amp;a=search', 'Cold Call List' => CATSUtility::getIndexName() . '?m=contacts&amp;a=showColdCallList');
 }
Exemplo n.º 6
0
 public function __construct()
 {
     parent::__construct();
     $this->_authenticationRequired = true;
     $this->_moduleDirectory = 'companies';
     $this->_moduleName = 'companies';
     $this->_moduleTabText = 'Companies';
     $this->_subTabs = array('Add Company' => CATSUtility::getIndexName() . '?m=companies&amp;a=add*al=' . ACCESS_LEVEL_EDIT . '*hrmode=0', 'Search Companies' => CATSUtility::getIndexName() . '?m=companies&amp;a=search*hrmode=0', 'Go To My Company' => CATSUtility::getIndexName() . '?m=companies&amp;a=internalPostings*hrmode=0');
 }
Exemplo n.º 7
0
 /**
  * Adds more options to the action area on the pager.  Overloads 
  * DataGrid Inner Action Area function.
  *
  * @return html innerActionArea commands.
  */
 public function getInnerActionArea()
 {
     $html = parent::getInnerActionArea();
     $newParameterArray = $this->_parameters;
     $newParameterArray['exportIDs'] = '<dynamic>';
     $html .= sprintf('<a href="javascript:void(0);" onclick="window.location.href=\'%s?m=export&amp;a=exportByDataGrid&amp;i=%s&amp;p=%s&amp;&dynamicArgument%s=\' + urlEncode(serializeArray(exportArray%s));">Export Selected</a><br />', CATSUtility::getIndexName(), urlencode($this->_instanceName), urlencode(serialize($newParameterArray)), urlencode($this->_instanceName), md5($this->_instanceName));
     //$html .= sprintf(
     //            '<a href="">Delete Selected</a><br />'
     //         );
     return $html;
 }
Exemplo n.º 8
0
 /**
  * Generates HTML code for export forms / menus.
  *
  * @param flag data item type being exported
  * @param string comma-separated list of data item IDs
  * @param integer number of pixles right the export box should be displayed
  * @return array containing parts of html code for the export form.
  */
 public static function getForm($dataItemType, $IDs, $popUpOffset = 35, $linkOffset = 5)
 {
     $indexName = CATSUtility::getIndexName();
     /* Build form header. */
     $header = '<form name="selectedObjects" action="' . $indexName . '" method="get">' . "\n" . '<input type="hidden" name="m" value="export" />' . "\n" . '<input type="hidden" name="onlySelected" value="true" />' . "\n" . '<input type="hidden" name="dataItemType" value="' . $dataItemType . '" />' . "\n";
     /* Build form menu. */
     $allRecordsURL = sprintf('%s?m=export&amp;a=export&amp;dataItemType=%s', $indexName, $dataItemType);
     $currentPageURL = sprintf('%s?m=export&amp;a=export&amp;dataItemType=%s&amp;ids=%s', $indexName, $dataItemType, $IDs);
     $menu = '<div style="float: left; margin-left: 4px; margin-right: ' . $linkOffset . 'px;">' . '<form name="selectAll" action="#">' . '<input type="checkbox" name="allBox" title="Select All" onclick="toggleChecksAll();" />' . '</form>' . '</div>' . '<a href="#" id="exportBoxLink" onclick="showBox(\'ExportBox\'); return false;">Export</a><br />' . '<div class="exportPopup" id="ExportBox" align="left" onmouseover="showBox(\'ExportBox\');" onmouseout="hideBox(\'ExportBox\');">' . '<a href="' . $allRecordsURL . '">Export All Records</a><br />' . '<a href="' . $currentPageURL . '">Export Current Page</a><br />' . '<a href="#" onclick="checkSelected(); return false;">Export Selected Records</a>' . '</div>';
     $footer = '</form>';
     return array('header' => $header, 'footer' => $footer, 'menu' => $menu);
 }
Exemplo n.º 9
0
    public function __construct()
    {
        parent::__construct();

        $this->_authenticationRequired = true;
        $this->_moduleDirectory = 'lists';
        $this->_moduleName = 'lists';
        $this->_moduleTabText = 'Lists';
        $this->_subTabs = array(
            'Show Lists'     => CATSUtility::getIndexName() . '?m=lists'
           /* 'New Static List' => CATSUtility::getIndexName() . '?m=lists&a=newListStatic*al=' . ACCESS_LEVEL_EDIT, */
           /* 'New Dynamic List' => CATSUtility::getIndexName() . '?m=lists&a=newListDynamic*al=' . ACCESS_LEVEL_EDIT */
        );
    }
Exemplo n.º 10
0
 /**
  * Adds more options to the action area on the pager.  Overloads
  * DataGrid Inner Action Area function.
  *
  * @return html innerActionArea commands.
  */
 public function getInnerActionArea()
 {
     //TODO: Add items:
     //  - Add to List
     //  - Add to Pipeline
     //  - Mass set rank (depends on each candidate having their own personal rank - are we going to do this?)
     $html = '';
     $html .= $this->getInnerActionAreaItem('Remove From This List', CATSUtility::getIndexName() . '?m=lists&amp;a=removeFromListDatagrid&amp;dataItemType=' . DATA_ITEM_CANDIDATE . '&amp;savedListID=' . $this->getMiscArgument(), false);
     $html .= $this->getInnerActionAreaItemPopup('Add To Pipeline', CATSUtility::getIndexName() . '?m=candidates&amp;a=considerForJobSearch', 750, 460);
     if (MAIL_MAILER != 0) {
         $html .= $this->getInnerActionAreaItem('Send E-Mail', CATSUtility::getIndexName() . '?m=candidates&amp;a=emailCandidates');
     }
     $html .= $this->getInnerActionAreaItem('Export', CATSUtility::getIndexName() . '?m=export&amp;a=exportByDataGrid');
     $html .= parent::getInnerActionArea();
     return $html;
 }
Exemplo n.º 11
0
 public function __construct()
 {
     parent::__construct();
     $this->_realAccessLevel = $_SESSION['CATS']->getRealAccessLevel();
     $this->_authenticationRequired = true;
     $this->_moduleDirectory = 'settings';
     $this->_moduleName = 'settings';
     $this->_moduleTabText = 'Settings';
     /* Only CATS professional on site gets to make career portal customizer users. */
     if (!file_exists('modules/asp') && LicenseUtility::isProfessional()) {
         $this->_settingsUserCategories = array(array('Career Portal Customizer', 'careerportal', 'This user can\'t do anything but modify the career portal settings.  It is intended to be used by the CATS Professional Support Team.  This user does not count against your maximum users.', ACCESS_LEVEL_SA, ACCESS_LEVEL_READ));
     }
     $mp = array('Administration' => CATSUtility::getIndexName() . '?m=settings&amp;a=administration', 'My Profile' => CATSUtility::getIndexName() . '?m=settings');
     /* Only CATS professional can download addons. */
     if (file_exists('modules/asp') || LicenseUtility::isProfessional()) {
         $mp['Downloads'] = CATSUtility::getIndexName() . '?m=settings&amp;a=downloads';
     }
     $this->_subTabs = $mp;
     $this->_hooks = $this->defineHooks();
 }
Exemplo n.º 12
0
    public function __construct()
    {
        parent::__construct();

        $this->_realAccessLevel = $_SESSION['CATS']->getRealAccessLevel();
        $this->_authenticationRequired = true;
        $this->_moduleDirectory = 'settings';
        $this->_moduleName = 'settings';
        $this->_moduleTabText = 'Settings';

        $mp = array(
            'Administration' => CATSUtility::getIndexName() . '?m=settings&amp;a=administration',
            'My Profile'     => CATSUtility::getIndexName() . '?m=settings'
        );

        $mp['Downloads'] = CATSUtility::getIndexName() . '?m=settings&a=downloads';

        $this->_subTabs = $mp;
        
        $this->_hooks = $this->defineHooks();
    }
Exemplo n.º 13
0
 private function displayPublicJobOrders()
 {
     $site = new Site(-1);
     $careerPortalSiteID = $site->getFirstSiteID();
     if (!eval(Hooks::get('RSS_SITEID'))) {
         return;
     }
     $jobOrders = new JobOrders($careerPortalSiteID);
     $rs = $jobOrders->getAll(JOBORDERS_STATUS_ACTIVE, -1, -1, -1, false, true);
     /* XML Headers */
     header('Content-type: text/xml');
     $indexName = CATSUtility::getIndexName();
     $stream = sprintf("<?xml version=\"1.0\" encoding=\"utf-8\"?>\n" . "<rss version=\"2.0\">\n" . "<channel>\n" . "<title>New Job Orders</title>\n" . "<description>CATS RSS Feed</description>\n" . "<link>%s</link>\n" . "<pubDate>%s</pubDate>\n", CATSUtility::getAbsoluteURI(), DateUtility::getRSSDate());
     foreach ($rs as $rowIndex => $row) {
         $uri = sprintf("%scareers/?p=showJob&amp;ID=%d", CATSUtility::getAbsoluteURI(), $row['jobOrderID']);
         // Fix URL if viewing from /rss without using globals or dirup '../'
         if (strpos($_SERVER['PHP_SELF'], '/rss/') !== false) {
             $uri = str_replace('/rss/', '/', $uri);
         }
         $stream .= sprintf("<item>\n" . "<title>%s (%s)</title>\n" . "<description>Located in %s.</description>\n" . "<link>%s</link>\n" . "</item>\n", $row['title'], $jobOrders->typeCodeToString($row['type']), StringUtility::makeCityStateString($row['city'], $row['state']), $uri);
     }
     $stream .= "</channel>\n</rss>\n";
     echo $stream;
 }
Exemplo n.º 14
0
 /**
  * Returns link HTML for a data item.
  *
  * @param flag Data Item type flag.
  * @param integer Data Item ID.
  * @param boolean Show name / data item title?
  * @return string Link HTML (<a href="...">...</a>).
  */
 private function getHTMLOfLink($dataItemID, $dataItemType, $showTitle = true)
 {
     $string = '<a href="' . CATSUtility::getIndexName();
     switch ($dataItemType) {
         case DATA_ITEM_CANDIDATE:
             $candidates = new Candidates($this->_siteID);
             $string .= '?m=candidates&amp;a=show&amp;candidateID=' . $dataItemID . '">';
             $string .= '<img src="images/mru/candidate.gif" alt="" style="border: none;" title="Candidate" />';
             if ($showTitle) {
                 $data = $candidates->get($dataItemID);
                 if (!isset($data['firstName'])) {
                     $string = '<img src="images/mru/company.gif" alt="" style="border: none;" /> (Candidate Deleted)<a>';
                 } else {
                     $string .= '&nbsp;' . $data['firstName'] . ' ' . $data['lastName'];
                 }
             }
             $image = 'images/mru/candidate.gif';
             break;
         case DATA_ITEM_COMPANY:
             $companies = new Companies($this->_siteID);
             $string .= '?m=companies&amp;a=show&amp;companyID=' . $dataItemID . '">';
             $string .= '<img src="images/mru/company.gif" alt="" style="border: none;" title="Company" />';
             if ($showTitle) {
                 $data = $companies->get($dataItemID);
                 if (!isset($data['name'])) {
                     $string = '<img src="images/mru/company.gif" alt="" style="border: none;" /> (Company Deleted)<a>';
                 } else {
                     $string .= '&nbsp;' . $data['name'];
                 }
             }
             break;
         case DATA_ITEM_CONTACT:
             $contacts = new Contacts($this->_siteID);
             $string .= '?m=contacts&amp;a=show&amp;contactID=' . $dataItemID . '">';
             $string .= '<img src="images/mru/contact.gif" alt="" style="border: none;" title="Contact" />';
             if ($showTitle) {
                 $data = $contacts->get($dataItemID);
                 if (!isset($data['firstName'])) {
                     $string = '<img src="images/mru/contact.gif" alt="" style="border: none;" /> (Contact Deleted)<a>';
                 } else {
                     $string .= '&nbsp;' . $data['firstName'] . ' ' . $data['lastName'];
                 }
             }
             break;
         case DATA_ITEM_JOBORDER:
             $jobOrders = new JobOrders($this->_siteID);
             $string .= '?m=joborders&amp;a=show&amp;jobOrderID=' . $dataItemID . '">';
             $string .= '<img src="images/mru/job_order.gif" alt="" style="border: none;" title="Job Order" />';
             if ($showTitle) {
                 $data = $jobOrders->get($dataItemID);
                 if (!isset($data['title'])) {
                     $string = '<img src="images/mru/job_order.gif" alt="" style="border: none;" /> (Job Order Deleted)<a>';
                 } else {
                     $string .= '&nbsp;' . $data['title'];
                 }
             }
             break;
     }
     $string .= '</a>';
     return $string;
 }
Exemplo n.º 15
0
                                <td>
                                    <select id="addFieldSelect<?php echo($index); ?>">
                                      <?php foreach($this->extraFieldTypes as $extraFieldTypeIndex => $extraFieldTypeData): ?>
                                        <option value="<?php echo($extraFieldTypeIndex); ?>"><?php $this->_($extraFieldTypeData['name']); ?></option>
                                      <?php endforeach; ?>
                                   </select>
                                </td>
                            </tr>
                        </table>                                    
                        <input type="button" class="button" value="Add Field" onclick="onAddField<?php echo($index); ?>();" />&nbsp;
                        <input type="button" class="button" value="Cancel" onclick="onHideAddArea<?php echo($index); ?>();" />
                    </div>
                    <div id="addFieldOption<?php echo($index); ?>">
                        <a href="javascript:void(0);" onclick="document.getElementById('addField<?php echo($index); ?>').style.display=''; document.getElementById('addFieldOption<?php echo($index); ?>').style.display='none'; document.getElementById('addFieldName<?php echo($index); ?>').value=''; document.getElementById('addFieldName<?php echo($index); ?>').focus();">
                            <img src="images/actions/add_small.gif" border="0" />&nbsp;Add field to <?php echo($data['name']); ?>
                        </a>
                    </div>
                    <br />
                    <br />
                </td>
            </tr>
        <?php endforeach; ?>

    </table>
    <input type="submit" class="button" value="Save" style="display:none;" id="buttonSave" />
    <input type="button" name="back" class = "button" value="Done" id="buttonDone"  onclick="document.location.href='<?php echo(CATSUtility::getIndexName()); ?>?m=settings&amp;a=administration';" />
</form>
    <?php 
$AUIEO_CONTENT=ob_get_clean();
			?>
Exemplo n.º 16
0
 public function verificationImage()
 {
     // FIXME: mt_rand()?!
     srand((double) microtime() * 10000);
     $string = strtoupper(md5(rand(0, 10000)));
     $verifyString = substr($string, 0, 6);
     /* Replace some numbers so all of the characters are quite obviousally
      * as they look.
      */
     $verifyString = str_replace('9', 'T', $verifyString);
     $verifyString = str_replace('6', 'Q', $verifyString);
     $verifyString = str_replace('5', 'R', $verifyString);
     $verifyString = str_replace('0', 'X', $verifyString);
     $verifyString = str_replace('1', 'P', $verifyString);
     $db = DatabaseConnection::getInstance();
     $sql = sprintf("INSERT INTO word_verification (\n                word\n             )\n             VALUES (\n                %s\n             )", $db->makeQueryString($verifyString));
     $db->query($sql);
     $wordVerifyID = $db->getLastInsertID();
     $HTML = '<img src="' . CATSUtility::getIndexName() . '?m=graphs&amp;a=wordVerify&amp;wordVerifyID=' . $wordVerifyID . '" alt="Graph" />';
     $HTML .= '<input type="hidden" name="wordVerifyID" id="wordVerifyID" value="' . $wordVerifyID . '" />';
     return $HTML;
 }
Exemplo n.º 17
0
 public function __construct($instanceName, $siteID, $parameters, $misc = 0)
 {
     $this->_db = DatabaseConnection::getInstance();
     $this->_siteID = $siteID;
     $this->_assignedCriterion = "";
     $this->_dataItemIDColumn = 'contact.contact_id';
     $this->_classColumns = array('First Name' => array('select' => 'contact.first_name AS firstName', 'pagerRender' => 'if ($rsData[\'isHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; return \'<a href="' . CATSUtility::getIndexName() . '?m=contacts&amp;a=show&amp;contactID=\'.$rsData[\'contactID\'].\'" class="\'.$className.\'">\'.htmlspecialchars($rsData[\'firstName\']).\'</a>\';', 'sortableColumn' => 'firstName', 'pagerWidth' => 75, 'pagerOptional' => false, 'alphaNavigation' => true, 'filter' => 'contact.first_name'), 'Last Name' => array('select' => 'contact.last_name AS lastName', 'sortableColumn' => 'lastName', 'pagerRender' => 'if ($rsData[\'isHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; return \'<a href="' . CATSUtility::getIndexName() . '?m=contacts&amp;a=show&amp;contactID=\'.$rsData[\'contactID\'].\'" class="\'.$className.\'">\'.htmlspecialchars($rsData[\'lastName\']).\'</a>\';', 'pagerWidth' => 85, 'pagerOptional' => false, 'alphaNavigation' => true, 'filter' => 'contact.last_name'), 'Company' => array('select' => 'company.name AS name,' . 'company.company_id as companyID', 'pagerRender' => 'if ($rsData[\'isHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; return \'<a href="' . CATSUtility::getIndexName() . '?m=companies&amp;a=show&amp;companyID=\'.$rsData[\'companyID\'].\'" class="\'.$className.\'">\'.htmlspecialchars($rsData[\'name\']).\'</a>\';', 'sortableColumn' => 'name', 'pagerWidth' => 60, 'pagerOptional' => true, 'alphaNavigation' => true, 'filter' => 'company.name'), 'Title' => array('select' => 'contact.title AS title', 'sortableColumn' => 'title', 'pagerWidth' => 140, 'alphaNavigation' => true, 'pagerOptional' => true, 'filter' => 'contact.title'), 'Department' => array('select' => 'company_department.company_department_id AS companyDepartmentID, company_department.name as department', 'join' => 'LEFT JOIN company_department on company_department.company_department_id = contact.company_department_id', 'sortableColumn' => 'department', 'pagerWidth' => 120, 'alphaNavigation' => true, 'pagerOptional' => true, 'filter' => 'company_department.department'), 'Work Phone' => array('select' => 'contact.phone_work AS workPhone', 'sortableColumn' => 'workPhone', 'pagerWidth' => 140, 'alphaNavigation' => false, 'pagerOptional' => true, 'filter' => 'contact.work_phone'), 'Cell Phone' => array('select' => 'contact.phone_cell AS cellPhone', 'sortableColumn' => 'cellPhone', 'pagerWidth' => 140, 'alphaNavigation' => false, 'pagerOptional' => true, 'filter' => 'contact.phone_cell'), 'Other Phone' => array('select' => 'contact.phone_other AS otherPhone', 'sortableColumn' => 'otherPhone', 'pagerWidth' => 140, 'alphaNavigation' => false, 'pagerOptional' => true, 'filter' => 'contact.phone_other'), 'E-Mail' => array('select' => 'contact.email1 AS email1', 'sortableColumn' => 'email1', 'pagerWidth' => 80, 'filter' => 'contact.email1'), '2nd E-Mail' => array('select' => 'contact.email2 AS email2', 'sortableColumn' => 'email2', 'pagerWidth' => 80, 'filter' => 'contact.email2'), 'Address' => array('select' => 'contact.address AS address', 'sortableColumn' => 'address', 'pagerWidth' => 250, 'alphaNavigation' => true, 'filter' => 'contact.address'), 'City' => array('select' => 'contact.city AS city', 'sortableColumn' => 'city', 'pagerWidth' => 80, 'alphaNavigation' => true, 'filter' => 'contact.city'), 'State' => array('select' => 'contact.state AS state', 'sortableColumn' => 'state', 'filterType' => 'dropDown', 'pagerWidth' => 50, 'alphaNavigation' => true, 'filter' => 'contact.state'), 'Zip' => array('select' => 'contact.zip AS zip', 'sortableColumn' => 'zip', 'pagerWidth' => 50, 'filter' => 'contact.zip'), 'Misc Notes' => array('select' => 'contact.notes AS notes', 'sortableColumn' => 'notes', 'pagerWidth' => 300, 'filter' => 'contact.notes'), 'Created' => array('select' => 'DATE_FORMAT(contact.date_created, \'%m-%d-%y\') AS dateCreated', 'pagerRender' => 'return $rsData[\'dateCreated\'];', 'sortableColumn' => 'dateCreatedSort', 'pagerWidth' => 60, 'filterHaving' => 'DATE_FORMAT(contact.date_created, \'%m-%d-%y\')'), 'Modified' => array('select' => 'DATE_FORMAT(contact.date_modified, \'%m-%d-%y\') AS dateModified', 'pagerRender' => 'return $rsData[\'dateModified\'];', 'sortableColumn' => 'dateModifiedSort', 'pagerWidth' => 60, 'pagerOptional' => false, 'filterHaving' => 'DATE_FORMAT(contact.date_modified, \'%m-%d-%y\')'), 'OwnerID' => array('select' => '', 'filter' => 'contact.owner', 'pagerOptional' => false, 'filterable' => false, 'filterDescription' => 'Only My Contacts'), 'IsHot' => array('select' => '', 'filter' => 'contact.is_hot', 'pagerOptional' => false, 'filterable' => false, 'filterDescription' => 'Only Hot Contacts'));
     if (US_ZIPS_ENABLED) {
         $this->_classColumns['Near Zipcode'] = array('select' => 'contact.zip AS zip', 'filter' => 'contact.zip', 'pagerOptional' => false, 'filterTypes' => '=@');
     }
     /* Extra fields get added as columns here. */
     $contacts = new Contacts($this->_siteID);
     $extraFieldsRS = $contacts->extraFields->getSettings();
     foreach ($extraFieldsRS as $index => $data) {
         $fieldName = $data['fieldName'];
         if (!isset($this->_classColumns[$fieldName])) {
             $columnDefinition = $contacts->extraFields->getDataGridDefinition($index, $data, $this->_db);
             /* Return false for extra fields that should not be columns. */
             if ($columnDefinition !== false) {
                 $this->_classColumns[$fieldName] = $columnDefinition;
             }
         }
     }
     parent::__construct($instanceName, $parameters, $misc);
 }
Exemplo n.º 18
0
 /**
  * Returns the javascript for the apply filter function for the table.
  * The generated JS function is submitFilter[MD5](boolean).  If the
  * argument is true, the property filterVisible is retained rather than
  * forced to true.  If the argument is false, the property filterVisible is
  * set to false.  If it is omitted, filterVisible is set to true.
  *
  * @return string Javascript
  */
 public function _getApplyFilterFunctionDefinition()
 {
     $md5InstanceName = md5($this->_instanceName);
     $newParameterArray = $this->_parameters;
     $newParameterArray['rangeStart'] = 0;
     $newParameterArray['filter'] = '<dynamic>';
     $newParameterArray['filterVisible'] = true;
     echo 'submitFilter', $md5InstanceName, ' = function(retainFilterVisible) { ';
     if (isset($this->ajaxMode) && $this->ajaxMode) {
         echo sprintf('populateAjaxPager(\'%s\', \'%s\', \'%s\', document.getElementById(\'filterArea%s\').value);', urlencode($this->_instanceName), urlencode(serialize($newParameterArray)), $_SESSION['CATS']->getCookie(), $md5InstanceName);
     } else {
         $requestString = $this->_getUnrelatedRequestString();
         $requestString .= '&' . urlencode('parameters' . $this->_instanceName) . '=' . urlencode(serialize($newParameterArray));
         echo 'if (typeof(retainFilterVisible) == \'undefined\') {';
         echo sprintf('document.location.href=\'%s?%s&dynamicArgument%s=\' + urlEncode(document.getElementById(\'filterArea%s\').value);', CATSUtility::getIndexName(), $requestString, urlencode($this->_instanceName), $md5InstanceName);
         echo '} else if (typeof(retainFilterVisible) != \'undefined\' && retainFilterVisible == false) {';
         $newParameterArray = $this->_parameters;
         $newParameterArray['rangeStart'] = 0;
         $newParameterArray['filter'] = '<dynamic>';
         $newParameterArray['filterVisible'] = false;
         $requestString = $this->_getUnrelatedRequestString();
         $requestString .= '&' . urlencode('parameters' . $this->_instanceName) . '=' . urlencode(serialize($newParameterArray));
         echo sprintf('document.location.href=\'%s?%s&dynamicArgument%s=\' + urlEncode(document.getElementById(\'filterArea%s\').value);', CATSUtility::getIndexName(), $requestString, urlencode($this->_instanceName), $md5InstanceName);
         echo '} else {';
         $newParameterArray = $this->_parameters;
         $newParameterArray['rangeStart'] = 0;
         $newParameterArray['filter'] = '<dynamic>';
         $requestString = $this->_getUnrelatedRequestString();
         $requestString .= '&' . urlencode('parameters' . $this->_instanceName) . '=' . urlencode(serialize($newParameterArray));
         echo sprintf('document.location.href=\'%s?%s&dynamicArgument%s=\' + urlEncode(document.getElementById(\'filterArea%s\').value);', CATSUtility::getIndexName(), $requestString, urlencode($this->_instanceName), $md5InstanceName);
         echo '}';
     }
     echo '}';
 }
Exemplo n.º 19
0
        <div id="contents">
            <table width="100%">
                <tr>
                    <td width="3%">
                        <img src="images/settings.gif" width="24" height="24" border="0" alt="Settings" style="margin-top: 3px;" />&nbsp;
                    </td>
                    <td align="left"><h2>Settings: Customization</h2></td>
                </tr>
            </table>

            <p class="note">Calendar Customization</p>
            <table>
                <tr>
                    <td>
                        <form name="editCalendarForm" id="editCalendarForm" action="<?php echo(CATSUtility::getIndexName()); ?>?m=settings&amp;a=customizeCalendar" method="post">
                            <input type="hidden" name="postback" value="postback" />
                            <table class="editTable" width="700">
                                <tr>
                                    <td class="tdVertical" style="width:250px;">
                                        Disable AJAX dynamic event loading:
                                    </td>
                                    <td class="tdData">
                                        <input type="checkbox" name="noAjax"<?php if ($this->calendarSettingsRS['noAjax'] == '1'): ?> checked<?php endif; ?>>
                                    </td>
                                </tr>
                                <tr>
                                    <td class="tdVertical" style="width:250px;">
                                        By default, all events are public:
                                    </td>
                                    <td class="tdData">
Exemplo n.º 20
0
 *
 * Copyright (C) 2005 - 2007 Cognizo Technologies, Inc.
 *
 *
 * The contents of this file are subject to the CATS Public License
 * Version 1.1a (the "License"); you may not use this file except in
 * compliance with the License. You may obtain a copy of the License at
 * http://www.catsone.com/. Software distributed under the License is
 * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either
 * express or implied. See the License for the specific language governing
 * rights and limitations under the License.
 *
 * Software distributed under the License is distributed on an "AS IS"
 * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
 * License for the specific language governing rights and limitations
 * under the License.
 *
 * The Original Code is "CATS Standard Edition".
 *
 * The Initial Developer of the Original Code is Cognizo Technologies, Inc.
 * Portions created by the Initial Developer are Copyright (C) 2005 - 2007
 * (or from the year in which this file was created to the year 2007) by
 * Cognizo Technologies, Inc. All Rights Reserved.
 *
 * $Id: index.php 3078 2007-09-21 20:25:28Z will $
 */
$xmlPage = true;
chdir('..');
include_once './lib/CATSUtility.php';
include_once CATSUtility::getIndexName();
Exemplo n.º 21
0
<?php 
//trace("======");
/* 
 * CandidATS
 * Sites Management
 *
 * Copyright (C) 2014 - 2015 Auieo Software Private Limited, Parent Company of Unicomtech.
 * 
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

ob_start();
if ($this->isPopup)
{
    TemplateUtility::printHeader('Candidate - '.$this->data['first_name'].' '.$this->data['last_name'], array( 'js/activity.js', 'js/sorttable.js', 'js/match.js', 'js/lib.js', 'js/pipeline.js', 'js/attachment.js'));
}
else
{
    TemplateUtility::printHeader('Candidate - '.$this->data['first_name'].' '.$this->data['last_name'], array( 'js/activity.js', 'js/sorttable.js', 'js/match.js', 'js/lib.js', 'js/pipeline.js', 'js/attachment.js'));
}
$AUIEO_HEADER=  ob_get_clean();

$AUIEO_CONTENT="";
ob_start();
if ($this->data['is_admin_hidden'] == 1)
{
    ?>
    <p class="warning">This Candidate is hidden.  Only CATS Administrators can view it or search for it.  To make it visible by the site users, click <a href="<?php echo(CATSUtility::getIndexName()); ?>?m=candidates&a=administrativeHideShow&candidateID=<?php echo($this->candidateID); ?>&state=0" style="font-weight:bold;">Here.</a></p>
<?php 
Exemplo n.º 22
0
       <div id="contents">
            <table>
                <tr>
                    <td width="3%">
                        <img src="images/settings.gif" width="24" height="24" border="0" alt="Settings" style="margin-top: 3px;" />&nbsp;
                    </td>
                    <td><h2>Settings: Administration</h2></td>
                </tr>
            </table>

            <p class="note">E-Mail Settings</p>

            <table>
                <tr>
                    <td>
                        <form name="emailSettingsForm" id="emailSettingsForm" action="<?php echo(CATSUtility::getIndexName()); ?>?m=settings&amp;a=emailSettings" method="post">
                            <input type="hidden" name="postback" value="postback" />
                            <input type="hidden" name="configured" value="1" />

                            <table class="editTable" width="700">
                                <tr id="fromAddressRow">
                                    <td class="tdVertical" style="width: 175px;">
                                        <label for="fromAddress" id="fromAddressLabel">From E-Mail Address for Outgoing Messages:</label>
                                    </td>
                                    <td class="tdData">
                                        <input type="text" class="inputbox" name="fromAddress" id="fromAddress" value="<?php $this->_($this->mailerSettingsRS['fromAddress']); ?>" style="width: 180px;" />
                                    </td>
                                </tr>
                                <tr>
                                    <td class="tdVertical" style="width: 175px;">&nbsp;</td>
                                    <td class="tdData">&nbsp;</td>
Exemplo n.º 23
0
                                <?php endif; ?>
                            </span>
                        </td>
                    </tr>


                    <tr>
                        <td>
                            <label id="groupingLabel" for="grouping">Grouping:</label>&nbsp;
                        </td>
                        <td>
                            <input type="checkbox" class="inputbox" id="grouping" name="grouping" <?php echo $this->checked; ?> />&nbsp;*
                        </td>
                    </tr>

                    <tr>
                        <td colspan="2">
                            <br />
                            <input type="submit" class="button" id="butGrouping" name="butGrouping" value="Grouping" />
                            <input type="reset"  class="button" id="reset"          name="reset"          value="Reset" />
                            <input type="button" name="back" class = "button" value="Back" onclick="document.location.href='<?php echo(CATSUtility::getIndexName()); ?>?m=settings';" />
                       </td>
                    </tr>
                </table>
            </form>

        </div>
    <?php 
$AUIEO_CONTENT=ob_get_clean();
			?>
Exemplo n.º 24
0
 public function __construct()
 {
     $this->_indexName = CATSUtility::getIndexName();
     $this->_indexURL = CATSUtility::getAbsoluteURI($this->_indexName);
     parent::__construct();
 }
Exemplo n.º 25
0
    public function __construct($instanceName, $siteID, $parameters, $misc = 0)
    {
        $this->_db = DatabaseConnection::getInstance();
        $this->_siteID = $siteID;
        $this->_assignedCriterion = "";
        $this->_dataItemIDColumn = 'candidate.candidate_id';
        $this->_classColumns = array('Attachments' => array('select' => 'IF(candidate_joborder_submitted.candidate_joborder_id, 1, 0) AS submitted,
                                                IF(attachment_id, 1, 0) AS attachmentPresent', 'pagerRender' => 'if ($rsData[\'submitted\'] == 1)
                                                    {
                                                        $return = \'<img src="images/job_orders.gif" alt="" width="16" height="16" title="Submitted for a Job Order" />\';
                                                    }
                                                    else
                                                    {
                                                        $return = \'<img src="images/mru/blank.gif" alt="" width="16" height="16" />\';
                                                    }

                                                    if ($rsData[\'attachmentPresent\'] == 1)
                                                    {
                                                        $return .= \'<img src="images/paperclip.gif" alt="" width="16" height="16" title="Attachment Present" />\';
                                                    }
                                                    else
                                                    {
                                                        $return .= \'<img src="images/mru/blank.gif" alt="" width="16" height="16" />\';
                                                    }

                                                    return $return;
                                                   ', 'join' => 'LEFT JOIN attachment
                                                        ON candidate.candidate_id = attachment.data_item_id
														AND attachment.data_item_type = ' . DATA_ITEM_CANDIDATE . '
                                                    LEFT JOIN candidate_joborder AS candidate_joborder_submitted
                                                        ON candidate_joborder_submitted.candidate_id = candidate.candidate_id
                                                        AND candidate_joborder_submitted.status >= ' . PIPELINE_STATUS_SUBMITTED . '
                                                        AND candidate_joborder_submitted.site_id = ' . $this->_siteID . '
                                                        AND candidate_joborder_submitted.status != ' . PIPELINE_STATUS_NOTINCONSIDERATION, 'pagerWidth' => 34, 'pagerOptional' => true, 'pagerNoTitle' => true, 'sizable' => false, 'exportable' => false, 'filterable' => false), 'First Name' => array('select' => 'candidate.first_name AS firstName', 'pagerRender' => 'if ($rsData[\'isHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; return \'<a href="' . CATSUtility::getIndexName() . '?m=candidates&amp;a=show&amp;candidateID=\'.$rsData[\'candidateID\'].\'" class="\'.$className.\'">\'.htmlspecialchars($rsData[\'firstName\']).\'</a>\';', 'sortableColumn' => 'firstName', 'pagerWidth' => 75, 'pagerOptional' => false, 'alphaNavigation' => true, 'filter' => 'candidate.first_name'), 'Last Name' => array('select' => 'candidate.last_name AS lastName', 'sortableColumn' => 'lastName', 'pagerRender' => 'if ($rsData[\'isHot\'] == 1) $className =  \'jobLinkHot\'; else $className = \'jobLinkCold\'; return \'<a href="' . CATSUtility::getIndexName() . '?m=candidates&amp;a=show&amp;candidateID=\'.$rsData[\'candidateID\'].\'" class="\'.$className.\'">\'.htmlspecialchars($rsData[\'lastName\']).\'</a>\';', 'pagerWidth' => 85, 'pagerOptional' => false, 'alphaNavigation' => true, 'filter' => 'candidate.last_name'), 'E-Mail' => array('select' => 'candidate.email1 AS email1', 'sortableColumn' => 'email1', 'pagerWidth' => 80, 'filter' => 'candidate.email1'), '2nd E-Mail' => array('select' => 'candidate.email2 AS email2', 'sortableColumn' => 'email2', 'pagerWidth' => 80, 'filter' => 'candidate.email2'), 'Home Phone' => array('select' => 'candidate.phone_home AS phoneHome', 'sortableColumn' => 'phoneHome', 'pagerWidth' => 80, 'filter' => 'candidate.phone_home'), 'Cell Phone' => array('select' => 'candidate.phone_cell AS phoneCell', 'sortableColumn' => 'phoneCell', 'pagerWidth' => 80, 'filter' => 'candidate.phone_cell'), 'Work Phone' => array('select' => 'candidate.phone_work AS phoneWork', 'sortableColumn' => 'phoneWork', 'pagerWidth' => 80), 'Address' => array('select' => 'candidate.address AS address', 'sortableColumn' => 'address', 'pagerWidth' => 250, 'alphaNavigation' => true, 'filter' => 'candidate.address'), 'City' => array('select' => 'candidate.city AS city', 'sortableColumn' => 'city', 'pagerWidth' => 80, 'alphaNavigation' => true, 'filter' => 'candidate.city'), 'State' => array('select' => 'candidate.state AS state', 'sortableColumn' => 'state', 'filterType' => 'dropDown', 'pagerWidth' => 50, 'alphaNavigation' => true, 'filter' => 'candidate.state'), 'Zip' => array('select' => 'candidate.zip AS zip', 'sortableColumn' => 'zip', 'pagerWidth' => 50, 'filter' => 'candidate.zip'), 'Misc Notes' => array('select' => 'candidate.notes AS notes', 'sortableColumn' => 'notes', 'pagerWidth' => 300, 'filter' => 'candidate.notes'), 'Web Site' => array('select' => 'candidate.web_site AS webSite', 'pagerRender' => 'return \'<a href="\'.htmlspecialchars($rsData[\'webSite\']).\'">\'.htmlspecialchars($rsData[\'webSite\']).\'</a>\';', 'sortableColumn' => 'webSite', 'pagerWidth' => 80, 'filter' => 'candidate.web_site'), 'Key Skills' => array('select' => 'candidate.key_skills AS keySkills', 'pagerRender' => 'return substr(trim($rsData[\'keySkills\']), 0, 30) . (strlen(trim($rsData[\'keySkills\'])) > 30 ? \'...\' : \'\');', 'sortableColumn' => 'keySkills', 'pagerWidth' => 210, 'filter' => 'candidate.key_skills'), 'Recent Status' => array('select' => '(
                                                    SELECT
                                                        CONCAT(
                                                            \'<a href="' . CATSUtility::getIndexName() . '?m=joborders&amp;a=show&amp;jobOrderID=\',
                                                            joborder.joborder_id,
                                                            \'" title="\',
                                                            joborder.title,
                                                            \' (\',
                                                            company.name,
                                                            \')">\',
                                                            candidate_joborder_status.short_description,
                                                            \'</a>\'
                                                        )
                                                    FROM
                                                        candidate_joborder
                                                    LEFT JOIN candidate_joborder_status
                                                        ON candidate_joborder_status.candidate_joborder_status_id = candidate_joborder.status
                                                    LEFT JOIN joborder
                                                        ON joborder.joborder_id = candidate_joborder.joborder_id
                                                    LEFT JOIN company
                                                        ON joborder.company_id = company.company_id
                                                    WHERE
                                                        candidate_joborder.candidate_id = candidate.candidate_id
                                                    ORDER BY
                                                        candidate_joborder.date_modified DESC
                                                    LIMIT 1
                                                ) AS lastStatus
                                                ', 'sort' => 'lastStatus', 'pagerRender' => 'return $rsData[\'lastStatus\'];', 'exportRender' => 'return $rsData[\'lastStatus\'];', 'pagerWidth' => 140, 'exportable' => false, 'filterHaving' => 'lastStatus', 'filterTypes' => '=~'), 'Recent Status (Extended)' => array('select' => '(
                                                    SELECT
                                                        CONCAT(
                                                            candidate_joborder_status.short_description,
                                                            \'<br />\',
                                                            \'<a href="' . CATSUtility::getIndexName() . '?m=companies&amp;a=show&amp;companyID=\',
                                                            company.company_id,
                                                            \'">\',
                                                            company.name,
                                                            \'</a> - \',
                                                            \'<a href="' . CATSUtility::getIndexName() . '?m=joborders&amp;a=show&amp;jobOrderID=\',
                                                            joborder.joborder_id,
                                                            \'">\',
                                                            joborder.title,
                                                            \'</a>\'
                                                        )
                                                    FROM
                                                        candidate_joborder
                                                    LEFT JOIN candidate_joborder_status
                                                        ON candidate_joborder_status.candidate_joborder_status_id = candidate_joborder.status
                                                    LEFT JOIN joborder
                                                        ON joborder.joborder_id = candidate_joborder.joborder_id
                                                    LEFT JOIN company
                                                        ON joborder.company_id = company.company_id
                                                    WHERE
                                                        candidate_joborder.candidate_id = candidate.candidate_id
                                                    ORDER BY
                                                        candidate_joborder.date_modified DESC
                                                    LIMIT 1
                                                ) AS lastStatusLong
                                                ', 'sortableColumn' => 'lastStatusLong', 'pagerRender' => 'return $rsData[\'lastStatusLong\'];', 'pagerWidth' => 310, 'exportable' => false, 'filterable' => false), 'Source' => array('select' => 'candidate.source AS source', 'sortableColumn' => 'source', 'pagerWidth' => 140, 'alphaNavigation' => true, 'filter' => 'candidate.source'), 'Available' => array('select' => 'DATE_FORMAT(candidate.date_available, \'%m-%d-%y\') AS dateAvailable', 'sortableColumn' => 'dateAvailable', 'pagerWidth' => 60), 'Current Employer' => array('select' => 'candidate.current_employer AS currentEmployer', 'sortableColumn' => 'currentEmployer', 'pagerWidth' => 125, 'alphaNavigation' => true, 'filter' => 'candidate.current_employer'), 'Current Pay' => array('select' => 'candidate.current_pay AS currentPay', 'sortableColumn' => 'currentPay', 'pagerWidth' => 125, 'filter' => 'candidate.current_pay', 'filterTypes' => '===>=<'), 'Desired Pay' => array('select' => 'candidate.desired_pay AS desiredPay', 'sortableColumn' => 'desiredPay', 'pagerWidth' => 125, 'filter' => 'candidate.desired_pay', 'filterTypes' => '===>=<'), 'Can Relocate' => array('select' => 'candidate.can_relocate AS canRelocate', 'pagerRender' => 'return ($rsData[\'canRelocate\'] == 0 ? \'No\' : \'Yes\');', 'exportRender' => 'return ($rsData[\'canRelocate\'] == 0 ? \'No\' : \'Yes\');', 'sortableColumn' => 'canRelocate', 'pagerWidth' => 80, 'filter' => 'candidate.can_relocate'), 'Owner' => array('select' => 'owner_user.first_name AS ownerFirstName,' . 'owner_user.last_name AS ownerLastName,' . 'CONCAT(owner_user.last_name, owner_user.first_name) AS ownerSort', 'join' => 'LEFT JOIN user AS owner_user ON candidate.owner = owner_user.user_id', 'pagerRender' => 'return StringUtility::makeInitialName($rsData[\'ownerFirstName\'], $rsData[\'ownerLastName\'], false, LAST_NAME_MAXLEN);', 'exportRender' => 'return $rsData[\'ownerFirstName\'] . " " .$rsData[\'ownerLastName\'];', 'sortableColumn' => 'ownerSort', 'pagerWidth' => 75, 'alphaNavigation' => true, 'filter' => 'CONCAT(owner_user.first_name, owner_user.last_name)'), 'Created' => array('select' => 'DATE_FORMAT(candidate.date_created, \'%m-%d-%y\') AS dateCreated', 'pagerRender' => 'return $rsData[\'dateCreated\'];', 'sortableColumn' => 'dateCreatedSort', 'pagerWidth' => 60, 'filterHaving' => 'DATE_FORMAT(candidate.date_created, \'%m-%d-%y\')'), 'Modified' => array('select' => 'DATE_FORMAT(candidate.date_modified, \'%m-%d-%y\') AS dateModified', 'pagerRender' => 'return $rsData[\'dateModified\'];', 'sortableColumn' => 'dateModifiedSort', 'pagerWidth' => 60, 'pagerOptional' => false, 'filterHaving' => 'DATE_FORMAT(candidate.date_modified, \'%m-%d-%y\')'), 'Added To List' => array('select' => 'DATE_FORMAT(saved_list_entry.date_created, \'%m-%d-%y\') AS dateAddedToList,
                                                     saved_list_entry.date_created AS dateAddedToListSort', 'pagerRender' => 'return $rsData[\'dateAddedToList\'];', 'sortableColumn' => 'dateAddedToListSort', 'pagerWidth' => 60, 'pagerOptional' => false, 'filterable' => false, 'exportable' => false), 'OwnerID' => array('select' => '', 'filter' => 'candidate.owner', 'pagerOptional' => false, 'filterable' => false, 'filterDescription' => 'Only My Candidates'), 'IsHot' => array('select' => '', 'filter' => 'candidate.is_hot', 'pagerOptional' => false, 'filterable' => false, 'filterDescription' => 'Only Hot Candidates'));
        if (US_ZIPS_ENABLED) {
            $this->_classColumns['Near Zipcode'] = array('select' => 'candidate.zip AS zip', 'filter' => 'candidate.zip', 'pagerOptional' => false, 'filterTypes' => '=@');
        }
        /* Extra fields get added as columns here. */
        $candidates = new Candidates($this->_siteID);
        $extraFieldsRS = $candidates->extraFields->getSettings();
        foreach ($extraFieldsRS as $index => $data) {
            $fieldName = $data['fieldName'];
            if (!isset($this->_classColumns[$fieldName])) {
                $columnDefinition = $candidates->extraFields->getDataGridDefinition($index, $data, $this->_db);
                /* Return false for extra fields that should not be columns. */
                if ($columnDefinition !== false) {
                    $this->_classColumns[$fieldName] = $columnDefinition;
                }
            }
        }
        parent::__construct($instanceName, $parameters, $misc);
    }
Exemplo n.º 26
0
                                    <tr>
                                        <td style="border-bottom: 1px solid #c0c0c0; font-weight: bold; padding-right: 10px;">Title (Internal)</td>
                                        <td style="border-bottom: 1px solid #c0c0c0; font-weight: bold; padding-right: 10px;">Completed</td>
                                        <td style="border-bottom: 1px solid #c0c0c0; font-weight: bold; padding-right: 10px;">Description (Public)</td>
                                    </tr>
                                    <?php foreach ($this->questionnaires as $questionnaire): ?>
                                    <tr>
                                        <td style="padding-right: 10px;" nowrap="nowrap"><a href="<?php echo(CATSUtility::getIndexName()); ?>?m=candidates&a=show_questionnaire&candidateID=<?php echo($this->candidateID); ?>&questionnaireTitle=<?php echo urlencode($questionnaire['questionnaireTitle']); ?>&print=no"><?php echo $questionnaire['questionnaireTitle']; ?></a></td>
                                        <td style="padding-right: 10px;" nowrap="nowrap"><?php echo date('F j. Y', strtotime($questionnaire['questionnaireDate'])); ?></td>
                                        <td style="padding-right: 10px;" nowrap="nowrap"><?php echo $questionnaire['questionnaireDescription']; ?></td>
                                        <td style="padding-right: 10px;" nowrap="nowrap">
                                            <a id="edit_link" href="<?php echo(CATSUtility::getIndexName()); ?>?m=candidates&a=show_questionnaire&candidateID=<?php echo($this->candidateID); ?>&questionnaireTitle=<?php echo urlencode($questionnaire['questionnaireTitle']); ?>&print=no">
                                                <img src="images/actions/view.gif" width="16" height="16" class="absmiddle" alt="view" border="0" />&nbsp;View
                                            </a>
                                            &nbsp;
                                            <a id="edit_link" href="<?php echo(CATSUtility::getIndexName()); ?>?m=candidates&a=show_questionnaire&candidateID=<?php echo($this->candidateID); ?>&questionnaireTitle=<?php echo urlencode($questionnaire['questionnaireTitle']); ?>&print=yes">
                                                <img src="images/actions/print.gif" width="16" height="16" class="absmiddle" alt="print" border="0" />&nbsp;Print
                                            </a>
                                        </td>
                                    </tr>
                                    <?php endforeach; ?>
                                    </table>
                                </td>
                            </tr>
                            <?php endif; ?>

                            <tr>
                                <td valign="top" class="vertical">Attachments:</td>
                                <td valign="top" class="data">
                                    <table class="attachmentsTable">
                                        <?php foreach ($this->attachmentsRS as $rowNumber => $attachmentsData):
Exemplo n.º 27
0
                </tr>
            </table>
        </td>
    </tr>
</table>
<br clear="all" />
<br />

<p class="note">Candidate Pipeline</p>

<p id="ajaxPipelineControl">
    Number of visible entries:&nbsp;&nbsp;
    <select id="numberOfEntriesSelect" onchange="PipelineJobOrder_changeLimit(<?php $this->_($this->data['jobOrderID']); ?>, this.value, <?php echo(1); ?>, 'ajaxPipelineTable', '<?php echo($this->sessionCookie); ?>', 'ajaxPipelineTableIndicator', '<?php echo(CATSUtility::getIndexName()); ?>');" class="selectBox">
        <option value="15" <?php if ($this->pipelineEntriesPerPage == 15): ?>selected<?php endif; ?>>15 entries</option>
        <option value="30" <?php if ($this->pipelineEntriesPerPage == 30): ?>selected<?php endif; ?>>30 entries</option>
        <option value="50" <?php if ($this->pipelineEntriesPerPage == 50): ?>selected<?php endif; ?>>50 entries</option>
        <option value="99999" <?php if ($this->pipelineEntriesPerPage == 99999): ?>selected<?php endif; ?>>All entries</option>
    </select>&nbsp;
    <span id="ajaxPipelineNavigation">
    </span>&nbsp;
    <img src="images/indicator.gif" alt="" id="ajaxPipelineTableIndicator" />
</p>

<div id="ajaxPipelineTable">
</div>
<script type="text/javascript">
    PipelineJobOrder_populate(<?php $this->_($this->data['jobOrderID']); ?>, 0, <?php $this->_($this->pipelineEntriesPerPage); ?>, 'dateCreatedInt', 'desc', <?php echo(1); ?>, 'ajaxPipelineTable', '<?php echo($this->sessionCookie); ?>', 'ajaxPipelineTableIndicator', '<?php echo(CATSUtility::getIndexName()); ?>');
</script>
    
<?php $AUIEO_CONTENT=ob_get_clean(); ?>
Exemplo n.º 28
0
     $_SESSION['CATS']->logout();
     unset($_SESSION['CATS']);
     unset($_SESSION['modules']);
     $URI = 'm=login';
     /* Local demo account doesn't relogin. */
     if (!empty($unixName) && $unixName != 'demo') {
         $URI .= '&s=' . $unixName;
     }
     if (isset($_GET['message'])) {
         $URI .= '&message=' . urlencode($_GET['message']);
     }
     if (isset($_GET['messageSuccess'])) {
         $URI .= '&messageSuccess=' . urlencode($_GET['messageSuccess']);
     }
     /* catsone.com demo domain doesn't relogin. */
     if (strpos(CATSUtility::getIndexName(), '://demo.catsone.com') !== false) {
         CATSUtility::transferURL('http://www.catsone.com');
     } else {
         CATSUtility::transferRelativeURI($URI);
     }
 } else {
     if (!ModuleUtility::moduleRequiresAuthentication($_GET['m'])) {
         /* No authentication required; load the module. */
         ModuleUtility::loadModule($_GET['m']);
     } else {
         if (!$_SESSION['CATS']->isLoggedIn()) {
             /* User isn't logged in and authentication is required; send the user
              * to the login page.
              */
             ModuleUtility::loadModule('login');
         } else {
Exemplo n.º 29
0
 /**
  * Transfers, via a Location: header, the "absolute" version of a URI that
  * is relative to index.php?.
  *
  * @param string Relative URI.
  * @return void
  */
 public static function transferRelativeURI($relativePath)
 {
     $newLocation = self::getAbsoluteURI(CATSUtility::getIndexName() . '?' . $relativePath);
     self::transferURL($newLocation);
 }
Exemplo n.º 30
0
                </a>&nbsp;&nbsp;&nbsp;&nbsp;
                <a id="history_link" href="<?php echo(CATSUtility::getIndexName()); ?>?m=settings&a=transfer&dataItemType=100&dataItemID=<?php echo($this->candidateID); ?>">
                    Transfer
                </a>&nbsp;&nbsp;&nbsp;&nbsp;
                <a id="history_link" href="<?php echo(CATSUtility::getIndexName()); ?>?m=settings&a=duplicate&dataItemType=100&dataItemID=<?php echo($this->candidateID); ?>">
                    Copy
                </a>&nbsp;&nbsp;&nbsp;&nbsp;
<?php 
    } 
    if ($this->accessLevel >= ACCESS_LEVEL_MULTI_SA){ ?>
                <?php if ($this->data['is_admin_hidden'] == 1){ ?>
                    <a href="<?php echo(CATSUtility::getIndexName()); ?>?m=candidates&a=administrativeHideShow&candidateID=<?php echo($this->candidateID); ?>&state=0">
                        <img src="images/resume_preview_inline.gif" width="16" height="16" class="absmiddle" alt="delete" border="0" />&nbsp;Administrative Show
                    </a>
                    <?php }else{ ?>
                    <a href="<?php echo(CATSUtility::getIndexName()); ?>?m=candidates&a=administrativeHideShow&candidateID=<?php echo($this->candidateID); ?>&state=1">
                        <img src="images/resume_preview_inline.gif" width="16" height="16" class="absmiddle" alt="delete" border="0" />&nbsp;Administrative Hide
                    </a>
                <?php } ?>
                &nbsp;&nbsp;&nbsp;&nbsp;
            <?php } ?>
                
                <br clear="all" />
            <br />
            <p class="note">Emails <span style="float:right;"><a href="index.php?m=candidates&a=emailCandidates&idlist=<?php echo $this->candidateID; ?>">Send Email</a></span></p>
            <table class="sortablepair">
                <tr>
                    <th align="left">Date</th>
                    <th align="left">Subject</th>
                    <th align="left">From</th>
                    <th align="left">To</th>