[fix] problem in o2m
[odoo/odoo.git] / addons / auction / report / total.xsl
1 <?xml version="1.0" encoding="utf-8"?>
2 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format">
3
4         <xsl:import href="../../base/report/corporate_defaults.xsl"/>
5
6         <xsl:template match="/">
7                 <xsl:apply-templates select="report"/>
8         </xsl:template>
9
10         <xsl:template match="/">
11                 <document filename="example_5.pdf">
12                 <template >
13                         <pageTemplate id="main">
14                                 <frame id="mainbox" x1="2cm" y1="2cm" width="19cm" height="24cm"/>
15                                 <pageGraphics>
16                                         <xsl:apply-imports/>
17                                 </pageGraphics>
18                         </pageTemplate>
19                 </template>
20
21
22                 <stylesheet>
23                         <paraStyle name="section" fontName="Helvetica-Bold" fontSize="16" spaceAfter="0.5cm" spaceBefore="1.5cm"/>
24                 </stylesheet>
25                 <story>
26                         <spacer length="2cm"/>
27                         <para t="1">Date printing: <xsl:value-of select="report/date"/></para>
28                         <para style="section" t="1">
29                                 Auction
30                         </para>
31                         <xsl:apply-templates select="report/auction"/>
32                         <para style="section" t="1">
33                                 Items
34                         </para>
35                         <xsl:apply-templates select="report/objects"/>
36                         <para style="section" t="1">
37                                 Buyers
38                         </para>
39                         <xsl:apply-templates select="report/buyer"/>
40                         <para style="section" t="1">
41                                 Sellers
42                         </para>
43                         <xsl:apply-templates select="report/seller"/>
44                 </story>
45                 </document>
46         </xsl:template>
47
48         <xsl:template match="report/buyer">
49                 <blockTable colWidths="4cm,14.9cm">
50                 <tr>
51                         <td t="1"># of buyers:</td>
52                         <td><xsl:value-of select="buy_nbr"/></td>
53                 </tr><tr>
54                         <td t="1"># of paid items:</td>
55                         <td><xsl:value-of select="paid_nbr"/></td>
56                 </tr><tr>
57                         <td t="1"># commissions:</td>
58                         <td><xsl:value-of select="comm_nbr"/></td>
59                 </tr><tr>
60                         <td t="1"># of items taken away:</td>
61                         <td><xsl:value-of select="taken_nbr"/></td>
62                 </tr><tr>
63                         <td t="1">Credit:</td>
64                         <td><xsl:value-of select="credit"/> EUR</td>
65                 </tr><tr>
66                         <td t="1">Paid:</td>
67                         <td><xsl:value-of select="paid"/> EUR</td>
68                 </tr>
69                 </blockTable>
70         </xsl:template>
71
72         <xsl:template match="report/auction">
73                 <blockTable colWidths="4cm,14.9cm">
74                 <tr>
75                         <td t="1">Auction:</td>
76                         <td><xsl:value-of select="title"/></td>
77                 </tr><tr>
78                         <td t="1">Date:</td>
79                         <td><xsl:value-of select="date"/></td>
80                 </tr>
81                 </blockTable>
82         </xsl:template>
83
84         <xsl:template match="/report/seller">
85                 <blockTable colWidths="4cm,14.9cm">
86                 <tr>
87                         <td t="1"># of sellers:</td>
88                         <td><xsl:value-of select="sell_nbr"/></td>
89                 </tr><tr>
90                         <td t="1">Debit:</td>
91                         <td><xsl:value-of select="debit"/> EUR</td>
92                 </tr>
93                 </blockTable>
94         </xsl:template>
95
96         <xsl:template match="/report/objects">
97                 <blockTable colWidths="4cm,14.9cm">
98                 <tr>
99                         <td t="1"># of items:</td>
100                         <td><xsl:value-of select="obj_nbr"/></td>
101                 </tr><tr>
102                         <td t="1">Min Estimate:</td>
103                         <td><xsl:value-of select="est_min"/></td>
104                 </tr><tr>
105                         <td t="1">Max Estimate:</td>
106                         <td><xsl:value-of select="est_max"/></td>
107                 </tr><tr>
108                         <td t="1"># of unsold items:</td>
109                         <td><xsl:value-of select="unsold"/></td>
110                 </tr><tr>
111                         <td t="1">Adjudication:</td>
112                         <td><xsl:value-of select="obj_price"/> EUR</td>
113                 </tr>
114                 </blockTable>
115         </xsl:template>
116
117 </xsl:stylesheet>