Merge branch 'master' into bbmaster
This commit is contained in:
commit
073d483bf0
3 changed files with 28 additions and 4 deletions
|
@ -31,6 +31,7 @@ from zope.traversing.api import getName, getParent
|
|||
from cybertools.browser.form import FormController
|
||||
from cybertools.stateful.interfaces import IStateful, IStatesDefinition
|
||||
from loops.browser.common import BaseView
|
||||
from loops.browser.concept import ConceptView
|
||||
from loops.browser.node import NodeView
|
||||
from loops.common import adapted, AdapterBase
|
||||
from loops.expert.concept import ConceptQuery, FullQuery
|
||||
|
@ -74,7 +75,7 @@ class QuickSearchResults(NodeView):
|
|||
return self.viewIterator(result)
|
||||
|
||||
|
||||
class Search(BaseView):
|
||||
class Search(ConceptView):
|
||||
|
||||
form_action = 'execute_search_action'
|
||||
maxRowNum = 0
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#
|
||||
# Copyright (c) 2007 Helmut Merz helmutm@cy55.de
|
||||
# Copyright (c) 2011 Helmut Merz helmutm@cy55.de
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
|
@ -18,8 +18,6 @@
|
|||
|
||||
"""
|
||||
Managing information form objects provided by external sources, e.g. loops.agent.
|
||||
|
||||
$Id$
|
||||
"""
|
||||
|
||||
from persistent.mapping import PersistentMapping
|
||||
|
@ -27,6 +25,7 @@ from zope import interface, component
|
|||
from zope.interface import implements
|
||||
from zope.component import adapts
|
||||
|
||||
from loops.common import adapted
|
||||
from loops.interfaces import ILoopsObject
|
||||
from loops.integrator.interfaces import IExternalSourceInfo
|
||||
|
||||
|
@ -46,6 +45,13 @@ class ExternalSourceInfo(object):
|
|||
return getattr(self.context, sourceInfoAttrName, PersistentMapping())
|
||||
|
||||
def getExternalIdentifier(self):
|
||||
# first try to find adapter on adapted concept or resource
|
||||
adapted = adapted(self.context)
|
||||
if adapted != self.context:
|
||||
adaptedSourceInfo = IExternalSourceInfo(adapted, None)
|
||||
if adaptedSourceInfo is not None:
|
||||
return adaptedSourceInfo.getExternalIdentifier()
|
||||
# otherweise use stored external identifier
|
||||
return self.getSourceInfo().get('externalIdentifier')
|
||||
def setExternalIdentifier(self, value):
|
||||
info = self.getSourceInfo()
|
||||
|
|
17
organize/data/organize_queries_de.dmp
Normal file
17
organize/data/organize_queries_de.dmp
Normal file
|
@ -0,0 +1,17 @@
|
|||
concept(u'list_events', u'Termine', u'query', options=u'delta:2', viewName=u'list_events.html')
|
||||
concept(u'personal_info', u'Pers\xf6nliche Information', u'query', options=u'', viewName=u'personal_info.html')
|
||||
concept(u'recent_changes', u'Aktuelle \xc4nderungen', u'query', options=u'types:project,orgunit,person,topic,task,event,resource:*', viewName=u'recent_changes.html')
|
||||
|
||||
# "in box"
|
||||
concept(u'wi_planned', u'Aktuell zu bearbeiten', u'query', options=u'wi_state:planned', viewName=u'userworkitems.html')
|
||||
|
||||
# for work items overview
|
||||
concept(u'wi_current', u'Aktuelle Aktivit\xe4ten', u'query', options=u'wi_to:today\nwi_state:planned,accepted,delegated,running,done', viewName=u'userworkitems.html')
|
||||
concept(u'wi_done_today', u'Erledigt', u'query', options=u'wi_to:today\nwi_from:-2\nwi_state:done,done_x,finished', viewName=u'userworkitems.html')
|
||||
concept(u'wi_tomorrow', u'Aktivit\xe4ten morgen', u'query', options=u'wi_to:+2\nwi_from:tomorrow\nwi_state:planned,accepted', viewName=u'userworkitems.html')
|
||||
|
||||
# future work items
|
||||
concept(u'wi_future', u'Aktivit\xe4ten k\xfcnftig', u'query', options=u'wi_to:+366\nwi_from:tomorrow\nwi_state:planned,accepted,delegated,running,done', viewName=u'userworkitems.html')
|
||||
|
||||
# done
|
||||
concept(u'wi_done', u'Aktivit\xe4ten erledigt', u'query', options=u'wi_from:-60\nwi_state:done,done_x,finished', viewName=u'userworkitems.html')
|
Loading…
Add table
Reference in a new issue