[IMP] product: move product packaging field from product.product to product.template
[odoo/odoo.git] / addons / product / views / report_pricelist.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <openerp>
3 <data>
4 <template id="report_pricelist">
5     <t t-call="report.html_container">
6         <t t-call="report.internal_layout">
7             <div class="page">
8                 <h2>Price List</h2>
9
10                 <div class="row mt32 mb32">
11                     <div class="col-xs-3">
12                         <strong>Price List Name</strong>:<br/>
13                         <span t-esc="get_pricelist(data['form']['price_list'])"/>
14                     </div>
15                     <div class="col-xs-3">
16                         <strong>Currency</strong>:<br/>
17                         <span t-esc="get_currency(data['form']['price_list'])"/>
18                     </div>
19                     <div class="col-xs-3">
20                         <strong>Print date</strong>:<br/>
21                         <t t-esc="formatLang(time.strftime('%Y-%m-%d'), date=True)"/>
22                     </div>
23                 </div>
24
25                 <table class="table table-condensed">
26                     <thead>
27                         <tr>
28                             <th>
29                                 <strong>Description</strong>
30                             </th>
31                             <t t-foreach="get_titles(data['form'])" t-as="k">
32                                 <th t-if="k.has_key('qty1')"><strong t-esc="k['qty1']"/></th>
33                                 <th t-if="k.has_key('qty2')"><strong t-esc="k['qty2']"/></th>
34                                 <th t-if="k.has_key('qty3')"><strong t-esc="k['qty3']"/></th>
35                                 <th t-if="k.has_key('qty4')"><strong t-esc="k['qty4']"/></th>
36                                 <th t-if="k.has_key('qty5')"><strong t-esc="k['qty5']"/></th>
37                             </t>
38                         </tr>
39                     </thead>
40                     <tbody>
41                         <t t-foreach="get_categories(objects,data['form'])" t-as="c">
42                             <tr>
43                                 <td colspan="100">
44                                     <strong t-esc="c['name']"/>
45                                 </td>
46                             </tr>
47                             <tr t-foreach="c['products']" t-as="p">
48                                 <td>
49                                     <t t-if="p.get('code')">
50                                         [<span t-esc="p['code']"/>]
51                                     </t> 
52                                     <span t-esc="p['name']"/>
53                                 </td>
54                                 <td t-if="p.has_key('qty1') and p['qty1']"><strong t-esc="p['qty1']"/></td>
55                                 <td t-if="p.has_key('qty2') and p['qty2']"><strong t-esc="p['qty2']"/></td>
56                                 <td t-if="p.has_key('qty3') and p['qty3']"><strong t-esc="p['qty3']"/></td>
57                                 <td t-if="p.has_key('qty4') and p['qty4']"><strong t-esc="p['qty4']"/></td>
58                                 <td t-if="p.has_key('qty5') and p['qty5']"><strong t-esc="p['qty5']"/></td>
59                             </tr>
60                         </t>
61                     </tbody>
62                 </table>
63             </div>
64         </t>
65     </t>
66 </template>
67 </data>
68 </openerp>