svn commit: r1788020 - in /ofbiz/ofbiz-plugins/trunk/birt: config/BirtErrorUiLabels.xml groovyScripts/report/PrepareBirtCall.groovy

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

svn commit: r1788020 - in /ofbiz/ofbiz-plugins/trunk/birt: config/BirtErrorUiLabels.xml groovyScripts/report/PrepareBirtCall.groovy

jleroux@apache.org
Author: jleroux
Date: Tue Mar 21 18:52:50 2017
New Revision: 1788020

URL: http://svn.apache.org/viewvc?rev=1788020&view=rev
Log:
Fixed: After creating a new Flexible Birt report, before visualising it you
need to do other actions
(OFBIZ-9194)

The solution I provided with revision: 1781218 was wrong. A really satisfying
solution would be to gray the "Send" button on the
birt/control/CreateFlexibleReport page. But that's not something easy to do
because it's generated from a content.

So I decided to remove the part in the PrepareBirtCall.groovy and add an
indication in the BirtErrorNotPublishedReport for users to use their browser
back button. Because you catch a ViewHandlerException in
RequestHandler.renderView() and there is not much you can do at this stage...

Modified:
    ofbiz/ofbiz-plugins/trunk/birt/config/BirtErrorUiLabels.xml
    ofbiz/ofbiz-plugins/trunk/birt/groovyScripts/report/PrepareBirtCall.groovy

Modified: ofbiz/ofbiz-plugins/trunk/birt/config/BirtErrorUiLabels.xml
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/birt/config/BirtErrorUiLabels.xml?rev=1788020&r1=1788019&r2=1788020&view=diff
==============================================================================
--- ofbiz/ofbiz-plugins/trunk/birt/config/BirtErrorUiLabels.xml (original)
+++ ofbiz/ofbiz-plugins/trunk/birt/config/BirtErrorUiLabels.xml Tue Mar 21 18:52:50 2017
@@ -66,8 +66,8 @@
         <value xml:lang="fr">Aucun rapport à supprimer</value>
     </property>
     <property key="BirtErrorNotPublishedReport">
-        <value xml:lang="en">After creating a new Flexible Birt report, before visualising it, you need to add the data set fields with the Birt Report Designer and publish the report</value>
-        <value xml:lang="fr">Après avoir créé un nouveau rapport Birt Flexible, avant de le visualiser, vous devez ajouter les champs du jeu de données (data set fields) avec le Concepteur de rapports Birt (Birt Report Designer) et publier le rapport</value>
+        <value xml:lang="en">After creating a new Flexible Birt report, before visualising it, you need to add the data set fields with the Birt Report Designer and publish the report. Use your browser back button...</value>
+        <value xml:lang="fr">Après avoir créé un nouveau rapport Birt Flexible, avant de le visualiser, vous devez ajouter les champs du jeu de données (data set fields) avec le Concepteur de rapports Birt (Birt Report Designer) et publier le rapport. Utilisez le bouton de retour du navigateur...</value>
     </property>
     <property key="BirtErrorRetrievingTurnOver">
         <value xml:lang="en">Error while retrieving turnover informations</value>

Modified: ofbiz/ofbiz-plugins/trunk/birt/groovyScripts/report/PrepareBirtCall.groovy
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/birt/groovyScripts/report/PrepareBirtCall.groovy?rev=1788020&r1=1788019&r2=1788020&view=diff
==============================================================================
--- ofbiz/ofbiz-plugins/trunk/birt/groovyScripts/report/PrepareBirtCall.groovy (original)
+++ ofbiz/ofbiz-plugins/trunk/birt/groovyScripts/report/PrepareBirtCall.groovy Tue Mar 21 18:52:50 2017
@@ -26,9 +26,5 @@ birtParameters.modelElementName = parame
 birtParameters.userLogin = context.userLogin
 birtParameters.locale = locale
 
-if(!birtParameters.rptDesignFile) {
-    request.setAttribute("_ERROR_MESSAGE_", UtilProperties.getMessage("BirtErrorUiLabels", "BirtErrorNotPublishedReport", locale))
-    return "error"
-}
 request.setAttribute("birtParameters", birtParameters)
 return "success"