Friday, April 9, 2021
1 change · master
Resolved issues and error corrections
This fix ensures storage migration includes attachments linked to specific fields, not just general attachments. It helps prevent incomplete migrations and avoids applying the process to URL-only fields where file storage changes are not relevant.
Original PR description
Description of the issue/feature this PR addresses:
This change is necessary to migrate attachment which are assigned to a field. Otherwise the `_search `method would filter all of those attachments.
```python
if not any(arg[0] in ('id', 'res_field') for arg in args):
args.insert(0, ('res_field', '=', False))
```
Current behavior before PR:
Only attachment not related to a field will be migrated.
Desired behavior after PR is merged:
All attachments are migrated.
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr