diff options
| author | Xavier Morel <xmo@odoo.com> | 2018-12-06 10:46:57 +0000 |
|---|---|---|
| committer | Xavier Morel <xmo@odoo.com> | 2018-12-07 13:37:34 +0000 |
| commit | 66f0e26f6f3f2155fcfcc55e84f2e76cbfdb2c1d (patch) | |
| tree | 7dbd4cbc827e8455eb4d8bd4013003b8069fc448 /addons/gamification | |
| parent | 299f9f1eb06f9df950df1dc02e368caa9b3a9871 (diff) | |
[CHG] *: make binary fields default to attachment=True
Check that it makes custom binary fields into attachment as that's the
main reason for the change: when users create binary fields via Studio,
they're necessarily db-stored (as the interface doesn't allow altering
the attachment attribute and it's unclear how we'd handle users
switching it on/off every time), which significantly bloats their
database (and burns storage & backup space), especially as the primary
use case for binary fields is adding images and documents to records.
* check that binary fields are properly created as attachment=True
* add attachment=False on fields where that seems relevant (most but not
all of the fields previously using the default)
* remove occurrences of attachment=True
closes odoo/odoo#29308
Diffstat (limited to 'addons/gamification')
| -rw-r--r-- | addons/gamification/models/badge.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/gamification/models/badge.py b/addons/gamification/models/badge.py index 6686b29fee5..cf750aaa5f2 100644 --- a/addons/gamification/models/badge.py +++ b/addons/gamification/models/badge.py @@ -66,7 +66,7 @@ class GamificationBadge(models.Model): name = fields.Char('Badge', required=True, translate=True) active = fields.Boolean('Active', default=True) description = fields.Text('Description', translate=True) - image = fields.Binary("Image", attachment=True, help="This field holds the image used for the badge, limited to 256x256") + image = fields.Binary("Image", help="This field holds the image used for the badge, limited to 256x256") rule_auth = fields.Selection([ ('everyone', 'Everyone'), |
