Back to index

plone3  3.1.7
Public Member Functions | Static Public Attributes Class Reference
Inheritance diagram for
Inheritance graph
Collaboration diagram for
Collaboration graph

List of all members.

Public Member Functions

def nextURL
def handle_save_action
def handle_cancel_action

Static Public Attributes

 validator = null_validator,
string name = u'cancel'

Detailed Description

A base add form for content rule.

Use this for rule elements that require configuration before being added to
a rule. Element types that do not should use NullAddForm instead.

Sub-classes should define create() and set the form_fields class variable.

Notice the suble difference between AddForm and NullAddform in that the
create template method for AddForm takes as a parameter a dict 'data':

    def create(self, data):
        return MyAssignment(data.get('foo'))
whereas the NullAddForm has no data parameter:

    def create(self):
        return MyAssignment()

Definition at line 23 of file

Member Function Documentation

Definition at line 58 of file

00059     def handle_cancel_action(self, action, data):
00060         nextURL = self.nextURL()
00061         if nextURL:
00062             self.request.response.redirect(self.nextURL())
00063         return ''

Here is the call graph for this function:

Definition at line 52 of file

00053     def handle_save_action(self, action, data):
00054         self.createAndAdd(data)

Reimplemented in

Definition at line 45 of file

00046     def nextURL(self):
00047         rule = aq_parent(aq_inner(self.context))
00048         context = aq_parent(aq_inner(rule))
00049         url = str(getMultiAdapter((context, self.request), name=u"absolute_url"))
00050         return '%s/++rule++%s/@@manage-elements' % (url, rule.__name__)

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

Definition at line 57 of file

Definition at line 56 of file

The documentation for this class was generated from the following file: