Merge PR #506 into 17.0

Signed-off-by pedrobaeza
This commit is contained in:
OCA-git-bot 2024-11-14 18:24:21 +00:00
commit 75177d37a9
2 changed files with 5 additions and 6 deletions

View File

@ -52,6 +52,11 @@ patch(AttachmentList.prototype, {
*
* @returns {String}
*/
canDownload(attachment) {
return (
super.canDownload(attachment) && attachment.mimetype != "application/link"
);
},
get attachmentUrl() {
return url("/web/content", {
id: this.attachment.id,

View File

@ -30,12 +30,6 @@
</xpath>
</t>
<t t-inherit="mail.AttachmentList" t-inherit-mode="extension">
<xpath
expr="//div[contains(@class, 'o-mail-AttachmentCard-aside')]//button[@title='Download']"
position="attributes"
>
<attribute name="t-if">attachment.mimetype != 'application/link'</attribute>
</xpath>
<xpath
expr="//div[hasclass('o-mail-AttachmentCard-aside')]//button[@title='Download']"
position="after"