#4-Registro-de-Información-Personal #16

Merged
alex merged 15 commits from #4-Registro-de-Información-Personal into main 2024-09-08 13:08:42 +00:00
Showing only changes of commit dd95b70c66 - Show all commits

View File

@ -3,7 +3,6 @@ package com.primefactorsolutions.views;
import com.primefactorsolutions.model.Employee; import com.primefactorsolutions.model.Employee;
import com.primefactorsolutions.service.EmployeeService; import com.primefactorsolutions.service.EmployeeService;
import com.vaadin.flow.component.button.Button; import com.vaadin.flow.component.button.Button;
import com.vaadin.flow.component.checkbox.Checkbox;
import com.vaadin.flow.component.html.H2; import com.vaadin.flow.component.html.H2;
import com.vaadin.flow.component.html.Main; import com.vaadin.flow.component.html.Main;
import com.vaadin.flow.router.PageTitle; import com.vaadin.flow.router.PageTitle;
@ -44,7 +43,6 @@ public class EmployeesListView extends Main {
private void configureTable() { private void configureTable() {
table.setColumns("firstName", "lastName", "status"); table.setColumns("firstName", "lastName", "status");
addEditButtonColumn("Edit", this::navigateToEditView); addEditButtonColumn("Edit", this::navigateToEditView);
addEditButtonColumn("Save", this::navigateToSaveChangeStatus);
setupPagingGrid(); setupPagingGrid();
} }
alex marked this conversation as resolved Outdated
Outdated
Review

no es necesario agregar esto porque ya existe el boton edit que navega a la vista edit.

no es necesario agregar esto porque ya existe el boton edit que navega a la vista edit.
@ -76,10 +74,6 @@ public class EmployeesListView extends Main {
getUI().ifPresent(ui -> ui.navigate(EmployeeView.class, "new")); getUI().ifPresent(ui -> ui.navigate(EmployeeView.class, "new"));
} }
private void navigateToSaveChangeStatus(Employee employee) {
// no-op
}
private void setupPagingGrid() { private void setupPagingGrid() {
table.setPaginationBarMode(PagingGrid.PaginationBarMode.BOTTOM); table.setPaginationBarMode(PagingGrid.PaginationBarMode.BOTTOM);
table.setPageSize(5); table.setPageSize(5);