Skip to content

Conversation

@xaviedoanhduy
Copy link

depend on: #446

Note: this is a technical module so it is quite difficult to test the functionality on the UI. so I encourage everyone to follow the steps I tested below to create records in Fs Image Thumbnails:

$ ./odoo.sh shell

>>>import base64

>>>from odoo.addons.fs_image.fields import FSImageValue

>>>attachment = self.env['ir.attachment'].create({
...     'name': 'test',
...     'datas': base64.b64encode(open('/home/trobz/Pictures/my/Heart-shaped-glasses.jpeg', 'rb').read()),
... })
>>>image_value = FSImageValue(attachment)

>>>thumbnails = self.env['fs.thumbnail'].get_or_create_thumbnails(image_value, sizes=[(800,600), (400, 200)], base_name='my')

>>>env.cr.commit()
  1. check in: menu Settings >> Technical >> Database Structure >> Attachments

image
image
image
image

  1. check in: menu Settings >> Technical >> FS Storage >> Fs Thumbnail

image

@lmignon
Copy link
Contributor

lmignon commented Sep 14, 2025

/ocabot migration fs_image_thumbnail

@OCA-git-bot OCA-git-bot added this to the 18.0 milestone Sep 14, 2025
@kobros-tech
Copy link
Contributor

@xaviedoanhduy

There is a conflict!

@xaviedoanhduy xaviedoanhduy force-pushed the 18.0-mig-fs_image_thumbnail branch from 66e77dc to c02db79 Compare September 17, 2025 02:23
lmignon and others added 17 commits September 17, 2025 09:25
Currently translated at 100.0% (27 of 27 strings)

Translation: storage-16.0/storage-16.0-fs_image_thumbnail
Translate-URL: https://translation.odoo-community.org/projects/storage-16-0/storage-16-0-fs_image_thumbnail/es/
Currently translated at 100.0% (27 of 27 strings)

Translation: storage-16.0/storage-16.0-fs_image_thumbnail
Translate-URL: https://translation.odoo-community.org/projects/storage-16-0/storage-16-0-fs_image_thumbnail/it/
Currently translated at 100.0% (27 of 27 strings)

Translation: storage-16.0/storage-16.0-fs_image_thumbnail
Translate-URL: https://translation.odoo-community.org/projects/storage-16-0/storage-16-0-fs_image_thumbnail/it/
@xaviedoanhduy xaviedoanhduy force-pushed the 18.0-mig-fs_image_thumbnail branch from c02db79 to 2af0b99 Compare September 17, 2025 02:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants