Last change
on this file since 3511 was
3153,
checked in by vmaksymiv, 13 years ago
|
pyflakes fixes
|
-
Property svn:eol-style set to
native
|
File size:
686 bytes
|
Line | |
---|
1 | import logging |
---|
2 | from Products.CMFCore.utils import getToolByName |
---|
3 | |
---|
4 | from quintagroup.dropdownmenu import PROJECT_NAME |
---|
5 | |
---|
6 | logger = logging.getLogger('quintagroup.dropdownmenu') |
---|
7 | |
---|
8 | UNINSTALL = "profile-%s:uninstall" % PROJECT_NAME |
---|
9 | |
---|
10 | |
---|
11 | def uninstall(portal, reinstall=False): |
---|
12 | """ Uninstall this product. |
---|
13 | |
---|
14 | This external method is need, because portal_quickinstaller doens't |
---|
15 | know what GenericProfile profile to apply when uninstalling a product. |
---|
16 | """ |
---|
17 | setup_tool = getToolByName(portal, 'portal_setup') |
---|
18 | if reinstall: |
---|
19 | return "Ran all reinstall steps." |
---|
20 | else: |
---|
21 | setup_tool.runAllImportStepsFromProfile(UNINSTALL) |
---|
22 | return "Ran all uninstall steps." |
---|
Note: See
TracBrowser
for help on using the repository browser.