aboutsummaryrefslogtreecommitdiffstats
path: root/src/_helpers/band_helper.rb
diff options
context:
space:
mode:
Diffstat (limited to 'src/_helpers/band_helper.rb')
-rw-r--r--src/_helpers/band_helper.rb30
1 files changed, 29 insertions, 1 deletions
diff --git a/src/_helpers/band_helper.rb b/src/_helpers/band_helper.rb
index 0380184..812892d 100644
--- a/src/_helpers/band_helper.rb
+++ b/src/_helpers/band_helper.rb
@@ -1,9 +1,37 @@
puts "Loading BandHelper..."
module BandHelper
+
def bandlinks_all
"#{link('Exeloume', 'http://www.facebook.com/exeloume')}, " +
"#{link('Imbalance', 'http://www.imbalance.no')} og " +
"#{link('Ninth Circle', 'http://www.ninthcircle.no')}"
end
-end \ No newline at end of file
+
+ def tourdate(date, venue, town, comments = "")
+ rendered_date = tag "span", :class => "date" do
+ date
+ end
+
+ rendered_venue = tag "span", :class => "venue" do
+ venue
+ end
+
+ rendered_town = tag "span", :class => "town" do
+ town
+ end
+
+ output = "#{rendered_date}: #{rendered_venue}, #{rendered_town}"
+
+ unless comments.empty?
+ rendered_comments = tag "span", :class => "comments" do
+ "(#{comments})"
+ end
+ output += " #{rendered_comments}"
+ end
+
+ tag "li", :class => "tour_entry" do
+ output
+ end
+ end
+end