Page 1 of 1

expose propertygroups via webdav

PostPosted:Mon Sep 19, 2011 8:35 pm
by bkc
Hi,

I have uploaded a document, created a custom propertygroup and set a few properties on my document.

via webdav, I tried propnames command and get back a list like this:
Fetching property names `2011-08-misc.xls': http://www.openkm.org/1.0 author
http://www.jcp.org/jcr/1.0 isCheckedOut
DAV: displayname
DAV: creationdate
http://www.openkm.org/1.0 versionComment
http://www.openkm.org/1.0 size
DAV: lockdiscovery
DAV: getlastmodified
DAV: getetag
http://www.openkm.org/1.0 text
DAV: iscollection
DAV: resource-id
DAV: resourcetype
DAV: parent-set
DAV: supported-report-set
DAV: getcontenttype
DAV: supportedlock
DAV: getcontentlength
succeeded.
dav:/OpenKM/repository/default/okm:root/test/>
I would like to retrieve the properties from my custom propertygroup via webdav, but that doesn't work:
dav:/OpenKM/repository/default/okm:root/test/> propget 2011-08-misc.xls sfi.shipmentid
Fetching properties for `2011-08-misc.xls':
Could not fetch property: 404 Not Found
Can you add the ability to get and set custom propertygroup properties via webdav?

Also it would be nice to be able to set a property in a group on a document that doesn't yet have that propertygroup added. Can the server search the registered propertygroups and figure out which one to autmatically add when a propset command is issued?

Thanks

Re: expose propertygroups via webdav

PostPosted:Fri Sep 23, 2011 3:27 pm
by jllort
This kind of feature is not actually allowed via webdav.

I would like understanding better your scenario to understanding if it's good idea expose it there.

Re: expose propertygroups via webdav

PostPosted:Sun Sep 25, 2011 9:07 am
by pavila
Please, post your property groups definition. I don't see your custom property listed with the propnames command.

Re: expose propertygroups via webdav

PostPosted:Tue Oct 04, 2011 1:57 pm
by bkc
Hi, sorry for the late reply.

I guess what I really want is a full REST interface to openkm that allows me to set meta-data properties and search by those properties.

Since openKM doesn't seem to have that, it seemed reasonable to me to at least expose custom properties via webdav.

Here's my PropertyGroups.cnd
Code: Select all
[okg:sfi] mixin
- okp:sfi.shipmentid (string) = '' autocreated
- okp:sfi.orgid (string) = autocreated
- okp:sfi.document_type (string) = '' multiple autocreated
- okp:sfi.customs_entryid (string) = '' autocreated
- okp:sfi.status (string) = '' autocreated
- okp:sfi.customs_reference (string) = '' autocreated
- okp:sfi.customer_reference (string) = '' autocreated

Re: expose propertygroups via webdav

PostPosted:Wed Oct 12, 2011 7:02 am
by pavila
As I can see this Property Group has not been assigned to "2011-08-misc.xls" document. Also note that OpenKM has its API exposed by WebServices and this is a better (and more tested) approach to manage these metadata properties. Just go to http://wiki.openkm.com/index.php/Webservices_Guide and take a look.