This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| l = [] | |
| for m in env['ir.model'].search([]): | |
| m._in_modules() | |
| if m.modules is '': | |
| l.append(m.id) | |
| #query = ("delete from ir_model_fields where model_id in (%s)" % ','.join(map(str, l))) | |
| #env.cr.execute(query) | |
| #env.cr.commit() | |
| #query = ("delete from ir_model where id in (%s)" % ','.join(map(str, l))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # In case you find the following error, the scripts might be useful : | |
| # "The %(date_field)s (%(date)s) doesn't match the %(sequence_field)s (%(sequence)s).\n" | |
| # "You might want to clear the field %(sequence_field)s before proceeding with the change of the date.", | |
| # The sequence mixin (addons/account/models/sequence_mixin.py) contains a new method, _constrains_date_sequence. | |
| # That method checks that the date in the sequence is aligned with | |
| # the date of the model (INV/2020/12/0001 for a date of 25/12/2020) | |
| # This is a new constraints, and this can cause some problems for users that where using another format. | |
| # Since v14, for account.move and other models, the sequence is defaulted in the code | |
| # (on the format <JOURNAL_CODE>/YYYY/MONTH/NUMBER for accounting). |