[jira] [Commented] (OFBIZ-7213) Override allow-html attribute do not work in service implementing any interface

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Commented] (OFBIZ-7213) Override allow-html attribute do not work in service implementing any interface

Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-7213?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15326234#comment-15326234 ]

Deepak Dixit commented on OFBIZ-7213:
-------------------------------------

This has been done at

Trunk at r#1747959
15.12 at r#1747960
14.12 at r#1747961
13.07 at r#1747962

Thanks Nameet for you contribution.

> Override allow-html attribute do not work in service implementing any interface
> -------------------------------------------------------------------------------
>
>                 Key: OFBIZ-7213
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-7213
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: Trunk
>            Reporter: Nameet Jain
>            Assignee: Deepak Dixit
>            Priority: Critical
>         Attachments: OFBIZ-7213.patch
>
>
> To test I used an interface say "testInterface". Try as shown below
> =============Add test interface and service =========
> {code}
>     <service name="testInterface" engine="interface">
>         <attribute name="testData" type="String" mode="IN" optional="true"/>
>     </service>
>     <service name="checkAllowHtmlForOverride" engine="java" location="org.ofbiz.order.order.OrderServices" invoke="checkAllowHtmlForOverride">
>         <implements service="testInterface"/>
>         <override name="testData" allow-html="any" ></override>
>     </service>
> {code}
> ===================================
> Add service definition for the service "checkAllowHtmlForOverride"  in "org.ofbiz.order.order.OrderServices".
> {code}
> public static Map<String, Object> checkAllowHtmlForOverride(DispatchContext dctx, Map<String, ? extends Object> context) {
>         String testData = (String) context.get("testData");
>         Debug.log("==============" + testData);
>         return ServiceUtil.returnSuccess();
>     }
> {code}
> Run service "checkAllowHtmlForOverride" from service engine.
> {code}
> *Exception :*
>      [java] 2016-06-07 19:07:38,429 |http-nio-8443-exec-9 |ServiceDispatcher             |E| Incoming context (in runSync : checkAllowHtmlForOverride) does not match expected requirements
>      [java] org.ofbiz.service.ServiceValidationException: In field [testData] less-than (<) and greater-than (>) symbols are not allowed.
>      [java] at org.ofbiz.service.ModelService.validate(ModelService.java:597) ~[ofbiz-service.jar:?]
>      [java] at org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:376) [ofbiz-service.jar:?]
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)