Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

Recent XML-RPC Updates: msg#00018

cms.opengroupware.xmlrpc.devel

Subject: Recent XML-RPC Updates

For anyone not in the habit of tracking the ChangeLog -
http://www.opengroupware.org/changeblogger/ - this is just an FYI of
numerous patches recently applied to trunk.

* moved isPrivate handling from PersonDocument into CompanyDocument
object to allow for isPrivate in company records (Bug#316) (v5.3.78)
----------------------------------------------------
Should allow you to set private flag on enterprise documents. Currently
testing, there might still be a problem.


* added generic.getTypeById method (Bug#1708) (v5.3.77)
----------------------------------------------------
Allows you to retrieve the document type corresponding to a
pkey/objectId. This is useful especially when working with the obj_link
related actions.

#!/usr/bin/env python
import xmlrpclib
server = xmlrpclib.Server('http://awilliam:fred@localhost/RPC2')
result = server.generic.getTypeById("10003")
print result
result = server.generic.getTypeById("10000")
print result
result = server.generic.getTypeById("43")
print result

Returns:
Team
Person
Unknown


* added access.getACLById method (Bug#1684) (v5.3.76)
----------------------------------------------------
Allows you to retrieve the ACLs applied to an object.

And of the following are valid:
print server.access.getACLById(10120)
print server.access.getACLById("10120")
print server.access.getACLById("27160,10120")
print server.access.getACLById([ 27160 ])
print server.access.getACLById([ "27160", 10120 ])

#!/usr/bin/env python
import xmlrpclib
server = xmlrpclib.Server('http://awilliam:fred@localhost/RPC2')
print server.access.getACLById([ "27160", 10120 ])

Returns:
{'10120': [{'operations': 'wr', 'entityName': 'Team', 'objectId':
25850},
{'operations': 'wr', 'entityName': 'Person', 'objectId':
10120},
{'operations': 'wr', 'entityName': 'Team', 'objectId':
9981},
{'operations': 'w', 'entityName': 'Team', 'objectId':
25920},
{'operations': 'r', 'entityName': 'Team', 'objectId':
9991}],
'27160': [{'operations': 'r', 'entityName': 'Team', 'objectId':
10003},
{'operations': 'wr', 'entityName': 'Team', 'objectId':
9991}]}

NOTE: This is only tested for company objects (contacts & enteprises).
It might work for documents [in projects], it certainly will not work
for appointments.


* added appointment.setPermissions method (Bug#219) (v5.3.75)
-----------------------------------------
Allows you to change the permissions on appointment objects and adds the
"writeAccess" and "accessTeamId" to the appointment document.
"writeAccess" is an array of object id's with write access, and
accessTeamId is the team selected for read access.

#!/usr/bin/env python
import xmlrpclib
server = xmlrpclib.Server('http://awilliam:fred@localhost/RPC2')
result = server.appointment.setPermissions('25730', '10003', [ '9991',
'10003']);
print "Method Result: %s" % result
result = server.appointment.getById("25730")
print "Write Access: %s" % result['writeAccess']
print "Read Access: %s" % result['accessTeamId']
print
result = server.appointment.setPermissions('25730', '9991', '10003');
print "Method Result: %s" % result
result = server.appointment.getById("25730")
print "Write Access: %s" % result['writeAccess']
print "Read Access: %s" % result['accessTeamId']

Returns:
awilliam@aleph:~/OGo/TestScripts/xmlrpcd> ./setPermOnApp.py
Method Result: True
Write Access: ['9991', '10003']
Read Access: 10003

Method Result: True
Write Access: ['10003']
Read Access: 9991

Currently there is a small bug that you can only grant write access to
teams, and not to accounts; it should be possible to mix write access
for either.


* removed duplicate encoding of 'comment' key (Bug#1598) (v5.3.74)


* added appointment.setResources method (Bug#1599) (v5.3.73)
-----------------------------------------------
Allows to associate resources to appointments (by name).

For example:
server.appointment.setResources(25730, "North Conference Room");
server.appointment.setResources(25730, [ "North Conference Room", "Video
Projector #3" ]);
server.appointment.setResources("25730", [ ]);

However the "resourceNames" key is not yet encoded in the appointment
document, so you can't see you changes [ except in the WebUI]. :)
Patch forth-coming.


--
OpenGroupware.org XML-RPC
xmlrpc@xxxxxxxxxxxxxxxxx
http://mail.opengroupware.org/mailman/listinfo/xmlrpc



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
db.postgresql.b...    video.ffmpeg.us...    gis.qgis.devel/...    web.rdf.redland...    file-systems.oc...    recreation.rail...    systems.archos....    python.c++/2003...    lang.c--/2005-0...    multimedia.gpho...    network.unison....    editors.jedit.u...    hardware.pciids...    cms.tiki.cvs/20...    bug-tracking.ma...    java.hadoop.hba...    ietf.rsvp/2002-...    xfree86.devel/2...    qnx.openqnx.dev...    apache.labs.dev...    tex.pdftex/2008...    os.solaris.open...    user-groups.lin...    kde.koffice/200...   
Home | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation