Commit 5436c864 authored by Jean-Paul Smets's avatar Jean-Paul Smets

Renamed convertToBase to convertToBaseFormat

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13479 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent d80beca3
......@@ -149,7 +149,7 @@ class OOoDocument(File, ConversionCacheMixin):
"""
self.log(format, force)
if (not self.hasOOFile()) or force:
self.convertToBase()
self.convertToBaseFormat()
if format is None:
result = self.getOOFile()
mime = self.getMimeType()
......@@ -261,7 +261,7 @@ class OOoDocument(File, ConversionCacheMixin):
return True # XXX why return ? - why not?
security.declarePrivate('_convertToBase')
def _convertToBase(self):
def _convertToBaseFormat(self):
"""
Converts the original document into ODF
by invoking the conversion server. Store the result
......@@ -423,7 +423,7 @@ class OOoDocument(File, ConversionCacheMixin):
"""
# first check if we have base
if not self.hasOOFile():
self.convertToBase()
self.convertToBaseFormat()
if not self.isAllowed(format):
if REQUEST is not None:
return self.returnMessage('can not convert to ' + format + ' for some reason',1)
......
......@@ -299,7 +299,7 @@ class TestIngestion(ERP5TypeTestCase):
filename = 'TEST-en-002.' + format
f = makeFileUpload(filename)
context.edit(file=f)
context.convertToBase()
context.convertToBaseFormat()
context.reindexObject(); get_transaction().commit(); self.tic()
self.failUnless(context.hasFile())
if context.getPortalType() in ('Image', 'File'): # these are not subject to conversion
......@@ -318,7 +318,7 @@ class TestIngestion(ERP5TypeTestCase):
filename = 'TEST-en-002.' + format
f = makeFileUpload(filename)
context.edit(file=f)
context.convertToBase()
context.convertToBaseFormat()
context.reindexObject(); get_transaction().commit(); self.tic()
clearCache()
target_list = [x[1] for x in context.getTargetFormatItemList()]
......
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