There is a problem, with BLC 2.2.1-SNAPSHOT (not tried with previous BLC version) when you create a customer rule on a page :
url : http://i.imgur.com/eVUAxPv.png
Below the expression saved in database :
When i try to access at the page, an exception is thrown :
Code: Select all
[ERROR] 13:25:48 AbstractPageRuleProcessor - [Error: unable to resolve method: java.lang.String.getType() [arglength=0]]
[Near : {... Unknown ....}]
^
[Line: 1, Column: 0]
The problem is due to the ".getType()" in the MVEL expression. If i replace : customer.type.getType()=="BUSINESS" BY
customer.type=="BUSINESS" it works perfectly.
Just for your information "CustomerType" is a BroadleafEnumeration. I tried with others BroadleafEnumerations and each time the MVEL expression contains ".getType()".
It's certainly a bug when you save a MVEL expression which contains a BroadleafEnumeration.
Thanks in advance