You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Shashank (JIRA)" <ji...@apache.org> on 2009/02/26 19:11:47 UTC

[jira] Created: (WW-3013) Validating tabular input

Validating tabular input
------------------------

                 Key: WW-3013
                 URL: https://issues.apache.org/struts/browse/WW-3013
             Project: Struts 2
          Issue Type: Task
          Components: Core Actions
    Affects Versions: 2.0.14
         Environment: Windows Xp, JDK 1.5, WebSphere Portal, Liferay
            Reporter: Shashank
            Priority: Critical


I want to make a tabular input along with validation. 
For example:
IN JSP:

<% for (int i=0;i<=someBussinessLogicResultSet.size();i++) { %> 
         <s:textfield name="mytext" />
<% } %>
<s:submit>

Then in Action I wrote:

@Validation
public myaction extends ActionSupport{

public String execute()
{
return SUCCESS;
}

@RequiredStringValidation(message="Please enter value in text box")
public void getMytext() {return mytext;}

public void setMytext(List mytext) {this.mytext=mytext;}

private List mytext;

}


I know the above code will not work unless i remove the validations. 
But however if I need a validation so that a error message is displayed on only those text fields which are left empty by the user, how can I do so??

Although just for note I am not using scriplet as shown above but my text fiels are within display tags.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (WW-3013) Validating tabular input

Posted by "Musachy Barroso (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/struts/browse/WW-3013?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Musachy Barroso closed WW-3013.
-------------------------------

    Resolution: Not A Problem

Ask questions on the users mailing list please.

> Validating tabular input
> ------------------------
>
>                 Key: WW-3013
>                 URL: https://issues.apache.org/struts/browse/WW-3013
>             Project: Struts 2
>          Issue Type: Task
>          Components: Core Actions
>    Affects Versions: 2.0.14
>         Environment: Windows Xp, JDK 1.5, WebSphere Portal, Liferay
>            Reporter: Shashank
>            Priority: Critical
>
> I want to make a tabular input along with validation. 
> For example:
> IN JSP:
> <% for (int i=0;i<=someBussinessLogicResultSet.size();i++) { %> 
>          <s:textfield name="mytext" />
> <% } %>
> <s:submit>
> Then in Action I wrote:
> @Validation
> public myaction extends ActionSupport{
> public String execute()
> {
> return SUCCESS;
> }
> @RequiredStringValidation(message="Please enter value in text box")
> public void getMytext() {return mytext;}
> public void setMytext(List mytext) {this.mytext=mytext;}
> private List mytext;
> }
> I know the above code will not work unless i remove the validations. 
> But however if I need a validation so that a error message is displayed on only those text fields which are left empty by the user, how can I do so??
> Although just for note I am not using scriplet as shown above but my text fiels are within display tags.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.