forked from OCA/timesheet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathreports.xml
86 lines (83 loc) · 3.5 KB
/
reports.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
<?xml version="1.0"?>
<openerp>
<data><record id="attendances_landscape_header" model="ir.header_webkit">
<field name="footer_html"><![CDATA[
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="content-type"/>
<script>
function subst() {
var vars={};
var x=document.location.search.substring(1).split('&');
for(var i in x) {var z=x[i].split('=',2);vars[z[0]] = unescape(z[1]);}
var x=['frompage','topage','page','webpage','section','subsection','subsubsection'];
for(var i in x) {
var y = document.getElementsByClassName(x[i]);
for(var j=0; j<y.length; ++j) y[j].textContent = vars[x[i]];
}
}
</script>
</head>
<% import datetime %>
<body style="border:0" onload="subst()">
<table style="border-top: 1px solid black; width: 1080px">
<tr style="border-collapse:collapse;">
<td style="text-align:left;font-size:10;width:350px;">${formatLang( str(datetime.datetime.today()), date_time=True)}</td>
<td style="text-align:center;font-size:10;width:350px;"></td>
<td style="text-align:right;font-size:10;width:350px;">Page <span class="page"/></td>
<td style="text-align:left;font-size:10;width:30px"> of <span class="topage"/></td>
</tr>
</table>
</body>
</html>]]></field>
<field name="orientation">Landscape</field>
<field name="format">A4</field>
<field name="html"><![CDATA[
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="content-type"/>
<script>
function subst() {
var vars={};
var x=document.location.search.substring(1).split('&');
for(var i in x) {var z=x[i].split('=',2);vars[z[0]] = unescape(z[1]);}
var x=['frompage','topage','page','webpage','section','subsection','subsubsection'];
for(var i in x) {
var y = document.getElementsByClassName(x[i]);
for(var j=0; j<y.length; ++j) y[j].textContent = vars[x[i]];
}
}
</script>
<style type="text/css">
${css}
</style>
</head>
<body style="border:0; margin: 0;" onload="subst()">
<table class="header" style="border-bottom: 0px solid black; width: 100%">
<tr>
<td><h1>${_("Attendances Analysis")} - ${objects[0].company_id.partner_id.name | entity}</h1></td>
</tr>
</table> ${_debug or ''|n}
</body>
</html>]]>
</field>
<field name="css"><![CDATA[
body, table, td, span, div {
font-family: Helvetica, Arial;
}
]]>
</field>
<field eval="20" name="margin_top"/>
<field name="name">Attendances Landscape Header</field>
</record>
<record id="attendance_analysis_report_id" model="ir.actions.report.xml">
<field name="name">Attendances Analysis</field>
<field name="type">ir.actions.report.xml</field>
<field name="model">hr.employee</field>
<field name="report_name">attendance_analysis.calendar_report</field>
<field name="report_rml">hr_attendance_analysis/report/calendar_report.mako</field>
<field name="report_type">webkit</field>
<field name="webkit_header" ref="attendances_landscape_header"/>
</record>
</data>
</openerp>