On Fri, 14 Oct 2005 16:36:45 +0200, gnotari wrote
On Fri, 14 Oct 2005 15:36:09 +0200, gnotari wrote
I'm at loss:
I'm replicating the example at cap. 14.3 of Philipp's (Worldcookery)
book. It's all about auto-assigning names to object being added to
containers.
After much
I think the answer to that question is both, but X['Y'] seem to have
precedents over X.Y.
class MyContainer(OOBTree):
title=u''
class MyContent(Persistent):
title=u''
Adding MyContent in MyContainer you can traverse MyContainer/MyContent/title
or you can traverse MyContainer/title
Achim,
Take a look at homefolder in the trunk. You can find it here:
http://svn.zope.org/Zope3/trunk/src/zope/app/homefolder/
It does what you want to do.
On Fri, 07 Apr 2006 16:50:50 +0200, Achim Domma wrote
Frank Burkhardt wrote:
Do I understand it right, that I do not grant a
I'm trying to do a join form with formlib and are getting errors when checking
invariants.
I have my form interface IJoinForm
class IJoinForm(Interface):
a join form
username = schema.TextLine(
title=_('User Name'),
required=True)
password = schema.Password(
# this is needed to adapt to a view for formlib
implements(IWidgetInputError)
On 03.05.2006, at 20:59, mats.nordgren wrote:
I'm trying to do a join form with formlib and are getting errors
when checking
invariants.
I have my form interface IJoinForm
class IJoinForm(Interface
line 23, in IWorkspace value_type=Object(title=uObject,
description=uadsf),
in zope/schema/_field.py
class Object(Field):
__doc__ = IObject.__doc__
implements(IObject)
def __init__(self, schema, **kw): you need to pass a schema as a non
key-word
if not
Look at form.txt in the formlib directory.
On Wed, 17 May 2006 11:24:43 -0500, Jachin Rupe wrote
hi there
thanks for the help. I was just reading somewhere that formlib is
the way to go. Is that the general consensus?
The problem is, it doesn't look like formlib is covered in either
(Pdb) catalog.searchResults(AbbreviationIndex = ABC)
*** TypeError: ('two-length tuple expected', 'ABC')
(Pdb) catalog.searchResults([AbbreviationIndex ,ABC])
*** TypeError: searchResults() takes exactly 1 argument (2 given)
(Pdb) res = catalog.searchResults()
(Pdb) res == None
True
How
My bad, should be
catalog.searchResults(AbbreviationIndex=('ABC', 'ABC')
Field indices expect a high and low as Alen stated
Sincerely,
Mats
On Sun, 21 May 2006 18:49:46 +0200, Florian Lindner wrote
Am Sonntag, 21. Mai 2006 17:58 schrieb mats.nordgren:
(Pdb) catalog.searchResults
This seems to work
class EditForm(form.EditForm):
form_fields = form.Fields(ISchema)
def __init__(self, context, request):
self.context, self.request = context, request
@form.action('Edit')
def handle_edit_action(self, action, data):
if data['image'] != None:
Never mind it was a user error on my part.
I was stuffing the data variables in the create function into the context not
the object being created. Oooops :)
On Fri, 26 May 2006 13:02:42 -0500, mats.nordgren wrote
I've been trying to use NameChooser with formlibs AddForm and it
always tells
I'm totally clueless as how to get a dict widget to work.
class IMyObject(Interface):
mydict = Dict(
title=u'My Dict',
key_type=TextLine(),
value_type=Int())
I see in zope.app.form.browser the config file has no view defined for IDict
and ?IField?. Is it just a matter of
Marco,
You need to pass the id not the principal object.
principalRoleManager.getRolesForPrincipal(self.request.principal.id)
Cheers,
Mats
On Wed, 14 Jun 2006 20:00:40 +0200, Marco Mariani wrote
How do I get the list of roles for the current principal?
I've tried
from
I'm not sure this is it or not but FieldProperty doesn't play nice with the
persistent list and dict, it will only accept the non persistent list.
class ITest(Interface):
... mylist = List(title=u'My List')
...
class Test(Persistent):
... implements(ITest)
... mylist =
I've tried to get WingIDE to work for debugging Zope3 but have only had
limited success. I've followed the instructions at wingware.com where it
tells you to add the wingdbstub. I added 'import wingdbstub' in
$ZOPEINSTANCE/bin/runzope and it will break on errors but will not break on
Ooops that should be
page
for="">zope.app.container.interfaces.IAdding
name=AddContent.html
class=.forms.MyContentAddForm
permission=zope.ManageContent /
Mats
On Tue, 20 Jun 2006 23:37:35 -0500, mats.nordgren wrote
John,
I have never done it with the add
Never knew about IPython and really like what I see. Thanks for the hint. I
got the debugging to work for Zope3 with the following simple change to the
tutorial.
IPython.Shell.IPShell(user_ns=locals()).mainloop(sys_exit=1)
to
IPython.Shell.IPShell(user_ns={'root': root, 'app':
17 matches
Mail list logo