From xmlrpc@opengroupware.org Sun Jun 4 22:08:17 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Sun, 04 Jun 2006 17:08:17 -0400 Subject: [OGo-XML-RPC] Multiple Qualifiers Message-ID: <1149455297.8799.0.camel@aleph.whitemice.org> Is it possible have multiple qualifiers in the fetch spec for an enterprise or contact fetch operation? I've tried both "firstname = 'STEVE' AND name = 'SEIBEL'" and "firstname like 'STEVE' AND name like 'SEIBEL'", but get a fault message like "UnsupportedQualifierException: SkyPersonDataSource: EOKeyValueQualifers are only supported with the following operators: (EOQualifierOperatorLike, EOQualifierOperatorEqual): firstname like 'steve'" But a qualifier like "name like 'seibel'" works, as does "firstname like 'steve'" Multiple qualifiers seems to work for retrieving tasks. From xmlrpc@opengroupware.org Sun Jun 4 22:24:58 2006 From: xmlrpc@opengroupware.org (Helge Hess) Date: Sun, 4 Jun 2006 23:24:58 +0200 Subject: [OGo-XML-RPC] Multiple Qualifiers In-Reply-To: <1149455297.8799.0.camel@aleph.whitemice.org> References: <1149455297.8799.0.camel@aleph.whitemice.org> Message-ID: <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> On Jun 4, 2006, at 11:08PM, Adam Tauno Williams wrote: > Is it possible have multiple qualifiers in the fetch spec for an > enterprise or contact fetch operation? Unfortunately, no. More exactly, the backend is a command like "company::search" which takes a simple dictionary (aka Map aka Hashtable) plus an operation (AND/OR) as arguments. So you can only specify one operation per search and only one value per key, eg: operation = AND search-dict = { firstname = 'blub'; name = 'murks*'; } Yup, this sucks, but its the way it is right now ... should be fixed (a search command which can take arbitary qualifiers should be added). Greets, Helge From xmlrpc@opengroupware.org Wed Jun 7 03:18:29 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Tue, 06 Jun 2006 22:18:29 -0400 Subject: [OGo-XML-RPC] Multiple Qualifiers In-Reply-To: <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> References: <1149455297.8799.0.camel@aleph.whitemice.org> <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> Message-ID: <1149646710.7881.4.camel@aleph.whitemice.org> > > Is it possible have multiple qualifiers in the fetch spec for an > > enterprise or contact fetch operation? > Unfortunately, no. More exactly, the backend is a command like > "company::search" which takes a simple dictionary (aka Map aka > Hashtable) plus an operation (AND/OR) as arguments. > So you can only specify one operation per search and only one value > per key, eg: > operation = AND > search-dict = { > firstname = 'blub'; > name = 'murks*'; > } > Yup, this sucks, but its the way it is right now ... Actually, this would be fine, if I could get it to work. :) result = server.person.fetch( { 'operation' : 'AND', 'search-dict' : { 'firstname' : 'steve', 'name' : 'berns' }, 'sortOrderings' : ["name",], } Doesn't work. Neither does - result = server.person.fetch( { 'operation' : 'AND', 'search-dict' : [ 'firstname = steve', 'name = berns', ], 'sortOrderings' : ["name",], } ) From xmlrpc@opengroupware.org Wed Jun 7 18:30:34 2006 From: xmlrpc@opengroupware.org (Helge Hess) Date: Wed, 7 Jun 2006 19:30:34 +0200 Subject: [OGo-XML-RPC] Multiple Qualifiers In-Reply-To: <1149646710.7881.4.camel@aleph.whitemice.org> References: <1149455297.8799.0.camel@aleph.whitemice.org> <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> <1149646710.7881.4.camel@aleph.whitemice.org> Message-ID: <472446CD-B097-4E09-902E-01A109B6CD76@opengroupware.org> On Jun 7, 2006, at 4:18AM, Adam Tauno Williams wrote: > Actually, this would be fine, if I could get it to work. :) > > result = server.person.fetch( > { > 'operation' : 'AND', > 'search-dict' : { > 'firstname' : 'steve', > 'name' : 'berns' > }, > 'sortOrderings' : ["name",], > } > > Doesn't work. Hm, no. I explained how the backend works. The XML-RPC API uses EOQualifier objects. Should look like: server.person.fetch( { "qualifier": "firstName = 'steve' AND name = 'berns'", "sortOrderings": [ "name", ] }); Maybe use 'like' instead of '='. Didn't try. Greets, Helge From xmlrpc@opengroupware.org Wed Jun 7 18:53:36 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Wed, 07 Jun 2006 13:53:36 -0400 Subject: [OGo-XML-RPC] Multiple Qualifiers In-Reply-To: <472446CD-B097-4E09-902E-01A109B6CD76@opengroupware.org> References: <1149455297.8799.0.camel@aleph.whitemice.org> <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> <1149646710.7881.4.camel@aleph.whitemice.org> <472446CD-B097-4E09-902E-01A109B6CD76@opengroupware.org> Message-ID: <1149702816.4405.38.camel@aleph.whitemice.org> > Hm, no. I explained how the backend works. The XML-RPC API uses > EOQualifier objects. Should look like: > server.person.fetch( > { "qualifier": "firstName = 'steve' AND name = 'berns'", > "sortOrderings": [ "name", ] }); > Maybe use 'like' instead of '='. Didn't try. Yep, that is like what I started with. If I - result = server.person.fetch( { "qualifier": "firstName = 'steve' AND name = 'berns'", "sortOrderings" : ["name",], }); - I get a : xmlrpclib.Fault: If I - result = server.person.fetch( { "qualifier": "firstName LIKE 'steve' AND name LIKE 'berns'", "sortOrderings" : ["name",], }); - I get a : xmlrpclib.Fault: Interesting that this doesn't return an error - result = server.person.fetch( { "qualifier": "firstName LIKE '*steve*' AND name LIKE '*berns*'", "sortOrderings" : ["name",], }); - but it also returns no data. Neither does this, which I know should match - result = server.person.fetch( { "qualifier": "firstName LIKE '*tev*' AND name LIKE '*ern*'", "sortOrderings" : ["name",], }); Do you think there might be a bug here? Bummer. It seems that, at least for companies (contacts & enterprises) I can search for just about any value using a fetchSpec, including extended attributes. So I put together a Gtk# form so I could do something like query-by-example... then next/prev around in the results. It works so long as I only put a value in one field. That and I'm still getting tweaked by bug#1598 (duplicate comment fields): http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=1598 From xmlrpc@opengroupware.org Thu Jun 8 01:46:41 2006 From: xmlrpc@opengroupware.org (Helge Hess) Date: Thu, 8 Jun 2006 02:46:41 +0200 Subject: [OGo-XML-RPC] Multiple Qualifiers In-Reply-To: <1149702816.4405.38.camel@aleph.whitemice.org> References: <1149455297.8799.0.camel@aleph.whitemice.org> <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> <1149646710.7881.4.camel@aleph.whitemice.org> <472446CD-B097-4E09-902E-01A109B6CD76@opengroupware.org> <1149702816.4405.38.camel@aleph.whitemice.org> Message-ID: <9C7D60C2-66E0-4180-A376-2271A08E20C6@opengroupware.org> On Jun 7, 2006, at 7:53PM, Adam Tauno Williams wrote: > Interesting that this doesn't return an error - > result = server.person.fetch( > { > "qualifier": "firstName LIKE '*steve*' AND name LIKE > '*berns*'", > "sortOrderings" : ["name",], > }); > - but it also returns no data. Hm, yes, the EOQualifier=>backend converter checks for the "*". I think it can't do arbitary LIKE searches either (don't know which ones it can deal with). > Neither does this, which I know should match - > result = server.person.fetch( > { > "qualifier": "firstName LIKE '*tev*' AND name LIKE '*ern*'", > "sortOrderings" : ["name",], > }); > > > Do you think there might be a bug here? Maybe. Try 'tev*' instead of '*tev*'. Does this change anything? Greets, Helge From xmlrpc@opengroupware.org Thu Jun 8 02:44:20 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Wed, 07 Jun 2006 21:44:20 -0400 Subject: [OGo-XML-RPC] Multiple Qualifiers In-Reply-To: <9C7D60C2-66E0-4180-A376-2271A08E20C6@opengroupware.org> References: <1149455297.8799.0.camel@aleph.whitemice.org> <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> <1149646710.7881.4.camel@aleph.whitemice.org> <472446CD-B097-4E09-902E-01A109B6CD76@opengroupware.org> <1149702816.4405.38.camel@aleph.whitemice.org> <9C7D60C2-66E0-4180-A376-2271A08E20C6@opengroupware.org> Message-ID: <1149731060.7587.8.camel@aleph.whitemice.org> On Thu, 2006-06-08 at 02:46 +0200, Helge Hess wrote: > On Jun 7, 2006, at 7:53PM, Adam Tauno Williams wrote: > > Interesting that this doesn't return an error - > > result = server.person.fetch( > > { > > "qualifier": "firstName LIKE '*steve*' AND name LIKE > > '*berns*'", > > "sortOrderings" : ["name",], > > }); > > - but it also returns no data. > > Hm, yes, the EOQualifier=>backend converter checks for the "*". I > think it can't do arbitary LIKE searches either (don't know which > ones it can deal with). > > > Neither does this, which I know should match - > > result = server.person.fetch( > > { > > "qualifier": "firstName LIKE '*tev*' AND name LIKE '*ern*'", > > "sortOrderings" : ["name",], > > }); > > Do you think there might be a bug here? > Maybe. Try 'tev*' instead of '*tev*'. Does this change anything? "qualifier": "firstName LIKE '*teve' AND name LIKE '*ern*'" --> err "qualifier": "firstName LIKE 'tev*' AND name LIKE '*ern*'" --> no data "qualifier": "firstName LIKE 'stev*' AND name LIKE '*ern*'" --> no data "qualifier": "firstName LIKE 'stev*'", --> no data ... hmmm... ok..... "qualifier": "firstname LIKE 'stev*' AND name LIKE '*ern*'" --> RETURNS DATA "qualifier": "firstname LIKE 'steve' AND name LIKE '*ern*'" --> err "qualifier": "firstname LIKE '*steve' AND name LIKE '*ern*'" --> err "qualifier": "firstname LIKE 'steve*' AND name LIKE '*ern*'" --> RETURNS DATA "qualifier": "firstname LIKE 'steve*' AND name LIKE 'Bern*'" --> RETURNS DATA "qualifier": "firstname LIKE 'steve*' AND name LIKE 'Berns*'" --> RETURNS DATA Interesting, so if I stick an * on the end of the value then it works. I suppose that is something better then nothing, but it certainly is odd. From xmlrpc@opengroupware.org Thu Jun 8 02:48:57 2006 From: xmlrpc@opengroupware.org (Helge Hess) Date: Thu, 8 Jun 2006 03:48:57 +0200 Subject: [OGo-XML-RPC] Multiple Qualifiers In-Reply-To: <1149731060.7587.8.camel@aleph.whitemice.org> References: <1149455297.8799.0.camel@aleph.whitemice.org> <249604E5-229F-4BA6-9C5F-81627001B0B5@opengroupware.org> <1149646710.7881.4.camel@aleph.whitemice.org> <472446CD-B097-4E09-902E-01A109B6CD76@opengroupware.org> <1149702816.4405.38.camel@aleph.whitemice.org> <9C7D60C2-66E0-4180-A376-2271A08E20C6@opengroupware.org> <1149731060.7587.8.camel@aleph.whitemice.org> Message-ID: <927F8ECF-268D-445E-96AC-F5AC2C0E237D@opengroupware.org> On Jun 8, 2006, at 3:44AM, Adam Tauno Williams wrote: > I suppose that is something better then nothing, but it certainly is > odd. "I told you so" ;-) Really, its odd and not really required. Should be fixed, but its quite some work to fix it. Greets, Helge From xmlrpc@opengroupware.org Mon Jun 26 11:42:54 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Mon, 26 Jun 2006 06:42:54 -0400 Subject: [OGo-XML-RPC] OGoMojo 0.0.19 w/MOGIMon Message-ID: <1151318574.11373.3.camel@aleph.whitemice.org> OGoMojo-0.0.19 is available - http://docs.opengroupware.org/Members/whitemice/OGoMojo/OGoMojo-0.0.19.tar.gz/view This is the interim 0.0.19 release of OGoMojo. This release features the first version of MOGIMon, a service which monitors the OpenGroupware log table in order to propogate changes to other applications, send user notifications, etc... This is an interim release, meaning that I haven't gone through all the tests to verify no regressions. However, besides MOGIMon, a great number of potential crashers have been fixed. Some MOGIMon documentation: http://docs.opengroupware.org/Members/whitemice/OGoMojo/MOGIMon-HOWTO/view An example MOGIMon "plugin" (pusher) is here: http://docs.opengroupware.org/Members/whitemice/OGoMojo/Hedera.cs/view This example plugin propagates Update and Create events to another database over an ODBC connection. Although it doesn't matter, this remote database is an Informix Universal Server; data is propagated to facilitate use in reporting and ERP applications. Changes are made via a web interface to OGo via XML-RPC and then flow back into the 'main' database. MOGIMon gives this the appearance of a live connection between the two databases. Caveat - Currently only update and create events can really be propogated, because when a delete event occurs it is impossible to discover what type of object it was that was deleted. Also this expects an up-to-date obj_link table. So using OGo's own log table isn't ideal but doing so provided a quick solution that was at least close to complete. We're try to figure out some more complete method of capturing change events. From xmlrpc@opengroupware.org Tue Jun 27 13:49:48 2006 From: xmlrpc@opengroupware.org (xmlrpc@opengroupware.org) Date: Tue, 27 Jun 2006 14:49:48 +0200 Subject: [OGo-XML-RPC] Passing dates from Perl Message-ID: Hello, I am writing a small Perl script to become familiar with the XML-RPC API. I am using the RPC::XML::Client package of Perl to get a connection to the OGo server. Now, I want to create a task programmatically. But contrary to the documentation, the xmlrpcd does not seem to accept dates in the format %Y%m%dT%H%M%S. In xmlrpcd.log I find the following: Jun 27 12:32:04 ogo-xmlrpcd-1.1 [3480]: [WARN] <0x08316CE4[LSNewJobCommand]> date command argument 'startDate' is not a date (NSShortInline8BitString): 20060722T10:30:00 Jun 27 12:32:04 ogo-xmlrpcd-1.1 [3480]: [ERROR] <0x08316CE4[LSNewJobCommand]> Could not convert key startDate (NSShortInline8BitString:20060722T10:30:00) to date, format is %Y-%m-%d %H:%M:%S When I try the format %Y-%m-%d %H:%M:%S, I still get the warning in the logs and an error on the client side, but the task is created all right. Can someone tell me more about this issue? Should I use %Y-%m-%d %H:%M:%S and ignore the warning, i.e. did the date format change since the documentation was written (xml-rpc-de.pdf from around 2003)? Or is it that the xmlrpcd somehow does not properly convert date strings into date objects in my setup? The server is runing OGo-1.1.3 with sope-4.5.6. Thanks, Alex From xmlrpc@opengroupware.org Tue Jun 27 14:19:16 2006 From: xmlrpc@opengroupware.org (Helge Hess) Date: Tue, 27 Jun 2006 15:19:16 +0200 Subject: [OGo-XML-RPC] Passing dates from Perl In-Reply-To: References: Message-ID: <1A756C09-D358-4B4E-AE33-2FB5603912D1@opengroupware.org> On Jun 27, 2006, at 14:49, alex.lists@freenet.de wrote: > Now, I want to create a task programmatically. But contrary to the > documentation, the xmlrpcd does not seem to accept dates in the format > %Y%m%dT%H%M%S. You need to submit proper XML-RPC date values, not strings. Helge From xmlrpc@opengroupware.org Tue Jun 27 14:35:01 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Tue, 27 Jun 2006 09:35:01 -0400 Subject: [OGo-XML-RPC] Passing dates from Perl In-Reply-To: References: Message-ID: <1151415301.3888.13.camel@aleph.whitemice.org> > I am writing a small Perl script to become familiar with the XML-RPC > API. I am using the RPC::XML::Client package of Perl to get a > connection to the OGo server. > Now, I want to create a task programmatically. But contrary to the > documentation, the xmlrpcd does not seem to accept dates in the format > %Y%m%dT%H%M%S. > In xmlrpcd.log I find the following: > Jun 27 12:32:04 ogo-xmlrpcd-1.1 [3480]: [WARN] <0x08316CE4[LSNewJobCommand]> date command argument 'startDate' is not a date (NSShortInline8BitString): 20060722T10:30:00 > Jun 27 12:32:04 ogo-xmlrpcd-1.1 [3480]: [ERROR] <0x08316CE4[LSNewJobCommand]> Could not convert key startDate (NSShortInline8BitString:20060722T10:30:00) to date, format is %Y-%m-%d %H:%M:%S > When I try the format %Y-%m-%d %H:%M:%S, I still get the warning in > the logs and an error on the client side, but the task is created all > right. I think it accepts standard dates as in PHP I can call XML_RPC_iso8601_encode($value) to encode the date and in .NET using the CookComputing XML-RPC assembly DateTime types are automatically formatted and submitted without errors. > Can someone tell me more about this issue? Should I use %Y-%m-%d > %H:%M:%S and ignore the warning, i.e. did the date format change since > the documentation was written (xml-rpc-de.pdf from around 2003)? It might be useful to look at the code of POGI (PHP) or OGoMojo (C#), as I've gotten most things to work in both of those. There are lots of 'caveats and addendums' that xml-rpc-de doesn't include. > Or > is it that the xmlrpcd somehow does not properly convert date strings > into date objects in my setup? > The server is runing OGo-1.1.3 with sope-4.5.6. An insertJob call on-the-wire looks like ------------------ Content-Type: text/xml User-Agent: XML-RPC.NET Authorization: Basic ******************** Content-Length: 24391 Connection: keep-alive Host: gourd-amber person.insertJob owner id skyrix://gourd-amber.morrison.iserv.net/morrisonOGo/10000 login ogo url http://www.whitemice.org login adam gender male isComplete 1 addresses mailing country USA type mailing state MI name1 ********************* street ********************* zip ********************* id skyrix://gourd-amber.morrison.iserv.net/morrisonOGo/10140 city ********************* name2 CIS/IT Dept. name3 ATTN: Adam Tauno Williams private id skyrix://gourd-amber.morrison.iserv.net/morrisonOGo/10130 city Grand Rapids name1 Adam Tauno Williams country USA zip ********************* street ********************* state MI type private location country USA type location state MI name1 Morrison Industrial Equipment street ********************* zip ********************* id skyrix://gourd-amber.morrison.iserv.net/morrisonOGo/10150 city Grand Rapids name2 CIS/IT Dept. name3 ATTN: Adam Tauno Williams keywords extendedKeys email1 email2 callfrequency division email3 headboy job_title mailmktcode other_title1 other_title2 salesperson territory birthday 19271206T05:00:00 number OGo10100 objectVersion 183 comment This dude rocks! firstname Adam phoneTypes 01_tel 02_tel 03_tel_funk 05_tel_private 10_fax 15_fax_private id skyrix://gourd-amber.morrison.iserv.net/morrisonOGo/10100 isAccount 1 extendedAttrs email1 adam@morrison-ind.com headboy no email3 awilliam@wmmi.net email2 awilliam@whitemice.org salesperson none territory none lastChanged 20031128T12:17:25 job_title System and Network Administrator phones 03_tel_funk telephoneId 10180 info number **************** type 03_tel_funk 01_tel telephoneId 10160 info number **************** type 01_tel 15_fax_private telephoneId 10210 info number type 15_fax_private 10_fax telephoneId 10200 info number **************** type 10_fax 02_tel telephoneId 10170 info number type 02_tel 05_tel_private telephoneId 10190 info number type 05_tel_private isPrivate 0 name Williams degree UNIX System Administration nickname ATW middlename Tauno associatedContacts Associated Contacts totalWork 75 actualWork 50 executor id skyrix://gourd-amber.morrison.iserv.net/morrisonOGo/10100 login adam creator id skyrix://gourd-amber.morrison.iserv.net/morrisonOGo/10100 login adam priority 1 percentComplete 25 keywords mogi insertJob sensitivity 3 associatedCompanies Associated Companies accountingInfo Accounting Info startDate 20060627T00:00:00 name TEST JOB endDate 20060704T00:00:00 From xmlrpc@opengroupware.org Tue Jun 27 15:19:41 2006 From: xmlrpc@opengroupware.org (xmlrpc@opengroupware.org) Date: Tue, 27 Jun 2006 16:19:41 +0200 Subject: [OGo-XML-RPC] Re: Passing dates from Perl References: <1A756C09-D358-4B4E-AE33-2FB5603912D1@opengroupware.org> Message-ID: Helge Hess writes: > On Jun 27, 2006, at 14:49, alex.lists@freenet.de wrote: >> Now, I want to create a task programmatically. But contrary to the >> documentation, the xmlrpcd does not seem to accept dates in the format >> %Y%m%dT%H%M%S. > > You need to submit proper XML-RPC date values, not strings. > Ahh, I see. I have to wrap the arguments into XML-RPC types. For the record, in Perl you can do this like so: use RPC::XML qw/RPC_DATETIME_ISO8601 time2iso8601/; $time = RPC_DATETIME_ISO8601 "20060701T17:00:00"; Thanks again, Alex From xmlrpc@opengroupware.org Wed Jun 28 12:26:52 2006 From: xmlrpc@opengroupware.org (xmlrpc@opengroupware.org) Date: Wed, 28 Jun 2006 13:26:52 +0200 Subject: [OGo-XML-RPC] Creating Team Tasks Message-ID: Hello, is there a way to create a team task via XML-RPC? According to the API documentation the job data type has an "isTeamJob" field, but I cannot figure out how to specify the team. Thanks, Alex From xmlrpc@opengroupware.org Wed Jun 28 16:33:12 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Wed, 28 Jun 2006 11:33:12 -0400 Subject: [OGo-XML-RPC] Creating Team Tasks In-Reply-To: References: Message-ID: <1151508792.3997.23.camel@aleph.whitemice.org> > is there a way to create a team task via XML-RPC? According to the API > documentation the job data type has an "isTeamJob" field, but I cannot > figure out how to specify the team. I'm not certain that the isTeamJob actually signifies. Does it mean the task is currently delegated to a team, or that it was created delegated to a team, etc... ? Have you tried simply setting the executant to be a team? My fear is your going to bump into - http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=239 (which has pretty much shut down some of my intentions). From xmlrpc@opengroupware.org Thu Jun 29 14:32:38 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Thu, 29 Jun 2006 09:32:38 -0400 Subject: [OGo-XML-RPC] LSDBObjectCommandException - no participants set In-Reply-To: <7cf0134682f745468ab6592f80a1a31f@opengroupware.org> References: <92fad8ce0601181151t1e9cb9dbh8b249e83dade2fab@mail.gmail.com> <1137768940.7069.6.camel@aleph.whitemice.org> <92fad8ce0601201921j2c7f8864pc28747da04dd5652@mail.gmail.com> <7cf0134682f745468ab6592f80a1a31f@opengroupware.org> Message-ID: <1151587958.3831.11.camel@aleph.whitemice.org> On Sat, 2006-01-21 at 11:35 +0100, Helge Hess wrote: > On Jan 21, 2006, at 4:21, Alejandro Martínez Marcos wrote: > > The problem is that wether I try to insert an appointment > > without any participants, or wether I put some participants in it, I > > always get the same exception ("no participants set"). It seems that > > this version of Ogo requires participants to insert and appointment, > > and that there is some bug in xml-rpc (or I am doing something wrong > > or have something misconfigured). > I would expect that, in OGo every appointment must have a participant. > The only thing I could imagine is that the xmlrpcd somehow uses the > login user as the participant automagically if no other participants > are passed in. Yep, just confirmed that, if no participants are specified then the creator is automatically assigned as a participant. Sending ----------------------- {'startDate': , 'endDate': , 'title': 'Test Appointment I'} Appointment Created! ---------------------- {'startDate': , 'endDate': , 'title': 'Test Appointment I', 'participants': [{'password': '*************', 'dbStatus': 'updated', 'name': 'Williams', 'firstname': 'adam', 'companyId': 10410, 'number': 'OGo10410', 'objectVersion': 2, 'isLocked': 0, 'isAccount': 1, 'isExtraAccount': 0, 'isPerson': 1, 'ownerId': 10000, 'login': 'adam', 'isIntraAccount': 1, 'templateUserId': 9999}], 'location': '', 'id': 'skyrix://ws1.cable.orka.telecoms.bg/localhost.localdomain/10680'} It really feels like it has to be some kind of packaging thing, because it works perfectly on my OGo boxes. But I can't imagine how/what. > Maybe you should create a bugreport on the matter and attach a small > Python script which reproduces the issue. http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=1683 http://bugzilla.opengroupware.org/bugzilla/attachment.cgi?id=434&action=view From xmlrpc@opengroupware.org Thu Jun 29 14:45:29 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Thu, 29 Jun 2006 09:45:29 -0400 Subject: [OGo-XML-RPC] LSDBObjectCommandException - no participants set In-Reply-To: <1151587958.3831.11.camel@aleph.whitemice.org> References: <92fad8ce0601181151t1e9cb9dbh8b249e83dade2fab@mail.gmail.com> <1137768940.7069.6.camel@aleph.whitemice.org> <92fad8ce0601201921j2c7f8864pc28747da04dd5652@mail.gmail.com> <7cf0134682f745468ab6592f80a1a31f@opengroupware.org> <1151587958.3831.11.camel@aleph.whitemice.org> Message-ID: <1151588729.3831.15.camel@aleph.whitemice.org> > > > The problem is that wether I try to insert an appointment > > > without any participants, or wether I put some participants in it, I > > > always get the same exception ("no participants set"). It seems that > > > this version of Ogo requires participants to insert and appointment, > > > and that there is some bug in xml-rpc (or I am doing something wrong > > > or have something misconfigured) > > Maybe you should create a bugreport on the matter and attach a small > > Python script which reproduces the issue. > http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=1683 > http://bugzilla.opengroupware.org/bugzilla/attachment.cgi?id=434&action=view What I'm seeing is that I can create *ONE* appointment, and subsequent calls to appointment.insert fail. Restarting ogo-xmlrpcd allows me to create one more appointment, etc... First Run ----------------------- [root@ws1 ~]# ./test2.py 20060118T10:10:10 20060118T11:15:10 /usr/lib/python2.3/xmlrpclib.py:373: FutureWarning: %u/%o/%x/%X of negative int will return a signed string in Python 2.4 and up return "" % (repr(self.value), id(self)) {'startDate': , 'endDate': , 'title': 'Test Appointment I'} Appointment Created! ---------------------- {'startDate': , 'endDate': , 'title': 'Test Appointment I', 'participants': [{'password': '***************', 'dbStatus': 'updated', 'name': 'Williams', 'firstname': 'adam', 'companyId': 10410, 'number': 'OGo10410', 'objectVersion': 2, 'isLocked': 0, 'isAccount': 1, 'isExtraAccount': 0, 'isPerson': 1, 'ownerId': 10000, 'login': 'adam', 'isIntraAccount': 1, 'templateUserId': 9999}], 'location': '', 'id': 'skyrix://ws1.cable.orka.telecoms.bg/TestBox/10730'} Second Run ----------------------- [root@ws1 ~]# ./test2.py 20060119T10:10:10 20060119T11:15:10 /usr/lib/python2.3/xmlrpclib.py:373: FutureWarning: %u/%o/%x/%X of negative int will return a signed string in Python 2.4 and up return "" % (repr(self.value), id(self)) {'startDate': , 'endDate': , 'title': 'Test Appointment I'} Traceback (most recent call last): File "./test2.py", line 18, in ? result = server.appointment.insert(dict) File "/usr/lib/python2.3/xmlrpclib.py", line 1029, in __call__ return self.__send(self.__name, args) File "/usr/lib/python2.3/xmlrpclib.py", line 1316, in __request verbose=self.__verbose File "/usr/lib/python2.3/xmlrpclib.py", line 1080, in request return self._parse_response(h.getfile(), sock) File "/usr/lib/python2.3/xmlrpclib.py", line 1219, in _parse_response return u.close() File "/usr/lib/python2.3/xmlrpclib.py", line 742, in close raise Fault(**self._stack[0]) xmlrpclib.Fault: From xmlrpc@opengroupware.org Thu Jun 29 17:37:10 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Thu, 29 Jun 2006 12:37:10 -0400 Subject: [OGo-XML-RPC] POGI 0.2.1 Released Message-ID: <1151599030.6313.0.camel@aleph.whitemice.org> http://docs.opengroupware.org/Members/whitemice/ogo-n-php/pogi021/view New required configuration value: $GLOBALS['ogoConfig']['NumberPrefix'] = 'OGo'; Change the value of this is you have altered the value of the Number prefix via defaults. The code needs to know this so we can strip it from then number to produce a short ids for the team as the team objects do not contain an id value - and you have to use the id value when calling the access methods. http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=844 New method: OGoTeam::getShortId() New method: OGoManager::setPermission($_obj, $_ent, $_perm = '') To set contact 10100 to read only for object 26850 ----------------------------------------------------- $server = new OGoServer('*************', '/RPC2', 80); // Set you user credentials - username, password $server->login('************', '***********'); // Create A Task Manager Object $contactManager = $server->getPersonManager(); $contact = $contactManager->getById(10100); $contactManager->setPermission($contact, array(26850), 'r'); _obj is an enterprise or contact object. _ent is an array of object ids, either accounts or teams. _perm can be "", "r" or "rw" _obj must be an OGoEnterprise or OGoPerson object or else this method silently does nothing. You can also specify an $_ent as null, like - $contactManager->setPermission($contact, null, ''); This will apply the specified permissions to the object for all of the teams the current user is a contact of. From xmlrpc@opengroupware.org Fri Jun 30 09:53:38 2006 From: xmlrpc@opengroupware.org (xmlrpc@opengroupware.org) Date: Fri, 30 Jun 2006 10:53:38 +0200 Subject: [OGo-XML-RPC] Re: Creating Team Tasks References: <1151508792.3997.23.camel@aleph.whitemice.org> Message-ID: Adam Tauno Williams writes: >> is there a way to create a team task via XML-RPC? According to the API >> documentation the job data type has an "isTeamJob" field, but I cannot >> figure out how to specify the team. > > I'm not certain that the isTeamJob actually signifies. Does it mean the > task is currently delegated to a team, or that it was created delegated > to a team, etc... ? I thought that the team flag had a simple meaning, but after reading this http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=752 I not sure anymore. > Have you tried simply setting the executant to be a team? > > My fear is your going to bump into - > http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=239 > (which has pretty much shut down some of my intentions). Yes, exactly: the executor is not preserved. Seems like the XML-RPC interface needs some work. By the way, what is the meaning of the person argument in the person.*Job() methods? Alex From xmlrpc@opengroupware.org Fri Jun 30 11:48:37 2006 From: xmlrpc@opengroupware.org (Adam Tauno Williams) Date: Fri, 30 Jun 2006 06:48:37 -0400 Subject: [OGo-XML-RPC] Re: Creating Team Tasks In-Reply-To: References: <1151508792.3997.23.camel@aleph.whitemice.org> Message-ID: <1151664517.4736.13.camel@aleph.whitemice.org> > >> is there a way to create a team task via XML-RPC? According to the API > >> documentation the job data type has an "isTeamJob" field, but I cannot > >> figure out how to specify the team. > > I'm not certain that the isTeamJob actually signifies. Does it mean the > > task is currently delegated to a team, or that it was created delegated > > to a team, etc... ? > I thought that the team flag had a simple meaning, but after reading > this > http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=752 > I not sure anymore. Yep, although I haven't tested that one in awhile. I know that when I tried to make a Gtk# widget for displaying tasks I had problems reliably determining what kind of object (team or account) the executant was. > > Have you tried simply setting the executant to be a team? > > My fear is your going to bump into - > > http://bugzilla.opengroupware.org/bugzilla/show_bug.cgi?id=239 > > (which has pretty much shut down some of my intentions). > Yes, exactly: the executor is not preserved. Seems like the XML-RPC > interface needs some work. It does. http://bugzilla.opengroupware.org/bugzilla/buglist.cgi?query_format=&product=XmlRpcAPI&bug_status=NEW&bug_status=NEEDINFO&bug_status=REOPENED&bug_status=ASSIGNED&short_desc_type=allwordssubstr&short_desc=&long_desc_type=substring&long_desc=&Search=Search But at least OGo has an API! :) Actually some bits of it work better than others; for instance, the contact/enterprise parts work pretty well and are quite complete. The schedular API seems like it is 90% 'there'. But the job.* namespace seems to be the red-headed step child of the API. The code repository contains this note ---- Note: the XML-RPC API as available will stay and not change for the foreseeable future. But you may want to check out the SandStorm servers or ZideStore, which both provide a bit easier API (but are less stable from an API point of view). ---- http://svn.opengroupware.org/viewcvs/trunk/XmlRpcAPI/README?rev=760&view=markup And if you are really bored/curious you can look around in SandStorm - http://svn.opengroupware.org/viewcvs/trunk/Recycler/SandStorm/skyjobd/INTERFACE.xml?rev=16&view=markup Retooling the XML-RPC API has been on the roadmap for a long time (although I can't seem to find that page right now) But so far I haven't been able to convince any bored C developers to look at it. :( But not for lack of trying. > By the way, what is the meaning of the person argument in the > person.*Job() methods? Always struck me as odd too, since it seems to have to be the current account anyway. I assume it instructs the daemon who the owner of the task is. From xmlrpc@opengroupware.org Fri Jun 30 12:07:12 2006 From: xmlrpc@opengroupware.org (Helge Hess) Date: Fri, 30 Jun 2006 13:07:12 +0200 Subject: [OGo-XML-RPC] Re: Creating Team Tasks In-Reply-To: <1151664517.4736.13.camel@aleph.whitemice.org> References: <1151508792.3997.23.camel@aleph.whitemice.org> <1151664517.4736.13.camel@aleph.whitemice.org> Message-ID: <97632970-C041-408D-977E-106438827C78@opengroupware.org> On Jun 30, 2006, at 12:48, Adam Tauno Williams wrote: > And if you are really bored/curious you can look around in SandStorm - > http://svn.opengroupware.org/viewcvs/trunk/Recycler/SandStorm/ > skyjobd/INTERFACE.xml?rev=16&view=markup This stuff is dead and won't get resurrected. The longterm goal is to add everything required to ZideStore. In the meantime, sure, we should fix xmlrpcd if it contains bugs and maybe even add some smaller methods ;-) >> By the way, what is the meaning of the person argument in the >> person.*Job() methods? > Always struck me as odd too, since it seems to have to be the current > account anyway. I assume it instructs the daemon who the owner of the > task is. Yup, the API contains some odd edges which probably deserve a cleanup ;-) Greets, Helge -- Helge Hess http://docs.opengroupware.org/Members/helge/