orbeon / orbeon-forms

Orbeon Forms is an open source web forms solution. It includes an XForms engine, the Form Builder web-based form editor, and the Form Runner runtime.
http://www.orbeon.com/
GNU Lesser General Public License v2.1
514 stars 220 forks source link

FR: Publish/unpublish of form should not change last modified date #1210

Open ebruchez opened 11 years ago

ebruchez commented 11 years ago

This has been reported by a customer. It is a bit confusing to see the last modification date of the form change when publishing/unpublishing.

What we do when we publish or unpublish a form is that we read and write the form definition itself. And that is because the form's metadata is stored within the form itself, and we don't have a separate API to write that metadata. So the form is written again and its date changes.

It's might be desirable to go the separate "update form metadata" API route for this.

avernet commented 11 years ago

Maybe Form Runner could pass the timestamp of the document to the persistence layer? Right now the RDBMs persistence layers use current-dateTime() (e.g. for MySQL), but could very easily take a time passed in the request, if present.

ebruchez commented 11 years ago

If we make a distinction between "data" (form definition) and "metadata", and consider that embedding the metadata within or around the data is just an implementation detail, I think it would make sense to change the API. Then, if that requires a way, at the lower level, to pass the document's last modification date, then we should certainly do that.