@FXML public void initialize() { area_ChoiceBox.setItems(Enum2ObservableList.transit(StoreAreaCode.values())); ObservableList<SimpleEnumProperty<StoreAreaCode>> observableList = area_ChoiceBox.getItems(); // set default rowNum_Field.setText("1"); shelvesNum_Field.setText("20"); for (SimpleEnumProperty<StoreAreaCode> enumProperty : observableList) { if (enumProperty.getEnum() == defaultAreaCode) { area_ChoiceBox.setValue(enumProperty); } } // init check formatCheckQueue = new FormatCheckQueue(); formatCheckQueue.addTasker( new CheckIsNullTasker(rowNum_Field), new CheckIsNullTasker(shelvesNum_Field)); }
@FXML public void initialize() { type_TableColumn.setCellValueFactory( cellData -> new SimpleStringProperty(cellData.getValue().getStaff().getChinese())); ID_TableColumn.setCellValueFactory( cellData -> new SimpleStringProperty(cellData.getValue().getID())); name_TableColumn.setCellValueFactory( cellData -> new SimpleStringProperty(cellData.getValue().getName())); gender_TableColumn.setCellValueFactory( cellData -> new SimpleStringProperty(cellData.getValue().getSex().toString())); age_TableColumn.setCellValueFactory( cellData -> new SimpleStringProperty(Integer.toString(cellData.getValue().getAge()))); institution_TableColumn.setCellValueFactory( cellData -> new SimpleStringProperty(cellData.getValue().getInstitutionID())); personID_TableColumn.setCellValueFactory( cell -> new SimpleStringProperty(cell.getValue().getPersonID())); love_TableColumn.setCellValueFactory( cell -> new SimpleStringProperty(cell.getValue().getLove())); // init check formatCheckQueue = new FormatCheckQueue(); formatCheckQueue.addTasker(new CheckIsNullTasker(institution_Field)); }