mirror of
https://github.com/bringout/oca-ocb-sale.git
synced 2026-04-27 23:32:00 +02:00
19.0 vanilla
This commit is contained in:
parent
79f83631d5
commit
73afc09215
6267 changed files with 1534193 additions and 1130106 deletions
|
|
@ -0,0 +1,32 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<template id="portal_timesheet_table_inherit" inherit_id="hr_timesheet.portal_timesheet_table">
|
||||
<th name="t_label" position="before">
|
||||
<t t-set="display_sol" t-value="False"/>
|
||||
<t t-foreach="timesheets" t-as="timesheet">
|
||||
<t t-if="timesheet.so_line != task.sale_line_id">
|
||||
<t t-set="display_sol" t-value="True"/>
|
||||
</t>
|
||||
</t>
|
||||
<th t-if="display_sol">Sales Order Item</th>
|
||||
</th>
|
||||
<xpath expr="//tr/td[t[@t-esc='timesheet.name']]" position="after">
|
||||
<td t-if="display_sol">
|
||||
<t t-if="timesheet.so_line.order_id.access_url and so_accessible"><a t-att-href="'%s' % timesheet.so_line.order_id.access_url"><t t-out="timesheet.so_line.display_name"/></a></t>
|
||||
<t t-elif="timesheet.so_line.display_name" t-out="timesheet.so_line.display_name"></t>
|
||||
<span t-else="" class="text-muted">Non-billable</span>
|
||||
</td>
|
||||
</xpath>
|
||||
<xpath expr="//div[@name='allocated_time']" position="after">
|
||||
<tr t-if="task.allow_billable and task.sale_line_id and task.sale_line_id.remaining_hours_available" t-attf-class="{{task.remaining_hours_so < 0 and 'text-danger'}}">
|
||||
<td><strong>Time Remaining on SO: </strong></td>
|
||||
<td class="text-end">
|
||||
<span t-if="is_uom_day" t-esc="timesheets._convert_hours_to_days(task.remaining_hours_so)" t-options='{"widget": "timesheet_uom"}'/>
|
||||
<span t-else="" t-esc="task.remaining_hours_so" t-options='{"widget": "float_time"}'/>
|
||||
</td>
|
||||
</tr>
|
||||
</xpath>
|
||||
</template>
|
||||
|
||||
</odoo>
|
||||
Loading…
Add table
Add a link
Reference in a new issue