[FIX] hr_fleet: bring back Attachments on assignation log

The "Attachments" column was removed in odoo/odoo#76550, but it seems that it
is still needed after all.

closes odoo/odoo#83106

Taskid: 2741777
X-original-commit: 60e4057bc51f9879c756b6efdeb90368ca64b4cd
Signed-off-by: Arnaud Joset <arj@odoo.com>
Signed-off-by: Kevin Baptiste <kba@odoo.com>
This commit is contained in:
Kevin Baptiste
2022-01-20 16:08:22 +00:00
parent 65aab85da0
commit ef38588090
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ class Employee(models.Model):
"res_model": "fleet.vehicle.assignation.log",
"views": [[False, "tree"], [False, "form"]],
"domain": [("driver_employee_id", "in", self.ids)],
"context": dict(self._context, create=False),
"context": dict(self._context, default_driver_id=self.user_id.partner_id.id, default_driver_employee_id=self.id),
"name": "History Employee Cars",
}
@@ -18,6 +18,8 @@
<field name="arch" type="xml">
<xpath expr="//field[@name='driver_id']" position="after">
<field name="driver_employee_id" widget="many2one_avatar" optional="hide"/>
<field name="attachment_number" string=" "/>
<button name="action_get_attachment_view" string="Attachments" type="object" icon="fa-paperclip"/>
</xpath>
</field>
</record>