13 Replies Latest reply on Sep 28, 2007 6:40 AM by Maksim Kaszynski

    subTable, dataTabel and tooltip problems

    Miroslav Genov Newbie

      Hello guys, I have found some problems (in versiond 3.1.1-SNAPSHOT and 3.1.0 )

      1. subTable problem.
      When a subTable component is used ( 3.1.0 version ) all looks like a charm. After version is changed from 3.1.0 to 3.1.1-SNAPSHOT things looks different and the subtable borders aren't shown correctly.

      2. toolTip with datatable.
      When user enters the page for the first time and goes over a row which has a tooltip that looks like an empty box.

      3. There is a problem with rendering of any of components. This is the error message which firefox is displaying when I'm trying to open the page.

      XML Parsing Error: not well-formed
      Location: http://localhost:8080/agreement-web/pages/agreementsView.jsf
      Line Number 96, Column 123:<script type="text/javascript" language="Javascript">function dpf(f) {var adp = f.adp;if (adp != null) {for (var i = 0;i < adp.length;i++) {f.removeChild(adp);}}};function apf(f, pvp) {var adp = new Array();f.adp = adp;var ps = pvp.split(',');for (var i = 0,ii = 0;i < ps.length;i++,ii++) {var p = document.createElement("input");p.type = "hidden";p.name = ps;p.value = ps[i + 1];f.appendChild(p);adp[ii] = p;i += 1;}};function jsfcljs(f, pvp, t) {apf(f, pvp);var ft = f.target;if (t) {f.target = t;}f.submit();f.target = ft;dpf(f);};</script>
      



      And also the full page source
      <html xmlns="http://www.w3.org/1999/xhtml"
       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:t="http://myfaces.apache.org/tomahawk"
       xmlns:a4j="https://ajax4jsf.dev.java.net/ajax"
       xmlns:rich="http://richfaces.ajax4jsf.org/rich"
       xmlns:fn="http://java.sun.com/jsp/jstl/functions"
       xmlns:agr="http://agreements.com/agr">
      <ui:composition template="/templates/agreements.xhtml">
       <ui:define name="mainPage">
       <a4j:outputPanel id="errorsPanel">
       <h:messages />
       </a4j:outputPanel>
       <h1>????????</h1>
       <br />
       <h:form id="agreementsForm">
       <table width="100%">
       <tr>
       <td align="center"><a4j:outputPanel id="dataPanel">
       <table>
       <tr>
       <td align="center">?????</td>
       <td align="center">
       <h:selectOneMenu id="nameChangeButton" value="#{agreementView.nameState}">
       <f:selectItems value="#{agreementView.nameStates}" />
       <a4j:support event="onchange" reRender="dataPanel,agreementList,agreementScroller" action="#{agreementView.change}"/>
       </h:selectOneMenu>
       </td>
       <td align="center">?????</td>
      
       <td align="center">?.K. #</td>
       <td align="center">
       <h:selectOneMenu id="personalChangeButton" value="#{agreementView.personalState}">
       <f:selectItems value="#{agreementView.personalStates}" />
       <a4j:support event="onchange" reRender="dataPanel,agreementList,agreementScroller" action="#{agreementView.change}"/>
       </h:selectOneMenu>
       </td>
       <td align="center">???</td>
       <td align="center">??? #</td>
       <td align="center">
       <h:selectOneMenu id="ipMacChangeButton" value="#{agreementView.accountState}">
       <f:selectItems value="#{agreementView.accountStates}" />
       <a4j:support event="onchange" reRender="dataPanel,agreementList,agreementScroller" action="#{agreementView.change}" />
       </h:selectOneMenu></td>
       </tr>
       <tr>
       <td><h:inputText id="searchIngoingNumber"
       value="#{searchBean.ingoingNumber}" size="6">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText></td>
      
       <td>
       <h:inputText id="searchName" value="#{searchBean.name}" rendered="#{agreementView.nameState == 'FIRSTNAME'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText>
       <h:inputText id="searchCompanyName" value="#{searchBean.companyName}" rendered="#{agreementView.nameState == 'COMPANY'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText>
       <h:inputText id="searchLastName" value="#{searchBean.lastName}" rendered="#{agreementView.nameState == 'LASTNAME'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText>
       </td>
      
       <td><h:inputText id="searchStreet"
       value="#{searchBean.street}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText></td>
      
       <td><h:inputText id="searchCardNumber"
       value="#{searchBean.cardNumber}" size="6">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText></td>
      
       <td>
       <h:inputText id="searchEmail"
       value="#{searchBean.email}" size="6" rendered="#{agreementView.personalState == 'EMAIL'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText>
      
       <h:inputText id="searchMobile"
       value="#{searchBean.mobile}" size="6" rendered="#{agreementView.personalState == 'GSM'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText>
      
       <h:inputText id="searchTelephone"
       value="#{searchBean.telephone}" size="6" rendered="#{agreementView.personalState == 'TELEPHONE'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText>
      
       </td>
      
       <td><h:inputText id="searchVatId"
       value="#{searchBean.vatId}" size="8">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText></td>
      
       <td><h:inputText id="searchTaxId"
       value="#{searchBean.taxId}" size="8">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="250" />
       </h:inputText></td>
      
       <td>
       <h:inputText id="searchIp" value="#{searchBean.ip}"
       size="13" rendered="#{agreementView.accountState == 'IP'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="2500" />
       </h:inputText>
      
       <h:inputText id="searchMAC" value="#{searchBean.mac}"
       size="13" rendered="#{agreementView.accountState == 'MAC'}">
       <a4j:support event="onkeyup"
       reRender="agreementList,agreementScroller"
       action="#{agreementView.search}" requestDelay="2500" />
       </h:inputText>
      
       </td>
       </tr>
       </table>
       </a4j:outputPanel></td>
       </tr>
       <tr>
       <td colspan="5" align="center"><t:buffer into="#{table}">
       <a4j:region id="agreementViewRegion">
       <rich:dataTable width="80%" id="agreementList" rows="5"
       value="#{agreementView.allAgreements}" var="agr">
       <f:facet name="header">
       <rich:columnGroup>
       <rich:column styleClass="headerText" colspan="8">
       <h:outputText value="????????" />
       </rich:column>
       <rich:column breakBefore="true">
       <h:outputText styleClass="headerText" value="?????" />
       </rich:column>
       <rich:column>
       <h:outputText styleClass="headerText" value="???" />
       </rich:column>
       <rich:column>
       <h:outputText styleClass="headerText" value="???/?.?????" />
       </rich:column>
       <rich:column colspan="5">
       <h:outputText styleClass="headerText" value="???????" />
       </rich:column>
       </rich:columnGroup>
       </f:facet>
       <rich:column>
       <h:outputText value="#{agr.ingoingNumber}" />
       </rich:column>
       <rich:column>
       <h:outputText rendered="#{agr.client.clientType == 0}"
       value="#{agr.client.firstname} #{agr.client.family}" />
       <h:outputText rendered="#{agr.client.clientType == 1}"
       value="#{agr.client.firmtype.firmtype} #{agr.client.firmName}" />
       </rich:column>
       <rich:column>
       <h:outputText rendered="#{agr.client.clientType == 0}"
       value="#{agr.client.egn}" />
       <h:outputText rendered="#{agr.client.clientType == 1}"
       value="#{agr.client.taxid}" />
       </rich:column>
       <rich:column colspan="6" align="right">
       <h:commandLink style="defaultLinkStyle"
       action="#{agreementView.viewAppendixes}" rendered="#{agr:isActionAllowed('viewAppendixes')}">
       <h:graphicImage value="/images/document.png" alt="???????????" />
       </h:commandLink>
      
       <h:commandLink style="defaultLinkStyle"
       action="#{agreementView.editAgreement}" rendered="#{agr:isActionAllowed('editAgreement')}">
       <h:graphicImage value="/images/edit.gif" alt="???????????" />
       </h:commandLink>
       <h:commandLink style="defaultLinkStyle"
       action="#{agreementView.printAgreement}" rendered="#{agr:isActionAllowed('printAgreement')}">
       <h:graphicImage value="/images/print.gif" alt="?????" />
       </h:commandLink>
       </rich:column>
       <rich:subTable var="adr" value="#{agr.client.addressesAsList}">
       <rich:column>
       <f:facet name="header">
       <rich:spacer />
       </f:facet>
       </rich:column>
       <rich:column>
       <h:outputText value="#{adr.account.username}"></h:outputText>
       <f:facet name="header">
       <h:outputText value="User" />
       </f:facet>
       </rich:column>
       <rich:column>
       <h:outputText value="#{adr.telephone}"></h:outputText>
       <f:facet name="header">
       <h:outputText value="???????" />
       </f:facet>
       </rich:column>
       <rich:column>
       <h:outputText value="#{adr.mobile}"></h:outputText>
       <f:facet name="header">
       <h:outputText value="???????" />
       </f:facet>
       </rich:column>
       <rich:column>
       <h:outputText
       value="#{adr.street.streetname} ##{adr.streetnumber} #{adr.floor != '' ? '??:':''} #{adr.floor} #{adr.entrance != '' ? '??:':''} #{adr.entrance} #{adr.appartmentnumber != '' ? '??:':''} #{adr.appartmentnumber}"></h:outputText>
       <f:facet name="header">
       <h:outputText value="?????" />
       </f:facet>
       </rich:column>
       <rich:column>
       <h:outputText value="#{adr.account.ip}"></h:outputText>
       <f:facet name="header">
       <h:outputText value="IP" />
       </f:facet>
       </rich:column>
       <rich:column>
       <h:outputText value="#{adr.account.mac}"></h:outputText>
       <f:facet name="header">
       <h:outputText value="Mac" />
       </f:facet>
       </rich:column>
       <rich:column>
       <h:outputText value="#{adr.contactname}"></h:outputText>
       <f:facet name="header">
       <h:outputText value="???? ?? ???????" />
       </f:facet>
       </rich:column>
       </rich:subTable>
       </rich:dataTable>
       </a4j:region>
       </t:buffer> <rich:datascroller id="agreementScroller" for="agreementList"
       maxPages="20" scrollerListener="#{agreementView.listen}"
       stepControls="false" fastControls="hide" /> <h:outputText
       value="#{table}" escape="false" /></td>
       </tr>
       </table>
       </h:form>
       <rich:modalPanel id="addScreen" minHeight="200" minWidth="250"
       height="200" width="250" zindex="2000">
       <f:facet name="header">
       <h:outputText value="???????? ?? ??????????" />
       </f:facet>
       <f:facet name="controls">
       <h:graphicImage value="/images/minus.gif" style="cursor:pointer"
       onclick="Richfaces.hideModalPanel('mp')" />
       </f:facet>
       <h:form id="streetAddingForm">
       <a4j:outputPanel id="streetPanel">
       </a4j:outputPanel>
       </h:form>
       </rich:modalPanel>
       </ui:define>
      </ui:composition>
      </html>
      
      



      The screen shots of bugs #1 and #2 are at http://matrix.evo.bg/~matrix/screenshot/



        • 1. Re: subTable, dataTabel and tooltip problems
          Maksim Kaszynski Apprentice

          Miroslav,
          Items 2 and 3 - do they appear in 3.1.1 only, or in 3.10 as well?

          • 3. Re: subTable, dataTabel and tooltip problems
            Miroslav Genov Newbie

            Huh I forgot to say that after clicking of refresh ( F5 button click ) tool tip is working fine. Maybe the problem with tooltip occurs in the initialization.

            • 4. Re: subTable, dataTabel and tooltip problems
              Miroslav Genov Newbie

               

              "maksimkaszynski" wrote:
              Miroslav,
              Items 2 and 3 - do they appear in 3.1.1 only, or in 3.10 as well?


              On both of them 3.1.1 and on 3.1.0.


              PP: Can I edit any of my previous posts ?

              • 5. Re: subTable, dataTabel and tooltip problems
                Sergey Smirnov Master

                 

                "mgenov@gmail.com" wrote:

                PP: Can I edit any of my previous posts ?


                No. Jboss forum does not allow this. So, you Preview before posting. This is only one way to make post looks nice.

                • 6. Re: subTable, dataTabel and tooltip problems
                  Ilya Shaikovsky Master

                  what filter are you use?

                  If Fast - please use HTML Tidy validator for FF to check your markup. Wrong html code after ajax requests under fast filter - will completelly broke layout. For example - you miss tbody element in your table.

                  • 7. Re: subTable, dataTabel and tooltip problems
                    Ilya Shaikovsky Master

                    previous comment was to 3) point

                    1) Look to demosite.. I'm not able to see problems with subtable there. I still think - its about markup.


                    2) - Will be explored.

                    • 8. Re: subTable, dataTabel and tooltip problems
                      Miroslav Genov Newbie

                       

                      "ilya_shaikovsky" wrote:
                      what filter are you use?

                      If Fast - please use HTML Tidy validator for FF to check your markup. Wrong html code after ajax requests under fast filter - will completelly broke layout. For example - you miss tbody element in your table.


                      No. I do not use Fast Filter.

                      I've tried HTML Tidy Validator and It shows me several warnings and this is one of them:

                      line 47 column 25 - Warning: missing </span> before <table>
                      

                      And this is the code which plugin has selected.

                      <span id="agreementsForm:dataPanel">
                       <table>
                       <tr>
                       <td align="center">?????</td>
                       <td align="center">
                       <select id="agreementsForm:nameChangeButton" name="agreementsForm:nameChangeButton" size="1" onchange="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id23':'agreementsForm:j_id23'} ,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )">
                       <option value="org.mgenov.agreements.web.state.NameState::COMPANY" selected="selected">??? ?? ???????</option>
                       <option value="org.mgenov.agreements.web.state.NameState::FIRSTNAME">???</option>
                       <option value="org.mgenov.agreements.web.state.NameState::LASTNAME">???????</option>
                       </select>
                       </td>
                       <td align="center">?????</td>
                       <td align="center">?.K. #</td>
                       <td align="center"><select id="agreementsForm:personalChangeButton" name="agreementsForm:personalChangeButton" size="1" onchange="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id26':'agreementsForm:j_id26'} ,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )"> <option value="org.mgenov.agreements.web.state.PersonalState::EMAIL">E-mail</option>
                       <option value="org.mgenov.agreements.web.state.PersonalState::GSM" selected="selected">???????</option>
                       <option value="org.mgenov.agreements.web.state.PersonalState::TELEPHONE">???????</option>
                       </select>
                       </td>
                       <td align="center">???</td>
                       <td align="center">??? #</td>
                       <td align="center">
                       <select id="agreementsForm:ipMacChangeButton" name="agreementsForm:ipMacChangeButton" size="1" onchange="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id29':'agreementsForm:j_id29'} ,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )"> <option value="org.mgenov.agreements.web.state.AccountState::MAC">MAC</option>
                       <option value="org.mgenov.agreements.web.state.AccountState::IP" selected="selected">IP</option>
                       </select>
                       </td>
                       </tr>
                       <tr>
                       <td><input id="agreementsForm:searchIngoingNumber" type="text" name="agreementsForm:searchIngoingNumber" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id31':'agreementsForm:j_id31'} ,'eventsQueue':'agreementsForm:j_id31','requestDelay':250,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" size="6" /></td>
                       <td><input id="agreementsForm:searchCompanyName" type="text" name="agreementsForm:searchCompanyName" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id34':'agreementsForm:j_id34'} ,'eventsQueue':'agreementsForm:j_id34','requestDelay':250,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" />
                       </td>
                       <td><input id="agreementsForm:searchStreet" type="text" name="agreementsForm:searchStreet" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id37':'agreementsForm:j_id37'} ,'eventsQueue':'agreementsForm:j_id37','requestDelay':250,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" /></td>
                       <td><input id="agreementsForm:searchCardNumber" type="text" name="agreementsForm:searchCardNumber" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id39':'agreementsForm:j_id39'} ,'eventsQueue':'agreementsForm:j_id39','requestDelay':250,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" size="6" /></td>
                      
                       <td><input id="agreementsForm:searchMobile" type="text" name="agreementsForm:searchMobile" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id42':'agreementsForm:j_id42'} ,'eventsQueue':'agreementsForm:j_id42','requestDelay':250,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" size="6" />
                      
                       </td>
                      
                       <td><input id="agreementsForm:searchVatId" type="text" name="agreementsForm:searchVatId" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id45':'agreementsForm:j_id45'} ,'eventsQueue':'agreementsForm:j_id45','requestDelay':250,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" size="8" /></td>
                      
                       <td><input id="agreementsForm:searchTaxId" type="text" name="agreementsForm:searchTaxId" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id47':'agreementsForm:j_id47'} ,'eventsQueue':'agreementsForm:j_id47','requestDelay':250,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" size="8" /></td>
                      
                       <td><input id="agreementsForm:searchIp" type="text" name="agreementsForm:searchIp" onkeyup="A4J.AJAX.Submit('_viewRoot','agreementsForm',event,{'parameters':{'agreementsForm:j_id49':'agreementsForm:j_id49'} ,'eventsQueue':'agreementsForm:j_id49','requestDelay':2500,'actionUrl':'/agreement-web/pages/agreementsView.jsf'} )" size="13" />
                      
                       </td>
                      </tr>
                      </table></span>
                      



                      PP: If you want I can give you page's url address.

                      • 9. Re: subTable, dataTabel and tooltip problems
                        Miroslav Genov Newbie

                         

                        "ilya_shaikovsky" wrote:
                        previous comment was to 3) point

                        1) Look to demosite.. I'm not able to see problems with subtable there. I still think - its about markup.


                        2) - Will be explored.



                        Which version of richfaces is on demosite ?

                        With 3.1.0 all works fine but when I switch to 3.1.1 things are going to be different.


                        • 10. Re: subTable, dataTabel and tooltip problems
                          Maksim Kaszynski Apprentice

                          We seemed to fix a lot of bugs in 3.1.1. It look like here's some weird regression )))

                          • 11. Re: subTable, dataTabel and tooltip problems
                            Miroslav Genov Newbie

                            Hi again guys,

                            1. At this moment I've fixed the bug that causes errors on firefox. The problem was with <t:buffer component.
                            2. Now I'm using the version 3.1.1 and the problems with subtable only occurs on IE and only when table cell is empty.

                            On firefox everything is looking fine.

                            • 12. Re: subTable, dataTabel and tooltip problems
                              Miroslav Genov Newbie

                              Hi again :)

                              For the problem with empty cells I've made a research about this problem on IE 6. On most pages people gives for solution adding of empty char thats why I've added an <f:verbatim>&amp;nbsp;</f:verbatim> on
                              each cell and everything is looking fine.



                              • 13. Re: subTable, dataTabel and tooltip problems
                                Maksim Kaszynski Apprentice

                                Miroslav, thank you for your research!