Added icons (thanks WIll! :D)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@39840 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Andrew O'Neil 2007-08-10 05:02:52 +00:00
parent ca4a3b91d8
commit 6b4cdc6dbb
5 changed files with 13 additions and 7 deletions

View File

@ -16,7 +16,7 @@ class FeedbackAdmin extends LeftAndMain {
return $this->getLastFormIn($this->renderWith('FeedbackAdmin_right'));
}
public function EditForm() {
public function Section() {
$url = rtrim($_SERVER['REQUEST_URI'], '/');
if(strrpos($url, '&')) {
$url = substr($url, 0, strrpos($url, '&'));
@ -27,6 +27,12 @@ class FeedbackAdmin extends LeftAndMain {
$section = 'accepted';
}
return $section;
}
public function EditForm() {
$section = $this->Section();
if($section == 'accepted') {
$filter = 'IsSpam=0 AND NeedsModeration=0';
$title = "<h2>Accepted Comments</h2>";

BIN
images/approvecomment.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
images/declinecomment.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@ -47,13 +47,13 @@
<td width="18"><a class="popuplink editlink" href="$EditLink" target="_blank"><img src="cms/images/edit.gif" alt="edit" /></a></td>
<% end_if %>
<% if HasAcceptButton %>
<td width="18"><a class="acceptlink" href="$AcceptLink" title="Accept this comment"><img src="cms/images/accept.gif" alt="accept" /></a></td>
<td width="18"><a class="acceptlink" href="$AcceptLink" title="Accept this comment"><img src="cms/images/approvecomment.png" alt="accept" /></a></td>
<% end_if %>
<% if HasSpamButton %>
<td width="18"><a class="spamlink" href="$SpamLink" title="Mark this comment as spam"><img src="cms/images/spam.gif" alt="spam" /></a></td>
<td width="18"><a class="spamlink" href="$SpamLink" title="Mark this comment as spam"><img src="cms/images/declinecomment.png" alt="spam" /></a></td>
<% end_if %>
<% if HasHamButton %>
<td width="18"><a class="hamlink" href="$HamLink" title="Mark this comment as not spam"><img src="cms/images/ham.gif" alt="ham" /></a></td>
<td width="18"><a class="hamlink" href="$HamLink" title="Mark this comment as not spam"><img src="cms/images/approvecomment.png" alt="ham" /></a></td>
<% end_if %>
<% if Can(delete) %>
<td width="18"><a class="deletelink" href="$DeleteLink" title="Delete this row"><img src="cms/images/delete.gif" alt="delete" /></a></td>

View File

@ -1,14 +1,14 @@
<ul id="sitetree" class="tree unformatted">
<li id="$ID" class="Root"><a>Comments</a>
<ul>
<li id="record-comments">
<li id="record-comments" <% if Section=accepted %>class="current"<% end_if %>>
<a href="$baseURL/admin/feedback/showtable/accepted" title="Accepted">Accepted</a>
</li>
<li id="record-unmoderated">
<li id="record-unmoderated" <% if Section=unmoderated %>class="current"<% end_if %>>
<a href="$baseURL/admin/feedback/showtable/unmoderated" title="Awaiting Moderation">Awaiting Moderation</a>
</li>
<li id="record-spam">
<a href="$baseURL/admin/feedback/showtable/spam" title="Spam">Spam</a>
<a href="$baseURL/admin/feedback/showtable/spam" title="Spam" <% if Section=spam %>class="current"<% end_if %>>Spam</a>
</li>
</ul>
</li>