Chris Withers schrieb:
for id in self.manage_targets.keys():
title =
self.manage_targets[id]['name']
self.tgt_folder=Folder()
This is dangerous...
Why is that?
self._setObject(id,self.tgt_folder)
(Thu, Feb 16, 2006 at 12:00:05PM -0500) [EMAIL PROTECTED] wrote/schrieb/egrapse:
From: Roman Klesel [EMAIL PROTECTED]
Still I can't get what I want.
when I now do:
system.manage_addProduct['OFSP'].manage_addFile(fid,
title='',
file=cpu_load,
Hello Sascha,
Sascha Welter schrieb:
manage_addFile (and some others like manage_addFolder, ...) work
directly without xy.manage_addProduct[...].
That part is in the Zope book.
The syntax with manage_addProduct[... is used for filesystem based
products (like the stuff you have in your
(Mon, Feb 20, 2006 at 03:45:31PM +0100) Roman Klesel wrote/schrieb/egrapse:
Sascha Welter schrieb:
manage_addFile (and some others like manage_addFolder, ...) work
directly without xy.manage_addProduct[...].
That part is in the Zope book.
The syntax with manage_addProduct[... is
Roman Klesel wrote:
Chris Withers schrieb:
for id in self.manage_targets.keys():
title =
self.manage_targets[id]['name']
self.tgt_folder=Folder()
This is dangerous...
Why is that?
'cos arbitarilly assigning
Roman Klesel wrote:
form OFS.Image import File
- I build a class _File(File):
I really doubt you need to do that...
- pimped it up a little bit.
What, specifically, did you add?
- _setObject'ed it
You shouldn't be calling that directly...
Chris
--
Simplistix - Content Management,
Roman Klesel wrote:
for id in self.manage_targets.keys():
title = self.manage_targets[id]['name']
self.tgt_folder=Folder()
This is dangerous...
Roman Klesel wrote:
Hello,
Roman Klesel schrieb:
Hello,
in a product I try to make a file object persistent with the _setObject()
method.
What's wrong with:
container.manage_addProduct['OFSP'].manage_addFile(id, file='',
title='', precondition='', content_type='', REQUEST=None)
--
On 16 Feb 2006, at 09:33, Roman Klesel wrote:
Hello Bruno,
bruno desthuilliers schrieb:
What's wrong with:
container.manage_addProduct['OFSP'].manage_addFile(id, file='',
title='', precondition='', content_type='', REQUEST=None)
Well, in a fs product I don't have container nor
Hello,
Jens Vagelpohl schrieb:
If that object subclasses
from the normal Zope Folder class (or is a Zope Folder) you *will* have
manage_addProduct.
Yes, actually you guys a right! self.manage_addProduct is available...
Hmmm ... wonder what made me think it's not ...
Still I can't get what
Please learn to read and to provide the *complete* traceback. The
error text alone is not enough most of the time.
Your error *may* mean that 'system' is not yet wrapped. Are your
positive that 'system' is a folder that already exists in the ZODB,
i.e. has already been _setObject'ed?
Hello,
one more thing ...
Roman Klesel schrieb:
Your error *may* mean that 'system' is not yet wrapped. Are your
positive that 'system' is a folder that already exists in the ZODB,
i.e. has already been _setObject'ed?
As far as I can tell: Yes!
Actually I'm pretty shure, because as I
Hello again,
I works! I just managed to get everything as I expected it to be.
How I did it:
form OFS.Image import File
- I build a class _File(File):
- pimped it up a little bit.
- instatiated it
- _setObject'ed it
... et voila
I have nice File-objects with nice CMI interface...
Thanks for
13 matches
Mail list logo