Form versioning and the builder

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Form versioning and the builder

bwallis42
My persistence API implements versioning and I have been struggling with getting it to work correctly.

What seems to be missing from the documentation is that when a template is fetched you need to include the version number in the response headers using "orbeon-form-definition-version" for the name. If you don't then the builder always thinks you are editing version 1.

This should be added to the persistence API documentation.

Secondly, is there a way to open older versions of form templates in the builder? I cannot see how to do this and can only open the latest version.

In our system we can have a number of published "drafts" of a form template (say, versions 1, 2, 3, 4, 5)  and then decide to "release" one for general usage, say version 3. After that we might want to continue with an edit to version 4 (saving and replacing that version) and then release that one. Version 5 might have been an experiment that we later decide to delete or maybe release.

Sounds a bit complicated but it is how our current system works (with Orbeon 3.9) and I'd like to maintain that behaviour with our upgrade to 4.9 (or later).

thanks
brian wallis...
Reply | Threaded
Open this post in threaded view
|

Re: Form versioning and the builder

Alessandro  Vernet
Administrator
Hi Brian,

If by "template" you mean "deployed form definition", then you're correct, and this is so when a user fills out a form, we know which version of that form she filled, so we can use the correct definition when the data is shown again. And you're correct: the documentation didn't say anything about this; I've added a note about this on:


There is no versioning at the level of the Form Builder data (just like with any other data), so no, unfortunately not. This would certainly make sense, and we have an RFE for this:


Alex

On Mon, Jun 29, 2015 at 4:43 AM, bwallis42 <[hidden email]> wrote:
My persistence API implements versioning and I have been struggling with
getting it to work correctly.

What seems to be missing from the documentation is that when a template is
fetched you need to include the version number in the response headers using
"orbeon-form-definition-version" for the name. If you don't then the builder
always thinks you are editing version 1.

This should be added to the persistence API documentation.

Secondly, is there a way to open older versions of form templates in the
builder? I cannot see how to do this and can only open the latest version.

In our system we can have a number of published "drafts" of a form template
(say, versions 1, 2, 3, 4, 5)  and then decide to "release" one for general
usage, say version 3. After that we might want to continue with an edit to
version 4 (saving and replacing that version) and then release that one.
Version 5 might have been an experiment that we later decide to delete or
maybe release.

Sounds a bit complicated but it is how our current system works (with Orbeon
3.9) and I'd like to maintain that behaviour with our upgrade to 4.9 (or
later).

thanks
brian wallis...


--
View this message in context: http://discuss.orbeon.com/Form-versioning-and-the-builder-tp4660151.html
Sent from the Orbeon Forms community mailing list mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Reply | Threaded
Open this post in threaded view
|

Re: Form versioning and the builder

bwallis42
Alessandro Vernet wrote
If by "template" you mean "deployed form definition", then you're correct,
and this is so when a user fills out a form, we know which version of that
form she filled, so we can use the correct definition when the data is
shown again. And you're correct: the documentation didn't say anything
about this; I've added a note about this on:

http://wiki.orbeon.com/forms/doc/developer-guide/form-runner/persistence-api#TOC-CRUD
Thanks, that will help others implementing the API.

There is no versioning at the level of the Form Builder data (just like
with any other data), so no, unfortunately not. This would certainly make
sense, and we have an RFE for this:

https://github.com/orbeon/orbeon-forms/issues/750
I hadn't thought about it that way, pulling a published version back into the data store but that makes sense.

For the moment I will "fake" the versioning by manipulating the form ID value to include our form template version. This seems to work OK, now to edit a particular version of a form we use a URL like

http://localhost:8080/orbeon/fr/orbeon/builder/edit/124:9

to edit version 9 of the template. I am assuming that the ID field is treated opaquely in Orbeon and is just passed through to our persistence layer (it seems to be that way).

thanks
brian...

Reply | Threaded
Open this post in threaded view
|

Re: Form versioning and the builder

Alessandro  Vernet
Administrator
Brian,

Yes, other than the fact that the document id generated upon new form creation, it is just passed through to the persistence API.

Alex

On Mon, Jun 29, 2015 at 11:21 PM, bwallis42 <[hidden email]> wrote:
Alessandro  Vernet wrote
> If by "template" you mean "deployed form definition", then you're correct,
> and this is so when a user fills out a form, we know which version of that
> form she filled, so we can use the correct definition when the data is
> shown again. And you're correct: the documentation didn't say anything
> about this; I've added a note about this on:
>
> http://wiki.orbeon.com/forms/doc/developer-guide/form-runner/persistence-api#TOC-CRUD

Thanks, that will help others implementing the API.


> There is no versioning at the level of the Form Builder data (just like
> with any other data), so no, unfortunately not. This would certainly make
> sense, and we have an RFE for this:
>
> https://github.com/orbeon/orbeon-forms/issues/750

I hadn't thought about it that way, pulling a published version back into
the data store but that makes sense.

For the moment I will "fake" the versioning by manipulating the form ID
value to include our form template version. This seems to work OK, now to
edit a particular version of a form we use a URL like

http://localhost:8080/orbeon/fr/orbeon/builder/edit/124:9

to edit version 9 of the template. I am assuming that the ID field is
treated opaquely in Orbeon and is just passed through to our persistence
layer (it seems to be that way).

thanks
brian...



--
View this message in context: http://discuss.orbeon.com/Form-versioning-and-the-builder-tp4660151p4660159.html
Sent from the Orbeon Forms community mailing list mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet