info.php 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. <?php
  2. /* Copyright (C) 2016-2017 Alexandre Spangaro <aspangaro@zendsi.com>
  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/compta/tva/info.php
  19. * \ingroup tax
  20. * \brief Page with info about vat
  21. */
  22. require '../../main.inc.php';
  23. require_once DOL_DOCUMENT_ROOT.'/compta/tva/class/tva.class.php';
  24. require_once DOL_DOCUMENT_ROOT.'/core/lib/vat.lib.php';
  25. require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
  26. $langs->load("compta");
  27. $langs->load("bills");
  28. $id=GETPOST('id','int');
  29. $action=GETPOST('action','aZ09');
  30. // Security check
  31. $socid = GETPOST('socid','int');
  32. if ($user->societe_id) $socid=$user->societe_id;
  33. $result = restrictedArea($user, 'tax', '', '', 'charges');
  34. /*
  35. * View
  36. */
  37. $title=$langs->trans("VAT") . " - " . $langs->trans("Info");
  38. $help_url='';
  39. llxHeader("",$title,$helpurl);
  40. $object = new Tva($db);
  41. $object->fetch($id);
  42. $object->info($id);
  43. $head = vat_prepare_head($object);
  44. dol_fiche_head($head, 'info', $langs->trans("VATPayment"), 0, 'payment');
  45. $linkback = '<a href="'.DOL_URL_ROOT.'/compta/tva/reglement.php">'.$langs->trans("BackToList").'</a>';
  46. dol_banner_tab($object, 'id', $linkback, 1, 'rowid', 'ref', $morehtmlref, '', 0, '', '');
  47. print '<div class="fichecenter">';
  48. print '<div class="underbanner clearboth"></div>';
  49. print '<table width="100%"><tr><td>';
  50. dol_print_object_info($object);
  51. print '</td></tr></table>';
  52. print '</div>';
  53. dol_fiche_end();
  54. llxFooter();
  55. $db->close();