コード例 #1
0
 @Override
 public TableDto getSelectedTable() {
   if (tableChooser.getSelectedTables().size() == 1) {
     return tableChooser.getSelectedTables().get(0);
   }
   return null;
 }
コード例 #2
0
ファイル: EntityModalView.java プロジェクト: obiba/opal
 @Override
 public void setTables(JsArray<TableDto> tables, TableDto selectedTable) {
   clear();
   valuesPanel.setVisible(tables.length() > 0);
   if (tables.length() > 0) {
     tableChooser.addTableSelections(tables);
     tableChooser.selectTable(selectedTable);
   }
 }
コード例 #3
0
  @Inject
  public DeriveFromVariableView(Binder uiBinder) {
    initWidget(uiBinder.createAndBindUi(this));

    tableChooser.addStyleName("table-chooser-large");
    variableBox.addStyleName("table-chooser-large");
  }
コード例 #4
0
ファイル: EntityModalView.java プロジェクト: obiba/opal
  private void clear() {
    tableChooser.clear();

    while (table.getColumnCount() > 0) {
      table.removeColumn(0);
    }

    addTableColumns();
  }
コード例 #5
0
ファイル: EntityModalView.java プロジェクト: obiba/opal
 @Inject
 public EntityModalView(EventBus eventBus) {
   super(eventBus);
   widget = uiBinder.createAndBindUi(this);
   valueSelectionHandler = new ValueSelectionHandlerImpl();
   initializeTable();
   initializeDisplayOptions();
   dialog.setTitle(translations.entityDetailsModalTitle());
   dialog.setMinWidth(MIN_WIDTH);
   dialog.setMinHeight(MIN_HEIGHT);
   tableChooser.addStyleName("table-chooser-large");
 }
コード例 #6
0
 @Override
 public void selectTable(TableDto tableDto) {
   tableChooser.selectTable(tableDto);
 }
コード例 #7
0
 @Override
 public void addTableSelections(JsArray<TableDto> tables) {
   tableChooser.addTableSelections(tables);
 }
コード例 #8
0
ファイル: EntityModalView.java プロジェクト: obiba/opal
 private TableDto getSelectedTable() {
   List<TableDto> tables = tableChooser.getSelectedTables();
   // there is only one table since the chooser is not multi select
   return tables.isEmpty() ? null : tables.get(0);
 }