Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy
URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Month.groovy Mon Jan 9 17:59:01 2012 @@ -18,24 +18,11 @@ */ import java.sql.*; -import java.text.*; import java.util.*; -import org.ofbiz.security.*; -import org.ofbiz.entity.*; import org.ofbiz.base.util.*; -import org.ofbiz.webapp.pseudotag.*; -import org.ofbiz.workeffort.workeffort.*; startParam = parameters.start; - -facilityId = parameters.facilityId; -fixedAssetId = parameters.fixedAssetId; -partyId = parameters.partyId; -workEffortTypeId = parameters.workEffortTypeId; -calendarType = parameters.calendarType; -entityExprList = context.entityExprList; - -start = null; +Timestamp start = null; if (UtilValidate.isNotEmpty(startParam)) { start = new Timestamp(Long.parseLong(startParam)); } @@ -44,16 +31,13 @@ if (start == null) { } else { start = UtilDateTime.getMonthStart(start, timeZone, locale); } - tempCal = UtilDateTime.toCalendar(start, timeZone, locale); numDays = tempCal.getActualMaximum(Calendar.DAY_OF_MONTH); - prev = UtilDateTime.getMonthStart(start, -1, timeZone, locale); context.prevMillis = new Long(prev.getTime()).toString(); next = UtilDateTime.getDayStart(start, numDays+1, timeZone, locale); context.nextMillis = new Long(next.getTime()).toString(); end = UtilDateTime.getMonthEnd(start, timeZone, locale); - //Find out what date to get from getFrom = null; prevMonthDays = tempCal.get(Calendar.DAY_OF_WEEK) - tempCal.getFirstDayOfWeek(); @@ -63,7 +47,6 @@ numDays += prevMonthDays; getFrom = new Timestamp(tempCal.getTimeInMillis()); firstWeekNum = tempCal.get(Calendar.WEEK_OF_YEAR); context.put("firstWeekNum", firstWeekNum); - // also get days until the end of the week at the end of the month lastWeekCal = UtilDateTime.toCalendar(end, timeZone, locale); monthEndDay = lastWeekCal.get(Calendar.DAY_OF_WEEK); @@ -74,15 +57,12 @@ if (followingMonthDays < 0) { followingMonthDays += 7; } numDays += followingMonthDays; - -serviceCtx = UtilMisc.toMap("userLogin", userLogin, "start", getFrom, "numPeriods", numDays, "periodType", Calendar.DATE); -serviceCtx.putAll(UtilMisc.toMap("partyId", partyId, "facilityId", facilityId, "fixedAssetId", fixedAssetId, "workEffortTypeId", workEffortTypeId, "calendarType", calendarType, "locale", locale, "timeZone", timeZone)); -if (entityExprList) { - serviceCtx.putAll(["entityExprList" : entityExprList]); +Map serviceCtx = dispatcher.getDispatchContext().makeValidContext("getWorkEffortEventsByPeriod", "IN", parameters); +serviceCtx.putAll(UtilMisc.toMap("userLogin", userLogin, "start", getFrom, "numPeriods", numDays, "periodType", Calendar.DATE, "locale", locale, "timeZone", timeZone)); +if (context.entityExprList) { + serviceCtx.entityExprList = entityExprList; } - result = dispatcher.runSync("getWorkEffortEventsByPeriod", serviceCtx); - context.put("periods",result.get("periods")); context.put("maxConcurrentEntries", result.get("maxConcurrentEntries")); context.put("start", start); Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/WEB-INF/actions/calendar/Week.groovy Mon Jan 9 17:59:01 2012 @@ -18,53 +18,29 @@ */ import java.util.*; -import org.ofbiz.security.*; -import org.ofbiz.entity.*; -import org.ofbiz.base.util.*; -import org.ofbiz.webapp.pseudotag.*; -import org.ofbiz.workeffort.workeffort.*; import java.sql.Timestamp; +import org.ofbiz.base.util.*; -String currentDay = parameters.currentDay; String startParam = parameters.start; - -facilityId = parameters.facilityId; -fixedAssetId = parameters.fixedAssetId; -partyId = parameters.partyId; -workEffortTypeId = parameters.workEffortTypeId; -calendarType = parameters.calendarType; -entityExprList = (List) context.get("entityExprList"); -filterOutCanceledEvents = parameters.filterOutCanceledEvents; -if (!filterOutCanceledEvents) { - filterOutCanceledEvents = Boolean.FALSE; -} - Timestamp start = null; if (UtilValidate.isNotEmpty(startParam)) { start = new Timestamp(Long.parseLong(startParam)); } - if (start == null) { start = UtilDateTime.getWeekStart(nowTimestamp, timeZone, locale); } else { start = UtilDateTime.getWeekStart(start, timeZone, locale); } - Timestamp prev = UtilDateTime.getDayStart(start, -7, timeZone, locale); context.prevMillis = new Long(prev.getTime()).toString(); Timestamp next = UtilDateTime.getDayStart(start, 7, timeZone, locale); context.nextMillis = new Long(next.getTime()).toString(); Timestamp end = UtilDateTime.getDayStart(start, 6, timeZone, locale); - -Map serviceCtx = UtilMisc.toMap("userLogin", userLogin,"start",start,"numPeriods", 7, - "periodType", Calendar.DATE); -serviceCtx.putAll(UtilMisc.toMap("partyId", partyId, "facilityId", facilityId, - "fixedAssetId", fixedAssetId, "workEffortTypeId", workEffortTypeId, "calendarType", calendarType, - "locale", locale, "timeZone", timeZone)); -if (entityExprList) { - serviceCtx.putAll(["entityExprList" : entityExprList]); +Map serviceCtx = dispatcher.getDispatchContext().makeValidContext("getWorkEffortEventsByPeriod", "IN", parameters); +serviceCtx.putAll(UtilMisc.toMap("userLogin", userLogin, "start", start, "numPeriods", 7, "periodType", Calendar.DATE, "locale", locale, "timeZone", timeZone)); +if (context.entityExprList) { + serviceCtx.entityExprList = entityExprList; } - Map result = dispatcher.runSync("getWorkEffortEventsByPeriod",serviceCtx); context.put("periods",result.get("periods")); context.put("maxConcurrentEntries",result.get("maxConcurrentEntries")); Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/calendarEventContent.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/calendarEventContent.ftl?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/calendarEventContent.ftl (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/calendarEventContent.ftl Mon Jan 9 17:59:01 2012 @@ -50,7 +50,11 @@ under the License. </#list> </#if> <#else> - <a href="<@ofbizUrl>${parameters._LAST_VIEW_NAME_}?form=edit&parentTypeId=${parentTypeId?if_exists}&period=${periodType?if_exists}&start=${parameters.start?if_exists}&workEffortId=${workEffort.workEffortId}${addlParam?if_exists}${urlParam?if_exists}</@ofbizUrl>" class="event"> + <#-- Allow containing screens to specify the URL for editing an event --> + <#if !editCalEventUrl?exists> + <#assign editCalEventUrl = parameters._LAST_VIEW_NAME_> + </#if> + <a href="<@ofbizUrl>${editCalEventUrl}?form=edit&parentTypeId=${parentTypeId?if_exists}&period=${periodType?if_exists}&start=${parameters.start?if_exists}&workEffortId=${workEffort.workEffortId}${addlParam?if_exists}${urlParam?if_exists}</@ofbizUrl>" class="event"> ${workEffort.workEffortId} </a> ${workEffort.workEffortName?default("")} Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/day.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/day.ftl?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/day.ftl (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/day.ftl Mon Jan 9 17:59:01 2012 @@ -17,6 +17,10 @@ specific language governing permissions under the License. --> <#if periods?has_content> + <#-- Allow containing screens to specify the URL for creating a new event --> + <#if !newCalEventUrl?exists> + <#assign newCalEventUrl = parameters._LAST_VIEW_NAME_> + </#if> <#if (maxConcurrentEntries < 2)> <#assign entryWidth = 100> <#else> @@ -33,7 +37,7 @@ under the License. <tr<#if currentPeriod> class="current-period"<#else><#if (period.calendarEntries?size > 0)> class="active-period"</#if></#if>> <td class="label"> ${period.start?time?string.short}<br /> - <a href="<@ofbizUrl>${parameters._LAST_VIEW_NAME_}?period=day&form=edit&parentTypeId=${parentTypeId?if_exists}&start=${parameters.start?if_exists}&currentStatusId=CAL_TENTATIVE&estimatedStartDate=${period.start?string("yyyy-MM-dd HH:mm:ss")}&estimatedCompletionDate=${period.end?string("yyyy-MM-dd HH:mm:ss")}${urlParam?if_exists}${addlParam?if_exists}</@ofbizUrl>">${uiLabelMap.CommonAddNew}</a> + <a href="<@ofbizUrl>${newCalEventUrl}?period=day&form=edit&parentTypeId=${parentTypeId?if_exists}&start=${parameters.start?if_exists}&currentStatusId=CAL_TENTATIVE&estimatedStartDate=${period.start?string("yyyy-MM-dd HH:mm:ss")}&estimatedCompletionDate=${period.end?string("yyyy-MM-dd HH:mm:ss")}${urlParam?if_exists}${addlParam?if_exists}</@ofbizUrl>">${uiLabelMap.CommonAddNew}</a> </td> <#list period.calendarEntries as calEntry> <#if calEntry.workEffort.actualStartDate?exists> Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/month.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/month.ftl?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/month.ftl (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/month.ftl Mon Jan 9 17:59:01 2012 @@ -20,6 +20,10 @@ under the License. <#assign styleTd = "style='height: 8em; width: 10em; vertical-align: top; padding: 0.5em;'"> <#if periods?has_content> + <#-- Allow containing screens to specify the URL for creating a new event --> + <#if !newCalEventUrl?exists> + <#assign newCalEventUrl = parameters._LAST_VIEW_NAME_> + </#if> <table cellspacing="0" class="basic-table calendar"> <tr class="header-row"> <td width="1%"> </td> @@ -40,7 +44,7 @@ under the License. </#if> <td ${styleTd} <#if currentPeriod> class="current-period"<#else><#if (period.calendarEntries?size > 0)> class="active-period"</#if></#if>> <span class="h1"><a href='<@ofbizUrl>${parameters._LAST_VIEW_NAME_}?period=day&start=${period.start.time?string("#")}${urlParam?if_exists}${addlParam?if_exists}</@ofbizUrl>'>${period.start?date?string("d")?cap_first}</a></span> - <a class="add-new" href='<@ofbizUrl>${parameters._LAST_VIEW_NAME_}?period=month&form=edit&start=${parameters.start?if_exists}&parentTypeId=${parentTypeId?if_exists}&currentStatusId=CAL_TENTATIVE&estimatedStartDate=${period.start?string("yyyy-MM-dd HH:mm:ss")}&estimatedCompletionDate=${period.end?string("yyyy-MM-dd HH:mm:ss")}${urlParam?if_exists}${addlParam?if_exists}</@ofbizUrl>'>${uiLabelMap.CommonAddNew}</a> + <a class="add-new" href='<@ofbizUrl>${newCalEventUrl}?period=month&form=edit&start=${parameters.start?if_exists}&parentTypeId=${parentTypeId?if_exists}&currentStatusId=CAL_TENTATIVE&estimatedStartDate=${period.start?string("yyyy-MM-dd HH:mm:ss")}&estimatedCompletionDate=${period.end?string("yyyy-MM-dd HH:mm:ss")}${urlParam?if_exists}${addlParam?if_exists}</@ofbizUrl>'>${uiLabelMap.CommonAddNew}</a> <br class="clear"/> <#assign maxNumberOfPersons = 0/> Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/week.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/week.ftl?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/week.ftl (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/webapp/workeffort/calendar/week.ftl Mon Jan 9 17:59:01 2012 @@ -17,6 +17,10 @@ specific language governing permissions under the License. --> <#if periods?has_content> + <#-- Allow containing screens to specify the URL for creating a new event --> + <#if !newCalEventUrl?exists> + <#assign newCalEventUrl = parameters._LAST_VIEW_NAME_> + </#if> <#if (maxConcurrentEntries < 2)> <#assign entryWidth = 100> <#else> @@ -33,7 +37,7 @@ under the License. <tr<#if currentPeriod> class="current-period"<#else><#if (period.calendarEntries?size > 0)> class="active-period"</#if></#if>> <td class="centered" width="1%"> <a href="<@ofbizUrl>${parameters._LAST_VIEW_NAME_}?period=day&start=${period.start.time?string("#")}${urlParam?if_exists}${addlParam?if_exists}</@ofbizUrl>">${period.start?date?string("EEEE")?cap_first} ${period.start?date?string.short}</a><br /> - <a href="<@ofbizUrl>${parameters._LAST_VIEW_NAME_}?period=week&form=edit&start=${parameters.start?if_exists}&parentTypeId=${parentTypeId?if_exists}&currentStatusId=CAL_TENTATIVE&estimatedStartDate=${period.start?string("yyyy-MM-dd HH:mm:ss")}&estimatedCompletionDate=${period.end?string("yyyy-MM-dd HH:mm:ss")}${addlParam?if_exists}${urlParam?if_exists}</@ofbizUrl>">${uiLabelMap.CommonAddNew}</a> + <a href="<@ofbizUrl>${newCalEventUrl}?period=week&form=edit&start=${parameters.start?if_exists}&parentTypeId=${parentTypeId?if_exists}&currentStatusId=CAL_TENTATIVE&estimatedStartDate=${period.start?string("yyyy-MM-dd HH:mm:ss")}&estimatedCompletionDate=${period.end?string("yyyy-MM-dd HH:mm:ss")}${addlParam?if_exists}${urlParam?if_exists}</@ofbizUrl>">${uiLabelMap.CommonAddNew}</a> </td> <#list period.calendarEntries as calEntry> <#if calEntry.workEffort.actualStartDate?exists> Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarForms.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarForms.xml (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarForms.xml Mon Jan 9 17:59:01 2012 @@ -20,6 +20,7 @@ under the License. <forms xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-form.xsd"> + <form name="FilterCalendarEvents" type="single" target="calendar"> <field name="calendarType"> <drop-down allow-empty="false"> @@ -32,23 +33,23 @@ under the License. <field name="partyId"> <lookup target-form-name="LookupPartyName" size="16"/> </field> - <field name="workEffortTypeId"> + <field name="workEffortTypeId" title="${uiLabelMap.PartyEventType}"> <drop-down allow-empty="true"> <entity-options entity-name="WorkEffortType" description="${description}"> <entity-order-by field-name="description"/> </entity-options> </drop-down> </field> - <field name="facilityId"> + <field name="facilityId" title="${uiLabelMap.Facility}"> <drop-down allow-empty="true"> <entity-options entity-name="Facility" description="${facilityName}"> <entity-order-by field-name="facilityName"/> </entity-options> </drop-down> </field> - <field name="fixedAssetId"> + <field name="fixedAssetId" title="${uiLabelMap.AccountingFixedAsset}"> <drop-down allow-empty="true"> - <entity-options entity-name="FixedAsset" description="${fixedAssetId} - ${fixedAssetName}"> + <entity-options entity-name="FixedAsset" description="${fixedAssetName}"> <entity-order-by field-name="fixedAssetId"/> </entity-options> </drop-down> @@ -56,6 +57,7 @@ under the License. <field name="hideEvents"><check/></field> <field name="viewButton" title="${uiLabelMap.CommonView}"><submit/></field> </form> + <!-- Forms Specific to portlet --> <form name="EditCalendar" extends="CommonPortletEdit" extends-resource="component://common/widget/PortletEditForms.xml"> <field name="initialView"> @@ -67,61 +69,79 @@ under the License. </field> <field name="updateButton"><submit/></field> </form> - <form name="editCalEvent" type="single" target="createWorkEffortAndPartyAssign" default-map-name="workEffort"> - <alt-target use-when="workEffort!=null" target="updateWorkEffort"/> - <field name="workEffortId" use-when="workEffort!=null"><hidden/></field> - <field name="partyId"><hidden value="${parameters.userLogin.partyId}"/></field> - <field name="fixedAssetId"><hidden value="${parameters.fixedAssetId}"/></field> - <field name="roleTypeId" use-when="workEffort==null"><hidden value="CAL_OWNER"/></field> - <field name="statusId" use-when="workEffort==null"><hidden value="PRTYASGN_ASSIGNED"/></field> - <field name="workEffortName" title="${uiLabelMap.WorkEffortEventName}"><text/></field> - <field name="description" title="${uiLabelMap.CommonDescription}"><text/></field> - <field name="workEffortTypeId" use-when="parentTypeId!=void"> + + <form name="editCalEvent" type="single" default-map-name="workEffort"> + <actions> + <entity-condition entity-name="StatusItem" list="statusItemList"> + <condition-list combine="or"> + <condition-expr field-name="statusTypeId" value="EVENT_STATUS" /> + <condition-expr field-name="statusTypeId" value="CALENDAR_STATUS" /> + </condition-list> + </entity-condition> + <!-- Allow containing screens to specify the create and update URLs --> + <set field="createCalEventUrl" from-field="createCalEventUrl" default-value="createWorkEffortAndPartyAssign" /> + <set field="updateCalEventUrl" from-field="updateCalEventUrl" default-value="updateWorkEffort" /> + </actions> + <alt-target use-when="workEffort==null" target="${createCalEventUrl}" /> + <alt-target use-when="workEffort!=null" target="${updateCalEventUrl}" /> + <field name="workEffortId" use-when="workEffort!=null"><hidden /></field> + <field name="start"><hidden value="${parameters.start}" /></field> + <field name="partyId"><hidden value="${parameters.userLogin.partyId}" /></field> + <field name="fixedAssetId"><hidden value="${parameters.fixedAssetId}" /></field> + <field name="roleTypeId" use-when="workEffort==null"><hidden value="CAL_OWNER" /></field> + <field name="statusId" use-when="workEffort==null"><hidden value="PRTYASGN_ASSIGNED" /></field> + <field name="workEffortName" title="${uiLabelMap.WorkEffortEventName}"><text /></field> + <field name="description" title="${uiLabelMap.CommonDescription}"><text /></field> + <!-- This is wrong. A calendar item work effort type is an EVENT. "Meeting" is a work effort purpose. --> + <field name="workEffortTypeId" use-when="parentTypeId!=void" title="${uiLabelMap.PartyEventType}"> <drop-down no-current-selected-key="MEETING"> <entity-options entity-name="WorkEffortType" description="${description}"> - <entity-constraint name="parentTypeId" env-name="parentTypeId"/> - <entity-order-by field-name="description"/> + <entity-constraint name="parentTypeId" env-name="parentTypeId" /> + <entity-order-by field-name="description" /> </entity-options> </drop-down> </field> - <field name="workEffortTypeId" use-when="parentTypeId==void"> + <field name="workEffortTypeId" use-when="parentTypeId==void" title="${uiLabelMap.PartyEventType}"> <drop-down> <entity-options entity-name="WorkEffortType" description="${description}"> - <entity-order-by field-name="description"/> + <entity-order-by field-name="description" /> </entity-options> </drop-down> </field> - <field name="currentStatusId" use-when="workEffort!=null"> - <display-entity entity-name="StatusItem" description="${description}" key-field-name="statusId"/> + <field name="currentStatusId" title="${uiLabelMap.CommonStatus}"> + <drop-down no-current-selected-key="CAL_TENTATIVE"> + <list-options key-name="statusId" list-name="statusItemList" description="${description}" /> + </drop-down> </field> - <field name="currentStatusId" use-when="workEffort==null"><hidden value="CAL_TENTATIVE"/></field> <field name="scopeEnumId"> <drop-down no-current-selected-key="WES_PRIVATE"> <entity-options entity-name="Enumeration" key-field-name="enumId" description="${description}"> - <entity-constraint name="enumTypeId" value="WORK_EFF_SCOPE"/> - <entity-order-by field-name="description"/> + <entity-constraint name="enumTypeId" value="WORK_EFF_SCOPE" /> + <entity-order-by field-name="description" /> </entity-options> </drop-down> </field> - <field name="estimatedStartDate"><date-time input-method="time-dropdown" default-value="${workEffort.estimatedStartDate}" /></field> - <field name="estimatedCompletionDate"><date-time input-method="time-dropdown" default-value="${workEffort.estimatedCompletionDate}"/></field> - <field name="actualStartDate" use-when="parentWorkEffortId!=null"><display type="date-time"/></field> - <field name="actualCompletionDate" use-when="parentWorkEffortId!=null"><display type="date-time"/></field> - <field name="addButton" use-when="workEffort==null"><submit/></field> - <field name="updateButton" use-when="workEffort!=null"><submit/></field> + <field name="estimatedStartDate"><date-time input-method="time-dropdown" /></field> + <field name="estimatedCompletionDate"><date-time input-method="time-dropdown" /></field> + <field name="actualStartDate" use-when="workEffort!=null"><date-time input-method="time-dropdown" /></field> + <field name="actualCompletionDate" use-when="workEffort!=null"><date-time input-method="time-dropdown" /></field> + <field name="addButton" use-when="workEffort==null"><submit /></field> + <field name="updateButton" use-when="workEffort!=null"><submit /></field> </form> + <form name="cancelEvent" type="single" target="updateWorkEffort"> <field name="workEffortId"><hidden value="${parameters.workEffortId}"/></field> <field name="currentStatusId"><hidden value="CAL_CANCELLED"/></field> <field name="cancel" title="${uiLabelMap.WorkEffortCancelCalendarEvent}"><submit/></field> </form> + <form name="showCalEvent" type="single" default-map-name="workEffort"> <field name="workEffortName" title="${uiLabelMap.WorkEffortEventName}"><display/></field> <field name="description" title="${uiLabelMap.CommonDescription}"><display/></field> - <field name="workEffortTypeId"> + <field name="workEffortTypeId" title="${uiLabelMap.PartyEventType}"> <display-entity entity-name="WorkEffortType" description="${description}"/> </field> - <field name="currentStatusId" use-when="workEffort!=null"> + <field name="currentStatusId" title="${uiLabelMap.CommonStatus}"> <display-entity entity-name="StatusItem" description="${description}" key-field-name="statusId"/> </field> <field name="scopeEnumId"> @@ -129,9 +149,10 @@ under the License. </field> <field name="estimatedStartDate"><display type="date-time"></display></field> <field name="estimatedCompletionDate"><display type="date-time"></display></field> - <field name="actualStartDate" use-when="parentWorkEffortId!=null"><display type="date-time"/></field> - <field name="actualCompletionDate" use-when="parentWorkEffortId!=null"><display type="date-time"/></field> + <field name="actualStartDate"><display type="date-time"/></field> + <field name="actualCompletionDate"><display type="date-time"/></field> </form> + <form name="showCalEventRoles" type="list" list-name="roles" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar"> <actions> Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarScreens.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarScreens.xml (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CalendarScreens.xml Mon Jan 9 17:59:01 2012 @@ -50,7 +50,7 @@ under the License. <widgets> <include-screen name="eventDetail"/> <container style="bothclear"> - <screenlet title="${uiLabelMap.WorkEffortDayView}: ${bsh:org.ofbiz.base.util.UtilDateTime.timeStampToString(start, "EEEE MMMM d, yyyy", timeZone, locale)}" navigation-menu-name="Day"> + <screenlet title="${uiLabelMap.WorkEffortDayView}: ${bsh:org.ofbiz.base.util.UtilDateTime.timeStampToString(start, "EEEE MMMM d, yyyy", timeZone, locale)}" navigation-menu-name="Day" padded="false"> <include-menu name="Day" location="component://workeffort/widget/WorkEffortMenus.xml"/> <platform-specific> <html><html-template location="component://workeffort/webapp/workeffort/calendar/day.ftl"/></html> @@ -72,7 +72,7 @@ under the License. <widgets> <include-screen name="eventDetail"/> <container style="bothclear"> - <screenlet title="${uiLabelMap.WorkEffortWeekView}: ${uiLabelMap.CommonWeek} ${bsh:org.ofbiz.base.util.UtilDateTime.timeStampToString(start, "w", timeZone, locale)}" navigation-menu-name="Week"> + <screenlet title="${uiLabelMap.WorkEffortWeekView}: ${uiLabelMap.CommonWeek} ${bsh:org.ofbiz.base.util.UtilDateTime.timeStampToString(start, "w", timeZone, locale)}" navigation-menu-name="Week" padded="false"> <include-menu name="Week" location="component://workeffort/widget/WorkEffortMenus.xml"/> <platform-specific> <html><html-template location="component://workeffort/webapp/workeffort/calendar/week.ftl"/></html> @@ -91,7 +91,7 @@ under the License. <widgets> <include-screen name="eventDetail"/> <container style="bothclear"> - <screenlet title="${uiLabelMap.WorkEffortMonthView}: ${bsh:org.ofbiz.base.util.UtilDateTime.timeStampToString(start, "MMMM yyyy", timeZone, locale)}" navigation-menu-name="Month"> + <screenlet title="${uiLabelMap.WorkEffortMonthView}: ${bsh:org.ofbiz.base.util.UtilDateTime.timeStampToString(start, "MMMM yyyy", timeZone, locale)}" navigation-menu-name="Month" padded="false"> <include-menu name="Month" location="component://workeffort/widget/WorkEffortMenus.xml"/> <platform-specific> <html><html-template location="component://workeffort/webapp/workeffort/calendar/month.ftl"/></html> @@ -140,88 +140,96 @@ under the License. </section> </screen> - <screen name="eventDetail"> <section> + <condition> + <if-compare field="parameters.form" operator="equals" value="edit" /> + </condition> <actions> - <entity-one entity-name="WorkEffort" value-field="workEffort"/> - <script location="component://workeffort/script/isCalOwner.groovy"/> + <entity-one entity-name="WorkEffort" value-field="workEffort" /> </actions> <widgets> <section> - <condition><!-- check if need to display detail screen --> - <and> - <if-compare field="parameters.form" operator="equals" value="edit"/> - <or> - <and> - <not><if-empty field="workEffort"/></not> - <if-compare field="workEffort.currentStatusId" operator="not-equals" value="CAL_CANCELLED"/> - </and> - <if-empty field="workEffort"/> - </or> - </and> + <condition> + <not><if-empty field="workEffort" /></not> + </condition> + <actions> + <script location="component://workeffort/script/isCalOwner.groovy" /> + </actions> + <widgets /> + </section> + <section> + <condition> + <or> + <and> + <not><if-empty field="workEffort" /></not> + <if-compare field="workEffort.currentStatusId" operator="not-equals" value="CAL_CANCELLED" /> + <if-compare field="isCalOwner" operator="equals" value="true" type="Boolean" /> + </and> + <if-empty field="workEffort" /> + <if-has-permission permission="WORKEFFORTMGR" action="ADMIN" /> + </or> + </condition> + <actions> + <set field="useEditForm" value="true" /> + </actions> + <widgets /> + </section> + <section> + <condition> + <if-compare field="useEditForm" operator="equals" value="true" /> </condition> <widgets> - <section><!-- check if edit form needs to be shown, otherwise show view only form --> - <condition> - <and> - <or> - <if-compare field="isCalOwner" operator="equals" value="true" type="Boolean"/> - <if-has-permission permission="WORKEFFORTMGR" action="ADMIN"/> - </or> - <if-compare field="workEffort.currentStatusId" operator="not-equals" value="PTS_COMPLETED"/> - </and> - </condition> - <widgets><!-- edit section --> - <container style="lefthalf" > - <screenlet title="${uiLabelMap.WorkEffortAddCalendarEvent}"> - <section> - <condition> - <not><if-empty field="workEffort"/></not> - </condition> - <widgets> - <include-form name="cancelEvent" location="component://workeffort/widget/CalendarForms.xml"/> - </widgets> - </section> - <include-form name="editCalEvent" location="component://workeffort/widget/CalendarForms.xml"/> - </screenlet> - </container> - <container style="righthalf"> - <screenlet title="${uiLabelMap.WorkEffortParticipants}"> - <include-form name="showCalEventRolesDel" location="component://workeffort/widget/CalendarForms.xml"/> - <section> - <condition> - <and> - <not><if-empty field="workEffort"/></not> - <if-compare field="workEffortTypeId" operator="not-equals" value="WES_PUBLIC"/> - </and> - </condition> - <widgets> - <include-form name="addCalEventRole" location="component://workeffort/widget/CalendarForms.xml"/> - </widgets> - </section> - </screenlet> - </container> - <container style="clear"/> - </widgets> - <fail-widgets><!-- view section --> - <container style="lefthalf"> - <screenlet title="${uiLabelMap.WorkEffortSummary}"> - <include-form name="showCalEvent" location="component://workeffort/widget/CalendarForms.xml"/> - </screenlet> - </container> - <container style="righthalf"> - <screenlet title="${uiLabelMap.WorkEffortParticipants}"> - <include-form name="showCalEventRoles" location="component://workeffort/widget/CalendarForms.xml"/> - </screenlet> - </container> - </fail-widgets> - </section> - </widgets> + <container style="lefthalf"> + <screenlet title="${uiLabelMap.WorkEffortAddCalendarEvent}"> + <section> + <condition> + <not><if-empty field="workEffort" /></not> + </condition> + <widgets> + <include-form name="cancelEvent" location="component://workeffort/widget/CalendarForms.xml" /> + </widgets> + </section> + <include-form name="editCalEvent" location="component://workeffort/widget/CalendarForms.xml" /> + </screenlet> + </container> + <container style="righthalf"> + <screenlet title="${uiLabelMap.WorkEffortParticipants}"> + <include-form name="showCalEventRolesDel" location="component://workeffort/widget/CalendarForms.xml" /> + <section> + <condition> + <and> + <not><if-empty field="workEffort" /></not> + <!-- Commenting this out because it doesn't make any sense. + <if-compare field="workEffortTypeId" operator="not-equals" value="WES_PUBLIC" /> + --> + </and> + </condition> + <widgets> + <include-form name="addCalEventRole" location="component://workeffort/widget/CalendarForms.xml" /> + </widgets> + </section> + </screenlet> + </container> + <container style="clear" /> + </widgets> + <fail-widgets> + <container style="lefthalf"> + <screenlet title="${uiLabelMap.WorkEffortSummary}"> + <include-form name="showCalEvent" location="component://workeffort/widget/CalendarForms.xml" /> + </screenlet> + </container> + <container style="righthalf"> + <screenlet title="${uiLabelMap.WorkEffortParticipants}"> + <include-form name="showCalEventRoles" location="component://workeffort/widget/CalendarForms.xml" /> + </screenlet> + </container> + </fail-widgets> </section> </widgets> </section> </screen> + <screen name="calendarEventContent"> <section> <actions> Modified: ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CommonScreens.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CommonScreens.xml (original) +++ ofbiz/branches/jackrabbit20100709/applications/workeffort/widget/CommonScreens.xml Mon Jan 9 17:59:01 2012 @@ -149,27 +149,23 @@ under the License. <screen name="CommonCalendarDecorator"> <section> <actions> - <set field="headerItem" value="calendar"/> + <set field="headerItem" value="calendar" /> </actions> <widgets> <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}"> <decorator-section name="body"> <section> <condition> - <if-has-permission permission="WORKEFFORTMGR" action="_VIEW"/> + <if-has-permission permission="WORKEFFORTMGR" action="_VIEW" /> </condition> <actions> - <script location="component://workeffort/webapp/workeffort/WEB-INF/actions/calendar/Days.groovy"/> + <script location="component://workeffort/webapp/workeffort/WEB-INF/actions/calendar/Days.groovy" /> </actions> <widgets> - <decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml"> - <decorator-section name="search-options"> - <include-form name="FilterCalendarEvents" location="component://workeffort/widget/CalendarForms.xml"/> - </decorator-section> - <decorator-section name="search-results"> - <decorator-section-include name="body"/> - </decorator-section> - </decorator-screen> + <screenlet id="calendarOptions" name="calendarOptionsScreenlet" collapsible="true" title="${uiLabelMap.WorkEffortCalendarFindEntries}"> + <include-form name="FilterCalendarEvents" location="component://workeffort/widget/CalendarForms.xml" /> + </screenlet> + <decorator-section-include name="body" /> </widgets> <fail-widgets> <label style="h3">${uiLabelMap.WorkEffortViewPermissionError}</label> Modified: ofbiz/branches/jackrabbit20100709/applyOfbizPatchesAndHotDeploy.sh URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/applyOfbizPatchesAndHotDeploy.sh?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/applyOfbizPatchesAndHotDeploy.sh (original) +++ ofbiz/branches/jackrabbit20100709/applyOfbizPatchesAndHotDeploy.sh Mon Jan 9 17:59:01 2012 @@ -22,19 +22,19 @@ # present in the hot-deploy directory if [ -f "../ofbiz.patch" ]; then - patch -p0 <../ofbiz.patch + patch -p0 <../ofbiz.patch fi for f in hot-deploy/* do if [ "$f" != "hot-deploy/README.txt" ]; then - if [ -f "$f/patches/applications.patch" ]; then - echo apply patches for component $f - cd $f - ../../ant apply-ofbiz-patches - echo return code $? - cd ../../ - fi + if [ -f "$f/patches/applications.patch" ]; then + echo apply patches for component $f + cd $f + ../../ant apply-ofbiz-patches + echo return code $? + cd ../../ + fi fi done Modified: ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/ObjectType.java URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/ObjectType.java?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/ObjectType.java (original) +++ ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/ObjectType.java Mon Jan 9 17:59:01 2012 @@ -106,7 +106,7 @@ public class ObjectType { if (loader == null) loader = Thread.currentThread().getContextClassLoader(); try { - theClass = loader.loadClass(className); + theClass = Class.forName(className, true, loader); } catch (Exception e) { theClass = classCache.get(className); if (theClass == null) { Modified: ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/UtilIO.java URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/UtilIO.java?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/UtilIO.java (original) +++ ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/UtilIO.java Mon Jan 9 17:59:01 2012 @@ -378,7 +378,7 @@ public final class UtilIO { for (i = offset; i < length && buffer[i] != ':'; i++); if (i > offset && i < length) { String className = new String(buffer, offset, i); - Class<?> type = ClassLoaderContainer.getClassLoader().loadClass(className); + Class<?> type = Class.forName(className, true, ClassLoaderContainer.getClassLoader()); if (buffer[length - 1] == '\n') { length--; } Modified: ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/template/FreeMarkerWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/template/FreeMarkerWorker.java?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/template/FreeMarkerWorker.java (original) +++ ofbiz/branches/jackrabbit20100709/framework/base/src/org/ofbiz/base/util/template/FreeMarkerWorker.java Mon Jan 9 17:59:01 2012 @@ -277,6 +277,14 @@ public class FreeMarkerWorker { env.setTimeZone(timeZone); } + /** + * Returns a <code>Configuration</code> instance initialized to OFBiz defaults. Client code should + * call this method instead of creating its own <code>Configuration</code> instance. The instance + * returned by this method includes the <code>component://</code> resolver and the OFBiz custom + * transformations. + * + * @return A <code>Configuration</code> instance. + */ public static Configuration getDefaultOfbizConfig() { return defaultOfbizConfig; } Modified: ofbiz/branches/jackrabbit20100709/framework/common/config/CommonUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/common/config/CommonUiLabels.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/common/config/CommonUiLabels.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/common/config/CommonUiLabels.xml Mon Jan 9 17:59:01 2012 @@ -113,6 +113,10 @@ <value xml:lang="zh_CN">ç®å½</value> <value xml:lang="zh_TW">ç®é</value> </property> + <property key="CatalogComponentDescription"> + <value xml:lang="en">Product Catalog management, Categories, Product, Price rules, Promotions, Product Store</value> + <value xml:lang="fr">Gestion des catalogues, Catégories, Articles, Promotions, Règles de prix, Centres de profit </value> + </property> <property key="CommonAbort"> <value xml:lang="en">Abort</value> <value xml:lang="es">Cancelar</value> @@ -4964,7 +4968,7 @@ <value xml:lang="de">Jede Minute</value> <value xml:lang="en">Minute</value> <value xml:lang="es">Minuto</value> - <value xml:lang="fr">Chaque minute</value> + <value xml:lang="fr">Minute</value> <value xml:lang="hi_IN">मिनà¤</value> <value xml:lang="it">Minuto</value> <value xml:lang="pt">Minuto a Minuto</value> @@ -10157,6 +10161,10 @@ <value xml:lang="zh_CN">设å¤</value> <value xml:lang="zh_TW">å ´æ</value> </property> + <property key="FacilityComponentDescription"> + <value xml:lang="en">Inventory management, Facility, location, Shipment, Receipt, Physical Inventory</value> + <value xml:lang="fr">Gestion des stocks, lieux de stockage, emplacement, expédition, réception, inventaire</value> + </property> <property key="Financials"> <value xml:lang="ar">اÙ٠اÙÙØ©</value> <value xml:lang="de">Finanzen</value> @@ -11051,6 +11059,10 @@ <value xml:lang="zh_CN">订å</value> <value xml:lang="zh_TW">è¨å®</value> </property> + <property key="OrderComponentDescription"> + <value xml:lang="en">Sales Order management, Purchase order, Customer request, Requirement, Quote, Statistics</value> + <value xml:lang="fr">Gestion des commandes de vente, d'achat, des demandes, des devis, des besoins, des stats</value> + </property> <property key="PageTitleAddDataSource"> <value xml:lang="ar">إضاÙØ© ٠صدر اÙ٠عÙÙ٠ات جدÙد</value> <value xml:lang="de">Neue Datenquelle hinzufügen</value> @@ -11313,6 +11325,10 @@ <value xml:lang="zh_CN">å¢ä½</value> <value xml:lang="zh_TW">æå¡</value> </property> + <property key="PartyComponentDescription"> + <value xml:lang="en">Customers - Suppliers - Employee Management, Communications, Classifications</value> + <value xml:lang="fr">Gestion des clients, Fournisseurs, Employés, Communications, Classifications</value> + </property> <property key="PortalPageNotFound"> <value xml:lang="en">This page (${parameters.portalPageId}) could not be found!</value> <value xml:lang="es">Esta página (${parameters.portalPageId}) no se ha encontrado!</value> Modified: ofbiz/branches/jackrabbit20100709/framework/common/data/CommonTypeData.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/common/data/CommonTypeData.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/common/data/CommonTypeData.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/common/data/CommonTypeData.xml Mon Jan 9 17:59:01 2012 @@ -141,4 +141,15 @@ under the License. <ServerHitType description="Entity" hitTypeId="ENTITY"/> <ServerHitType description="Service" hitTypeId="SERVICE"/> + <!-- Keyword Type --> + <EnumerationType enumTypeId="KEYWORD_TYPE" hasTable="N" description="Keyword Type"/> + <Enumeration enumId="KWT_KEYWORD" enumTypeId="KEYWORD_TYPE" enumCode="KEYWORD" sequenceId="01" description="Keyword"/> + <Enumeration enumId="KWT_TAG" enumTypeId="KEYWORD_TYPE" enumCode="TAG" sequenceId="02" description="Tag"/> + + <!-- Keyword Status --> + <StatusType statusTypeId="KEYWORD_STATUS" hasTable="N" description="Keyword"/> + <StatusItem statusId="KW_APPROVED" statusTypeId="KEYWORD_STATUS" statusCode="APPROVED" sequenceId="01" description="Approved"/> + <StatusItem statusId="KW_PENDING" statusTypeId="KEYWORD_STATUS" statusCode="PENDING" sequenceId="02" description="Pending"/> + <StatusItem statusId="KW_DISAPPROVED" statusTypeId="KEYWORD_STATUS" statusCode="DISAPPROVED" sequenceId="03" description="Disapproved"/> + </entity-engine-xml> Modified: ofbiz/branches/jackrabbit20100709/framework/common/webcommon/WEB-INF/common-controller.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/common/webcommon/WEB-INF/common-controller.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/common/webcommon/WEB-INF/common-controller.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/common/webcommon/WEB-INF/common-controller.xml Mon Jan 9 17:59:01 2012 @@ -34,13 +34,6 @@ under the License. <handler name="simple" type="request" class="org.ofbiz.webapp.event.SimpleEventHandler"/> <handler name="groovy" type="request" class="org.ofbiz.webapp.event.GroovyEventHandler"/> <handler name="rome" type="request" class="org.ofbiz.webapp.event.RomeEventHandler"/> - <!-- These event handlers have been deprecated, if you need to send json responses then chain - the json request from this controller after calling your event - <handler name="jsonservice" type="request" class="org.ofbiz.webapp.event.JSONServiceEventHandler"/> - <handler name="jsonservice-multi" type="request" class="org.ofbiz.webapp.event.JSONServiceMultiEventHandler"/> - <handler name="jsonsimple" type="request" class="org.ofbiz.webapp.event.JSONSimpleEventHandler"/> - <handler name="jsonjava" type="request" class="org.ofbiz.webapp.event.JSONJavaEventHandler"/> - --> <!-- view handlers --> <handler name="screen" type="view" class="org.ofbiz.widget.screen.MacroScreenViewHandler"/> Modified: ofbiz/branches/jackrabbit20100709/framework/common/webcommon/includes/lookup.ftl URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/common/webcommon/includes/lookup.ftl?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/common/webcommon/includes/lookup.ftl (original) +++ ofbiz/branches/jackrabbit20100709/framework/common/webcommon/includes/lookup.ftl Mon Jan 9 17:59:01 2012 @@ -27,7 +27,20 @@ under the License. <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <title>${title?if_exists}</title> - <script language="javascript" src="<@ofbizContentUrl>/images/jquery/jquery-1.7.min.js</@ofbizContentUrl>" type="text/javascript"></script> + <#-- the trick "<scr" + "ipt below is because browsers should not parse the contents of CDATA elements, but apparently they do. --> + <script language="JavaScript" type="text/javascript">//<![CDATA[ + var jQueryLibLoaded = false; + function initJQuery() { + if (typeof(jQuery) == 'undefined') { + if (!jQueryLibLoaded) { + jQueryLibLoaded = true; + document.write("<scr" + "ipt type=\"text/javascript\" src=\"<@ofbizContentUrl>/images/jquery/jquery-1.7.min.js</@ofbizContentUrl>\"></scr" + "ipt>"); + } + setTimeout("initJQuery()", 50); + } + } + initJQuery(); + //]]></script> <script language="javascript" src="<@ofbizContentUrl>/images/selectall.js</@ofbizContentUrl>" type="text/javascript"></script> <#if layoutSettings.javaScripts?has_content> <#--layoutSettings.javaScripts is a list of java scripts. --> Modified: ofbiz/branches/jackrabbit20100709/framework/common/widget/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/common/widget/CommonScreens.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/common/widget/CommonScreens.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/common/widget/CommonScreens.xml Mon Jan 9 17:59:01 2012 @@ -523,6 +523,9 @@ under the License. <screen name="login"> <section> + <actions> + <set field="titleProperty" value="PageTitleLogin" /> + </actions> <widgets> <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}"> <decorator-section name="body"> Modified: ofbiz/branches/jackrabbit20100709/framework/entity/config/entityengine.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/entity/config/entityengine.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/entity/config/entityengine.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/entity/config/entityengine.xml Mon Jan 9 17:59:01 2012 @@ -48,6 +48,7 @@ access. For a detailed description see t <!-- the connection factory class to use, one is needed for obtaining connections/pools for defined resources --> <connection-factory class="org.ofbiz.entity.connection.DBCPConnectionFactory"/> + <!-- debug-xa-resources value="true" --> <!-- see https://issues.apache.org/jira/browse/OFBIZ-4282 for more --> <delegator name="default" entity-model-reader="main" entity-group-reader="main" entity-eca-reader="main" distributed-cache-clear-enabled="false"> <group-map group-name="org.ofbiz" datasource-name="localderby"/> Modified: ofbiz/branches/jackrabbit20100709/framework/entity/dtd/entity-config.xsd URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/entity/dtd/entity-config.xsd?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/entity/dtd/entity-config.xsd (original) +++ ofbiz/branches/jackrabbit20100709/framework/entity/dtd/entity-config.xsd Mon Jan 9 17:59:01 2012 @@ -25,6 +25,7 @@ under the License. <xs:element maxOccurs="unbounded" ref="resource-loader"/> <xs:element ref="transaction-factory"/> <xs:element ref="connection-factory"/> + <xs:element ref="debug-xa-resources"/> <xs:element maxOccurs="unbounded" ref="delegator"/> <xs:element maxOccurs="unbounded" ref="entity-model-reader"/> <xs:element maxOccurs="unbounded" ref="entity-group-reader"/> @@ -81,6 +82,11 @@ under the License. <xs:attributeGroup ref="attlist.connection-factory"/> </xs:complexType> </xs:element> + <xs:element name="debug-xa-resources"> + <xs:complexType> + <xs:attribute default="false" name="value" type="xs:boolean"/> + </xs:complexType> + </xs:element> <xs:attributeGroup name="attlist.connection-factory"> <xs:attribute type="xs:string" name="class" use="required"/> </xs:attributeGroup> Modified: ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/GenericEntity.java URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/GenericEntity.java?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/GenericEntity.java (original) +++ ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/GenericEntity.java Mon Jan 9 17:59:01 2012 @@ -461,7 +461,7 @@ public class GenericEntity extends Obser } boolean isNullString = false; - if ("null".equals(value)) { + if ("null".equals(value) || "[null-field]".equals(value)) { // count this as a null too, but only for numbers and stuff, not for Strings isNullString = true; } @@ -1076,6 +1076,8 @@ public class GenericEntity extends Obser } else { element.setAttribute(name, value); } + } else { + element.setAttribute(name, GenericEntity.NULL_FIELD.toString()); } } Modified: ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/config/EntityConfigUtil.java URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/config/EntityConfigUtil.java?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/config/EntityConfigUtil.java (original) +++ ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/config/EntityConfigUtil.java Mon Jan 9 17:59:01 2012 @@ -48,6 +48,10 @@ public class EntityConfigUtil { private final String txFactoryTxMgrJndiName; private final String txFactoryTxMgrJndiServerName; private final String connFactoryClass; + /** + * Create Begin stacktrace when enlisting transactions + */ + private final Boolean debugXAResources; private final Map<String, ResourceLoaderInfo> resourceLoaderInfos = new HashMap<String, ResourceLoaderInfo>(); private final Map<String, DelegatorInfo> delegatorInfos = new HashMap<String, DelegatorInfo>(); @@ -122,6 +126,12 @@ public class EntityConfigUtil { connFactoryClass = connectionFactoryElement.getAttribute("class"); + Element debugXaResourcesElement = UtilXml.firstChildElement(rootElement, "debug-xa-resources"); + if (debugXaResourcesElement == null) { + debugXAResources = false; + } else { + debugXAResources = "true".equals(debugXaResourcesElement.getAttribute("value")); + } // not load all of the maps... // resource-loader - resourceLoaderInfos @@ -188,6 +198,13 @@ public class EntityConfigUtil { public static String getTxFactoryTxMgrJndiName() { return configRef.get().txFactoryTxMgrJndiName; } + + /** + * @return true Create Begin stacktrace when enlisting transactions + */ + public static boolean isDebugXAResource() { + return configRef.get().debugXAResources; + } public static String getTxFactoryTxMgrJndiServerName() { return configRef.get().txFactoryTxMgrJndiServerName; Modified: ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java (original) +++ ofbiz/branches/jackrabbit20100709/framework/entity/src/org/ofbiz/entity/transaction/TransactionUtil.java Mon Jan 9 17:59:01 2012 @@ -53,6 +53,7 @@ import org.ofbiz.base.util.UtilDateTime; import org.ofbiz.base.util.UtilGenerics; import org.ofbiz.base.util.UtilValidate; import org.ofbiz.entity.GenericEntityException; +import org.ofbiz.entity.config.EntityConfigUtil; /** * <p>Transaction Utility to help with some common transaction tasks @@ -62,7 +63,7 @@ public class TransactionUtil implements // Debug module name public static final String module = TransactionUtil.class.getName(); public static Map<Xid, DebugXaResource> debugResMap = Collections.<Xid, DebugXaResource>synchronizedMap(new HashMap<Xid, DebugXaResource>()); - public static boolean debugResources = true; + public static boolean debugResources = EntityConfigUtil.isDebugXAResource(); private static ThreadLocal<List<Transaction>> suspendedTxStack = new ThreadLocal<List<Transaction>>(); private static ThreadLocal<List<Exception>> suspendedTxLocationStack = new ThreadLocal<List<Exception>>(); @@ -194,7 +195,7 @@ public class TransactionUtil implements } } - protected static synchronized void internalBegin(UserTransaction ut, int timeout) throws SystemException, NotSupportedException { + protected static void internalBegin(UserTransaction ut, int timeout) throws SystemException, NotSupportedException { // set the timeout for THIS transaction if (timeout > 0) { ut.setTransactionTimeout(timeout); Modified: ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js (original) +++ ofbiz/branches/jackrabbit20100709/framework/images/webapp/images/selectall.js Mon Jan 9 17:59:01 2012 @@ -394,7 +394,11 @@ function ajaxAutoCompleter(areaCsvString var numAreas = parseInt(areaArray.length / 3); for (var i = 0; i < numAreas * 3; i = i + 3) { - var url = areaArray[i + 1] + "?" + areaArray[i + 2]; + var initUrl = areaArray[i + 1]; + if (initUrl.indexOf("?") > -1) + var url = initUrl + "&" + areaArray[i + 2]; + else + var url = initUrl + "?" + areaArray[i + 2]; var div = areaArray[i]; // create a separated div where the result JSON Opbject will be placed if ((jQuery("#" + div + "_auto")).length < 1) { Modified: ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/resources/templates/build.xml Mon Jan 9 17:59:01 2012 @@ -98,10 +98,10 @@ </or> </condition> </fail> - <patch strip="0" patchfile="patches/root.patch" dir="${ofbiz.home.dir}"/> - <patch strip="0" patchfile="patches/framework.patch" dir="${ofbiz.home.dir}"/> - <patch strip="0" patchfile="patches/applications.patch" dir="${ofbiz.home.dir}"/> - <patch strip="0" patchfile="patches/specialpurpose.patch" dir="${ofbiz.home.dir}"/> + <patch strip="0" patchfile="patches/root.patch" dir="${ofbiz.home.dir}" failonerror="true"/> + <patch strip="0" patchfile="patches/framework.patch" dir="${ofbiz.home.dir}" failonerror="true"/> + <patch strip="0" patchfile="patches/applications.patch" dir="${ofbiz.home.dir}" failonerror="true"/> + <patch strip="0" patchfile="patches/specialpurpose.patch" dir="${ofbiz.home.dir}" failonerror="true"/> <delete> <fileset dir="${ofbiz.home.dir}" includes="**/*.rej"/> </delete> Modified: ofbiz/branches/jackrabbit20100709/framework/service/data/ServiceDemoData.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/service/data/ServiceDemoData.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/service/data/ServiceDemoData.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/service/data/ServiceDemoData.xml Mon Jan 9 17:59:01 2012 @@ -21,155 +21,6 @@ under the License. <entity-engine-xml> <!-- Temporal Expression demo data --> - <!-- Pre-define all 60 minutes --> - <TemporalExpression tempExprId="MINUTE_00" tempExprTypeId="MINUTE_RANGE" description="Minute 0" integer1="0" integer2="0"/> - <TemporalExpression tempExprId="MINUTE_01" tempExprTypeId="MINUTE_RANGE" description="Minute 1" integer1="1" integer2="1"/> - <TemporalExpression tempExprId="MINUTE_02" tempExprTypeId="MINUTE_RANGE" description="Minute 2" integer1="2" integer2="2"/> - <TemporalExpression tempExprId="MINUTE_03" tempExprTypeId="MINUTE_RANGE" description="Minute 3" integer1="3" integer2="3"/> - <TemporalExpression tempExprId="MINUTE_04" tempExprTypeId="MINUTE_RANGE" description="Minute 4" integer1="4" integer2="4"/> - <TemporalExpression tempExprId="MINUTE_05" tempExprTypeId="MINUTE_RANGE" description="Minute 5" integer1="5" integer2="5"/> - <TemporalExpression tempExprId="MINUTE_06" tempExprTypeId="MINUTE_RANGE" description="Minute 6" integer1="6" integer2="6"/> - <TemporalExpression tempExprId="MINUTE_07" tempExprTypeId="MINUTE_RANGE" description="Minute 7" integer1="7" integer2="7"/> - <TemporalExpression tempExprId="MINUTE_08" tempExprTypeId="MINUTE_RANGE" description="Minute 8" integer1="8" integer2="8"/> - <TemporalExpression tempExprId="MINUTE_09" tempExprTypeId="MINUTE_RANGE" description="Minute 9" integer1="9" integer2="9"/> - <TemporalExpression tempExprId="MINUTE_10" tempExprTypeId="MINUTE_RANGE" description="Minute 10" integer1="10" integer2="10"/> - <TemporalExpression tempExprId="MINUTE_11" tempExprTypeId="MINUTE_RANGE" description="Minute 11" integer1="11" integer2="11"/> - <TemporalExpression tempExprId="MINUTE_12" tempExprTypeId="MINUTE_RANGE" description="Minute 12" integer1="12" integer2="12"/> - <TemporalExpression tempExprId="MINUTE_13" tempExprTypeId="MINUTE_RANGE" description="Minute 13" integer1="13" integer2="13"/> - <TemporalExpression tempExprId="MINUTE_14" tempExprTypeId="MINUTE_RANGE" description="Minute 14" integer1="14" integer2="14"/> - <TemporalExpression tempExprId="MINUTE_15" tempExprTypeId="MINUTE_RANGE" description="Minute 15" integer1="15" integer2="15"/> - <TemporalExpression tempExprId="MINUTE_16" tempExprTypeId="MINUTE_RANGE" description="Minute 16" integer1="16" integer2="16"/> - <TemporalExpression tempExprId="MINUTE_17" tempExprTypeId="MINUTE_RANGE" description="Minute 17" integer1="17" integer2="17"/> - <TemporalExpression tempExprId="MINUTE_18" tempExprTypeId="MINUTE_RANGE" description="Minute 18" integer1="18" integer2="18"/> - <TemporalExpression tempExprId="MINUTE_19" tempExprTypeId="MINUTE_RANGE" description="Minute 19" integer1="19" integer2="19"/> - <TemporalExpression tempExprId="MINUTE_20" tempExprTypeId="MINUTE_RANGE" description="Minute 20" integer1="20" integer2="20"/> - <TemporalExpression tempExprId="MINUTE_21" tempExprTypeId="MINUTE_RANGE" description="Minute 21" integer1="21" integer2="21"/> - <TemporalExpression tempExprId="MINUTE_22" tempExprTypeId="MINUTE_RANGE" description="Minute 22" integer1="22" integer2="22"/> - <TemporalExpression tempExprId="MINUTE_23" tempExprTypeId="MINUTE_RANGE" description="Minute 23" integer1="23" integer2="23"/> - <TemporalExpression tempExprId="MINUTE_24" tempExprTypeId="MINUTE_RANGE" description="Minute 24" integer1="24" integer2="24"/> - <TemporalExpression tempExprId="MINUTE_25" tempExprTypeId="MINUTE_RANGE" description="Minute 25" integer1="25" integer2="25"/> - <TemporalExpression tempExprId="MINUTE_26" tempExprTypeId="MINUTE_RANGE" description="Minute 26" integer1="26" integer2="26"/> - <TemporalExpression tempExprId="MINUTE_27" tempExprTypeId="MINUTE_RANGE" description="Minute 27" integer1="27" integer2="27"/> - <TemporalExpression tempExprId="MINUTE_28" tempExprTypeId="MINUTE_RANGE" description="Minute 28" integer1="28" integer2="28"/> - <TemporalExpression tempExprId="MINUTE_29" tempExprTypeId="MINUTE_RANGE" description="Minute 29" integer1="29" integer2="29"/> - <TemporalExpression tempExprId="MINUTE_30" tempExprTypeId="MINUTE_RANGE" description="Minute 30" integer1="30" integer2="30"/> - <TemporalExpression tempExprId="MINUTE_31" tempExprTypeId="MINUTE_RANGE" description="Minute 31" integer1="31" integer2="31"/> - <TemporalExpression tempExprId="MINUTE_32" tempExprTypeId="MINUTE_RANGE" description="Minute 32" integer1="32" integer2="32"/> - <TemporalExpression tempExprId="MINUTE_33" tempExprTypeId="MINUTE_RANGE" description="Minute 33" integer1="33" integer2="33"/> - <TemporalExpression tempExprId="MINUTE_34" tempExprTypeId="MINUTE_RANGE" description="Minute 34" integer1="34" integer2="34"/> - <TemporalExpression tempExprId="MINUTE_35" tempExprTypeId="MINUTE_RANGE" description="Minute 35" integer1="35" integer2="35"/> - <TemporalExpression tempExprId="MINUTE_36" tempExprTypeId="MINUTE_RANGE" description="Minute 36" integer1="36" integer2="36"/> - <TemporalExpression tempExprId="MINUTE_37" tempExprTypeId="MINUTE_RANGE" description="Minute 37" integer1="37" integer2="37"/> - <TemporalExpression tempExprId="MINUTE_38" tempExprTypeId="MINUTE_RANGE" description="Minute 38" integer1="38" integer2="38"/> - <TemporalExpression tempExprId="MINUTE_39" tempExprTypeId="MINUTE_RANGE" description="Minute 39" integer1="39" integer2="39"/> - <TemporalExpression tempExprId="MINUTE_40" tempExprTypeId="MINUTE_RANGE" description="Minute 40" integer1="40" integer2="40"/> - <TemporalExpression tempExprId="MINUTE_41" tempExprTypeId="MINUTE_RANGE" description="Minute 41" integer1="41" integer2="41"/> - <TemporalExpression tempExprId="MINUTE_42" tempExprTypeId="MINUTE_RANGE" description="Minute 42" integer1="42" integer2="42"/> - <TemporalExpression tempExprId="MINUTE_43" tempExprTypeId="MINUTE_RANGE" description="Minute 43" integer1="43" integer2="43"/> - <TemporalExpression tempExprId="MINUTE_44" tempExprTypeId="MINUTE_RANGE" description="Minute 44" integer1="44" integer2="44"/> - <TemporalExpression tempExprId="MINUTE_45" tempExprTypeId="MINUTE_RANGE" description="Minute 45" integer1="45" integer2="45"/> - <TemporalExpression tempExprId="MINUTE_46" tempExprTypeId="MINUTE_RANGE" description="Minute 46" integer1="46" integer2="46"/> - <TemporalExpression tempExprId="MINUTE_47" tempExprTypeId="MINUTE_RANGE" description="Minute 47" integer1="47" integer2="47"/> - <TemporalExpression tempExprId="MINUTE_48" tempExprTypeId="MINUTE_RANGE" description="Minute 48" integer1="48" integer2="48"/> - <TemporalExpression tempExprId="MINUTE_49" tempExprTypeId="MINUTE_RANGE" description="Minute 49" integer1="49" integer2="49"/> - <TemporalExpression tempExprId="MINUTE_50" tempExprTypeId="MINUTE_RANGE" description="Minute 50" integer1="50" integer2="50"/> - <TemporalExpression tempExprId="MINUTE_51" tempExprTypeId="MINUTE_RANGE" description="Minute 51" integer1="51" integer2="51"/> - <TemporalExpression tempExprId="MINUTE_52" tempExprTypeId="MINUTE_RANGE" description="Minute 52" integer1="52" integer2="52"/> - <TemporalExpression tempExprId="MINUTE_53" tempExprTypeId="MINUTE_RANGE" description="Minute 53" integer1="53" integer2="53"/> - <TemporalExpression tempExprId="MINUTE_54" tempExprTypeId="MINUTE_RANGE" description="Minute 54" integer1="54" integer2="54"/> - <TemporalExpression tempExprId="MINUTE_55" tempExprTypeId="MINUTE_RANGE" description="Minute 55" integer1="55" integer2="55"/> - <TemporalExpression tempExprId="MINUTE_56" tempExprTypeId="MINUTE_RANGE" description="Minute 56" integer1="56" integer2="56"/> - <TemporalExpression tempExprId="MINUTE_57" tempExprTypeId="MINUTE_RANGE" description="Minute 57" integer1="57" integer2="57"/> - <TemporalExpression tempExprId="MINUTE_58" tempExprTypeId="MINUTE_RANGE" description="Minute 58" integer1="58" integer2="58"/> - <TemporalExpression tempExprId="MINUTE_59" tempExprTypeId="MINUTE_RANGE" description="Minute 59" integer1="59" integer2="59"/> - - <!-- Pre-define all 24 hours of the day --> - <TemporalExpression tempExprId="HOUR_00" tempExprTypeId="HOUR_RANGE" description="Hour 0" integer1="0" integer2="0"/> - <TemporalExpression tempExprId="HOUR_01" tempExprTypeId="HOUR_RANGE" description="Hour 1" integer1="1" integer2="1"/> - <TemporalExpression tempExprId="HOUR_02" tempExprTypeId="HOUR_RANGE" description="Hour 2" integer1="2" integer2="2"/> - <TemporalExpression tempExprId="HOUR_03" tempExprTypeId="HOUR_RANGE" description="Hour 3" integer1="3" integer2="3"/> - <TemporalExpression tempExprId="HOUR_04" tempExprTypeId="HOUR_RANGE" description="Hour 4" integer1="4" integer2="4"/> - <TemporalExpression tempExprId="HOUR_05" tempExprTypeId="HOUR_RANGE" description="Hour 5" integer1="5" integer2="5"/> - <TemporalExpression tempExprId="HOUR_06" tempExprTypeId="HOUR_RANGE" description="Hour 6" integer1="6" integer2="6"/> - <TemporalExpression tempExprId="HOUR_07" tempExprTypeId="HOUR_RANGE" description="Hour 7" integer1="7" integer2="7"/> - <TemporalExpression tempExprId="HOUR_08" tempExprTypeId="HOUR_RANGE" description="Hour 8" integer1="8" integer2="8"/> - <TemporalExpression tempExprId="HOUR_09" tempExprTypeId="HOUR_RANGE" description="Hour 9" integer1="9" integer2="9"/> - <TemporalExpression tempExprId="HOUR_10" tempExprTypeId="HOUR_RANGE" description="Hour 10" integer1="10" integer2="10"/> - <TemporalExpression tempExprId="HOUR_11" tempExprTypeId="HOUR_RANGE" description="Hour 11" integer1="11" integer2="11"/> - <TemporalExpression tempExprId="HOUR_12" tempExprTypeId="HOUR_RANGE" description="Hour 12" integer1="12" integer2="12"/> - <TemporalExpression tempExprId="HOUR_13" tempExprTypeId="HOUR_RANGE" description="Hour 13" integer1="13" integer2="13"/> - <TemporalExpression tempExprId="HOUR_14" tempExprTypeId="HOUR_RANGE" description="Hour 14" integer1="14" integer2="14"/> - <TemporalExpression tempExprId="HOUR_15" tempExprTypeId="HOUR_RANGE" description="Hour 15" integer1="15" integer2="15"/> - <TemporalExpression tempExprId="HOUR_16" tempExprTypeId="HOUR_RANGE" description="Hour 16" integer1="16" integer2="16"/> - <TemporalExpression tempExprId="HOUR_17" tempExprTypeId="HOUR_RANGE" description="Hour 17" integer1="17" integer2="17"/> - <TemporalExpression tempExprId="HOUR_18" tempExprTypeId="HOUR_RANGE" description="Hour 18" integer1="18" integer2="18"/> - <TemporalExpression tempExprId="HOUR_19" tempExprTypeId="HOUR_RANGE" description="Hour 19" integer1="19" integer2="19"/> - <TemporalExpression tempExprId="HOUR_20" tempExprTypeId="HOUR_RANGE" description="Hour 20" integer1="20" integer2="20"/> - <TemporalExpression tempExprId="HOUR_21" tempExprTypeId="HOUR_RANGE" description="Hour 21" integer1="21" integer2="21"/> - <TemporalExpression tempExprId="HOUR_22" tempExprTypeId="HOUR_RANGE" description="Hour 22" integer1="22" integer2="22"/> - <TemporalExpression tempExprId="HOUR_23" tempExprTypeId="HOUR_RANGE" description="Hour 23" integer1="23" integer2="23"/> - - <!-- Pre-define all days of the week (Sunday -> Saturday) --> - <TemporalExpression tempExprId="DAYOFWEEK_01" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Sunday" integer1="1" integer2="1"/> - <TemporalExpression tempExprId="DAYOFWEEK_02" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Monday" integer1="2" integer2="2"/> - <TemporalExpression tempExprId="DAYOFWEEK_03" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Tuesday" integer1="3" integer2="3"/> - <TemporalExpression tempExprId="DAYOFWEEK_04" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Wednesday" integer1="4" integer2="4"/> - <TemporalExpression tempExprId="DAYOFWEEK_05" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Thursday" integer1="5" integer2="5"/> - <TemporalExpression tempExprId="DAYOFWEEK_06" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Friday" integer1="6" integer2="6"/> - <TemporalExpression tempExprId="DAYOFWEEK_07" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Saturday" integer1="7" integer2="7"/> - - <!-- Pre-define some day of the week ranges --> - <TemporalExpression tempExprId="MON_TO_FRI" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Monday to Friday" integer1="2" integer2="6"/> - <TemporalExpression tempExprId="SAT_TO_SUN" tempExprTypeId="DAY_OF_WEEK_RANGE" description="Saturday to Sunday" integer1="7" integer2="1"/> - - <!-- Pre-define all 13 months (January -> Undecimber) --> - <TemporalExpression tempExprId="MONTH_RANGE_01" tempExprTypeId="MONTH_RANGE" description="January" integer1="0" integer2="0"/> - <TemporalExpression tempExprId="MONTH_RANGE_02" tempExprTypeId="MONTH_RANGE" description="February" integer1="1" integer2="1"/> - <TemporalExpression tempExprId="MONTH_RANGE_03" tempExprTypeId="MONTH_RANGE" description="March" integer1="2" integer2="2"/> - <TemporalExpression tempExprId="MONTH_RANGE_04" tempExprTypeId="MONTH_RANGE" description="April" integer1="3" integer2="3"/> - <TemporalExpression tempExprId="MONTH_RANGE_05" tempExprTypeId="MONTH_RANGE" description="May" integer1="4" integer2="4"/> - <TemporalExpression tempExprId="MONTH_RANGE_06" tempExprTypeId="MONTH_RANGE" description="June" integer1="5" integer2="5"/> - <TemporalExpression tempExprId="MONTH_RANGE_07" tempExprTypeId="MONTH_RANGE" description="July" integer1="6" integer2="6"/> - <TemporalExpression tempExprId="MONTH_RANGE_08" tempExprTypeId="MONTH_RANGE" description="August" integer1="7" integer2="7"/> - <TemporalExpression tempExprId="MONTH_RANGE_09" tempExprTypeId="MONTH_RANGE" description="September" integer1="8" integer2="8"/> - <TemporalExpression tempExprId="MONTH_RANGE_10" tempExprTypeId="MONTH_RANGE" description="October" integer1="9" integer2="9"/> - <TemporalExpression tempExprId="MONTH_RANGE_11" tempExprTypeId="MONTH_RANGE" description="November" integer1="10" integer2="10"/> - <TemporalExpression tempExprId="MONTH_RANGE_12" tempExprTypeId="MONTH_RANGE" description="December" integer1="11" integer2="11"/> - <TemporalExpression tempExprId="MONTH_RANGE_13" tempExprTypeId="MONTH_RANGE" description="Undecimber" integer1="12" integer2="12"/> - - <!-- Pre-define all 31 days of the month --> - <TemporalExpression tempExprId="DAYOFMONTH_01" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 1 of Month" integer1="1" integer2="1"/> - <TemporalExpression tempExprId="DAYOFMONTH_02" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 2 of Month" integer1="2" integer2="2"/> - <TemporalExpression tempExprId="DAYOFMONTH_03" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 3 of Month" integer1="3" integer2="3"/> - <TemporalExpression tempExprId="DAYOFMONTH_04" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 4 of Month" integer1="4" integer2="4"/> - <TemporalExpression tempExprId="DAYOFMONTH_05" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 5 of Month" integer1="5" integer2="5"/> - <TemporalExpression tempExprId="DAYOFMONTH_06" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 6 of Month" integer1="6" integer2="6"/> - <TemporalExpression tempExprId="DAYOFMONTH_07" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 7 of Month" integer1="7" integer2="7"/> - <TemporalExpression tempExprId="DAYOFMONTH_08" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 8 of Month" integer1="8" integer2="8"/> - <TemporalExpression tempExprId="DAYOFMONTH_09" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 9 of Month" integer1="9" integer2="9"/> - <TemporalExpression tempExprId="DAYOFMONTH_10" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 10 of Month" integer1="10" integer2="10"/> - <TemporalExpression tempExprId="DAYOFMONTH_11" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 11 of Month" integer1="11" integer2="11"/> - <TemporalExpression tempExprId="DAYOFMONTH_12" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 12 of Month" integer1="12" integer2="12"/> - <TemporalExpression tempExprId="DAYOFMONTH_13" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 13 of Month" integer1="13" integer2="13"/> - <TemporalExpression tempExprId="DAYOFMONTH_14" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 14 of Month" integer1="14" integer2="14"/> - <TemporalExpression tempExprId="DAYOFMONTH_15" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 15 of Month" integer1="15" integer2="15"/> - <TemporalExpression tempExprId="DAYOFMONTH_16" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 16 of Month" integer1="16" integer2="16"/> - <TemporalExpression tempExprId="DAYOFMONTH_17" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 17 of Month" integer1="17" integer2="17"/> - <TemporalExpression tempExprId="DAYOFMONTH_18" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 18 of Month" integer1="18" integer2="18"/> - <TemporalExpression tempExprId="DAYOFMONTH_19" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 19 of Month" integer1="19" integer2="19"/> - <TemporalExpression tempExprId="DAYOFMONTH_20" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 20 of Month" integer1="20" integer2="20"/> - <TemporalExpression tempExprId="DAYOFMONTH_21" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 21 of Month" integer1="21" integer2="21"/> - <TemporalExpression tempExprId="DAYOFMONTH_22" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 22 of Month" integer1="22" integer2="22"/> - <TemporalExpression tempExprId="DAYOFMONTH_23" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 23 of Month" integer1="23" integer2="23"/> - <TemporalExpression tempExprId="DAYOFMONTH_24" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 24 of Month" integer1="24" integer2="24"/> - <TemporalExpression tempExprId="DAYOFMONTH_25" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 25 of Month" integer1="25" integer2="25"/> - <TemporalExpression tempExprId="DAYOFMONTH_26" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 26 of Month" integer1="26" integer2="26"/> - <TemporalExpression tempExprId="DAYOFMONTH_27" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 27 of Month" integer1="27" integer2="27"/> - <TemporalExpression tempExprId="DAYOFMONTH_28" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 28 of Month" integer1="28" integer2="28"/> - <TemporalExpression tempExprId="DAYOFMONTH_29" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 29 of Month" integer1="29" integer2="29"/> - <TemporalExpression tempExprId="DAYOFMONTH_30" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 30 of Month" integer1="30" integer2="30"/> - <TemporalExpression tempExprId="DAYOFMONTH_31" tempExprTypeId="DAY_OF_MONTH_RANGE" description="Day 31 of Month" integer1="31" integer2="31"/> - <!-- Pre-define nth Monday of the month - many US observances occur on a Monday --> <TemporalExpression tempExprId="1ST_MONDAY_IN_MONTH" tempExprTypeId="DAY_IN_MONTH" description="First Monday in Month" integer1="2" integer2="1"/> <TemporalExpression tempExprId="2ND_MONDAY_IN_MONTH" tempExprTypeId="DAY_IN_MONTH" description="Second Monday in Month" integer1="2" integer2="2"/> Modified: ofbiz/branches/jackrabbit20100709/framework/service/ofbiz-component.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/service/ofbiz-component.xml?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/service/ofbiz-component.xml (original) +++ ofbiz/branches/jackrabbit20100709/framework/service/ofbiz-component.xml Mon Jan 9 17:59:01 2012 @@ -30,6 +30,7 @@ under the License. <entity-resource type="model" reader-name="main" loader="main" location="entitydef/entitymodel.xml"/> <entity-resource type="data" reader-name="seed" loader="main" location="data/ScheduledServiceData.xml"/> <entity-resource type="data" reader-name="seed-initial" loader="main" location="data/ScheduledServices.xml"/> + <entity-resource type="data" reader-name="seed" loader="main" location="data/ServiceSeedData.xml"/> <entity-resource type="data" reader-name="seed" loader="main" location="data/ServiceSecurityData.xml"/> <entity-resource type="data" reader-name="demo" loader="main" location="data/ServiceDemoData.xml"/> Modified: ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java URL: http://svn.apache.org/viewvc/ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java?rev=1229278&r1=1229277&r2=1229278&view=diff ============================================================================== --- ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java (original) +++ ofbiz/branches/jackrabbit20100709/framework/webapp/src/org/ofbiz/webapp/control/RequestHandler.java Mon Jan 9 17:59:01 2012 @@ -139,6 +139,18 @@ public class RequestHandler { requestMap = requestMapMap.get(defaultRequest); } } + + // check for override view + if (overrideViewUri != null) { + ConfigXMLReader.ViewMap viewMap = getControllerConfig().getViewMapMap().get(overrideViewUri); + if (viewMap == null) { + String defaultRequest = controllerConfig.getDefaultRequest(); + if (defaultRequest != null) { // required! to avoid a null pointer exception and generate a requesthandler exception if default request not found. + requestMap = requestMapMap.get(defaultRequest); + } + } + } + // still not found so stop if (requestMap == null) { throw new RequestHandlerException(requestMissingErrorMessage); |
Free forum by Nabble | Edit this page |