myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lof...@apache.org
Subject svn commit: r1789506 - in /myfaces/tobago/branches/TOBAGO-1719: ./ tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/ tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/ tobago-example/tobago-example-de...
Date Thu, 30 Mar 2017 12:04:34 GMT
Author: lofwyr
Date: Thu Mar 30 12:04:34 2017
New Revision: 1789506

URL: http://svn.apache.org/viewvc?rev=1789506&view=rev
Log:
Merged from trunk
TOBAGO-1705: tc:sheet is empty after filtering results [from revision 1789379]
demo: fix header look [from revision 1789380]

Modified:
    myfaces/tobago/branches/TOBAGO-1719/   (props changed)
    myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java
    myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java
  (contents, props changed)
    myfaces/tobago/branches/TOBAGO-1719/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/50-filter/sheet-filter.xhtml

Propchange: myfaces/tobago/branches/TOBAGO-1719/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Mar 30 12:04:34 2017
@@ -1,4 +1,4 @@
 /myfaces/tobago/branches/tobago-1.5.x:1356585,1357124
 /myfaces/tobago/branches/tobago-3.0.x:1781306,1781310,1781380
 /myfaces/tobago/branches/tobago-tree-table:1226794-1341423
-/myfaces/tobago/trunk:1571193,1571804,1571816,1571941,1571945,1571962,1571966,1576730,1589960,1591854,1600239,1600818,1601860,1602151,1602154,1602343,1604224,1606201,1607642,1609696-1609697,1609718,1610942,1610948,1610970,1610989,1611011,1611259,1611264,1611276,1611329,1611338-1611339,1611571,1613015,1613032,1614827,1614853,1615053,1615114,1615121,1617310,1619789,1621101,1621107,1621134,1621156,1621264,1621282,1621332,1622222,1622243,1622508,1623934,1624033,1625968,1625972,1626270,1628899,1628953,1636842,1636911,1640117,1640147,1640541,1640548,1640638,1640761,1640917,1641575,1641635,1641772,1641775,1641777,1656502,1656507,1657180,1657269,1657276,1657279,1658343,1658909,1658912,1659026,1659031,1660696,1660699,1660708,1660714,1665486,1665521,1665549,1665569-1665570,1666464,1667304,1667306-1667307,1667309,1668147,1668153,1668249,1675330,1675565,1675584,1675588-1675589,1675636,1676030,1676035,1676038,1679031,1680197,1681981,1682187,1682448,1682545,1682548,1683231,1683306,1683373,1683664
 ,1686204,1687354,1693426,1696720,1698292,1698297,1700742,1700795,1701249,1701251,1701256,1701980,1709006,1725894,1726691,1726986,1727161,1731050-1731051,1731054,1731057,1731218-1731219,1787403,1787422,1787443,1787651,1787780,1787926,1788112,1788115,1788125,1788196,1788214-1788215,1788225,1788239,1788381,1788385,1788392,1788484,1788502,1789295,1789305,1789309,1789347-1789348,1789354,1789364,1789366
+/myfaces/tobago/trunk:1571193,1571804,1571816,1571941,1571945,1571962,1571966,1576730,1589960,1591854,1600239,1600818,1601860,1602151,1602154,1602343,1604224,1606201,1607642,1609696-1609697,1609718,1610942,1610948,1610970,1610989,1611011,1611259,1611264,1611276,1611329,1611338-1611339,1611571,1613015,1613032,1614827,1614853,1615053,1615114,1615121,1617310,1619789,1621101,1621107,1621134,1621156,1621264,1621282,1621332,1622222,1622243,1622508,1623934,1624033,1625968,1625972,1626270,1628899,1628953,1636842,1636911,1640117,1640147,1640541,1640548,1640638,1640761,1640917,1641575,1641635,1641772,1641775,1641777,1656502,1656507,1657180,1657269,1657276,1657279,1658343,1658909,1658912,1659026,1659031,1660696,1660699,1660708,1660714,1665486,1665521,1665549,1665569-1665570,1666464,1667304,1667306-1667307,1667309,1668147,1668153,1668249,1675330,1675565,1675584,1675588-1675589,1675636,1676030,1676035,1676038,1679031,1680197,1681981,1682187,1682448,1682545,1682548,1683231,1683306,1683373,1683664
 ,1686204,1687354,1693426,1696720,1698292,1698297,1700742,1700795,1701249,1701251,1701256,1701980,1709006,1725894,1726691,1726986,1727161,1731050-1731051,1731054,1731057,1731218-1731219,1787403,1787422,1787443,1787651,1787780,1787926,1788112,1788115,1788125,1788196,1788214-1788215,1788225,1788239,1788381,1788385,1788392,1788484,1788502,1789295,1789305,1789309,1789347-1789348,1789354,1789364,1789366,1789379-1789380

Modified: myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java?rev=1789506&r1=1789505&r2=1789506&view=diff
==============================================================================
--- myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java
(original)
+++ myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java
Thu Mar 30 12:04:34 2017
@@ -132,6 +132,15 @@ public abstract class AbstractUIData ext
     if (dataModel != null) {
       dataModel.reset();
     }
+
+    if (getFirst() >= getRowCount()) {
+      LOG.warn("Illegal paging state detected, first='{}' >= rowCount='{}'. Setting first
to 0. "
+          + "This might happen because the data model has changed. "
+          + "You may want to manipulate the sheet state in your application after manipulating
the model "
+          + "(e. g. filtering) to avoid this warning.", getFirst(), getRowCount());
+      setFirst(0);
+    }
+
     super.encodeBegin(context);
   }
 

Modified: myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java?rev=1789506&r1=1789505&r2=1789506&view=diff
==============================================================================
--- myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java
(original)
+++ myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java
Thu Mar 30 12:04:34 2017
@@ -538,11 +538,8 @@ public class SheetRenderer extends Rende
     boolean emptySheet = true;
     // rows = 0 means: show all
     final int last = sheet.isRowsUnlimited() ? Integer.MAX_VALUE : sheet.getFirst() + sheet.getRows();
-    final int first = sheet.getFirst();
-    final int rowCount = sheet.getRowCount();
-    final int firstRowIndexOfLastPage = sheet.getFirstRowIndexOfLastPage();
 
-    for (int rowIndex = first < rowCount ? first : firstRowIndexOfLastPage; rowIndex <
last; rowIndex++) {
+    for (int rowIndex = sheet.getFirst(); rowIndex < last; rowIndex++) {
       sheet.setRowIndex(rowIndex);
       if (!sheet.isRowAvailable()) {
         break;

Propchange: myfaces/tobago/branches/TOBAGO-1719/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Mar 30 12:04:34 2017
@@ -1,4 +1,4 @@
 /myfaces/tobago/branches/tobago-1.5.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java:1356585,1357124
 /myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java:1226794-1341423
-/myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java:1789354,1789364,1789366
+/myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/renderkit/renderer/SheetRenderer.java:1789354,1789364,1789366,1789379-1789380
 /myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java:1571193,1571804,1571816,1571941,1571945,1571962,1571966,1576730,1589960,1591854,1600239,1600818,1601860,1602151,1602154,1602343,1604224,1606201,1607642,1609696-1609697,1609718,1610942,1610948,1610970,1610989,1611011,1611259,1611264,1611276,1611329,1611338-1611339,1611571,1613015,1613032,1614827,1614853,1615053,1615114,1615121,1617310,1619789,1621101,1621107,1621134,1621156,1621264,1621282,1621332,1622222,1622243,1622508,1623934,1624033,1625968,1625972,1626270,1628899,1628953,1636842,1636911,1642608,1657269,1682545

Modified: myfaces/tobago/branches/TOBAGO-1719/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/50-filter/sheet-filter.xhtml
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/TOBAGO-1719/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/50-filter/sheet-filter.xhtml?rev=1789506&r1=1789505&r2=1789506&view=diff
==============================================================================
--- myfaces/tobago/branches/TOBAGO-1719/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/50-filter/sheet-filter.xhtml
(original)
+++ myfaces/tobago/branches/TOBAGO-1719/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/50-filter/sheet-filter.xhtml
Thu Mar 30 12:04:34 2017
@@ -63,7 +63,10 @@
               <f:ajax execute=":::sheet" render=":::sheet" listener="#{sheetFilterController.filter}"/>
             </tc:selectOneChoice>
           </tc:panel>
-          <tc:out value="Period"/>
+          <tc:panel>
+            <tc:out value="Period"/>
+            <tc:out value=""/>
+          </tc:panel>
           <tc:panel>
             <tc:out value="Discoverer"/>
             <tc:in value="#{sheetFilterController.discoverer}">



Mime
View raw message