Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- init:[
- '<div id="list"></div>'
- ],
- data:{
- data: [
- { idfield:'abc', desc: 'parent1', children: [ { id:'fgh', desc: 'child1' }, { id:'lmn', desc: 'child2' } ] },
- { idfield:'def', desc: 'parent2', children: [ { id:'xyz', desc: 'child1' } ] }
- ]
- },
- ui:{
- '#list':{
- bind:'data',
- list:'<div><div id="list2"></div></div>', // list item
- id:['idfield'], // field(s) to generate unique row id
- check:true, // should the list report errors to parent
- manifest:{
- // 1st level child manifest
- ui:{
- '#list2':{
- bind:'children',
- id:['id'], // field(s) to generate unique row id
- list:'<div></div>', // list item
- check:true,
- manifest:{
- //2nd level manifest
- }
- }
- }
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement