I am using the new obsolete definition with v9.2, I have a requirement to display request parameter 'valid until' whose maximum value can be 'valid from' + 7 days.
can someone assist me with the valuation script that can be used in this case.
I am using the new obsolete definition with v9.2, I have a requirement to display request parameter 'valid until' whose maximum value can be 'valid from' + 7 days.
can someone assist me with the valuation script that can be used in this case.
Why don't you just set (Max. days valid = 7) on the Service Item?
AccProduct.MaxValidDays
i am using the request property with new style definition. How do i declare the column values of table (AccProduct.MaxValidDays) in my validation script? I know to do this with the obsolete definition.
Ex. you give the parameter name the same name as the colomn ex: ValidUntil
Valuation script : Value = Provider.GetValue(Of Date)("ValidFrom").AddDays(7)
Validation script: If Provider.GetValue(Of Date)("ValidUntil") > Provider.GetValue(Of Date)("ValidFrom").AddDays(7) Then
Throw New ViException("Some text...", ExceptionRelevance.EndUser)
End If
Also look at these post:
https://www.oneidentity.com/community/identity-manager/f/forum/38481/mandatory-fields-in-angular-web-portal/90225
https://www.oneidentity.com/community/identity-manager/f/forum/37044/version-9-2--request-property-validation-and-how-to-get-parametervalues-into-a-process-from-dialogparameter/87604
https://www.oneidentity.com/community/identity-manager/f/forum/38603/request-properties-new-style-change-parameter-type-dynamically
Thanks for your response! However, This is still not working. Maybe there is some problem with the 'valid from' valuation script (below) i am using here.
the requirement is to enforce that the "Valid From" date is always set to today's date (request date) even if the user selects a different date. can you help me with the valuation script & validation script here? Maybe i can try the valid Until later once this is fixed.
Thanks for your response! However, This is still not working. Maybe there is some problem with the 'valid from' valuation script (below) i am using here.
the requirement is to enforce that the "Valid From" date is always set to today's date (request date) even if the user selects a different date. can you help me with the valuation script & validation script here? Maybe i can try the valid Until later once this is fixed.
I thought it would work, but I can also confirm that it doesn't.
It does something when set to Parameter type = 'User prompt' but does nothing when set to = 'Fix'.
Don't know if this is a bug or this approach is just a glitch.
Don't have time to investigate right now
As a work-around maybe you could do something with the value temple of ShoppingCartItem.ValidFrom
Just rough example
If String.Equals("56b0630e-05ca-4227-a2d7-5de6d916dafa", Provider.GetValue(Of String)("UID_AccProduct"), StringComparison.Ordinal) Then Value = DateTime.Today.AddTicks(1) End If
Thanks, i cannot use the column templates because i need few customized parameters that returns all the userid the logged in user has , i couldnot achieve it with obsolete definition hence used the non-obsolete one which has more options to customize.