mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
prepare #I8NJ48 app_web_fullwidth优化全局设置 置顶
This commit is contained in:
@@ -42,7 +42,7 @@
|
|||||||
Easy config the chatter position to bottom or side or Responsive form every user.
|
Easy config the chatter position to bottom or side or Responsive form every user.
|
||||||
""",
|
""",
|
||||||
'depends': [
|
'depends': [
|
||||||
'web'
|
'app_odoo_customize'
|
||||||
],
|
],
|
||||||
'data': [
|
'data': [
|
||||||
'views/res_users_views.xml',
|
'views/res_users_views.xml',
|
||||||
|
|||||||
@@ -1,3 +1,5 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
from . import res_users
|
from . import res_users
|
||||||
|
from . import res_config_settings
|
||||||
|
|
||||||
|
|||||||
18
app_web_fullwidth/models/res_config_settings.py
Normal file
18
app_web_fullwidth/models/res_config_settings.py
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
|
import logging
|
||||||
|
|
||||||
|
from odoo import api, fields, models, _
|
||||||
|
from odoo.exceptions import UserError, ValidationError
|
||||||
|
|
||||||
|
_logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
|
class ResConfigSettings(models.TransientModel):
|
||||||
|
_inherit = 'res.config.settings'
|
||||||
|
|
||||||
|
default_chatter_position = fields.Selection([
|
||||||
|
("auto", "Responsive"),
|
||||||
|
("bottom", "Bottom"),
|
||||||
|
("sided", "Sided"),
|
||||||
|
], string='Default Chatter Position', default="bottom", default_model="res.users")
|
||||||
@@ -10,7 +10,7 @@ class ResUsers(models.Model):
|
|||||||
("auto", "Responsive"),
|
("auto", "Responsive"),
|
||||||
("bottom", "Bottom"),
|
("bottom", "Bottom"),
|
||||||
("sided", "Sided"),
|
("sided", "Sided"),
|
||||||
], default="auto",)
|
], string='Chatter Position', default="bottom")
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def SELF_READABLE_FIELDS(self):
|
def SELF_READABLE_FIELDS(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user