2012-12-21 116 views
1

我使用豐富的面孔。JSF豐富:選項卡switchType = ajax更新第一個選項卡

<rich:tabPanel id="feedModifyDetails" switchType="client"> 
    <rich:tab id="ftpDefaultValuePanel" header="FtpDefaults"> 
      some code 
    </rich:tab> 

    <rich:tab id="feedSchedule" header="FeedSchedules" >  
      some code 
    </rich:tab> 

    <rich:tab id="feedFTPCommunicationParams" header="FeedFTPCommunicationParams">              
      some code 
    </rich:tab> 

    <rich:tab id="feedFTPErrorEscalations" header="FeedFTPErrorEscalations" 
      switchType="ajax"> 
      <ui:include src="ftpErrorEscalations.xhtml" /> 
    </rich:tab>  

    <rich:tab id="ftpErrorAction" header="FtpErrorActionDefaults" switchType="ajax"> 
      <ui:include src="ftpErrorAction.xhtml" /> 
    </rich:tab>  
</rich:tabPanel> 

正如展現在上面的代碼

  1. 豐富:一個tabpanel我使用switchType = 「客戶」。
  2. for last 2 rich:tab我已經使用switchType =「ajax」。

預期結果:

  1. 最後兩位標籤將被裝上標籤時用戶點擊。

錯誤: 當(AJAX請求選項卡)一個Ajax請求被髮送,但即響應將更新第一標籤 最後一個選項卡中的任何一個用戶點擊:<rich:tab id="ftpDefaultValuePanel" header="FtpDefaults" >

難道我所做的財產以後錯了嗎?

+1

你可以試試'immediate = true'爲ajax請求選項卡並查看結果嗎? –

+0

謝謝他們的工作......你能告訴我背後的原因嗎? – Vipul

回答

1

通過將immediate=true對AJAX請求的選項卡可以指示該部件的值必須被轉換並立即生效(即,在應用請求值相 ),而不是等待直到一個處理驗證階段。

+0

immediate =「true」應該添加到tabPanel或每個選項卡 – Taimur

相關問題