Highlighted
Acclaimed Contributor.
Acclaimed Contributor.
998 views

User select in catalog. Condition for dynamic field.

Is it possible to set condition for user selection for dynamic field.

For example if it's field from contacts table and i need user can only select from contacts wich have flag active in contact table.

0 Likes
9 Replies
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: User select in catalog. Condition for dynamic field.

Hello,

In former versions user selections (if you mean ess Service catalog) had  quite limited configuration possibilities. You could have specified only the table from which data should be chosen in the user selection field but I don't recall that you could have set any condition above it (at least with standard functionality).

Highlighted
Honored Contributor.
Honored Contributor.

Re: User select in catalog. Condition for dynamic field.

Am not sure if I understand it right? but I remember having a user selection for "device" table that would only let a user select those CI's with a specific "subtype". So, in your case, they can only select a contact with a field "flag"= active?

If yes, set a condition in Query field in Dynamic field validations of the catalog item.

 

Highlighted
Acclaimed Contributor.
Acclaimed Contributor.

Re: User select in catalog. Condition for dynamic field.

 Vadim Gorda

No ability even set condition in some script like "ScAPI*" ?

 SandyAdmin

I mean when some user go to ServiceCatalog and some item in catalog ask to select for some user from CONTACTS table (user selection in model, where set dynamic field related to contact.name field in contacts table)

And i need to display in such search from contacts table only records (only contact.name) which have true in field active

 

See attach.

0 Likes
Highlighted
Honored Contributor.
Honored Contributor.

Re: User select in catalog. Condition for dynamic field.

Then, just set a query under catalog item Dynamic Field Validations 

Validation Rule: Record in Table

Field Name: Contact Name

Query: active="true"

This is expected to display only Contact records having active=true when you click on the dropdown. Please note I'm using 9.x HPSM.

0 Likes
Highlighted
Acclaimed Contributor.
Acclaimed Contributor.

Re: User select in catalog. Condition for dynamic field.

My SM is 9.3 and i have not query in setting for dynamic field (only table name and name of field)

0 Likes
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: User select in catalog. Condition for dynamic field.

Hello Alarmus,

I think you were talking about Service catalog ordering process which had (as i said i have not done taioring for quyet long) vey limited tailoring opportunities including absense of format control, links etc.

As i remember dvd is not an option as well as ifields are populated on form based on Item options which you set in the Item definition so you can not tie classic form based DVD for the field.

Regarding scripting - we were doing it in foreground as nothig was workibg on front.

0 Likes
Highlighted
Acclaimed Contributor.
Acclaimed Contributor.

Re: User select in catalog. Condition for dynamic field.

Just there is 2 places: "Service Assistant -Select Employee " and "Approval delegation - Delegate to" where you choose contact from contacts table, wich have some other interface to enter contact data (3 lines) - but i can set condition for this in sl=ScAPI_svcCatOperator in function getOperatorByCompany() -> set new query

 

that's why I believed that it is possible to put conditions in this place (user selection in catalog item), too

0 Likes
Highlighted
Acclaimed Contributor.. Acclaimed Contributor..
Acclaimed Contributor..

Re: User select in catalog. Condition for dynamic field.

Hello,

If i got you right these are scripts which select data from contact table for adding to Approval (Initial approve of SD, approval of requesters manager or similar). But that script was working after you were trying to add Interaction and not while you are chosing data in the elements on the form itself (not applicable for on form logic).

Again i might be wrong.

0 Likes
Highlighted
Acclaimed Contributor.
Acclaimed Contributor.

Re: User select in catalog. Condition for dynamic field.

that example with 2 places work while you are chosing data in the elements on the form itself.

That why hope that there is same method for user selection on form in catalog.

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.