public function breadcrumbTitle($depth) { if ($depth == 0) { return $this->config->getTitle(); } $subgridConfig = $this->config->subgridConfig($this->statusVariables, $depth); $id = $this->statusVariables['gridParentId' . $depth]; $title = ipDb()->fetchValue("SELECT " . $subgridConfig->tableName() . ".`" . $subgridConfig->getBreadcrumbField() . "` FROM " . $subgridConfig->tableName() . " " . $this->joinQuery() . " WHERE " . $subgridConfig->tableName() . '.`' . $subgridConfig->idField() . '` = ' . ipDb()->getConnection()->quote($id) . " "); return $title; }
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . ' - Delete Contact'); $act = Tools::Param('act'); if ("Delete Contact" === $act) { $contactModel = new ContactModel(); $contactModel->populateFromForm(); if (!$contactModel->validateForDelete()) { $contactView = new ContactFormView('Delete Contact', $contactModel); $body = "<h2>Invalid data</h2>\n" . $contactView->getForm(); } else { $contactController = new ContactController(); $contactController->delete($contactModel); $body = "Deleted contact # " . $contactModel->getId() . "<br />\n"; } } else { $contactController = new ContactController(); $contactModel = $contactController->get(Tools::param('id'));
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . ' - Delete Note'); $act = Tools::Param('act'); if ("Delete Note" === $act) { $noteModel = new NoteModel(); $noteModel->populateFromForm(); if (!$noteModel->validateForDelete()) { $noteView = new NoteFormView('Delete Note', $noteModel); $body = "<h2>Invalid data</h2>\n" . $noteView->getForm(); } else { $noteController = new NoteController(); $noteController->delete($noteModel); $body = "Deleted note # " . $noteModel->getId() . "<br />\n"; } } else { $noteController = new NoteController(); $noteModel = $noteController->get(Tools::param('id'));
/** * phpjobseeker * * Copyright (C) 2009, 2015 Kevin Benton - kbenton at bentonfam dot org * * This program 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. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $page = new PJSWebPage($config->getTitle() . ' - Application Statuses'); $body = "<h2>Application Statuses</h2>"; $asc = new ApplicationStatusController('read'); $asmList = $asc->getAll(); $asv = new ApplicationStatusListView('html', $asmList); $body .= $asv->getView(); $page->setBody($body); $page->displayPage();
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . "Notes - Add Note"); $body = ''; $act = Tools::Param('act'); if ("Add Note" === $act) { $model = new NoteModel(); $model->populateFromForm(); if (!$model->validateForAdd()) { $view = new NoteFormView('Add Note', $model); $body = "<h2>Invalid data</h2>\n" . $view->getForm(); } else { $noteController = new NoteController(); $newId = $noteController->add($model); if ($newId > 0) { $body = "Added note # " . $newId . "<br />\n"; } }
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . ' - Edit Search'); $act = Tools::Param('act'); if ("Edit Search" === $act) { $searchModel = new SearchModel(); $searchModel->populateFromForm(); if (!$searchModel->validateForUpdate()) { $view = new SearchFormView('Edit Search', $searchModel); $body = "<h2>Invalid data</h2>\n" . $view->getForm(); } else { $searchController = new SearchController(); $newId = $searchController->update($searchModel); if ($newId > 0) { $body = "Edited search: " . $searchModel->getSearchName() . " as # " . $newId . "<br />\n"; } } } else {
<?php /** * phpjobseeker * * Copyright (C) 2009, 2015 Kevin Benton - kbenton at bentonfam dot org * * This program 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. * * This program 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. * */ require_once 'Libs/autoload.php'; $config = new Config(); $page = new PJSWebPage($config->getTitle() . " - Keywords"); $body = "<h2>Keywords</h2>\n<div>Not yet written.<div>"; $page->setBody($body); $page->displayPage();
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . ' - Edit Contact'); $act = Tools::Param('act'); if ("Edit Contact" === $act) { $contactModel = new ContactModel(); $contactModel->populateFromForm(); if (!$contactModel->validateForUpdate()) { $view = new ContactFormView('Edit Contact', $contactModel); $body = "<h2>Invalid data</h2>\n" . $view->getForm(); } else { $contactController = new ContactController(); $newId = $contactController->update($contactModel); if ($newId > 0) { $body = "Edited contact # " . $newId . "<br />\n"; } } } else {
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . "Searches - Add Search"); $body = ''; $act = Tools::Param('act'); if ("Add Search" === $act) { $model = new SearchModel(); $model->populateFromForm(); if (!$model->validateForAdd()) { $view = new SearchFormView('Add Search', $model); $body = "<h2>Invalid data</h2>\n" . $view->getForm(); } else { $searchController = new SearchController(); $newId = $searchController->add($model); if ($newId > 0) { $body = "Added search # " . $newId . "<br />\n"; } }
/** * phpjobseeker * * Copyright (C) 2009, 2015 Kevin Benton - kbenton at bentonfam dot org * * This program 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. * * This program 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. * */ require_once 'Libs/autoload.php'; $config = new Config(); $page = new PJSWebPage($config->getTitle() . " - Searches"); $body = "<h2>Searches</h2>\n"; $searchController = new SearchController('read'); $searchModelList = $searchController->getAll(); $searchListView = new SearchListView('html', $searchModelList); $body .= $searchListView->getView(); $page->setBody($body); $page->displayPage();
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . ' - Edit Note'); $act = Tools::Param('act'); if ("Edit Note" === $act) { $noteModel = new NoteModel(); $noteModel->populateFromForm(); if (!$noteModel->validateForUpdate()) { $view = new NoteFormView('Edit Note', $noteModel); $body = "<h2>Invalid data</h2>\n" . $view->getForm(); } else { $noteController = new NoteController(); $newId = $noteController->update($noteModel); if ($newId > 0) { $body = "Edited note # " . $newId . "<br />\n"; } } } else {
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . "Contacts - Add Contact"); $body = ''; $act = Tools::Param('act'); if ("Add Contact" === $act) { $model = new ContactModel(); $model->populateFromForm(); if (!$model->validateForAdd()) { $view = new ContactFormView('Add Contact', $model); $body = "<h2>Invalid data</h2>\n" . $view->getForm(); } else { $contactController = new ContactController(); $newId = $contactController->add($model); if ($newId > 0) { $body = "Added contact # " . $newId . "<br />\n"; } }
/** * phpjobseeker * * Copyright (C) 2009, 2015 Kevin Benton - kbenton at bentonfam dot org * * This program 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. * * This program 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. * */ require_once 'Libs/autoload.php'; $config = new Config(); $page = new PJSWebPage($config->getTitle() . " - Companies"); $body = "<h2>Companies</h2>\n"; $companyController = new CompanyController('read'); $companyModelList = $companyController->getAll(); $companyListView = new CompanyListView('html', $companyModelList); $body .= $companyListView->getView(); $page->setBody($body); $page->displayPage();
* phpjobseeker * * Copyright (C) 2009, 2015 Kevin Benton - kbenton at bentonfam dot org * * This program 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. * * This program 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. * */ require_once 'Libs/autoload.php'; // @todo Show application statuses in index page $config = new Config(); try { $dbc = new DBConnection(); } catch (DaoException $ex) { echo "Has this system been set up yet? Have you used resetDb.php?\n"; exit; } $config = new Config(); $page = new PJSWebPage($config->getTitle()); $page->displayPage();
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . ' - Delete Search'); $act = Tools::Param('act'); if ("Delete Search" === $act) { $searchModel = new SearchModel(); $searchModel->populateFromForm(); if (!$searchModel->validateForDelete()) { $searchView = new SearchFormView('Delete Search', $searchModel); $body = "<h2>Invalid data</h2>\n" . $searchView->getForm(); } else { $searchController = new SearchController(); $searchController->delete($searchModel); $body = "Deleted search # " . $searchModel->getId() . "<br />\n"; } } else { $searchController = new SearchController(); $searchModel = $searchController->get(Tools::param('id'));
* the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program 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. * */ require_once "Libs/autoload.php"; $config = new Config(); $webPage = new PJSWebPage($config->getTitle() . "Jobs - Add Job"); $body = ''; $act = Tools::Param('act'); if ("Add Job" === $act) { $model = new JobModel(); $model->populateFromForm(); if (!$model->validateForAdd()) { $view = new JobFormView('Add Job', $model); $body = "<h2>Invalid data</h2>\n" . $view->getForm(); } else { $jobController = new JobController(); $newId = $jobController->add($model); if ($newId > 0) { $body = "Added job # " . $newId . "<br />\n"; } }
* 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. * */ require_once 'Libs/autoload.php'; // Be sure to specify these in apply order. The reset script will automatically // reverse the order for safe removal. $controllerNames = array('VersionController', 'AuthTicketController', 'ApplicationStatusController', 'ApplicationStatusSummaryController', 'CompanyController', 'ContactController', 'JobController', 'KeywordController', 'NoteController', 'SearchController', 'JobKeywordMapController'); $controllers = array(); try { $config = new Config(); $page = new PJSWebPage($config->getTitle() . " - Reset DB", true); $body = "<ul>\n"; $dbc = new DBConnection("admin", null, null, null, null, null, 'mysqli', true); if (!$dbc->getCreatedDb()) { // Database exists. Don't allow reset if the user is not logged in. $auth = new Auth(); if (!$auth->isAuthorized()) { throw new Exception("User must be logged in to reset the database!"); } if ("1" !== $config->getResetOk()) { throw new Exception("Reset capability is turned off! See config.xml"); } } $dbh = $dbc->getConnection(); foreach (array_reverse($controllerNames) as $controllerName) { $controller = new $controllerName('write');
/** * phpjobseeker * * Copyright (C) 2009, 2015 Kevin Benton - kbenton at bentonfam dot org * * This program 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. * * This program 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. * */ require_once 'Libs/autoload.php'; $config = new Config(); $page = new PJSWebPage($config->getTitle() . " - Jobs"); $body = "<h2>Jobs</h2>\n"; $controller = new JobController('read'); $modelList = $controller->getAll(); $modelListView = new JobListView('html', $modelList); $body .= $modelListView->getView(); $page->setBody($body); $page->displayPage();