// Load Purchase Detail
 private void loadPurDtl() {
   try {
     logger.info(
         "Company ID : " + companyid + " | User Name : " + username + " > " + "Loading Search...");
     recordCnt = listEnqDtls.size();
     beanPurEnqDtlDM = new BeanItemContainer<SmsPurEnqDtlDM>(SmsPurEnqDtlDM.class);
     beanPurEnqDtlDM.addAll(listEnqDtls);
     logger.info(
         "Company ID : "
             + companyid
             + " | User Name : "
             + username
             + " > "
             + "Got the dPurDt. result set");
     tblSmsEnqDtl.setContainerDataSource(beanPurEnqDtlDM);
     tblSmsEnqDtl.setVisibleColumns(
         new Object[] {
           "pordName", "productUom", "enquiryQty", "enqDtlStaus", "lastUpdateddt", "lastUpdatedby"
         });
     tblSmsEnqDtl.setColumnHeaders(
         new String[] {
           "Product Name", "UOM", "Enquiry Qty", "Status", "Last Updated Date", "Last Updated By"
         });
     tblSmsEnqDtl.setColumnFooter("lastUpdatedby", "No.of Records : " + recordCnt);
     tblSmsEnqDtl.setPageLength(7);
   } catch (Exception e) {
     logger.info(e.getMessage());
   }
 }
  @Override
  protected Component getChart() {
    List<StockData> data = new LinkedList<StockData>();
    for (int i = 0; i < 200; i++) {
      data.addAll(getStockData());
    }

    Container container = new BeanItemContainer<StockData>(StockData.class, data);

    Table table = new Table();
    table.setContainerDataSource(container);
    table.addGeneratedColumn(
        "values",
        new Table.ColumnGenerator() {
          @Override
          public Object generateCell(Table source, Object itemId, Object columnId) {
            return new Sparkline(
                100, 20, (Number[]) source.getItem(itemId).getItemProperty(columnId).getValue());
          }
        });

    table.setVisibleColumns("month", "values", "latest");
    table.setHeightUndefined();

    return table;
  }
  private void cargarUsuarios(List<Usuario> lstUsuarios, boolean flagLimpiar) {

    IndexedContainer container = new IndexedContainer();
    container.addContainerProperty("id", Long.class, null);
    container.addContainerProperty("usuario", String.class, null);
    container.addContainerProperty("clave", String.class, null);
    container.addContainerProperty("nombres", String.class, null);
    container.addContainerProperty("apePat", String.class, null);
    container.addContainerProperty("apeMat", String.class, null);
    container.addContainerProperty("cargo", String.class, null);
    container.addContainerProperty("descCargo", String.class, null);
    container.addContainerProperty("rol", Rol.class, null);
    container.addContainerProperty("policia", Policia.class, null);
    container.addContainerProperty("dependencia", Dependencia.class, null);
    container.addContainerProperty("oficina.id", Long.class, null);
    container.addContainerProperty("oficina.nombre", String.class, null);
    container.addContainerProperty("rol.id", Long.class, null);

    tblUsuarios.setContainerDataSource(container);
    tblUsuarios.setVisibleColumns(
        new Object[] {"usuario", "nombres", "apePat", "apeMat", "cargo", "oficina.nombre"});

    tblUsuarios.setColumnWidth("usuario", 50);
    tblUsuarios.setColumnWidth("nombres", 75);
    tblUsuarios.setColumnWidth("apePat", 75);
    tblUsuarios.setColumnWidth("apeMat", 75);
    tblUsuarios.setColumnWidth("cargo", 130);
    tblUsuarios.setColumnWidth("oficina.nombre", 160);

    tblUsuarios.setColumnHeader("usuario", "Usuario");
    tblUsuarios.setColumnHeader("nombres", "Nombres");
    tblUsuarios.setColumnHeader("apePat", "Ape. Paterno");
    tblUsuarios.setColumnHeader("apeMat", "Ape. Materno");
    tblUsuarios.setColumnHeader("cargo", "Cargo");
    tblUsuarios.setColumnHeader("oficina.nombre", "Oficina");

    int con = 1;
    for (Usuario usuario : lstUsuarios) {
      Item item = container.addItem(con++);
      item.getItemProperty("id").setValue(usuario.getId());
      item.getItemProperty("usuario").setValue(usuario.getUsuario());
      item.getItemProperty("clave").setValue(usuario.getClave());
      item.getItemProperty("nombres").setValue(usuario.getNombres());
      item.getItemProperty("apePat").setValue(usuario.getApePat());
      item.getItemProperty("apeMat").setValue(usuario.getApeMat());
      item.getItemProperty("rol").setValue(usuario.getRol());
      item.getItemProperty("cargo").setValue(usuario.getCargo());
      item.getItemProperty("dependencia").setValue(usuario.getOficina());
      item.getItemProperty("policia").setValue(usuario.getPolicia());
      item.getItemProperty("descCargo").setValue(usuario.getDescCargo());
      item.getItemProperty("rol.id")
          .setValue(usuario.getRol() != null ? usuario.getRol().getId() : null);
      item.getItemProperty("oficina.id")
          .setValue(usuario.getOficina() != null ? usuario.getOficina().getId() : null);
      item.getItemProperty("oficina.nombre")
          .setValue(usuario.getOficina() != null ? usuario.getOficina().getNombre() : null);
    }
    limpiar();
  }
  @Override
  protected void configureTable(Table table) {
    table.setContainerDataSource(getTableContainer());

    setupGeneratedColumns(table);
    table.setVisibleColumns(new Object[] {"name", "playerCount", "roundCount", "gameCount"});
    table.setColumnHeaders(new String[] {"Name", "Players", "Rounds", "Games"});
  }
 private void AddressList() {
   contactList.setContainerDataSource(addressBookData);
   contactList.setVisibleColumns(visibleCols);
   contactList.setSelectable(true);
   contactList.setImmediate(true);
   contactList.setWidth("380px");
   contactList.setHeight("190px");
 }
  @SuppressWarnings("serial")
  private Component getTable() {
    List<UserOprYayasan> lm = GenericPersistence.findList(UserOprYayasan.class);

    dashboardPanels = new VerticalLayout();
    dashboardPanels.addStyleName("dashboard-panels");
    Responsive.makeResponsive(dashboardPanels);
    beans.setBeanIdProperty("id");
    beans.removeAllItems();
    if (lm != null) {
      beans.addAll(lm);
    } else {
      beans.addBean(new UserOprYayasan());
    }

    tabel.addGeneratedColumn(
        "aksi",
        new ColumnGenerator() {
          @Override
          public Object generateCell(Table source, Object itemId, Object columnId) {
            HorizontalLayout hl = new HorizontalLayout();
            Button edit = new Button(FontAwesome.EDIT);
            Button hapus = new Button(FontAwesome.TRASH_O);
            edit.addStyleName(ValoTheme.BUTTON_FRIENDLY);
            edit.addStyleName(ValoTheme.BUTTON_SMALL);
            hapus.addStyleName(ValoTheme.BUTTON_FRIENDLY);
            hapus.addStyleName(ValoTheme.BUTTON_SMALL);
            BeanItem<?> i = (BeanItem<?>) source.getContainerDataSource().getItem(itemId);
            final UserOprYayasan o = (UserOprYayasan) i.getBean();
            edit.addClickListener(
                new ClickListener() {
                  @Override
                  public void buttonClick(ClickEvent event) {
                    tambahUserYayasanbaru(o);
                  }
                });
            hl.addComponent(edit);
            hl.addComponent(hapus);
            return hl;
          }
        });
    tabel.setSizeFull();
    tabel.setImmediate(true);
    tabel.setSelectable(true);
    tabel.setContainerDataSource(beans);
    tabel.setRowHeaderMode(Table.RowHeaderMode.INDEX);
    tabel.setColumnHeader("useNnama", "NAMA PENGGUNA");
    tabel.setColumnHeader("nama", "NAMA");
    tabel.setColumnHeader("realName", "NAMA LENGKAP");
    tabel.setColumnHeader("registerDate", "TANGGAL REGISTRASI");
    tabel.setColumnHeader("email", "E-MAIL");
    tabel.setColumnHeader("lastSuccessfulLogin", "TERAKHIR LOGIN");
    tabel.setColumnHeader("aksi", "AKSI");
    tabel.setVisibleColumns(
        "aksi", "nama", "realName", "registerDate", "email", "lastSuccessfulLogin");
    dashboardPanels.addComponent(tabel);
    return dashboardPanels;
  }
 @Override
 public void bind() {
   Table userList = this.view.getUserList();
   container = new BeanItemContainer<User>(User.class);
   userList.setContainerDataSource(container);
   userList.setVisibleColumns(new String[] {"userName", "firstName", "lastName"});
   userList.setImmediate(true);
   userList.setSelectable(true);
   userList.setMultiSelect(false);
   // userList.setEditable(true);
 }
 @Override
 protected void initView() {
   super.initView();
   processTable = new Table();
   dataSource = new BeanItemContainer<ProcessDefinition>(ProcessDefinition.class);
   processTable.setContainerDataSource(dataSource);
   processTable.setVisibleColumns(
       new String[] {"name", "key", "version", "resourceName", "category"});
   processTable.setSizeFull();
   processTable.addGeneratedColumn("name", createNameColumnGenerator());
   getViewLayout().addComponent(processTable);
   getViewLayout().setExpandRatio(processTable, 1.0F);
 }
  /** 初始化表格 * */
  private void initRightTable(Table table, Container container) {
    table.setSizeFull();
    table.setHeight(100, Unit.PERCENTAGE);
    table.setContainerDataSource(container);
    table.setVisibleColumns(Constants.COMPLAIN_TYPE_COL);
    table.setColumnHeaders(Constants.COMPLAIN_TYPE_COL_HEADERS_CHINESE);

    table.setColumnCollapsingAllowed(true);
    table.setColumnReorderingAllowed(true);
    table.addItemClickListener(
        new ItemClickListener() {

          @Override
          public void itemClick(ItemClickEvent event) {
            // MouseButton.LEFT 左键单击
            if (event.getButtonName().equals(MouseButton.LEFT.getName())) {
              createWindow(event.getItem());
            }
          }
        });
  }
  private void initContactList() {
    contactList.setContainerDataSource(contactContainer);
    contactList.setVisibleColumns(new String[] {FNAME, LNAME, COMPANY});
    contactList.setSelectable(true);
    contactList.setImmediate(true);

    contactList.addValueChangeListener(
        new Property.ValueChangeListener() {
          public void valueChange(ValueChangeEvent event) {
            Object contactId = contactList.getValue();

            /*
             * When a contact is selected from the list, we want to show
             * that in our editor on the right. This is nicely done by the
             * FieldGroup that binds all the fields to the corresponding
             * Properties in our contact at once.
             */
            if (contactId != null) editorFields.setItemDataSource(contactList.getItem(contactId));

            editorLayout.setVisible(contactId != null);
          }
        });
  }
Exemple #11
0
  @Override
  /** displays a list of historicProcessInstances */
  protected void initView() {
    super.initView();
    Button refresh = new Button("Refresh");
    refresh.addStyleName(Reindeer.BUTTON_SMALL);
    refresh.addListener(
        new Button.ClickListener() {
          private static final long serialVersionUID = 1L;

          @Override
          public void buttonClick(ClickEvent event) {
            getPresenter().init();
          }
        });

    processTable = new Table();
    dataSource =
        new BeanItemContainer<HistoricProcessInstanceTitle>(HistoricProcessInstanceTitle.class);
    processTable.setContainerDataSource(dataSource);
    processTable.setVisibleColumns(
        new String[] {
          "id",
          "processDefinitionId",
          "title",
          "startUserId",
          "startTime",
          "endTime",
          "durationInMillis"
        });
    processTable.setSizeFull();
    processTable.addGeneratedColumn("id", createNameColumnGenerator());
    processTable.addGeneratedColumn("durationInMillis", new TimeColumnGenerator());
    getViewLayout().addComponent(refresh);
    getViewLayout().addComponent(processTable);
    getViewLayout().setExpandRatio(processTable, 1.0F);
  }
  @Override
  public void execute() {
    List<ChangeRecord> historyList = view.getUi().getStockService().findChanges(good);
    Window subWindow = new Window();
    subWindow.setModal(true);
    subWindow.setHeight("650px");
    subWindow.setWidth("700px");
    subWindow.setClosable(true);
    view.getUi().addWindow(subWindow);

    final Button pdfButton = new Button(bundle.getString("pdf.export"));
    pdfButton.setIcon(new ThemeResource("img/pdf.png"));
    pdfButton.setWidth("150");
    StreamResource pdfStream = getPDFStream(view.getUi().getStockService().findChanges(good));
    pdfStream.setMIMEType("application/pdf");
    FileDownloader pdfDownloader = new FileDownloader(pdfStream);
    pdfDownloader.extend(pdfButton);

    final VerticalLayout layout = new VerticalLayout();
    layout.setMargin(true);
    layout.setSpacing(true);
    layout.addComponent(pdfButton);

    for (ChangeRecord record : historyList) {
      for (ChangeRecord.PropertyChange p : record.getChangeList()) {
        p.setName(bundle.getString(p.getName()));
      }
      Panel panel = new Panel();
      BeanItemContainer<ChangeRecord.PropertyChange> container =
          new BeanItemContainer<>(ChangeRecord.PropertyChange.class, record.getChangeList());
      Table table = new Table();
      table.setContainerDataSource(container);
      table.setVisibleColumns("name", "oldValue", "newValue");
      table.setColumnHeaders(
          bundle.getString("history.property"),
          bundle.getString("history.old"),
          bundle.getString("history.new"));
      table.setColumnExpandRatio("name", 0.33f);
      table.setColumnExpandRatio("oldValue", 0.33f);
      table.setColumnExpandRatio("newValue", 0.33f);
      table.setPageLength(0);
      table.setWidth("100%");

      VerticalLayout panelLayout = new VerticalLayout();
      panelLayout.addComponent(
          new Label(
              "<b>"
                  + new SimpleDateFormat("dd-MM-YYYY HH:mm").format(record.getDate())
                  + ": "
                  + record.getUser().getName()
                  + " "
                  + record.getUser().getSurname()
                  + "</b><br/>",
              ContentMode.HTML));
      panelLayout.addComponent(table);
      panel.setContent(panelLayout);
      layout.addComponent(panel);
    }

    subWindow.setContent(layout);
  }
  public TradeTab() {
    HorizontalSplitPanel mainPanel = new HorizontalSplitPanel();
    mainPanel.setHeight("100%");

    VerticalLayout leftPanel = new VerticalLayout();
    leftPanel.setMargin(true);
    leftPanel.setSpacing(true);
    leftPanel.setHeight("100%");

    itemContainer.addContainerProperty("auction", AuctionService.class, null);
    itemContainer.addContainerProperty("id", String.class, null);
    itemContainer.addContainerProperty("description", String.class, null);
    itemContainer.addContainerProperty("startingPrice", Long.class, null);
    itemContainer.addContainerProperty("item", AuctionItem.class, null);

    itemTable.addStyleName("h1");
    //		itemTable.addStyleName("noheader");
    itemTable.setSelectable(true);
    itemTable.setImmediate(true);
    itemTable.setVisibleColumns(new String[] {"description", "startingPrice"});
    itemTable.setColumnHeaders(new String[] {"Description", "Starting Price"});
    itemTable.setSizeFull();

    itemTable.addListener(
        new Property.ValueChangeListener() {
          public void valueChange(ValueChangeEvent event) {
            Application application = getApplication();
            if (application instanceof UriFragmentService)
              ((UriFragmentService) application).setUriFragment(getCurrentUriFragment(), false);

            Object itemId = itemTable.getValue();
            AuctionItem item =
                itemId != null
                    ? (AuctionItem) itemTable.getContainerProperty(itemId, "item").getValue()
                    : null;
            for (Iterator<Component> iter = dynamicLayout.getComponentIterator();
                iter.hasNext(); ) {
              Component component = iter.next();
              if (component instanceof SelectionListener<?>) {
                ((SelectionListener<AuctionItem>) component).selectionChanged(item);
              }
            }
          }
        });

    leftPanel.addComponent(itemTable);
    leftPanel.setExpandRatio(itemTable, 1f);

    // Button panel
    VerticalLayout buttonBarLayout = new VerticalLayout();
    buttonBar = new DynamicContainer(buttonBarLayout);
    buttonBar.setWidth("100%");
    leftPanel.addComponent(buttonBar);

    // Progress Indicator (hidden)
    ProgressIndicator progress = new ProgressIndicator(ProgressIndicator.SIZE_UNDEFINED);
    progress.addStyleName("hidden");
    progress.setPollingInterval(POLL_INTERVAL);
    leftPanel.addComponent(progress);
    leftPanel.setExpandRatio(progress, 0f);

    mainPanel.addComponent(leftPanel);
    mainPanel.addComponent(container);

    Table table = new Table();
    table.setSizeFull();

    setCompositionRoot(mainPanel);
    setCaption("Trade");
    setSizeFull();
  }
 public void setVisibleTablePropertiesList(Object... tablePropertyIds) {
   tableList.setVisibleColumns(tablePropertyIds);
 }
  private void cargarDatos() {
    Notificacion notificacionBuscar = new Notificacion();
    notificacionBuscar.setInforme(informe);
    List<Notificacion> notificaciones = notificacionService.buscar(notificacionBuscar);

    IndexedContainer container = new IndexedContainer();
    container.addContainerProperty(COLUMNA_UNIDAD_PROCURADURIA, String.class, null);
    container.addContainerProperty(COLUMNA_TIPO_NOTIFICACION, String.class, null);
    container.addContainerProperty(COLUMNA_FECHA_RECEPCION, String.class, null);
    container.addContainerProperty(COLUMNA_FECHA_VENCIMIENTO, String.class, null);
    container.addContainerProperty(COLUMNA_FECHA_PLAZO, String.class, null);
    container.addContainerProperty(COLUMNA_ESTADO_NOTIFICACION, String.class, null);
    container.addContainerProperty(COLUMNA_OPCION_ELIMINAR, Button.class, null);
    container.addContainerProperty(COLUMNA_OPCION_SEGUIMIENTO, Button.class, null);

    DateFormat df = new SimpleDateFormat("dd/MM/yyyy");

    int con = 1;
    for (final Notificacion notificacion : notificaciones) {
      Item item = container.addItem(con++);
      item.getItemProperty(COLUMNA_UNIDAD_PROCURADURIA)
          .setValue(notificacion.getUnidad() == null ? null : notificacion.getUnidad().getNombre());
      item.getItemProperty(COLUMNA_TIPO_NOTIFICACION)
          .setValue(
              notificacion.getTipoNotificacion() == null
                  ? null
                  : notificacion.getTipoNotificacion().getNombre());
      item.getItemProperty(COLUMNA_FECHA_RECEPCION)
          .setValue(
              notificacion.getFechaRecepcion() == null
                  ? null
                  : df.format(notificacion.getFechaRecepcion()));
      item.getItemProperty(COLUMNA_FECHA_VENCIMIENTO)
          .setValue(
              notificacion.getFechaVencimiento() == null
                  ? null
                  : df.format(notificacion.getFechaVencimiento()));
      item.getItemProperty(COLUMNA_FECHA_PLAZO)
          .setValue(
              notificacion.getFechaPlazo() == null
                  ? null
                  : df.format(notificacion.getFechaPlazo()));
      item.getItemProperty(COLUMNA_ESTADO_NOTIFICACION)
          .setValue(notificacion.getEstado() == null ? null : notificacion.getEstado().getNombre());
      Button eliminar = new Button();
      eliminar.setCaption("Eliminar");
      eliminar.addListener(
          new ClickListener() {

            @Override
            public void buttonClick(ClickEvent event) {
              notificacionService.eliminar(notificacion);
              cargarDatos();
            }
          });
      item.getItemProperty(COLUMNA_OPCION_ELIMINAR).setValue(eliminar);
      Button seguimiento = new Button();
      seguimiento.setCaption("Seguimiento");
      seguimiento.addListener(
          new ClickListener() {

            @Override
            public void buttonClick(ClickEvent event) {

              PanelRegistroInformeSeguimientoNotificacion
                  panelRegistroInformeSeguimientoNotificacion =
                      new PanelRegistroInformeSeguimientoNotificacion(notificacion);

              Window wdSeguimiento = new Window();

              wdSeguimiento.setModal(true);
              wdSeguimiento.setResizable(false);
              wdSeguimiento.addComponent(panelRegistroInformeSeguimientoNotificacion);

              wdSeguimiento.setCaption("Seguimiento");
              wdSeguimiento.setWidth("1050px");
              getApplication().getMainWindow().getWindow().addWindow(wdSeguimiento);
            }
          });
      item.getItemProperty(COLUMNA_OPCION_SEGUIMIENTO).setValue(seguimiento);
    }

    tblNotificacion.setContainerDataSource(container);
    tblNotificacion.setVisibleColumns(
        new Object[] {
          COLUMNA_UNIDAD_PROCURADURIA,
          COLUMNA_TIPO_NOTIFICACION,
          COLUMNA_FECHA_RECEPCION,
          COLUMNA_FECHA_VENCIMIENTO,
          COLUMNA_FECHA_PLAZO,
          COLUMNA_ESTADO_NOTIFICACION,
          COLUMNA_OPCION_ELIMINAR,
          COLUMNA_OPCION_SEGUIMIENTO
        });
    tblNotificacion.setColumnWidth(COLUMNA_UNIDAD_PROCURADURIA, 100);
    tblNotificacion.setColumnWidth(COLUMNA_TIPO_NOTIFICACION, 100);
    tblNotificacion.setColumnWidth(COLUMNA_FECHA_RECEPCION, 100);
    tblNotificacion.setColumnWidth(COLUMNA_FECHA_VENCIMIENTO, 100);
    tblNotificacion.setColumnWidth(COLUMNA_FECHA_PLAZO, 100);
    tblNotificacion.setColumnWidth(COLUMNA_ESTADO_NOTIFICACION, 100);
    tblNotificacion.setColumnWidth(COLUMNA_OPCION_ELIMINAR, 100);
    tblNotificacion.setColumnWidth(COLUMNA_OPCION_SEGUIMIENTO, 100);
    tblNotificacion.setColumnHeader(COLUMNA_UNIDAD_PROCURADURIA, "Unidad");
    tblNotificacion.setColumnHeader(COLUMNA_TIPO_NOTIFICACION, "Tipo");
    tblNotificacion.setColumnHeader(COLUMNA_FECHA_RECEPCION, "F. Recepcion");
    tblNotificacion.setColumnHeader(COLUMNA_FECHA_VENCIMIENTO, "F. Vencimiento");
    tblNotificacion.setColumnHeader(COLUMNA_FECHA_PLAZO, "F. Plazo");
    tblNotificacion.setColumnHeader(COLUMNA_ESTADO_NOTIFICACION, "Estado");
    tblNotificacion.setColumnHeader(COLUMNA_OPCION_ELIMINAR, "");
    tblNotificacion.setColumnHeader(COLUMNA_OPCION_SEGUIMIENTO, "");
  }
Exemple #16
0
  protected Component createMainArea() {
    layout = new VerticalLayout();

    layout.setSpacing(true);
    layout.setMargin(true);
    layout.setSizeFull();

    HorizontalLayout filterLine = new HorizontalLayout();

    TextField filterBox = new TextField();
    filterBox.addStyleName(JabylonStyle.SEARCH_FIELD.getCSSName());
    filterBox.addListener(
        new TextChangeListener() {

          @Override
          public void textChange(TextChangeEvent event) {
            propertyFilter.setFilterText(event.getText());
            propertyPairContainer.addContainerFilter(propertyFilter);
          }
        });
    filterBox.setInputPrompt(
        Messages.getString("PropertiesEditor_FILTER_INPUT_PROMPT")); // $NON-NLS-1$
    filterLine.addComponent(filterBox);

    final CheckBox untranslatedBox =
        new CheckBox(
            Messages.getString(
                "PropertiesEditor_SHOW_ONLY_UNTRANSLATED_BUTTON_CAPTION")); //$NON-NLS-1$
    untranslatedBox.addListener(
        new ClickListener() {

          @Override
          public void buttonClick(ClickEvent event) {
            propertyPairContainer.removeContainerFilter(untranslatedFilter);
            if (untranslatedBox.getValue().equals(Boolean.TRUE))
              propertyPairContainer.addContainerFilter(untranslatedFilter);
          }
        });
    untranslatedBox.setImmediate(true);
    filterLine.addComponent(untranslatedBox);

    layout.addComponent(filterLine);
    layout.setExpandRatio(filterLine, 0);

    table = new Table();
    table.addStyleName(JabylonStyle.TABLE_STRIPED.getCSSName());
    table.setSizeFull();
    target = descriptor.loadProperties();
    source = descriptor.getMaster().loadProperties();

    propertyPairContainer = new PropertyPairContainer(source, target);
    table.setContainerDataSource(propertyPairContainer);
    table.setVisibleColumns(
        propertyPairContainer.getContainerPropertyIds().subList(0, 2).toArray());
    table.setWidth(100, Table.UNITS_PERCENTAGE);
    table.addGeneratedColumn(
        Messages.getString("PropertiesEditor_PROBLEMS_COLUMN_HEADER"),
        new ColumnGenerator() { //$NON-NLS-1$

          @Override
          public Object generateCell(Table source, Object itemId, Object columnId) {

            if (reviews.containsKey(itemId)) {
              Embedded embedded = new Embedded("", ImageConstants.IMAGE_ERROR); // $NON-NLS-1$

              Review review = reviews.get((String) itemId).iterator().next();
              // TODO: this can't be the right way to refresh?
              if (review.cdoInvalid()) {
                reviews.remove(itemId, review); // the review is
                // no
                // longer valid
                embedded.setIcon(ImageConstants.IMAGE_OK);
                embedded.setDescription(""); // $NON-NLS-1$
              } else {
                embedded.setDescription(review.getMessage());
              }

              return embedded;
            } else return new Embedded("", ImageConstants.IMAGE_OK); // $NON-NLS-1$
          }
        });

    table.setColumnHeaderMode(Table.COLUMN_HEADER_MODE_EXPLICIT);

    table.setColumnHeaders(
        new String[] {
          Messages.getString("PropertiesEditor_ORIGINAL_COLUMN_HEADER"),
          Messages.getString("PropertiesEditor_TRANSLATED_COLUMN_HEADER"),
          Messages.getString("PropertiesEditor_PROBLEMS_COLUMN_HEADER")
        }); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
    table.setColumnExpandRatio(propertyPairContainer.getContainerPropertyIds().get(0), 1.0f);
    table.setColumnExpandRatio(propertyPairContainer.getContainerPropertyIds().get(1), 1.0f);
    table.setColumnExpandRatio(
        Messages.getString("PropertiesEditor_PROBLEMS_COLUMN_HEADER"), 0.0f); // $NON-NLS-1$

    table.setEditable(false);
    table.setWriteThrough(false);

    table.setSelectable(true);
    table.setMultiSelect(false);
    table.setImmediate(true); // react at once when something is selected
    table.addListener(this);

    layout.addComponent(table);

    layout.setExpandRatio(table, 2);
    createEditorArea();
    return layout;
  }
 public void setVisibleTablePropertiesDetil(Object... tablePropertyIds) {
   tableDetil.setVisibleColumns(tablePropertyIds);
 }