예제 #1
0
from interfaces import IContainer,IBlock
import interfaces
from BlockishSchema import BlockishSchema

from Products.Five.browser import BrowserView
from Acquisition import aq_inner,aq_parent

import json
##code-section module-header #fill in your manual code here
##/code-section module-header

##code-section after-local-schema #fill in your manual code here
##/code-section after-local-schema

Container_schema = OrderedBaseFolderSchema.copy() + \
    BlockishSchema.copy()

##code-section after-schema #fill in your manual code here
##/code-section after-schema

class ContainerJSON(BrowserView):
    """ JSON Encoded Issue """
    def __init__(self,context,request):
        """ Initialize context and request as view multiadaption parameters.

        Note that the BrowserView constructor does this for you.
        This step here is just to show how view receives its context and
        request parameter. You do not need to write __init__() for your
        views.
        """
        self.context = context
예제 #2
0
from Products.CMFCore.utils import getToolByName
from interfaces import IContainer, IBlock
import interfaces
from BlockishSchema import BlockishSchema
from ScriptishSchema import ScriptishSchema

from Products.Five.browser import BrowserView
from Acquisition import aq_inner, aq_parent

##code-section module-header #fill in your manual code here
##/code-section module-header

##code-section after-local-schema #fill in your manual code here
##/code-section after-local-schema

Container_schema = OrderedBaseFolderSchema.copy() + BlockishSchema.copy() + ScriptishSchema.copy()

##code-section after-schema #fill in your manual code here
##/code-section after-schema


class ContainerView(BrowserView):
    """
    """

    def __init__(self, context, request):
        """
	"""
        self.context = context
        self.request = request