[FIX] hr_timesheet: buttons aren't aligned correctly

Since the merge of Bootstrap 5, the `btn-block` class don't exist
anymore. So we use grid instead to align the buttons.

Steps to reproduce:
* Go to field service
* Create a field service task
* Click on worksheet
* Go back to the task
* Click on sign report
* The buttons are not correctly aligned => BUG

closes odoo/odoo#102714

X-original-commit: af053ab9e21ef86e31c9a27b404658c864df1446
Related: odoo/enterprise#32540
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
Signed-off-by: Romeo Fragomeli (rfr) <rfr@odoo.com>
This commit is contained in:
Romeo Fragomeli
2022-10-10 14:04:49 +02:00
parent ba4b71427f
commit 170a98d458
@@ -3,14 +3,10 @@
<template id="portal_my_task" inherit_id="project.portal_my_task" name="Portal: My Task with Timesheets">
<xpath expr="//li[@id='task-nav']" position="before">
<li t-if="timesheets and allow_timesheets" class="list-group-item flex-grow-1 d-flex flex-wrap justify-content-center align-items-center" id='nav-report'>
<div class="o_download_pdf btn-toolbar flex-sm-nowrap">
<div class="btn-group flex-grow-1 me-1">
<a class="btn btn-secondary btn-block o_download_btn" t-att-href="task.get_portal_url(report_type='pdf', download=True)" title="Download"><i class="fa fa-download"/> Download</a>
</div>
<div class="btn-group flex-grow-1">
<a class="btn btn-secondary btn-block o_print_btn o_project_timesheet_print" t-att-href="task.get_portal_url(report_type='pdf')" href="#" title="Print" target="_blank"><i class="fa fa-print"/> Print</a>
</div>
<li t-if="timesheets and allow_timesheets" class="list-group-item d-grid flex-grow-1" id='nav-report'>
<div class="o_download_pdf d-flex gap-1 align-items-center">
<a class="btn btn-secondary flex-fill o_download_btn" t-att-href="task.get_portal_url(report_type='pdf', download=True)" title="Download"><i class="fa fa-download"/> Download</a>
<a class="btn btn-secondary flex-fill o_print_btn o_project_timesheet_print" t-att-href="task.get_portal_url(report_type='pdf')" href="#" title="Print" target="_blank"><i class="fa fa-print"/> Print</a>
</div>
</li>
</xpath>