1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
<?php
use Garradin\Entities\Files\File;
?>
{include file="admin/_head.tpl" title="Documents" current="docs"}
<nav class="tabs">
<aside>
{linkbutton shape="search" label="Rechercher" href="search.php"}
{if $context == File::CONTEXT_DOCUMENTS}
{linkbutton shape="plus" label="Nouveau répertoire" target="_dialog" data-dialog-class="small" href="!docs/new_dir.php?parent=%s"|args:$path}
{linkbutton shape="upload" label="Ajouter un fichier" target="_dialog" data-dialog-class="small" href="!common/files/upload.php?p=%s"|args:$path}
{/if}
</aside>
<ul>
<li{if $context == File::CONTEXT_DOCUMENTS} class="current"{/if}><a href="./">Documents</a></li>
{if $session->canAccess($session::SECTION_ACCOUNTING, $session::ACCESS_ADMIN)}
<li{if $context == File::CONTEXT_TRANSACTION} class="current"{/if}><a href="./?p=<?=File::CONTEXT_TRANSACTION?>">Fichiers des écritures</a></li>
{/if}
|
|
|
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
<?php
use Garradin\Entities\Files\File;
?>
{include file="admin/_head.tpl" title="Documents" current="docs"}
<nav class="tabs">
<aside>
{linkbutton shape="search" label="Rechercher" href="search.php"}
{if $context == File::CONTEXT_DOCUMENTS}
{linkbutton shape="plus" label="Nouveau répertoire" target="_dialog" href="!docs/new_dir.php?parent=%s"|args:$path}
{linkbutton shape="upload" label="Ajouter un fichier" target="_dialog" href="!common/files/upload.php?p=%s"|args:$path}
{/if}
</aside>
<ul>
<li{if $context == File::CONTEXT_DOCUMENTS} class="current"{/if}><a href="./">Documents</a></li>
{if $session->canAccess($session::SECTION_ACCOUNTING, $session::ACCESS_ADMIN)}
<li{if $context == File::CONTEXT_TRANSACTION} class="current"{/if}><a href="./?p=<?=File::CONTEXT_TRANSACTION?>">Fichiers des écritures</a></li>
{/if}
|
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
<tr>
{if $can_delete}
<td class="check">
{input type="checkbox" name="check[]" value=$file.id}
</td>
{/if}
<th><a href="?p={$file->path()}">{$file.name}</a></th>
<td colspan="3"></td>
<td class="actions">{linkbutton href="!common/files/delete.php?p=%s"|args:$file->pathname() label="Supprimer" shape="delete" target="_dialog"}</td>
</tr>
{else}
</tr>
{if $can_delete}
<td class="check">
{input type="checkbox" name="check[]" value=$file.id}
</td>
{/if}
<th><a href="{if $file->canPreview()}{$admin_url}common/files/preview.php?p={$file->pathname()}{else}{$file->url(true)}{/if}" target="_dialog">{$file.name}</th>
<td>{$file.modified|date}</td>
<td>{$file.type}</td>
<td>{$file.size|size_in_bytes}</td>
<td class="actions">
{if $file->canPreview()}
{linkbutton href="!common/files/preview.php?p=%s"|args:$file->pathname() label="Voir" shape="eye" target="_dialog"}
{/if}
{linkbutton href=$file->url(true) label="Télécharger" shape="download"}
{if $can_write && $file->getEditor()}
{linkbutton href="!common/files/edit.php?p=%s"|args:$file->pathname() label="Modifier" shape="edit" target="_dialog"}
{/if}
{linkbutton href="!common/files/delete.php?p=%s"|args:$file->pathname() label="Supprimer" shape="delete" target="_dialog"}
</td>
|
|
>
>
>
|
>
>
>
>
>
|
|
|
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
|
<tr>
{if $can_delete}
<td class="check">
{input type="checkbox" name="check[]" value=$file.id}
</td>
{/if}
<th><a href="?p={$file->path()}">{$file.name}</a></th>
<td></td>
<td>Répertoire</td>
<td></td>
<td class="actions">{linkbutton href="!common/files/delete.php?p=%s"|args:$file->pathname() label="Supprimer" shape="delete" target="_dialog"}</td>
</tr>
{else}
</tr>
{if $can_delete}
<td class="check">
{input type="checkbox" name="check[]" value=$file.id}
</td>
{/if}
<th>
{if $file->canPreview()}
<a href="{"!common/files/preview.php?p=%s"|local_url|args:$file->pathname()}" target="_dialog" data-mime="{$file.mime}">{$file.name}</a>
{else}
<a href="{$file->url(true)}" target="_blank">{$file.name}</a>
{/if}
</th>
<td>{$file.modified|date}</td>
<td>{$file.mime}</td>
<td>{$file.size|size_in_bytes}</td>
<td class="actions">
{if $file->canPreview()}
{linkbutton href="!common/files/preview.php?p=%s"|args:$file->pathname() label="Voir" shape="eye" target="_dialog" data-mime=$file.mime}
{/if}
{linkbutton href=$file->url(true) label="Télécharger" shape="download"}
{if $can_write && $file->getEditor()}
{linkbutton href="!common/files/edit.php?p=%s"|args:$file->pathname() label="Modifier" shape="edit" target="_dialog"}
{/if}
{linkbutton href="!common/files/delete.php?p=%s"|args:$file->pathname() label="Supprimer" shape="delete" target="_dialog"}
</td>
|