From 5c5058b586abf68cbac82e846a511a34a8642499 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 20 Aug 2005 16:52:28 +0000 Subject: [PATCH] =?UTF-8?q?New:=20La=20fonction=20de=20remplissage=20de=20?= =?UTF-8?q?ville=20auto=20fonctionne=20aussi=20en=20mise=20a=20jour=20de?= =?UTF-8?q?=20soci=E9t=E9s?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/soc.php | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/htdocs/soc.php b/htdocs/soc.php index 8b44fed1eb3..c81de4de6a4 100644 --- a/htdocs/soc.php +++ b/htdocs/soc.php @@ -171,7 +171,10 @@ if ($_GET["action"] == 'create' || $_POST["action"] == 'create') print ''; } - include("./soc.js.php"); + if ($conf->global->MAIN_AUTO_FILLTOWNFROMZIP) + { + include("./soc.js.php"); + } print '
'; @@ -319,6 +322,12 @@ elseif ($_GET["action"] == 'edit') if ($_GET["socid"]) { + + if ($conf->global->MAIN_AUTO_FILLTOWNFROMZIP) + { + include("./soc.js.php"); + } + if ($no_reload <> 1) { $soc = new Societe($db); @@ -333,7 +342,7 @@ elseif ($_GET["action"] == 'edit') print ''; } - print ''; + print ''; print ''; print ''; print ''; @@ -383,7 +392,12 @@ elseif ($_GET["action"] == 'edit') print $soc->adresse; print ''; - print ''.$langs->trans('Zip').''; + print ''.$langs->trans('Zip').'global->MAIN_AUTO_FILLTOWNFROMZIP) print ' onblur="PopupPostalCode(cp.value,ville)"'; + print '>'; + if ($conf->global->MAIN_AUTO_FILLTOWNFROMZIP) print ' '; + print ''; + print ''.$langs->trans('Town').''; print ''.$langs->trans('State').'';