Home Analyst Portal

Filtered Config Item Picker for MAs (or any Activity)

Brian_WinterBrian_Winter Customer Advanced IT Monkey ✭✭✭

Any way to make a picker for just a single CI class, ala the User Picker? And have it located in a Manual Activity?

Best Answer

  • Brian_WinterBrian_Winter Customer Advanced IT Monkey ✭✭✭
    Answer ✓

    I think I found the silver bullet. I added

    Scoped: true,

    and it now seems that only the Class listed in ClassId is both visible and selectable. Still in the early testing stage, but this is looks very promising.

    🤞

Answers

  • Jan_SchulzJan_Schulz Customer Adept IT Monkey ✭✭

    Do you mean something like in the custom forms objectpicker. There you can configure the class guid which you can select in the picker. See custom forms https://cireson.com/how-to-create-custom-forms-for-the-cireson-portal/

  • Brian_WinterBrian_Winter Customer Advanced IT Monkey ✭✭✭

    That's a start. So I have 3 Related Config Items (new custom classes) a Function, CostCenter, and LegalEntity. Now, say, I have a tab that I want to show these 3 items, but separate object pickers. Here's my code for Function:

    {

                    name: "Function",

                    type: "multipleObjectPicker",

                    PropertyName: "RelatesToConfigItem",

                    ClassId: "85fea85a-d243-50bd-f496-565ed59389f1",

                    PropertyToDisplay: {DisplayName:"Function",Description:"Description"},

                    SelectableRow: true,

                    SelectProperty: "Function"

                  },

    However, this pulls back ALL Related Config Items, not just the Function. Please don't say "Type Projection" - I am woefully ignorant on how to do those.

  • Jan_SchulzJan_Schulz Customer Adept IT Monkey ✭✭

    @Brian_Winter If I understand your situation correctly, you are using the generic relation RelatesToConfigItem. However, in this case all configitems are returned, since through inheritance derived classes also correspond to a configitem. It would be best to use your own relation. Then only the desired items of the specific class are returned. Not to go into detail here, because I do not know the entire solution I would recommend in principle a separate relation in the created custom classes. These would then have to be made available to the desired form via typeprojection.

  • Brian_WinterBrian_Winter Customer Advanced IT Monkey ✭✭✭
    Answer ✓

    I think I found the silver bullet. I added

    Scoped: true,

    and it now seems that only the Class listed in ClassId is both visible and selectable. Still in the early testing stage, but this is looks very promising.

    🤞

  • Jan_SchulzJan_Schulz Customer Adept IT Monkey ✭✭

    @Brian_Winter this is new for me. Good to know :-). It would be nice if the information about custom forms would be better described from cireson.

  • Brian_WinterBrian_Winter Customer Advanced IT Monkey ✭✭✭

    Agreed 100% This is the only KA that I found: https://support.cireson.com/KnowledgeBase/View/51?seletedTab=enduser#heading-4-end-user

    While very helpful, it doesn't even mention the Scoped option. I found it digging around various OotB forms for Work and Config Items.

  • Brian_WinterBrian_Winter Customer Advanced IT Monkey ✭✭✭

    While I'm working in JSON forms, is there a way to define a simple list, "Yes", "No", "Maybe"?

  • Jan_SchulzJan_Schulz Customer Adept IT Monkey ✭✭

    i only know the way to use an existing enumeration list in the class of the form.

    If i were you i would open a new thread in this forum with this question.

  • Justin_WorkmanJustin_Workman Cireson Support Super IT Monkey ✭✭✭✭✭

    @Brian_Winter , are you just wanting a static list that's defined in the form but saves to an existing string property?

    Something like this:

    {DataType: "StringList", PropertyDisplayName: "My Custom String Field", PropertyName: "String01", Options: ["Alpha", "Beta", "Gamma"]}

    This doesn't exist, but would be pretty epic!

  • Brian_WinterBrian_Winter Customer Advanced IT Monkey ✭✭✭

    Damn You Justin!! 😠 I was on the way to copy/paste... and then I read the last sentence. 😭


    I guess it's create an enum and extend the SR/MA. 😔

Sign In or Register to comment.