svn commit: r804935 [2/4] - in /ofbiz/trunk: applications/accounting/ applications/accounting/src/org/ofbiz/accounting/tax/ applications/accounting/webapp/accounting/invoice/ applications/accounting/webapp/accounting/payment/ applications/accounting/we...

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

svn commit: r804935 [2/4] - in /ofbiz/trunk: applications/accounting/ applications/accounting/src/org/ofbiz/accounting/tax/ applications/accounting/webapp/accounting/invoice/ applications/accounting/webapp/accounting/payment/ applications/accounting/we...

jleroux@apache.org
Modified: ofbiz/trunk/applications/workeffort/src/org/ofbiz/workeffort/workeffort/WorkEffortServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/src/org/ofbiz/workeffort/workeffort/WorkEffortServices.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/src/org/ofbiz/workeffort/workeffort/WorkEffortServices.java (original)
+++ ofbiz/trunk/applications/workeffort/src/org/ofbiz/workeffort/workeffort/WorkEffortServices.java Mon Aug 17 11:01:25 2009
@@ -358,18 +358,18 @@
         if (UtilValidate.isNotEmpty(partyIds)) {
             // (non cancelled) public events, with a startdate
             List<EntityCondition> publicEvents = UtilMisc.<EntityCondition>toList(
-             EntityCondition.makeCondition("scopeEnumId", EntityOperator.EQUALS, "WES_PUBLIC"),
-             EntityCondition.makeCondition("parentTypeId", EntityOperator.EQUALS, "EVENT")
-             );
+                    EntityCondition.makeCondition("scopeEnumId", EntityOperator.EQUALS, "WES_PUBLIC"),
+                    EntityCondition.makeCondition("parentTypeId", EntityOperator.EQUALS, "EVENT")
+                    );
             
             if (cancelledCheckAndList != null) {
-             publicEvents.addAll(cancelledCheckAndList);
+                publicEvents.addAll(cancelledCheckAndList);
             }
             entityExprList.add(
-             EntityCondition.makeCondition(UtilMisc.toList(
-             EntityCondition.makeCondition("partyId", EntityOperator.IN, partyIds),
-             EntityCondition.makeCondition(publicEvents, EntityJoinOperator.AND)
-             ), EntityJoinOperator.OR));
+                    EntityCondition.makeCondition(UtilMisc.toList(
+                            EntityCondition.makeCondition("partyId", EntityOperator.IN, partyIds),
+                            EntityCondition.makeCondition(publicEvents, EntityJoinOperator.AND)
+                    ), EntityJoinOperator.OR));
         }
         if (UtilValidate.isNotEmpty(facilityId)) {
             entityExprList.add(EntityCondition.makeCondition("facilityId", EntityOperator.EQUALS, facilityId));
@@ -438,22 +438,22 @@
      */
   
     public static Map<String, Object> getWorkEffortEventsByPeriod(DispatchContext ctx, Map<String, ? extends Object> context) {
-    
-     /*
-     To create testdata for  this function for  fixedasset/facility
-
- 1) go to Manufacturing -> JobShop, then click on "create new Production run":
- https://localhost:8443/manufacturing/control/CreateProductionRun
- 2) enter as productId "PROD_MANUF", quantity 1, start date tomorrow and press the submit button
- ` 3) in the next screen, click on the "Confirm" link (top part of the sccreen)
+        
+        /*
+         To create testdata for  this function for  fixedasset/facility
+
+        1) go to Manufacturing -> JobShop, then click on "create new Production run":
+                https://localhost:8443/manufacturing/control/CreateProductionRun
+        2) enter as productId "PROD_MANUF", quantity 1, start date tomorrow and press the submit button
+    `    3) in the next screen, click on the "Confirm" link (top part of the sccreen)
 
- Now you have a confirmed production run (starting tomorrow) happening in facility "WebStoreWarehouse",
- with a task happening in fixed asset "WORKCENTER_COST"
+        Now you have a confirmed production run (starting tomorrow) happening in facility "WebStoreWarehouse",
+        with a task happening in fixed asset "WORKCENTER_COST"
 
- In the calendars screen, selecting the proper facility you should see the work effort associated to the production run;
- if you select the proper fixed asset you should see the task.
+        In the calendars screen, selecting the proper facility you should see the work effort associated to the production run;
+        if you select the proper fixed asset you should see the task.
 
-     */
+         */
         GenericDelegator delegator = ctx.getDelegator();
         Security security = ctx.getSecurity();
         GenericValue userLogin = (GenericValue) context.get("userLogin");
@@ -514,9 +514,9 @@
         }
 
         // cancelled status id's
-    List<EntityCondition> cancelledCheckAndList = UtilMisc.<EntityCondition>toList(
-     EntityCondition.makeCondition("currentStatusId", EntityOperator.NOT_EQUAL, "EVENT_CANCELLED"),
-     EntityCondition.makeCondition("currentStatusId", EntityOperator.NOT_EQUAL, "CAL_CANCELLED"));
+        List<EntityCondition> cancelledCheckAndList = UtilMisc.<EntityCondition>toList(
+                EntityCondition.makeCondition("currentStatusId", EntityOperator.NOT_EQUAL, "EVENT_CANCELLED"),
+                EntityCondition.makeCondition("currentStatusId", EntityOperator.NOT_EQUAL, "CAL_CANCELLED"));
         
 
         List<EntityCondition> entityExprList = UtilGenerics.checkList(context.get("entityExprList"));
@@ -525,82 +525,82 @@
         }
 
         // should have at least a start date
-    EntityCondition startDateRequired = EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
- EntityCondition.makeCondition("estimatedStartDate", EntityOperator.NOT_EQUAL, null),
- EntityCondition.makeCondition("actualStartDate", EntityOperator.NOT_EQUAL, null)
- ), EntityJoinOperator.OR);
-    
+        EntityCondition startDateRequired = EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                EntityCondition.makeCondition("estimatedStartDate", EntityOperator.NOT_EQUAL, null),                                
+                EntityCondition.makeCondition("actualStartDate", EntityOperator.NOT_EQUAL, null)                                
+        ), EntityJoinOperator.OR);
+        
         List<EntityCondition> periodCheckAndlList = UtilMisc.<EntityCondition>toList(
-         startDateRequired,
-         // the startdate should be less than the period end
-         EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
-         EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
-         EntityCondition.makeCondition("actualStartDate", EntityOperator.EQUALS, null),
-         EntityCondition.makeCondition("estimatedStartDate", EntityOperator.NOT_EQUAL, null),
-         EntityCondition.makeCondition("estimatedStartDate", EntityOperator.LESS_THAN_EQUAL_TO, endStamp)
-         ), EntityJoinOperator.AND),
-         EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
-         EntityCondition.makeCondition("actualStartDate", EntityOperator.NOT_EQUAL, null),
-         EntityCondition.makeCondition("actualStartDate", EntityOperator.LESS_THAN_EQUAL_TO, endStamp)
-         ), EntityJoinOperator.AND)
-         ), EntityJoinOperator.OR),
-         // if the completion date is not null then it should be larger than the period start
-         EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
-         // can also be empty
-         EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
-         EntityCondition.makeCondition("estimatedCompletionDate", EntityOperator.EQUALS, null),
-         EntityCondition.makeCondition("actualCompletionDate", EntityOperator.EQUALS, null)
-         ), EntityJoinOperator.AND),
-         // check estimated value if the actual is not provided
-         EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
-         EntityCondition.makeCondition("actualCompletionDate", EntityOperator.EQUALS, null),
-         EntityCondition.makeCondition("estimatedCompletionDate", EntityOperator.NOT_EQUAL, null),
-         EntityCondition.makeCondition("estimatedCompletionDate", EntityOperator.GREATER_THAN_EQUAL_TO, startStamp)
-         ), EntityJoinOperator.AND),
-         // at last check the actual value
-         EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
-         EntityCondition.makeCondition("actualCompletionDate", EntityOperator.NOT_EQUAL, null),
-         EntityCondition.makeCondition("actualCompletionDate", EntityOperator.GREATER_THAN_EQUAL_TO, startStamp)
-         ), EntityJoinOperator.AND)
-         ), EntityJoinOperator.OR));
+                startDateRequired,
+                // the startdate should be less than the period end
+                EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                        EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                                EntityCondition.makeCondition("actualStartDate", EntityOperator.EQUALS, null),
+                                EntityCondition.makeCondition("estimatedStartDate", EntityOperator.NOT_EQUAL, null),
+                                EntityCondition.makeCondition("estimatedStartDate", EntityOperator.LESS_THAN_EQUAL_TO, endStamp)
+                        ), EntityJoinOperator.AND),
+                        EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                                EntityCondition.makeCondition("actualStartDate", EntityOperator.NOT_EQUAL, null),
+                                EntityCondition.makeCondition("actualStartDate", EntityOperator.LESS_THAN_EQUAL_TO, endStamp)
+                        ), EntityJoinOperator.AND)
+                ), EntityJoinOperator.OR),
+                // if the completion date is not null then it should be larger than the period start
+                EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                        // can also be empty
+                        EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                                EntityCondition.makeCondition("estimatedCompletionDate", EntityOperator.EQUALS, null),
+                                EntityCondition.makeCondition("actualCompletionDate", EntityOperator.EQUALS, null)
+                        ), EntityJoinOperator.AND),
+                        // check estimated value if the actual is not provided
+                        EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                                EntityCondition.makeCondition("actualCompletionDate", EntityOperator.EQUALS, null),
+                                EntityCondition.makeCondition("estimatedCompletionDate", EntityOperator.NOT_EQUAL, null),
+                                EntityCondition.makeCondition("estimatedCompletionDate", EntityOperator.GREATER_THAN_EQUAL_TO, startStamp)
+                        ), EntityJoinOperator.AND),
+                        // at last check the actual value
+                        EntityCondition.makeCondition(UtilMisc.<EntityCondition>toList(
+                                EntityCondition.makeCondition("actualCompletionDate", EntityOperator.NOT_EQUAL, null),
+                                EntityCondition.makeCondition("actualCompletionDate", EntityOperator.GREATER_THAN_EQUAL_TO, startStamp)
+                        ), EntityJoinOperator.AND)
+                ), EntityJoinOperator.OR));
         
         entityExprList.addAll(periodCheckAndlList);
 
         // (non cancelled) recurring events
         List<EntityCondition> recurringEvents = UtilMisc.<EntityCondition>toList(EntityCondition.makeCondition("tempExprId", EntityOperator.NOT_EQUAL, null));
         if (filterOutCanceledEvents.booleanValue()) {
-         recurringEvents.addAll(cancelledCheckAndList);
+            recurringEvents.addAll(cancelledCheckAndList);
         }
 
         EntityCondition eclTotal = EntityCondition.makeCondition(UtilMisc.toList(
-         EntityCondition.makeCondition(entityExprList, EntityJoinOperator.AND),
-         EntityCondition.makeCondition(recurringEvents, EntityJoinOperator.AND)
-         ), EntityJoinOperator.OR);
+                EntityCondition.makeCondition(entityExprList, EntityJoinOperator.AND),
+                EntityCondition.makeCondition(recurringEvents, EntityJoinOperator.AND)
+                ), EntityJoinOperator.OR);
         
         List<String> orderByList = UtilMisc.toList("estimatedStartDate");
         if (partyIdsToUse.size() > 0 || UtilValidate.isNotEmpty(facilityId) || UtilValidate.isNotEmpty(fixedAssetId)) {
             try {
                 List<GenericValue> tempWorkEfforts = null;
                 if (UtilValidate.isNotEmpty(partyIdsToUse)) {
-                 // Debug.log("=====conditions for party: " + eclTotal);
+                    // Debug.log("=====conditions for party: " + eclTotal);
                     tempWorkEfforts = EntityUtil.filterByDate(delegator.findList("WorkEffortAndPartyAssignAndType", eclTotal, null, orderByList, null, false));
                 } else if (UtilValidate.isNotEmpty(fixedAssetId)) {
-                 EntityConditionList<EntityCondition> ecl =
-                 EntityCondition.makeCondition(UtilMisc.toList(
-                 eclTotal,
-                 EntityCondition.makeCondition("fixedAssetId", EntityOperator.EQUALS, fixedAssetId)
-                 ), EntityJoinOperator.AND);
+                    EntityConditionList<EntityCondition> ecl =
+                        EntityCondition.makeCondition(UtilMisc.toList(
+                            eclTotal,
+                            EntityCondition.makeCondition("fixedAssetId", EntityOperator.EQUALS, fixedAssetId)
+                    ), EntityJoinOperator.AND);
                     // Get "old style" work efforts and "new style" work efforts
-                 // Debug.log("=====conditions for fixed asset: " + ecl);
+                    // Debug.log("=====conditions for fixed asset: " + ecl);
                     tempWorkEfforts = delegator.findList("WorkEffort", ecl, null, orderByList, null, false);
                     tempWorkEfforts.addAll(EntityUtil.filterByDate(delegator.findList("WorkEffortAndFixedAssetAssign", ecl, null, orderByList, null, false)));
                 } else {
-                 EntityConditionList<EntityCondition> ecl =
-                 EntityCondition.makeCondition(UtilMisc.toList(
-                 eclTotal,
-                 EntityCondition.makeCondition("facilityId", EntityOperator.EQUALS, facilityId)
-                 ), EntityJoinOperator.AND);
-                 // Debug.log("=====conditions for facility: " + ecl);
+                    EntityConditionList<EntityCondition> ecl =
+                        EntityCondition.makeCondition(UtilMisc.toList(
+                            eclTotal,
+                            EntityCondition.makeCondition("facilityId", EntityOperator.EQUALS, facilityId)
+                    ), EntityJoinOperator.AND);
+                    // Debug.log("=====conditions for facility: " + ecl);
                     tempWorkEfforts = delegator.findList("WorkEffort", ecl, null, UtilMisc.toList("estimatedStartDate"), null, false);
                 }
                 validWorkEfforts = WorkEffortWorker.removeDuplicateWorkEfforts(tempWorkEfforts);
@@ -627,10 +627,10 @@
                 Calendar cal = UtilDateTime.toCalendar(startStamp, timeZone, locale);
                 for (GenericValue workEffort : validWorkEfforts) {
                     if (UtilValidate.isNotEmpty(workEffort.getString("tempExprId"))) {
-                     // check if either the workeffort is public or the requested party is a member
-                     if (UtilValidate.isNotEmpty(partyIdsToUse) && !workEffort.getString("scopeEnumId").equals("WES_PUBLIC") && !partyIdsToUse.contains(workEffort.getString("partyId"))) {
-                     continue;
-                     }
+                        // check if either the workeffort is public or the requested party is a member
+                        if (UtilValidate.isNotEmpty(partyIdsToUse) && !workEffort.getString("scopeEnumId").equals("WES_PUBLIC") && !partyIdsToUse.contains(workEffort.getString("partyId"))) {
+                            continue;
+                        }
                         TemporalExpression tempExpr = TemporalExpressionWorker.getTemporalExpression(delegator, workEffort.getString("tempExprId"));
                         Set<Date> occurrences = tempExpr.getRange(range, cal);
                         for (Date occurrence : occurrences) {
@@ -667,15 +667,15 @@
                 List<Map<String, Object>> curWorkEfforts = FastList.newInstance();
                 Map<String, Object> entry = FastMap.newInstance();
                 for (GenericValue workEffort : validWorkEfforts) {
-                 Timestamp startDate = workEffort.getTimestamp("estimatedStartDate");
-                 if (workEffort.getTimestamp("actualStartDate") != null) {
-                 startDate = workEffort.getTimestamp("actualStartDate");
-                 }
-                 Timestamp endDate = workEffort.getTimestamp("estimatedCompletionDate");
-                 if (workEffort.getTimestamp("actualCompletionDate") != null) {
-                 endDate = workEffort.getTimestamp("actualCompletionDate");
-                 }
-                 if (endDate == null) endDate = startDate;
+                    Timestamp startDate = workEffort.getTimestamp("estimatedStartDate");
+                    if (workEffort.getTimestamp("actualStartDate") != null) {
+                        startDate = workEffort.getTimestamp("actualStartDate");
+                    }
+                    Timestamp endDate = workEffort.getTimestamp("estimatedCompletionDate");
+                    if (workEffort.getTimestamp("actualCompletionDate") != null) {
+                        endDate = workEffort.getTimestamp("actualCompletionDate");
+                    }
+                    if (endDate == null) endDate = startDate;
                     DateRange weRange = new DateRange(startDate, endDate);
                     if (periodRange.intersectsRange(weRange)) {
                         Map<String, Object> calEntry = FastMap.newInstance();

Modified: ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/CreateUrlParam.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/CreateUrlParam.groovy?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/CreateUrlParam.groovy (original)
+++ ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/CreateUrlParam.groovy Mon Aug 17 11:01:25 2009
@@ -38,7 +38,7 @@
 }
 
 if (urlParam) {
- urlParam = "&" + urlParam;
+    urlParam = "&" + urlParam;
 }
 
 context.put("urlParam", urlParam);

Modified: ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy (original)
+++ ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy Mon Aug 17 11:01:25 2009
@@ -70,14 +70,14 @@
 lastWeekCal = UtilDateTime.toCalendar(getTo, timeZone, locale);
 followingMonthDays = lastWeekCal.get(Calendar.DAY_OF_WEEK) - monthEndDay;
 if (followingMonthDays < 0) {
- followingMonthDays += 7;
+    followingMonthDays += 7;
 }
 numDays += followingMonthDays;
 
 serviceCtx = UtilMisc.toMap("userLogin", userLogin, "start", getFrom, "numPeriods", new Integer(numDays), "periodType", new Integer(Calendar.DATE));
 serviceCtx.putAll(UtilMisc.toMap("partyId", partyId, "facilityId", facilityId, "fixedAssetId", fixedAssetId, "workEffortTypeId", workEffortTypeId, "locale", locale, "timeZone", timeZone));
 if (entityExprList) {
- serviceCtx.putAll(["entityExprList" : entityExprList]);
+    serviceCtx.putAll(["entityExprList" : entityExprList]);
 }
 
 result = dispatcher.runSync("getWorkEffortEventsByPeriod", serviceCtx);

Modified: ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy (original)
+++ ofbiz/trunk/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy Mon Aug 17 11:01:25 2009
@@ -35,7 +35,7 @@
 entityExprList = (List) context.get("entityExprList");
 filterOutCanceledEvents = parameters.filterOutCanceledEvents;
 if (!filterOutCanceledEvents) {
- filterOutCanceledEvents = Boolean.FALSE;
+    filterOutCanceledEvents = Boolean.FALSE;
 }
 
 Timestamp start = null;
@@ -56,10 +56,10 @@
 Timestamp end = UtilDateTime.getDayStart(start, 6, timeZone, locale);
 
 Map serviceCtx = UtilMisc.toMap("userLogin", userLogin,"start",start,"numPeriods",new Integer(7),
- "periodType",new Integer(Calendar.DATE));
+        "periodType",new Integer(Calendar.DATE));
 serviceCtx.putAll(UtilMisc.toMap("partyId", partyId, "facilityId", facilityId,
- "fixedAssetId", fixedAssetId, "workEffortTypeId", workEffortTypeId,
- "locale", locale, "timeZone", timeZone));
+        "fixedAssetId", fixedAssetId, "workEffortTypeId", workEffortTypeId,
+        "locale", locale, "timeZone", timeZone));
 if (entityExprList) {
     serviceCtx.putAll(["entityExprList" : entityExprList]);
 }

Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/component/ComponentConfig.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/component/ComponentConfig.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/component/ComponentConfig.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/component/ComponentConfig.java Mon Aug 17 11:01:25 2009
@@ -86,12 +86,12 @@
     }
 
     public static Boolean componentExists(String componentName) {
-     ComponentConfig componentConfig = componentConfigs.get(componentName);
-     if (componentConfig == null) {
-     return Boolean.FALSE;
-     } else {
-     return Boolean.TRUE;
-     }
+        ComponentConfig componentConfig = componentConfigs.get(componentName);
+        if (componentConfig == null) {
+            return Boolean.FALSE;
+        } else {
+            return Boolean.TRUE;
+        }
     }
     
     public static Collection<ComponentConfig> getAllComponents() {

Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilDateTime.java Mon Aug 17 11:01:25 2009
@@ -851,7 +851,7 @@
     }
 
     public static Timestamp getWeekEnd(Timestamp stamp, TimeZone timeZone, Locale locale) {
-     Timestamp weekStart = getWeekStart(stamp, timeZone, locale);
+        Timestamp weekStart = getWeekStart(stamp, timeZone, locale);
         Calendar tempCal = toCalendar(weekStart, timeZone, locale);
         tempCal.add(Calendar.DAY_OF_MONTH, 6);
         return getDayEnd(new Timestamp(tempCal.getTimeInMillis()), timeZone, locale);

Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilMisc.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilMisc.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilMisc.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/util/UtilMisc.java Mon Aug 17 11:01:25 2009
@@ -757,7 +757,7 @@
 
     /** This is meant to be very quick to create and use for small sized maps, perfect for how we usually use UtilMisc.toMap */
     @SuppressWarnings("serial")
- protected static class SimpleMap<V> implements Map<String, V>, java.io.Serializable {
+    protected static class SimpleMap<V> implements Map<String, V>, java.io.Serializable {
         protected Map<String, V> realMapIfNeeded = null;
 
         String[] names;

Modified: ofbiz/trunk/framework/bi/webapp/bi/main.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/bi/webapp/bi/main.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/bi/webapp/bi/main.ftl (original)
+++ ofbiz/trunk/framework/bi/webapp/bi/main.ftl Mon Aug 17 11:01:25 2009
@@ -1,38 +1,38 @@
 
 <h1>${uiLabelMap.BusinessIntelligenceIntegratedFramework}</h1>
 <p>
- ${uiLabelMap.BusinessIntelligenceNote1}
- ${uiLabelMap.BusinessIntelligenceNote2}
- ${uiLabelMap.BusinessIntelligenceNote3}
- ${uiLabelMap.BusinessIntelligenceNote4}
- ${uiLabelMap.BusinessIntelligenceNote5}
- ${uiLabelMap.BusinessIntelligenceNote6}
- ${uiLabelMap.BusinessIntelligenceNote7}
- ${uiLabelMap.BusinessIntelligenceNote8}
- ${uiLabelMap.BusinessIntelligenceNote9}
- ${uiLabelMap.BusinessIntelligenceNote10}
- ${uiLabelMap.BusinessIntelligenceNote11}
- ${uiLabelMap.BusinessIntelligenceNote12}
+    ${uiLabelMap.BusinessIntelligenceNote1}
+    ${uiLabelMap.BusinessIntelligenceNote2}
+    ${uiLabelMap.BusinessIntelligenceNote3}
+    ${uiLabelMap.BusinessIntelligenceNote4}
+    ${uiLabelMap.BusinessIntelligenceNote5}
+    ${uiLabelMap.BusinessIntelligenceNote6}
+    ${uiLabelMap.BusinessIntelligenceNote7}
+    ${uiLabelMap.BusinessIntelligenceNote8}
+    ${uiLabelMap.BusinessIntelligenceNote9}
+    ${uiLabelMap.BusinessIntelligenceNote10}
+    ${uiLabelMap.BusinessIntelligenceNote11}
+    ${uiLabelMap.BusinessIntelligenceNote12}
 </p>
 <h2>${uiLabelMap.BusinessIntelligenceCurrentStatus}</h2>
 <p>
- ${uiLabelMap.BusinessIntelligenceNote13}
- ${uiLabelMap.BusinessIntelligenceNote14}
- ${uiLabelMap.BusinessIntelligenceNote15}
- ${uiLabelMap.BusinessIntelligenceNote16}
- ${uiLabelMap.BusinessIntelligenceNote17}
- ${uiLabelMap.BusinessIntelligenceNote18}
+    ${uiLabelMap.BusinessIntelligenceNote13}
+    ${uiLabelMap.BusinessIntelligenceNote14}
+    ${uiLabelMap.BusinessIntelligenceNote15}
+    ${uiLabelMap.BusinessIntelligenceNote16}
+    ${uiLabelMap.BusinessIntelligenceNote17}
+    ${uiLabelMap.BusinessIntelligenceNote18}
 </p>
 <h2>${uiLabelMap.BusinessIntelligenceQuickStartGuide}</h2>
 <p>
- ${uiLabelMap.BusinessIntelligenceNote19}
- ${uiLabelMap.BusinessIntelligenceNote20}
- ${uiLabelMap.BusinessIntelligenceNote21}
- ${uiLabelMap.BusinessIntelligenceNote22}
- ${uiLabelMap.BusinessIntelligenceNote23}
- ${uiLabelMap.BusinessIntelligenceNote24}
- ${uiLabelMap.BusinessIntelligenceNote25}
- ${uiLabelMap.BusinessIntelligenceNote26}
- ${uiLabelMap.BusinessIntelligenceNote27}
- ${uiLabelMap.BusinessIntelligenceNote28}
+    ${uiLabelMap.BusinessIntelligenceNote19}
+    ${uiLabelMap.BusinessIntelligenceNote20}
+    ${uiLabelMap.BusinessIntelligenceNote21}
+    ${uiLabelMap.BusinessIntelligenceNote22}
+    ${uiLabelMap.BusinessIntelligenceNote23}
+    ${uiLabelMap.BusinessIntelligenceNote24}
+    ${uiLabelMap.BusinessIntelligenceNote25}
+    ${uiLabelMap.BusinessIntelligenceNote26}
+    ${uiLabelMap.BusinessIntelligenceNote27}
+    ${uiLabelMap.BusinessIntelligenceNote28}
 </p>

Modified: ofbiz/trunk/framework/bi/webapp/bi/reportbuilder/RenderStarSchemaReport.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/bi/webapp/bi/reportbuilder/RenderStarSchemaReport.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/bi/webapp/bi/reportbuilder/RenderStarSchemaReport.ftl (original)
+++ ofbiz/trunk/framework/bi/webapp/bi/reportbuilder/RenderStarSchemaReport.ftl Mon Aug 17 11:01:25 2009
@@ -19,7 +19,7 @@
 
 <table cellspacing="0" class="basic-table hover-bar">
     <tr class="header-row">
-     <#assign firstRecord = records[0]?if_exists/>
+        <#assign firstRecord = records[0]?if_exists/>
         <#list columnNames as columnName>
         <td<#if firstRecord?exists && firstRecord[columnName]?default("")?is_number> class="align-text"</#if>>
             ${columnName}

Modified: ofbiz/trunk/framework/bi/widget/BiScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/bi/widget/BiScreens.xml?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/bi/widget/BiScreens.xml (original)
+++ ofbiz/trunk/framework/bi/widget/BiScreens.xml Mon Aug 17 11:01:25 2009
@@ -142,7 +142,7 @@
                 <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
                     <decorator-section name="body">
                         <container style="screenlet">
-                         <container>
+                            <container>
                                 <section>
                                     <widgets>
                                         <platform-specific>
@@ -152,17 +152,17 @@
                                 </section>
                             </container>
                             <container style="screenlet-body">
-                             <link target="quickInitDataWarehouse" text="${uiLabelMap.BusinessIntelligenceQuickInitDataWarehouse}" style="buttontext">
-                                 <parameter param-name="fromDate"/>
-                                 <parameter param-name="thruDate"/>
-                             </link>
-                             <label style="note"> (${uiLabelMap.CommonFromDate} ${fromDate} ${uiLabelMap.CommonThruDate} ${thruDate})</label>
-                             <label style="note">
-                                 ${uiLabelMap.BusinessIntelligenceNote29}
-                                 ${uiLabelMap.BusinessIntelligenceNote30}
-                                 ${uiLabelMap.BusinessIntelligenceNote31}
-                             </label>
-                         </container>
+                                <link target="quickInitDataWarehouse" text="${uiLabelMap.BusinessIntelligenceQuickInitDataWarehouse}" style="buttontext">
+                                    <parameter param-name="fromDate"/>
+                                    <parameter param-name="thruDate"/>
+                                </link>
+                                <label style="note"> (${uiLabelMap.CommonFromDate} ${fromDate} ${uiLabelMap.CommonThruDate} ${thruDate})</label>
+                                <label style="note">
+                                    ${uiLabelMap.BusinessIntelligenceNote29}
+                                    ${uiLabelMap.BusinessIntelligenceNote30}
+                                    ${uiLabelMap.BusinessIntelligenceNote31}
+                                </label>
+                            </container>
                         </container>
                     </decorator-section>
                 </decorator-screen>

Modified: ofbiz/trunk/framework/common/webcommon/WEB-INF/actions/includes/GetParentPortalPageId.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/webcommon/WEB-INF/actions/includes/GetParentPortalPageId.groovy?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/webcommon/WEB-INF/actions/includes/GetParentPortalPageId.groovy (original)
+++ ofbiz/trunk/framework/common/webcommon/WEB-INF/actions/includes/GetParentPortalPageId.groovy Mon Aug 17 11:01:25 2009
@@ -24,31 +24,31 @@
 
 // executes only on startup when only the basic parameters.portalPageId (from commonscreens.xml) is available
 if (userLogin && parameters.parentPortalPageId && !parameters.portalPageId) {
- // look for system page according the current securitygroup
- //get the security group
- condSec = EntityCondition.makeCondition([
- EntityCondition.makeCondition("portalPageId", EntityOperator.LIKE, parameters.parentPortalPageId + "%"),
+    // look for system page according the current securitygroup
+    //get the security group
+    condSec = EntityCondition.makeCondition([
+            EntityCondition.makeCondition("portalPageId", EntityOperator.LIKE, parameters.parentPortalPageId + "%"),
             EntityCondition.makeCondition("parentPortalPageId", EntityOperator.EQUALS, null),
- EntityCondition.makeCondition("userLoginId", EntityOperator.EQUALS, userLogin.userLoginId)
- ],EntityOperator.AND);
- portalMainPages = EntityUtil.filterByDate(delegator.findList("PortalPageAndUserLogin", condSec, null, null, null, false));
- if (!portalMainPages) { // look for a null securityGroup if not found
-    condSec = EntityCondition.makeCondition([
+            EntityCondition.makeCondition("userLoginId", EntityOperator.EQUALS, userLogin.userLoginId)
+            ],EntityOperator.AND);
+    portalMainPages = EntityUtil.filterByDate(delegator.findList("PortalPageAndUserLogin", condSec, null, null, null, false));
+    if (!portalMainPages) { // look for a null securityGroup if not found
+        condSec = EntityCondition.makeCondition([
             EntityCondition.makeCondition("securityGroupId", EntityOperator.EQUALS, null),
             EntityCondition.makeCondition("parentPortalPageId", EntityOperator.EQUALS, null),
             EntityCondition.makeCondition("portalPageId", EntityOperator.LIKE, parameters.parentPortalPageId + "%")
-        ],EntityOperator.AND);
-    portalMainPages = delegator.findList("PortalPage", condSec, null, null, null, false);
- }
+            ],EntityOperator.AND);
+        portalMainPages = delegator.findList("PortalPage", condSec, null, null, null, false);
+    }
     if (portalMainPages) {
-     portalPageId = portalMainPages.get(0).portalPageId;
-     // check if overridden with a privat page
-     privatMainPages = delegator.findByAnd("PortalPage", [originalPortalPageId : portalPageId, ownerUserLoginId : userLogin.userLoginId]);
-     if (privatMainPages) {
+        portalPageId = portalMainPages.get(0).portalPageId;
+        // check if overridden with a privat page
+        privatMainPages = delegator.findByAnd("PortalPage", [originalPortalPageId : portalPageId, ownerUserLoginId : userLogin.userLoginId]);
+        if (privatMainPages) {
             context.parameters.portalPageId = privatMainPages.get(0).portalPageId;
-     } else {
-     context.parameters.portalPageId = portalPageId;
-     }
+        } else {
+            context.parameters.portalPageId = portalPageId;
+        }
     }
 }
 // Debug.log('======portalPageId: ' + parameters.portalPageId);
@@ -58,11 +58,11 @@
         if (portalPage.parentPortalPageId) {
             context.parameters.parentPortalPageId = portalPage.parentPortalPageId;
         } else {
-         if ("_NA_".equals(portalPage.ownerUserLoginId)) {
-         context.parameters.parentPortalPageId = portalPage.portalPageId;
-         } else {
+            if ("_NA_".equals(portalPage.ownerUserLoginId)) {
+                context.parameters.parentPortalPageId = portalPage.portalPageId;
+            } else {
                 context.parameters.parentPortalPageId = portalPage.originalPortalPageId;
-         }
+            }
         }
     }
 }

Modified: ofbiz/trunk/framework/common/webcommon/includes/ajaxAutocompleteOptions.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/webcommon/includes/ajaxAutocompleteOptions.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/webcommon/includes/ajaxAutocompleteOptions.ftl (original)
+++ ofbiz/trunk/framework/common/webcommon/includes/ajaxAutocompleteOptions.ftl Mon Aug 17 11:01:25 2009
@@ -20,7 +20,7 @@
 <#if autocompleteOptions?exists>
   <ul>
     <#list autocompleteOptions as autocompleteOption>
-    <#assign fields = autocompleteOption.values()/>
+        <#assign fields = autocompleteOption.values()/>
       <li><#list fields as field><#if field_index == 1><span class="informal"> </#if>${field}<#if (field_index > 0)><#if field_has_next> <#else></span></#if></#if></#list></li>
     </#list>
   </ul>

Modified: ofbiz/trunk/framework/common/webcommon/includes/insertDropDown.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/webcommon/includes/insertDropDown.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/webcommon/includes/insertDropDown.ftl (original)
+++ ofbiz/trunk/framework/common/webcommon/includes/insertDropDown.ftl Mon Aug 17 11:01:25 2009
@@ -23,12 +23,12 @@
   <#if topLine.dropDownList.size() gt 1>
   <#if topLine.hiddenFieldList?exists>
     <#list topLine.hiddenFieldList as field>
-  <input type="hidden" name="${field.name}" value="${field.value}"/>
+      <input type="hidden" name="${field.name}" value="${field.value}"/>
     </#list>
   </#if>
   <select name="${topLine.selectionName?if_exists}" onChange="javascript:document.${topLine.action}.submit();">
     <#list topLine.dropDownList as option>
-  <option <#if option.key == topLine.selectedKey >selected="selected"</#if> value="${option.key?if_exists}">${option.value?if_exists}</option>
+      <option <#if option.key == topLine.selectedKey >selected="selected"</#if> value="${option.key?if_exists}">${option.value?if_exists}</option>
     </#list>
   </select>
 <#else>

Modified: ofbiz/trunk/framework/common/webcommon/includes/lookup.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/webcommon/includes/lookup.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/webcommon/includes/lookup.ftl (original)
+++ ofbiz/trunk/framework/common/webcommon/includes/lookup.ftl Mon Aug 17 11:01:25 2009
@@ -97,15 +97,15 @@
             var thisForm = obj_caller.target.form;
             var evalString = "";
 
-     if (arguments.length > 2 ) {
-         for(var i=1; i < arguments.length; i=i+2) {
+            if (arguments.length > 2 ) {
+                for(var i=1; i < arguments.length; i=i+2) {
                     evalString = "setSourceColor(thisForm." + arguments[i] + ")";
                     eval(evalString);
-         evalString = "thisForm." + arguments[i] + ".value='" + arguments[i+1] + "'";
-         eval(evalString);
-         }
-     }
-     window.close();
+                    evalString = "thisForm." + arguments[i] + ".value='" + arguments[i+1] + "'";
+                    eval(evalString);
+                }
+            }
+            window.close();
          }
     </script>
 </head>

Modified: ofbiz/trunk/framework/common/webcommon/portal/editPortalPage.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/webcommon/portal/editPortalPage.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/webcommon/portal/editPortalPage.ftl (original)
+++ ofbiz/trunk/framework/common/webcommon/portal/editPortalPage.ftl Mon Aug 17 11:01:25 2009
@@ -30,15 +30,15 @@
             <input name="portalPageId" value="${portalPage.portalPageId}" type="hidden"/>
             <input name="columnSeqId" value="${portalPageColumn.columnSeqId}" type="hidden"/>
             <input name="parentPortalPageId" value="${parameters.parentPortalPageId}" type="hidden"/>
-        <select name="columnWidthPercentage" onchange="javascript:document.updatePortalPageColum_${portalPageColumn_index}.submit()">
-          <option value="">${uiLabelMap.CommonSetColumnWidth}</option>
-          <option <#if portalPageColumn.columnWidthPercentage?default(0) == 10> selected</#if> value="25">25%</option>
-          <option <#if portalPageColumn.columnWidthPercentage?default(0) == 20> selected</#if> value="50">50%</option>
-          <option <#if portalPageColumn.columnWidthPercentage?default(0) == 30> selected</#if> value="75">75%</option>
-        </select>
-       </form>
-      </li>
-    </ul>
+            <select name="columnWidthPercentage" onchange="javascript:document.updatePortalPageColum_${portalPageColumn_index}.submit()">
+              <option value="">${uiLabelMap.CommonSetColumnWidth}</option>
+              <option <#if portalPageColumn.columnWidthPercentage?default(0) == 10> selected</#if> value="25">25%</option>
+              <option <#if portalPageColumn.columnWidthPercentage?default(0) == 20> selected</#if> value="50">50%</option>
+              <option <#if portalPageColumn.columnWidthPercentage?default(0) == 30> selected</#if> value="75">75%</option>
+            </select>
+           </form>
+          </li>
+        </ul>
       </td>
       <#if portalPageColumn_has_next>
         <td>&nbsp;</td>

Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
+++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Mon Aug 17 11:01:25 2009
@@ -232,14 +232,14 @@
                     </widgets>
                     <fail-widgets>
                         <screenlet title="${title}" id="findScreenlet" collapsible="true" padded="false">
-                        <container id="search-options">
-                            <decorator-section-include name="search-options"/>
-                        </container>
+                            <container id="search-options">
+                                <decorator-section-include name="search-options"/>
+                            </container>
                         </screenlet>
                         <screenlet>
-                    <container id="search-results">
-                        <decorator-section-include name="search-results"/>
-                    </container>
+                            <container id="search-results">
+                                <decorator-section-include name="search-results"/>
+                            </container>
                         </screenlet>
                     </fail-widgets>
                 </section>

Modified: ofbiz/trunk/framework/entity/config/entityengine.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entity/config/entityengine.xml?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/entity/config/entityengine.xml (original)
+++ ofbiz/trunk/framework/entity/config/entityengine.xml Mon Aug 17 11:01:25 2009
@@ -38,7 +38,7 @@
     </transaction-factory>
     -->
     <!--
-     It is common to use UserTransaction for the TransactionManager, but if that doesn't work, try this: <transaction-manager-jndi jndi-server-name="default" jndi-name="java:comp/TransactionManager"/>
+        It is common to use UserTransaction for the TransactionManager, but if that doesn't work, try this: <transaction-manager-jndi jndi-server-name="default" jndi-name="java:comp/TransactionManager"/>
         Common UserTransaction locations:
             java:comp/UserTransaction (most servers: Resin, Orion, OC4J, etc)
             UserTransaction (RexIP)

Modified: ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaUtil.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaUtil.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaUtil.java (original)
+++ ofbiz/trunk/framework/entityext/src/org/ofbiz/entityext/eca/EntityEcaUtil.java Mon Aug 17 11:01:25 2009
@@ -125,7 +125,7 @@
             numDefs++;
         }
         try {
-         Debug.logImportant("Loaded [" + numDefs + "] Entity ECA definitions from " + handler.getFullLocation() + " in loader " + handler.getLoaderName(), module);
+            Debug.logImportant("Loaded [" + numDefs + "] Entity ECA definitions from " + handler.getFullLocation() + " in loader " + handler.getLoaderName(), module);
         } catch (GenericConfigException e) {
             Debug.logError(e, module);
             return;

Modified: ofbiz/trunk/framework/example/webapp/appheader.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/webapp/appheader.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/example/webapp/appheader.ftl (original)
+++ ofbiz/trunk/framework/example/webapp/appheader.ftl Mon Aug 17 11:01:25 2009
@@ -29,11 +29,11 @@
         <li <#if selected = "${uiLabelMap.ExampleFormWidgetExamples}"> class="selected"</#if>><a href="<@ofbizUrl>FormWidgetExamples?portalPageId=${uiLabelMap.ExampleFormWidgetExamples}</@ofbizUrl>">${uiLabelMap.ExampleFormWidgetExamples}</a></li>
         <li <#if selected = "${uiLabelMap.ExampleAjaxExamples}"> class="selected"</#if>><a href="<@ofbizUrl>authview/findExampleAjax?portalPageId=${uiLabelMap.ExampleAjaxExamples}</@ofbizUrl>">${uiLabelMap.ExampleAjaxExamples}</a></li>
         <#if portalPages?has_content>
-         <#list portalPages as page>
-          <#if page.portalPageName?has_content>
-             <li<#if selected = "${page.portalPageId}"> class="selected"</#if>><a href="<@ofbizUrl>showPortalPage?portalPageId=${page.portalPageId}</@ofbizUrl>"><#if page.portalPageName?exists>${page.portalPageName}<#else>?</#if></a></li>
+            <#list portalPages as page>
+              <#if page.portalPageName?has_content>
+                <li<#if selected = "${page.portalPageId}"> class="selected"</#if>><a href="<@ofbizUrl>showPortalPage?portalPageId=${page.portalPageId}</@ofbizUrl>"><#if page.portalPageName?exists>${page.portalPageName}<#else>?</#if></a></li>
               </#if>
-         </#list>
+            </#list>
         </#if>
         <li class="opposed"><a href="<@ofbizUrl>ManagePortalPages?parentPortalPageId=EXAMPLE</@ofbizUrl>">${uiLabelMap.CommonDashboard}</a></li>
       </#if>

Modified: ofbiz/trunk/framework/example/webapp/example/reports/fonts.fo.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/example/webapp/example/reports/fonts.fo.ftl?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/example/webapp/example/reports/fonts.fo.ftl (original)
+++ ofbiz/trunk/framework/example/webapp/example/reports/fonts.fo.ftl Mon Aug 17 11:01:25 2009
@@ -29,8 +29,8 @@
 
    <fo:page-sequence master-reference="portrait" initial-page-number="1">
      <fo:flow flow-name="xsl-region-body">
- <fo:block text-align="center">Font samples</fo:block>
- <fo:block></fo:block>
+    <fo:block text-align="center">Font samples</fo:block>
+    <fo:block></fo:block>
         <fo:block color="red">Helvetica</fo:block>
         <fo:block font-family="Helvetica" font-style="normal" font-weight="normal">the quick brown fox jumps over the lazy dog 1234657890</fo:block>
         <fo:block font-family="Helvetica" font-style="normal" font-weight="bold">the quick brown fox jumps over the lazy dog 1234657890</fo:block>

Modified: ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java (original)
+++ ofbiz/trunk/framework/minilang/src/org/ofbiz/minilang/method/callops/CallService.java Mon Aug 17 11:01:25 2009
@@ -322,7 +322,7 @@
                 methodContext.putEnv(simpleMethod.getEventErrorMessageName(), errorMessage);
             } else if (methodContext.getMethodType() == MethodContext.SERVICE) {
                 ServiceUtil.addErrors(UtilMisc.<String, String>getListFromMap(methodContext.getEnvMap(), this.simpleMethod.getServiceErrorMessageListName()),
-                 UtilMisc.<String, String, Object>getMapFromMap(methodContext.getEnvMap(), this.simpleMethod.getServiceErrorMessageMapName()), result);
+                        UtilMisc.<String, String, Object>getMapFromMap(methodContext.getEnvMap(), this.simpleMethod.getServiceErrorMessageMapName()), result);
                 // the old way, makes a mess of messages passed up the stack: methodContext.putEnv(simpleMethod.getServiceErrorMessageName(), errorMessage);
                 Debug.logError(new Exception(errorMessage), module);
             }

Modified: ofbiz/trunk/framework/resources/templates/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/resources/templates/build.xml?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/resources/templates/build.xml (original)
+++ ofbiz/trunk/framework/resources/templates/build.xml Mon Aug 17 11:01:25 2009
@@ -9,7 +9,7 @@
 
     <property environment="env"/>
     <property name="desc" value="@component-resource-name@ Component"/>
- <property name="name" value="ofbiz-@component-name@"/>
+    <property name="name" value="ofbiz-@component-name@"/>
     <property name="component-name" value="ofbiz-@component-name@"/>
     <property name="ofbiz.home.dir" value="../.."/>
     <property name="src.dir" value="src"/>

Modified: ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/AbstractAuthorization.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/AbstractAuthorization.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/AbstractAuthorization.java (original)
+++ ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/AbstractAuthorization.java Mon Aug 17 11:01:25 2009
@@ -31,91 +31,91 @@
 import org.ofbiz.base.util.string.FlexibleStringExpander;
 
 public abstract class AbstractAuthorization implements Authorization {
-
+    
     private static final String module = AbstractAuthorization.class.getName();
     
- /**
- * Used to manage Auto-Grant permissions for the current "request"
- */
- private static ThreadLocal<List<String>> autoGrant = new ThreadLocal<List<String>>();
- private static ThreadLocal<String> origPermission = new ThreadLocal<String>();
- private static ThreadLocal<String> uid = new ThreadLocal<String>();
-
- private static final String[] basePermissions = { "access", "create", "read", "update", "delete" };
-
- /**
- * Checks to see if the user has a static permission
- *
- * @param userId the user's userId
- * @param permission the expanded permission string
- * @param context name/value pairs used for permission lookup
- * @return true if the user has permission
- */
- public abstract boolean hasStaticPermission(String userId, String permission, Map<String, ? extends Object> context);
-
- /**
- * Locates the Dynamic Access implementation for the permissions and invokes it
- *
- * @param userId the user's userId
- * @param permission the expanded permission string
- * @param context name/value pairs used for permission lookup
- * @return true if the user has permission
- */
- public abstract boolean hasDynamicPermission(String userId, String permission, Map<String, ? extends Object> context);
-
- /**
- * Obtains a list of permissions auto-granted by the given permission
- *
- * @param userId the user's userId
- * @param permission the expanded permission string
- * @param context name/value pairs used for permission lookup
- * @return a List of permission strings to auto-grant the user
- */
- public abstract List<String> getAutoGrantPermissions(String userId, String permission, Map<String, ? extends Object> context);
-
- /**
- * Takes a regular expression (permissionRegexp) and evaluates it against base permissions and returns permission
- * values for each match.
- * Example 1: ".*:example" will return values for access:example, create:example, read:example, update:example and delete:example
- * Example 2: "(access|read):example:${exampleId} will return values for access:example:${exampleId} and read:example:${exampleId}
- *  
- * NOTE: the regular expression can only be part of the base permission (before the first colon)
- *
- * @param userId the user's userId
- * @param permissionRegexp permission string containing regexp in the base position
- * @param expanded  true if the permission string is already expanded, false if it will contain ${} context values
- * @return
- */
- public Map<String, Boolean> findMatchingPermission(String userId, String permissionRegexp, Map<String, ? extends Object> context) {
-    Map<String, Boolean> resultMap = FastMap.newInstance();
-    
-    String regexp = permissionRegexp.substring(0, permissionRegexp.indexOf(":"));
-    String permStr = permissionRegexp.substring(permissionRegexp.indexOf(":"));
-    
-    Pattern p = Pattern.compile("^" + regexp + ":.*$");
-    for (String base : basePermissions) {
-        Matcher m = p.matcher(base + permStr);
-        if (m.find()) {
-            String permission = m.group();
-            resultMap.put(permission, hasPermission(userId, permission, context));
-        }
-    }
-    return resultMap;
- }
-
- /**
- * Test to see if the specified user has permission
- *
- * @param userId the user's userId
- * @param permission the raw permission string
- * @param context name/value pairs used for permission lookup
- * @return true if the user has permission
- */
- public boolean hasPermission(String userId, String permission, Map<String, ? extends Object> context) {
-    // expand the permission string
- String expandedPermission = FlexibleStringExpander.expandString(permission, context);
-
- // verify the ThreadLocal data; make sure it isn't stale (from a thread pool)
+    /**
+     * Used to manage Auto-Grant permissions for the current "request"
+     */
+    private static ThreadLocal<List<String>> autoGrant = new ThreadLocal<List<String>>();
+    private static ThreadLocal<String> origPermission = new ThreadLocal<String>();
+    private static ThreadLocal<String> uid = new ThreadLocal<String>();
+    
+    private static final String[] basePermissions = { "access", "create", "read", "update", "delete" };
+    
+    /**
+     * Checks to see if the user has a static permission
+     *
+     * @param userId the user's userId
+     * @param permission the expanded permission string
+     * @param context name/value pairs used for permission lookup
+     * @return true if the user has permission
+     */
+    public abstract boolean hasStaticPermission(String userId, String permission, Map<String, ? extends Object> context);
+    
+    /**
+     * Locates the Dynamic Access implementation for the permissions and invokes it
+     *
+     * @param userId the user's userId
+     * @param permission the expanded permission string
+     * @param context name/value pairs used for permission lookup
+     * @return true if the user has permission
+     */
+    public abstract boolean hasDynamicPermission(String userId, String permission, Map<String, ? extends Object> context);
+    
+    /**
+     * Obtains a list of permissions auto-granted by the given permission
+     *
+     * @param userId the user's userId
+     * @param permission the expanded permission string
+     * @param context name/value pairs used for permission lookup
+     * @return a List of permission strings to auto-grant the user
+     */
+    public abstract List<String> getAutoGrantPermissions(String userId, String permission, Map<String, ? extends Object> context);
+    
+    /**
+     * Takes a regular expression (permissionRegexp) and evaluates it against base permissions and returns permission
+     * values for each match.
+     * Example 1: ".*:example" will return values for access:example, create:example, read:example, update:example and delete:example
+     * Example 2: "(access|read):example:${exampleId} will return values for access:example:${exampleId} and read:example:${exampleId}
+     *  
+     * NOTE: the regular expression can only be part of the base permission (before the first colon)
+     *
+     * @param userId the user's userId
+     * @param permissionRegexp permission string containing regexp in the base position    
+     * @param expanded  true if the permission string is already expanded, false if it will contain ${} context values
+     * @return
+     */
+    public Map<String, Boolean> findMatchingPermission(String userId, String permissionRegexp, Map<String, ? extends Object> context) {
+        Map<String, Boolean> resultMap = FastMap.newInstance();
+        
+        String regexp = permissionRegexp.substring(0, permissionRegexp.indexOf(":"));
+        String permStr = permissionRegexp.substring(permissionRegexp.indexOf(":"));
+        
+        Pattern p = Pattern.compile("^" + regexp + ":.*$");
+        for (String base : basePermissions) {
+            Matcher m = p.matcher(base + permStr);
+            if (m.find()) {
+                String permission = m.group();
+                resultMap.put(permission, hasPermission(userId, permission, context));
+            }
+        }
+        return resultMap;
+    }
+    
+    /**
+     * Test to see if the specified user has permission
+     *
+     * @param userId the user's userId
+     * @param permission the raw permission string
+     * @param context name/value pairs used for permission lookup    
+     * @return true if the user has permission
+     */
+    public boolean hasPermission(String userId, String permission, Map<String, ? extends Object> context) {
+        // expand the permission string
+        String expandedPermission = FlexibleStringExpander.expandString(permission, context);
+        
+        // verify the ThreadLocal data; make sure it isn't stale (from a thread pool)
         String threadUid = uid.get();
         if (threadUid != null && !userId.equals(threadUid)) {
             origPermission.remove();
@@ -131,68 +131,68 @@
             uid.set(userId);
             initialCall = true;
         }
-                      
- // split the permission string; so we can walk up the levels
- String[] permSplit = expandedPermission.split(":");
- StringBuilder joined = new StringBuilder();
- int index = 1;
-
- if (permSplit != null && permSplit.length > 1) {
-    if (Debug.verboseOn()) Debug.logVerbose("Security 2.0 schema found -- walking tree : " + expandedPermission, module);
-     // start walking
-     for (String perm : permSplit) {
-        if (permSplit.length >= index) {
-         if (joined.length() > 0) {
-         joined.append(":");
-         }
-         joined.append(perm);
-        
-         // first check auto-granted permissions
-         List<String> grantedPerms = autoGrant.get();
-         if (grantedPerms != null && grantedPerms.size() > 0) {
-            Debug.logVerbose("Auto-Grant permissions found; looking for a match", module);
-         for (String granted : grantedPerms) {
-            if (Debug.verboseOn()) Debug.logVerbose("Testing - " + granted + " - with - " + joined.toString(), module);
-         if (joined.toString().equals(granted)) {
-            // permission granted
-            handleAutoGrantPermissions(userId, expandedPermission, context);
-         return true;
-         }
-         }
-         }
-        
-         // next check static permission
-         if (hasStaticPermission(userId, joined.toString(), context)) {
-         // permission granted
-         handleAutoGrantPermissions(userId, expandedPermission, context);
-         return true;
-         }
-        }
-     index++;
-     }
-    
-     // finally check dynamic permission (outside the loop)
-     String threadPerm = origPermission.get();
-     if (initialCall || !permission.equals(threadPerm)) {
-         if (hasDynamicPermission(userId, expandedPermission, context)) {
-            // permission granted
-            handleAutoGrantPermissions(userId, expandedPermission, context);
-            return true;
-         }
-     } else {
-        Debug.logWarning("Recursive permission check detected; do not call hasPermission() from a dynamic access implementation!", module);
-     }
- } else {
-    // legacy mode; only call static permission check; no auto grants
-    Debug.logVerbose("Legacy permission detected; falling back to static permission check", module);
-    return hasStaticPermission(userId, expandedPermission, context);
- }
- return false;
- }
-
- protected void handleAutoGrantPermissions(String userId, String expandedPermission, Map<String, ? extends Object> context) {        
-    List<String> granted = getAutoGrantPermissions(userId, expandedPermission, context);
-    if (granted != null && granted.size() > 0) {
+                          
+        // split the permission string; so we can walk up the levels
+        String[] permSplit = expandedPermission.split(":");
+        StringBuilder joined = new StringBuilder();
+        int index = 1;
+        
+        if (permSplit != null && permSplit.length > 1) {
+            if (Debug.verboseOn()) Debug.logVerbose("Security 2.0 schema found -- walking tree : " + expandedPermission, module);
+            // start walking
+            for (String perm : permSplit) {
+                if (permSplit.length >= index) {
+                    if (joined.length() > 0) {
+                        joined.append(":");
+                    }
+                    joined.append(perm);
+                    
+                    // first check auto-granted permissions
+                    List<String> grantedPerms = autoGrant.get();
+                    if (grantedPerms != null && grantedPerms.size() > 0) {
+                        Debug.logVerbose("Auto-Grant permissions found; looking for a match", module);
+                        for (String granted : grantedPerms) {
+                            if (Debug.verboseOn()) Debug.logVerbose("Testing - " + granted + " - with - " + joined.toString(), module);
+                            if (joined.toString().equals(granted)) {
+                                // permission granted
+                                handleAutoGrantPermissions(userId, expandedPermission, context);
+                                return true;
+                            }
+                        }
+                    }
+                    
+                    // next check static permission
+                    if (hasStaticPermission(userId, joined.toString(), context)) {
+                        // permission granted
+                        handleAutoGrantPermissions(userId, expandedPermission, context);
+                        return true;
+                    }
+                }
+                index++;
+            }
+            
+            // finally check dynamic permission (outside the loop)
+            String threadPerm = origPermission.get();
+            if (initialCall || !permission.equals(threadPerm)) {
+                if (hasDynamicPermission(userId, expandedPermission, context)) {
+                    // permission granted
+                    handleAutoGrantPermissions(userId, expandedPermission, context);
+                    return true;
+                }
+            } else {
+                Debug.logWarning("Recursive permission check detected; do not call hasPermission() from a dynamic access implementation!", module);
+            }
+        } else {
+            // legacy mode; only call static permission check; no auto grants
+            Debug.logVerbose("Legacy permission detected; falling back to static permission check", module);
+            return hasStaticPermission(userId, expandedPermission, context);
+        }
+        return false;
+    }
+    
+    protected void handleAutoGrantPermissions(String userId, String expandedPermission, Map<String, ? extends Object> context) {                
+        List<String> granted = getAutoGrantPermissions(userId, expandedPermission, context);
+        if (granted != null && granted.size() > 0) {
             List<String> alreadyGranted = autoGrant.get();
             if (alreadyGranted == null) {
                 alreadyGranted = FastList.newInstance();
@@ -208,15 +208,15 @@
             }
             autoGrant.set(granted);            
         }
- }
-
- /**
- * Used to clear the values set in ThreadLocal
- * -- needed when thread pools are used which do not handle clearing between requests
- */
- public static void clearThreadLocal() {
-    origPermission.remove();
+    }
+    
+    /**
+     * Used to clear the values set in ThreadLocal
+     * -- needed when thread pools are used which do not handle clearing between requests
+     */
+    public static void clearThreadLocal() {
+        origPermission.remove();
         autoGrant.remove();
         uid.remove();        
- }
+    }
 }

Modified: ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/Authorization.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/Authorization.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/Authorization.java (original)
+++ ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/Authorization.java Mon Aug 17 11:01:25 2009
@@ -26,17 +26,17 @@
 
 public interface Authorization {
 
- /**
- * Test to see if the specified user has permission
- *
- * @param userId the user's userId
- * @param permission the raw permission string
- * @param context name/value pairs used for permission lookup
- * @return true if the user has permission
- */
- public boolean hasPermission(String userId, String permission, Map<String, ? extends Object> context);
-      
- /**
+    /**
+     * Test to see if the specified user has permission
+     *
+     * @param userId the user's userId
+     * @param permission the raw permission string
+     * @param context name/value pairs used for permission lookup    
+     * @return true if the user has permission
+     */
+    public boolean hasPermission(String userId, String permission, Map<String, ? extends Object> context);
+              
+    /**
      * Test to see if the specified user has permission
      *
      * @param session HttpSession used to obtain the userId
@@ -45,7 +45,7 @@
      * @return true if the user has permission
      */
     public boolean hasPermission(HttpSession session, String permission, Map<String, ? extends Object> context);
-
+    
     /**
      * Takes a regular expression (permissionRegexp) and evaluates it against base permissions and returns permission
      * values for each match.

Modified: ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/EntityAuthorization.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/EntityAuthorization.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/EntityAuthorization.java (original)
+++ ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/EntityAuthorization.java Mon Aug 17 11:01:25 2009
@@ -41,7 +41,7 @@
 
     private static final String module = EntityAuthorization.class.getName();
     
- /**
+    /**
      * UtilCache to cache a Collection of UserLoginSecurityGroup entities for each UserLogin, by userLoginId.
      */
     private static UtilCache<String, List<GenericValue>> userLoginSecurityGroupByUserLoginId = new UtilCache<String, List<GenericValue>>("security.UserLoginSecurityGroupByUserLoginId");
@@ -60,72 +60,72 @@
     
     protected GenericDelegator delegator;
     
- @Override
- public List<String> getAutoGrantPermissions(String userId, String permission, Map<String, ? extends Object> context) {
-    if (Debug.verboseOn()) Debug.logVerbose("Running getAutoGrantPermissions()", module);
-    boolean checking = true;
-    String checkString = permission;
-    
-    while (checking) {
-        if (Debug.verboseOn()) Debug.logVerbose("Looking for auto-grant permissions for : " + checkString, module);
-        List<String> autoGrant = getPermissionAutoGrant(checkString);
-        if (autoGrant != null && autoGrant.size() > 0) {
-            return autoGrant;
-        }
-        if (checkString.indexOf(":") > -1) {
-            checkString = checkString.substring(0, checkString.lastIndexOf(":"));
-        } else {
-            checking = false;
-        }
-    }
- return null;
- }
-
- @Override
- public boolean hasDynamicPermission(String userId, String permission, Map<String, ? extends Object> context) {
-    if (Debug.verboseOn()) Debug.logVerbose("Running hasDynamicPermission()", module);    
- String permissionId = permission;
- boolean checking = true;
-
- // find the dynamic access implementation
- String dynamicAccess = null;
- while (checking) {
-    if (Debug.verboseOn()) Debug.logVerbose("Looking for dynamic access for permission -- " + permissionId, module);
-    dynamicAccess = getPermissionDynamicAccess(permissionId);
-    if (UtilValidate.isEmpty(dynamicAccess)) {
-        if (permissionId.indexOf(":") > -1) {
-            permissionId = permissionId.substring(0, permissionId.lastIndexOf(":"));
-        } else {
-            Debug.logVerbose("No sections left to check; no dynamic access implementation found", module);
-            checking = false;
-        }
-    } else {
-        if (Debug.verboseOn()) Debug.logVerbose("Dynamic access implementation found : " + dynamicAccess, module);
-        checking = false;
-    }
- }
-
- // if one exists invoke it
- if (UtilValidate.isNotEmpty(dynamicAccess)) {
-    // load the dynamic access handler and invoke it
-    if (Debug.verboseOn()) Debug.logVerbose("Loading DynamicAccessHandler for -- " + dynamicAccess, module);
-    DynamicAccessHandler dah = DynamicAccessFactory.getDynamicAccessHandler(delegator, dynamicAccess);
-    if (dah != null) {
-        if (Debug.verboseOn()) Debug.logVerbose("Calling DynamicAccessHandler : " + dah.getClass().getName(), module);
-        return dah.handleDynamicAccess(dynamicAccess, userId, permission, context);
-    } else {
-        if (Debug.verboseOn()) {
-            Debug.logVerbose("No DynamicAccessHandler found for pattern matching -- " + dynamicAccess, module);
-        }
-    }
- }
- return false;
- }
-
- @Override
- public boolean hasStaticPermission(String userId, String permission, Map<String, ? extends Object> context) {
-    if (Debug.verboseOn()) Debug.logVerbose("Running hasStaticPermission()", module);
-    Iterator<GenericValue> iterator = getUserLoginSecurityGroupByUserLoginId(userId);
+    @Override
+    public List<String> getAutoGrantPermissions(String userId, String permission, Map<String, ? extends Object> context) {
+        if (Debug.verboseOn()) Debug.logVerbose("Running getAutoGrantPermissions()", module);
+        boolean checking = true;
+        String checkString = permission;
+        
+        while (checking) {
+            if (Debug.verboseOn()) Debug.logVerbose("Looking for auto-grant permissions for : " + checkString, module);
+            List<String> autoGrant = getPermissionAutoGrant(checkString);
+            if (autoGrant != null && autoGrant.size() > 0) {
+                return autoGrant;
+            }
+            if (checkString.indexOf(":") > -1) {
+                checkString = checkString.substring(0, checkString.lastIndexOf(":"));
+            } else {
+                checking = false;
+            }
+        }
+        return null;
+    }
+
+    @Override
+    public boolean hasDynamicPermission(String userId, String permission, Map<String, ? extends Object> context) {
+        if (Debug.verboseOn()) Debug.logVerbose("Running hasDynamicPermission()", module);        
+        String permissionId = permission;
+        boolean checking = true;
+        
+        // find the dynamic access implementation
+        String dynamicAccess = null;
+        while (checking) {
+            if (Debug.verboseOn()) Debug.logVerbose("Looking for dynamic access for permission -- " + permissionId, module);
+            dynamicAccess = getPermissionDynamicAccess(permissionId);
+            if (UtilValidate.isEmpty(dynamicAccess)) {
+                if (permissionId.indexOf(":") > -1) {
+                    permissionId = permissionId.substring(0, permissionId.lastIndexOf(":"));
+                } else {
+                    Debug.logVerbose("No sections left to check; no dynamic access implementation found", module);
+                    checking = false;
+                }
+            } else {
+                if (Debug.verboseOn()) Debug.logVerbose("Dynamic access implementation found : " + dynamicAccess, module);
+                checking = false;
+            }
+        }
+        
+        // if one exists invoke it
+        if (UtilValidate.isNotEmpty(dynamicAccess)) {
+            // load the dynamic access handler and invoke it
+            if (Debug.verboseOn()) Debug.logVerbose("Loading DynamicAccessHandler for -- " + dynamicAccess, module);
+            DynamicAccessHandler dah = DynamicAccessFactory.getDynamicAccessHandler(delegator, dynamicAccess);
+            if (dah != null) {
+                if (Debug.verboseOn()) Debug.logVerbose("Calling DynamicAccessHandler : " + dah.getClass().getName(), module);
+                return dah.handleDynamicAccess(dynamicAccess, userId, permission, context);
+            } else {
+                if (Debug.verboseOn()) {
+                    Debug.logVerbose("No DynamicAccessHandler found for pattern matching -- " + dynamicAccess, module);
+                }
+            }
+        }
+        return false;
+    }
+
+    @Override
+    public boolean hasStaticPermission(String userId, String permission, Map<String, ? extends Object> context) {
+        if (Debug.verboseOn()) Debug.logVerbose("Running hasStaticPermission()", module);
+        Iterator<GenericValue> iterator = getUserLoginSecurityGroupByUserLoginId(userId);
         GenericValue userLoginSecurityGroup = null;
 
         while (iterator.hasNext()) {
@@ -135,9 +135,9 @@
             }
         }
         return false;
- }
-
- /**
+    }
+    
+    /**
      * Test to see if the specified user has permission
      *
      * @param session HttpSession used to obtain the userId
@@ -145,19 +145,19 @@
      * @param context name/value pairs used for permission lookup    
      * @return true if the user has permission
      */
- public boolean hasPermission(HttpSession session, String permission, Map<String, ? extends Object> context) {
+    public boolean hasPermission(HttpSession session, String permission, Map<String, ? extends Object> context) {
         GenericValue userLogin = (GenericValue) session.getAttribute("userLogin");
         if (userLogin != null) {
             return hasPermission(userLogin.getString("userLoginId"), permission, context);
         }
         return false;
     }
-
- public void setDelegator(GenericDelegator delegator) {
-    this.delegator = delegator;
- }
-
- private Iterator<GenericValue> getUserLoginSecurityGroupByUserLoginId(String userId) {
+    
+    public void setDelegator(GenericDelegator delegator) {
+        this.delegator = delegator;
+    }
+    
+    private Iterator<GenericValue> getUserLoginSecurityGroupByUserLoginId(String userId) {
         List<GenericValue> collection = userLoginSecurityGroupByUserLoginId.get(userId);
 
         if (collection == null) {
@@ -178,7 +178,7 @@
         collection = EntityUtil.filterByDate(collection, true);
         return collection.iterator();
     }
-
+    
     private boolean securityGroupHasPermission(String groupId, String permission) {
         GenericValue securityGroupPermissionValue = delegator.makeValue("SecurityGroupPermission",
                 UtilMisc.toMap("groupId", groupId, "permissionId", permission));
@@ -198,7 +198,7 @@
             securityGroupPermissionCache.put(securityGroupPermissionValue, exists);
         }
         return exists.booleanValue();
-    }
+    }    
     
     private List<String> getPermissionAutoGrant(String permission) {
         List<String> autoGrants = permissionAutoGrantCache.get(permission);

Modified: ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/da/DynamicAccess.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/da/DynamicAccess.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/da/DynamicAccess.java (original)
+++ ofbiz/trunk/framework/security/src/org/ofbiz/security/authz/da/DynamicAccess.java Mon Aug 17 11:01:25 2009
@@ -24,23 +24,23 @@
 
 public interface DynamicAccess {
 
- /**
- * Processes the dynamic permission check
- *
- * @param userId the user's userId
- * @param permission the raw permission string
- * @param context name/value pairs needed for permission lookup
- * @return true if the user has permission
- */
- public boolean hasPermission(String userId, String permission, Map<String, ? extends Object> context);
+    /**
+     * Processes the dynamic permission check
+     *
+     * @param userId the user's userId
+     * @param permission the raw permission string
+     * @param context name/value pairs needed for permission lookup
+     * @return true if the user has permission
+     */
+    public boolean hasPermission(String userId, String permission, Map<String, ? extends Object> context);
 
- /**
- * Returns the name of the permission this object handles
- * @return permission name
- */
- public String getPermissionName();
-
- /**
+    /**
+     * Returns the name of the permission this object handles
+     * @return permission name
+     */
+    public String getPermissionName();
+    
+    /**
      * Method for injecting the delegator object
      *
      * @param delegator the GenericDelegator object to use for the Authorization implementation

Modified: ofbiz/trunk/framework/testtools/build.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/testtools/build.xml?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/testtools/build.xml (original)
+++ ofbiz/trunk/framework/testtools/build.xml Mon Aug 17 11:01:25 2009
@@ -34,7 +34,7 @@
         <fileset dir="../base/lib" includes="*.jar"/>
         <fileset dir="../base/lib/scripting" includes="*.jar"/>
         <fileset dir="../base/lib/commons" includes="*.jar"/>
-     <fileset dir="../base/build/lib" includes="*.jar"/>
+        <fileset dir="../base/build/lib" includes="*.jar"/>
         <fileset dir="../entity/lib" includes="*.jar"/>
         <fileset dir="../entity/build/lib" includes="*.jar"/>
         <fileset dir="../security/build/lib" includes="*.jar"/>
@@ -43,11 +43,11 @@
         <fileset dir="../minilang/build/lib" includes="*.jar"/>
         <fileset dir="../webapp/lib" includes="*.jar"/>
     </path>
-
- <target name="init">
- <property name="lib.dir" value="lib"/>
- <property name="selenium.lib.dir" value="${lib.dir}"/>
- </target>
+    
+    <target name="init">
+        <property name="lib.dir" value="lib"/>
+        <property name="selenium.lib.dir" value="${lib.dir}"/>
+    </target>
 
     <!-- ================================================================== -->
     <!-- Compilation of the source files                                                                                                                         -->
@@ -58,11 +58,11 @@
     </target>
 
 
- <target name="install-seleniumxml" depends="init" description="Download the selenium files">
+    <target name="install-seleniumxml" depends="init" description="Download the selenium files">
         <!--mkdir dir="${selenium.lib.dir}"/-->
- <get src="http://downloads.sourceforge.net/seleniumxml/selenium-server-1.0-SNAPSHOT-20081126.jar?use_mirror="
- dest="${selenium.lib.dir}/selenium-server.jar" usetimestamp="true" />
- </target>
+        <get src="http://downloads.sourceforge.net/seleniumxml/selenium-server-1.0-SNAPSHOT-20081126.jar?use_mirror="
+            dest="${selenium.lib.dir}/selenium-server.jar" usetimestamp="true" />
+    </target>
 
     <!-- ================================================================== -->
     <!-- Build JavaDoc                                                      -->

Modified: ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoader.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoader.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoader.java (original)
+++ ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoader.java Mon Aug 17 11:01:25 2009
@@ -31,40 +31,40 @@
 
 public class DataLoader {
 
- private String file;
- private String iterations;
- private SeleniumXml parent;
- private SeleniumXml currentTest;
- private List children;
+    private String file;
+    private String iterations;
+    private SeleniumXml parent;
+    private SeleniumXml currentTest;
+    private List children;
 
- private int currentRowIndx;
+    private int currentRowIndx;
 
 
- //Objects initialized from csvreader script.
- private PyDictionary fieldNameMap;
- private PyList dataList;
- private PyList fieldNames;
+    //Objects initialized from csvreader script.
+    private PyDictionary fieldNameMap;
+    private PyList dataList;
+    private PyList fieldNames;
 
 
 
 
- public DataLoader(String file, String iterations, SeleniumXml parent, List<Element> children) {
- super();
- this.file = file;
- this.iterations = iterations;
- this.parent = parent;
- this.children = children;
- initData();
- }
+    public DataLoader(String file, String iterations, SeleniumXml parent, List<Element> children) {
+        super();
+        this.file = file;
+        this.iterations = iterations;
+        this.parent = parent;
+        this.children = children;
+        initData();
+    }
 
- private void initData() {
- // Run the python script
- // Read header and get record count
- PythonInterpreter interp = InitJython.getInterpreter();
+    private void initData() {
+        // Run the python script
+        // Read header and get record count
+        PythonInterpreter interp = InitJython.getInterpreter();
 
- Map map = new HashMap();
- map.put("file", this.file);
- interp.set("params", map);
+        Map map = new HashMap();
+        map.put("file", this.file);
+        interp.set("params", map);
         interp.exec("from csvreader import CSVReader");
         String cmd = "reader = CSVReader('" + this.file + "')";
         interp.exec(cmd);
@@ -78,43 +78,43 @@
         //this.dataList = (PyArray) map.get("dataList");
         //this.fieldNames = (PyDictionary) map.get("fieldNames");
 
- }
+    }
 
- private void next() {
- this.currentRowIndx = (this.currentRowIndx + 1) % this.dataList.__len__();
- }
-
- private void loadData() {
-
- int size = this.fieldNames.__len__();
- for(int i=0; i<size; i++) {
- PyObject name = this.fieldNames.__getitem__(i);
- PyObject valueList = this.dataList.__getitem__(this.currentRowIndx);
- PyObject columnIndx = this.fieldNameMap.__getitem__(name);
- Integer convIndx = (Integer) columnIndx.__tojava__(Integer.class);
- //int convIndx = Integer.parseInt((String) columnIndx.__tojava__(String.class));
- PyObject value = valueList.__getitem__(convIndx);
- this.currentTest.addParam((String) name.__tojava__(String.class), (String) value.__tojava__(String.class));
- }
-
- }
-
- public void runTest() {
-
- //Depending on the iteration instruction repeat the following until complete
- int iter = Integer.parseInt(this.iterations);
-
- //Iterate through entire list of data
- if (iter == -1) {
- iter = this.dataList.__len__();
- }
-
- this.currentTest = new SeleniumXml(this.parent);
- for(int i=0; i<iter; i++) {
- loadData();
- currentTest.runCommands(this.children);
- next();
- }
+    private void next() {
+        this.currentRowIndx = (this.currentRowIndx + 1) % this.dataList.__len__();
+    }
+
+    private void loadData() {
+
+        int size = this.fieldNames.__len__();
+        for(int i=0; i<size; i++) {
+            PyObject name = this.fieldNames.__getitem__(i);
+            PyObject valueList = this.dataList.__getitem__(this.currentRowIndx);
+            PyObject columnIndx = this.fieldNameMap.__getitem__(name);
+            Integer convIndx = (Integer) columnIndx.__tojava__(Integer.class);
+            //int convIndx = Integer.parseInt((String) columnIndx.__tojava__(String.class));
+            PyObject value = valueList.__getitem__(convIndx);
+            this.currentTest.addParam((String) name.__tojava__(String.class), (String) value.__tojava__(String.class));
+        }
+
+    }
+
+    public void runTest() {
+
+        //Depending on the iteration instruction repeat the following until complete
+        int iter = Integer.parseInt(this.iterations);
+
+        //Iterate through entire list of data
+        if (iter == -1) {
+            iter = this.dataList.__len__();
+        }
+
+        this.currentTest = new SeleniumXml(this.parent);
+        for(int i=0; i<iter; i++) {
+            loadData();
+            currentTest.runCommands(this.children);
+            next();
+        }
 
- }
+    }
 }

Modified: ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoop.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoop.java?rev=804935&r1=804934&r2=804935&view=diff
==============================================================================
--- ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoop.java (original)
+++ ofbiz/trunk/framework/testtools/src/org/ofbiz/testtools/seleniumxml/DataLoop.java Mon Aug 17 11:01:25 2009
@@ -35,23 +35,23 @@
 
     private String dataListName;
     private SeleniumXml parent;
- private SeleniumXml currentTest;
- private List children;
-
- private int currentRowIndx;
-
-
-
- public DataLoop(String dataListName, SeleniumXml parent, List<Element> children) {
- super();
- this.dataListName = dataListName;
- this.parent = parent;
- this.children = children;
- }
+    private SeleniumXml currentTest;
+    private List children;
+    
+    private int currentRowIndx;
+    
+    
+    
+    public DataLoop(String dataListName, SeleniumXml parent, List<Element> children) {
+        super();
+        this.dataListName = dataListName;
+        this.parent = parent;
+        this.children = children;
+    }
 
- public void runTest() {
+    public void runTest() {
 
- this.currentTest = new SeleniumXml(this.parent);
+        this.currentTest = new SeleniumXml(this.parent);
         Map dataMap = this.parent.getMap();
         List dataList = (List)dataMap.get(this.dataListName);
         Iterator iter = dataList.iterator();
@@ -66,8 +66,8 @@
                     Object value = entry.getValue();
                     dataMap.put(name, value);
             }
-        currentTest.runCommands(this.children);
- }
-
- }
+             currentTest.runCommands(this.children);
+        }
+        
+    }
 }