PrimeFaces时间轴组件不适用于IE8

时间:2015-07-10 18:56:44

标签: javascript jsf primefaces internet-explorer-8 timeline

我在项目中使用时间轴组件(pe:timeline),它在Chrome上运行正常,但在IE8上运行不正常。

我坚持的问题是,在IE8上,组件根本不会被渲染。 我正在使用的代码:

使用Javascript:

function showContent() {  
    $('#textArea').val(PF('timelineWdgt').getSelectedEvent().content);  
} 

XHTML:

<h:body>
     <f:event id="postConstructorEvent"
        type="javax.faces.event.PreRenderComponentEvent"
        listener="#{acervoBean.inicializaPaginaAcervo}" />
     <p:growl id="growl" showSummary="true" showDetail="true" autoUpdate="true"/> 
     <h:form id="searchMultimidia">
        <h:panelGroup class="nav">
           <h:panelGrid columns="2" class="grid" style="width:90%">
        <pe:timeline id="timeline" locale="pt_BR" value="#{acervoBean.model}"  
                     editable="true" showButtonNew="false"
                     showNavigation="true" zoomMin="1500000000"
                     timeZone="#{acervoBean.timeZone}"  
                     widgetVar="timelineWdgt" style="margin-top:10px;">  
            <pe:javascript event="select" execute="showContent()"/>  
            <p:ajax event="delete" update="@none" onstart="timelineWdgt.cancelDelete()"/>
            <p:ajax event="add" update="@none" onstart="timelineWdgt.cancelAdd()"/>
        </pe:timeline>  
...
...

豆:

@PostConstruct
public void postContruct() {
    model = new TimelineModel();

    Calendar cal = Calendar.getInstance(TimeZone.getTimeZone("UTC"));
    cal.set(Calendar.HOUR_OF_DAY, 0);
    cal.set(Calendar.MINUTE, 0);
    model.add(new TimelineEvent("Dia inicial", cal.getTime()));

    cal.add(Calendar.WEEK_OF_MONTH, 1);
    model.add(new TimelineEvent("Dia final", cal.getTime()));
}
...
...

我正在使用 Mojarra 2.1.17, Primefaces 3.5和 Apache Tomcat 7.0.56

感谢。

0 个答案:

没有答案