A dropdown component [label="Type"] has an invalid value for "value". All selected values must be present in the choiceValues array, but value was and choiceValues was 117; 118. (APNX-1-4198-000)

Getting above error how to resolve .. as value is null ..

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Senior Developer

    a!dropdownField(
                    label: "Select " & cons!TTP_CONFIG_DISPLAY_VALUES[3],
                    labelPosition: "ABOVE",
                    placeholder: "Select a Data",
                    choiceLabels: local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{022666ad-2a5e-48b1-a87a-a30eee29b231}firstName'],
                    choiceValues: local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{7cefb235-e416-4c2f-b471-dc52652e4b18}clientId'],
                    value: if(
                      and(
                        a!isNotNullOrEmpty(
                          local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{7cefb235-e416-4c2f-b471-dc52652e4b18}clientId']
                        ),
                        contains(
                          local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{7cefb235-e416-4c2f-b471-dc52652e4b18}clientId'],
                          ri!request.clientId
                        )
                      ),
                      ri!request.clientId,
                      null()
                    ),
                    saveInto: {
                      a!save(ri!request.clientid, save!value),
                      a!save(ri!request.consumerid, null())
                    },
                    searchDisplay: "AUTO",
                    
                    required: true,
                   
                    validations: {}
                  )

    Check the above code

    You can use index function instead of a!isnullOrEmpty

    index(recordType!Department(name: "Engineering"), recordType!Department.fields.name, "")

    link: docs.appian.com/.../fnc_array_index.html

Reply
  • 0
    Certified Senior Developer

    a!dropdownField(
                    label: "Select " & cons!TTP_CONFIG_DISPLAY_VALUES[3],
                    labelPosition: "ABOVE",
                    placeholder: "Select a Data",
                    choiceLabels: local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{022666ad-2a5e-48b1-a87a-a30eee29b231}firstName'],
                    choiceValues: local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{7cefb235-e416-4c2f-b471-dc52652e4b18}clientId'],
                    value: if(
                      and(
                        a!isNotNullOrEmpty(
                          local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{7cefb235-e416-4c2f-b471-dc52652e4b18}clientId']
                        ),
                        contains(
                          local!client['recordType!{a3480fb1-15c0-4549-8121-7b4bfe485728}TTP Client.fields.{7cefb235-e416-4c2f-b471-dc52652e4b18}clientId'],
                          ri!request.clientId
                        )
                      ),
                      ri!request.clientId,
                      null()
                    ),
                    saveInto: {
                      a!save(ri!request.clientid, save!value),
                      a!save(ri!request.consumerid, null())
                    },
                    searchDisplay: "AUTO",
                    
                    required: true,
                   
                    validations: {}
                  )

    Check the above code

    You can use index function instead of a!isnullOrEmpty

    index(recordType!Department(name: "Engineering"), recordType!Department.fields.name, "")

    link: docs.appian.com/.../fnc_array_index.html

Children
No Data