Back to index

plone3  3.1.7
Public Member Functions | Static Public Attributes
plone.app.controlpanel.overview.OverviewControlPanel Class Reference
Inheritance diagram for plone.app.controlpanel.overview.OverviewControlPanel:
Inheritance graph
[legend]
Collaboration diagram for plone.app.controlpanel.overview.OverviewControlPanel:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def __call__
def action
def migration
def core_versions
def pil
def version_overview
def is_dev_mode
def mailhost_warning
def categories
def sublists

Static Public Attributes

tuple template = ViewPageTemplateFile('overview.pt')
string base_category = 'controlpanel'
tuple ignored_categories = ('controlpanel_user')

Detailed Description

Definition at line 32 of file overview.py.


Member Function Documentation

Definition at line 39 of file overview.py.

00039 
00040     def __call__(self):
00041         self.request.set('disable_border', 1)
00042         return self.template()

Here is the caller graph for this function:

Definition at line 44 of file overview.py.

00044 
00045     def action(self):
00046         return getToolByName(aq_inner(self.context), 'portal_actions')

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 85 of file overview.py.

00085 
00086     def categories(self):
00087         root = self.action().get(self.base_category, None)
00088         if root is None:
00089             return ()
00090         category_ids = [i for i in root.objectIds()
00091                           if i not in self.ignored_categories]
00092         def _title(id):
00093             title = root[c].getProperty('title')
00094             domain = root[c].getProperty('i18n_domain', 'plone')
00095             return translate(title, domain=domain, context=self.request)
00096         return [dict(id=c, title=_title(c)) for c in category_ids]

Here is the call graph for this function:

Definition at line 52 of file overview.py.

00052 
00053     def core_versions(self):
00054         return self.migration().coreVersions()

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 71 of file overview.py.

00071 
00072     def is_dev_mode(self):
00073         qi = getToolByName(aq_inner(self.context), 'portal_quickinstaller')
00074         return qi.isDevelopmentMode()

Here is the call graph for this function:

Definition at line 75 of file overview.py.

00075 
00076     def mailhost_warning(self):
00077         mailhost = getToolByName(aq_inner(self.context), 'MailHost', None)
00078         if mailhost is None:
00079             return True
00080         mailhost = getattr(aq_base(mailhost), 'smtp_host', None)
00081         email = getattr(aq_inner(self.context), 'email_from_address', None)
00082         if mailhost and email:
00083             return False
00084         return True

Here is the call graph for this function:

Definition at line 48 of file overview.py.

00048 
00049     def migration(self):
00050         return getToolByName(aq_inner(self.context), 'portal_migration')

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 55 of file overview.py.

00055 
00056     def pil(self):
00057         return 'PIL' in self.core_versions()

Here is the call graph for this function:

Definition at line 97 of file overview.py.

00097 
00098     def sublists(self, category):
00099         categories = self.base_category + '/' + category
00100         actions = self.action().listActionInfos(categories=categories)
00101         def _title(v):
00102             return translate(v.get('title'),
00103                              domain='plone',
00104                              context=self.request)
00105         actions.sort(key=_title)
00106         return three_column_list(actions)

Here is the call graph for this function:

Definition at line 58 of file overview.py.

00058 
00059     def version_overview(self):
00060         versions = [
00061             'Plone ' + self.migration().getInstanceVersion(),
00062         ]
00063         core_versions = self.core_versions()
00064         for v in ('CMF', 'Zope', 'Python'):
00065             versions.append(v + ' ' + core_versions.get(v))
00066         pil = core_versions.get('PIL', None)
00067         if pil is not None:
00068             versions.append('PIL ' + pil)
00069         return versions

Here is the call graph for this function:


Member Data Documentation

Definition at line 36 of file overview.py.

Definition at line 37 of file overview.py.

tuple plone.app.controlpanel.overview.OverviewControlPanel.template = ViewPageTemplateFile('overview.pt') [static]

Definition at line 34 of file overview.py.


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