|
|
Subject: Re: MailHosts as utilities - msg#00005
List: web.zope.z3base.five
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
- --On 7. Dezember 2006 12:20:21 +0100 Lennart Regebro <regebro@xxxxxxxxx>
wrote:
> On 12/7/06, Chris Withers <chris@xxxxxxxxxxxxxxxx> wrote:
> > Anyone done any work on writing an interface for MailHost-like things
> > and then getting MailHost, MaildropHost, SecureMailHost and friends to
> > implement the interface and be registered as local utilities?
>
> I think Zope3 actually may have some stuff like that. CPSMailAccess
> uses it, I think.
>
>
zope.sendmail?
- -aj
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)
iD8DBQFFd/pJCJIWIbr9KYwRAqYIAJ0dFqeAmWpIpWxZKMV2Z3Bt6xyrBgCdESI3
NEW/33fw3emuCwO1ZKtKtwc=
=4b5Q
-----END PGP SIGNATURE-----
Was this page helpful?
Thread at a glance:
Previous Message by Date:
click to view message preview
Re: MailHosts as utilities
On 12/7/06, Chris Withers <chris@xxxxxxxxxxxxxxxx> wrote:
> Anyone done any work on writing an interface for MailHost-like things
> and then getting MailHost, MaildropHost, SecureMailHost and friends to
> implement the interface and be registered as local utilities?
I think Zope3 actually may have some stuff like that. CPSMailAccess
uses it, I think.
--
Lennart Regebro, Nuxeo http://www.nuxeo.com/
CPS Content Management http://www.nuxeo.org/
Next Message by Date:
click to view message preview
Widget Error on direct __call__ with pt
Hello,
I am using the following code for a sequence widget, based on the
objectwidget in Five 1.4.2
class TableRecordSequenceWidget(ListSequenceWidget):
def __init__(self, context, field, request, template_='',
subwidget=None):
super(TableRecordSequenceWidget, self).__init__(
context, field, request, subwidget)
def __call__(self):
.... render sth........
It works good as long as I write the rendered html directly in the
__call__ method.
But I would really like to have it in a page template for cleaner
developing.
However when I try to change it to return a page template in the call
method,
(like I found it in many examples)
def __call__(self):
class TemplateObjectWidgetView(ObjectWidgetView):
template = ZopeTwoPageTemplateFile("itemwidget.pt")
template = TemplateObjectWidgetView(self, self.request)
return template()
I have the following error:
Any help? Again, the version without the page template works perfectly
The error occurs when try to get the widget structure of the
objectwidget in my page tamplate:
<td tal:define="widget python:view.widgets.get('items')" >
<div class="CellsTableRowListHeader"
tal:content="structure widget"></div>
</td>
In the earlier version (with the html dirctly in the call method) it was
necessary to initialize the whole object widget like this. And now?
Maybe is a problem with ZopeTwoPageTemplateFile?
Module ZPublisher.Publish, line 115, in publish
Module ZPublisher.mapply, line 88, in mapply
Module ZPublisher.Publish, line 41, in call_object
Module zope.formlib.form, line 898, in __call__
Module zope.formlib.form, line 892, in render
Module Shared.DC.Scripts.Bindings, line 311, in __call__
Module Shared.DC.Scripts.Bindings, line 348, in _bindAndExec
Module Products.PageTemplates.PageTemplateFile, line 113, in _exec
Module Products.PageTemplates.PageTemplate, line 104, in pt_render
- <ImplicitAcquirerWrapper object at 0x05BA8110>
Module TAL.TALInterpreter, line 238, in __call__
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 749, in do_useMacro
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 457, in do_optTag_tal
Module TAL.TALInterpreter, line 442, in do_optTag
Module TAL.TALInterpreter, line 437, in no_tag
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 749, in do_useMacro
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 457, in do_optTag_tal
Module TAL.TALInterpreter, line 442, in do_optTag
Module TAL.TALInterpreter, line 437, in no_tag
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 780, in do_defineSlot
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 457, in do_optTag_tal
Module TAL.TALInterpreter, line 442, in do_optTag
Module TAL.TALInterpreter, line 437, in no_tag
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 728, in do_defineMacro
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 772, in do_defineSlot
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 728, in do_defineMacro
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 780, in do_defineSlot
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 772, in do_defineSlot
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 749, in do_useMacro
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 457, in do_optTag_tal
Module TAL.TALInterpreter, line 442, in do_optTag
Module TAL.TALInterpreter, line 437, in no_tag
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 780, in do_defineSlot
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 457, in do_optTag_tal
Module TAL.TALInterpreter, line 442, in do_optTag
Module TAL.TALInterpreter, line 437, in no_tag
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 749, in do_useMacro
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 457, in do_optTag_tal
Module TAL.TALInterpreter, line 442, in do_optTag
Module TAL.TALInterpreter, line 437, in no_tag
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 749, in do_useMacro
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 457, in do_optTag_tal
Module TAL.TALInterpreter, line 442, in do_optTag
Module TAL.TALInterpreter, line 437, in no_tag
Module TAL.TALInterpreter, line 281, in interpret
Module TAL.TALInterpreter, line 647, in do_insertStructure_tal
Module Products.PageTemplates.TALES, line 221, in evaluate
- URL: index
- Line 286, Column 4
- Expression: standard:'widget'
- Names:
{'container': <PurchaseRequisition at
/Plone/purchaserequisition.2006-11-29.5884219316/pr/196>,
'context': <PurchaseRequisition at
/Plone/purchaserequisition.2006-11-29.5884219316/pr/196>,
'default': <Products.PageTemplates.TALES.Default instance at
0x017EB5F8>,
'here': <PurchaseRequisition at
/Plone/purchaserequisition.2006-11-29.5884219316/pr/196>,
'loop': <Products.PageTemplates.TALES.SafeMapping object at
0x05BAB440>,
'modules':
<Products.PageTemplates.ZRPythonExpr._SecureModuleImporter instance at
0x017D8B48>,
'nothing': None,
'options': {'args': ()},
'repeat': <Products.PageTemplates.TALES.SafeMapping object at
0x05BAB440>,
'request': <HTTPRequest,
URL=http://localhost:8080/Plone/purchaserequisition.2006-11-29.5884219316/pr/196/predit>,
'root': <Application at >,
'template': <ImplicitAcquirerWrapper object at 0x05BA8110>,
'traverse_subpath': [],
'user': <PropertiedUser 'mugdiman'>,
'view': <Products.Five.metaclass.PREditView object at 0x05B89C50>,
'views': <zope.app.pagetemplate.viewpagetemplatefile.ViewMapper
object at 0x05BA82D0>}
Module Products.PageTemplates.Expressions, line 185, in __call__
Module Products.PageTemplates.Expressions, line 180, in _eval
Module Products.PageTemplates.Expressions, line 85, in render
Module Products.PurchaseRequisition.browser.objectwidget, line 386, in
__call__
Module zope.app.form.browser.objectwidget, line 41, in __call__
Module Shared.DC.Scripts.Bindings, line 311, in __call__
Module Shared.DC.Scripts.Bindings, line 346, in _bindAndExec
Module Shared.DC.Scripts.Bindings, line 1, in ?
Module Shared.DC.Scripts.Bindings, line 291, in _getTraverseSubpath
AttributeError: 'str' object has no attribute 'other'
Previous Message by Thread:
click to view message preview
Re: MailHosts as utilities
On 12/7/06, Chris Withers <chris@xxxxxxxxxxxxxxxx> wrote:
> Anyone done any work on writing an interface for MailHost-like things
> and then getting MailHost, MaildropHost, SecureMailHost and friends to
> implement the interface and be registered as local utilities?
I think Zope3 actually may have some stuff like that. CPSMailAccess
uses it, I think.
--
Lennart Regebro, Nuxeo http://www.nuxeo.com/
CPS Content Management http://www.nuxeo.org/
Next Message by Thread:
click to view message preview
Re: MailHosts as utilities
Lennart Regebro wrote:
> On 12/7/06, Chris Withers <chris@xxxxxxxxxxxxxxxx> wrote:
>> Anyone done any work on writing an interface for MailHost-like things
>> and then getting MailHost, MaildropHost, SecureMailHost and friends to
>> implement the interface and be registered as local utilities?
>
> I think Zope3 actually may have some stuff like that. CPSMailAccess
> uses it, I think.
I'm more talking about retrofitting existing ones so that we can do away
with the superValues nonsense...
Chris
--
Simplistix - Content Management, Zope & Python Consulting
- http://www.simplistix.co.uk
|
|