blob: 1a07fceee2587c2203c02638b6af6afe47e3de17 (
plain)
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
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
|
{* $Header: /cvsroot/bitweaver/_bit_articles/templates/list_articles.tpl,v 1.19 2006/09/03 20:04:53 squareing Exp $ *}
<div class="floaticon">{bithelp}</div>
{strip}
<div class="listing articles">
<div class="header">
<h1>{tr}Articles{/tr}</h1>
</div>
<div class="body">
{formfeedback hash=$feedback}
<div class="navbar">
<ul>
<li>{biticon ipackage="icons" iname="emblem-symbolic-link" iexplain="sort by"}</li>
{if $gBitSystem->isFeatureActive( 'articles_list_title' )}
<li>{smartlink ititle='Title' isort='title' offset=$offset type=$find_type topic=$find_topic}</li>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_author' )}
<li>{smartlink ititle='Author' isort='author_name' offset=$offset type=$find_type topic=$find_topic}</li>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_date' )}
<li>{smartlink ititle='Publish Date' isort='publish_date' offset=$offset type=$find_type topic=$find_topic}</li>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_expire' )}
<li>{smartlink ititle='Expire Date' isort='expire_date' offset=$offset type=$find_type topic=$find_topic}</li>
{/if}
</ul>
</div>
<div class="clear"></div>
{include file="bitpackage:articles/article_filter_inc.tpl"}
{form}
<table class="data">
<caption>{tr}Articles Listing{/tr}</caption>
<tr>
{if $gBitSystem->isFeatureActive( 'articles_list_img' )}
<th style="width:10px;">{tr}Image{/tr}</th>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_type' )}
<th>{smartlink ititle='Type' isort='type_name' offset=$offset type=$find_type topic=$find_topic}</th>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_topic' )}
<th>{smartlink ititle='Topic' isort='topic_name' offset=$offset type=$find_type topic=$find_topic}</th>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_status' )}
<th>{smartlink ititle='Status' isort='status_id' offset=$offset type=$find_type topic=$find_topic}</th>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_reads' )}
<th>{smartlink ititle='Reads' isort='hits' offset=$offset type=$find_type topic=$find_topic}</th>
{/if}
<th>{tr}Action{/tr}</th>
</tr>
{cycle values="even,odd" print=false}
{foreach item=article from=$listpages}
<tr class="{cycle advance=false}">
{if $gBitSystem->isFeatureActive( 'articles_list_img' )}
<td rowspan="2">
{if $article.image_url}
{if $gBitUser->hasPermission( 'p_articles_read' )}
<a href="{$article.display_url}">
{/if}
<img src="{$article.image_url}" title="{$article.title|escape}" alt="{tr}Article Image{/tr}" />
{if $gBitUser->hasPermission( 'p_articles_read' )}
</a>
{/if}
{/if}
</td>
{/if}
<td colspan="5">
{if $gBitSystem->isFeatureActive( 'articles_list_title' )}
<h2>
{if $gBitUser->hasPermission( 'p_articles_read' )}
<a href="{$article.display_url}">{$article.title|escape}</a>
{else}
{$article.title|escape}
{/if}
</h2>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_author' )}
{tr}Created by{/tr}: {displayname user=$article.author_name}
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_date' ) or $gBitSystem->isFeatureActive( 'articles_list_expire' )}<br />{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_date' ) and $gBitSystem->isFeatureActive( 'articles_list_expire' )}
{tr}Displayed from <strong>{$article.publish_date|bit_short_datetime}</strong> until <strong>{$article.expire_date|bit_short_datetime}</strong>{/tr}
{elseif $gBitSystem->isFeatureActive( 'articles_list_date' )}
{tr}Displayed from <strong>{$article.publish_date|bit_short_datetime}</strong>{/tr}
{elseif $gBitSystem->isFeatureActive( 'articles_list_expire' )}
{tr}Displayed until <strong>{$article.expire_date|bit_short_datetime}</strong>{/tr}
{/if}
</td>
</tr>
<tr class="{cycle}">
{if $gBitSystem->isFeatureActive( 'articles_list_type' )}
<td>{tr}{$article.type_name}{/tr}</td>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_topic' )}
<td>{$article.topic_name}</td>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_status' )}
<td>{$article.status_name}</td>
{/if}
{if $gBitSystem->isFeatureActive( 'articles_list_reads' )}
<td style="text-align:right;">{$article.hits}</td>
{/if}
<td style="text-align:right;">
{if $article.status_id eq $smarty.const.ARTICLE_STATUS_PENDING and $gBitUser->hasPermission( 'p_articles_approve_submission' )}
{smartlink ititle="Approve Article" ibiticon="icons/dialog-ok" sort_mode=$sort_mode status_id=$smarty.request.status_id article_id=$article.article_id content_id=$article.content_id set_status_id=$smarty.const.ARTICLE_STATUS_APPROVED action=approve}
{/if}
{if $gBitUser->hasPermission( 'p_articles_edit' ) or ( $article.author eq $user and $article.creator_edit eq 'y' )}
{smartlink ititle="Edit" ifile="edit.php" ibiticon="icons/accessories-text-editor" article_id=$article.article_id}
{/if}
{if $gBitUser->hasPermission( 'p_articles_remove' )}
{smartlink ititle="Remove" ibiticon="icons/edit-delete" action=remove remove_article_id=$article.article_id status_id=$smarty.request.status_id}
{/if}
</td>
</tr>
{foreachelse}
<tr class="norecords">
<td colspan="5">
{tr}No records found{/tr}
</td>
</tr>
{/foreach}
</table>
{/form}
{include file="bitpackage:kernel/pagination.tpl"}
</div><!-- end .body -->
</div><!-- end .article -->
{/strip}
|