Author: jonesde
Date: Sun May 3 06:12:46 2009 New Revision: 771030 URL: http://svn.apache.org/viewvc?rev=771030&view=rev Log: Reverted changes in SVN revs 770084 and 770408; this gets the example component back to the good old security until things settle and patterns are better established and agreed on for the new stuff that Andrew is proponing Modified: ofbiz/trunk/framework/example/config/ExampleUiLabels.xml ofbiz/trunk/framework/example/data/ExampleSecurityData.xml ofbiz/trunk/framework/example/entitydef/entitymodel.xml ofbiz/trunk/framework/example/ofbiz-component.xml ofbiz/trunk/framework/example/security/CreateExample.groovy ofbiz/trunk/framework/example/security/UpdateExample.groovy ofbiz/trunk/framework/example/servicedef/services.xml ofbiz/trunk/framework/example/widget/example/CommonScreens.xml ofbiz/trunk/framework/example/widget/example/ExampleAjaxScreens.xml ofbiz/trunk/framework/example/widget/example/ExampleFeatureScreens.xml ofbiz/trunk/framework/example/widget/example/ExampleForms.xml ofbiz/trunk/framework/example/widget/example/ExampleScreens.xml ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml Modified: ofbiz/trunk/framework/example/config/ExampleUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/config/ExampleUiLabels.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/config/ExampleUiLabels.xml (original) +++ ofbiz/trunk/framework/example/config/ExampleUiLabels.xml Sun May 3 06:12:46 2009 @@ -466,13 +466,13 @@ <value xml:lang="it">DA FARE</value> </property> <property key="ExampleViewPermissionError"> - <value xml:lang="en">You do not have permission to view this page. ("access:example" needed)</value> - <value xml:lang="fr">Vous n'avez pas l'autorisation de voir cette page ("access:example" nécessaire)</value> - <value xml:lang="it">Tu non sei autorizzare a vedere questa pagina. (Permesso "access:example" necessario)</value> - <value xml:lang="ro">Nu esti autorizat sa vezi aceasta pagina. (Este necesar Permisul "access:example")</value> - <value xml:lang="ru">У Ð²Ð°Ñ Ð½ÐµÑ Ð¿Ñав Ð´Ð»Ñ Ð¿ÑоÑмоÑÑа ÑÑой ÑÑÑаниÑÑ. (Ð½ÐµÐ¾Ð±Ñ Ð¾Ð´Ð¸Ð¼Ñ Ð¿Ñава "access:example")</value> - <value xml:lang="th">à¸à¸¸à¸à¹à¸¡à¹à¹à¸à¹à¸£à¸±à¸à¸à¸à¸¸à¸à¸²à¸à¹à¸«à¹à¹à¸à¹à¸²à¸à¸¹à¸«à¸à¹à¸²à¸à¸µà¹à¹à¸à¹ (หà¸à¹à¸² "access:example" à¸à¸µà¹à¸à¹à¸à¸à¸à¸²à¸£)</value> - <value xml:lang="zh">ä½ æ²¡ææµè§è¿ä¸ªé¡µé¢çæéã(éè¦"access:example")</value> + <value xml:lang="en">You do not have permission to view this page. ("EXAMPLE_VIEW" or "EXAMPLE_ADMIN" needed)</value> + <value xml:lang="fr">Vous n'avez pas l'autorisation de voir cette page ("EXAMPLE_VIEW" ou "EXAMPLE_ADMIN" nécessaire)</value> + <value xml:lang="it">Tu non sei autorizzare a vedere questa pagina. (Permesso "EXAMPLE_VIEW" o "EXAMPLE_ADMIN" necessario)</value> + <value xml:lang="ro">Nu esti autorizat sa vezi aceasta pagina. (Este necesar Permisul "EXAMPLE_VIEW" sau "EXAMPLE_ADMIN")</value> + <value xml:lang="ru">У Ð²Ð°Ñ Ð½ÐµÑ Ð¿Ñав Ð´Ð»Ñ Ð¿ÑоÑмоÑÑа ÑÑой ÑÑÑаниÑÑ. (Ð½ÐµÐ¾Ð±Ñ Ð¾Ð´Ð¸Ð¼Ñ Ð¿Ñава "EXAMPLE_VIEW" или "EXAMPLE_ADMIN")</value> + <value xml:lang="th">à¸à¸¸à¸à¹à¸¡à¹à¹à¸à¹à¸£à¸±à¸à¸à¸à¸¸à¸à¸²à¸à¹à¸«à¹à¹à¸à¹à¸²à¸à¸¹à¸«à¸à¹à¸²à¸à¸µà¹à¹à¸à¹ (หà¸à¹à¸² "EXAMPLE_VIEW" หรืภ"EXAMPLE_ADMIN" à¸à¸µà¹à¸à¹à¸à¸à¸à¸²à¸£)</value> + <value xml:lang="zh">ä½ æ²¡ææµè§è¿ä¸ªé¡µé¢çæéã(éè¦"EXAMPLE_VIEW"æ"EXAMPLE_ADMIN")</value> </property> <property key="ExampleWelcome"> <value xml:lang="en">Welcome to the Example application!</value> Modified: ofbiz/trunk/framework/example/data/ExampleSecurityData.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/data/ExampleSecurityData.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/data/ExampleSecurityData.xml (original) +++ ofbiz/trunk/framework/example/data/ExampleSecurityData.xml Sun May 3 06:12:46 2009 @@ -19,30 +19,16 @@ --> <entity-engine-xml> <!-- Example security --> - <SecurityPermission description="ACCESS the Example Application" permissionId="access:example"/> - <SecurityPermission description="CREATE operations in the Example Application" permissionId="create:example" dynamicAccess="component://example/security/CreateExample.groovy"/> - <SecurityPermission description="READ operations in the Example Application" permissionId="read:example"/> - <SecurityPermission description="UPDATE operations in the Example Application" permissionId="update:example" dynamicAccess="component://example/security/UpdateExample.groovy"/> - <SecurityPermission description="DELETE operations in the Example Application" permissionId="delete:example"/> - - <SecurityPermission description="CREATE STATUS operations in the Example Application" permissionId="create:example:status"/> - <SecurityPermission description="READ STATUS operations in the Example Application" permissionId="read:example:status"/> - <SecurityPermission description="UPDATE STATUS operations in the Example Application" permissionId="update:example:status"/> - <SecurityPermission description="DELETE STATUS operations in the Example Application" permissionId="delete:example:status"/> - - <SecurityPermission description="CREATE ITEM operations in the Example Application" permissionId="create:example:item"/> - <SecurityPermission description="READ ITEM operations in the Example Application" permissionId="read:example:item"/> - <SecurityPermission description="UPDATE ITEM operations in the Example Application" permissionId="update:example:item"/> - <SecurityPermission description="DELETE ITEM operations in the Example Application" permissionId="delete:example:item"/> - - <SecurityPermission description="CREATE FEATURE operations in the Example Application" permissionId="create:example:feature"/> - <SecurityPermission description="READ ITEM operations in the Example Application" permissionId="read:example:feature"/> - <SecurityPermission description="UPDATE ITEM operations in the Example Application" permissionId="update:example:feature"/> - <SecurityPermission description="DELETE ITEM operations in the Example Application" permissionId="delete:example:feature"/> - - <SecurityGroupPermission groupId="BIZADMIN" permissionId="access:example"/> - <SecurityGroupPermission groupId="BIZADMIN" permissionId="create:example"/> - <SecurityGroupPermission groupId="BIZADMIN" permissionId="read:example"/> - <SecurityGroupPermission groupId="BIZADMIN" permissionId="update:example"/> - <SecurityGroupPermission groupId="BIZADMIN" permissionId="delete:example"/> + <SecurityPermission description="View operations in the Example Management Screens." permissionId="EXAMPLE_VIEW"/> + <SecurityPermission description="Create operations in the Example Management Screens." permissionId="EXAMPLE_CREATE"/> + <SecurityPermission description="Update operations in the Example Management Screens." permissionId="EXAMPLE_UPDATE"/> + <SecurityPermission description="Delete operations in the Example Management Screens." permissionId="EXAMPLE_DELETE"/> + <SecurityPermission description="ALL operations in the Example Management Screens." permissionId="EXAMPLE_ADMIN"/> + <SecurityGroupPermission groupId="FULLADMIN" permissionId="EXAMPLE_ADMIN"/> + <SecurityGroupPermission groupId="FLEXADMIN" permissionId="EXAMPLE_CREATE"/> + <SecurityGroupPermission groupId="FLEXADMIN" permissionId="EXAMPLE_DELETE"/> + <SecurityGroupPermission groupId="FLEXADMIN" permissionId="EXAMPLE_UPDATE"/> + <SecurityGroupPermission groupId="FLEXADMIN" permissionId="EXAMPLE_VIEW"/> + <SecurityGroupPermission groupId="VIEWADMIN" permissionId="EXAMPLE_VIEW"/> + <SecurityGroupPermission groupId="BIZADMIN" permissionId="EXAMPLE_ADMIN"/> </entity-engine-xml> Modified: ofbiz/trunk/framework/example/entitydef/entitymodel.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/entitydef/entitymodel.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/entitydef/entitymodel.xml (original) +++ ofbiz/trunk/framework/example/entitydef/entitymodel.xml Sun May 3 06:12:46 2009 @@ -55,7 +55,6 @@ <field name="exampleDate" type="date-time"></field> <field name="anotherDate" type="date-time"></field> <field name="anotherText" type="long-varchar"></field> - <field name="createdByUser" type="id-vlong-ne"></field> <prim-key field="exampleId"/> <relation type="one" fk-name="EXMPL_TYP" rel-entity-name="ExampleType"> <key-map field-name="exampleTypeId"/> @@ -63,9 +62,6 @@ <relation type="one" fk-name="EXMPL_STTS" rel-entity-name="StatusItem"> <key-map field-name="statusId"/> </relation> - <relation type="one" fk-name="EXMPL_USER" rel-entity-name="UserLogin"> - <key-map field-name="createdByUser" rel-field-name="userLoginId"/> - </relation> </entity> <entity entity-name="ExampleItem" package-name="org.ofbiz.example.example" title="Example Item Entity" default-resource-name="ExampleEntityLabels"> <field name="exampleId" type="id-ne"></field> Modified: ofbiz/trunk/framework/example/ofbiz-component.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/ofbiz-component.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/ofbiz-component.xml (original) +++ ofbiz/trunk/framework/example/ofbiz-component.xml Sun May 3 06:12:46 2009 @@ -54,6 +54,6 @@ menu-name="secondary" server="default-server" location="webapp/example" - base-permission="access:example" + base-permission="OFBTOOLS,EXAMPLE" mount-point="/example"/> </ofbiz-component> Modified: ofbiz/trunk/framework/example/security/CreateExample.groovy URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/security/CreateExample.groovy?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/security/CreateExample.groovy (original) +++ ofbiz/trunk/framework/example/security/CreateExample.groovy Sun May 3 06:12:46 2009 @@ -1,21 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ - - // this dynamic access grants ANYONE access - return true; \ No newline at end of file Modified: ofbiz/trunk/framework/example/security/UpdateExample.groovy URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/security/UpdateExample.groovy?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/security/UpdateExample.groovy (original) +++ ofbiz/trunk/framework/example/security/UpdateExample.groovy Sun May 3 06:12:46 2009 @@ -1,34 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ - -import org.ofbiz.base.util.Debug; - -exampleId = permissionContext.get("exampleId"); -//Debug.logInfo("Groovy DA Context : " + permissionContext, "groovy"); -//Debug.logInfo("Calling UpdateExample.groovy - " + exampleId, "groovy"); -if (exampleId != null) { - example = delegator.findOne("Example", [exampleId : exampleId], true); - //Debug.logInfo("Example : " + example, "groovy"); - - if (example.createdByUser == null || userId.equals(example.createdByUser)) { - return true; - } -} - -return false; Modified: ofbiz/trunk/framework/example/servicedef/services.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/servicedef/services.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/servicedef/services.xml (original) +++ ofbiz/trunk/framework/example/servicedef/services.xml Sun May 3 06:12:46 2009 @@ -27,37 +27,29 @@ <!-- Example & Related Services --> <service name="createExample" default-entity-name="Example" engine="entity-auto" invoke="create" auth="true"> <description>Create a Example</description> - <required-permissions join-type="AND"> - <check-permission permission="create:example"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="CREATE"/> <auto-attributes include="pk" mode="OUT" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> <override name="exampleTypeId" optional="false"/> <override name="statusId" optional="false"/> - <override name="exampleName" optional="false"/> + <override name="exampleName" optional="false"/> </service> <service name="updateExample" default-entity-name="Example" engine="entity-auto" invoke="update" auth="true"> <description>Update a Example</description> - <required-permissions join-type="AND"> - <check-permission permission="update:example:${exampleId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="UPDATE"/> <auto-attributes include="pk" mode="IN" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> <attribute name="oldStatusId" type="String" mode="OUT" optional="false"/> </service> <service name="deleteExample" default-entity-name="Example" engine="entity-auto" invoke="delete" auth="true"> <description>Delete a Example</description> - <required-permissions join-type="AND"> - <check-permission permission="delete:example:${exampleId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="DELETE"/> <auto-attributes include="pk" mode="IN" optional="false"/> </service> <service name="createExampleStatus" default-entity-name="ExampleStatus" engine="simple" location="component://example/script/org/ofbiz/example/example/ExampleServices.xml" invoke="createExampleStatus" auth="true"> <description>Create a ExampleStatus</description> - <required-permissions join-type="AND"> - <check-permission permission="update:example:status:${exampleId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="CREATE"/> <auto-attributes include="all" mode="IN" optional="false"> <exclude field-name="statusDate"/> <exclude field-name="statusEndDate"/> @@ -66,9 +58,7 @@ <service name="createExampleItem" default-entity-name="ExampleItem" engine="entity-auto" invoke="create" auth="true"> <description>Create a ExampleItem</description> - <required-permissions join-type="AND"> - <check-permission permission="create:example:item:${exampleId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="CREATE"/> <auto-attributes include="pk" mode="IN" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> <override name="exampleItemSeqId" mode="OUT"/> <!-- make this OUT rather than IN, we will automatically generate the next sub-sequence ID --> @@ -76,78 +66,60 @@ </service> <service name="updateExampleItem" default-entity-name="ExampleItem" engine="entity-auto" invoke="update" auth="true"> <description>Update a ExampleItem</description> - <required-permissions join-type="AND"> - <check-permission permission="update:example:item:${exampleId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="UPDATE"/> <auto-attributes include="pk" mode="IN" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> </service> <service name="deleteExampleItem" default-entity-name="ExampleItem" engine="entity-auto" invoke="delete" auth="true"> <description>Delete a ExampleItem</description> - <required-permissions join-type="AND"> - <check-permission permission="delete:example:item:${exampleId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="DELETE"/> <auto-attributes include="pk" mode="IN" optional="false"/> </service> <!-- ExampleFeature Services --> <service name="createExampleFeature" default-entity-name="ExampleFeature" engine="entity-auto" invoke="create" auth="true"> <description>Create a ExampleFeature</description> - <required-permissions join-type="AND"> - <check-permission permission="create:example:feature"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="CREATE"/> <auto-attributes include="pk" mode="OUT" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> <override name="description" optional="false"/> </service> <service name="updateExampleFeature" default-entity-name="ExampleFeature" engine="entity-auto" invoke="update" auth="true"> <description>Update a ExampleFeature</description> - <required-permissions join-type="AND"> - <check-permission permission="update:example:feature"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="UPDATE"/> <auto-attributes include="pk" mode="IN" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> </service> <service name="deleteExampleFeature" default-entity-name="ExampleFeature" engine="entity-auto" invoke="delete" auth="true"> <description>Delete a ExampleFeature</description> - <required-permissions join-type="AND"> - <check-permission permission="delete:example:feature"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="DELETE"/> <auto-attributes include="pk" mode="IN" optional="false"/> </service> <service name="createExampleFeatureAppl" default-entity-name="ExampleFeatureAppl" engine="entity-auto" invoke="create" auth="true"> <description>Create a ExampleFeatureAppl</description> - <required-permissions join-type="AND"> - <check-permission permission="create:example:feature:${exampleFeatureId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="CREATE"/> <auto-attributes include="pk" mode="IN" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> <override name="fromDate" optional="true"/> </service> <service name="updateExampleFeatureAppl" default-entity-name="ExampleFeatureAppl" engine="entity-auto" invoke="update" auth="true"> <description>Update a ExampleFeatureAppl</description> - <required-permissions join-type="AND"> - <check-permission permission="update:example:feature:${exampleFeatureId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="UPDATE"/> <auto-attributes include="pk" mode="IN" optional="false"/> <auto-attributes include="nonpk" mode="IN" optional="true"/> </service> <service name="deleteExampleFeatureAppl" default-entity-name="ExampleFeatureAppl" engine="entity-auto" invoke="delete" auth="true"> <description>Delete a ExampleFeatureAppl</description> - <required-permissions join-type="AND"> - <check-permission permission="delete:example:feature:${exampleFeatureId}"/> - </required-permissions> + <permission-service service-name="exampleGenericPermission" main-action="DELETE"/> <auto-attributes include="pk" mode="IN" optional="false"/> </service> <!-- Permission Services --> - <!-- @deprecated <service name="exampleGenericPermission" engine="simple" location="component://example/script/org/ofbiz/example/ExamplePermissionServices.xml" invoke="exampleGenericPermission"> <implements service="permissionInterface"/> </service> - --> <!-- Example ServiceTest Service --> <service name="testCreateExampleService" engine="simple" Modified: ofbiz/trunk/framework/example/widget/example/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/CommonScreens.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/CommonScreens.xml (original) +++ ofbiz/trunk/framework/example/widget/example/CommonScreens.xml Sun May 3 06:12:46 2009 @@ -71,7 +71,7 @@ <section> <condition> <and> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> <not><if-empty field="example"/></not> </and> </condition> @@ -82,9 +82,9 @@ </decorator-section> <decorator-section name="body"> <section> - <!-- do check for access:example permission --> + <!-- do check for EXAMPLE, _VIEW permission --> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <widgets> <section> @@ -135,7 +135,7 @@ <section> <condition> <and> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> <not><if-empty field="exampleFeature"/></not> </and> </condition> @@ -148,7 +148,7 @@ <section> <!-- do check for EXAMPLE, _VIEW permission --> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <widgets> <section> Modified: ofbiz/trunk/framework/example/widget/example/ExampleAjaxScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/ExampleAjaxScreens.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/ExampleAjaxScreens.xml (original) +++ ofbiz/trunk/framework/example/widget/example/ExampleAjaxScreens.xml Sun May 3 06:12:46 2009 @@ -34,7 +34,7 @@ <decorator-section name="body"> <section> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <widgets> <container style="h1"><label>${uiLabelMap[titleProperty]}</label></container> @@ -68,7 +68,7 @@ <screen name="ListExampleFormOnly"> <section> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <actions> <!-- NOTE: these are needed because this may be run as a top level screen and would have no decorator --> @@ -84,7 +84,7 @@ <screen name="CreateExampleFormOnly"> <section> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <actions> <!-- these are only needed so that when bsh evaluates use-when attributes these will exist and not cause an error --> Modified: ofbiz/trunk/framework/example/widget/example/ExampleFeatureScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/ExampleFeatureScreens.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/ExampleFeatureScreens.xml (original) +++ ofbiz/trunk/framework/example/widget/example/ExampleFeatureScreens.xml Sun May 3 06:12:46 2009 @@ -34,7 +34,7 @@ <decorator-section name="body"> <section> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <widgets> <decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml"> @@ -98,7 +98,7 @@ <screen name="LookupExampleFeature"> <section> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <actions> <property-map resource="ExampleUiLabels" map-name="uiLabelMap" global="true"/> Modified: ofbiz/trunk/framework/example/widget/example/ExampleForms.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/ExampleForms.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/ExampleForms.xml (original) +++ ofbiz/trunk/framework/example/widget/example/ExampleForms.xml Sun May 3 06:12:46 2009 @@ -142,8 +142,6 @@ <field name="displayAnotherText" use-when="example!=null&&example.get("anotherText")!=null"> <display description="${example.anotherText}"/> </field> - <field name="createdByUser" use-when="example==null"><hidden value="${userLogin.userLoginId}"/></field> - <field name="createdByUser" use-when="example!=null"><hidden/></field> <field name="submitButton" use-when="example==null" title="${uiLabelMap.CommonCreate}"><submit button-type="button"/></field> <field name="submitButton" use-when="example!=null" title="${uiLabelMap.CommonUpdate}"><submit button-type="button"/></field> </form> Modified: ofbiz/trunk/framework/example/widget/example/ExampleScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/ExampleScreens.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/ExampleScreens.xml (original) +++ ofbiz/trunk/framework/example/widget/example/ExampleScreens.xml Sun May 3 06:12:46 2009 @@ -34,7 +34,7 @@ <decorator-section name="body"> <section> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <widgets> <decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml"> Modified: ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml?rev=771030&r1=771029&r2=771030&view=diff ============================================================================== --- ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml (original) +++ ofbiz/trunk/framework/example/widget/example/FormWidgetExampleScreens.xml Sun May 3 06:12:46 2009 @@ -31,7 +31,7 @@ <decorator-section name="body"> <section> <condition> - <if-has-permission permission="access:example"/> + <if-has-permission permission="EXAMPLE" action="_VIEW"/> </condition> <widgets> <container style="h1"><label>${uiLabelMap.PageTitleFormWidgetExamples}</label></container> |
Free forum by Nabble | Edit this page |