I just test it up,
When can not have a field name wich contains a "-".
And as often, qooxdoo failled silently. Wchich is in my sens a bad idea.

2011/3/10 Benjamin Dreux <[email protected]>:
> I've tryed the solution i gaved, but it's still not working.
> Maybe if someone else look at this it will help;
> Here is the code i use to fetch the json data i use to fill the form:
>
>     this.contactStore = new qx.data.store.Json("xxx");
>     var formContact = this.contactForm();
>    var formView = new qx.ui.form.renderer.Single(formContact);
>    var formGroup = new qx.ui.groupbox.GroupBox(this.tr("Contact"));
>    formGroup.setLayout(new qx.ui.layout.Canvas());
>
>    formGroup.add(formView);
>    var scrollPane = new qx.ui.container.Scroll(formGroup);
>    contactDetailContainer.add(scrollPane,{flex:1});
>
>    var contactFormController = new qx.data.controller.Form(null,formContact);
>    this.contactStore.bind("model",contactFormController,"model");
>
> I will not show the real url. But i'm sure it work perfectly. because
> i can see the loaded file. When i stop the js script running, i can
> see that the controller has a copy of my json data in it's model
> property.
>
> Here is the form i use :
> contactForm :function(){
>       var form = new qx.ui.form.Form();
>
>       var firstNameField = new qx.ui.form.TextField();
>       firstNameField.setRequired(true);
>       form.add(firstNameField,this.tr("Firstname"),null,"first-name");
>
>       var lastNameField = new qx.ui.form.TextField();
>       lastNameField.setRequired(true);
>       form.add(lastNameField,this.tr("Lastname"),null,"last-name");
>       return form;
> }
> And here is the json data:
> {"first-name":"paul","last-name":"smith"}
>
> regards
> 2011/3/10 Benjamin Dreux <[email protected]>:
>> I was desperatly reading all the message about form in the userlist.
>> And then i found this message,
>> http://qooxdoo.678.n2.nabble.com/Form-controller-and-Radiobuttons-td4225459.html
>> It's kind of the same issue.
>> Then i add a look at qx.ui.form.Form#add
>> There is a special field to change the name of the propery in the 
>> databinding.
>>
>>
>>
>> 2011/3/10 Alexander Steitz <[email protected]>:
>>> Hi Benjamin,
>>>
>>> I can't answer your question, but I've informed the developer of this
>>> component so he can take a look and (hopefully) answer your question.
>>>
>>> Regards,
>>>  Alex
>>>
>>> On Thursday March 10 2011 17:29:37 Benjamin Dreux wrote:
>>>> Maybe my question was bad formulated.
>>>> I have a form, wich i want to fill with an object (wich i get from a
>>>> json store).
>>>> The form have a name for each field, and the json object have different
>>>> name. How can i match thoose.
>>>>
>>>> I've seen the method setDelegate from controller.list. it will be fine
>>>> to me. But i cant find a way.
>>>>
>>>> Any help will be welcome
>>>>
>>>> 2011/3/10 Benjamin Dreux <[email protected]>:
>>>> > Hi
>>>> > There is a way to match source property to target property with tree
>>>> > cotnroller and list controller why there isn't one such thing in the
>>>> > form controller?
>>>> > If i want to do the same kind of thing with a form controller what am
>>>> > i supposed to do?
>>>> >
>>>> > Thanks for any answer
>>>
>>> ------------------------------------------------------------------------------
>>> Colocation vs. Managed Hosting
>>> A question and answer guide to determining the best fit
>>> for your organization - today and in the future.
>>> http://p.sf.net/sfu/internap-sfd2d
>>> _______________________________________________
>>> qooxdoo-devel mailing list
>>> [email protected]
>>> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>>>
>>
>>
>>
>> --
>> Benjamin Dreux
>> Analyste-Programmeur
>> Chaire de logiciel libre-Finance Social et solidaire
>> UQAM
>> Montréal
>>
>
>
>
> --
> Benjamin Dreux
> Analyste-Programmeur
> Chaire de logiciel libre-Finance Social et solidaire
> UQAM
> Montréal
>



-- 
Benjamin Dreux
Analyste-Programmeur
Chaire de logiciel libre-Finance Social et solidaire
UQAM
Montréal

------------------------------------------------------------------------------
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to