From 1d6fedf71272c6c0776b1701ddc3d85cd8fa0ec6 Mon Sep 17 00:00:00 2001 From: Skud Date: Mon, 26 Nov 2012 20:53:00 +1100 Subject: [PATCH] extracted crop thumbnail into a partial --- app/views/crops/_thumbnail.html.haml | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 app/views/crops/_thumbnail.html.haml diff --git a/app/views/crops/_thumbnail.html.haml b/app/views/crops/_thumbnail.html.haml new file mode 100644 index 000000000..b01c46849 --- /dev/null +++ b/app/views/crops/_thumbnail.html.haml @@ -0,0 +1,9 @@ + +.thumbnail(style='height: 200px') + = image_tag('http://placehold.it/150x150', :alt => '', :class => 'img-rounded') + %p= link_to crop.system_name, crop + - if crop.scientific_names.count > 0 + %p + %i + %small + = crop.scientific_names.first.scientific_name