svn commit: r1747642 - in /ofbiz/trunk/specialpurpose/birt: webapp/ordermgr/WEB-INF/actions/reports/OrderByChannel.groovy webapp/ordermgr/reports/OrdersByChannel.rptdesign widget/order/OrderForms.xml

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

svn commit: r1747642 - in /ofbiz/trunk/specialpurpose/birt: webapp/ordermgr/WEB-INF/actions/reports/OrderByChannel.groovy webapp/ordermgr/reports/OrdersByChannel.rptdesign widget/order/OrderForms.xml

Deepak Dixit-5
Author: deepak
Date: Fri Jun 10 06:54:06 2016
New Revision: 1747642

URL: http://svn.apache.org/viewvc?rev=1747642&view=rev
Log:
(OFBIZ-7273) Applied slightly modified patch from jira ticket
=======================================
Report "Sale Orders By Channel" is not rendering details
=======================================
Thanks Nameet Jain for your contirbution.

Modified:
    ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/WEB-INF/actions/reports/OrderByChannel.groovy
    ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/reports/OrdersByChannel.rptdesign
    ofbiz/trunk/specialpurpose/birt/widget/order/OrderForms.xml

Modified: ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/WEB-INF/actions/reports/OrderByChannel.groovy
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/WEB-INF/actions/reports/OrderByChannel.groovy?rev=1747642&r1=1747641&r2=1747642&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/WEB-INF/actions/reports/OrderByChannel.groovy (original)
+++ ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/WEB-INF/actions/reports/OrderByChannel.groovy Fri Jun 10 06:54:06 2016
@@ -20,12 +20,11 @@
 import org.ofbiz.base.util.*;
 
 birtParameters = [:];
-if(request.getParameter("saleChannel")){
-    birtParameters.saleChannel = request.getParameter("saleChannel");
+if(request.getParameter("SalesChannel")){
+    birtParameters.saleChannel = request.getParameter("SalesChannel");
 }else{
     birtParameters.saleChannel = "null";
 }
-
 request.setAttribute("birtParameters", birtParameters);
 
 return "success";

Modified: ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/reports/OrdersByChannel.rptdesign
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/reports/OrdersByChannel.rptdesign?rev=1747642&r1=1747641&r2=1747642&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/reports/OrdersByChannel.rptdesign (original)
+++ ofbiz/trunk/specialpurpose/birt/webapp/ordermgr/reports/OrdersByChannel.rptdesign Fri Jun 10 06:54:06 2016
@@ -255,7 +255,7 @@ module = "OrdersByChannel.rptdesign";]]>
             <method name="open"><![CDATA[salesOrderItemFacts = null;
 try {
     if(params["saleChannel"] != "null"){
-        salesOrderItemFacts = delegator.findByAnd("SalesOrderItemFact", UtilMisc.toMap("saleChannel", params["saleChannel"]), null, false);
+        salesOrderItemFacts = delegator.findByAnd("SalesOrderItemFact", UtilMisc.toMap("salesChannelEnumId", params["saleChannel"]), null, false);
     }else{
         salesOrderItemFacts = delegator.findList("SalesOrderItemFact", null, null, null, null, false);
     }
@@ -267,17 +267,13 @@ countOfRow = 0;
 if (salesOrderItemFacts) {
     totalRow = salesOrderItemFacts.size();
 }]]></method>
-            <method name="fetch"><![CDATA[if (countOfRow == totalRow - 1) return false;
-
+            <method name="fetch"><![CDATA[if (countOfRow > (totalRow - 1)) return false;
 salesOrderItemFact = salesOrderItemFacts.get(countOfRow);
-
 row["orderId"] = salesOrderItemFact.getString("orderId");
 row["orderItemSeqId"] = salesOrderItemFact.getString("orderItemSeqId");
-row["orderStatus"] = salesOrderItemFact.getString("orderStatus");
 row["quantity"] = salesOrderItemFact.getString("quantity");
-row["saleChannel"] = salesOrderItemFact.getString("saleChannel");
+row["saleChannel"] = salesOrderItemFact.getString("brand");
 row["extNetAmount"] = salesOrderItemFact.getString("extNetAmount");
-
 countOfRow ++;
 return true;]]></method>
         </script-data-set>

Modified: ofbiz/trunk/specialpurpose/birt/widget/order/OrderForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/specialpurpose/birt/widget/order/OrderForms.xml?rev=1747642&r1=1747641&r2=1747642&view=diff
==============================================================================
--- ofbiz/trunk/specialpurpose/birt/widget/order/OrderForms.xml (original)
+++ ofbiz/trunk/specialpurpose/birt/widget/order/OrderForms.xml Fri Jun 10 06:54:06 2016
@@ -78,7 +78,7 @@ under the License.
         <field name="SalesChannel" title="${uiLabelMap.OrderSalesChannel}">
             <drop-down allow-empty="false">
                 <option key="" description="- ${uiLabelMap.CommonSelectAny} -"/>
-                <entity-options entity-name="Enumeration" key-field-name="description">
+                <entity-options entity-name="Enumeration" key-field-name="enumId" description="${description}">
                     <entity-constraint name="enumTypeId" operator="equals" value="ORDER_SALES_CHANNEL"/>
                 </entity-options>
             </drop-down>