List of New Articles

This page uses a Hashtag List to show Articles marked as New.   The table is styled using Bootstrap 3 default theme classes.   Methods are provided to mark Articles as Reviewed or Rejected.  
Status Headline Action
new New Headline Mark Reviewed Mark Rejected
new New Headline Mark Reviewed Mark Rejected



Processed this Hashtag Markup:
<# start list for articles;
	include when status is "new";
	show 10 rows per page;
#>

<# start header #>
<table class="table table-striped table-hover">
	<thead>
	<tr>
		<th>Status</th>
		<th>Headline</th>
		<th>Action</th>
	</tr>
	</thead>
<# end header #>

<# start row #>
	<tr>
		<td><# status #></td>
		<td><# headline as html #></td>
		<td><a href="mark-reviewed?id=<# id #>" class="label label-primary">Mark Reviewed</a>
			<a href="mark-rejected?id=<# id #>" class="label label-primary">Mark Rejected</a>
		</td>
	</tr>
<# end row #>

<# start footer #>
</table>
<# end footer #>

<# no results #>
<h4 class="alert alert-warning text-center">No New Articles</h4>
<# end no results #>

<# end list #>

Hashtag Markup for Mark Reviewed Action: /articles/mark-reviewed
<# update record for "articles.<#[url.id]#>" reference as "article";
	set article.status to "reviewed";
	redirect to "/articles/new?index=<#[url.index]#>";
#>

Hashtag Markup for Mark Rejected Action: /articles/mark-rejected
<# update record for "articles.<#[url.id]#>" reference as "article";
	set article.status to "rejected";
	redirect to "/articles/new?index=<#[url.index]#>";
#>

The Articles Mini-App uses the Hashtag Markup Language to provide a review process for Article Headlines.

Articles are stored in an SQL database.   Methods are provided to mark articles as reviewed, or update or delete any existing articles.