RemiFr82
5 months ago
4 changed files with 106 additions and 0 deletions
-
5user_portal_internal/__init__.py
-
53user_portal_internal/__manifest__.py
-
26user_portal_internal/i18n/fr.po
-
22user_portal_internal/views/res_users.xml
@ -0,0 +1,5 @@ |
|||
# -*- coding: utf-8 -*- |
|||
# from . import controllers |
|||
# from . import models |
|||
# from . import wizards |
|||
# from .hooks import pre_init_hook, post_init_hook, uninstall_hook |
@ -0,0 +1,53 @@ |
|||
# -*- coding: utf-8 -*- |
|||
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html). |
|||
{ |
|||
"name": "User Portal Internal", |
|||
"version": "1.0.0", |
|||
"summary": "Switch user between portal and internal - no dev mode", |
|||
"description": """ |
|||
Adds 2 secondary actions on the Users views for Access Rights users. |
|||
""", |
|||
"author": "RemiFr82", |
|||
"contributors": "", |
|||
"maintainer": "RemiFr82", |
|||
"website": "https://remifr82.me", |
|||
"license": "LGPL-3", |
|||
"category": "Technical", |
|||
# "price": 0, |
|||
# "currency": "EUR", |
|||
"application": False, |
|||
"installable": True, |
|||
"auto_install": False, |
|||
# "pre_init_hook": "", |
|||
# "post_init_hook": "", |
|||
# "uninstall_hook": "", |
|||
# "excludes": [], |
|||
# "external_dependencies": [], |
|||
"depends": [ |
|||
"base", |
|||
"portal", |
|||
], |
|||
"data": [ |
|||
# Base data |
|||
# "data/ir_model.xml", |
|||
# Security |
|||
# 'security/res_groups.xml', |
|||
# 'security/ir.model.access.csv', |
|||
# 'security/ir_rule.xml', |
|||
# Views |
|||
"views/res_users.xml", |
|||
# Wizards |
|||
# 'wizards/transient_model.xml', |
|||
# Reports |
|||
# 'reports/report_templates.xml', |
|||
# 'reports/sql_view.xml', |
|||
], |
|||
"assets": { |
|||
# "reports/report_assets.xml" |
|||
}, |
|||
"css": [], |
|||
"images": [], |
|||
"js": [], |
|||
"test": [], |
|||
"demo": [], |
|||
} |
@ -0,0 +1,26 @@ |
|||
# Translation of Odoo Server. |
|||
# This file contains the translation of the following modules: |
|||
# * user_portal_internal |
|||
# |
|||
msgid "" |
|||
msgstr "" |
|||
"Project-Id-Version: Odoo Server 16.0-20230613\n" |
|||
"Report-Msgid-Bugs-To: \n" |
|||
"POT-Creation-Date: 2024-07-30 17:17+0000\n" |
|||
"PO-Revision-Date: 2024-07-30 17:17+0000\n" |
|||
"Last-Translator: \n" |
|||
"Language-Team: \n" |
|||
"MIME-Version: 1.0\n" |
|||
"Content-Type: text/plain; charset=UTF-8\n" |
|||
"Content-Transfer-Encoding: \n" |
|||
"Plural-Forms: \n" |
|||
|
|||
#. module: user_portal_internal |
|||
#: model:ir.actions.server,name:user_portal_internal.user_to_internal_action_server |
|||
msgid "Set user to internal" |
|||
msgstr "Convertir en utilisateur interne" |
|||
|
|||
#. module: user_portal_internal |
|||
#: model:ir.actions.server,name:user_portal_internal.user_to_portal_action_server |
|||
msgid "Set user to portal" |
|||
msgstr "Convertir en utilisateur portail" |
@ -0,0 +1,22 @@ |
|||
<?xml version="1.0" encoding="utf-8"?> |
|||
<odoo> |
|||
|
|||
<record id="user_to_portal_action_server" model="ir.actions.server"> |
|||
<field name="name">Set user to portal</field> |
|||
<field name="model_id" ref="base.model_res_users" /> |
|||
<field name="binding_model_id" ref="base.model_res_users" /> |
|||
<field name="groups_id" eval="[(6, 0, [ref('base.group_erp_manager')])]" /> |
|||
<field name="state">code</field> |
|||
<field name="code">records.write({'groups_id': [(6, 0, [env.ref('base.group_portal').id])]})</field> |
|||
</record> |
|||
|
|||
<record id="user_to_internal_action_server" model="ir.actions.server"> |
|||
<field name="name">Set user to internal</field> |
|||
<field name="model_id" ref="base.model_res_users" /> |
|||
<field name="binding_model_id" ref="base.model_res_users" /> |
|||
<field name="groups_id" eval="[(6, 0, [ref('base.group_erp_manager')])]" /> |
|||
<field name="state">code</field> |
|||
<field name="code">records.write({'groups_id': [(6, 0, [env.ref('base.group_user').id])]})</field> |
|||
</record> |
|||
|
|||
</odoo> |
Write
Preview
Loading…
Cancel
Save
Reference in new issue