mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-24 17:04:14 +01:00
do NOT overwrite everything, if vfs-upload is used without id:
- using fallback id of "file_widget" the client-side uses - ignore validation, if there is no id
This commit is contained in:
parent
0f7484812e
commit
d8827da73f
@ -47,6 +47,9 @@ class File extends Etemplate\Widget
|
||||
|
||||
if($xml) parent::__construct($xml);
|
||||
|
||||
// set fallback-id client-side uses
|
||||
if (empty($this->id)) $this->id = 'file_widget';
|
||||
|
||||
// Legacy multiple - id ends in []
|
||||
if(substr($this->id,-2) == '[]')
|
||||
{
|
||||
|
@ -352,7 +352,7 @@ class Vfs extends File
|
||||
parent::validate($cname, $expand, $content, $validated);
|
||||
break;
|
||||
}
|
||||
if (true) $valid = $value;
|
||||
if (!empty($this->id)) $valid = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user