diff --git a/htdocs/compta/tva/clients.php b/htdocs/compta/tva/clients.php
index 5cff8a4b94d..e0a863a4f28 100644
--- a/htdocs/compta/tva/clients.php
+++ b/htdocs/compta/tva/clients.php
@@ -118,6 +118,11 @@ foreach($listofparams as $param) {
}
}
+$special_report = false;
+if (isset($_REQUEST['extra_report']) && $_REQUEST['extra_report'] == 1) {
+ $special_report = true;
+}
+
llxHeader('','','','',0,0,'','',$morequerystring);
$fsearch.=' ';
@@ -145,6 +150,15 @@ if ($modetax==1) { // Calculate on invoice for goods and services
$description.=' '.$langs->trans("DepositsAreIncluded");
}
$description.=$fsearch;
+ $description.=' '
+ . ' '
+ . $langs->trans('SimpleReport')
+ . ''
+ . ' '
+ . ' '
+ . $langs->trans('AddExtraReport')
+ . ''
+ . ' ';
$builddate=time();
//$exportlink=$langs->trans("NotYetAvailable");
@@ -180,6 +194,15 @@ if ($modetax==0) { // Invoice for goods, payment for services
//if ($conf->global->MAIN_MODULE_COMPTABILITE || $conf->global->MAIN_MODULE_ACCOUNTING) $description.=' '.img_warning().' '.$langs->trans('OptionVatInfoModuleComptabilite');
//if (! empty($conf->global->MAIN_MODULE_COMPTABILITE)) $description.=' '.$langs->trans("WarningDepositsNotIncluded");
$description.=$fsearch;
+ $description.=' '
+ . ' '
+ . $langs->trans('SimpleReport')
+ . ''
+ . ' '
+ . ' '
+ . $langs->trans('AddExtraReport')
+ . ''
+ . ' ';
$builddate=time();
//$exportlink=$langs->trans("NotYetAvailable");
@@ -365,153 +388,164 @@ if (is_array($coll_list)) {
print '';
-// Get country 2-letters code
-global $mysoc;
-$country_id = $mysoc->country_id;
-$country = new Ccountry($db);
-$country->fetch($country_id);
+if ($special_report) {
+ // Get country 2-letters code
+ global $mysoc;
+ $country_id = $mysoc->country_id;
+ $country = new Ccountry($db);
+ $country->fetch($country_id);
-// Print listing of other-country customers as additional report
-// This matches tax requirements to list all same-country customers (only)
-print '
Other countries customers
';
-print 'Based on 2 first letters of VAT number being different from your company\'s country';
-$coll_list = vat_by_thirdparty($db,0,$date_start,$date_end,$modetax,'sell');
+ // Print listing of other-country customers as additional report
+ // This matches tax requirements to list all same-country customers (only)
+ print '
';
-
-// Print listing of same-country customers as additional report
-// This matches tax requirements to list all same-country customers (only)
-print '
Same country customers with VAT
';
-print 'Based on 2 first letters of VAT number being the same as your company\'s country';
-$coll_list = vat_by_thirdparty($db,0,$date_start,$date_end,$modetax,'sell');
-
-print "
';
+ // Print listing of same-country customers as additional report
+ // This matches tax requirements to list all same-country customers (only)
+ print '