index 09425b2ac35ce557ac24c11d5f93829cb8fbd827..5798c8d646e1ab223a16db221e06f52cf47a05e2 100644 (file)
continue
cvt = self.to_hyperdb_value(property.__class__)
if isinstance(property, Password):
- params[param] = cvt(value)
+ params[param] = password.JournalPassword(value)
elif isinstance(property, Date):
params[param] = cvt(value)
elif isinstance(property, Interval):
if not isinstance(value, password.Password):
raise TypeError('new property "%s" not a Password'%propname)
propvalues[propname] = value
+ journalvalues[propname] = \
+ current and password.JournalPassword(current)
elif value is not None and isinstance(prop, Date):
if not isinstance(value, date.Date):
raise DatabaseError(_('Database open read-only'))
self.db.destroynode(self.classname, nodeid)
- def history(self, nodeid):
- """Retrieve the journal of edits on a particular node.
-
- 'nodeid' must be the id of an existing node of this class or an
- IndexError is raised.
-
- The returned list contains tuples of the form
-
- (nodeid, date, tag, action, params)
-
- 'date' is a Timestamp object specifying the time of the change and
- 'tag' is the journaltag specified when the database was opened.
- """
- if not self.do_journal:
- raise ValueError('Journalling is disabled for this class')
- return self.db.getjournal(self.classname, nodeid)
-
# Locating nodes:
def hasnode(self, nodeid):
"""Determine if the given nodeid actually exists