Created
June 12, 2014 08:24
-
-
Save osiro/79686a50244970f42fe2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- # TODO add in data for project creator (John Smith) and location (Perth, WA) | |
.project-tiles | |
.recent-projects | |
- if projects.count(:all) > 0 # just "count" raises an exception: https://github.com/Casecommons/pg_search/issues/127 | |
- projects.each do |project| | |
%article.project{ data: { project: { id: project.id } } } | |
.project-thumbnail | |
= link_to project_path(project) do | |
= image_tag(project.thumbnail.url) | |
.project-details | |
= link_to project_path(project) do | |
%h3= truncate(project.title, length: 50) | |
.creator | |
= link_to 'John Smith', "#" | |
%p= truncate(project.description, length: 100) | |
%span.location Perth, WA | |
- else | |
.general-message | |
%h3 Sorry, no projects found. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment