info.php 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. <?php
  2. /* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro>
  3. *
  4. * This program is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License as published by
  6. * the Free Software Foundation; either version 3 of the License, or
  7. * (at your option) any later version.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License
  15. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  16. */
  17. /**
  18. * \file htdocs/cron/info.php
  19. * \brief Page of info of a cron job
  20. */
  21. require '../main.inc.php';
  22. require_once DOL_DOCUMENT_ROOT."/cron/class/cronjob.class.php";
  23. require_once DOL_DOCUMENT_ROOT.'/core/lib/cron.lib.php';
  24. require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
  25. // Load translation files required by the page
  26. $langs->loadLangs(array('admin', 'cron'));
  27. // Security check
  28. if (!$user->rights->cron->read) accessforbidden();
  29. $id=GETPOST('id','int');
  30. $mesg = '';
  31. /*
  32. * View
  33. */
  34. llxHeader('',$langs->trans("CronInfo"));
  35. $object = new Cronjob($db);
  36. $object->fetch($id);
  37. $object->info($id);
  38. $head = cron_prepare_head($object);
  39. dol_fiche_head($head, 'info', $langs->trans("CronTask"), -1, 'cron');
  40. $linkback = '<a href="' . DOL_URL_ROOT . '/cron/list.php?status=-2&restore_lastsearch_values=1">' . $langs->trans("BackToList") . '</a>';
  41. $morehtmlref='<div class="refidno">';
  42. $morehtmlref.='</div>';
  43. dol_banner_tab($object, 'id', $linkback, 1, 'rowid', 'ref', $morehtmlref);
  44. print '<div class="underbanner clearboth"></div>';
  45. print '<br>';
  46. print '<table width="100%"><tr><td>';
  47. dol_print_object_info($object);
  48. print '</td></tr></table>';
  49. print '</div>';
  50. llxFooter();
  51. $db->close();