summaryrefslogtreecommitdiff
path: root/app/models
diff options
context:
space:
mode:
authorhukl <contact@smyck.org>2009-03-04 23:58:14 +0100
committerhukl <contact@smyck.org>2009-03-04 23:58:14 +0100
commitef8246f1caeaa81a9bae20b1e1e9592614d85c0c (patch)
treeac9677d6b4187e5194636ee2cd37709097de29bf /app/models
parentbd0ec81f6f6b1129bb78a7c5d813c1d87c8dbcac (diff)
new public_link method for pages which includes locale
Diffstat (limited to 'app/models')
-rw-r--r--app/models/page.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/page.rb b/app/models/page.rb
index 0d4da5d..950d9f2 100644
--- a/app/models/page.rb
+++ b/app/models/page.rb
@@ -94,6 +94,10 @@ class Page < ActiveRecord::Base
94 end 94 end
95 end 95 end
96 96
97 def public_link
98 "#{I18n.locale}/#{node.unique_name}"
99 end
100
97 def clone_attributes_from page 101 def clone_attributes_from page
98 return nil unless page 102 return nil unless page
99 103