[ofbiz-framework] branch trunk updated: Improved: Allow Unsafe Event Message (OFBIZ-12147)

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

[ofbiz-framework] branch trunk updated: Improved: Allow Unsafe Event Message (OFBIZ-12147)

James Yong-2
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 6a08920  Improved: Allow Unsafe Event Message (OFBIZ-12147)
6a08920 is described below

commit 6a0892060630b8bc7b0bee3e7614ae133f49e020
Author: James Yong <[hidden email]>
AuthorDate: Thu Jan 21 22:53:57 2021 +0800

    Improved: Allow Unsafe Event Message (OFBIZ-12147)
   
    Only delay jgrowl message when there is _UNSAFE_EVENT_MESSAGE_
   
    Thanks Michael for feedback.
---
 themes/common-theme/template/includes/Messages.ftl | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/themes/common-theme/template/includes/Messages.ftl b/themes/common-theme/template/includes/Messages.ftl
index e9b9322..67cbb33 100644
--- a/themes/common-theme/template/includes/Messages.ftl
+++ b/themes/common-theme/template/includes/Messages.ftl
@@ -102,11 +102,17 @@ under the License.
     <#assign jGrowlHeight = modelTheme.getProperty("jgrowlHeight")>
     <#assign jGrowlSpeed = modelTheme.getProperty("jgrowlSpeed")>
     <script>
+    <#if unsafeEventMessage?has_content>
 setTimeout(function(){
   showjGrowl(
           "${uiLabelMap.CommonShowAll}", "${uiLabelMap.CommonCollapse}", "${uiLabelMap.CommonHideAllNotifications}",
           "${jGrowlPosition}", "${jGrowlWidth}", "${jGrowlHeight}", "${jGrowlSpeed}");
-}, 10);
+      }, 10);
+    <#else>
+showjGrowl(
+        "${uiLabelMap.CommonShowAll}", "${uiLabelMap.CommonCollapse}", "${uiLabelMap.CommonHideAllNotifications}",
+        "${jGrowlPosition}", "${jGrowlWidth}", "${jGrowlHeight}", "${jGrowlSpeed}");
+    </#if>
     </script>
   </#if>
 </#escape>