From 635894cf10bf2435371de8c78b475e8fdec62469 Mon Sep 17 00:00:00 2001 From: philippe grand Date: Thu, 20 Apr 2017 14:51:36 +0200 Subject: [PATCH 1/2] Update code using new css class --- htdocs/admin/agenda.php | 3 +-- htdocs/admin/agenda_other.php | 3 +-- htdocs/admin/bank.php | 4 +--- htdocs/admin/company.php | 33 ++++++++++++--------------------- htdocs/admin/compta.php | 10 ++++------ htdocs/admin/events.php | 2 +- htdocs/admin/fichinter.php | 8 ++------ 7 files changed, 22 insertions(+), 41 deletions(-) diff --git a/htdocs/admin/agenda.php b/htdocs/admin/agenda.php index d076fcf7e26..051179d61ca 100644 --- a/htdocs/admin/agenda.php +++ b/htdocs/admin/agenda.php @@ -150,7 +150,6 @@ print $langs->trans("AgendaAutoActionDesc")."
\n"; print $langs->trans("OnlyActiveElementsAreShown").'
'; print "
\n"; -$var=true; print ''; print ''; print ''; @@ -180,7 +179,7 @@ if (! empty($triggers)) print ''."\n"; } } diff --git a/htdocs/admin/agenda_other.php b/htdocs/admin/agenda_other.php index 6e0a62610aa..1e2247514d9 100644 --- a/htdocs/admin/agenda_other.php +++ b/htdocs/admin/agenda_other.php @@ -245,7 +245,6 @@ if ($conf->global->MAIN_FEATURES_LEVEL >= 2) clearstatcache(); - $var=true; foreach ($dirmodels as $reldir) { $dir = dol_buildpath($reldir."core/modules/action/doc/"); @@ -266,7 +265,7 @@ if ($conf->global->MAIN_FEATURES_LEVEL >= 2) $module = new $classname($db, new ActionComm($db)); - print "\n"; + print '\n'; print "\n"; diff --git a/htdocs/admin/bank.php b/htdocs/admin/bank.php index 98cecb2f44b..8ed1e3cd9ac 100644 --- a/htdocs/admin/bank.php +++ b/htdocs/admin/bank.php @@ -273,7 +273,6 @@ print "\n"; clearstatcache(); -$var = true; foreach ($dirmodels as $reldir) { foreach (array('', '/doc') as $valdir) { @@ -305,8 +304,7 @@ foreach ($dirmodels as $reldir) $modulequalified = 0; if ($modulequalified) { - $var = ! $var; - print ''; print ''; print "\n"; - $var=true; print ''; print ''; print "\n"; - $var=true; - print ""; + print ""; print '
'.$langs->trans("ActionsEvents").''; $key='MAIN_AGENDA_ACTIONAUTO_'.$trigger['code']; $value=$conf->global->$key; - print ''; + print ''; print '
"; print (empty($module->name)?$name:$module->name); print "
'; + print '
'; print(empty($module->name) ? $name : $module->name); print "\n"; if (method_exists($module, 'info')) diff --git a/htdocs/admin/company.php b/htdocs/admin/company.php index 8c29fe67a1c..94cc66fd755 100644 --- a/htdocs/admin/company.php +++ b/htdocs/admin/company.php @@ -545,7 +545,6 @@ if ($action == 'edit' || $action == 'updateedit') print '
'.$langs->trans("FiscalYearInformation").''.$langs->trans("Value").'
'; @@ -561,10 +560,9 @@ if ($action == 'edit' || $action == 'updateedit') print ''.$langs->trans("VATManagement").''.$langs->trans("Description").' 
'; print ""; print ""; @@ -573,7 +571,7 @@ if ($action == 'edit' || $action == 'updateedit') print "\n"; - print ""; + print ""; print '
'; print ""; print ""; @@ -595,10 +593,9 @@ if ($action == 'edit' || $action == 'updateedit') print ''; print ''; print "\n"; - $var=true; // Note: When option is not set, it must not appears as set on on, because there is no default value for this option - print ""; + print ""; print '
'.$langs->transcountry("LocalTax1Management",$mysoc->country_code).''.$langs->trans("Description").' 
global->FACTURE_LOCAL_TAX1_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1on")?" checked":"")."> ".$langs->transcountry("LocalTax1IsUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX1_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1on")?" checked":"")."> ".$langs->transcountry("LocalTax1IsUsed",$mysoc->country_code)."'; print ''; print ""; @@ -620,7 +617,7 @@ if ($action == 'edit' || $action == 'updateedit') print "\n"; - print ""; + print ""; print '
global->FACTURE_LOCAL_TAX1_OPTION) || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1off")?" checked":"")."> ".$langs->transcountry("LocalTax1IsNotUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX1_OPTION) || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1off")?" checked":"")."> ".$langs->transcountry("LocalTax1IsNotUsed",$mysoc->country_code)."'; print ""; print ""; @@ -639,11 +636,10 @@ if ($action == 'edit' || $action == 'updateedit') print ''; print ''; print "\n"; - $var=true; // Note: When option is not set, it must not appears as set on on, because there is no default value for this option - print ""; + print ""; print '
'.$langs->transcountry("LocalTax2Management",$mysoc->country_code).''.$langs->trans("Description").' 
global->FACTURE_LOCAL_TAX2_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2on")?" checked":"")."> ".$langs->transcountry("LocalTax2IsUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX2_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2on")?" checked":"")."> ".$langs->transcountry("LocalTax2IsUsed",$mysoc->country_code)."'; print ''; print ""; @@ -662,7 +658,7 @@ if ($action == 'edit' || $action == 'updateedit') print "\n"; - print ""; + print ""; print '
global->FACTURE_LOCAL_TAX2_OPTION) || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2off")?" checked":"")."> ".$langs->transcountry("LocalTax2IsNotUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX2_OPTION) || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2off")?" checked":"")."> ".$langs->transcountry("LocalTax2IsNotUsed",$mysoc->country_code)."'; print ""; print ""; @@ -696,7 +692,6 @@ else print '
'; print ''; - $var=true; print ''; print ''; print "\n"; - $var=true; print ''; print ''; print "\n"; - $var=true; - print ""; + print ""; print '
'.$langs->trans("CompanyInfo").''.$langs->trans("Value").'
'.$langs->trans("CompanyName").''; @@ -965,7 +960,6 @@ else print '
'.$langs->trans("FiscalYearInformation").''.$langs->trans("Value").'
'.$langs->trans("FiscalMonthStart").''; @@ -983,10 +977,9 @@ else print ''.$langs->trans("VATManagement").''.$langs->trans("Description").' 
global->FACTURE_TVAOPTION)?"":" checked")."> ".$langs->trans("VATIsUsed")."
global->FACTURE_TVAOPTION)?"":" checked")."> ".$langs->trans("VATIsUsed")."'; print ""; print ""; @@ -995,7 +988,7 @@ else print "\n"; - print ""; + print ""; print '
global->FACTURE_TVAOPTION)?" checked":"")."> ".$langs->trans("VATIsNotUsed")."
global->FACTURE_TVAOPTION)?" checked":"")."> ".$langs->trans("VATIsNotUsed")."'; print ""; print ""; @@ -1018,10 +1011,9 @@ else print ''; print ''; print "\n"; - $var=true; - print ""; + print ""; print '
".$langs->trans("VATIsNotUsedDesc")."
'.$langs->transcountry("LocalTax1Management",$mysoc->country_code).''.$langs->trans("Description").' 
global->FACTURE_LOCAL_TAX1_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1on")?" checked":"")."> ".$langs->transcountry("LocalTax1IsUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX1_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1on")?" checked":"")."> ".$langs->transcountry("LocalTax1IsUsed",$mysoc->country_code)."'; print ""; print ""; @@ -1049,7 +1041,7 @@ else print "\n"; - print ""; + print ""; print '
".$langs->transcountry("LocalTax1IsUsedDesc",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX1_OPTION) || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1off")?" checked":"")."> ".$langs->transcountry("LocalTax1IsNotUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX1_OPTION) || $conf->global->FACTURE_LOCAL_TAX1_OPTION == "localtax1off")?" checked":"")."> ".$langs->transcountry("LocalTax1IsNotUsed",$mysoc->country_code)."'; print ""; print ""; @@ -1069,10 +1061,9 @@ else print ''; print ''; print "\n"; - $var=true; - print ""; + print ""; print '
'.$langs->transcountry("LocalTax2Management",$mysoc->country_code).''.$langs->trans("Description").' 
global->FACTURE_LOCAL_TAX2_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2on")?" checked":"")."> ".$langs->transcountry("LocalTax2IsUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX2_OPTION == '1' || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2on")?" checked":"")."> ".$langs->transcountry("LocalTax2IsUsed",$mysoc->country_code)."'; print ""; print ""; @@ -1101,7 +1092,7 @@ else print "\n"; - print ""; + print ""; print '\n"; foreach ($list as $key) { - - - print ''; + print ''; // Param $libelle = $langs->trans($key); diff --git a/htdocs/admin/events.php b/htdocs/admin/events.php index 161b1aac45d..74525a6855b 100644 --- a/htdocs/admin/events.php +++ b/htdocs/admin/events.php @@ -105,7 +105,7 @@ foreach ($eventstolog as $key => $arr) print ''."\n"; } } diff --git a/htdocs/admin/fichinter.php b/htdocs/admin/fichinter.php index 6c73afcf8f5..fce15178cdb 100644 --- a/htdocs/admin/fichinter.php +++ b/htdocs/admin/fichinter.php @@ -6,7 +6,7 @@ * Copyright (C) 2005-2014 Regis Houssin * Copyright (C) 2008 Raphael Bertrand (Resultic) * Copyright (C) 2011-2013 Juanjo Menent - * Copyright (C) 2011-2015 Philippe Grand + * Copyright (C) 2011-2017 Philippe Grand * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -410,7 +410,6 @@ print "\n"; clearstatcache(); -$var=true; foreach ($dirmodels as $reldir) { $dir = dol_buildpath($reldir."core/modules/fichinter/doc/"); @@ -532,9 +531,7 @@ print ''; print ''; print "\n"; print "\n"; -$var=true; -$var=! $var; print ''; print ''; print ''; @@ -583,11 +580,10 @@ print '\n"; // Use services duration -$var = !$var; print ''; print ''; print ''; -print ''; +print ''; print ''; From 4c2f3aeeac45ffb13ca937bc6d95a07bcc4f7282 Mon Sep 17 00:00:00 2001 From: Philippe Grand Date: Thu, 4 May 2017 13:46:25 +0200 Subject: [PATCH 2/2] Update compta.php --- htdocs/admin/compta.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/admin/compta.php b/htdocs/admin/compta.php index 4c289ee25c7..70bf15d03f3 100644 --- a/htdocs/admin/compta.php +++ b/htdocs/admin/compta.php @@ -119,7 +119,7 @@ print '
global->FACTURE_LOCAL_TAX2_OPTION) || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2off")?" checked":"")."> ".$langs->transcountry("LocalTax2IsNotUsed",$mysoc->country_code)."
global->FACTURE_LOCAL_TAX2_OPTION) || $conf->global->FACTURE_LOCAL_TAX2_OPTION == "localtax2off")?" checked":"")."> ".$langs->transcountry("LocalTax2IsNotUsed",$mysoc->country_code)."'; print ""; print ""; diff --git a/htdocs/admin/compta.php b/htdocs/admin/compta.php index c097b9f39b1..4c289ee25c7 100644 --- a/htdocs/admin/compta.php +++ b/htdocs/admin/compta.php @@ -3,7 +3,7 @@ * Copyright (C) 2004-2008 Laurent Destailleur * Copyright (C) 2005-2009 Regis Houssin * Copyright (C) 2011-2013 Juanjo Menent - * Copyright (C) 2013-2016 Philippe Grand + * Copyright (C) 2013-2017 Philippe Grand * Copyright (C) 2014 Marcos GarcĂ­a * * This program is free software; you can redistribute it and/or modify @@ -119,7 +119,7 @@ print '
'; print ''; print ''; print "\n"; -print ''; +print ''; print '\n"; -print ''; +print ''; print '\n"; print "
'.$langs->trans('OptionMode').''.$langs->trans('Description').'
'.$langs->trans('OptionModeTrue').'
'.$langs->trans('OptionModeTrue').''.nl2br($langs->trans('OptionModeTrueDesc')); // Write info on way to count VAT //if (! empty($conf->global->MAIN_MODULE_COMPTABILITE)) @@ -133,7 +133,7 @@ print ''.nl2br($langs->trans('OptionModeTrueDesc')); // // print nl2br($langs->trans('OptionModeTrueInfoExpert')); //} print "
'.$langs->trans('OptionModeVirtual').'
'.$langs->trans('OptionModeVirtual').''.nl2br($langs->trans('OptionModeVirtualDesc'))."
\n"; @@ -148,9 +148,7 @@ print "
'; $key='MAIN_LOGEVENTS_'.$arr['id']; $value=$conf->global->$key; - print ''; + print ''; print '
'.$langs->trans("Parameter").''.$langs->trans("Value").' 
'; print ''; print "
'; print $langs->trans("UseServicesDurationOnFichinter"); print '
'; print ''; print ''; print "\n"; -print ''; +print ''; print '\n"; -print ''; +print ''; print '\n"; print "
'.$langs->trans('OptionMode').''.$langs->trans('Description').'
'.$langs->trans('OptionModeTrue').'
'.$langs->trans('OptionModeTrue').''.nl2br($langs->trans('OptionModeTrueDesc')); // Write info on way to count VAT //if (! empty($conf->global->MAIN_MODULE_COMPTABILITE)) @@ -133,7 +133,7 @@ print ''.nl2br($langs->trans('OptionModeTrueDesc')); // // print nl2br($langs->trans('OptionModeTrueInfoExpert')); //} print "
'.$langs->trans('OptionModeVirtual').'
'.$langs->trans('OptionModeVirtual').''.nl2br($langs->trans('OptionModeVirtualDesc'))."
\n";