En-desarrollo #27

Merged
alex merged 39 commits from En-desarrollo into main 2024-10-07 18:23:34 +00:00
2 changed files with 5 additions and 4 deletions
Showing only changes of commit 13c81de48c - Show all commits

View File

@ -10,6 +10,7 @@ public abstract class BaseEntity {
@Id
@GeneratedValue(strategy = GenerationType.UUID)
private UUID id;
@Enumerated(EnumType.STRING)
Outdated
Review

estos campos van en esta clase. deberian estar en la clase que hace falta. Document?

estos campos van en esta clase. deberian estar en la clase que hace falta. Document?
private Employee.Status status;
private String fileName;
@Lob
@ -64,11 +65,11 @@ public abstract class BaseEntity {
return documentType;
}
public void setStatus(Employee.Status status) {
public void setStatusEmployee(Employee.Status status) {
this.status = status;
}
public Employee.Status getStatus() {
public Employee.Status getStatusEmployee() {
return status;
}
}

View File

@ -199,7 +199,7 @@ public class EmployeeView extends BeanValidationForm<Employee> implements HasUrl
private void saveEmployee() {
if (validateForm()) {
Employee employee = getEntity();
employee.setStatus(status.getValue());
employee.setStatusEmployee(status.getValue());
employeeService.createOrUpdate(employee);
Notification.show(NOTIFICATION_SAVE_SUCCESS);
getUI().ifPresent(ui -> ui.navigate(EmployeesListView.class));
@ -233,7 +233,7 @@ public class EmployeeView extends BeanValidationForm<Employee> implements HasUrl
if ("edit".equals(action) && !s.isEmpty()) {
saveButton.setVisible(true);
editButton.setVisible(false);
status.setValue(employee.getStatus());
status.setValue(employee.getStatusEmployee());
setFieldsEditable();
} else if ("view".equals(action) && !s.isEmpty()) {
setFieldsReadOnly();