Bean class not found - Javaweb

Asked

Viewed 57 times

1

Good evening, I am doing my tcc in Java Web and making data persistence with JPA and Hibernete. I did the CRUD apparently right, but when I click the sign up button it gives this error.

action="#{empresaController.incluir()}": Target Unreachable, identifier 'empresaController' resolved to null

I guess you’re not finding my class empresaController.

Could someone help me ?

@ManagedBean
@SessionScoped
public class EmpresaController extends BaseController<Empresa>{

    public EmpresaController() {
        super(Empresa.class);
        this.dao = new EmpresaDao();
    }

    @Override
    public void limpar() {
        this.objeto = new Empresa();

    }
    @Override
    public String incluir() {
        return super.incluir(); 
    }
}
  • You can edit the question by placing the class code empresaController?

  • edited already with the code

  • I don’t have an answer, but maybe this thread in the GUJ be useful to help identify the problem. (You imported this ManagedBean of javax.faces.bean.ManagedBean?)

  • yes is imported from javax.faces.bean.Managedbean

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.