[IMP] hr_expense: attachment expense sheet

The goal of this pr is to remove the name of the file on the expense report.

closes odoo/odoo#141226

Task: 3473105
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
This commit is contained in:
Maximilien (malb)
2023-11-06 15:36:58 +00:00
parent c0dc12f464
commit d6bd6d5eec
@@ -6,7 +6,7 @@ import { AttachmentView } from "@mail/core/common/attachment_view";
patch(AttachmentView.prototype, {
get displayName() {
if (this.state.thread.model === 'hr.expense.sheet') {
return (this.state.thread.mainAttachment.res_name || this.state.thread.name) + ' - ' + this.state.thread.mainAttachment.filename;
return (this.state.thread.mainAttachment.res_name || this.state.thread.name);
}
return super.displayName;
}