Hi, so when i was testing the summary view interface using a query rule to get customer info by iD. I got this kind of message. How to solve this? Thank you
Expression evaluation error at function a!eval_inputMapWithTypes_ruleInputCast [line 42]: Could not cast from List of Variant to SJ Customer. Details: CastInvalidCould not cast from List of Variant to SJ Customer. Details: CastInvalid
Discussion posts and replies are publicly visible
sallyjoyg0002 Please try this
a!queryRecordType( recordType: 'recordType!ISJ_CM_Customer_Record', /*(Your Record Type)*/ filters: a!queryFilter( field: 'recordType!SJ_CM_Customer_Record.customerID', /*(Your Record Type Field)*/ operator: "=", value: ri!customerID /*(Your rule input)*/ ), pagingInfo: a!pagingInfo( startIndex: 1, batchSize: 1 ) ).data
Try with creating a new expression rule with Adding you record type with above shown example add record field and compare with rule input to follow above example and check again with using this rule.
Thank you that worked. Just a follow up question, i have a set of docu images in a folder but in my records, its contained in an integer variable (the folder id of the image). How do i retrieve the image in an interface?
thank you
Hello,Below might be useful!a!localVariables( local!images_cdt: folder(ri!idOfFolder, "documentChildren"), { a!imageField( images: a!forEach( items: local!images_cdt, expression: a!documentImage(document: fv!item) ) ), /* OR */ a!richTextDisplayField( value: a!forEach( items: local!images_cdt, expression: a!richTextImage(a!documentImage(document: fv!item)) ) ) })
Use this code in your display value of column field of your record where you see document id in integer
a!imageField( images: a!documentImage( document: fv!row[SJ_CM_Customer_Record.docImage], /*(Your Record Type Field)*/ size: "SMALL")
There is still an error