I have the following attributes in my class:
static String URL="jdbc:jtds:sqlserver://blablabla; databaseName=Pxx";
static String usuario;
static String password ;
static String DRIVER="net.sourceforge.jtds.jdbc.Driver";
I would like to pass parameters to the user and password attribute through a screen with 2 inputs
:
<label> Usuário: <h:inputText value ="#{sql_controle.parans.usuario}"/></label>
<label> Password: <h:inputText value ="#{sql_controle.parans.password}"/></label>
<br></br><br></br>
<p:commandButton value="CRIAR CONEXÂO" class ="btnSalvar"
action="#{sql_controle.createParam()}" onclick="#"/>
Except that they are not getting the parameters any attribute of another class that uses this procedure not being static
works. I would like to know how to do this in attributes of type static
.