Skip to content

Commit

Permalink
Merge pull request #2451 from Dolibarr/revert-2318-3.5-accountingmask
Browse files Browse the repository at this point in the history
Revert "FIXED Allowed 0 to be used as an account mask"
  • Loading branch information
eldy committed Mar 14, 2015
2 parents da042c1 + 4a9a3ab commit da72cf3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
4 changes: 2 additions & 2 deletions htdocs/core/modules/societe/mod_codecompta_aquarium.php
Expand Up @@ -44,8 +44,8 @@ class mod_codecompta_aquarium extends ModeleAccountancyCode
function __construct()
{
global $conf;
if (is_null($conf->global->COMPANY_AQUARIUM_MASK_CUSTOMER)) $conf->global->COMPANY_AQUARIUM_MASK_CUSTOMER='411';
if (is_null($conf->global->COMPANY_AQUARIUM_MASK_SUPPLIER)) $conf->global->COMPANY_AQUARIUM_MASK_SUPPLIER='401';
if (empty($conf->global->COMPANY_AQUARIUM_MASK_CUSTOMER)) $conf->global->COMPANY_AQUARIUM_MASK_CUSTOMER='411';
if (empty($conf->global->COMPANY_AQUARIUM_MASK_SUPPLIER)) $conf->global->COMPANY_AQUARIUM_MASK_SUPPLIER='401';
$this->prefixcustomeraccountancycode=$conf->global->COMPANY_AQUARIUM_MASK_CUSTOMER;
$this->prefixsupplieraccountancycode=$conf->global->COMPANY_AQUARIUM_MASK_SUPPLIER;
}
Expand Down
6 changes: 1 addition & 5 deletions htdocs/societe/admin/societe.php
Expand Up @@ -114,11 +114,7 @@
{
$param=GETPOST("param".$i,'alpha');
$value=GETPOST("value".$i,'alpha');
// Use the default values if the field is not set
if ($param == '') {
$param = null;
}
$res = dolibarr_set_const($db,$param,$value,'chaine',0,'',$conf->entity);
if ($param) $res = dolibarr_set_const($db,$param,$value,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
}
}
Expand Down

0 comments on commit da72cf3

Please sign in to comment.