Search in sources :

Example 41 with WDataTable

use of com.github.bordertech.wcomponents.WDataTable in project wcomponents by BorderTech.

the class WDataTableRenderer_Test method testDoPaintExpandModeServer.

// SERVER outputs "dynamic" see https://github.com/BorderTech/wcomponents/issues/701
@Test
public void testDoPaintExpandModeServer() throws IOException, SAXException, XpathException {
    WDataTable component = new WDataTable();
    component.addColumn(new WTableColumn(COL1_HEADING_TEST, WTextField.class));
    component.addColumn(new WTableColumn(COL2_HEADING_TEST, WTextField.class));
    component.addColumn(new WTableColumn(COL3_HEADING_TEST, WTextField.class));
    TableDataModel tableModel = createTableModel();
    component.setDataModel(tableModel);
    component.setVisible(true);
    component.setExpandMode(ExpandMode.SERVER);
    assertXpathEvaluatesTo("dynamic", "//ui:table/ui:rowexpansion/@mode", component);
}
Also used : WTableColumn(com.github.bordertech.wcomponents.WTableColumn) WDataTable(com.github.bordertech.wcomponents.WDataTable) SimpleTableDataModel(com.github.bordertech.wcomponents.SimpleTableDataModel) TableDataModel(com.github.bordertech.wcomponents.TableDataModel) WTextField(com.github.bordertech.wcomponents.WTextField) Test(org.junit.Test)

Aggregations

WDataTable (com.github.bordertech.wcomponents.WDataTable)41 WTableColumn (com.github.bordertech.wcomponents.WTableColumn)38 WTextField (com.github.bordertech.wcomponents.WTextField)29 Test (org.junit.Test)28 SimpleTableDataModel (com.github.bordertech.wcomponents.SimpleTableDataModel)23 TableDataModel (com.github.bordertech.wcomponents.TableDataModel)23 WText (com.github.bordertech.wcomponents.WText)8 TableTreeNode (com.github.bordertech.wcomponents.TableTreeNode)5 WButton (com.github.bordertech.wcomponents.WButton)5 ActionConstraint (com.github.bordertech.wcomponents.WDataTable.ActionConstraint)4 WDateField (com.github.bordertech.wcomponents.WDateField)4 XmlStringBuilder (com.github.bordertech.wcomponents.XmlStringBuilder)3 UIContext (com.github.bordertech.wcomponents.UIContext)2 TreeTableDataModel (com.github.bordertech.wcomponents.TreeTableDataModel)1 WComponent (com.github.bordertech.wcomponents.WComponent)1 WDataTableRowRenderer (com.github.bordertech.wcomponents.WDataTableRowRenderer)1 WRepeater (com.github.bordertech.wcomponents.WRepeater)1 SubUIContext (com.github.bordertech.wcomponents.WRepeater.SubUIContext)1 SystemException (com.github.bordertech.wcomponents.util.SystemException)1 TreeNode (com.github.bordertech.wcomponents.util.TreeNode)1