Introduce backend_view_entry hook (#511)

Gives plugins the option to modify the central entry list in the plugin, so far to show additional information
This commit is contained in:
onli 2017-05-11 22:48:27 +02:00
parent bfeccabcdb
commit 74f7acb69d
2 changed files with 5 additions and 1 deletions

View File

@ -354,7 +354,8 @@ switch($serendipity['GET']['adminAction']) {
}
}
$smartentries[] = array(
$smartentry = array(
'id' => $ey['id'],
'title' => serendipity_specialchars($ey['title']),
'timestamp' => (int)$ey['timestamp'],
@ -368,6 +369,8 @@ switch($serendipity['GET']['adminAction']) {
'archive_link' => serendipity_archiveURL($ey['id'], $ey['title'], 'serendipityHTTPPath', true, array('timestamp' => $ey['timestamp'])),
'preview_link' => '?serendipity[action]=admin&serendipity[adminModule]=entries&serendipity[adminAction]=preview&' . serendipity_setFormToken('url') . '&serendipity[id]=' . $ey['id']
);
serendipity_plugin_api::hook_event('backend_view_entry', $smartentry);
$smartentries[] = $smartentry;
}

View File

@ -175,6 +175,7 @@
{if $entry.isdraft}
<span class="entry_status status_draft">{$CONST.DRAFT}</span>
{/if}
{$entry.info_more}
</div>
</li>
{/foreach}