Package org.olat.core.gui.components.table

Examples of org.olat.core.gui.components.table.DefaultColumnDescriptor


    tgc.setPreferencesOffered(true, "TableGuiDemoPrefs");
    table = new TableController(tgc, ureq, getWindowControl(), getTranslator(), this);
    table.setMultiSelect(true);
    table.addMultiSelectAction("guidemo.table.submit", "submitAction");
    table.addMultiSelectAction("guidemo.table.submit2", "submitAction2");
    table.addColumnDescriptor(new DefaultColumnDescriptor("guidemo.table.header1", 0, null, ureq.getLocale()));
    table.addColumnDescriptor(new DefaultColumnDescriptor("guidemo.table.header2", 1, null, ureq.getLocale()));
    table.addColumnDescriptor(new DefaultColumnDescriptor("guidemo.table.header3", 2, null, ureq.getLocale()));
    table.addColumnDescriptor(new DefaultColumnDescriptor("guidemo.table.header4", 3, null, ureq.getLocale()));
    table.addColumnDescriptor(new DefaultColumnDescriptor("guidemo.table.header5", 4, null, ureq.getLocale()));
    table.addColumnDescriptor(new CustomRenderColumnDescriptor("guidemo.table.header6", 5, null, ureq.getLocale(), CustomRenderColumnDescriptor.ALIGNMENT_CENTER, new ImageCellRenderer()));
    table.addColumnDescriptor(new StaticColumnDescriptor("action.select", "guidemo.table.header7", "Select"));
    model = new SampleTableModel();
    table.setTableDataModel(model);
    vcMain.put("table", table.getInitialComponent());
View Full Code Here


  }
 
  @Override
  public ColumnDescriptor createColumnDescriptor(UserRequest ureq, int column, String headerId) {
    if (column==0) {
      return new DefaultColumnDescriptor("stat.table.header.node", 0, null, ureq.getLocale());
    }
   
    if (headerId!=null) {
      Translator translator = Util.createPackageTranslator(ShibbolethModule.class, ureq.getLocale());
      if (translator!=null) {
View Full Code Here

    tableConfig.setDownloadOffered(false);
    //disable the default sorting for this table
    tableConfig.setSortingEnabled(false);
    tableCtr = new TableController(tableConfig, ureq, getWindowControl(), trans, this);
    // dummy header key, won't be used since setDisplayTableHeader is set to false
    tableCtr.addColumnDescriptor(new DefaultColumnDescriptor("bookmarksPortlet.bgname", 0, CMD_LAUNCH, trans.getLocale()));
    tableCtr.addColumnDescriptor(new DefaultColumnDescriptor("bookmarksPortlet.type", 1, null, trans.getLocale(), ColumnDescriptor.ALIGNMENT_RIGHT));
   
    this.sortingCriteria = getPersistentSortingConfiguration(ureq);
    reloadModel(sortingCriteria);

    this.bookmarksVC.put("table", tableCtr.getInitialComponent());           
View Full Code Here

   
    nodeListCtr = new TableController(tableConfig, ureq, getWindowControl(), this.getTranslator(), this);
    // table columns   
    nodeListCtr.addColumnDescriptor(new CustomRenderColumnDescriptor("table.header.node", 0,
        null, ureq.getLocale(), ColumnDescriptor.ALIGNMENT_LEFT, new IndentedNodeRenderer()));
    nodeListCtr.addColumnDescriptor(new DefaultColumnDescriptor("table.action.select", 1,
        CMD_SELECT_NODE, ureq.getLocale()));
   
    // get list of course node data and populate table data model
    ICourse course = CourseFactory.loadCourse(ores);
    CourseNode rootNode = course.getRunStructure().getRootNode();
View Full Code Here

    TableGuiConfiguration tableConfig = new TableGuiConfiguration();
    tableConfig.setDownloadOffered(false);
    tableConfig.setTableEmptyMessage(translate("bookmarks.nobookmarks"));
    tableCtr = new TableController(tableConfig, ureq, getWindowControl(), getTranslator(), null);
    tableCtr.addColumnDescriptor(new DefaultColumnDescriptor("table.bm.title", 0, "choose", ureq.getLocale()));
    tableCtr.addColumnDescriptor(new DefaultColumnDescriptor("table.bm.resource", 1, null, ureq.getLocale()));
    tableCtr.addColumnDescriptor(new DefaultColumnDescriptor("table.bm.description", 2, null, ureq.getLocale()));
    listenTo(tableCtr);

    if (allowEdit) {
      tableCtr.addColumnDescriptor(new StaticColumnDescriptor("edit", "table.header.edit", myContent.getTranslator().translate(
          "action.edit")));
View Full Code Here

   * this data model
   *
   * @param subscriptionsTableCtr
   */
  void addTableColumns(TableController subscriptionsTableCtr) {
    subscriptionsTableCtr.addColumnDescriptor(new DefaultColumnDescriptor("overview.column.type", 0, "launch", getLocale()));
    subscriptionsTableCtr.addColumnDescriptor(new DefaultColumnDescriptor("overview.column.resname", 1, null, getLocale()));
    subscriptionsTableCtr.addColumnDescriptor(new DefaultColumnDescriptor("overview.column.subidentifier", 2, null, getLocale()));
    subscriptionsTableCtr.addColumnDescriptor(new StaticColumnDescriptor("del", "overview.column.action", trans
        .translate("overview.column.action.cellvalue")));
  }
View Full Code Here

TOP

Related Classes of org.olat.core.gui.components.table.DefaultColumnDescriptor

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.