mirror of
https://github.com/odoo/design-themes.git
synced 2025-10-07 01:18:52 +07:00
[IMP] orm/all: Make _name or _inherit mandatory
This is a request following the revert of the use of class names
(concerning the python inheritance and typing project)
closes odoo/design-themes#1040
X-original-commit: 2263661435
Related: odoo/odoo#191963
Related: odoo/enterprise#76269
Signed-off-by: Raphael Collet <rco@odoo.com>
This commit is contained in:
@@ -5,7 +5,7 @@ from odoo.http import request
|
|||||||
|
|
||||||
|
|
||||||
class IrHttp(models.AbstractModel):
|
class IrHttp(models.AbstractModel):
|
||||||
_inherit = ['ir.http']
|
_inherit = 'ir.http'
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def _pre_dispatch(cls, rule, args):
|
def _pre_dispatch(cls, rule, args):
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ from odoo import api, models
|
|||||||
|
|
||||||
|
|
||||||
class Website(models.Model):
|
class Website(models.Model):
|
||||||
_inherit = ['website']
|
_inherit = 'website'
|
||||||
|
|
||||||
@api.model
|
@api.model
|
||||||
def get_test_themes_websites_theme_preview(self):
|
def get_test_themes_websites_theme_preview(self):
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_anelusia_post_copy(self, mod):
|
def _theme_anelusia_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_headline')
|
self.enable_view('website.template_footer_headline')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_artists_post_copy(self, mod):
|
def _theme_artists_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_vertical')
|
self.enable_view('website.template_header_vertical')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_avantgarde_post_copy(self, mod):
|
def _theme_avantgarde_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_hamburger')
|
self.enable_view('website.template_header_hamburger')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_aviato_post_copy(self, mod):
|
def _theme_aviato_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_contact')
|
self.enable_view('website.template_footer_contact')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_beauty_post_copy(self, mod):
|
def _theme_beauty_post_copy(self, mod):
|
||||||
self.enable_view('website.footer_custom')
|
self.enable_view('website.footer_custom')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_bewise_post_copy(self, mod):
|
def _theme_bewise_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_headline')
|
self.enable_view('website.template_footer_headline')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_bistro_post_copy(self, mod):
|
def _theme_bistro_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_vertical')
|
self.enable_view('website.template_header_vertical')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_bookstore_post_copy(self, mod):
|
def _theme_bookstore_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_search')
|
self.enable_view('website.template_header_search')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_buzzy_post_copy(self, mod):
|
def _theme_buzzy_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_headline')
|
self.enable_view('website.template_footer_headline')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_clean_post_copy(self, mod):
|
def _theme_clean_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_default')
|
self.enable_view('website.template_header_default')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_cobalt_post_copy(self, mod):
|
def _theme_cobalt_post_copy(self, mod):
|
||||||
self.enable_asset("website.ripple_effect_scss")
|
self.enable_asset("website.ripple_effect_scss")
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_common_post_copy(self, mod):
|
def _theme_common_post_copy(self, mod):
|
||||||
# Reset all default color when switching themes
|
# Reset all default color when switching themes
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_enark_post_copy(self, mod):
|
def _theme_enark_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_descriptive')
|
self.enable_view('website.template_footer_descriptive')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_graphene_post_copy(self, mod):
|
def _theme_graphene_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_stretch')
|
self.enable_view('website.template_header_stretch')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_kea_post_copy(self, mod):
|
def _theme_kea_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_minimalist')
|
self.enable_view('website.template_footer_minimalist')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_kiddo_post_copy(self, mod):
|
def _theme_kiddo_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_default_align_right')
|
self.enable_view('website.template_header_default_align_right')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_loftspace_post_copy(self, mod):
|
def _theme_loftspace_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_search')
|
self.enable_view('website.template_header_search')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_monglia_post_copy(self, mod):
|
def _theme_monglia_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_minimalist')
|
self.enable_view('website.template_footer_minimalist')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_nano_post_copy(self, mod):
|
def _theme_nano_post_copy(self, mod):
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_notes_post_copy(self, mod):
|
def _theme_notes_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_descriptive')
|
self.enable_view('website.template_footer_descriptive')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_odoo_experts_post_copy(self, mod):
|
def _theme_odoo_experts_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_contact')
|
self.enable_view('website.template_footer_contact')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_orchid_post_copy(self, mod):
|
def _theme_orchid_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_default')
|
self.enable_view('website.template_header_default')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_paptic_post_copy(self, mod):
|
def _theme_paptic_post_copy(self, mod):
|
||||||
self.enable_asset("website.ripple_effect_scss")
|
self.enable_asset("website.ripple_effect_scss")
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_real_estate_post_copy(self, mod):
|
def _theme_real_estate_post_copy(self, mod):
|
||||||
self.enable_asset("website.ripple_effect_scss")
|
self.enable_asset("website.ripple_effect_scss")
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def _header_templates(self):
|
def _header_templates(self):
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_treehouse_post_copy(self, mod):
|
def _theme_treehouse_post_copy(self, mod):
|
||||||
self.disable_view('website.header_visibility_standard')
|
self.disable_view('website.header_visibility_standard')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_vehicle_post_copy(self, mod):
|
def _theme_vehicle_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_minimalist')
|
self.enable_view('website.template_footer_minimalist')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_yes_post_copy(self, mod):
|
def _theme_yes_post_copy(self, mod):
|
||||||
self.enable_view('website.template_footer_descriptive')
|
self.enable_view('website.template_footer_descriptive')
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ from odoo import models
|
|||||||
|
|
||||||
|
|
||||||
class ThemeUtils(models.AbstractModel):
|
class ThemeUtils(models.AbstractModel):
|
||||||
_inherit = ['theme.utils']
|
_inherit = 'theme.utils'
|
||||||
|
|
||||||
def _theme_zap_post_copy(self, mod):
|
def _theme_zap_post_copy(self, mod):
|
||||||
self.enable_view('website.template_header_sales_four')
|
self.enable_view('website.template_header_sales_four')
|
||||||
|
|||||||
Reference in New Issue
Block a user