2013-02-28 00:46:37 +04:00
|
|
|
<input type="hidden" id="disableSharing" data-status="<?php p($_['disableSharing']); ?>">
|
2013-01-18 16:11:29 +04:00
|
|
|
<?php foreach($_['files'] as $file):
|
2013-01-22 15:30:12 +04:00
|
|
|
$relative_deleted_date = OCP\relative_modified_date($file['timestamp']);
|
2013-01-18 16:11:29 +04:00
|
|
|
// the older the file, the brighter the shade of grey; days*14
|
2013-02-19 13:23:34 +04:00
|
|
|
$relative_date_color = round((time()-$file['date'])/60/60/24*14);
|
2013-01-18 16:11:29 +04:00
|
|
|
if($relative_date_color>200) $relative_date_color = 200;
|
|
|
|
$name = str_replace('+', '%20', urlencode($file['name']));
|
|
|
|
$name = str_replace('%2F', '/', $name);
|
|
|
|
$directory = str_replace('+', '%20', urlencode($file['directory']));
|
|
|
|
$directory = str_replace('%2F', '/', $directory); ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
<tr data-filename="<?php p($file['name']);?>"
|
2013-03-04 15:12:27 +04:00
|
|
|
data-type="<?php ($file['type'] == 'dir')?p('dir'):p('file')?>"
|
2013-02-28 00:46:37 +04:00
|
|
|
data-mime="<?php p($file['mimetype'])?>"
|
|
|
|
data-permissions='<?php p($file['permissions']); ?>'
|
2013-01-22 15:00:04 +04:00
|
|
|
<?php if ( $_['dirlisting'] ): ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
id="<?php p($file['directory'].'/'.$file['name']);?>"
|
|
|
|
data-file="<?php p($file['directory'].'/'.$file['name']);?>"
|
2013-01-22 15:00:04 +04:00
|
|
|
data-timestamp=''
|
|
|
|
data-dirlisting=1
|
|
|
|
<?php else: ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
id="<?php p($file['name'].'.d'.$file['timestamp']);?>"
|
|
|
|
data-file="<?php p($file['name'].'.d'.$file['timestamp']);?>"
|
|
|
|
data-timestamp='<?php p($file['timestamp']);?>'
|
2013-01-22 15:00:04 +04:00
|
|
|
data-dirlisting=0
|
|
|
|
<?php endif; ?>>
|
2013-01-18 16:11:29 +04:00
|
|
|
<td class="filename svg"
|
|
|
|
<?php if($file['type'] == 'dir'): ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
style="background-image:url(<?php print_unescaped(OCP\mimetype_icon('dir')); ?>)"
|
2013-01-18 16:11:29 +04:00
|
|
|
<?php else: ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
style="background-image:url(<?php print_unescaped(OCP\mimetype_icon($file['mimetype'])); ?>)"
|
2013-01-18 16:11:29 +04:00
|
|
|
<?php endif; ?>
|
|
|
|
>
|
|
|
|
<?php if(!isset($_['readonly']) || !$_['readonly']): ?><input type="checkbox" /><?php endif; ?>
|
|
|
|
<?php if($file['type'] == 'dir'): ?>
|
2013-01-21 16:07:43 +04:00
|
|
|
<?php if( $_['dirlisting'] ): ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
<a class="name" href="<?php p($_['baseURL'].'/'.$name); ?>" title="">
|
2013-01-21 16:07:43 +04:00
|
|
|
<?php else: ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
<a class="name" href="<?php p($_['baseURL'].'/'.$name.'.d'.$file['timestamp']); ?>" title="">
|
2013-01-21 16:07:43 +04:00
|
|
|
<?php endif; ?>
|
2013-01-18 16:11:29 +04:00
|
|
|
<?php else: ?>
|
2013-01-21 16:07:43 +04:00
|
|
|
<?php if( $_['dirlisting'] ): ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
<a class="name" href="<?php p($_['downloadURL'].'/'.$name); ?>" title="">
|
2013-01-21 16:07:43 +04:00
|
|
|
<?php else: ?>
|
2013-02-28 00:46:37 +04:00
|
|
|
<a class="name" href="<?php p($_['downloadURL'].'/'.$name.'.d'.$file['timestamp']);?>" title="">
|
2013-01-21 16:07:43 +04:00
|
|
|
<?php endif; ?>
|
2013-01-18 16:11:29 +04:00
|
|
|
<?php endif; ?>
|
|
|
|
<span class="nametext">
|
|
|
|
<?php if($file['type'] == 'dir'):?>
|
2013-02-28 00:46:37 +04:00
|
|
|
<?php print_unescaped(htmlspecialchars($file['name']));?>
|
2013-01-18 16:11:29 +04:00
|
|
|
<?php else:?>
|
2013-02-28 00:46:37 +04:00
|
|
|
<?php print_unescaped(htmlspecialchars($file['basename']));?><span
|
|
|
|
class='extension'><?php p($file['extension']);?></span>
|
2013-01-18 16:11:29 +04:00
|
|
|
<?php endif;?>
|
|
|
|
</span>
|
|
|
|
<?php if($file['type'] == 'dir'):?>
|
|
|
|
<span class="uploadtext" currentUploads="0">
|
|
|
|
</span>
|
|
|
|
<?php endif;?>
|
|
|
|
</a>
|
|
|
|
</td>
|
|
|
|
<td class="date">
|
|
|
|
<span class="modified"
|
2013-02-28 00:46:37 +04:00
|
|
|
title="<?php p($file['date']); ?>"
|
|
|
|
style="color:rgb(<?php p($relative_date_color.','
|
2013-01-18 16:11:29 +04:00
|
|
|
.$relative_date_color.','
|
2013-02-28 00:46:37 +04:00
|
|
|
.$relative_date_color) ?>)">
|
|
|
|
<?php p($relative_deleted_date); ?>
|
2013-01-18 16:11:29 +04:00
|
|
|
</span>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<?php endforeach;
|