File: DTMLDocument.py

package info (click to toggle)
zope-replacesupport 1.0.2-2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 168 kB
  • ctags: 155
  • sloc: python: 743; makefile: 38; sh: 25
file content (20 lines) | stat: -rw-r--r-- 450 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20

from Products.ReplaceSupport.ReplaceHandler import ReplaceHandler

__handler_class_name__ = 'DTMLDocumentHandler'

class DTMLDocumentHandler( ReplaceHandler ):
	'''search & replace in DTML Documents'''

	def getMetaType( self ):
		return 'DTML Document'

	def getChangePermission( self ):
		return 'Change DTML Documents'

	def getBody( self, ob ):
		return ob.raw
	
	def manageEdit( self, ob, body, params='' ):
		ob.manage_edit( body, ob.title )