Modification des champs dates
This commit is contained in:
parent
b8a78b3b20
commit
8bc908a4da
@ -19,7 +19,7 @@ Class Ciblage
|
||||
{
|
||||
if (method_exists($this, $key) and !empty($valeur) and $valeur != 'tous') {
|
||||
if(is_array($valeur)) {
|
||||
if(!empty($valeur[0]))
|
||||
if($valeur[0] != "")
|
||||
$this->$key($valeur);
|
||||
} else
|
||||
$this->$key($valeur);
|
||||
@ -226,10 +226,30 @@ Class Ciblage
|
||||
}
|
||||
|
||||
protected function dateCrea_ent($valeur) {
|
||||
if(!is_array($valeur)) {
|
||||
$format = explode('/', $valeur);
|
||||
$valeur = $format[2].$format[1].$format[0];
|
||||
} else {
|
||||
$format1 = explode('/', $valeur[0]);
|
||||
$format2 = explode('/', $valeur[0]);
|
||||
|
||||
$valeur[0] = $format1[2].$format1[1].$format1[0];
|
||||
$valeur[1] = $format2[2].$format2[1].$format2[0];
|
||||
}
|
||||
$this->setFilterRange('dateCrea_etab', $valeur);
|
||||
}
|
||||
|
||||
protected function dateImmat($valeur) {
|
||||
if(!is_array($valeur)) {
|
||||
$format = explode('/', $valeur);
|
||||
$valeur = $format[2].$format[1].$format[0];
|
||||
} else {
|
||||
$format1 = explode('/', $valeur[0]);
|
||||
$format2 = explode('/', $valeur[0]);
|
||||
|
||||
$valeur[0] = $format1[2].$format1[1].$format1[0];
|
||||
$valeur[1] = $format2[2].$format2[1].$format2[0];
|
||||
}
|
||||
$this->setFilterRange('dateImmat', $valeur);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user