mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
opt customize
This commit is contained in:
@@ -23,7 +23,7 @@
|
||||
|
||||
{
|
||||
'name': 'Odoo Customize(Debranding, My Odoo)',
|
||||
'version': '12.19.04.22',
|
||||
'version': '12.19.04.30',
|
||||
'author': 'Sunpop.cn',
|
||||
'category': 'Productivity',
|
||||
'website': 'https://www.sunpop.cn',
|
||||
@@ -66,6 +66,7 @@
|
||||
23. Add reset or clear website blog data
|
||||
24. Customize Odoo Native Module(eg. Enterprise) Url
|
||||
25. Add remove expense data
|
||||
26. Add multi uninstall modules
|
||||
|
||||
This module can help to white label the Odoo.
|
||||
Also helpful for training and support for your odoo end-user.
|
||||
@@ -83,9 +84,10 @@
|
||||
# 'web_mobile'
|
||||
],
|
||||
'data': [
|
||||
'views/app_odoo_customize_view.xml',
|
||||
'views/app_theme_config_settings_view.xml',
|
||||
'views/ir_model_view.xml',
|
||||
'views/app_odoo_customize_views.xml',
|
||||
'views/app_theme_config_settings_views.xml',
|
||||
'views/ir_model_views.xml',
|
||||
'views/ir_views.xml',
|
||||
# data
|
||||
'data/ir_config_parameter.xml',
|
||||
'data/ir_module_module.xml',
|
||||
|
||||
@@ -3,4 +3,5 @@
|
||||
from . import res_config_settings
|
||||
from . import ir_ui_view
|
||||
from . import base_language_install
|
||||
from . import models
|
||||
# from . import mail_thread
|
||||
|
||||
17
app_odoo_customize/models/models.py
Normal file
17
app_odoo_customize/models/models.py
Normal file
@@ -0,0 +1,17 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import models, fields, api
|
||||
|
||||
|
||||
class Module(models.Model):
|
||||
_inherit = 'ir.module.module'
|
||||
|
||||
@api.multi
|
||||
def module_multi_uninstall(self):
|
||||
""" Perform the various steps required to uninstall a module completely
|
||||
including the deletion of all database structures created by the module:
|
||||
tables, columns, constraints, etc.
|
||||
"""
|
||||
modules = self.browse(self.env.context.get('active_ids'))
|
||||
[module.button_immediate_uninstall() for module in modules if module not in ['base', 'web']]
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 217 KiB After Width: | Height: | Size: 215 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 124 KiB After Width: | Height: | Size: 128 KiB |
@@ -29,6 +29,8 @@
|
||||
<p>This moduld allows user to quickly customize and debranding Odoo. Quick debug, Language Switcher,
|
||||
Online Documentation Access,Quick Data Clear. </p>
|
||||
<p class="mb16">Support Odoo 12, 11, 10, 9. Including communicate and enterprise version. </p>
|
||||
<h3>Update: v12.19.04.30</h3>
|
||||
<p>26. Add multi uninstall modules</p>
|
||||
<h3>Update: v12.19.04.18</h3>
|
||||
<p>25. Add remove expense data</p>
|
||||
<h3>Update: v12.19.04.17</h3>
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<odoo>
|
||||
<!-- Modules -->
|
||||
<record id="app_module_tree" model="ir.ui.view">
|
||||
<field name="name">app.ir.module.module.form</field>
|
||||
<field name="name">app.ir.module.module.tree</field>
|
||||
<field name="model">ir.module.module</field>
|
||||
<field name="inherit_id" ref="base.module_tree" />
|
||||
<field name="arch" type="xml">
|
||||
16
app_odoo_customize/views/ir_views.xml
Normal file
16
app_odoo_customize/views/ir_views.xml
Normal file
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<odoo>
|
||||
<data>
|
||||
<record id="action_server_module_multi_uninstall" model="ir.actions.server">
|
||||
<field name="name">Uninstall Modules</field>
|
||||
<field name="type">ir.actions.server</field>
|
||||
<field name="binding_model_id" ref="base.model_ir_module_module" />
|
||||
<field name="model_id" ref="base.model_ir_module_module" />
|
||||
<field name="state">code</field>
|
||||
<field name="code">
|
||||
if records:
|
||||
records.module_multi_uninstall()
|
||||
</field>
|
||||
</record>
|
||||
</data>
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user