From: richard Date: Mon, 23 Sep 2002 08:24:51 +0000 (+0000) Subject: import fixes X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=ed514ee429ad97c9e57248e5215a857b5c9ab51d;p=roundup.git import fixes git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1213 57a73879-2fb5-44c3-a270-3262357dd7e2 --- diff --git a/roundup/backends/rdbms_common.py b/roundup/backends/rdbms_common.py index b5572e3..f6fe029 100644 --- a/roundup/backends/rdbms_common.py +++ b/roundup/backends/rdbms_common.py @@ -1,4 +1,4 @@ -# $Id: rdbms_common.py,v 1.13 2002-09-23 08:17:05 richard Exp $ +# $Id: rdbms_common.py,v 1.14 2002-09-23 08:24:51 richard Exp $ # standard python modules import sys, os, time, re, errno, weakref, copy @@ -462,10 +462,13 @@ class Database(FileStorage, hyperdb.Database, roundupdb.Database): cl = self.classes[classname] cols, mls = self.determine_columns(cl.properties.items()) - # add the special props - node = node.copy() - node['creation'] = node['activity'] = date.Date() - node['creator'] = self.curuserid + # we'll be supplied these props if we're doing an import + if not node.has_key('creator'): + # add in the "calculated" properties (dupe so we don't affect + # calling code's node assumptions) + node = node.copy() + node['creation'] = node['activity'] = date.Date() + node['creator'] = self.curuserid # default the non-multilink columns for col, prop in cl.properties.items():