Mercurial > hg > Members > nobuyasu > tasks
changeset 3:cb113e610e08 draft
modified index.html
author | e085711 |
---|---|
date | Thu, 13 Sep 2012 01:44:23 +0900 |
parents | b216e48fc4a5 |
children | 76e3d7881a20 |
files | app/views/Application/index.html |
diffstat | 1 files changed, 4 insertions(+), 46 deletions(-) [+] |
line wrap: on
line diff
--- a/app/views/Application/index.html Thu Sep 13 01:40:32 2012 +0900 +++ b/app/views/Application/index.html Thu Sep 13 01:44:23 2012 +0900 @@ -2,59 +2,17 @@ #{set title:'Home' /} #{if frontPost} - <div class="post"> - <h2 class="post-title"> - <a href="#">${frontPost.title}</a> - </h2> - - <div clas="post-metadata"> - <span class="post-author">by ${frontPost.author.fullname}</span> - <span class="post-data">by ${frontPost.postedAt.format('MMM dd')}</span> - <span class="post-comments"> - | - ${frontPost.comments.size() ?:'no'} - comment${frontPost.comments.size().pluralize()} - #{if frontPost.comments} - ,latest by ${PfrontPost.comments[-1].author} - - #{/if} - </span> - </div> - <div class="post-content"> - ${frontPost.content.nl2br()} - </div> - </div> - #{if olderPosts} + #{display post:frontPost, as:'home' /} + + #{if olderPosts.size()} <div class="older-posts"> <h3>Older posts <span class="from">from this blog</span></h3> - #{list items:olderPosts, as:'oldPost'} - <div class="post"> - <h2 class="post-title"> - <a href="#">${oldPost.title}</a> - </h2> - <div class="post-metadata"> - <span class="post-author"> - by ${oldPost.author.fullname} - </span> - <span class="post-date"> - ${oldPost.postedAt.format('dd MMM yy')} - </span> - <div class="post-comments"> - ${oldPost.comments.size() ?:'no'} - comment${oldPost.comments.size().pluralize()} - #{if oldPost.comments} - - latest by ${oldPost.comments[-1].author} - #{/if} - </div> - </div> - </div> + #{display post:oldPost, as:'teaser'/} #{/list} </div> - #{/if} - #{/if}