Commit 468f02b6 authored by Bartek Górny's avatar Bartek Górny

status_message is now called external_processing_status_message

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@10553 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 8891bb30
......@@ -128,20 +128,20 @@ class ExternalDocument(DMSFile):
s,inf=self._spiderSource()
except Exception,e:
self.log(e,level=1)
self.setStatusMessage("Tried on %s: %s" % (self._time(),str(e)))
self.setExternalProcessingStatusMessage("Tried on %s: %s" % (self._time(),str(e)))
return False
chars=len(s)
if chars==0:
self.setStatusMessage("Tried on %s: got empty string" % self._time())
self.setExternalProcessingStatusMessage("Tried on %s: got empty string" % self._time())
return False
try:
s=self._processData(s,inf)
except Exception,e:
self.log(e,level=1)
self.setStatusMessage("Spidered on %s, %i chars, but could not process; reason: %s" % (self._time(), chars, str(e)))
self.setExternalProcessingStatusMessage("Spidered on %s, %i chars, but could not process; reason: %s" % (self._time(), chars, str(e)))
return False
self.setTextContent(s)
self.setStatusMessage("Spidered on %s, %i chars, recorded %i chars" % (self._time(), chars, len(s)))
self.setExternalProcessingStatusMessage("Spidered on %s, %i chars, recorded %i chars" % (self._time(), chars, len(s)))
return True
security.declareProtected(Permissions.View, 'getProtocolItemList')
......
......@@ -204,7 +204,7 @@ class ExternalWebPage(ExternalDocument):
try:
s=recode(s)
except CanNotDecode:
self.setStatusMessage("Spidered on %s, %i chars, but could not decode" % (self._time(), chars))
self.setExternalProcessingStatusMessage("Spidered on %s, %i chars, but could not decode" % (self._time(), chars))
return False
s=stripHtml(s) # remove headers, doctype and the like
s=clearHtml(s) # remove tags
......
......@@ -3,7 +3,7 @@ class ExternalDocument:
"""
"""
_properties = (
{ 'id' : 'status_message',
{ 'id' : 'external_processing_status_message',
'description' : 'message about status',
'type' : 'string',
'mode' : 'w' },
......
......@@ -35,7 +35,7 @@ class OOoDocument:
'description' : 'mime type of OOo version',
'type' : 'string',
'mode' : ''},
{ 'id' : 'status_message',
{ 'id' : 'external_processing_status_message',
'description' : 'message about status',
'type' : 'string',
'mode' : 'w' },
......
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