|
| Convert MVText on Request Form to MVDN on Approval form. |
 |
Sat, 10 May 2008 21:19:13 GMT |
Workflow involves parents asking for access to student records. Customer
desires parents not be allowed to search for student in directory, but
rather request access based on 6 digit Student ID's, which will then be
verified by an approver before access is granted.
On request form, parent is allowed to enter multiple student ID's into an
MVEditor, String.
I'd like to convert this so that on the approval form the ID's entered as
text have been resolved to the DN's which those ID's represent (the ID is
conveniently identical to the CN of the user object). The reason I want
this converted is that ultimately I will write a multi-valued DN attribute
to the user, associating students to the parent object, a'la Direct Reports
to Manager.
I'm assuming I have to do a pre-activity data mapping with a query to
determine the DN for each CN. Not having much luck. Also, since a parent
can enter more than one student, does this mean that the mapping activity
will involve some looping on the flowdata object, to bring back a DN for
each student ID entered?
Help? :-0
Thanks,
Rob
|
| Post Reply
|
| Re: Convert MVText on Request Form to MVDN on Approval form. |
 |
Sun, 11 May 2008 12:46:02 GMT |
Hi Rob,
Sounds like you will need to do some pre activity code on the flowdata
for the approval form.
You will need to do something like this.....
var studentCodes = flowdata.getObject(<path-to-start-form-control>);
for (i=0, studentCodes.length > i; i++) {
var tmpCode = studentCodes[i];
// Now validate the student codes exist
}
make not of the getObject()...this is used to get all values from a
form control, not just the first one selected.
You will then need to return an array of DN's from the function. Here
is a code snipit.
function returnArray() {
var retArray = new Array()
retArray[1] = "CN=1000001,OU=Students,=SCHOOL");
retArray[2] = "CN=1000002,OU=Students,=SCHOOL");
return retArray;
}
returnArray();
Work the above code into the logic for validating ther student
numbers.
The above code is of the top of my head without any vilidation so make
sure that it is syntactically correct.
Hope that helps.
Cheers
Rowan
Rob.S;1554990 Wrote:
> Workflow involves parents asking for access to student records.
> Customer
> desires parents not be allowed to search for student in directory, but
> rather request access based on 6 digit Student ID's, which will then
> be
> verified by an approver before access is granted.
>
> On request form, parent is allowed to enter multiple student ID's into
> an
> MVEditor, String.
>
> I'd like to convert this so that on the approval form the ID's entered
> as
> text have been resolved to the DN's which those ID's represent (the ID
> is
> conveniently identical to the CN of the user object). The reason I
> want
> this converted is that ultimately I will write a multi-valued DN
> attribute
> to the user, associating students to the parent object, a'la Direct
> Reports
> to Manager.
>
> I'm assuming I have to do a pre-activity data mapping with a query to
> determine the DN for each CN. Not having much luck. Also, since a
> parent
> can enter more than one student, does this mean that the mapping
> activity
> will involve some looping on the flowdata object, to bring back a DN
> for
> each student ID entered?
>
> Help? :-0
>
> Thanks,
>
> Rob
--
Misterwippy
------------------------------------------------------------------------
Misterwippy's Profile: http://forums.novell.com/member.php?userid=170
View this thread: http://forums.novell.com/showthread.php?t=327439
|
| Post Reply
|
| Re: Convert MVText on Request Form to MVDN on Approval form. |
 |
Mon, 12 May 2008 02:37:34 GMT |
Thanks... I'll take a crack at adapting this in the morning, and then either
report on success, or post what I've tried that isn't quite cutting it.
R.
"Misterwippy" <Misterwippy@no-mx.forums.novell.com> wrote in
message
news:Misterwippy.398xun@no-mx.forums.novell.com...
>
> Hi Rob,
>
> Sounds like you will need to do some pre activity code on the flowdata
> for the approval form.
>
> You will need to do something like this.....
>
>
> var studentCodes = flowdata.getObject(<path-to-start-form-control>);
>
> for (i=0, studentCodes.length > i; i++) {
>
> var tmpCode = studentCodes[i];
>
> // Now validate the student codes exist
>
> }
>
>
> make not of the getObject()...this is used to get all values from a
> form control, not just the first one selected.
>
> You will then need to return an array of DN's from the function. Here
> is a code snipit.
>
> function returnArray() {
>
> var retArray = new Array()
>
> retArray[1] = "CN=1000001,OU=Students,=SCHOOL");
> retArray[2] = "CN=1000002,OU=Students,=SCHOOL");
>
> return retArray;
>
> }
>
> returnArray();
>
> Work the above code into the logic for validating ther student
> numbers.
>
> The above code is of the top of my head without any vilidation so make
> sure that it is syntactically correct.
>
> Hope that helps.
>
> Cheers
>
> Rowan
>
>
> Rob.S;1554990 Wrote:
>> Workflow involves parents asking for access to student records.
>> Customer
>> desires parents not be allowed to search for student in directory, but
>> rather request access based on 6 digit Student ID's, which will then
>> be
>> verified by an approver before access is granted.
>>
>> On request form, parent is allowed to enter multiple student ID's into
>> an
>> MVEditor, String.
>>
>> I'd like to convert this so that on the approval form the ID's entered
>> as
>> text have been resolved to the DN's which those ID's represent (the ID
>> is
>> conveniently identical to the CN of the user object). The reason I
>> want
>> this converted is that ultimately I will write a multi-valued DN
>> attribute
>> to the user, associating students to the parent object, a'la Direct
>> Reports
>> to Manager.
>>
>> I'm assuming I have to do a pre-activity data mapping with a query to
>> determine the DN for each CN. Not having much luck. Also, since a
>> parent
>> can enter more than one student, does this mean that the mapping
>> activity
>> will involve some looping on the flowdata object, to bring back a DN
>> for
>> each student ID entered?
>>
>> Help? :-0
>>
>> Thanks,
>>
>> Rob
>
>
> --
> Misterwippy
> ------------------------------------------------------------------------
> Misterwippy's Profile: http://forums.novell.com/member.php?userid=170
> View this thread: http://forums.novell.com/showthread.php?t=327439
>
|
| Post Reply
|
| Re: Convert MVText on Request Form to MVDN on Approval form. |
 |
Mon, 12 May 2008 10:24:06 GMT |
On 05/11/2008 07:46 AM, Misterwippy wrote:
> Hi Rob,
>
> Sounds like you will need to do some pre activity code on the flowdata
> for the approval form.
>
> You will need to do something like this.....
>
>
> var studentCodes = flowdata.getObject(<path-to-start-form-control>);
>
> for (i=0, studentCodes.length > i; i++) {
>
> var tmpCode = studentCodes[i];
>
> // Now validate the student codes exist
>
> }
>
>
> make not of the getObject()...this is used to get all values from a
> form control, not just the first one selected.
>
> You will then need to return an array of DN's from the function. Here
> is a code snipit.
>
> function returnArray() {
>
> var retArray = new Array()
>
> retArray[1] = "CN=1000001,OU=Students,=SCHOOL");
> retArray[2] = "CN=1000002,OU=Students,=SCHOOL");
>
> return retArray;
>
> }
>
> returnArray();
>
> Work the above code into the logic for validating ther student
> numbers.
>
> The above code is of the top of my head without any vilidation so make
> sure that it is syntactically correct.
>
> Hope that helps.
>
> Cheers
>
> Rowan
>
>
I would suggest using a Mapping Activity instead of the pre-mapping in
the approval. Build your data set before you get to the approval.
Because doing it in the pre-activity will slow down the form being
presented to the user.
|
| Post Reply
|
|
|