def do_POST(self):
dc = self.IFACE_CLASS
uri = urlparse.urljoin(self.get_baseuri(dc), self.path)
uri = urllib.unquote(uri)
dbname, dburi = TrytonDAVInterface.get_dburi(uri)
if dburi.startswith('Calendars'):
# read the body
body = None
if 'Content-Length' in self.headers:
l = self.headers['Content-Length']
body = self.rfile.read(atoi(l))
ct = None
if 'Content-Type' in self.headers:
ct = self.headers['Content-Type']
try:
DATA = '%s\n' % dc._get_caldav_post(uri, body, ct)
except DAV_Error, exception:
ec, _ = exception
return self.send_status(ec)
self.send_body(DATA, 200, 'OK', 'OK')
return
return _prev_do_POST(self)
评论列表
文章目录