mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 15:32:13 +00:00
fix parameter for addDocumentAttributes, editDocumentAttributes may return a string
This commit is contained in:
parent
070af52849
commit
0208d54409
|
@ -162,16 +162,20 @@ $(document).ready( function() {
|
|||
if($arr) {
|
||||
$this->formField($arr[0], $arr[1]);
|
||||
}
|
||||
} elseif(is_string($arr) {
|
||||
echo $arr;
|
||||
} else {
|
||||
$this->formField(htmlspecialchars($attrdef->getName()), $this->getAttributeEditField($attrdef, $document->getAttribute($attrdef)));
|
||||
}
|
||||
}
|
||||
}
|
||||
$arrs = $this->callHook('addDocumentAttributes', $folder);
|
||||
$arrs = $this->callHook('addDocumentAttributes', $document);
|
||||
if(is_array($arrs)) {
|
||||
foreach($arrs as $arr) {
|
||||
$this->formField($arr[0], $arr[1]);
|
||||
}
|
||||
} elseif(is_string($arr) {
|
||||
echo $arr;
|
||||
}
|
||||
$this->formSubmit("<i class=\"icon-save\"></i> ".getMLText('save'));
|
||||
?>
|
||||
|
|
Loading…
Reference in New Issue
Block a user