how to implement jsPanel with jsf

1

I'm trying to render an xhtml page inside jsPanel, but just get the jsPanel empty. this is the javascript:

function executeLoad(aUrl){

$.jsPanel({
    load:{
        url: aUrl
    },
    selector: "#content",
    title: "com url",    
    bootstrap: 'primary',


});

}

no xhtml I'll call you

<p:menuitem value="Lista Tipo Grupo" onclick="executeLoad('../sisger/TipoGrupo/sisgerTipoGru/List.xhtml')" />

returns me:

In the chrome object inspector only the original codogo appears without rendering.

    
asked by anonymous 08.12.2015 / 14:32

1 answer

1

Depends on which version you are using. In case the option "load" has been replaced by "contentAjax" that receives a json array of data, including the destination url. Here is an example jsPanel v3.0.0

function executeLoad(aUrl){

$.jsPanel({
    contentAjax: {
    url:      aUrl, // exemplo de url: '../media/files/exampleAjax.html'
    autoload: true
},
    headerTitle: 'Título da Janela',
    contentSize: {width: 470, height: 340},
    position:    {my: "center-top", at: "center-top"},
    theme:       'lightblue',
});

}
    
08.12.2016 / 17:10