exit(-1); } $bankref = $argv[1]; $num = $argv[2]; $model = $argv[3]; $newlangid = 'en_EN'; // To force a new lang id $invoicestatic = new Facture($db); $invoicesupplierstatic = new FactureFournisseur($db); $societestatic = new Societe($db); $chargestatic = new ChargeSociales($db); $memberstatic = new Adherent($db); $paymentstatic = new Paiement($db); $paymentsupplierstatic = new PaiementFourn($db); $paymentsocialcontributionstatic = new PaymentSocialContribution($db); $paymentvatstatic = new Tva($db); $bankstatic = new Account($db); $banklinestatic = new AccountLine($db); // Parse parameters foreach ($argv as $key => $value) { $found = false; // Define options if (preg_match('/^lang=/i', $value)) { $found = true; $valarray = explode('=', $value); $newlangid = $valarray[1]; print 'Use language ' . $newlangid . ".\n"; } } $outputlangs = $langs; if (!empty($newlangid)) {
$page = $_GET["page"]; if ($page < 0) { $page = 0; } //$limit = $conf->liste_limit; //$offset = $limit * $page ; if (!$sortfield) { $sortfield = "cs.date_ech"; } if (!$sortorder) { $sortorder = "DESC"; } /* * View */ $tva_static = new Tva($db); $socialcontrib = new ChargeSociales($db); $payment_sc_static = new PaymentSocialContribution($db); $sal_static = new PaymentSalary($db); llxHeader('', $langs->trans("SpecialExpensesArea")); $title = $langs->trans("SpecialExpensesArea"); if ($_GET["mode"] == 'sconly') { $title = $langs->trans("SocialContributionsPayments"); } $param = ''; if (GETPOST("mode") == 'sconly') { $param = '&mode=sconly'; } if ($sortfield) { $param .= '&sortfield=' . $sortfield; }
*/ require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT . "/compta/tva/class/tva.class.php"; $langs->load("compta"); $langs->load("compta"); // Security check $socid = isset($_GET["socid"]) ? $_GET["socid"] : ''; if ($user->societe_id) { $socid = $user->societe_id; } $result = restrictedArea($user, 'tax', '', '', 'charges'); /* * View */ llxHeader(); $tva_static = new Tva($db); print_fiche_titre($langs->trans("VATPayments")); $sql = "SELECT rowid, amount, label, f.datev as dm"; $sql .= " FROM " . MAIN_DB_PREFIX . "tva as f "; $sql .= " WHERE f.entity = " . $conf->entity; $sql .= " ORDER BY dm DESC"; $result = $db->query($sql); if ($result) { $num = $db->num_rows($result); $i = 0; $total = 0; print '<table class="noborder" width="100%">'; print '<tr class="liste_titre">'; print '<td nowrap align="left">' . $langs->trans("Ref") . '</td>'; print "<td>" . $langs->trans("Label") . "</td>"; print '<td nowrap align="left">' . $langs->trans("DatePayment") . '</td>';
$langs->load("compta"); $langs->load("banks"); $langs->load("bills"); $id = GETPOST("id", 'int'); $action = GETPOST("action", "alpha"); $refund = GETPOST("refund", "int"); if (empty($refund)) { $refund = 0; } // Security check $socid = isset($_GET["socid"]) ? $_GET["socid"] : ''; if ($user->societe_id) { $socid = $user->societe_id; } $result = restrictedArea($user, 'tax', '', '', 'charges'); $tva = new Tva($db); // Initialize technical object to manage hooks of thirdparties. Note that conf->hooks_modules contains array array $hookmanager->initHooks(array('taxvatcard', 'globalcard')); /** * Actions */ if ($_POST["cancel"] == $langs->trans("Cancel")) { header("Location: reglement.php"); exit; } if ($action == 'add' && $_POST["cancel"] != $langs->trans("Cancel")) { $error = 0; $datev = dol_mktime(12, 0, 0, $_POST["datevmonth"], $_POST["datevday"], $_POST["datevyear"]); $datep = dol_mktime(12, 0, 0, $_POST["datepmonth"], $_POST["datepday"], $_POST["datepyear"]); $tva->accountid = GETPOST("accountid"); $tva->type_payment = GETPOST("type_payment");
$mesg='<div class="error">Error try do delete a line linked to a conciliated bank transaction</div>'; } } /* * View */ llxHeader(); $html = new Form($db); if ($id) { $vatpayment = new Tva($db); $result = $vatpayment->fetch($id); if ($result <= 0) { dol_print_error($db); exit; } } // Formulaire saisie tva if ($_GET["action"] == 'create') { print "<form name='add' action=\"fiche.php\" method=\"post\">\n"; print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">'; print '<input type="hidden" name="action" value="add">';