This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from zope.component.hooks import setSite | |
import transaction | |
from Testing.makerequest import makerequest | |
from AccessControl.SecurityManagement import newSecurityManager | |
user = app.acl_users.getUser('zopemaster') | |
user = user.__of__(app.acl_users) | |
newSecurityManager(app, user) | |
app = makerequest(app) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from collections import namedtuple | |
import logging | |
from Acquisition import aq_parent | |
from DateTime import DateTime | |
from plone.app.layout.navigation.interfaces import INavigationRoot | |
from plone.registry.interfaces import IRegistry | |
from Products.CMFCore.utils import getToolByName | |
from Products.CMFPlone.browser.navtree import getNavigationRoot | |
from Products.CMFPlone.utils import base_hasattr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# Simple script to generate a .codeintel/config file for a buildout directory. | |
# The buildout must use collective.recipe.omelette to generate a parts/omelette | |
# directory. This will be used as the Python path | |
import os.path | |
import sys | |
path = "parts/omelette" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from AccessControl.SecurityManagement import newSecurityManager | |
from Testing.makerequest import makerequest | |
from zope.app.component.hooks import setSite | |
from Products.CMFCore.utils import getToolByName | |
import transaction | |
# we need to get a super user security and a request | |
user = app.acl_users.getUser(USERNAME) | |
user = user.__of__(app.acl_users) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ul class="navTree navTreeLevel0" style="display: none; width: 0px;"> | |
<li class="navTreeItem visualNoMarker navTreeFolderish section-ise-news"> | |
<a href="http://instance01.poseidon.4teamwork.ch/fraunhofer/platform/ise-home/ise-news" class="state-intranet-state-published navTreeFolderish contenttype-newsfolder" title=""> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<form class="mediothekSuche" action="" method="GET"> | |
<input type="text" name="search_value" placeholder="Suchbegriffe eingeben" style="width: 95%;"/> | |
<Input type="submit" name="submit" value="Suchen" /> | |
</form> | |
<script type="text/javascript"> | |
$(function() { | |
var base = "http://ilu.zhbluzern.ch/F"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from AccessControl.SecurityManagement import newSecurityManager | |
from Acquisition import aq_inner | |
from Acquisition import aq_parent | |
from Products.CMFCore.utils import getToolByName | |
from Testing.makerequest import makerequest | |
from zope.component.hooks import setSite | |
import transaction | |
app = globals()['app'] | |
# we need to get a super user security and a request |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from AccessControl.SecurityManagement import newSecurityManager | |
from Acquisition import aq_inner | |
from Acquisition import aq_parent | |
from Products.CMFCore.utils import getToolByName | |
from Testing.makerequest import makerequest | |
from zope.component.hooks import setSite | |
import transaction | |
app = globals()['app'] | |
# we need to get a super user security and a request |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def uncatalog_by_rid(_catalog, rid): | |
data = _catalog.data | |
paths = _catalog.paths | |
indexes = _catalog.indexes.keys() | |
for name in indexes: | |
x = _catalog.getIndex(name) | |
if hasattr(x, 'unindex_object'): | |
x.unindex_object(rid) | |
del data[rid] | |
del paths[rid] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html xmlns="http://www.w3.org/1999/xhtml"> | |
<head><title></title></head> | |
<body> | |
<p tal:content="here/getBody_pre | nothing" /> | |
<table style="width:800px; border: 1px solid grey"> | |
<tr tal:repeat="field options/wrappedFields | nothing"> | |
<th tal:content="field/fgField/widget/label" /> |
OlderNewer