Is there a way to highlight the selected row after clicking on a link in a
DataTable cell? 


  public final class ColumnList extends
      ArrayList<IColumn&lt;QuikViewEnv>>
  {
    public ColumnList()
    {
      add(new AbstractColumn<QuikViewEnv>(new Model<String>("Environment"),
"name"){
            public void populateItem(final
Item<ICellPopulator&lt;QuikViewEnv>> cellItem, String componentId,
                final IModel<QuikViewEnv> model)
            {
              Fragment nameCellFrag = new
Fragment(componentId,"envTableCell", QuikViewEnvPage.this);
              AjaxLink<QuikViewEnv> link = new
AjaxLink<QuikViewEnv>("envLink",model){
                @Override
                public void onClick(AjaxRequestTarget target)
                {
                  quikViewEnv = model.getObject();
                  form.setModel(new
CompoundPropertyModel<QuikViewEnv>(quikViewEnv)); 
                  success(quikViewEnv.name + " selected.");
                  *//TODO - make the row for this cellItem look selected
with a css class*
                  target.add(form);
                  target.add(feedbackPanel);
                }                
              };
              nameCellFrag.add(link);
              link.add(new Label("envLabel", model.getObject().name));
              cellItem.add(nameCellFrag);
            }
        });
      add(new PropertyColumn<QuikViewEnv>(
          new Model<String>("OHS Host"), "ohsPort", "ohsHost"));


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/AjaxFallbackDefaultDataTable-selected-row-color-tp4419138p4419138.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to