appy.gen: bugfixes.
This commit is contained in:
parent
8cc20b0d34
commit
d3a2b85a10
3 changed files with 30 additions and 17 deletions
|
@ -12,7 +12,7 @@ import appy.pod
|
|||
from appy.pod.renderer import Renderer
|
||||
from appy.shared.data import countries
|
||||
from appy.shared.utils import Traceback, getOsTempFolder, formatNumber, \
|
||||
cleanXhtml, FileWrapper, sequenceTypes
|
||||
XhtmlCleaner, FileWrapper, sequenceTypes
|
||||
|
||||
# Default Appy permissions -----------------------------------------------------
|
||||
r, w, d = ('read', 'write', 'delete')
|
||||
|
@ -1239,7 +1239,7 @@ class String(Type):
|
|||
# (ie for image size when images are resized). So in this case we
|
||||
# can't remove style-related information.
|
||||
keepStyles = self.allowImageUpload or self.richText
|
||||
value = cleanXhtml(value, keepStyles=keepStyles)
|
||||
value = XhtmlCleaner.clean(value, keepStyles=keepStyles)
|
||||
Type.store(self, obj, value)
|
||||
|
||||
def getFormattedValue(self, obj, value):
|
||||
|
|
|
@ -340,7 +340,8 @@ class BaseMixin:
|
|||
obj = self.getTool().getObject(rq['objectUid'])
|
||||
else:
|
||||
obj = self
|
||||
return obj.getMethod('on'+action)()
|
||||
if rq.get('appy', None) == '1': obj = obj.appy()
|
||||
return getattr(obj, 'on'+action)()
|
||||
|
||||
def rememberPreviousData(self):
|
||||
'''This method is called before updating an object and remembers, for
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue