summaryrefslogtreecommitdiff
path: root/jasper_reports
diff options
context:
space:
mode:
Diffstat (limited to 'jasper_reports')
-rw-r--r--jasper_reports/custom_reports/proforma_invoice.jrxml15
-rw-r--r--jasper_reports/custom_reports/sales_without_disc.jrxml15
2 files changed, 22 insertions, 8 deletions
diff --git a/jasper_reports/custom_reports/proforma_invoice.jrxml b/jasper_reports/custom_reports/proforma_invoice.jrxml
index cfaf829..3ee83a1 100644
--- a/jasper_reports/custom_reports/proforma_invoice.jrxml
+++ b/jasper_reports/custom_reports/proforma_invoice.jrxml
@@ -110,6 +110,10 @@
<property name="net.sf.jasperreports.xpath.field.expression" value="Customer-partner_id/Street2-street2"/>
<fieldDescription><![CDATA[Customer-partner_id/Street2-street2]]></fieldDescription>
</field>
+ <field name="Parent_name-parent_name" class="java.lang.String">
+ <property name="net.sf.jasperreports.xpath.field.expression" value="Customer-partner_id/Parent_name-parent_name"/>
+ <fieldDescription><![CDATA[Customer-partner_id/Parent_name-parent_name]]></fieldDescription>
+ </field>
<variable name="UnitPrice" class="java.math.BigDecimal">
<variableExpression><![CDATA[$F{Included_in_Price-price_include}=="True"?new BigDecimal($F{pricewithtax}):new BigDecimal($F{pricewithouttax})]]></variableExpression>
</variable>
@@ -129,6 +133,9 @@
<variableExpression><![CDATA[$F{Status-state}.toString().equals("sale")?"Pro-Forma Invoice # "+$F{documentno}:"Pro-Forma Invoice # "+$F{documentno}]]></variableExpression>
<initialValueExpression><![CDATA[$F{Status-state}.toString().equals("sale")?"Pro-Forma Invoice # "+$F{documentno}:"Pro-Forma Invoice # "+$F{documentno}]]></initialValueExpression>
</variable>
+ <variable name="customer_name" class="java.lang.String">
+ <initialValueExpression><![CDATA[$F{Parent_name-parent_name}.isEmpty()?$F{customername}:$F{Parent_name-parent_name}]]></initialValueExpression>
+ </variable>
<background>
<band splitType="Stretch"/>
</background>
@@ -191,13 +198,13 @@ Indonesia]]></text>
<text><![CDATA[Salesperson :]]></text>
</staticText>
<textField>
- <reportElement x="280" y="0" width="275" height="20" uuid="f479f74f-3834-4df7-b59f-431b722b9ec0"/>
- <textFieldExpression><![CDATA[$F{customername}]]></textFieldExpression>
- </textField>
- <textField>
<reportElement x="280" y="20" width="275" height="40" uuid="7e7d81ad-fb57-4528-bbd2-88f4d15f3ccc"/>
<textFieldExpression><![CDATA[$F{Street-street}]]></textFieldExpression>
</textField>
+ <textField>
+ <reportElement x="280" y="0" width="275" height="20" uuid="85b92ba9-a425-421e-bf69-6bc6b1018099"/>
+ <textFieldExpression><![CDATA[$V{customer_name}]]></textFieldExpression>
+ </textField>
</band>
</pageHeader>
<columnHeader>
diff --git a/jasper_reports/custom_reports/sales_without_disc.jrxml b/jasper_reports/custom_reports/sales_without_disc.jrxml
index c293008..a897ab7 100644
--- a/jasper_reports/custom_reports/sales_without_disc.jrxml
+++ b/jasper_reports/custom_reports/sales_without_disc.jrxml
@@ -110,6 +110,10 @@
<property name="net.sf.jasperreports.xpath.field.expression" value="Customer-partner_id/Street2-street2"/>
<fieldDescription><![CDATA[Customer-partner_id/Street2-street2]]></fieldDescription>
</field>
+ <field name="Parent_name-parent_name" class="java.lang.String">
+ <property name="net.sf.jasperreports.xpath.field.expression" value="Customer-partner_id/Parent_name-parent_name"/>
+ <fieldDescription><![CDATA[Customer-partner_id/Parent_name-parent_name]]></fieldDescription>
+ </field>
<variable name="UnitPrice" class="java.math.BigDecimal">
<variableExpression><![CDATA[$F{Included_in_Price-price_include}=="True"?new BigDecimal($F{pricewithtax}):new BigDecimal($F{pricewithouttax})]]></variableExpression>
</variable>
@@ -129,6 +133,9 @@
<variableExpression><![CDATA[$F{Status-state}.toString().equals("sale")?"Order # "+$F{documentno}:"Quotation # "+$F{documentno}]]></variableExpression>
<initialValueExpression><![CDATA[$F{Status-state}.toString().equals("sale")?"Order # "+$F{documentno}:"Quotation # "+$F{documentno}]]></initialValueExpression>
</variable>
+ <variable name="customer_name" class="java.lang.String">
+ <initialValueExpression><![CDATA[$F{Parent_name-parent_name}.isEmpty()?$F{customername}:$F{Parent_name-parent_name}]]></initialValueExpression>
+ </variable>
<background>
<band splitType="Stretch"/>
</background>
@@ -191,13 +198,13 @@ Indonesia]]></text>
<text><![CDATA[Salesperson :]]></text>
</staticText>
<textField>
- <reportElement x="280" y="0" width="275" height="20" uuid="f479f74f-3834-4df7-b59f-431b722b9ec0"/>
- <textFieldExpression><![CDATA[$F{customername}]]></textFieldExpression>
- </textField>
- <textField>
<reportElement x="280" y="20" width="275" height="40" uuid="7e7d81ad-fb57-4528-bbd2-88f4d15f3ccc"/>
<textFieldExpression><![CDATA[$F{Street-street}]]></textFieldExpression>
</textField>
+ <textField>
+ <reportElement x="280" y="0" width="275" height="20" uuid="f5c9f6ff-5207-4521-8418-7bb0b0058add"/>
+ <textFieldExpression><![CDATA[$V{customer_name}]]></textFieldExpression>
+ </textField>
</band>
</pageHeader>
<columnHeader>