Commit a7653de5 authored by Sebastien Robin's avatar Sebastien Robin

added dates


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@1134 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 8e1487d0
...@@ -36,6 +36,7 @@ from Products.ERP5Type.Document.Folder import Folder ...@@ -36,6 +36,7 @@ from Products.ERP5Type.Document.Folder import Folder
from Products.ERP5Type.Base import Base from Products.ERP5Type.Base import Base
from Products.ERP5Type import Permissions from Products.ERP5Type import Permissions
from Products.ERP5Type import PropertySheet from Products.ERP5Type import PropertySheet
from DateTime import DateTime
from zLOG import LOG from zLOG import LOG
import md5 import md5
...@@ -258,6 +259,9 @@ class Signature(SyncCode,Folder): ...@@ -258,6 +259,9 @@ class Signature(SyncCode,Folder):
self.setPublisherXupdate(None) self.setPublisherXupdate(None)
if len(self.getConflictList())>0: if len(self.getConflictList())>0:
self.resetConflictList() self.resetConflictList()
# XXX This may be a problem, if the document is changed
# during a synchronization
self.setLastSynchronizationDate(DateTime())
if status == self.NOT_SYNCHRONIZED: if status == self.NOT_SYNCHRONIZED:
self.setTempXML(None) self.setTempXML(None)
self.setPartialXML(None) self.setPartialXML(None)
...@@ -283,6 +287,34 @@ class Signature(SyncCode,Folder): ...@@ -283,6 +287,34 @@ class Signature(SyncCode,Folder):
""" """
self.force = force self.force = force
def getLastModificationDate(self):
"""
get the last modfication date, so that we don't always
check the xml
"""
return getattr(self,'modification_date',None)
def setLastModificationDate(self,value):
"""
set the last modfication date, so that we don't always
check the xml
"""
setattr(self,'modification_date',value)
def getLastSynchronizationDate(self):
"""
get the last modfication date, so that we don't always
check the xml
"""
return getattr(self,'synchronization_date',None)
def setLastSynchronizationDate(self,value):
"""
set the last modfication date, so that we don't always
check the xml
"""
setattr(self,'synchronization_date',value)
def setXML(self, xml): def setXML(self, xml):
""" """
set the XML corresponding to the object set the XML corresponding to the object
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment