Getting an error on user filter "Build An Application: Step 6"

I'm going through the Appian Developer's course, and am not able to get through "Build An Application: Step 6". I'm getting a "Invalid index: Cannot index property 'vehicleMake' of type Text into type RecordType]." Can't figure out where the bug's coming from since I'm just copying the code straight out of the exercise. Here's the code for the filter:

a!recordFilterList(
name: "Make",
options: a!forEach(
items: local!vehicleMakes.data,
expression: a!recordFilterListOption(
id: fv!index,
name: fv!item.make,
filter: a!queryFilter(
field: 'recordType!AE Vehicle'.vehicleMake,
operator: "=",
value: fv!item.make
),
dataCount: fv!item.count
)
)

Any ideas for why this is wrong?

  Discussion posts and replies are publicly visible

Parents Reply
  • Hi Peter, thanks.

    Here's the rest of the code, before the recordFilterList, and where the locals are defined:

    a!localVariables(
    local!vehicleMakes: a!queryRecordType (
    recordType: 'recordType!AE Vehicle',
    fields: a!aggregationFields(
    groupings: {
    a!grouping(
    Field: 'recordType!AE Vehicle.fields.vehicleMake',
    alias: "make"
    )
    },
    measures: {
    a!measure(
    field: 'recordType!AE Vehicle.fields.vehicleMake',
    function: "COUNT",
    alias: "count"
    )
    }
    ),
    pagingInfo: a!pagingInfo(
    startIndex: 1,
    batchSize: 5000
    )
    ),

Children