cesar vasde

Greenhorn
+ Follow
since Jan 01, 2011
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by cesar vasde

Tim Holloway wrote:Well, according to that latest sample, your LibroController no longer constructs and sets the libroBean property variable. So unless you have a dependency injection for libroBean in faces-config.xml that you're not showing us, the libroBean property isn't being initialized. Uninitialized would mean that the getLibroBean() returns null.



The injection I do it this way???

7 years ago
JSF
I have also tried to use @ ViewScoped instead of @SessionScoped, but the results are the same :S


How can find the problem ???
7 years ago
JSF

Tim Holloway wrote:"libroBean" is unreachable. It's an inner class object and you didn't provide a "get" accessor method for the libroBean property.



My class Libro Controller does provide all the getters and setters their attributes.


So I write //Getters and Setters



i.e. my object libroBean have a method get accesor Target Unreachable

If so, because comes this error

Pd: My class Librocontroller complete is

7 years ago
JSF
My doubt is because the netbeans marks the object "libroBean" as Target Unreachable



How do I fix this?
7 years ago
JSF
I've got following bean





Then I've this page xhtml (I will a fragment form):



Is the typical form to save data. I'm working in the Netbeans 7.0

I have the following issue:



This means that dependency injection only works with another bean. i.e. my bean LibroBean must be declared so:



And after that add annotations @ManagedProperty in the bean LibroController???

If so, because in this example here if it works without having the object to inject is a bean.

Example

Car class
TableBean class
face-config

I hope to help
7 years ago
JSF
You see, I have the following exceptions


This is the bean



faces-config.xml



The values that print in console are:

user: null
pass: null

As you can see, the fields of backing bean are null even though the xhtml page I put some value on them


What do you think is the problem?

7 years ago
JSF
You see I have several forms including a commandButton. Each form is located on different pages. Pages a user calls.

When you call the first form, it acts normally and you are directed to the relevant page. The problem comes when you call a second form, this is no longer acting normally and hangs

I've seen helping PhaseListener of the application to stay here



Tell me please what is happening
7 years ago
JSF
According to this example here, in a commandButton can put this:

<h:commandButton action="/shopping/page2" value="Submit" />

I'm working that way in my application. The problem I have is that the url does not refresh in the browser

For example: In page1.xhtml I have commandButton with action="/pages/page1.xhtml"

This button should take me to a page named page1.xhtml. But it does not, the view is updated but the URL of the browser still has the same url above.

Ie in the browser says /page/page1.xhtml but in reality I'm on page 2

This brings me to future problems, as sometimes the browser gets stuck and does not know which page to send

Help please

7 years ago
JSF
Is there anyone who has tried my code?

I need urgent help please

I'm debugging the application according to this example
And I get the following output



What does this mean?
7 years ago
JSF

John Tannel wrote:Cesar,

I'm sorry. I gave you wrong info and didn't realize it until I saw your code. data should NOT be a managed property, I'm sorry. The data property is bound to the data in the h:dataTable from the code there. You can remove that managed property from faces-config.



When I do that, I get an error message from Eclipse

John Tannel wrote:
As for what is not working, I'm not sure at the moment. I'm in the middle of something right now but in an hour I'll look over again and see if I can find the error. Do you get any errors printed at all, even in the tomcat logs? Or does it just hang on that page and do nothing? Try adding in some print statements to debug to make sure all the code executes.




I'm not get any error message Eclipse or Tomcat.

Simply hangs

I think I better share the code and how I could best help


http://www.megaupload.com/?d=HSSNXP6Z

And database

http://www.megaupload.com/?d=FLJU0LLT
7 years ago
JSF

John Tannel wrote:

Inside of your faces-config.xml do you have a navigation rule from index-pers.xhtml to modificar.xhtml for the action 'modificar'?


Inside the bean, change private UIData data =new UIData(); to private UIData data; (I don't think this is a problem, but I know 100% that it works the second way).
MAKE SURE that data is a managed property of PersonalBean. I think this may be your problem.

Here is some managed property info: http://mkblog.exadel.com/2009/08/learning-jsf2-managed-beans/
Read the part about "Dependency Injection"





Then the face-config.xml should look like



Or so



But both does not work



This code of the list



With this method I get the list of index-pers.xhtml
7 years ago
JSF
Well, here again

Here I have the form implemented with h: commandLink. This is the index-pers.xhtml




The Bean



The modificar.xhtml



The structure of the project



At the end happens this



Sorry for the inconvenience n_n
7 years ago
JSF
How I can verify that the data be cached?

I tried to implement the option of editing with the suggestion you gave me but the page takes to load
7 years ago
JSF
Sorry sometimes incorporated h: commandButton and when I click on them slow to load. What is this?

I would also like to know how to capture data about InputText

For the moment I'm trying to do with this form, in which values are displayed to edit





But I have noticed that when I edit the text boxes are not stored in the bean attribute

Another alternative that I think is through GET with h:link

I took the parameters to a xhtml page and then before rendering the page, through a f:event do a redirect event

What should ahcer to be saved?


Thanks for the help
7 years ago
JSF
Well I am trying to do is pass the id of a bean as a parameter to another JSF page and in this site and through the id can display the attributes of the bean

The id is in a table



The id of this bean is received on another website xhtml



This is the bean and entity





The problem is that only the ID passed as a parameter, I would like to pass all the parameters of the Bean, once did with just the ID, but now I think I changed something and isn't does

Watch

Page 1: Object 7 selected



Page 2: Only show the ID of th Object 7 and data sample corresponds to the last item added



Page 3: Here you can see



Is it possible to pass an entire object as a parameter with only the ID?

Help please !!!
7 years ago
JSF