diff options
author | Thomas Tanghus <thomas@tanghus.net> | 2013-05-17 04:54:08 +0200 |
---|---|---|
committer | Thomas Tanghus <thomas@tanghus.net> | 2013-05-17 04:54:08 +0200 |
commit | 152e275c8a780c220c5022ef059dd7b12adc7cf1 (patch) | |
tree | 3d4514d52158572ce1d3acb882072987e7c6cd8f /apps/files/ajax | |
parent | 4a8db293ececca68207761ee5e9c8323cf686bda (diff) | |
download | nextcloud-server-152e275c8a780c220c5022ef059dd7b12adc7cf1.tar.gz nextcloud-server-152e275c8a780c220c5022ef059dd7b12adc7cf1.zip |
Various cleanups in OC.dialogs
Diffstat (limited to 'apps/files/ajax')
-rw-r--r-- | apps/files/ajax/rawlist.php | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/apps/files/ajax/rawlist.php b/apps/files/ajax/rawlist.php index 1cd2944483c..f568afad4da 100644 --- a/apps/files/ajax/rawlist.php +++ b/apps/files/ajax/rawlist.php @@ -15,6 +15,14 @@ $mimetype = isset($_GET['mimetype']) ? $_GET['mimetype'] : ''; // make filelist $files = array(); +// If a type other than directory is requested first load them. +if($mimetype && strpos($mimetype, 'httpd/unix-directory') === false) { + foreach( \OC\Files\Filesystem::getDirectoryContent( $dir, 'httpd/unix-directory' ) as $i ) { + $i["date"] = OCP\Util::formatDate($i["mtime"] ); + $i['mimetype_icon'] = $i['type'] == 'dir' ? \mimetype_icon('dir'): \mimetype_icon($i['mimetype']); + $files[] = $i; + } +} foreach( \OC\Files\Filesystem::getDirectoryContent( $dir, $mimetype ) as $i ) { $i["date"] = OCP\Util::formatDate($i["mtime"] ); $i['mimetype_icon'] = $i['type'] == 'dir' ? \mimetype_icon('dir'): \mimetype_icon($i['mimetype']); |