So, you're saying that effectiveDate is requiredif state == 940?
Try adding [0] to the end of the field* vars.
David
Is it possible to require a field based on the value of another field? I
tried the following, but no dice:
field property=effectiveDate
So, you're saying that effectiveDate is requiredif state == 940?
Yep.
Try adding [0] to the end of the field* vars.
That worked - thanks! I've hacked together some client-side javascript for
this since there's not one in the validator natively - I'll try to work a
method up for equals.
Smoak [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 12:41 PM
To: 'Struts Users Mailing List'
Subject: RE: [VALIDATOR] requiredif ??
I'm Still struggling with requiredif... there doesn't seem to be a working
example of it included with 1.1b3. I've gone through the documentation
I'm Still struggling with requiredif... there doesn't seem to be a working
example of it included with 1.1b3. I've gone through the documentation and
come up with this. I'm trying to say that address is required only if
1. prospect is null
2. prospectNameOrId is not null
3. action is not
(0)207-375-4923
-Original Message-
From: Wendy Smoak [mailto:[EMAIL PROTECTED]]
Sent: 30 January 2003 17:41
To: 'Struts Users Mailing List'
Subject: RE: [VALIDATOR] requiredif ??
I'm Still struggling with requiredif... there doesn't seem to
be a working
example
: [VALIDATOR] requiredif ??
I'm Still struggling with requiredif... there doesn't seem to
be a working example of it included with 1.1b3. I've gone
through the documentation and come up with this. I'm trying
to say that address is required only if
1. prospect is null
2
Man, that looks convoluted.
Sri
-Original Message-
From: PILGRIM, Peter, FM [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 1:03 PM
To: 'Struts Users Mailing List'
Subject: RE: [VALIDATOR] requiredif ??
In the Struts User Guide there is a large example
From: Sri Sankaran [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 2:30 PM
To: Struts Users Mailing List
Subject: RE: [VALIDATOR] requiredif ??
Man, that looks convoluted.
Sri
Well, short of implementing a full boolean expression language inside
Validator, it was the best
Message-
From: James Turner [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 2:39 PM
To: 'Struts Users Mailing List'
Subject: RE: [VALIDATOR] requiredif ??
From: Sri Sankaran [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 2:30 PM
To: Struts Users Mailing
:55 -0500
Sri Sankaran [EMAIL PROTECTED] wrote:
Man, that looks convoluted.
Sri
-Original Message-
From: PILGRIM, Peter, FM [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 1:03 PM
To: 'Struts Users Mailing List'
Subject: RE: [VALIDATOR] requiredif ??
In the Struts User Guide
James wrote:
A quick look at that configuration looks correct. Let me know if it
doesn't work for you.
No, it doesn't. It's as if that rule isn't even there-- if there is no
prospect, and there is a prospect name, even if the address is blank, it
passes validation and goes to the next step.
From: Wendy Smoak [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 2:44 PM
To: 'Struts Users Mailing List'
Subject: RE: [VALIDATOR] requiredif ??
James wrote:
A quick look at that configuration looks correct. Let me know if it
doesn't work for you.
No, it doesn't
James wrote:
Dumb question: Are you sure you're running validations at all?
Yes. I have some simple validations like:
field property=newEmailAddress
depends=email
arg0 key=label.additional.email/
/field
and
fieldproperty=date
:39 AM
To: 'Struts Users Mailing List'
Subject: RE: [VALIDATOR] requiredif ??
From: Sri Sankaran [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 2:30 PM
To: Struts Users Mailing List
Subject: RE: [VALIDATOR] requiredif ??
Man, that looks convoluted.
Sri
Well, short
From: Karr, David [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 30, 2003 6:05 PM
To: Struts Users Mailing List
Subject: RE: [VALIDATOR] requiredif ??
Gee, I haven't been paying much attention to this issue, but
that looks like there could be some synergy with the JSTL EL
engine
On Thu, 30 Jan 2003, James Turner wrote:
Date: Thu, 30 Jan 2003 19:06:19 -0500
From: James Turner [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: [VALIDATOR] requiredif ??
From: Karr, David [mailto
Michelle Wynn wrote:
Has anyone had any success validating conditionally with requiredIf
client-side? There does not seem to have been a javascript method created
for this validation method. I looked in 1.1B and the most recent nightly
build. Also haven't had success validating server side
Requiredif doesn't implement client-side validation, to my mind it would
be too hard to come up with a mechanism to generate Javascript for the
fairly complex cases you can generate using it. If someone wants to
take a crack at writing it, feel free.
James
-Original Message-
From:
18 matches
Mail list logo