Author: jacopoc
Date: Tue Oct 16 23:24:17 2007 New Revision: 585393 URL: http://svn.apache.org/viewvc?rev=585393&view=rev Log: Applied patch from Adrian Crum as a first pass to share the same common login screens in all the applications. OFBIZ-1320 Modified: ofbiz/trunk/framework/common/webcommon/WEB-INF/common-controller.xml ofbiz/trunk/framework/common/widget/CommonScreens.xml ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml ofbiz/trunk/framework/example/widget/example/CommonScreens.xml Modified: ofbiz/trunk/framework/common/webcommon/WEB-INF/common-controller.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/webcommon/WEB-INF/common-controller.xml?rev=585393&r1=585392&r2=585393&view=diff ============================================================================== --- ofbiz/trunk/framework/common/webcommon/WEB-INF/common-controller.xml (original) +++ ofbiz/trunk/framework/common/webcommon/WEB-INF/common-controller.xml Tue Oct 16 23:24:17 2007 @@ -58,6 +58,7 @@ <security https="true" auth="false"/> <event type="java" path="org.ofbiz.webapp.control.LoginWorker" invoke="login"/> <response name="success" type="view" value="main"/> + <response name="requirePasswordChange" type="view" value="requirePasswordChange"/> <response name="error" type="view" value="login"/> </request-map> <request-map uri="logout"> @@ -91,6 +92,9 @@ <!-- View Mappings --> <view-map name="error" page="/error/error.jsp"/> + <view-map name="login" type="screen" page="component://common/widget/CommonScreens.xml#login"/> + <view-map name="requirePasswordChange" type="screen" page="component://common/widget/CommonScreens.xml#requirePasswordChange"/> + <view-map name="LookupLocales" type="screen" page="component://common/widget/LookupScreens.xml#LookupLocales"/> <view-map name="LookupTimezones" type="screen" page="component://common/widget/LookupScreens.xml#LookupTimezones"/> </site-conf> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=585393&r1=585392&r2=585393&view=diff ============================================================================== --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original) +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Tue Oct 16 23:24:17 2007 @@ -255,4 +255,31 @@ </section> </screen> + <screen name="login"> + <section> + <widgets> + <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="body"> + <platform-specific> + <html><html-template location="component://common/webcommon/login.ftl"/></html> + </platform-specific> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> + + <screen name="requirePasswordChange"> + <section> + <widgets> + <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}"> + <decorator-section name="body"> + <platform-specific> + <html><html-template location="component://common/webcommon/changePassword.ftl"/></html> + </platform-specific> + </decorator-section> + </decorator-screen> + </widgets> + </section> + </screen> </screens> Modified: ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml?rev=585393&r1=585392&r2=585393&view=diff ============================================================================== --- ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml (original) +++ ofbiz/trunk/framework/example/webapp/example/WEB-INF/controller.xml Tue Oct 16 23:24:17 2007 @@ -20,9 +20,9 @@ <site-conf xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/site-conf.xsd"> - <!-- The request handlers and requests that are common to all OFBiz components + <!-- The controller elements that are common to all OFBiz components can be found in the following xml file. A component can override the - requests found in the common-controller.xml file. --> + elements found in the common-controller.xml file. --> <include location="component://common/webcommon/WEB-INF/common-controller.xml"/> <description>Example Component Site Configuration File</description> @@ -148,8 +148,6 @@ <!-- View Mappings --> <view-map name="main" type="screen" page="component://example/widget/example/CommonScreens.xml#main"/> - <view-map name="login" type="screen" page="component://example/widget/example/CommonScreens.xml#login"/> - <view-map name="requirePasswordChange" type="screen" page="component://example/widget/example/CommonScreens.xml#requirePasswordChange"/> <view-map name="FindExample" type="screen" page="component://example/widget/example/ExampleScreens.xml#FindExample"/> <view-map name="EditExample" type="screen" page="component://example/widget/example/ExampleScreens.xml#EditExample"/> Modified: ofbiz/trunk/framework/example/widget/example/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/CommonScreens.xml?rev=585393&r1=585392&r2=585393&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/CommonScreens.xml (original) +++ ofbiz/trunk/framework/example/widget/example/CommonScreens.xml Tue Oct 16 23:24:17 2007 @@ -151,30 +151,4 @@ </widgets> </section> </screen> - <screen name="login"> - <section> - <widgets> - <decorator-screen name="main-decorator"> - <decorator-section name="body"> - <platform-specific> - <html><html-template location="component://common/webcommon/login.ftl"/></html> - </platform-specific> - </decorator-section> - </decorator-screen> - </widgets> - </section> - </screen> - <screen name="requirePasswordChange"> - <section> - <widgets> - <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}"> - <decorator-section name="body"> - <platform-specific> - <html><html-template location="component://common/webcommon/changePassword.ftl"/></html> - </platform-specific> - </decorator-section> - </decorator-screen> - </widgets> - </section> - </screen> </screens> |
Free forum by Nabble | Edit this page |