mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-11-29 08:56:03 +00:00
PROPPATCH: Setting properties on Principals now working.
This commit is contained in:
1 parent
fb5cd0403f
commit
84c5fbea22
5 files changed
+115
-5
No files matched your search
@@ -0,0 +1,27 @@
|
||||
HTTP/1.1 200 OK
|
||||
Date: Dow, 01 Jan 2000 00:00:00 GMT
|
||||
DAV: 1, 2, access-control, calendar-access, calendar-schedule, extended-mkcol, calendar-proxy
|
||||
Content-Length: 219
|
||||
Content-Type: text/xml; charset="utf-8"
|
||||
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<multistatus xmlns="DAV:">
|
||||
<response>
|
||||
<href>/caldav.php/user1/</href>
|
||||
<responsedescription>All requested changes were made.</responsedescription>
|
||||
</response>
|
||||
</multistatus>
|
||||
|
||||
displayname: >User Number One PROPPATCH'd in<
|
||||
fullname: >User Number One PROPPATCH'd in<
|
||||
|
||||
changed_by: >10<
|
||||
dav_name: >/user1/<
|
||||
property_name: >http://dotcal.com/principal-properties:country<
|
||||
property_value: >New Zealand<
|
||||
|
||||
changed_by: >10<
|
||||
dav_name: >/user1/<
|
||||
property_name: >http://dotcal.com/principal-properties:countrycode<
|
||||
property_value: >NZ<
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
#
|
||||
# Check for support of PROPPATCH method
|
||||
#
|
||||
# An attempt to set an arbitrary property on a principal
|
||||
#
|
||||
TYPE=PROPPATCH
|
||||
URL=http://mycaldav/caldav.php/user1/
|
||||
HEADER=User-agent: SpecTest PROPPATCH
|
||||
HEADER=Content-type: text/xml
|
||||
HEAD
|
||||
|
||||
BEGINDATA
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<propertyupdate xmlns="DAV:" xmlns:DC="http://dotcal.com/principal-properties">
|
||||
<set>
|
||||
<prop>
|
||||
<DC:country>New Zealand</DC:country>
|
||||
<DC:countrycode>NZ</DC:countrycode>
|
||||
<displayname>User Number One PROPPATCH'd in</displayname>
|
||||
</prop>
|
||||
</set>
|
||||
</propertyupdate>
|
||||
ENDDATA
|
||||
|
||||
QUERY
|
||||
SELECT fullname, displayname FROM dav_principal WHERE dav_name = '/user1/';
|
||||
ENDQUERY
|
||||
|
||||
QUERY
|
||||
SELECT dav_name, property_name, property_value, changed_by FROM property WHERE dav_name = '/user1/';
|
||||
ENDQUERY
|
||||
@@ -0,0 +1,17 @@
|
||||
HTTP/1.1 200 OK
|
||||
Date: Dow, 01 Jan 2000 00:00:00 GMT
|
||||
DAV: 1, 2, access-control, calendar-access, calendar-schedule, extended-mkcol, calendar-proxy
|
||||
Content-Length: 219
|
||||
Content-Type: text/xml; charset="utf-8"
|
||||
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<multistatus xmlns="DAV:">
|
||||
<response>
|
||||
<href>/caldav.php/user1/</href>
|
||||
<responsedescription>All requested changes were made.</responsedescription>
|
||||
</response>
|
||||
</multistatus>
|
||||
|
||||
displayname: >User 1<
|
||||
fullname: >User 1<
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
#
|
||||
# Check for support of PROPPATCH method
|
||||
#
|
||||
# An attempt to set an arbitrary property on a principal
|
||||
#
|
||||
TYPE=PROPPATCH
|
||||
URL=http://mycaldav/caldav.php/user1/
|
||||
HEADER=User-agent: SpecTest PROPPATCH
|
||||
HEADER=Content-type: text/xml
|
||||
HEAD
|
||||
|
||||
BEGINDATA
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<propertyupdate xmlns="DAV:" xmlns:DC="http://dotcal.com/principal-properties">
|
||||
<set>
|
||||
<prop>
|
||||
<displayname>User 1</displayname>
|
||||
</prop>
|
||||
</set>
|
||||
<remove>
|
||||
<prop>
|
||||
<DC:country/>
|
||||
<DC:countrycode/>
|
||||
</prop>
|
||||
</remove>
|
||||
</propertyupdate>
|
||||
ENDDATA
|
||||
|
||||
QUERY
|
||||
SELECT fullname, displayname FROM dav_principal WHERE dav_name = '/user1/';
|
||||
ENDQUERY
|
||||
|
||||
QUERY
|
||||
SELECT * FROM property WHERE dav_name = '/user1/';
|
||||
ENDQUERY
|
||||
Reference in new issue
Block a user