From aa42a633820d42fc2bc8d18d499eec559f2c43b7 Mon Sep 17 00:00:00 2001 From: Julie Lala Date: Thu, 17 Jul 2014 14:36:07 -0400 Subject: fix index --- views/home.ejs | 22 +--------------------- views/profile.ejs | 4 ++++ views/projects/list-projects.ejs | 11 ++++++++--- 3 files changed, 13 insertions(+), 24 deletions(-) (limited to 'views') diff --git a/views/home.ejs b/views/home.ejs index 45a6e6f..8b83a8f 100755 --- a/views/home.ejs +++ b/views/home.ejs @@ -24,27 +24,7 @@

Room Showcase

- - [[ include projects/list-projects ]] - - - - - - - - - - -
- Pace Gallery • 7.1.14 - - Pace Gallery • 7.1.14 -
- Pace Gallery • 7.1.14 - - Pace Gallery • 7.1.14 -
+ [[ include projects/list-projects ]] View More diff --git a/views/profile.ejs b/views/profile.ejs index 7bdbd51..8dd3c6d 100644 --- a/views/profile.ejs +++ b/views/profile.ejs @@ -38,6 +38,10 @@ + + [[ if (projects.length) { ]] +

[[- profile.username ]] has [[- projects.length ]] project[[- projects.length != 1 ? "s" : "" ]]

+ [[ } ]] [[ include projects/list-projects ]] diff --git a/views/projects/list-projects.ejs b/views/projects/list-projects.ejs index 205e778..3c71823 100644 --- a/views/projects/list-projects.ejs +++ b/views/projects/list-projects.ejs @@ -1,17 +1,22 @@ [[ if (projects.length) { ]] -

[[- profile.username ]] has [[- projects.length ]] project[[- projects.length != 1 ? "s" : "" ]]

- + [[ projects.forEach(function(project, i) { ]] + [[ if (i % 4 == 1) { ]] + + [[ } ]] + [[ }) ]] -- cgit v1.2.3-70-g09d2
+ [[ if (i == 0) { ]] - [[ if (profile._id == project.user_id) { ]] + [[ } ]] + [[ if (profile && profile._id == project.user_id) { ]]
edit
[[ } ]] [[- project.name ]]
[[- project.date ]]