mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-22 05:49:03 +01:00
Etemplate - fix using date widget min/max attributes made it required, even if not set as such
This commit is contained in:
parent
0b3e4f048e
commit
17fe08f8fd
@ -179,7 +179,7 @@ class Date extends Transformer
|
||||
$valid = (string)$value === '' ? '' : (int)$value;
|
||||
}
|
||||
|
||||
if (!empty($this->attrs['min']))
|
||||
if (!empty($this->attrs['min']) && !empty($value))
|
||||
{
|
||||
if(is_numeric($this->attrs['min']))
|
||||
{
|
||||
@ -203,7 +203,7 @@ class Date extends Transformer
|
||||
$value = $min;
|
||||
}
|
||||
}
|
||||
if (!empty($this->attrs['max']))
|
||||
if (!empty($this->attrs['max']) && !empty($value))
|
||||
{
|
||||
if(is_numeric($this->attrs['max']))
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user