Results 1 to 2 of 2

Thread: Problems with two dataviews

  1. #1

    Default Problems with two dataviews

    I have two dataviews:

    PHP Code:
        var dataviewON = new Ext.DataView({
                                    
    id:'dataviewON'
                                    
    tpltpl
                                    
    autoHeight:true
                                    
    multiSelecttrue
                                    
    overClass:'x-view-over'
                                    
    itemSelector:'div.thumb-wrap'
                                    
    emptyText'No images to display'
     
                                    
    plugins: [ 
                                        new 
    Ext.DataView.DragSelector(), 
                                        new 
    Ext.DataView.LabelEditor({dataIndex'name'}) 
                                    ], 
     
                                    
    prepareData: function(data){ 
                                        
    data.shortName Ext.util.Format.ellipsis(data.name15); 
                                        return 
    data
                                    }, 
                             
                                    
    listeners: { 
                                        
    selectionchange: { 
                                            
    fn: function(dv,nodes){ 
                                                var 
    nodes.length
                                                var 
    != 's' ''
                                                
    panel.setTitle('Encender/Apagar Equipos Aula ('+l+' alumno'+s+' seleccionado'+s+')'); 
                                            } 
                                        } 
                                    } 
                                });

        var 
    dataviewNet = new Ext.DataView({
                                    
    id:'dataviewNet'
                                    
    tpltpl
                                    
    autoHeight:true
                                    
    multiSelecttrue
                                    
    overClass:'x-view-over'
                                    
    itemSelector:'div.thumb-wrap'
                                    
    emptyText'No images to display'
     
                                    
    plugins: [ 
                                        new 
    Ext.DataView.DragSelector(), 
                                        new 
    Ext.DataView.LabelEditor({dataIndex'name'}) 
                                    ], 
     
                                    
    prepareData: function(data){ 
                                        
    data.shortName Ext.util.Format.ellipsis(data.name15); 
                                        return 
    data
                                    }, 
                             
                                    
    listeners: { 
                                        
    selectionchange: { 
                                            
    fn: function(dv,nodes){ 
                                                var 
    nodes.length
                                                var 
    != 's' ''
                                                
    panel2.setTitle('Habilitar/Deshabilitar Internet ('+l+' alumno'+s+' seleccionado'+s+')');
                                            } 
                                        } 
                                    } 
                                }); 
    when I insert this data:

    PHP Code:
        var myStore = new Ext.data.JsonStore({
            
    dataalumnos,
            
    root'images',
            
    fields: ['name','url','pcname']
        });

        
    dataviewON.setStore(myStore);
        
    dataviewNet.setStore(myStore); 
    I found this error:

    b is undefined
    DomHelper( )ext-all.js (lnea 7)
    DomHelper() ext-all.js (lnea 7)
    pintarDataView() conexion.js (lnea 142)
    pintarEquiposAula() conexion.js (lnea 125)
    success() conexion.js (lnea 77)
    DomHelper() ext-all.js (lnea 7)
    f() ext-base.js (lnea 7)
    apply() ext-base.js (lnea 7)

    Ext.DomHelper=function(){var t=null,k=...lclick",this.onNodeDblClick,this)}});

    Thanks.

  2. #2

    Default

    anyone can help me?

    The first setStore() works perfectly, and the second setStore works but with this error.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •