-
-
Notifications
You must be signed in to change notification settings - Fork 273
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] base_user_role_history - pylint
- Loading branch information
Showing
3 changed files
with
77 additions
and
76 deletions.
There are no files selected for viewing
17 changes: 7 additions & 10 deletions
17
base_user_role_history/security/base_user_role_line_history.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,14 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<!-- Copyright 2019 ACSONE SA/NV | ||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). --> | ||
|
||
<odoo> | ||
|
||
<record model="ir.model.access" id="base_user_role_line_history_access_name"> | ||
<field name="name">base.user.role.line.history access user</field> | ||
<field name="model_id" ref="model_base_user_role_line_history"/> | ||
<field name="group_id" ref="base.group_user"/> | ||
<field name="perm_read" eval="1"/> | ||
<field name="perm_create" eval="0"/> | ||
<field name="perm_write" eval="0"/> | ||
<field name="perm_unlink" eval="0"/> | ||
<field name="model_id" ref="model_base_user_role_line_history" /> | ||
<field name="group_id" ref="base.group_user" /> | ||
<field name="perm_read" eval="1" /> | ||
<field name="perm_create" eval="0" /> | ||
<field name="perm_write" eval="0" /> | ||
<field name="perm_unlink" eval="0" /> | ||
</record> | ||
|
||
</odoo> |
111 changes: 57 additions & 54 deletions
111
base_user_role_history/views/base_user_role_line_history.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,89 +1,92 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<!-- Copyright 2019 ACSONE SA/NV | ||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). --> | ||
|
||
<odoo> | ||
|
||
<!--FORM view--> | ||
|
||
<record model="ir.ui.view" id="base_user_role_line_history_form_view"> | ||
<field name="name">base.user.role.line.history.form (in base_user_role_history)</field> | ||
<field | ||
name="name" | ||
>base.user.role.line.history.form (in base_user_role_history)</field> | ||
<field name="model">base.user.role.line.history</field> | ||
<field name="arch" type="xml"> | ||
<form create="0" edit="0" delete="0"> | ||
<header> | ||
</header> | ||
<sheet> | ||
<group name="group_main" col="4"> | ||
<field name="create_uid" | ||
string="Editor"/> | ||
<field name="performed_action"/> | ||
<field name="user_id" | ||
string="Edited user"/> | ||
<field name="create_date" | ||
string="Date and time of edition"/> | ||
<field name="old_role_id"/> | ||
<field name="new_role_id"/> | ||
<field name="old_date_from"/> | ||
<field name="new_date_from"/> | ||
<field name="old_date_to"/> | ||
<field name="new_date_to"/> | ||
<field name="old_is_enabled"/> | ||
<field name="new_is_enabled"/> | ||
<field name="create_uid" string="Editor" /> | ||
<field name="performed_action" /> | ||
<field name="user_id" string="Edited user" /> | ||
<field name="create_date" string="Date and time of edition" /> | ||
<field name="old_role_id" /> | ||
<field name="new_role_id" /> | ||
<field name="old_date_from" /> | ||
<field name="new_date_from" /> | ||
<field name="old_date_to" /> | ||
<field name="new_date_to" /> | ||
<field name="old_is_enabled" /> | ||
<field name="new_is_enabled" /> | ||
</group> | ||
</sheet> | ||
</form> | ||
</field> | ||
</record> | ||
|
||
<!--TREE view--> | ||
|
||
<record model="ir.ui.view" id="base_user_role_line_history_tree_view"> | ||
<field name="name">base.user.role.line.history.tree (in base_user_role_history)</field> | ||
<field | ||
name="name" | ||
>base.user.role.line.history.tree (in base_user_role_history)</field> | ||
<field name="model">base.user.role.line.history</field> | ||
<field name="arch" type="xml"> | ||
<tree decoration-success="performed_action == 'add'" | ||
decoration-danger="performed_action == 'unlink'" | ||
create="0" edit="0" delete="0"> | ||
<field name="create_uid" | ||
string="Editor"/> | ||
<field name="create_date" | ||
string="Date and time of edition"/> | ||
<field name="performed_action"/> | ||
<field name="old_role_id"/> | ||
<field name="new_role_id"/> | ||
<field name="old_date_from"/> | ||
<field name="new_date_from"/> | ||
<field name="old_date_to"/> | ||
<field name="new_date_to"/> | ||
<field name="old_is_enabled"/> | ||
<field name="new_is_enabled"/> | ||
<tree | ||
decoration-success="performed_action == 'add'" | ||
decoration-danger="performed_action == 'unlink'" | ||
create="0" | ||
edit="0" | ||
delete="0" | ||
> | ||
<field name="create_uid" string="Editor" /> | ||
<field name="create_date" string="Date and time of edition" /> | ||
<field name="performed_action" /> | ||
<field name="old_role_id" /> | ||
<field name="new_role_id" /> | ||
<field name="old_date_from" /> | ||
<field name="new_date_from" /> | ||
<field name="old_date_to" /> | ||
<field name="new_date_to" /> | ||
<field name="old_is_enabled" /> | ||
<field name="new_is_enabled" /> | ||
</tree> | ||
</field> | ||
</record> | ||
|
||
<!--SEARCH view--> | ||
|
||
<record model="ir.ui.view" id="base_user_role_line_history_search_view"> | ||
<field name="name">base.user.role.line.history.search (in base_user_role_history)</field> | ||
<field | ||
name="name" | ||
>base.user.role.line.history.search (in base_user_role_history)</field> | ||
<field name="model">base.user.role.line.history</field> | ||
<field name="arch" type="xml"> | ||
<search> | ||
<field name="old_role_id"/> | ||
<field name="new_role_id"/> | ||
<field name="old_role_id" /> | ||
<field name="new_role_id" /> | ||
<group string="Group By" name="groupby"> | ||
<filter name="group_by_old_role" | ||
string="Old role" | ||
context="{'group_by': 'old_role_id'}"/> | ||
<filter name="group_by_new_role" | ||
string="New role" | ||
context="{'group_by': 'new_role_id'}"/> | ||
<filter name="group_by_performed_action" | ||
string="Action" | ||
context="{'group_by': 'performed_action'}"/> | ||
<filter | ||
name="group_by_old_role" | ||
string="Old role" | ||
context="{'group_by': 'old_role_id'}" | ||
/> | ||
<filter | ||
name="group_by_new_role" | ||
string="New role" | ||
context="{'group_by': 'new_role_id'}" | ||
/> | ||
<filter | ||
name="group_by_performed_action" | ||
string="Action" | ||
context="{'group_by': 'performed_action'}" | ||
/> | ||
</group> | ||
</search> | ||
</field> | ||
</record> | ||
|
||
</odoo> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,30 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<!-- Copyright 2019 ACSONE SA/NV | ||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). --> | ||
|
||
<odoo> | ||
|
||
<!--FORM view--> | ||
|
||
<record model="ir.ui.view" id="res_users_form_view"> | ||
<field name="name">res.users.form (in base_user_role_history)</field> | ||
<field name="model">res.users</field> | ||
<field name="inherit_id" ref="base.view_users_form"/> | ||
<field name="inherit_id" ref="base.view_users_form" /> | ||
<field name="arch" type="xml"> | ||
<div name="button_box" position="inside"> | ||
<button name="show_role_lines_history" | ||
help="Roles history" | ||
class="oe_stat_button" | ||
icon="fa-history" | ||
type="object"> | ||
<button | ||
name="show_role_lines_history" | ||
help="Roles history" | ||
class="oe_stat_button" | ||
icon="fa-history" | ||
type="object" | ||
> | ||
<div class="o_stat_info"> | ||
<span class="o_stat_text">Last update of roles</span> | ||
<field class="o_stat_value" name="last_role_line_modification"/> | ||
<field | ||
class="o_stat_value" | ||
name="last_role_line_modification" | ||
/> | ||
</div> | ||
</button> | ||
</div> | ||
</field> | ||
</record> | ||
|
||
</odoo> |