summaryrefslogtreecommitdiff
path: root/templates/attachments.tpl
diff options
context:
space:
mode:
authorMax Kremmel <xing@synapse.plus.com>2006-11-26 12:51:58 +0000
committerMax Kremmel <xing@synapse.plus.com>2006-11-26 12:51:58 +0000
commit550bd1ca526bec8747df6e6fe3e318fbcd8207dd (patch)
treed8d003de0221d1284e533e5bada92031f13f605b /templates/attachments.tpl
parente60710ab7165adb3402a1cc39f8f4efe0b6eb2a5 (diff)
downloadliberty-550bd1ca526bec8747df6e6fe3e318fbcd8207dd.tar.gz
liberty-550bd1ca526bec8747df6e6fe3e318fbcd8207dd.tar.bz2
liberty-550bd1ca526bec8747df6e6fe3e318fbcd8207dd.zip
move getAttachmentList function to LibertyAttachable, where it belongs and add a basic page to list all available attachments - only admin may view attachments from other users as well. - functionally still somewhat lacking...
Diffstat (limited to 'templates/attachments.tpl')
-rw-r--r--templates/attachments.tpl60
1 files changed, 60 insertions, 0 deletions
diff --git a/templates/attachments.tpl b/templates/attachments.tpl
new file mode 100644
index 0000000..2484865
--- /dev/null
+++ b/templates/attachments.tpl
@@ -0,0 +1,60 @@
+{strip}
+<div class="listing liberty">
+ <div class="header">
+ <h1>{tr}Liberty Attachments{/tr}</h1>
+ </div>
+
+ <div class="body">
+ {if $gBitUser->isAdmin()}
+ {form legend="Attachment Filter"}
+ {formfeedback hash=$feedback}
+
+ <div class="row">
+ {formlabel label="User" for=""}
+ {forminput}
+ <input type="text" name="login" value="{$smarty.request.login}" />
+ {formhelp note="Enter the login name of a given user."}
+ {/forminput}
+ </div>
+
+ <div class="submit">
+ <input type="submit" name="apply" value="{tr}Filter{/tr}" />
+ </div>
+ {/form}
+ {/if}
+
+ <table class="data">
+ <caption>{tr}Liberty Attachments{/tr}</caption>
+ <tr>
+ <th style="width:1px"></th>
+ <th>{tr}Details{/tr}</th>
+ <th>{tr}Actions{/tr}</th>
+ </tr>
+ {foreach from=$attachments item=attachment}
+ <tr class="{cycle values="odd,even"}">
+ <td style="text-align:center">
+ <a href="{$attachment.source_url}">
+ <img src="{$attachment.thumbnail_url.small}" alt="{$attachment.filename}" title="{tr}Attachment Thumbnail{/tr}" />
+ </a>
+ </td>
+ <td>
+ {tr}Owner{/tr}: {displayname hash=$attachment}
+ <br />
+ {tr}Size{/tr}: {$attachment.file_size|kbsize}
+ <br />
+ {tr}Wiki plugin link{/tr}: {$attachment.wiki_plugin_link}
+ </td>
+ <td>
+ </td>
+ </tr>
+ {foreachelse}
+ <tr class="norecords"><td colspan="3">
+ {tr}No records found{/tr}
+ </td></tr>
+ {/foreach}
+ </table>
+
+ {pagination login=$smarty.request.login}
+ </div><!-- end .body -->
+</div><!-- end .liberty -->
+{/strip}