Fix: on ne prend pas en compte le mois de janvier pour le debut d'année fiscale car il est pris par defaut
This commit is contained in:
parent
eebc13dd9a
commit
c4745e1a81
@ -352,7 +352,7 @@ function info()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// On change d'année fiscal si besoin
|
// On change d'année fiscal si besoin
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -90,7 +90,7 @@ class mod_commande_emeraude extends ModeleNumRefCommandes
|
|||||||
// D'abord on défini l'année fiscale
|
// D'abord on défini l'année fiscale
|
||||||
$prefix='C';
|
$prefix='C';
|
||||||
$current_month = date("n");
|
$current_month = date("n");
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -90,7 +90,7 @@ class mod_commande_rubis extends ModeleNumRefCommandes
|
|||||||
// D'abord on défini l'année fiscale
|
// D'abord on défini l'année fiscale
|
||||||
$prefix='C';
|
$prefix='C';
|
||||||
$current_month = date("n");
|
$current_month = date("n");
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -354,7 +354,7 @@ function info()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// On change d'année fiscal si besoin
|
// On change d'année fiscal si besoin
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -93,7 +93,7 @@ function info()
|
|||||||
$create_month = $current_month;
|
$create_month = $current_month;
|
||||||
}
|
}
|
||||||
|
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -398,7 +398,7 @@ function info()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// On change d'année fiscal si besoin
|
// On change d'année fiscal si besoin
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -94,7 +94,7 @@ function info()
|
|||||||
$create_month = $current_month;
|
$create_month = $current_month;
|
||||||
}
|
}
|
||||||
|
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -354,7 +354,7 @@ function info()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// On change d'année fiscal si besoin
|
// On change d'année fiscal si besoin
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -89,7 +89,7 @@ class mod_propale_emeraude extends ModeleNumRefPropales
|
|||||||
// D'abord on défini l'année fiscale
|
// D'abord on défini l'année fiscale
|
||||||
$prefix='PR';
|
$prefix='PR';
|
||||||
$current_month = date("n");
|
$current_month = date("n");
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -89,7 +89,7 @@ class mod_propale_rubis extends ModeleNumRefPropales
|
|||||||
// D'abord on défini l'année fiscale
|
// D'abord on défini l'année fiscale
|
||||||
$prefix='PR';
|
$prefix='PR';
|
||||||
$current_month = date("n");
|
$current_month = date("n");
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
$yy = strftime("%y",mktime(0,0,0,date("m"),date("d"),date("Y")+1));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -343,7 +343,7 @@ function info()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// On change d'année fiscal si besoin
|
// On change d'année fiscal si besoin
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -356,7 +356,7 @@ class mod_livraison_saphir extends ModeleNumRefDeliveryOrder
|
|||||||
}
|
}
|
||||||
|
|
||||||
// On change d'année fiscal si besoin
|
// On change d'année fiscal si besoin
|
||||||
if($conf->global->SOCIETE_FISCAL_MONTH_START && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
if($conf->global->SOCIETE_FISCAL_MONTH_START > 1 && $current_month >= $conf->global->SOCIETE_FISCAL_MONTH_START && $create_month >= $conf->global->SOCIETE_FISCAL_MONTH_START)
|
||||||
{
|
{
|
||||||
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
$this->yy = substr(strftime("%Y",mktime(0,0,0,date("m"),date("d"),date("Y")+1)),$numbityear);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user