[ofbiz-framework] branch trunk updated: Improved: widget tag (OFBIZ-11686)
This is an automated email from the ASF dual-hosted git repository. jamesyong pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git The following commit(s) were added to refs/heads/trunk by this push: new 60c78d2 Improved: widget tag (OFBIZ-11686) 60c78d2 is described below commit 60c78d24be4ab2b4f8aa2f6603968863c12b9b92 Author: James Yong AuthorDate: Fri May 15 11:16:15 2020 +0800 Improved: widget tag (OFBIZ-11686) Removed script-template tag. Use multi-block=true on html-template tag instead. --- applications/order/template/order/FindOrders.ftl | 72 +++- .../order/template/order/FindOrders.js.ftl | 86 -- .../order/widget/ordermgr/OrderViewScreens.xml | 3 +- .../webapp/ftl/ScriptTemplateListTransform.java| 5 +- framework/widget/dtd/widget-screen.xsd | 9 +- .../widget/artifact/ArtifactInfoGatherer.java | 5 - .../org/apache/ofbiz/widget/model/HtmlWidget.java | 124 + .../ofbiz/widget/model/ModelWidgetVisitor.java | 2 - .../ofbiz/widget/model/ScriptTemplateUtil.java | 43 --- .../ofbiz/widget/model/XmlWidgetVisitor.java | 10 +- .../ofbiz/widget/renderer/ScreenRenderer.java | 7 +- 11 files changed, 160 insertions(+), 206 deletions(-) diff --git a/applications/order/template/order/FindOrders.ftl b/applications/order/template/order/FindOrders.ftl index 0d1923d..6eaff5b 100644 --- a/applications/order/template/order/FindOrders.ftl +++ b/applications/order/template/order/FindOrders.ftl @@ -17,6 +17,76 @@ specific language governing permissions and limitations under the License. --> + +function lookupOrders(click) { +orderIdValue = document.lookuporder.orderId.value; +if (orderIdValue.length > 1) { +document.lookuporder.action = "<@ofbizUrl>orderview@ofbizUrl>"; +document.lookuporder.method = "get"; +} else { +document.lookuporder.action = "<@ofbizUrl>searchorders@ofbizUrl>"; +} + +if (click) { +document.lookuporder.submit(); +} +return true; +} +function toggleOrderId(master) { +var form = document.massOrderChangeForm; +var orders = form.elements.length; +for (var i = 0; i < orders; i++) { +var element = form.elements[i]; +if ("orderIdList" == element.name) { +element.checked = master.checked; +} +} +toggleOrderIdList(); +} +function setServiceName(selection) { +document.massOrderChangeForm.action = selection.value; +} +function runAction() { +var form = document.massOrderChangeForm; +form.submit(); +} + +function toggleOrderIdList() { +var form = document.massOrderChangeForm; +var orders = form.elements.length; +var isAllSelected = true; +var isSingle = true; +for (var i = 0; i < orders; i++) { +var element = form.elements[i]; +if ("orderIdList" == element.name) { +if (element.checked) { +isSingle = false; +} else { +isAllSelected = false; +} +} +} +if (isAllSelected) { +jQuery('#checkAllOrders').attr('checked', true); +} else { +jQuery('#checkAllOrders').attr('checked', false); +} +jQuery('#checkAllOrders').attr("checked", isAllSelected); +if (!isSingle && jQuery('#serviceName').val() != "") { +jQuery('#submitButton').removeAttr("disabled"); +} else { +jQuery('#submitButton').attr('disabled', true); +} +} + +function paginateOrderList(viewSize, viewIndex, hideFields) { +document.paginationForm.viewSize.value = viewSize; +document.paginationForm.viewIndex.value = viewIndex; +document.paginationForm.hideFields.value = hideFields; +document.paginationForm.submit(); +} + + <#if security.hasEntityPermission("ORDERMGR", "_VIEW", session)> <#if parameters.hideFields?has_content> @@ -404,9 +474,7 @@ under the License. <#if requestParameters.hideFields?default("N") != "Y"> - diff --git a/applications/order/template/order/FindOrders.js.ftl b/applications/order/template/order/FindOrders.js.ftl deleted file mode 100644 index 0b98270..000 --- a/applications/order/template/order/FindOrders.js.ftl +++ /dev/null @@ -1,86 +0,0 @@ -/*** -Licensed to the Apache Software Foundation (ASF) under one -or more contributor license agreements. See the NOTICE file -distributed with this work for additional information -regarding copyright ownership. The ASF licenses this file -to you under the Apache License, Version 2.0 (the -"License"); you may not use this file except in compliance -with the License. You may obtain a copy of the License at - -http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, -software distributed under the License is
[ofbiz-framework] branch trunk updated: Documented: Create a simple INSTALL file with minimum installation information and redirection to more documentation
This is an automated email from the ASF dual-hosted git repository. jleroux pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git The following commit(s) were added to refs/heads/trunk by this push: new 8f2ce4b Documented: Create a simple INSTALL file with minimum installation information and redirection to more documentation 8f2ce4b is described below commit 8f2ce4bc954d2ad07c179ce3aaeaf9365e98f401 Author: Jacques Le Roux AuthorDate: Thu May 14 17:38:28 2020 +0200 Documented: Create a simple INSTALL file with minimum installation information and redirection to more documentation (OFBIZ-11691) Following https://markmail.org/message/xi2bcvnmpdfvfgk2 discussion on dev ML here is the file I suggest. If we are OK we can backport it to the supported release branches. Of course I'm open to modifications... Thanks for their answers: Deepak Nigam, Michael Brohl, Pierre Smits and Taher Alkhateeb --- INSTALL | 57 + 1 file changed, 57 insertions(+) diff --git a/INSTALL b/INSTALL new file mode 100644 index 000..6327120 --- /dev/null +++ b/INSTALL @@ -0,0 +1,57 @@ +Welcome to Apache OFBiz! A powerful top level Apache software project. OFBiz +is an Enterprise Resource Planning (ERP) System written in Java and houses a +large set of libraries, entities, services and features to run all aspects of +your business. + +== System requirements + +The only requirement to run OFBiz is to have the Java Development Kit (JDK) +version 8 installed on your system (not just the JRE, but the full JDK) which +you can download from the below link. Make sure of setting the $JAVA_HOME +environment variable. + +https://adoptopenjdk.net/[JDK download] + + +== Quick start + +To quickly install and fire-up OFBiz, please follow the below instructions from +the command line at the OFBiz top level directory (folder). + +=== Download the Gradle wrapper: + +MS Windows: init-gradle-wrapper +Unix-like OS: ./gradle/init-gradle-wrapper + + +=== Prepare OFBiz: + + Clean system and load the complete OFBiz data +___ +Note: Depending on your Internet connection speed it might take a long time +for this step to complete if you are using OFBiz for the first time as it needs +to download all dependencies. So please be patient! +___ + +MS Windows: gradlew cleanAll loadAll +Unix-like OS: ./gradlew cleanAll loadAll + +=== Start OFBiz: + +MS Windows: gradlew ofbiz +Unix-like OS: ./gradlew ofbiz + +___ +Note: Ignore the % progress indicator because this task does not end as long +as OFBiz is running. +___ + +=== Visit OFBiz through your browser: + +https://localhost:8443/webtools + +== Going further +To complete your installation and use OFBiz please read README.adoc +You may prefer to read this AsciiDoc file in HTML format. +For that simply follow: +https://asciidoctor.org/docs/convert-documents/#converting-a-document-to-html
[ofbiz-plugins] branch trunk updated: Fixed: Application 'ismgr' doesn't show up
This is an automated email from the ASF dual-hosted git repository. jleroux pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/ofbiz-plugins.git The following commit(s) were added to refs/heads/trunk by this push: new 0712402 Fixed: Application 'ismgr' doesn't show up 0712402 is described below commit 071240205f28124378cf23dc5e400c8c62643363 Author: Pierre Smits AuthorDate: Thu May 14 10:58:10 2020 +0200 Fixed: Application 'ismgr' doesn't show up (OFBIZ-11704) fixed: app-bar-display (from 'false' to 'true' added: OFBTOOLS to base-permission --- assetmaint/ofbiz-component.xml | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/assetmaint/ofbiz-component.xml b/assetmaint/ofbiz-component.xml index f2586eb..8060f1a 100644 --- a/assetmaint/ofbiz-component.xml +++ b/assetmaint/ofbiz-component.xml @@ -43,16 +43,16 @@ title="AssetMaint" server="default-server" location="webapp/assetmaint" -base-permission="ASSETMAINT" +base-permission="OFBTOOLS,ASSETMAINT" mount-point="/assetmaint" app-bar-display="true"/> +base-permission="OFBTOOLS,ASSETMAINT" +mount-point="/ismgr" +app-bar-display="true"/>
buildbot failure in on ofbizTrunkFrameworkPlugins
The Buildbot has detected a new failure on builder ofbizTrunkFrameworkPlugins while building ofbiz-framework. Full details are available at: https://ci.apache.org/builders/ofbizTrunkFrameworkPlugins/builds/1354 Buildbot URL: https://ci.apache.org/ Buildslave for this Build: asf946_ubuntu Build Reason: downstream Build Source Stamp: [branch trunk] 4f5e6f9f06095b406128f6cdfce38b325a31668c Blamelist: holivier BUILD FAILED: failed shell_2 Sincerely, -The Buildbot
[ofbiz-framework] branch trunk updated: Fixed: Unable to navigate to 'Recently approved' screen under image management
This is an automated email from the ASF dual-hosted git repository. jleroux pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git The following commit(s) were added to refs/heads/trunk by this push: new fb447e7 Fixed: Unable to navigate to 'Recently approved' screen under image management fb447e7 is described below commit fb447e7b62b12f57f4a9a97da2a934925cdb0d84 Author: Jacques Le Roux AuthorDate: Thu May 14 13:34:42 2020 +0200 Fixed: Unable to navigate to 'Recently approved' screen under image management (OFBIZ-11403) It works on stable demo which uses 2.4.13 instead of 2.5.11 for trunk. I guess it's because since Groovy 2.5 DateTimeFormatter, introduced with Java 8, is used underneath. This fixes and improves it regarding localisation. Because it's easier with DateTimeFormatter and LocalDateTime to handle localisation --- .../imagemanagement/ImageRecentlyApproved.groovy | 29 +++--- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/applications/product/groovyScripts/catalog/imagemanagement/ImageRecentlyApproved.groovy b/applications/product/groovyScripts/catalog/imagemanagement/ImageRecentlyApproved.groovy index 1149cc8..2975122 100644 --- a/applications/product/groovyScripts/catalog/imagemanagement/ImageRecentlyApproved.groovy +++ b/applications/product/groovyScripts/catalog/imagemanagement/ImageRecentlyApproved.groovy @@ -19,26 +19,27 @@ import org.apache.ofbiz.base.util.* import org.apache.ofbiz.entity.util.* -import java.text.SimpleDateFormat -import java.util.List -import java.util.Set import org.apache.ofbiz.entity.condition.EntityCondition import org.apache.ofbiz.entity.condition.EntityOperator import org.apache.ofbiz.entity.util.EntityFindOptions +import java.sql.Timestamp +import java.text.SimpleDateFormat +import java.time.LocalDateTime +import java.time.format.DateTimeFormatter +import java.time.format.FormatStyle +import java.util.List +import java.util.Set + def limit = 13 // set number of days -def sdf = new SimpleDateFormat(" -MM-dd 00:00:00.000") -def sdf2 = new SimpleDateFormat(" dd/MM/") +def sdf = DateTimeFormatter.ofPattern("-MM-dd HH:mm:ss") +def sdf2 = DateTimeFormatter.ofPattern(" dd/MM/", locale); def sdfTime = new SimpleDateFormat("HH:mm") -def today = new Date() +def today = LocalDateTime.now() -for(i in 0..limit){ -def date1 = sdf.format(today-i) -def date2 = sdf.format(today-i+1) -def parseDate1 = sdf.parse(date1) -def parseDate2 = sdf.parse(date2) -def timeStampDate1 = UtilDateTime.toTimestamp(parseDate1) -def timeStampDate2 = UtilDateTime.toTimestamp(parseDate2) +for (i in 0..limit){ +def timeStampDate1 = Timestamp.valueOf(today.minusDays(i+1).format(sdf).toString()) +def timeStampDate2 = Timestamp.valueOf(today.minusDays(i).format(sdf).toString()) // make condition for distinct productId def exprs = [] exprs.add(EntityCondition.makeCondition("productContentTypeId",EntityOperator.EQUALS, "IMAGE")) @@ -55,7 +56,7 @@ for(i in 0..limit){ groupByTimeList.each() { key,value -> tempTimeList.add(value.purchaseFromDate) } - + def time = [] if(tempTimeList.size > 0){ for(j in 0..tempTimeList.size-1){
[ofbiz-framework] branch trunk updated: Improved: widget tag (OFBIZ-11686)
This is an automated email from the ASF dual-hosted git repository. holivier pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git The following commit(s) were added to refs/heads/trunk by this push: new 4f5e6f9 Improved: widget tag (OFBIZ-11686) 4f5e6f9 is described below commit 4f5e6f9f06095b406128f6cdfce38b325a31668c Author: holivier AuthorDate: Thu May 14 09:38:23 2020 +0200 Improved: widget tag (OFBIZ-11686) Correction in javadoc, by "script-template" --- .../java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java | 2 +- .../src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java index c749c87..6b3f385 100644 --- a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java +++ b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java @@ -33,7 +33,7 @@ import freemarker.template.TemplateModelException; import freemarker.template.TemplateTransformModel; /** - * Render the script tags collected from the + * Render the script tags collected from the "script-template" tag */ public class ScriptTemplateListTransform implements TemplateTransformModel { diff --git a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java index d6d16a2..9d3417c 100644 --- a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java +++ b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java @@ -52,7 +52,7 @@ public class ScriptTemplateUtil { } /** - * get the script src links collected from the tags + * get the script src links collected from the "script-template" tags * @param request * @return */
[ofbiz-framework] branch trunkGb deleted (was 4f5e6f9)
This is an automated email from the ASF dual-hosted git repository. holivier pushed a change to branch trunkGb in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git. was 4f5e6f9 Improved: widget tag (OFBIZ-11686) This change permanently discards the following revisions: discard 4f5e6f9 Improved: widget tag (OFBIZ-11686)
[ofbiz-framework] 01/01: Improved: widget tag (OFBIZ-11686)
This is an automated email from the ASF dual-hosted git repository. holivier pushed a commit to branch trunkGb in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git commit 4f5e6f9f06095b406128f6cdfce38b325a31668c Author: holivier AuthorDate: Thu May 14 09:38:23 2020 +0200 Improved: widget tag (OFBIZ-11686) Correction in javadoc, by "script-template" --- .../java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java | 2 +- .../src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java index c749c87..6b3f385 100644 --- a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java +++ b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java @@ -33,7 +33,7 @@ import freemarker.template.TemplateModelException; import freemarker.template.TemplateTransformModel; /** - * Render the script tags collected from the + * Render the script tags collected from the "script-template" tag */ public class ScriptTemplateListTransform implements TemplateTransformModel { diff --git a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java index d6d16a2..9d3417c 100644 --- a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java +++ b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java @@ -52,7 +52,7 @@ public class ScriptTemplateUtil { } /** - * get the script src links collected from the tags + * get the script src links collected from the "script-template" tags * @param request * @return */
[ofbiz-framework] branch trunkGb created (now 4f5e6f9)
This is an automated email from the ASF dual-hosted git repository. holivier pushed a change to branch trunkGb in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git. at 4f5e6f9 Improved: widget tag (OFBIZ-11686) This branch includes the following new commits: new 4f5e6f9 Improved: widget tag (OFBIZ-11686) The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference.
[ofbiz-framework] branch trunkGB deleted (was 4f5e6f9)
This is an automated email from the ASF dual-hosted git repository. holivier pushed a change to branch trunkGB in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git. was 4f5e6f9 Improved: widget tag (OFBIZ-11686) This change permanently discards the following revisions: discard 4f5e6f9 Improved: widget tag (OFBIZ-11686)
[ofbiz-framework] branch trunkGB created (now 4f5e6f9)
This is an automated email from the ASF dual-hosted git repository. holivier pushed a change to branch trunkGB in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git. at 4f5e6f9 Improved: widget tag (OFBIZ-11686) This branch includes the following new commits: new 4f5e6f9 Improved: widget tag (OFBIZ-11686) The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference.
[ofbiz-framework] 01/01: Improved: widget tag (OFBIZ-11686)
This is an automated email from the ASF dual-hosted git repository. holivier pushed a commit to branch trunkGB in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git commit 4f5e6f9f06095b406128f6cdfce38b325a31668c Author: holivier AuthorDate: Thu May 14 09:38:23 2020 +0200 Improved: widget tag (OFBIZ-11686) Correction in javadoc, by "script-template" --- .../java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java | 2 +- .../src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java index c749c87..6b3f385 100644 --- a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java +++ b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/ftl/ScriptTemplateListTransform.java @@ -33,7 +33,7 @@ import freemarker.template.TemplateModelException; import freemarker.template.TemplateTransformModel; /** - * Render the script tags collected from the + * Render the script tags collected from the "script-template" tag */ public class ScriptTemplateListTransform implements TemplateTransformModel { diff --git a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java index d6d16a2..9d3417c 100644 --- a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java +++ b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/ScriptTemplateUtil.java @@ -52,7 +52,7 @@ public class ScriptTemplateUtil { } /** - * get the script src links collected from the tags + * get the script src links collected from the "script-template" tags * @param request * @return */