<?xml version="1.0" encoding="UTF-8"?> <a:screen xmlns:c="leaf.application.action" xmlns:p="uncertain.proc" xmlns:a="http://www.leaf-framework.org/application" trace="true"> <a:view> <script type="text/javascript"><![CDATA[ function test1(){ alert("test1"); } function test2(){ alert("test2"); } function test3(){ alert("test3"); } ]]></script> <a:rightNavBars id="rightNavBars" right="40"> <a:rightNavBar title="合同起租" defaultImage="resources/images/lock.jpg" click="test1"/> <a:rightNavBar title="合同签约" defaultImage="resources/images/lock.jpg" click="test2"/> <a:rightNavBar title="合同结束" defaultImage="resources/images/lock.jpg" click="test3"/> </a:rightNavBars> </a:view> <script type="text/javascript"><![CDATA[ function useMethods() { $("rightNavBars").setItemBackground(0, "red"); $("rightNavBars").setImgBySrc(0, "https://www.baidu.com/img/baidu_jgylogo3.gif"); } ]]></script> </a:screen>