Process Mapping Logo

Process Mapping - Forums

Sharing 19 years of knowledge and experience

 
Metastorm BPM forums
Sign up Latest Topics
 
 
 


Reply
  Author   Comment  
edayvie

New Member
Registered:
Posts: 2
Reply with quote  #1 
Does anyone know a way to change this conditionally maybe with a code activity command?
In the component properties is is called 'default action behavior' .. optional, required, read only, hidden. 

I'm trying to do something like this when a field is changed:

If processbuisnesobject.variable = "something" then field1 is read-only.


Thanks
0
JoeOmerta

Veteran
Registered:
Posts: 210
Reply with quote  #2 
I have something similar i believe...

$find("input_field").editor.disable(); //This greys out an item so they can't modify it anymore.


Then to require something based on another field you can throw in this...

if(whatever)
{
   if(RequiredField("input_field","Please enter input_field"))
   {
       return true;
    }
}
0
praxkan

Veteran
Registered:
Posts: 142
Reply with quote  #3 
No supported way to do it. Javascript/jquery like Joe's method above is one way to do it.

The "supported" way to do this was overlay read only (dummy) fields over/under the real fields, and then on a certain condition being true - hide the real field and show the dummy field.

Sad workaround...yes.
0
edayvie

New Member
Registered:
Posts: 2
Reply with quote  #4 
Thanks for the help.  I used the "supported" way in a few places, but for the most part have found the  $find script example to be simpler.  I use either a conditional else with a enable or put a corresponding enable in 'On field entry' to prevent someone locking themselves out of the field but clicking the wrong dropdown item. 



with input_field properties 'Required' I'll do something like this:

var  inputvalue = eworkGetField("input_field","value");
if(inputvalue == "disable something")
{
$find("something").editor.disable();
eworkSetField("something","value","n/a");
}
else
{
$find("something").editor.enable();
eworkSetField("something","value","");
}


The only limitation I have found is it doesn't seem to work with radio groups. 

Thanks Again

0
Previous Topic | Next Topic
Print
Reply

Quick Navigation:


Create your own forum with Website Toolbox!