diff --git a/htdocs/admin/system/perf.php b/htdocs/admin/system/perf.php
index 6d9e3574789..e589db3ca26 100644
--- a/htdocs/admin/system/perf.php
+++ b/htdocs/admin/system/perf.php
@@ -473,7 +473,7 @@ $sql .= " FROM ".MAIN_DB_PREFIX."product as p";
$resql = $db->query($sql);
if ($resql)
{
- $limitforoptim = 10000;
+ $limitforoptim = 100000;
$num = $db->num_rows($resql);
$obj = $db->fetch_object($resql);
$nb = $obj->nb;
diff --git a/htdocs/comm/propal/card.php b/htdocs/comm/propal/card.php
index c6903495f37..b81ac502552 100644
--- a/htdocs/comm/propal/card.php
+++ b/htdocs/comm/propal/card.php
@@ -1661,8 +1661,7 @@ if ($action == 'create')
$langs->load("projects");
print '
';
print ''.$langs->trans("Project").' ';
- print img_picto('', 'project');
- $numprojet = $formproject->select_projects(($soc->id > 0 ? $soc->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 0, 0, 'maxwidth500');
+ print img_picto('', 'project').$formproject->select_projects(($soc->id > 0 ? $soc->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 1, 0, 'maxwidth500');
print ' id).'"> ';
print ' ';
print ' ';
@@ -1684,7 +1683,8 @@ if ($action == 'create')
print '';
print img_picto('', 'pdf').' ';
$liste = ModelePDFPropales::liste_modeles($db);
- print $form->selectarray('model', $liste, ($conf->global->PROPALE_ADDON_PDF_ODT_DEFAULT ? $conf->global->PROPALE_ADDON_PDF_ODT_DEFAULT : $conf->global->PROPALE_ADDON_PDF));
+ $preselected = ($conf->global->PROPALE_ADDON_PDF_ODT_DEFAULT ? $conf->global->PROPALE_ADDON_PDF_ODT_DEFAULT : $conf->global->PROPALE_ADDON_PDF);
+ print $form->selectarray('model', $liste, $preselected, 0, 0, 0, '', 0, 0, 0, '', '', 1);
print " ";
// Multicurrency
diff --git a/htdocs/commande/card.php b/htdocs/commande/card.php
index ff17626132a..66105e06fff 100644
--- a/htdocs/commande/card.php
+++ b/htdocs/commande/card.php
@@ -1731,7 +1731,8 @@ if ($action == 'create' && $usercancreate)
print img_picto('', 'pdf').' ';
include_once DOL_DOCUMENT_ROOT.'/core/modules/commande/modules_commande.php';
$liste = ModelePDFCommandes::liste_modeles($db);
- print $form->selectarray('model', $liste, $conf->global->COMMANDE_ADDON_PDF);
+ $preselected = $conf->global->COMMANDE_ADDON_PDF;
+ print $form->selectarray('model', $liste, $preselected, 0, 0, 0, '', 0, 0, 0, '', '', 1);
print "";
// Multicurrency
diff --git a/htdocs/compta/facture/card.php b/htdocs/compta/facture/card.php
index 983840f8156..16a472d878c 100644
--- a/htdocs/compta/facture/card.php
+++ b/htdocs/compta/facture/card.php
@@ -2956,7 +2956,7 @@ if ($action == 'create')
} else {
print ''.$langs->trans('Customer').' ';
print '';
- print $form->select_company($soc->id, 'socid', '((s.client = 1 OR s.client = 3) AND s.status=1)', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
+ print img_picto('', 'company').$form->select_company($soc->id, 'socid', '((s.client = 1 OR s.client = 3) AND s.status=1)', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
// Option to reload page to retrieve customer informations.
if (empty($conf->global->RELOAD_PAGE_ON_CUSTOMER_CHANGE_DISABLED))
{
@@ -3444,11 +3444,11 @@ if ($action == 'create')
if (!empty($conf->banque->enabled))
{
if (GETPOSTISSET('fk_account')) {
- $fk_account = GETPOST('fk_account');
+ $fk_account = GETPOST('fk_account', 'int');
}
print ' '.$langs->trans('BankAccount').' ';
- $form->select_comptes($fk_account, 'fk_account', 0, '', 1);
+ print img_picto('', 'bank_account', 'class="paddingrightonly"').$form->select_comptes($fk_account, 'fk_account', 0, '', 1, '', 0, '', 1);
print ' ';
}
@@ -3457,7 +3457,7 @@ if ($action == 'create')
{
$langs->load('projects');
print ''.$langs->trans('Project').' ';
- $numprojet = $formproject->select_projects(($socid > 0 ? $socid : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 0, 0, 'maxwidth500');
+ print img_picto('', 'project').$formproject->select_projects(($socid > 0 ? $socid : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 1, 0, 'maxwidth500');
print ' id.($fac_rec ? '&fac_rec='.$fac_rec : '')).'"> ';
print ' ';
}
@@ -3504,11 +3504,11 @@ if ($action == 'create')
if (!empty($conf->global->INVOICE_USE_DEFAULT_DOCUMENT)) {
// Hidden conf
$paramkey = 'FACTURE_ADDON_PDF_'.$object->type;
- $curent = !empty($conf->global->$paramkey) ? $conf->global->$paramkey : $conf->global->FACTURE_ADDON_PDF;
+ $preselected = !empty($conf->global->$paramkey) ? $conf->global->$paramkey : $conf->global->FACTURE_ADDON_PDF;
} else {
- $curent = $conf->global->FACTURE_ADDON_PDF;
+ $preselected = $conf->global->FACTURE_ADDON_PDF;
}
- print $form->selectarray('model', $liste, $curent);
+ print $form->selectarray('model', $liste, $preselected, 0, 0, 0, '', 0, 0, 0, '', '', 1);
print "";
// Multicurrency
diff --git a/htdocs/fourn/commande/card.php b/htdocs/fourn/commande/card.php
index c3ed206c9c1..c00e1d2d6e2 100644
--- a/htdocs/fourn/commande/card.php
+++ b/htdocs/fourn/commande/card.php
@@ -1610,7 +1610,7 @@ if ($action == 'create')
print $societe->getNomUrl(1);
print ' ';
} else {
- print $form->select_company((empty($socid) ? '' : $socid), 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
+ print img_picto('', 'company').$form->select_company((empty($socid) ? '' : $socid), 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
// reload page to retrieve customer informations
if (!empty($conf->global->RELOAD_PAGE_ON_SUPPLIER_CHANGE))
{
@@ -1672,6 +1672,7 @@ if ($action == 'create')
{
$langs->load("bank");
print ''.$langs->trans('BankAccount').' ';
+ print img_picto('', 'bank_account', 'class="paddingrightonly"');
$form->select_comptes($fk_account, 'fk_account', 0, '', 1);
print ' ';
}
@@ -1683,7 +1684,7 @@ if ($action == 'create')
$langs->load('projects');
print ''.$langs->trans('Project').' ';
- $formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 0, 0, 'maxwidth500');
+ print img_picto('', 'project').$formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 1, 0, 'maxwidth500');
print ' id).'"> ';
print ' ';
}
diff --git a/htdocs/fourn/facture/card.php b/htdocs/fourn/facture/card.php
index 8b4e55a6872..198e814c0a6 100644
--- a/htdocs/fourn/facture/card.php
+++ b/htdocs/fourn/facture/card.php
@@ -1805,7 +1805,7 @@ if ($action == 'create')
print $societe->getNomUrl(1);
print ' ';
} else {
- print $form->select_company($societe->id, 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
+ print img_picto('', 'company').$form->select_company($societe->id, 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
// reload page to retrieve supplier informations
if (!empty($conf->global->RELOAD_PAGE_ON_SUPPLIER_CHANGE))
{
@@ -2020,7 +2020,7 @@ if ($action == 'create')
print ''."\n";
@@ -2071,17 +2071,7 @@ if ($action == 'create')
if (!empty($conf->banque->enabled))
{
print ''.$langs->trans('BankAccount').' ';
- $form->select_comptes((GETPOSTISSET('fk_account') ?GETPOST('fk_account', 'alpha') : $fk_account), 'fk_account', 0, '', 1);
- print ' ';
- }
-
- // Multicurrency
- if (!empty($conf->multicurrency->enabled))
- {
- print '';
- print ''.$form->editfieldkey('Currency', 'multicurrency_code', '', $object, 0).' ';
- print '';
- print $form->selectMultiCurrency((GETPOSTISSET('multicurrency_code') ?GETPOST('multicurrency_code', 'alpha') : $currency_code), 'multicurrency_code');
+ print img_picto('', 'bank_account').$form->select_comptes((GETPOSTISSET('fk_account') ?GETPOST('fk_account', 'alpha') : $fk_account), 'fk_account', 0, '', 1, '', 0, '', 1);
print ' ';
}
@@ -2092,7 +2082,7 @@ if ($action == 'create')
$langs->load('projects');
print ''.$langs->trans('Project').' ';
- $formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 0, 0, 'maxwidth500');
+ print img_picto('', 'project').$formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $societe->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 1, 0, 'maxwidth500');
print ' ';
}
@@ -2106,6 +2096,16 @@ if ($action == 'create')
print '';
}
+ // Multicurrency
+ if (!empty($conf->multicurrency->enabled))
+ {
+ print '';
+ print ''.$form->editfieldkey('Currency', 'multicurrency_code', '', $object, 0).' ';
+ print '';
+ print $form->selectMultiCurrency((GETPOSTISSET('multicurrency_code') ?GETPOST('multicurrency_code', 'alpha') : $currency_code), 'multicurrency_code');
+ print ' ';
+ }
+
// Intracomm report
if (!empty($conf->intracommreport->enabled))
{
diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang
index cf35c4c0f83..e3646eb8112 100644
--- a/htdocs/langs/en_US/admin.lang
+++ b/htdocs/langs/en_US/admin.lang
@@ -1308,7 +1308,7 @@ YouUseBestDriver=You use driver %s which is the best driver currently available.
YouDoNotUseBestDriver=You use driver %s but driver %s is recommended.
NbOfObjectIsLowerThanNoPb=You have only %s %s in the database. This does not require any particular optimization.
SearchOptim=Search optimization
-YouHaveXObjectUseSearchOptim=You have %s %s in the database. You should add the constant %s to 1 in Home-Setup-Other. Limit the search to the beginning of strings which makes it possible for the database to use indexes and you should get an immediate response.
+YouHaveXObjectUseSearchOptim=You have %s %s in the database. You can add the constant %s to 1 in Home-Setup-Other. Limit the search to the beginning of strings which makes it possible for the database to use indexes and you should get an immediate response.
YouHaveXObjectAndSearchOptimOn=You have %s %s in the database and constant %s is set to 1 in Home-Setup-Other.
BrowserIsOK=You are using the %s web browser. This browser is ok for security and performance.
BrowserIsKO=You are using the %s web browser. This browser is known to be a bad choice for security, performance and reliability. We recommend using Firefox, Chrome, Opera or Safari.
diff --git a/htdocs/supplier_proposal/card.php b/htdocs/supplier_proposal/card.php
index a9411e6d283..d7ee97e1b9d 100644
--- a/htdocs/supplier_proposal/card.php
+++ b/htdocs/supplier_proposal/card.php
@@ -1151,7 +1151,7 @@ if ($action == 'create')
print '';
} else {
print '';
- print $form->select_company('', 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
+ print img_picto('', 'company').$form->select_company('', 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300');
print ' ';
print ' ';
}
@@ -1217,7 +1217,8 @@ if ($action == 'create')
print ''.$langs->trans("DefaultModel").' ';
print '';
$liste = ModelePDFSupplierProposal::liste_modeles($db);
- print $form->selectarray('model', $liste, ($conf->global->SUPPLIER_PROPOSAL_ADDON_PDF_ODT_DEFAULT ? $conf->global->SUPPLIER_PROPOSAL_ADDON_PDF_ODT_DEFAULT : $conf->global->SUPPLIER_PROPOSAL_ADDON_PDF));
+ $preselected = ($conf->global->SUPPLIER_PROPOSAL_ADDON_PDF_ODT_DEFAULT ? $conf->global->SUPPLIER_PROPOSAL_ADDON_PDF_ODT_DEFAULT : $conf->global->SUPPLIER_PROPOSAL_ADDON_PDF);
+ print $form->selectarray('model', $liste, $preselected, 0, 0, 0, '', 0, 0, 0, '', '', 1);
print " ";
// Project
@@ -1231,8 +1232,7 @@ if ($action == 'create')
print '';
print ''.$langs->trans("Project").' ';
-
- $numprojet = $formproject->select_projects(($soc->id > 0 ? $soc->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 0, 0, 'maxwidth500');
+ print img_picto('', 'project').$formproject->select_projects(($soc->id > 0 ? $soc->id : -1), $projectid, 'projectid', 0, 0, 1, 1, 0, 0, 0, '', 1, 0, 'maxwidth500');
print ' id).'"> ';
print ' ';