Test to fix a regression
This commit is contained in:
parent
5cb38ece19
commit
965e23b711
@ -781,7 +781,7 @@ function get_next_value($db,$mask,$table,$field,$where='',$objsoc='',$date='',$m
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Personalized field {XXX-1} à {XXX-9}
|
// Personalized field {XXX-1} à {XXX-9}
|
||||||
$maskperso=array();
|
/*$maskperso=array();
|
||||||
$maskpersonew=array();
|
$maskpersonew=array();
|
||||||
$tmpmask=$mask;
|
$tmpmask=$mask;
|
||||||
while (preg_match('/\{([A-Z]+)\-([1-9])\}/i',$tmpmask,$regKey))
|
while (preg_match('/\{([A-Z]+)\-([1-9])\}/i',$tmpmask,$regKey))
|
||||||
@ -789,17 +789,17 @@ function get_next_value($db,$mask,$table,$field,$where='',$objsoc='',$date='',$m
|
|||||||
$maskperso[$regKey[1]]='\{'.$regKey[1]+'\-'.$regKey[2].'\}';
|
$maskperso[$regKey[1]]='\{'.$regKey[1]+'\-'.$regKey[2].'\}';
|
||||||
$maskpersonew[$regKey[1]]=str_pad('', '_', $regKey[2], STR_PAD_RIGHT);
|
$maskpersonew[$regKey[1]]=str_pad('', '_', $regKey[2], STR_PAD_RIGHT);
|
||||||
$tmpmask=preg_replace('/\{'.$regKey[1].'\-'.$regKey[2].'\}/i', $maskpersonew, $tmpmask);
|
$tmpmask=preg_replace('/\{'.$regKey[1].'\-'.$regKey[2].'\}/i', $maskpersonew, $tmpmask);
|
||||||
}
|
}*/
|
||||||
|
|
||||||
$maskwithonlyymcode=$mask;
|
$maskwithonlyymcode=$mask;
|
||||||
$maskwithonlyymcode=preg_replace('/\{(0+)([@\+][0-9\-\+\=]+)?([@\+][0-9\-\+\=]+)?\}/i',$maskcounter,$maskwithonlyymcode);
|
$maskwithonlyymcode=preg_replace('/\{(0+)([@\+][0-9\-\+\=]+)?([@\+][0-9\-\+\=]+)?\}/i',$maskcounter,$maskwithonlyymcode);
|
||||||
$maskwithonlyymcode=preg_replace('/\{dd\}/i','dd',$maskwithonlyymcode);
|
$maskwithonlyymcode=preg_replace('/\{dd\}/i','dd',$maskwithonlyymcode);
|
||||||
$maskwithonlyymcode=preg_replace('/\{(c+)(0*)\}/i',$maskrefclient,$maskwithonlyymcode);
|
$maskwithonlyymcode=preg_replace('/\{(c+)(0*)\}/i',$maskrefclient,$maskwithonlyymcode);
|
||||||
$maskwithonlyymcode=preg_replace('/\{(t+)\}/i',$masktype_value,$maskwithonlyymcode);
|
$maskwithonlyymcode=preg_replace('/\{(t+)\}/i',$masktype_value,$maskwithonlyymcode);
|
||||||
foreach($maskperso as $key => $val)
|
/*foreach($maskperso as $key => $val)
|
||||||
{
|
{
|
||||||
$maskwithonlyymcode=preg_replace('/'.$val.'/i', $maskpersonew[$key], $maskwithonlyymcode);
|
$maskwithonlyymcode=preg_replace('/'.$val.'/i', $maskpersonew[$key], $maskwithonlyymcode);
|
||||||
}
|
}*/
|
||||||
$maskwithnocode=$maskwithonlyymcode;
|
$maskwithnocode=$maskwithonlyymcode;
|
||||||
$maskwithnocode=preg_replace('/\{yyyy\}/i','yyyy',$maskwithnocode);
|
$maskwithnocode=preg_replace('/\{yyyy\}/i','yyyy',$maskwithnocode);
|
||||||
$maskwithnocode=preg_replace('/\{yy\}/i','yy',$maskwithnocode);
|
$maskwithnocode=preg_replace('/\{yy\}/i','yy',$maskwithnocode);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user