summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorAlessandro Cosentino <cosenal@gmail.com>2012-08-12 21:30:42 -0400
committerAlessandro Cosentino <cosenal@gmail.com>2012-08-12 21:30:42 -0400
commitbe10a14e5877221041acd66a9da08e4514c8f8d1 (patch)
treeeff8ecca550cd0b4f69f57536beee2e167282e3d /templates
parent90fb216e7dd61c9571d225aa7c5c834c654d9cef (diff)
parent6c327bd5f8cdbebf45c6aa87f2d54f3dd26663a2 (diff)
Merge commit 'refs/merge-requests/12' of git://gitorious.org/owncloud/apps into merge-requests/12
Diffstat (limited to 'templates')
-rw-r--r--templates/main.php4
-rw-r--r--templates/part.items.php28
2 files changed, 22 insertions, 10 deletions
diff --git a/templates/main.php b/templates/main.php
index e02a29277..5c066e599 100644
--- a/templates/main.php
+++ b/templates/main.php
@@ -35,7 +35,9 @@ if ($_['feedid']){
<div id="rightcontent" class="rightcontent" data-id="<?php echo $_['feedid']; ?>">
<?php
echo $this->inc("part.items.header");
- echo $this->inc("part.items");
+ echo '<div id="feed_items">';
+ echo $this->inc("part.items");
+ echo '</div>';
?>
<div id="appsettings" class="popup bottomleft hidden"></div>
diff --git a/templates/part.items.php b/templates/part.items.php
index 7334fa35a..e481bd2d2 100644
--- a/templates/part.items.php
+++ b/templates/part.items.php
@@ -5,14 +5,13 @@ $feedid = isset($_['feedid']) ? $_['feedid'] : '';
$itemmapper = new OCA\News\ItemMapper();
$items = $itemmapper->findAll($feedid);
-echo '<div id="feed_items">';
echo '<ul>';
foreach($items as $item) {
if($item->isRead()){
- $newsItemClass = "title_read";
+ $newsItemClass = "read";
} else {
- $newsItemClass = "title_unread";
+ $newsItemClass = "";
}
if($item->isImportant()){
@@ -23,14 +22,25 @@ foreach($items as $item) {
$startTitle = $l->t('Mark as important');
}
- echo '<li class="news_item ' . $newsItemClass .'" data-id="' . $item->getId() . '" data-feedid="' . $feedid . '">';
- echo '<div class="item_utils"><ul>';
- echo '<li class="star ' . $starClass . '" title="' . $startTitle . '"></li>';
- echo '</ul></div>';
- echo '<h1 class="item_title"><a target="_blank" href="' . $item->getUrl() . '">' . $item->getTitle() . '</a></h1>';
+ echo '<li class="feed_item ' . $newsItemClass .'" data-id="' . $item->getId() . '" data-feedid="' . $feedid . '">';
+
+ echo '<div class="utils">';
+ echo '<ul class="primary_item_utils">';
+ echo '<li class="star ' . $starClass . '" title="' . $startTitle . '"></li>';
+ echo '</ul>';
+
+ echo '<ul class="secondary_item_utils">';
+ echo '<li class="keep_unread">' . $l->t('Keep unread') . '<input type="checkbox" /></li>';
+ echo '</ul>';
+ echo '</div>';
+
+ echo '<h1 class="item_title"><a target="_blank" href="' . $item->getUrl() . '">' . $item->getTitle() . '</a></h1>';
+
+ echo '<h2 class="item_author">' . $l->t('from') . ' ' . parse_url($item->getUrl())['host'] . '</h2>';
+
echo '<div class="body">' . $item->getBody() . '</div>';
+
echo '</li>';
}
echo '</ul>';
-echo '</div>';