Re: [Zope-dev] 2 Zopes

2000-10-26 Thread Gregor Heine

  Hi,
  
  Can anyone tell me a way to get Zope Objects from the first
  Zope-Installation to the second.
  I need this because i have to program a Product to putting data into
  different Zope Installations from one point of the Web.
  My boss want this way because he want a central point for data input,
  where the data are of different type and therefore they have to stored
  in different locations( different Zope Installations) My idea is to use
  ZPublisher.Client, but i don't find a way to use it.
  
  thanks as
 
 if you need to copy the actual objects verbatim you might want to
 investigate exporting to zexp and using file transfer between the hosts
 and (using Client to faciltate calling into zope) importing them on the
 second server.
 

The Client/Server Product is probably doing exactly what you want.
It uses the Zope Export/Import facility to transfer whole objects from one
Zope to another. 
You find it at www.zope.org/Members/MacGregor/Client_Server
maybe you give it a try :)

Cheers, 
Gregor!

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




[Zope-dev] How to use methods in a deeper folder?

2000-10-26 Thread Loibl Johann

Hi,

I would like to use a SQL-Method which exists in a deeper folder;

e.g. 

in dtml-Method  /eins/zwei/index_html  there exists 

dtml-in "/eins/zwei/drei/sqlMethod"
  dtml-var something
/dtml-in

and my sqlMethod is situated in folder /eins/zwei/drei/

Why  doesn't this work?

Could someone give me a helping hand?

Cheers, Hannes

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




Re: [Zope-dev] How to use methods in a deeper folder?

2000-10-26 Thread Phil Harris

Hannes,

There are a few ways to do this:

dtml-in "eins.zwei.drei.sqlMethod"

or 

dtml-with eins
  dtml-with zwei
dtml-with drei
  dtml-in sqlMethod


or

dtml-with "restrictedTraverse('/eins/zwei/drei/sqlMethod')"

all have their problems/advantages.

try some of the above and see how you get on.

hth

Phil

- Original Message - 
From: "Loibl Johann" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, October 26, 2000 1:02 PM
Subject: [Zope-dev] How to use methods in a deeper folder?


 Hi,
 
 I would like to use a SQL-Method which exists in a deeper folder;
 
 e.g. 
 
 in dtml-Method  /eins/zwei/index_html  there exists 
 
 dtml-in "/eins/zwei/drei/sqlMethod"
   dtml-var something
 /dtml-in
 
 and my sqlMethod is situated in folder /eins/zwei/drei/
 
 Why  doesn't this work?
 
 Could someone give me a helping hand?
 
 Cheers, Hannes
 
 ___
 Zope-Dev maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope-dev
 **  No cross posts or HTML encoding!  **
 (Related lists - 
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope )


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




Re: [Zope-dev] Bindings and Votings

2000-10-26 Thread Chris Withers

Michel Pelletier wrote:
 
 Sorta.  There is a bindings tab on PythonMethods where you assign names
 to various variables that show up in your namespace.  'self' is the
 container.  'context' is the context.  So:
 
 self.objectValues()
 
 will allways call the container whereas:
 
 context.objectValues()
 
 will call the method on the currently bound object.

...but can you bind self to the context or, more perversely, context to
the container?

 Unfortunately, complex also means "too hard for me to think too hard
 about".  Any volunteers?

How about the person who suggested it? ;-)

cheers,

Chris

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




Re: [Zope-dev] __replaceable__ or whatever it is ;-)

2000-10-26 Thread Shane Hathaway

Chris Withers wrote:
 I was wondering how the stuff for attributes that are replaceable in
 instance and singleton attributesis getting on.
 
 Itamar says the code is in the CVS for Zope, but neither of us can find
 any documentation.

FYI I actually added the docs in two places, but they were promptly
removed from the place they did not belong: the help system. 
Unfortunately the InterfacesWiki is currently the only good place.

 Could whoever did the coding please put something in the Interfaces Wiki
 or point us to where the official documentation lives?

http://www.zope.org/Members/michel/Projects/Interfaces/ObjectManagerItem
(See the bottom.)

 Also, when is it going to land in a erleased Zoep version? 2.3 I
 guess...

That's the plan.

Shane

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




RE: [Zope-dev] Bindings and Votings

2000-10-26 Thread Toby Dickenson

 ...but can you bind self to the context or, more perversely, 
 context to
 the container?

As the first line in your PythonMethod:

self,context = context,self

But why would you want to?

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




Re: [Zope-dev] Bindings and Votings

2000-10-26 Thread Chris Withers

Toby Dickenson wrote:
 
 As the first line in your PythonMethod:
 
 self,context = context,self

Haha... I forgot what it's like to have real assignment in TTW methods
;-)

 But why would you want to?

No particular reason, just wondering :-)

Chris

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




[Zope-dev] Flat Database/ZPatterns api, performance ?

2000-10-26 Thread Simon Michael

Flat Database (was ListMate) is just what I need to whip up an
interface for non-technical administrators - thanks. So I migrated two
data tables ("workshops"  "registrations") from gadfly to flatdb
instances using the CSV import feature, and the admin interface is
working fine.

I'm having a hard time, though, figuring out how to access the data
programmatically. I scavenged the docs (zpatterns wiki very helpful,
as far as it went; not much available for flatdb), searched the lists
(nothing) and grovelled around in the code. I'd appreciate any
comments or advice on the following.

1. how can I look up a row in the table by column value, other than
searching the whole table: ?

  dtml-in "workshops.entryValues()"
  dtml-if "getProperty('col_workshopid') == workshop"
  dtml-var "getProperty('col_description')"
  /dtml-if
  /dtml-in

2. how can I add an entry to a table ? I tried this:

  dtml-let entry="registrations.manage_addEntry()"
  dtml-call "entry.manage_addProperty('col_workshopid','string','TEST')"
  dtml-call "entry.manage_addProperty('col_firstname','string','TEST')"
  dtml-call "entry.manage_addProperty('col_lastname','string','TEST')"
  ...
  /dtml-let

and it seems to create a number of spurious rows with only the first
field set. This didn't work either:

  dtml-call "registrations.manage_addEntry().manage_changeProperties(
  col_workshopid='TEST', col_firstname='TEST', col_lastname='TEST', ... )"

3. displaying table contents seems quite slow. On this P100 with 48Mb
ram doing nothing but zope, no load and generally snappy, generating
the 50-row, 20-column registrations table listing takes 15
seconds. Any ideas about where this comes from ?

4. this is my first encounter with the mighty zpatterns. I wonder how
one might add a thing (data plugin ?) so that FlatDb could read the
data out of zgadfly or something faster, instead of migrating it as I
did ?

Many thanks!
-Simon

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




Re: [Zope-dev] Flat Database/ZPatterns api, performance ?

2000-10-26 Thread Itamar Shtull-Trauring

Simon Michael wrote:

 Flat Database (was ListMate) is just what I need to whip up an
 interface for non-technical administrators - thanks. So I migrated two
 data tables ("workshops"  "registrations") from gadfly to flatdb
 instances using the CSV import feature, and the admin interface is
 working fine.

I wrote flat database because I wanted some features ListMate didn't have
and didn't want ZClasses.  I basically copied the structure from ListMate,
so it's probably not the best design possible for ZPatterns. So (1) may not
be possible with the current code.

Maybe try creating entries like so:

dtml-let entry="newItem(id)"
  dtml-call "entry.manage_addProperty('col_workshopid','string','TEST')"
  dtml-call "entry.manage_addProperty('col_firstname','string','TEST')"
  dtml-call "entry.manage_addProperty('col_lastname','string','TEST')"
  ...
  /dtml-let

manage_addEntry doesn't return the new entry.

Idon't  remember how this works anymore, frankly.  The source code is your
friend :)

-- 
Itamar S.T.  [EMAIL PROTECTED]
Fingerprint = D365 7BE8 B81E 2B18 6534  025E D0E7 92DB E441 411C

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




[Zope-dev] Documentation Documentation on dev.zope.org

2000-10-26 Thread Amos Latteier

Hello Zope Developers,

I've added two documents to dev.zope.org

  How to Document Your Zope Product 
  http://dev.zope.org/Documentation/DocsProcedures/ProductDoc

  How to Document Your Changes to Zope
  http://dev.zope.org/Documentation/DocsProcedures/ZopeChanges

They are wikis so dive in and add your 2 cents.

-Amos

--
Amos Latteier mailto:[EMAIL PROTECTED]
Digital Creations http://www.digicool.com

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




Re: [Zope-dev] Unit testing, ZUnit - It is in the fishbowl, please comment

2000-10-26 Thread Lalo Martins

The proposal below is in the fishbowl, at
http://dev.zope.org/Wikis/DevSite/Proposals/UnitTestingProducts

The approach will be, developing the standalone ZUnit Product
while the proposal is in the fishbowl, then push for the
proposal (integrating it with App/Product*.py). Expect a first
release of ZUnit next week or in the other.

In the meanwhile, please comment in the proposal's discussion
page :-) (or here)


On Mon, Oct 23, 2000 at 10:56:31PM -0200, Lalo Martins wrote:
 We (I and Hiperlógica) started to develop a Product we called
 ZUnit, intended for XP-style unit-testing Python-based
 Products in a full Zope environment (with a real ZODB, REQUEST,
 RESPONSE, etc).
 
 We first conceived it as a kind of Zope-based version of
 unittestgui.py - you create a "TestRunner" object giving it the
 package, module and name of a TestSuite object generator (see
 the PyUnit documentation) and inside it you may click on some
 widget to run the tests and produce a "TestResult" object which
 you can inspect later. Does this sound like a good design?
 
 Then I figured in the long run a Product isn't the best
 sollution; instead, fiddling with App/Product* sounds more like
 it, to allow developers to register tests just like they
 register classes, ZClass superclasses, _misc and help. Of
 course, just like the current registerHelp and others, it
 wouldn't be mandatory and not using it wouldn't break anything.
 
 Then, in the Product's page in the Control Panel, there would
 be a tab "Test", where you'd be allowed to run the unit tests.
 
 What do people think of this? What does DC think of this? Can I
 go ahead and develop it in this direction?



[]s,
   |alo
   +
--
  Hack and Roll  ( http://www.hackandroll.org )
News for, uh, whatever it is that we are.


http://zope.gf.com.br/lalo   mailto:[EMAIL PROTECTED]
 pgp key: http://zope.gf.com.br/lalo/pessoal/pgp

Brazil of Darkness (RPG)--- http://zope.gf.com.br/BroDar

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )




[Zope-dev] HiperDOM example (objlink, that is) ?

2000-10-26 Thread Gregor Hoffleit

Hi,

perhaps I'm too stupid, but I don't grok how the objlink method in the
HiperDOM example has to look like. Could somebody post an example ?

Gregor


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )