N°3921 - Attribute file: Simplify size format in the backoffice (similar to the portal)

This commit is contained in:
Molkobain
2021-04-12 10:21:28 +02:00
parent 530ec111ef
commit 5878b18b02
2 changed files with 8 additions and 12 deletions

View File

@@ -118,7 +118,8 @@ class ormDocument
else
{
$data = $this->GetData();
$sResult = htmlentities($this->GetFileName(), ENT_QUOTES, 'UTF-8').' [ '.$this->GetMimeType().', size: '.strlen($data).' byte(s) ]<br/>';
$sSize = utils::BytesToFriendlyFormat(strlen($data));
$sResult = htmlentities($this->GetFileName(), ENT_QUOTES, 'UTF-8').' ('.$sSize.')<br/>';
}
return $sResult;
}