diff --git a/build/rpm/dolibarr_fedora.spec b/build/rpm/dolibarr_fedora.spec index 65da8cabfd7..d5a9189229e 100755 --- a/build/rpm/dolibarr_fedora.spec +++ b/build/rpm/dolibarr_fedora.spec @@ -212,6 +212,7 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/supplier_proposal %_datadir/dolibarr/htdocs/support %_datadir/dolibarr/htdocs/theme +%_datadir/dolibarr/htdocs/ticket %_datadir/dolibarr/htdocs/user %_datadir/dolibarr/htdocs/variants %_datadir/dolibarr/htdocs/webservices diff --git a/build/rpm/dolibarr_generic.spec b/build/rpm/dolibarr_generic.spec index 2fed89c03f3..673d5919d1a 100755 --- a/build/rpm/dolibarr_generic.spec +++ b/build/rpm/dolibarr_generic.spec @@ -292,6 +292,7 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/supplier_proposal %_datadir/dolibarr/htdocs/support %_datadir/dolibarr/htdocs/theme +%_datadir/dolibarr/htdocs/ticket %_datadir/dolibarr/htdocs/user %_datadir/dolibarr/htdocs/variants %_datadir/dolibarr/htdocs/webservices diff --git a/build/rpm/dolibarr_mandriva.spec b/build/rpm/dolibarr_mandriva.spec index fb15a2d2d92..e3d2a849db2 100755 --- a/build/rpm/dolibarr_mandriva.spec +++ b/build/rpm/dolibarr_mandriva.spec @@ -209,6 +209,7 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/supplier_proposal %_datadir/dolibarr/htdocs/support %_datadir/dolibarr/htdocs/theme +%_datadir/dolibarr/htdocs/ticket %_datadir/dolibarr/htdocs/user %_datadir/dolibarr/htdocs/variants %_datadir/dolibarr/htdocs/webservices diff --git a/build/rpm/dolibarr_opensuse.spec b/build/rpm/dolibarr_opensuse.spec index 70eba841bd8..5a64bec2e78 100755 --- a/build/rpm/dolibarr_opensuse.spec +++ b/build/rpm/dolibarr_opensuse.spec @@ -220,6 +220,7 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/supplier_proposal %_datadir/dolibarr/htdocs/support %_datadir/dolibarr/htdocs/theme +%_datadir/dolibarr/htdocs/ticket %_datadir/dolibarr/htdocs/user %_datadir/dolibarr/htdocs/variants %_datadir/dolibarr/htdocs/webservices diff --git a/dev/translation/sanity_check_en_langfiles.php b/dev/translation/sanity_check_en_langfiles.php index f65cefd7f94..2eedcda8760 100755 --- a/dev/translation/sanity_check_en_langfiles.php +++ b/dev/translation/sanity_check_en_langfiles.php @@ -295,6 +295,9 @@ if ((! empty($_REQUEST['unused']) && $_REQUEST['unused'] == 'true') || (isset($a if (preg_match('/^DescADHERENT_/', $value)) $qualifiedforclean=0; if (preg_match('/^SubmitTranslation/', $value)) $qualifiedforclean=0; if (preg_match('/^ModuleCompanyCode/', $value)) $qualifiedforclean=0; + // admin.lang + if (preg_match('/^DAV_ALLOW_PUBLIC_DIR/i', $value)) $qualifiedforclean=0; + if (preg_match('/^DAV_ALLOW_ECM_DIR/i', $value)) $qualifiedforclean=0; // boxes.lang if (preg_match('/^BoxTitleLast/', $value)) $qualifiedforclean=0; if (preg_match('/^BoxTitleLatest/', $value)) $qualifiedforclean=0; diff --git a/htdocs/adherents/class/adherent.class.php b/htdocs/adherents/class/adherent.class.php index 537b6f76a63..5d7664b13aa 100644 --- a/htdocs/adherents/class/adherent.class.php +++ b/htdocs/adherents/class/adherent.class.php @@ -464,7 +464,7 @@ class Adherent extends CommonObject $action='update'; // Actions on extra fields - if (empty($conf->global->MAIN_EXTRAFIELDS_DISABLED)) // For avoid conflicts if trigger used + if (! $error && empty($conf->global->MAIN_EXTRAFIELDS_DISABLED)) // For avoid conflicts if trigger used { $result=$this->insertExtraFields(); if ($result < 0) diff --git a/htdocs/adherents/class/adherent_type.class.php b/htdocs/adherents/class/adherent_type.class.php index 75f518074b1..ca8372c04ed 100644 --- a/htdocs/adherents/class/adherent_type.class.php +++ b/htdocs/adherents/class/adherent_type.class.php @@ -142,7 +142,7 @@ class AdherentType extends CommonObject /** * Met a jour en base donnees du type * - * @param User $user Object user making change + * @param User $user Object user making change * @param int $notrigger 1=do not execute triggers, 0 otherwise * @return int >0 if OK, < 0 if KO */ @@ -172,7 +172,7 @@ class AdherentType extends CommonObject $action='update'; // Actions on extra fields - if (empty($conf->global->MAIN_EXTRAFIELDS_DISABLED)) // For avoid conflicts if trigger used + if (! $error && empty($conf->global->MAIN_EXTRAFIELDS_DISABLED)) // For avoid conflicts if trigger used { $result=$this->insertExtraFields(); if ($result < 0) diff --git a/htdocs/adherents/subscription.php b/htdocs/adherents/subscription.php index 3e4af5438c6..f7a074106b9 100644 --- a/htdocs/adherents/subscription.php +++ b/htdocs/adherents/subscription.php @@ -330,7 +330,7 @@ if ($user->rights->adherent->cotisation->creer && $action == 'subscription' && ! if (! $error) { -// $db->commit(); + $db->commit(); } else { diff --git a/htdocs/admin/dict.php b/htdocs/admin/dict.php index e4f9fa1dd90..32995bce38f 100644 --- a/htdocs/admin/dict.php +++ b/htdocs/admin/dict.php @@ -379,7 +379,7 @@ $tabrowid[9] = "code_iso"; $tabrowid[10]= ""; $tabrowid[11]= "rowid"; $tabrowid[12]= ""; -$tabrowid[13]= ""; +$tabrowid[13]= "id"; $tabrowid[14]= ""; $tabrowid[15]= ""; $tabrowid[16]= "code"; diff --git a/htdocs/admin/ihm.php b/htdocs/admin/ihm.php index 62f17d5cb1d..50edc32d55f 100644 --- a/htdocs/admin/ihm.php +++ b/htdocs/admin/ihm.php @@ -309,8 +309,8 @@ if ($action == 'edit') // Edit // Firstname/Name print ''.$langs->trans("FirstnameNamePosition").''; - $array=array(0=>$langs->trans("Firstname").' '.$langs->trans("Lastname"),1=>$langs->trans("Lastname").' '.$langs->trans("Firstname")); - print $form->selectarray('MAIN_FIRSTNAME_NAME_POSITION',$array,(isset($conf->global->MAIN_FIRSTNAME_NAME_POSITION)?$conf->global->MAIN_FIRSTNAME_NAME_POSITION:0)); + $array=array(0=>$langs->trans("Firstname").' '.$langs->trans("Lastname"), 1=>$langs->trans("Lastname").' '.$langs->trans("Firstname")); + print $form->selectarray('MAIN_FIRSTNAME_NAME_POSITION', $array, (isset($conf->global->MAIN_FIRSTNAME_NAME_POSITION)?$conf->global->MAIN_FIRSTNAME_NAME_POSITION:0)); print ''; print ' '; print ''; diff --git a/htdocs/admin/mails_templates.php b/htdocs/admin/mails_templates.php index af7d29c0fd6..394742c7d2a 100644 --- a/htdocs/admin/mails_templates.php +++ b/htdocs/admin/mails_templates.php @@ -1,6 +1,6 @@ - * Copyright (C) 2004-2015 Laurent Destailleur + * Copyright (C) 2004-2018 Laurent Destailleur * Copyright (C) 2004 Benoit Mortier * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2010-2016 Juanjo Menent @@ -556,7 +556,7 @@ foreach ($fieldsforcontent as $tmpfieldlist) print ''; } else if ($tmpfieldlist == 'joinfiles') { - print ''; + print ''; } else { @@ -989,7 +989,7 @@ function fieldList($fieldlist, $obj='', $tabname='', $context='') print ''; if (! empty($conf->global->MAIN_MULTILANGS)) { - $selectedlang = $langs->defaultlang; + $selectedlang = GETPOSTISSET('langcode','aZ09')?GETPOST('langcode','aZ09'):$langs->defaultlang; if ($context == 'edit') $selectedlang = $obj->{$fieldlist[$field]}; print $formadmin->select_language($selectedlang, 'langcode', 0, null, 1, 0, 0, 'maxwidth150'); } diff --git a/htdocs/admin/modulehelp.php b/htdocs/admin/modulehelp.php index cf4596ccda2..6281376dc2e 100644 --- a/htdocs/admin/modulehelp.php +++ b/htdocs/admin/modulehelp.php @@ -313,7 +313,9 @@ if ($mode == 'desc') { $textexternal.='
'.$langs->trans("Origin").': '.$langs->trans("ExternalModule",$dirofmodule); if ($objMod->editor_name != 'dolibarr') $textexternal.='
'.$langs->trans("Publisher").': '.(empty($objMod->editor_name)?$langs->trans("Unknown"):$objMod->editor_name); - if (! empty($objMod->editor_url) && ! preg_match('/dolibarr\.org/i',$objMod->editor_url)) $textexternal.='
'.$langs->trans("Url").': '.$objMod->editor_url.''; + $editor_url = $objMod->editor_url; + if (! preg_match('/^http/', $editor_url)) $editor_url = 'http://'.$editor_url; + if (! empty($objMod->editor_url) && ! preg_match('/dolibarr\.org/i',$objMod->editor_url)) $textexternal.='
'.$langs->trans("Url").': '.$objMod->editor_url.''; $text.=$textexternal; $text.='
'; } diff --git a/htdocs/admin/multicurrency.php b/htdocs/admin/multicurrency.php index d4a031a6148..b301a2c7a03 100644 --- a/htdocs/admin/multicurrency.php +++ b/htdocs/admin/multicurrency.php @@ -19,14 +19,11 @@ /** * \file admin/multicurrency.php * \ingroup multicurrency - * \brief This file is an example module setup page - * Put some comments here + * \brief Page to setup multicurrency module */ + // Dolibarr environment - require '../main.inc.php'; - -// Libraries require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/multicurrency.lib.php'; require_once DOL_DOCUMENT_ROOT.'/multicurrency/class/multicurrency.class.php'; @@ -42,6 +39,8 @@ if (! $user->admin) { // Parameters $action = GETPOST('action', 'alpha'); + + /* * Actions */ @@ -164,6 +163,8 @@ if ($resql) * View */ +$form=new Form($db); + $page_name = "MultiCurrencySetup"; llxHeader('', $langs->trans($page_name)); @@ -176,21 +177,16 @@ print_fiche_titre($langs->trans($page_name), $linkback); $head = multicurrencyAdminPrepareHead(); dol_fiche_head($head, 'settings', $langs->trans("ModuleSetup"), -1, "multicurrency"); -// Setup page goes here -$form=new Form($db); -$var=false; print ''; print ''; print ''."\n"; -print ''; -print ''."\n"; - +print ''."\n"; +print ''; print ''; print ''; -print ''; -print ''; - print ''; print ''; -print ''; -print ''; print ''; print ''; -print ''; -print ''; print ''; print ''; -print ''; -print ''; */ print '
'.$langs->trans("Parameters").' '.$langs->trans("Value").''.$langs->trans("Value").'
'.$langs->transnoentitiesnoconv("MULTICURRENCY_USE_RATE_ON_DOCUMENT_DATE").' '; +print ''; print '
'; print ''; print ''; @@ -200,11 +196,9 @@ print '
'; print '
'.$langs->transnoentitiesnoconv("multicurrency_useOriginTx").' '; +print ''; print '
'; print ''; print ''; @@ -217,8 +211,7 @@ print '
'.$langs->transnoentitiesnoconv("multicurrency_buyPriceInCurrency").' '; +print ''; print ''; print ''; print ''; @@ -232,8 +225,7 @@ print '
'.$langs->transnoentitiesnoconv("multicurrency_modifyRateApplication").' '; +print ''; print ''; print ''; print ''; @@ -245,16 +237,17 @@ print '
'; + print '
'; if (!empty($conf->global->MAIN_MULTICURRENCY_ALLOW_SYNCHRONIZATION)) { - $var=false; + print '
'; print ''; + print ''; print ''."\n"; - print ''; - print ''; - print ''; print ''; - print ''; - print ''; print ''; - print ''; - print ''; print ''; - print ''; - print ''; print '
'.$form->textwithpicto($langs->trans("CurrencyLayerAccount"), $langs->trans("CurrencyLayerAccount_help_to_synchronize")).' '; + print ''; print ''; print ''; print ''; @@ -263,11 +256,9 @@ if (!empty($conf->global->MAIN_MULTICURRENCY_ALLOW_SYNCHRONIZATION)) print '
'.$langs->transnoentitiesnoconv("multicurrency_appId").' '; + print ''; print ''; print ''; print ''; @@ -279,8 +270,7 @@ if (!empty($conf->global->MAIN_MULTICURRENCY_ALLOW_SYNCHRONIZATION)) print '
'.$langs->transnoentitiesnoconv("multicurrency_appCurrencySource").' '; + print ''; print ''; print ''; print ''; @@ -291,8 +281,7 @@ if (!empty($conf->global->MAIN_MULTICURRENCY_ALLOW_SYNCHRONIZATION)) print '
'.$langs->transnoentitiesnoconv("multicurrency_alternateCurrencySource").' '; + print ''; print ''; print ''; print ''; @@ -302,35 +291,35 @@ if (!empty($conf->global->MAIN_MULTICURRENCY_ALLOW_SYNCHRONIZATION)) print '
'; + print '
'; print '
'; } +print '
'; print ''; print ''; print ''."\n"; -print ''; -print ''."\n"; +print ''."\n"; +print ''; - -print ''; print ''; +print ''; +print ''; +print ''; -print ''; -print ''; - +print ''; +print ''; +print ''; print ''; print ''; -print ''; -print ''; +print ''; +print ''; foreach ($TCurrency as &$currency) { @@ -338,8 +327,7 @@ foreach ($TCurrency as &$currency) print ''; print ''; - print ''; - print ''; } print '
'.$form->textwithpicto($langs->trans("CurrenciesUsed"), $langs->transnoentitiesnoconv("CurrenciesUsed_help_to_add")).' '.$langs->trans("Rate").''.$langs->trans("Rate").'
'.$form->selectCurrency('', 'code').''; print ''; print ''; -print ''.$form->selectCurrency('', 'code').' '; print ' '; print ''; -print '
'.$conf->currency.$form->textwithpicto(' ', $langs->trans("BaseCurrency")).' 1'; -print '
1
'.$currency->code.' - '.$currency->name.' '; + print ''; print '
'; print ''; print ''; @@ -349,13 +337,11 @@ foreach ($TCurrency as &$currency) print ' '; print ''; print '
'; - print '
'; - - +print '
'; print '