while clicking on checkbox below error is thrown .How to resolve this issue
Could not display interface. Please check definition and inputs. Interface Definition: Expression evaluation error [evaluation ID = YNISEST2] : An error occurred while executing a save: Expression evaluation error: The save target must be a load() variable, process variable, or node input (or a rule input passed one of those three), but instead was: [selected=, pagingInfo=[startIndex=1, batchSize=-1, sort=[field=property_name, ascending=true]]]
I am attaching code below
= load( /*local!gridSelection: a!gridSelection( selected: local!existingUserPropertyIds, pagingInfo: a!pagingInfo( startIndex: 1, batchSize: - 1, sort: a!sortInfo( field: "property_name", ascending: true ) ) ), local!properties: a!queryEntity( entity: cons!OR_PROPERTY_INFO, query: a!query( pagingInfo: local!gridSelection.pagingInfo ), fetchTotalCount: true ),*/ a!sectionLayout( contents: { with( local!userDetails: if( isnull( ri!userId ), null, a!queryEntity( entity: cons!OR_USER, query: a!query( filter: a!queryFilter( field: "user_id", operator: "=", value: ri!userId ), pagingInfo: a!pagingInfo( startIndex: 1, batchSize: - 1 ) ) ).data ), a!boxLayout( label: "ADD NEW USER", contents: { a!columnsLayout( columns: { a!columnLayout( contents: { a!textField( label: "First Name", labelPosition: "ABOVE", placeholder: "First name", value: if( isnull( local!userDetails ), ri!userDetails.first_name, local!userDetails.first_name ), saveInto: ri!userDetails.first_name, refreshAfter: "UNFOCUS", required: true, requiredmessage: "Please enter first name", validations: {} ) } ), a!columnLayout( contents: { a!textField( label: "Last Name", labelPosition: "ABOVE", placeholder: "Last name", value: if( isnull( local!userDetails ), ri!userDetails.last_name, local!userDetails.last_name ), saveInto: ri!userDetails.last_name, refreshAfter: "UNFOCUS", required: true, requiredmessage: "Please enter last name", validations: {} ) } ) } ), a!columnsLayout( columns: { a!columnLayout( contents: { a!textField( label: "Email", labelPosition: "ABOVE", placeholder: "Email", value: if( isnull( local!userDetails ), ri!userDetails.primary_email, local!userDetails.primary_email ), saveInto: ri!userDetails.primary_email, refreshAfter: "UNFOCUS", required: true, requiredmessage: "Please enter email", validations: {} ) } ), a!columnLayout( contents: { a!dropdownField( label: "Role", labelPosition: "ABOVE", placeholderLabel: "--- Select a Role ---", choiceLabels: { "Owner", "Manager", "Resident" }, choiceValues: { cons!OWNER_ROLE_ID, cons!MANAGER_ROLE_ID, cons!RESIDENT_ROLE_ID }, value: if( isnull( local!userDetails ), ri!userDetails.role_id, local!userDetails.role_id ), saveInto: ri!userDetails.role_id, required: true, requiredmessage: "Please select role", validations: {} ) } ) } ) }, style: "STANDARD", marginBelow: "STANDARD" ) ), a!columnsLayout( columns: { a!columnLayout( contents: { a!richTextDisplayField( label: "", labelPosition: "COLLAPSED", value: { a!richTextHeader( text: "Select Properties" ) } ), with( local!existingUserPropertyMappingInfo: if( isnull( ri!userId ), {}, a!queryEntity( entity: cons!OR_USER_PROPERTY_INFO, query: a!query( filter: a!queryFilter( field: "user_id", operator: "=", value: ri!userId ), pagingInfo: a!pagingInfo( startIndex: 1, batchSize: - 1 ) ) ).data ), local!existingUserPropertyIds: { a!forEach( items: local!existingUserPropertyMappingInfo, expression: fv!item.property_id ) }, local!gridSelection: a!gridSelection( selected: local!existingUserPropertyIds, pagingInfo: a!pagingInfo( startIndex: 1, batchSize: - 1, sort: a!sortInfo( field: "property_name", ascending: true ) ) ), local!properties: a!queryEntity( entity: cons!OR_PROPERTY_INFO, query: a!query( pagingInfo: a!pagingInfo( startIndex: 1, batchSize: - 1, sort: a!sortInfo( field: "property_name", ascending: true ) ) ), fetchTotalCount: true ), a!gridField( label: "Select Properties", labelPosition: "COLLAPSED", totalCount: local!properties.totalCount, columns: { a!gridTextColumn( label: "Property Name", field: "property_name", data: index( local!properties.data, "property_name", {} ) ), a!gridTextColumn( label: "Address", field: "address_line1", data: index( local!properties.data, "address_line1", {} ) ) }, identifiers: local!properties.identifiers, value: local!gridSelection, saveInto: { local!gridSelection, a!save( ri!userPropertyInfo, a!forEach( items: local!gridSelection.selected, expression: { property_id: fv!item, is_active: 1, user_property_status: 1 } ) ) }, selection: true, selectionStyle: "CHECKBOX", shadeAlternateRows: true, rowHeader: 1 ) ), /*a!textField( label: "Selected Property IDs", value: if( length( local!gridSelection.selected ) = 0, "No Property selected", joinarray( local!gridSelection.selected, ", " ) ), readOnly: true )*/ } ) } ), a!columnsLayout( columns: { a!columnLayout( contents: { a!buttonArrayLayout( buttons: { a!buttonWidget( label: "Cancel", style: "NORMAL", saveInto: { a!save( target: ri!actionEvent, value: "listUsers" ), a!save( target: ri!userId, value: null ) } ), a!buttonWidget( label: "Save", submit: true, style: "PRIMARY", disabled: false ) }, align: "END" ) } ) } ) } ) )
Discussion posts and replies are publicly visible