struts2配置方式返回json格式的List

        <action name="queryAllDefenceAreaList" 
            class="com.jxj.bss.web.actions.DefenceAreaAction"
            method="queryAllDefenceAreaList">
            <interceptor-ref name="isLogin"></interceptor-ref>
            <result type="json">
                <param name="includeProperties">resultCode,defenceAreaList\[\d+\]\.id,defenceAreaList\[\d+\]\.name</param>
            </result>
        </action>
        <action name="queryIPSANByMss" 
            class="com.jxj.bss.web.actions.IPSANAction" method="queryIPSANByMss">
            <interceptor-ref name="isLogin"></interceptor-ref>
            <result type="json">
                <param name="includeProperties">
                    ipsan\.info.*,<!-- 序列化map 用*替代  -->
                    resultCode
                </param>
            </result>
        </action>        

 

posted @ 2012-08-15 16:49  microsoft_kk  阅读(337)  评论(0编辑  收藏  举报