Intermediate commit:
* Improved tag framework * Added support for image tags * Moved most code of StoryMgr.evalNewStory to Story.evalStory to decrease redundancy * Added compatibility module (including drafts for database conversions) * Moved code for topics to compatibility module * Removed obsolete code
This commit is contained in:
parent
d5c59cf2ec
commit
09b39b2af3
48 changed files with 872 additions and 494 deletions
|
@ -1,2 +0,0 @@
|
|||
<% #item %>
|
||||
<% tagjoin.parent.skin name="preview" %>
|
|
@ -1,7 +1,31 @@
|
|||
//
|
||||
// The Antville Project
|
||||
// http://code.google.com/p/antville
|
||||
//
|
||||
// Copyright 2001-2007 by The Antville People
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the ``License'');
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an ``AS IS'' BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// $Revision$
|
||||
// $LastChangedBy$
|
||||
// $LastChangedDate$
|
||||
// $URL$
|
||||
//
|
||||
|
||||
TagHub.prototype.constructor = function(name, tagged, user) {
|
||||
var site = res.handlers.site;
|
||||
var tag = site.tags.get(name);
|
||||
if (!tag) {
|
||||
if (!tag || tag.type !== tagged._prototype) {
|
||||
tag = new Tag(name, site, tagged._prototype);
|
||||
site.tags.add(tag);
|
||||
}
|
||||
|
@ -13,10 +37,10 @@ TagHub.prototype.constructor = function(name, tagged, user) {
|
|||
|
||||
TagHub.prototype.getMacroHandler = function(name) {
|
||||
switch (name.toLowerCase()) {
|
||||
case "parent":
|
||||
case "tagged":
|
||||
case "story":
|
||||
case "image":
|
||||
return this.parent;
|
||||
return this.tagged;
|
||||
break;
|
||||
}
|
||||
};
|
||||
|
|
1
code/TagHub/TagHub.skin
Normal file
1
code/TagHub/TagHub.skin
Normal file
|
@ -0,0 +1 @@
|
|||
<% taghub.tagged.skin name="preview" %>
|
|
@ -1,3 +1,27 @@
|
|||
##
|
||||
## The Antville Project
|
||||
## http://code.google.com/p/antville
|
||||
##
|
||||
## Copyright 2001-2007 by The Antville People
|
||||
##
|
||||
## Licensed under the Apache License, Version 2.0 (the ``License'');
|
||||
## you may not use this file except in compliance with the License.
|
||||
## You may obtain a copy of the License at
|
||||
##
|
||||
## http://www.apache.org/licenses/LICENSE-2.0
|
||||
##
|
||||
## Unless required by applicable law or agreed to in writing, software
|
||||
## distributed under the License is distributed on an ``AS IS'' BASIS,
|
||||
## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
## See the License for the specific language governing permissions and
|
||||
## limitations under the License.
|
||||
##
|
||||
## $Revision: 3300 $
|
||||
## $LastChangedBy: piefke3000 $
|
||||
## $LastChangedDate: 2007-06-30 21:25:35 +0200 (Sat, 30 Jun 2007) $
|
||||
## $URL$
|
||||
##
|
||||
|
||||
_db = antville
|
||||
_table = tag_hub
|
||||
_id = id
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue