Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c77500bfab | |||
| d63a269de2 |
@@ -26,6 +26,7 @@
|
||||
# views/hr_timesheet_portal.xml",
|
||||
"views/hr_timesheet_view_task_form2.xml",
|
||||
"views/portal_tasks_list.xml",
|
||||
"views/portal_my_task_with_subtasks.xml"
|
||||
],
|
||||
"assets": {
|
||||
"web.assets_frontend": [
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<template id="hr_timesheet_portal_timesheet_table_inherit"
|
||||
inherit_id="hr_timesheet.portal_timesheet_table">
|
||||
<xpath expr="//table[hasclass('o_portal_my_doc_table')]" position="after">
|
||||
<t t-foreach="task.child_ids" t-as="subtask">
|
||||
<t t-if="subtask.billable_effective_hours > 0">
|
||||
<a t-attf-href="/my/tasks/#{subtask.id}">
|
||||
<span t-att-title="subtask.name" t-field="subtask.name" />
|
||||
</a>
|
||||
|
||||
<t t-set="timesheets" t-value="subtask.timesheet_ids" />
|
||||
|
||||
<table class="o_portal_my_doc_table table table-sm table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Date</th>
|
||||
<th>Employee</th>
|
||||
<th>Description</th>
|
||||
<th class="text-end" name="t_label">Time Spent</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr t-foreach="timesheets" t-as="timesheet" valign="middle">
|
||||
<td>
|
||||
<t t-esc="timesheet.date" t-options='{"widget": "date"}' />
|
||||
</td>
|
||||
<td t-attf-title="#{timesheet.employee_id.name}">
|
||||
<t t-esc="timesheet.employee_id.name" />
|
||||
</td>
|
||||
<td>
|
||||
<t t-esc="timesheet.name" />
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-if="is_uom_day" t-esc="timesheet._get_timesheet_time_day()"
|
||||
t-options='{"widget": "timesheet_uom"}' />
|
||||
<span t-else="" t-field="timesheet.unit_amount"
|
||||
t-options='{"widget": "float_time"}' />
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</t>
|
||||
</t>
|
||||
</xpath>
|
||||
</template>
|
||||
|
||||
</odoo>
|
||||
|
||||
Reference in New Issue
Block a user