-
Notifications
You must be signed in to change notification settings - Fork 24
/
showall_recent.tpl
126 lines (122 loc) · 5.16 KB
/
showall_recent.tpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
{*
* Copyright (c) 2004-2013 OIC Group, Inc.
*
* This file is part of Exponent
*
* Exponent is free software; you can redistribute
* it and/or modify it under the terms of the GNU
* General Public License as published by the Free
* Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* GPL: http://www.gnu.org/licenses/gpl.txt
*
*}
{css unique="blog" link="`$asset_path`css/blog.css"}
{/css}
{if $config.usecategories}
{css unique="categories" corecss="categories"}
{/css}
{/if}
<div class="module blog showall">
{if $moduletitle && !($config.hidemoduletitle xor $smarty.const.INVERT_HIDE_TITLE)}<h1>{/if}
{rss_link}
{if $moduletitle && !($config.hidemoduletitle xor $smarty.const.INVERT_HIDE_TITLE)}{'Recent Posts from'|gettext} '{$moduletitle}'</h1>{/if}
{permissions}
<div class="module-actions">
{if $permissions.edit == 1}
{icon class=add action=edit text="Add a new blog article"|gettext}
{/if}
{if $permissions.manage == 1}
{if !$config.disabletags}
{icon controller=expTag class="manage" action=manage_module model='blog' text="Manage Tags"|gettext}
{/if}
{if $config.usecategories}
{icon controller=expCat action=manage model='blog' text="Manage Categories"|gettext}
{/if}
{/if}
</div>
{/permissions}
{if $config.moduledescription != ""}
{$config.moduledescription}
{/if}
{subscribe_link}
{$myloc=serialize($__loc)}
{foreach name=items from=$page->records item=item}
{if $smarty.foreach.items.iteration<=$config.headcount || !$config.headcount}
<div class="item">
{if $config.datetag}
<p class="post-date">
<span class="month">{$item->publish_date|format_date:"%b"}</span>
<span class="day">{$item->publish_date|format_date:"%e"}</span>
<span class="year">{$item->publish_date|format_date:"%Y"}</span>
</p>
{/if}
<h2>
<a href="{link action=show title=$item->sef_url}" title="{$item->body|summarize:"html":"para"}">
{$item->title}
</a>
</h2>
<div class="post-info">
<span class="attribution">
{if $item->private}<strong>({'Draft'|gettext})</strong>{/if}
{if $item->publish_date > $smarty.now}
<strong>{'Will be'|gettext} 
{/if}
{$prepend = ''}
{if !$config.displayauthor}
<span class="label posted">{'Posted by'|gettext}</span>
<a href="{link action=showall_by_author author=$record->poster|username}">{attribution user_id=$record->poster}</a>
{$prepend = '  |  '}
{/if}
{if !$config.datetag}
{'on'|gettext} <span class="date">{$record->publish_date|format_date}</span>
{/if}
{if $record->publish_date > $smarty.now}
</strong> 
{/if}
</span>
{comments_count record=$record show=1 prepend=$prepend}
{tags_assigned record=$record prepend='  |  '}
</div>
{permissions}
<div class="item-actions">
{if $permissions.edit == 1}
{if $myloc != $item->location_data}
{if $permissions.manage == 1}
{icon action=merge id=$item->id title="Merge Aggregated Content"|gettext}
{else}
{icon img='arrow_merge.png' title="Merged Content"|gettext}
{/if}
{/if}
{icon action=edit record=$item}
{/if}
{if $permissions.delete == 1}
{icon action=delete record=$item}
{/if}
</div>
{/permissions}
{if $config.usebody!=2}
<div class="bodycopy">
{if $config.ffloat != "Below"}
{filedisplayer view="`$config.filedisplay`" files=$item->expFile record=$item is_listing=1}
{/if}
{if $config.usebody==1}
<p>{$item->body|summarize:"html":"paralinks"}</p>
{elseif $config.usebody==2}
{else}
{$item->body}
{/if}
{if $config.ffloat == "Below"}
{filedisplayer view="`$config.filedisplay`" files=$item->expFile record=$item is_listing=1}
{/if}
</div>
{clear}
{/if}
</div>
{/if}
{/foreach}
{if $page->total_records > $config.headcount}
{pagelinks paginate=$page more=1 text="More Items in"|gettext|cat:' '|cat:$moduletitle|cat:' ...'}
{/if}
</div>