• Post Reply Bookmark Topic Watch Topic
  • New Topic

Not getting the variable values.

pankaj semwal
Ranch Hand
Posts: 303
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

The value of workId is coming null in save method .Even i created the setter and getter method of workid.
But the value is not coming null in issueWork method.
Please help me.

This is my action class code
David Newton
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Where is workId supposed to be coming from?

Some general comments:
* misc: You have a Logger; use that instead of System.out.println.
* line 78: Your execute() method is returning "sucess", which is fine if you also misspelled it in the config file.
* lines 85-87: Don't get lazy; write something meaningful, even in your system.outs.
* lines 97-104: Simplify; all conditions result in the "add" result.
* lines 133 & 135: Unnecessary casts (your IDE should warn you about this)
* line 137: It doesn't appear that you're actually returning XML.
* line 139: don't get parameters directly from the request.
* line 145: No need to convert. You should always check for NumberFormatExceptions if you're going to work around the framework and do things manually.
* line 147: Convention generally says to name variables beginning with a lower-case letter. You don't *have* to, but it will help when others read your code.
* line 202: It looks like you're implementing RequestAware; at the very least you should use that to grab parameters directly from the request (although I don't believe you need to in this case).
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!