Knowledge Partner
Knowledge Partner
201 views

This workflow will self destruct....

Any thoughts on a way in a PRD form, to allow say, three tries at
picking some values, and on fourth, pull an Inspector Gadget and kill
the WF? I do not want to throw a 'red' error, I would rather 'end' the
workflow somehow.

Not sure if there is a simple way to do it? (IDM 4.01 or 4.02).
Labels (1)
0 Likes
7 Replies
Anonymous_User Absent Member.
Absent Member.

Re: This workflow will self destruct....


First question: How would you 'end' a workflow from a form script? I do
not think that is directly possible. SO... fire an event called KillWF
(or some other descriptive or obfuscated name) which sets a value in a
hidden field, submits the form. The next activity would test for the
hidden field "secret value" and proceed directly to the exit (or perhaps
log the event, then get out), do not pass Go, do not collect $200.00.
No "secret value", proceed as directed to The Island.

Still trying to get a handle on how to submit the form from within the
field code. I seem to recall doing that at one time, but I cannot find
the specific workflow in my storehouse of Designer Projects.


--
TSE7147N
------------------------------------------------------------------------
TSE7147N's Profile: https://forums.netiq.com/member.php?userid=5309
View this thread: https://forums.netiq.com/showthread.php?t=48756

0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: This workflow will self destruct....


TSE7147N;234376 Wrote:
> First question: How would you 'end' a workflow from a form script? I do
> not think that is directly possible. SO... fire an event called KillWF
> (or some other descriptive or obfuscated name) which sets a value in a
> hidden field, submits the form. The next activity would test for the
> hidden field "secret value" and proceed directly to the exit (or perhaps
> log the event, then get out), do not pass Go, do not collect $200.00.
> No "secret value", proceed as directed to The Island.
>
> Still trying to get a handle on how to submit the form from within the
> field code. I seem to recall doing that at one time, but I cannot find
> the specific workflow in my storehouse of Designer Projects.

There is the 'form.submit(/*string*/ action)'
(https://www.novell.com/coolsolutions/appnote/19307.html) function to
submit the form programmatically. I haven't test it though. Usually I
use jQuery like this:
Code:
--------------------
$("#SubmitAction1").click(); //It is needed to enable jQuery from the form scripts tab.
--------------------


--
hello_amigo
------------------------------------------------------------------------
hello_amigo's Profile: https://forums.netiq.com/member.php?userid=211
View this thread: https://forums.netiq.com/showthread.php?t=48756

0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: This workflow will self destruct....

Hi Geoff,

it depends on a couple of things, e.g., the form type, and security
concerns:

In a request form, the workflow process actually hasn't started yet.
"Ending" would be no more than closing/cancelling the form.

In an approval form, things may depend on your validation logic. If its
all client/browser based, you could call REST to terminate the process,
but you have the potential risk of user data tampering and preventing
your measures.
If you have client-server logic in the approval form (like Ajax input
validation), your "Inspector" could call SOAP to terminate the process.

Then, if you need to count invalid attempts, you might rely on the
client to count (tamper risk), or create some server/session based counter.

Sounds like fun

Wolfgang

On 23.09.2013 23:42, Geoffrey Carman wrote:
> Any thoughts on a way in a PRD form, to allow say, three tries at
> picking some values, and on fourth, pull an Inspector Gadget and kill
> the WF? I do not want to throw a 'red' error, I would rather 'end' the
> workflow somehow.
>
> Not sure if there is a simple way to do it? (IDM 4.01 or 4.02).

0 Likes
Knowledge Partner
Knowledge Partner

Re: This workflow will self destruct....

> it depends on a couple of things, e.g., the form type, and security
> concerns:


Good points.

> In a request form, the workflow process actually hasn't started yet.
> "Ending" would be no more than closing/cancelling the form.


This case was Request form. Basically there are some data fields that
get validated, but we would like to make it harder to keep trying
numbers to guess valid values. So maybe limit it to 3 tries before
restarting the form.

Which is only a minor slow down, since they can reopen the form as often
as they want...

Is there a function in teh Request form to call cancel?

> In an approval form, things may depend on your validation logic. If its
> all client/browser based, you could call REST to terminate the process,
> but you have the potential risk of user data tampering and preventing
> your measures.


Good points.

> If you have client-server logic in the approval form (like Ajax input
> validation), your "Inspector" could call SOAP to terminate the process.
>
> Then, if you need to count invalid attempts, you might rely on the
> client to count (tamper risk), or create some server/session based counter.
>
> Sounds like fun
>
> Wolfgang
>
> On 23.09.2013 23:42, Geoffrey Carman wrote:
>> Any thoughts on a way in a PRD form, to allow say, three tries at
>> picking some values, and on fourth, pull an Inspector Gadget and kill
>> the WF? I do not want to throw a 'red' error, I would rather 'end' the
>> workflow somehow.
>>
>> Not sure if there is a simple way to do it? (IDM 4.01 or 4.02).


0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: This workflow will self destruct....


On 24.09.2013 19:13, Geoffrey Carman wrote:
>
> Is there a function in the Request form to call cancel?
>


There's no official or supported way that I'm aware of.

Therefor the effect of such functions may depend on browser version,
UserApp version, if called from a Request Portlet, if there's an "R" in
the month, and you name it.

If you look into a debugger, you'll see that the Cancel button calls a
script function like
CancelAction1Click( "CancelAction1" );

Calling DOM might also do it the rude way - just like F5:
window.top.parent.location.href="http://172.17.2.91:8180/IDMProv";


Wolfgang
0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: This workflow will self destruct....


This might be more effective method to “make it harder to keep
trying” than a self destruct workflow…

Trow this in 'green':


Warning: You have now entered data incorrectly tree times.

One more failed attempt and your Manager will automatically get an email
on your inability to enter data correctly!



Never liked them 'red' error messages either too 'PC'

Just a thought, 🐵


--
gholdefe
------------------------------------------------------------------------
gholdefe's Profile: https://forums.netiq.com/member.php?userid=318
View this thread: https://forums.netiq.com/showthread.php?t=48756

0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: This workflow will self destruct....


Wolfgang Schreiber;234434 Wrote:
> Hi Geoff,
>
> it depends on a couple of things, e.g., the form type, and security
> concerns:
>
> In a request form, the workflow process actually hasn't started yet.
> "Ending" would be no more than closing/cancelling the form.
>
> In an approval form, things may depend on your validation logic. If its
> all client/browser based, you could call REST to terminate the process,
> but you have the potential risk of user data tampering and preventing
> your measures.
> If you have client-server logic in the approval form (like Ajax input
> validation), your "Inspector" could call SOAP to terminate the process.
>
> Then, if you need to count invalid attempts, you might rely on the
> client to count (tamper risk), or create some server/session based
> counter.
>
> Sounds like fun
>
> Wolfgang
>
> On 23.09.2013 23:42, Geoffrey Carman wrote:
> > Any thoughts on a way in a PRD form, to allow say, three tries at
> > picking some values, and on fourth, pull an Inspector Gadget and kill
> > the WF? I do not want to throw a 'red' error, I would rather 'end'

> the
> > workflow somehow.
> >
> > Not sure if there is a simple way to do it? (IDM 4.01 or 4.02).


Could you somehow detect the X attempts and put it into a pending state
via the workflow (ie: On X error, put request into pending or
something) and write an attribute on the user object so that NAM could
redirect or prevent multiple attempts?

Just asking.

Or are we better off dumping IDM and custom-writing our own validation
stuff if IDM can't do this on the forms?


--
kjhurni
------------------------------------------------------------------------
kjhurni's Profile: https://forums.netiq.com/member.php?userid=322
View this thread: https://forums.netiq.com/showthread.php?t=48756

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.