mirror of
https://github.com/Karaka-Management/oms-Media.git
synced 2026-02-17 09:48:41 +00:00
Upload fixes
This commit is contained in:
parent
918ca094aa
commit
5509176eed
|
|
@ -59,6 +59,8 @@
|
||||||
return this.files.length;
|
return this.files.length;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// todo: maybe do file upload together with data upload in FormData.
|
||||||
|
// let the module forward the files to the media module?!
|
||||||
jsOMS.Modules.Models.Media.Upload.prototype.upload = function (formId)
|
jsOMS.Modules.Models.Media.Upload.prototype.upload = function (formId)
|
||||||
{
|
{
|
||||||
// TODO: validate file type + file size
|
// TODO: validate file type + file size
|
||||||
|
|
|
||||||
|
|
@ -36,6 +36,8 @@ echo $this->getData('nav')->render();
|
||||||
</table>
|
</table>
|
||||||
<?php if(in_array($media->getExtension(), ['gif', 'bmp', 'jpg', 'jpeg', 'png'])) : ?>
|
<?php if(in_array($media->getExtension(), ['gif', 'bmp', 'jpg', 'jpeg', 'png'])) : ?>
|
||||||
<img src="<?= $this->request->getUri()->getBase() . $media->getPath(); ?>">
|
<img src="<?= $this->request->getUri()->getBase() . $media->getPath(); ?>">
|
||||||
|
<?php elseif($media->getExtension() === 'collection') : ?>
|
||||||
|
collection
|
||||||
<?php else : ?>
|
<?php else : ?>
|
||||||
<pre>
|
<pre>
|
||||||
<?php
|
<?php
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user