Hello everyone,
First of all, I wish you all a merry christmas (a little bit late) and a happy new year to come. Well I'm currently facing a tricky issue with Orbeon and I hope you will be able to give me some advice. My aim is to handle an order form. This order form is to be printed (as PDF, the PDF template processor works amazingly) and sent as XML file to another system. The thing is that this form contains some private data that: * should only be printed, and not be transferred (for example Credit Card Number); * should anyway be validated other XML schema. The solution I found and that almost works now is: * separate the data to be transmitted (public) and data to be only printed (private) into two Xforms models; * thus, the public model AND the private model can refer to their own XML schema. This works fine and fields controls on screen are correct. * on PDF submission, I use a print-instance in which I agregate public and private instances to be printed. * on file submission, I only submit the public instance. All this is working very well. BUT: * Whereas the controls shows exclamation marks on private instance (in private model) fields when not valid, I am able to submit the complete form for PDF output. I think this is due to the fact that the submission I use is declared in the public model, and thus it does not try to validate the private model...! I have attached a very simple example exposing this behavior: testxform.zip In this example, the user is able to download the public instance even if the private one is not valid. In fact my question is simple: how can I prevent the submission of an instance if another instance, located in another model, is not valid? Or maybe can you help me with another suggestion that does not involve model separation. Thank you for your support on this. Mathieu FERRY |
Administrator
|
Mathieu,
I fear that this may not be completely trivial. I could see a possible hack: submit the instance you don't want to submit to a dummy location (you could even use the "test:" URL...). Only if you catch xforms- submit-done do you then proceed with submitting the first instance. -Erik On Dec 26, 2007, at 3:16 PM, mferry wrote: > > Hello everyone, > > First of all, I wish you all a merry christmas (a little bit late) > and a > happy new year to come. > > Well I'm currently facing a tricky issue with Orbeon and I hope you > will be > able to give me some advice. > > My aim is to handle an order form. This order form is to be printed > (as PDF, > the PDF template processor works amazingly) and sent as XML file to > another > system. > The thing is that this form contains some private data that: > * should only be printed, and not be transferred (for example Credit > Card > Number); > * should anyway be validated other XML schema. > > The solution I found and that almost works now is: > * separate the data to be transmitted (public) and data to be only > printed > (private) into two Xforms models; > * thus, the public model AND the private model can refer to their > own XML > schema. This works fine and fields controls on screen are correct. > * on PDF submission, I use a print-instance in which I agregate > public and > private instances to be printed. > * on file submission, I only submit the public instance. > > All this is working very well. > > BUT: > * Whereas the controls shows exclamation marks on private instance (in > private model) fields when not valid, I am able to submit the > complete form > for PDF output. > I think this is due to the fact that the submission I use is > declared in the > public model, and thus it does not try to validate the private > model...! > > I have attached a very simple example exposing this behavior: > http://www.nabble.com/file/p14503021/testxform.zip testxform.zip > > In this example, the user is able to download the public instance > even if > the private one is not valid. > > In fact my question is simple: how can I prevent the submission of an > instance if another instance, located in another model, is not valid? > Or maybe can you help me with another suggestion that does not > involve model > separation. > > Thank you for your support on this. > > Mathieu FERRY > -- > View this message in context: http://www.nabble.com/Multiple-model-conditional-submission-tp14503021p14503021.html > Sent from the ObjectWeb OPS - Users mailing list archive at > Nabble.com. > > > -- > You receive this message as a subscriber of the [hidden email] > mailing list. > To unsubscribe: mailto:[hidden email] > For general help: mailto:[hidden email]?subject=help > OW2 mailing lists service home page: http://www.ow2.org/wws Orbeon Forms - Web Forms for the Enterprise Done the Right Way http://www.orbeon.com/ -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Thank you Erik for this hint,
I'll try this and give a feedback. Regards, -- Mathieu FERRY Erik Bruchez <ebruchez@orbeon .com> Pour Envoyé par : [hidden email] Erik Bruchez cc <ebruchez@gmail. com> Objet Re: [ops-users] Multiple model conditional submission 18/01/2008 09:10 PM Veuillez répondre à [hidden email] g Mathieu, I fear that this may not be completely trivial. I could see a possible hack: submit the instance you don't want to submit to a dummy location (you could even use the "test:" URL...). Only if you catch xforms- submit-done do you then proceed with submitting the first instance. -Erik On Dec 26, 2007, at 3:16 PM, mferry wrote: > > Hello everyone, > > First of all, I wish you all a merry christmas (a little bit late) > and a > happy new year to come. > > Well I'm currently facing a tricky issue with Orbeon and I hope you > will be > able to give me some advice. > > My aim is to handle an order form. This order form is to be printed > (as PDF, > the PDF template processor works amazingly) and sent as XML file to > another > system. > The thing is that this form contains some private data that: > * should only be printed, and not be transferred (for example Credit > Card > Number); > * should anyway be validated other XML schema. > > The solution I found and that almost works now is: > * separate the data to be transmitted (public) and data to be only > printed > (private) into two Xforms models; > * thus, the public model AND the private model can refer to their > own XML > schema. This works fine and fields controls on screen are correct. > * on PDF submission, I use a print-instance in which I agregate > public and > private instances to be printed. > * on file submission, I only submit the public instance. > > All this is working very well. > > BUT: > * Whereas the controls shows exclamation marks on private instance (in > private model) fields when not valid, I am able to submit the > complete form > for PDF output. > I think this is due to the fact that the submission I use is > declared in the > public model, and thus it does not try to validate the private > model...! > > I have attached a very simple example exposing this behavior: > http://www.nabble.com/file/p14503021/testxform.zip testxform.zip > > In this example, the user is able to download the public instance > even if > the private one is not valid. > > In fact my question is simple: how can I prevent the submission of an > instance if another instance, located in another model, is not valid? > Or maybe can you help me with another suggestion that does not > involve model > separation. > > Thank you for your support on this. > > Mathieu FERRY > -- > View this message in context: > Sent from the ObjectWeb OPS - Users mailing list archive at > Nabble.com. > > > -- > You receive this message as a subscriber of the [hidden email] > mailing list. > To unsubscribe: mailto:[hidden email] > For general help: mailto:[hidden email]?subject=help > OW2 mailing lists service home page: http://www.ow2.org/wws Orbeon Forms - Web Forms for the Enterprise Done the Right Way http://www.orbeon.com/ -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Free forum by Nabble | Edit this page |