From 359446212a8501e30a3e03cb6deb38c533fca81a Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Sun, 20 Jul 2008 07:45:55 +0000 Subject: [PATCH] API CHANGE Changed BlogEntry->Tags() to TagsCollection() to avoid confusion with the property "Tags" which is of DBField type "Text" (not DataObjectSet) - necessary to adjust to changed DataObject-write() behaviour of using DBField instances to write the value (rather than directly editing the SQL manipulation). See r52927 for details. --- code/BlogEntry.php | 2 +- templates/Includes/BlogSummary.ss | 4 ++-- templates/Layout/BlogEntry.ss | 4 ++-- templates/TagCloudWidget.ss | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/code/BlogEntry.php b/code/BlogEntry.php index 3ca53ba..06b5f33 100644 --- a/code/BlogEntry.php +++ b/code/BlogEntry.php @@ -83,7 +83,7 @@ class BlogEntry extends Page { /** * Returns the tags added to this blog entry */ - function Tags() { + function TagsCollection() { $theseTags = split(" *, *", trim($this->Tags)); $output = new DataObjectSet(); diff --git a/templates/Includes/BlogSummary.ss b/templates/Includes/BlogSummary.ss index 5b2207b..ff838fa 100644 --- a/templates/Includes/BlogSummary.ss +++ b/templates/Includes/BlogSummary.ss @@ -1,10 +1,10 @@

$MenuTitle

<% _t('POSTEDBY') %> $Author.XML <% _t('POSTEDON', 'on') %> $Date.Long | $Comments.Count <% _t('COMMENTS', 'Comments') %>

- <% if Tags %> + <% if TagsCollection %>

Tags: - <% control Tags %> + <% control TagsCollection %> <% if Last %><% else %>,<% end_if %> <% end_control %>

diff --git a/templates/Layout/BlogEntry.ss b/templates/Layout/BlogEntry.ss index 260958f..cb10b23 100644 --- a/templates/Layout/BlogEntry.ss +++ b/templates/Layout/BlogEntry.ss @@ -5,10 +5,10 @@

$Title

<% _t('POSTEDBY', 'Posted by') %> $Author.XML <% _t('POSTEDON', 'on') %> $Date.Long | $Comments.Count <% _t('COMMENTS', 'Comments') %>

- <% if Tags %> + <% if TagsCollection %>

<% _t('TAGS', 'Tags:') %> - <% control Tags %> + <% control TagsCollection %> <% if Last %><% else %>,<% end_if %> <% end_control %>

diff --git a/templates/TagCloudWidget.ss b/templates/TagCloudWidget.ss index 14939d6..773987c 100644 --- a/templates/TagCloudWidget.ss +++ b/templates/TagCloudWidget.ss @@ -1,5 +1,5 @@

- <% control Tags %> + <% control TagsCollection %> $Tag <% end_control %>

\ No newline at end of file