From 38c7c609bcea9b4106e7f83125ca456e42664e99 Mon Sep 17 00:00:00 2001 From: Alexis Algoud <alexis@atm-consulting.fr> Date: Mon, 2 Dec 2013 11:42:39 +0100 Subject: [PATCH] Error on mercure bill's number function. Ex draft bill for november : mask = FC{yy}{mm}{000@99} {mm} = 11 On validation, number -> FC131160 instead of FC131112 --- htdocs/core/lib/functions2.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/lib/functions2.lib.php b/htdocs/core/lib/functions2.lib.php index 22b90ef52e0..3fc40f8c8fe 100644 --- a/htdocs/core/lib/functions2.lib.php +++ b/htdocs/core/lib/functions2.lib.php @@ -629,7 +629,7 @@ function get_next_value($db,$mask,$table,$field,$where='',$objsoc='',$date='',$m if ($maskraz > 0) // A reset is required { if ($maskraz == 99) { - $maskraz = date('m'); + $maskraz = date('m', $date); $resetEveryMonth = true; } if ($maskraz > 12) return 'ErrorBadMaskBadRazMonth'; -- GitLab