affIndex.php 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <?php
  2. /* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
  3. * Copyright (C) 2008-2010 Laurent Destailleur <eldy@uers.sourceforge.net>
  4. * Copyright (C) 2009 Regis Houssin <regis.houssin@inodbox.com>
  5. * Copyright (C) 2011 Juanjo Menent <jmenent@2byte.es>
  6. *
  7. * This program is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License as published by
  9. * the Free Software Foundation; either version 3 of the License, or
  10. * (at your option) any later version.
  11. *
  12. * This program is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. * GNU General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU General Public License
  18. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  19. */
  20. /**
  21. * \file htdocs/cashdesk/affIndex.php
  22. * \ingroup cashdesk
  23. * \brief First page of point of sale module
  24. */
  25. require '../main.inc.php';
  26. require_once DOL_DOCUMENT_ROOT.'/cashdesk/include/environnement.php';
  27. require_once DOL_DOCUMENT_ROOT.'/cashdesk/include/keypad.php';
  28. $error=GETPOST('error');
  29. // Test if already logged
  30. if ( $_SESSION['uid'] <= 0 )
  31. {
  32. header('Location: index.php');
  33. exit;
  34. }
  35. // Load translation files required by the page
  36. $langs->loadLangs(array("companies","compta","cashdesk"));
  37. /*
  38. * View
  39. */
  40. $form = new Form($db);
  41. $arrayofjs=array();
  42. $arrayofcss=array('/cashdesk/css/style.css');
  43. top_htmlhead($head,$langs->trans("CashDesk"),0,0,$arrayofjs,$arrayofcss);
  44. print '<body>'."\n";
  45. if (!empty($error))
  46. {
  47. dol_htmloutput_events();
  48. }
  49. print '<div class="conteneur">'."\n";
  50. print '<div class="conteneur_img_gauche">'."\n";
  51. print '<div class="conteneur_img_droite">'."\n";
  52. print '<div class="menu_principal">'."\n";
  53. include_once 'tpl/menu.tpl.php';
  54. print '</div>'."\n";
  55. print '<div class="contenu">'."\n";
  56. include_once 'affContenu.php';
  57. print '</div>'."\n";
  58. include_once 'affPied.php';
  59. print '</div></div></div>'."\n";
  60. print '</body></html>'."\n";