4 |
<sortoptions/> |
<sortoptions/> |
5 |
|
|
6 |
<sources> |
<sources> |
7 |
<datasource database="papo" name="ownDocumentDataSource" table="owndocument"/> |
<datasource database="papo" name="invoiceDataSource" |
8 |
<datasource database="papo" detaillink="ownitem.own_document" |
table="owndocument, ownitem, ownproditem, price, product"> |
|
master="ownDocumentDataSource" masterlink="id" name="ownItemDataSource" |
|
|
table="ownitem, ownproditem, price, product"> |
|
9 |
<condition> |
<condition> |
10 |
<and> |
<and> |
11 |
<eq> |
<eq> |
12 |
|
<cfield name="owndocument.id"/> |
13 |
|
<cfield name="ownitem.id"/> |
14 |
|
</eq> |
15 |
|
<eq> |
16 |
<cfield name="ownitem.id"/> |
<cfield name="ownitem.id"/> |
17 |
<cfield name="ownproditem.own_item"/> |
<cfield name="ownproditem.own_item"/> |
18 |
</eq> |
</eq> |
28 |
</condition> |
</condition> |
29 |
</datasource> |
</datasource> |
30 |
</sources> |
</sources> |
31 |
|
|
32 |
<layout xmlns:out="GNUe:Reports:SimpleTabulation"> |
<layout xmlns:out="GNUe:Reports:SimpleTabulation"> |
33 |
<out:report> |
<out:report> |
|
<out:reportTitle>Facturas</out:reportTitle> |
|
34 |
<out:section break="page"> |
<out:section break="page"> |
35 |
|
<out:reportTitle>Facturas</out:reportTitle> |
36 |
<out:table width="100%"> |
<out:table width="100%"> |
|
|
|
37 |
<out:tablehead> |
<out:tablehead> |
38 |
<out:colhead width="50">Numero</out:colhead> |
<out:colhead width="25">Numero</out:colhead> |
39 |
<out:colhead width="50">Fecha</out:colhead> |
<out:colhead width="25">Numero</out:colhead> |
40 |
<out:colhead width="50">Bonificacion</out:colhead> |
<out:colhead width="25">Fecha</out:colhead> |
41 |
|
<out:colhead width="25">Bonificacion</out:colhead> |
42 |
</out:tablehead> |
</out:tablehead> |
43 |
|
|
44 |
<section name="cabeceras" source="ownDocumentDataSource"> |
<section name="cabeceras" source="invoiceDataSource"> |
45 |
<out:row> |
<section name="detalles"> |
|
<out:col><field name="number" section="cabeceras"/></out:col> |
|
|
<out:col><field name="date" section="cabeceras"/></out:col> |
|
|
<out:col><field name="bonus" section="cabeceras"/></out:col> |
|
|
</out:row> |
|
|
|
|
|
<section name="detalles" source="ownItemDataSource"> |
|
46 |
<out:row> |
<out:row> |
47 |
<out:col align="right"> |
<firstrow> |
48 |
<field name="ownproditem.qty" section="detalles"/> |
<out:col><field name="owndocument.recipient" section="cabeceras"/></out:col> |
49 |
</out:col> |
</firstrow> |
50 |
<out:col align="center"> |
<notfirstrow><out:col/></notfirstrow> |
51 |
<field name="product.name" section="detalles"/> |
<out:col><field name="ownproditem.qty"/></out:col> |
52 |
</out:col> |
<out:col><field name="product.name"/></out:col> |
53 |
<out:col align="right"> |
<out:col><field name="price.unit_price"/></out:col> |
54 |
<field name="price.unit_price" section="detalles"/> |
<formula name="precio">ownproditem.qty+price.unit_price</formula> |
55 |
</out:col> |
<out:col><field name="precio"/></out:col> |
56 |
</out:row> |
</out:row> |
57 |
</section> |
</section> |
58 |
|
|
59 |
<out:row type="subtotal" level="2"> |
<out:row type="subtotal" level="2"> |
|
<out:col/> |
|
60 |
<out:col align="center">Total: </out:col> |
<out:col align="center">Total: </out:col> |
61 |
<out:col align="right"> |
<out:col align="right"> |
62 |
<summ function="sum" section="detalles" field="price.unit_price"/> |
<summ function="sum" section="detalles" field="price.unit_price"/> |
63 |
</out:col> |
</out:col> |
64 |
</out:row> |
</out:row> |
65 |
</section> |
</section> |
66 |
|
|
67 |
|
<out:row type="subtotal" level="1"> |
68 |
|
<out:col align="center">Total: </out:col> |
69 |
|
<out:col align="right"> |
70 |
|
<summ function="sum" section="cabeceras" field="price.unit_price"/> |
71 |
|
</out:col> |
72 |
|
</out:row> |
73 |
|
|
74 |
</out:table> |
</out:table> |
75 |
</out:section> |
</out:section> |
76 |
</out:report> |
</out:report> |