2 Replies Latest reply on Jan 30, 2009 8:15 AM by Onur Kocer

    Can not select selectOneRadio

    Onur Kocer Newbie

      Hi everyone

      in my screen i include modalpanel with ui:include like;

      <ui:include src="/module/musteri/popup/rgMusMusMusteriAramaPopup.xhtml">
       <ui:param name="parentHome" value="{musMusMusteriGoruntulemeHome}">
      <s:convertEntity />
       </ui:param>
       <ui:param name="panelId" value="rgMusMusMusteriAramaPopup" />
      </ui:include>
      

      And when user press a button modalpanel opens.
      In that popup i have a datatable.When user selects from selectOneRadio it does not stay selected.

      I have solved that problem with using a:include and set ajaxrendered=false instead of ui:include
      but in some pages i can not use a:include i must i use ui:include because i can use ui:param inside ui:include

      i use richfaces 3.2.2

        • 1. Re: Can not select selectOneRadio
          Ilya Shaikovsky Master

          Please show the included page also.

          • 2. Re: Can not select selectOneRadio
            Onur Kocer Newbie

             

            <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
             "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
            <ui:composition xmlns="http://www.w3.org/1999/xhtml"
             xmlns:s="http://jboss.com/products/seam/taglib"
             xmlns:ui="http://java.sun.com/jsf/facelets"
             xmlns:f="http://java.sun.com/jsf/core"
             xmlns:h="http://java.sun.com/jsf/html"
             xmlns:r="http://richfaces.ajax4jsf.org/rich"
             xmlns:a="https://ajax4jsf.dev.java.net/ajax">
            
             <r:modalPanel moveable="true" resizeable="false" id="#{panelId}"
             width="750" height="500" zindex="100" >
             <f:facet name="header">
             <h:outputLabel value="#{messages['musteri.musteriArama.popup.etiket.baslik']}" />
             </f:facet>
             <f:facet name="controls">
             <h:graphicImage alt="#{messages['form.ikon.kapat']}"
             title="#{messages['form.ikon.kapat']}" url="/img/form_close.png"
             styleClass="cursor"
             onclick="javascript:Richfaces.hideModalPanel('#{panelId}')" />
             </f:facet>
            
            
             <a:include
             viewId="/module/musteri/region/rgMusMusMusteriArama.xhtml" />
            
            
            
            
             </r:modalPanel>
            
            </ui:composition>
            
            


            <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
             "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
            <ui:composition xmlns="http://www.w3.org/1999/xhtml"
             xmlns:s="http://jboss.com/products/seam/taglib"
             xmlns:ui="http://java.sun.com/jsf/facelets"
             xmlns:f="http://java.sun.com/jsf/core"
             xmlns:h="http://java.sun.com/jsf/html"
             xmlns:as="http://anadolusigorta.com.tr/jsf/comps"
             xmlns:r="http://richfaces.org/rich" xmlns:a="http://richfaces.org/a4j">
            
             <h:form>
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.musteriTipi']}" />
             </ui:define>
             <h:selectOneMenu styleClass="medium"
             value="#{rgMusMusMusteriAramaHome.musteriTipi}">
             <s:convertEnum />
             <s:selectItems value="#{entityEnumAction.getMusteriTipi()}"
             var="item"
             label="#{messages[as:concat('genel.musteriTipi.', item)]}"
             noSelectionLabel="#{messages['genel.mesaj.kayit.Seciniz']}" />
             <a:support ajaxSingle="true" event="onchange"
             action="#{rgMusMusMusteriAramaHome.musteriTipiSecildi}"
             reRender="gercek,tuzel,uyari" />
             </h:selectOneMenu>
             <s:div id="uyari" styleClass="alignRight">
             <h:outputText
             rendered="#{rgMusMusMusteriAramaHome.musteriTipi eq 'GERCEK'}"
             value="#{messages['musteri.musteriArama.etiket.TCKimlikNo']}" />
             <h:outputText
             rendered="#{rgMusMusMusteriAramaHome.musteriTipi eq 'TUZEL'}"
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.VergiNoUyari']}" />
             </s:div>
             </s:decorate>
            
            
             <s:div id="gercek">
             <s:div rendered="#{rgMusMusMusteriAramaHome.musteriTipi eq 'GERCEK'}">
            
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.TCKimlikNo']}" />
             </ui:define>
             <h:inputText styleClass="medium" id="TCKimlikNo" maxlength="11"
             value="#{rgMusMusMusteriAramaHome.tcKimlikNo}"
             onkeydown="return onlyInteger(event)" />
             </s:decorate>
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.PasaportNo']}" />
             </ui:define>
             <h:inputText styleClass="medium" id="PasNo" maxlength="20"
             onkeyup="javascript:this.value=this.value.toUpperCase();"
             value="#{rgMusMusMusteriAramaHome.pasaportNo}" />
             </s:decorate>
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.Adi']}" />
             </ui:define>
             <h:inputText styleClass="large" id="adUnvan" maxlength="50"
             onkeyup="javascript:this.value=this.value.toUpperCase();"
             value="#{rgMusMusMusteriAramaHome.adUnvan}" />
             </s:decorate>
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.Soyadi']}" />
             </ui:define>
             <h:inputText styleClass="large" id="musteriSoyadi" maxlength="30"
             onkeyup="javascript:this.value=this.value.toUpperCase();"
             value="#{rgMusMusMusteriAramaHome.musteriSoyadi}" />
             </s:decorate>
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.kktcKimlikNo']}" />
             </ui:define>
             <h:inputText styleClass="medium" maxlength="6"
             value="#{rgMusMusMusteriAramaHome.kktcKimlikNo}" />
             </s:decorate>
             <s:div styleClass="alignRight">
             <s:decorate>
             <h:selectBooleanCheckbox id="daskMusteri"
             value="#{rgMusMusMusteriAramaHome.daskMusteriSecimi}">
             </h:selectBooleanCheckbox>
            
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.DaskMusteri']}" />
            
            
             <a:commandButton styleClass="ortaButton"
             action="#{rgMusMusMusteriAramaHome.geriDonGercek()}"
             value="#{messages['form.button.temizle']}"
             reRender="adUnvan,musteriSoyadi,PasNo,TCKimlikNo" />
             <a:commandButton styleClass="ortaButton"
             value="#{messages['form.button.sorgula']}" ajaxSingle="true"
             action="#{rgMusMusMusteriAramaHome.sorgulama()}"
             process="TCKimlikNo,PasNo,daskMusteri"
             reRender="errorPopup_rgMusMusMusteriArama,gercekTable" />
             </s:decorate>
             </s:div>
             </s:div>
             <a:region>
             <s:div id="gercekTable">
             <s:div rendered="#{rgMusMusMusteriAramaHome.tabloDoludur()} ">
            
             <r:dataTable
             value="#{rgMusMusMusteriAramaHome.musteriAramaTablosuModelList}"
             var="entity" rowKeyVar="rkv" width="100%" rows="5">
            
             <f:facet name="header">
             <r:columnGroup>
             <r:column>
             <h:outputText value="#{messages['genel.mesaj.kayit.Seciniz']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.musteriNo']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.adisoyadi']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.il']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.ilce']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.table.detay']}" />
             </r:column>
             </r:columnGroup>
             </f:facet>
            
             <r:column>
             <h:selectOneRadio>
             <a:support event="onclick" ajaxSingle="true"
             onsubmit="dataTableSelectOneRadio(this);"
             action="#{rgMusMusMusteriAramaHome.selectMusteriAramaTablosu(rkv)}" />
             <f:selectItem itemValue="rkv" />
             </h:selectOneRadio>
             </r:column>
             <r:column>
             <h:outputText value="#{entity.MUSTERI_NO}" />
             </r:column>
             <r:column>
             <h:outputText value="#{entity.UNVAN}" />
             </r:column>
             <r:column>
             <h:outputText value="#{entity.MUSTERI_IL}" />
             </r:column>
             <r:column>
             <h:outputText value="#{entity.MUSTERI_ILCE}" />
             </r:column>
             <r:column>
             <s:div styleClass="alignCenter">
             <a:commandButton
             action="#{rgMusMusMusteriAramaHome.devamDetay(rkv)}"
             ajaxSingle="true"
             styleClass="kucukButton" value="#{entity.DETAY}"
             oncomplete="javascript:Richfaces.showModalPanel('#{rgMusMusMusteriAramaHome.regionName}')" />
             </s:div>
             </r:column>
             <f:facet name="footer">
             <r:datascroller ajaxSingle="true"
             rendered="#{rgMusMusMusteriAramaHome.musteriAramaTablosuModelList.size > 5}" />
             </f:facet>
             </r:dataTable>
             </s:div>
             </s:div>
             </a:region>
             </s:div>
            
            
            
             <s:div id="tuzel">
             <s:div rendered="#{rgMusMusMusteriAramaHome.musteriTipi eq 'TUZEL'}">
            
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.vergiKimlikNo']}"
             onkeydown="return onlyInteger(event)" />
             </ui:define>
             <h:inputText styleClass="medium" id="vergiKimlikNo"
             onkeydown="return onlyInteger(event)" maxlength="10"
             value="#{rgMusMusMusteriAramaHome.vergiKimlikNo}" />
             </s:decorate>
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.unvani']}" />
             </ui:define>
             <h:inputText styleClass="large" id="unvan" maxlength="50"
             onkeyup="javascript:this.value=this.value.toUpperCase();"
             value="#{rgMusMusMusteriAramaHome.unvan}" />
             </s:decorate>
             <s:decorate template="/layout/editNew.xhtml">
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.kktcKimlikNo']}" />
             </ui:define>
             <h:inputText styleClass="medium" maxlength="6"
             value="#{rgMusMusMusteriAramaHome.kktcKimlikNo}" />
             </s:decorate>
             <s:div styleClass="alignRight">
             <s:decorate template="/layout/editNew.xhtml">
             <h:selectBooleanCheckbox id="daskMusteriTuzel"
             value="#{rgMusMusMusteriAramaHome.daskMusteriSecimi}">
             </h:selectBooleanCheckbox>
             <ui:define name="label">
             <h:outputText
             value="#{messages['musteri.rgMusMusMusteriArama.etiket.DaskMusteri']}" />
             </ui:define>
            
             <a:commandButton styleClass="ortaButton"
             action="#{rgMusMusMusteriAramaHome.geriDonTuzel()}"
             value="#{messages['form.button.temizle']}"
             reRender="vergiKimlikNo,unvan" />
             <a:commandButton styleClass="ortaButton"
             value="#{messages['form.button.sorgula']}" ajaxSingle="true"
             action="#{rgMusMusMusteriAramaHome.sorgulama()}"
             process="vergiKimlikNo,unvan,daskMusteriTuzel"
             reRender="errorPopup_rgMusMusMusteriArama,tuzelTable" />
             </s:decorate>
             </s:div>
             </s:div>
             <s:div id="tuzelTable">
             <s:div rendered="#{rgMusMusMusteriAramaHome.tabloDoludurTuzel()}">
             <r:dataTable
             value="#{rgMusMusMusteriAramaHome.musteriAramaTablosuModelList}"
             var="entity" rowKeyVar="rkv" width="100%" rows="5">
            
             <f:facet name="header">
             <r:columnGroup>
             <r:column>
             <h:outputText value="#{messages['genel.mesaj.kayit.Seciniz']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.musteriNo']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.adisoyadi']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.il']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.etiket.ilce']}" />
             </r:column>
             <r:column>
             <h:outputText value="#{messages['musteri.table.detay']}" />
             </r:column>
             </r:columnGroup>
             </f:facet>
            
             <r:column>
             <h:selectOneRadio>
             <a:support event="onclick" ajaxSingle="true"
             action="#{rgMusMusMusteriAramaHome.selectMusteriAramaTablosu(rkv)}"
             onsubmit="dataTableSelectOneRadio(this);" />
             <f:selectItem itemValue="rkv" />
             </h:selectOneRadio>
             </r:column>
             <r:column>
             <h:outputText value="#{entity.MUSTERI_NO}" />
             </r:column>
             <r:column>
             <h:outputText value="#{entity.UNVAN}" />
             </r:column>
             <r:column>
             <h:outputText value="#{entity.MUSTERI_IL}" />
             </r:column>
             <r:column>
             <h:outputText value="#{entity.MUSTERI_ILCE}" />
             </r:column>
             <r:column>
             <s:div styleClass="alignCenter">
             <a:commandButton
             action="#{rgMusMusMusteriAramaHome.devamDetay(rkv)}"
             value="#{entity.DETAY}" styleClass="kucukButton"
             oncomplete="javascript:Richfaces.showModalPanel('#{rgMusMusMusteriAramaHome.regionName}')" />
             </s:div>
             </r:column>
             <f:facet name="footer">
             <r:datascroller ajaxSingle="true"
             rendered="#{rgMusMusMusteriAramaHome.musteriAramaTablosuModelList.size} > 5}" />
             </f:facet>
             </r:dataTable>
             </s:div>
             </s:div>
             </s:div>
             <r:spacer height="30">
             </r:spacer>
             <s:div styleClass="alignRight">
             <a:commandButton ajaxSingle="true"
             value="#{messages['form.button.geriDon']}"
             action="#{rgMusMusMusteriAramaHome.clear()}"
             oncomplete="javascript:Richfaces.hideModalPanel('rgMusMusMusteriAramaPopup')"
             styleClass="ortaButton" />
             <a:commandButton styleClass="ortaButton"
             oncomplete="javascript:if(#{parentHome.warningMessage.showState eq 'true'} )
             {Richfaces.showModalPanel('warningPopup_rgMusMusMusteriArama2');} else
             {Richfaces.hideModalPanel('rgMusMusMusteriAramaPopup');}" ajaxSingle="true"
             value="#{messages['form.button.devam']}"
             action="#{parentHome.devamPopup}" reRender="temizle,buttons" />
             </s:div>
             </h:form>
             <ui:include src="/layout/errorMessagePopup.xhtml">
             <ui:param name="parentHome" value="#{rgMusMusMusteriAramaHome}">
             <s:convertEntity />
             </ui:param>
             <ui:param name="panelId"
             value="errorPopup_rgMusMusMusteriArama" />
             </ui:include>
             <ui:include src="/layout/warningMessagePopup.xhtml">
             <ui:param name="parentHome" value="#{parentHome}">
             <s:convertEntity />
             </ui:param>
             <ui:param name="panelId"
             value="warningPopup_rgMusMusMusteriArama2" />
             </ui:include>
            
            </ui:composition>