blob: 237ffba9e91f9b714dd50e2ca0e2b674fbbe2468 (
plain)
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
|
<?xml version="1.0" encoding="UTF-8"?>
<templates id="template" xml:space="preserve">
<t t-name="hr_holidays.leave_per_type">
<table class="o_group o_inner_group table-striped">
<thead>
<tr>
<td colspan="2">
<div class="o_horizontal_separator"><t t-esc="widget.employee.data.display_name"/> in <t t-esc="widget.date.format('YYYY')"/></div>
</td>
</tr>
</thead>
<tbody>
<t t-if="widget.leavesPerType.length === 0">
<tr>
<td>None</td>
</tr>
</t>
<t t-foreach="widget.leavesPerType" t-as="leave_type">
<tr>
<td><t t-esc="leave_type.holiday_status_id[1]"/></td>
<td class="w-50"><t t-esc="leave_type.number_of_days"/> day(s)</td>
</tr>
</t>
</tbody>
</table>
</t>
<t t-name="hr_holidays.department_leave">
<table class="o_group o_inner_group table-striped">
<thead>
<tr>
<td colspan="2">
<div class="o_horizontal_separator"><t t-esc="widget.department.data.display_name"/> in <t t-esc="widget.date.format('MMMM')"/></div>
</td>
</tr>
</thead>
<tbody>
<t t-if="widget.departmentLeaves.length === 0">
<tr>
<td>None</td>
</tr>
</t>
<t t-foreach="widget.departmentLeaves" t-as="leave">
<tr t-attf-class="{{leave.employee_id[0] === widget.employee.res_id ? 'font-weight-bold' : ''}}">
<td><t t-esc="leave.employee_id[1]"/>: <t t-esc="leave.number_of_days"/> day(s) </td>
<td class="w-50"><t t-esc="leave.date_from"/> - <t t-esc="leave.date_to"/></td>
</tr>
</t>
</tbody>
</table>
</t>
<div t-name="hr_holidays.leave_stats" class="o_leave_stats">
<t t-if="widget.employee">
<t t-if="widget.leavesPerType">
<t t-call="hr_holidays.leave_per_type"/>
</t>
<t t-if="widget.departmentLeaves">
<t t-call="hr_holidays.department_leave"/>
</t>
</t>
</div>
</templates>
|