[IMP] base_import_module: add warning for demo data
task-3725221 closes odoo/odoo#154006 Signed-off-by: Pierre Masereel (pim) <pim@odoo.com>
This commit is contained in:
@@ -79,6 +79,13 @@ msgstr ""
|
||||
msgid "Created on"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_import_module
|
||||
#: model_terms:ir.ui.view,arch_db:base_import_module.view_base_module_import
|
||||
msgid ""
|
||||
"Demo data should only be used on test databases. Once they are loaded, they "
|
||||
"cannot be entirely removed!"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_import_module
|
||||
#: model:ir.model.fields,field_description:base_import_module.field_base_import_module__display_name
|
||||
msgid "Display Name"
|
||||
@@ -145,6 +152,13 @@ msgstr ""
|
||||
msgid "Install"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_import_module
|
||||
#. odoo-python
|
||||
#: code:addons/base_import_module/models/ir_module.py:0
|
||||
#, python-format
|
||||
msgid "Install an Industry"
|
||||
msgstr ""
|
||||
|
||||
#. module: base_import_module
|
||||
#: model_terms:ir.ui.view,arch_db:base_import_module.view_base_module_import
|
||||
msgid "Install the application"
|
||||
|
||||
@@ -402,7 +402,7 @@ class IrModule(models.Model):
|
||||
'modules_dependencies': missing_dependencies_description,
|
||||
})
|
||||
return {
|
||||
'name': 'Install an App',
|
||||
'name': _("Install an Industry"),
|
||||
'view_mode': 'form',
|
||||
'target': 'new',
|
||||
'res_id': import_module.id,
|
||||
|
||||
@@ -1,12 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<record id="view_base_module_import" model="ir.ui.view">
|
||||
<field name="name">base.import.module.form</field>
|
||||
<field name="model">base.import.module</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Install the application">
|
||||
<field name="state" invisible="1"/>
|
||||
<p class="alert alert-danger" role="alert" invisible="not with_demo or state == 'done'">
|
||||
Demo data should only be used on test databases. Once they are loaded, they cannot be entirely removed!
|
||||
</p>
|
||||
<p class="alert alert-warning" role="alert" invisible="state == 'done' or context.get('data_module')">Note: you can only import data modules (.xml files and static assets)</p>
|
||||
<field name="modules_dependencies" readonly="1" nolabel="1" invisible="state == 'done'"/>
|
||||
<group invisible="state != 'init'">
|
||||
|
||||
Reference in New Issue
Block a user