ListFields Questions

3 views
Skip to first unread message

mefleisch

unread,
Oct 25, 2010, 7:04:23 AM10/25/10
to inputex
Hi,

1. I can´t get it to work in Forms

new inputEx.Form( {
fields: [
{type: 'select', label: 'Title', name: 'title',
choices: [{ value: 'Mr' }, { value: 'Mrs' }, { value: 'Ms' }] },
{label: 'Firstname', name: 'firstname', required: true,
value:'Jacques' },
{label: 'Lastname', name: 'lastname', value:'Dupont' },
{type:'email', label: 'Email', name: 'email'},
{type:'url', label: 'Website',name:'website'},
{type:'list',name:'testn',
label:'testl',listLabel:'testll',value: ["one", "two", "three",
"four"], sortable: true }
],
buttons: [{type: 'submit', value: 'Change'}],
parentEl: 'container1'
});

shows testl as a stringField with the combined values of listField.

2. What is listLabel for?

3. To use ListFields in standard HTML, I would have to use hidden
field an set that to the combined values of the listField onChange?

Thanks
Guido

mefleisch

unread,
Oct 29, 2010, 3:43:19 AM10/29/10
to inputex
Ok, 2. is because this.options.listLabel is not set
to options.listLabel.

mefleisch

unread,
Oct 29, 2010, 5:55:26 AM10/29/10
to inputex
Ok, 1. my mistake, I added
fields/ListField.js
before
Field.js

Eric Abouaf

unread,
Nov 1, 2010, 5:24:26 AM11/1/10
to inp...@googlegroups.com
3. To use ListFields in standard HTML, I would have to use hidden
field an set that to the combined values of the listField onChange?

Hi,

For "standard" HTML fields, the ListField should now work properly.
The issue was that the "name" attributes of fields were not properly set to represent the structure
of the list.

we now set it to "mylistname[0]", "mylistname[1]", etc...

It is now fixed on the "master" branch, and will be included in the next release.
(http://github.com/neyric/inputex/commit/ff18fee97eba7b1f70dcda10f89164d2c5d6f28d)

Cheers

--
You received this message because you are subscribed to the Google Groups "inputex" group.
To post to this group, send email to inp...@googlegroups.com.
To unsubscribe from this group, send email to inputex+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/inputex?hl=en.




--
Eric Abouaf
eric....@gmail.com
Tél: 06 29 86 37 89
Reply all
Reply to author
Forward
0 new messages