odoo/openerp/addons/base/res/res_users_view.xml

317 lines
17 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<!-- change password wizard -->
<record id="change_password_wizard_view" model="ir.ui.view">
<field name="name">Change Password</field>
<field name="model">change.password.wizard</field>
<field name="arch" type="xml">
<form string="Change Password">
<field name="user_ids"/>
<footer>
<button string="Change Password" name="change_password_button" type="object" class="oe_highlight"/>
or
<button string="Cancel" class="oe_link" special="cancel" />
</footer>
</form>
</field>
</record>
<record id="change_password_wizard_user_tree_view" model="ir.ui.view">
<field name="name">Change Password Users</field>
<field name="model">change.password.user</field>
<field name="arch" type="xml">
<!-- the user list is editable, but one cannot add or delete rows -->
<tree string="Users" editable="bottom" create="false" delete="false">
<field name="user_login"/>
<field name="new_passwd" required="True" password="True"/>
</tree>
</field>
</record>
<act_window id="change_password_wizard_action"
name="Change Password"
src_model="res.users"
res_model="change.password.wizard"
view_type="form" view_mode="form"
key2="client_action_multi" target="new"
groups="base.group_erp_manager"/>
<!-- res.groups -->
<record id="view_groups_search" model="ir.ui.view">
<field name="name">res.groups.search</field>
<field name="model">res.groups</field>
<field name="arch" type="xml">
<search string="Groups">
<field name="name" filter_domain="['|', ('name','ilike',self), ('category_id','ilike',self)]" string="Group"/>
</search>
</field>
</record>
<record id="view_groups_form" model="ir.ui.view">
<field name="name">res.groups.form</field>
<field name="model">res.groups</field>
<field name="arch" type="xml">
<form string="Groups">
<sheet>
<group col="4">
<field name="category_id"/>
<field name="name"/>
</group>
<notebook>
<page string="Users">
<field name="users"/>
</page>
<page string="Inherited">
<label string="Users added to this group are automatically added in the following groups."/>
<field name="implied_ids"/>
</page>
<page string="Menus">
<field name="menu_access"/>
</page>
<page string="Views">
<field name="view_access"/>
</page>
<page string="Access Rights">
<field name="model_access">
<tree string="Access Rules" editable="top">
<field name="model_id"/>
<field name="perm_read"/>
<field name="perm_write"/>
<field name="perm_create"/>
<field name="perm_unlink"/>
<field name="name"/>
</tree>
<form string="Access Controls">
<group col="4">
<field name="name"/>
<field name="active"/>
<field name="model_id"/>
<newline/>
<field name="perm_read"/>
<field name="perm_write"/>
<field name="perm_create"/>
<field name="perm_unlink"/>
</group>
</form>
</field>
</page>
<page string="Rules">
<field name="rule_groups">
<tree string="Rules">
<field name="name"/>
<field name="model_id"/>
<field name="global"/>
</tree>
</field>
</page><page string="Notes">
<field name="comment"/>
</page>
</notebook>
</sheet>
</form>
</field>
</record>
<record id="action_res_groups" model="ir.actions.act_window">
<field name="name">Groups</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">res.groups</field>
<field name="view_type">form</field>
<field name="help">A group is a set of functional areas that will be assigned to the user in order to give them access and rights to specific applications and tasks in the system. You can create custom groups or edit the ones existing by default in order to customize the view of the menu that users will be able to see. Whether they can have a read, write, create and delete access right can be managed from here.</field>
</record>
<menuitem action="action_res_groups" id="menu_action_res_groups" parent="base.menu_users" groups="base.group_no_one"/>
<!-- res.users -->
<record id="view_users_simple_form" model="ir.ui.view">
<field name="name">res.users.simplified.form</field>
<field name="model">res.users</field>
<field name="priority">1</field>
<field name="arch" type="xml">
<form string="Users">
<sheet>
<field name="id" invisible="1"/>
<div class="oe_form_box_info oe_text_center" style="margin-bottom: 10px" attrs="{'invisible': [('id', '>', 0)]}">
You are creating a new user. After saving, the user will receive an invite email containing a link to set its password.
</div>
<field name="image" widget='image' class="oe_avatar oe_left" options='{"preview_image": "image_medium"}'/>
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1><field name="name"/></h1>
<field name="email" invisible="1"/>
<label for="login" class="oe_edit_only" string="Email Address"/>
<h2>
<field name="login" on_change="on_change_login(login)"
placeholder="email@yourcompany.com"/>
</h2>
<label for="company_id" class="oe_edit_only" groups="base.group_multi_company"/>
<field name="company_id" context="{'user_preference': 0}" groups="base.group_multi_company"/>
</div>
<group>
<label for="groups_id" string="Access Rights"
attrs="{'invisible': [('id', '>', 0)]}"/>
<div attrs="{'invisible': [('id', '>', 0)]}">
<field name="groups_id" readonly="1" widget="many2many_tags" style="display: inline;"/> You will be able to define additional access rights by editing the newly created user under the Settings / Users menu.
</div>
<field name="phone"/>
<field name="mobile"/>
<field name="fax"/>
</group>
</sheet>
</form>
</field>
</record>
<record id="view_users_form" model="ir.ui.view">
<field name="name">res.users.form</field>
<field name="model">res.users</field>
<field name="arch" type="xml">
<form string="Users">
<sheet>
<field name="id" invisible="1"/>
<div class="oe_right oe_button_box">
<button string="Change Password" type="action" name="%(change_password_wizard_action)d"
class="oe_link" help="Change the user password."/>
</div>
<field name="image" widget='image' class="oe_avatar oe_left" options='{"preview_image": "image_medium"}'/>
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1><field name="name"/></h1>
<field name="email" invisible="1"/>
<label for="login" class="oe_edit_only" string="Email Address"/>
<h2><field name="login" on_change="on_change_login(login)"/></h2>
<label for="company_id" class="oe_edit_only" groups="base.group_multi_company"/>
<field name="company_id" context="{'user_preference': 0}" groups="base.group_multi_company"/>
<group>
<field name="partner_id" readonly="1" required="0" groups="base.group_no_one"
attrs="{'invisible': [('id', '=', False)]}"/>
<field name="active"/>
</group>
</div>
<notebook colspan="4">
<page string="Access Rights">
<group string="Allowed Companies" groups="base.group_multi_company">
<field name="company_ids" nolabel="1" widget="many2many_tags"/>
</group>
<group col="4">
<field name="groups_id"/>
</group>
</page>
<page string="Preferences">
<group>
<group string="Localization" name="preferences">
<field name="lang"/>
<field name="tz"/>
</group>
<group string="Menus Customization" groups="base.group_no_one">
<field name="action_id"/>
</group>
</group>
<group string="Messaging and Social" name="messaging">
<field name="signature"/>
</group>
</page>
</notebook>
</sheet>
</form>
</field>
</record>
<record id="view_users_tree" model="ir.ui.view">
<field name="name">res.users.tree</field>
<field name="model">res.users</field>
<field name="arch" type="xml">
<tree string="Users">
<field name="name"/>
<field name="login"/>
<field name="lang"/>
<field name="login_date"/>
</tree>
</field>
</record>
<record id="view_users_search" model="ir.ui.view">
<field name="name">res.users.search</field>
<field name="model">res.users</field>
<field name="arch" type="xml">
<search string="Users">
<field name="name" filter_domain="['|', '|', ('name','ilike',self), ('login','ilike',self), ('email','ilike',self)]" string="User"/>
<field name="company_ids" string="Company" groups="base.group_multi_company"/>
</search>
</field>
</record>
<record id="user_groups_view" model="ir.ui.view">
<field name="name">res.users.groups</field>
<field name="model">res.users</field>
<field name="inherit_id" ref="view_users_form"/>
<field name="arch" type="xml">
<!-- dummy, will be modified by groups -->
<field name="groups_id" position="after"/>
</field>
</record>
<record id="action_res_users" model="ir.actions.act_window">
<field name="name">Users</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">res.users</field>
<field name="view_type">form</field>
<field name="view_id" ref="view_users_tree"/>
<field name="search_view_id" ref="view_users_search"/>
<field name="help">Create and manage users that will connect to the system. Users can be deactivated should there be a period of time during which they will/should not connect to the system. You can assign them groups in order to give them specific access to the applications they need to use in the system.</field>
</record>
<record id="action_res_users_view1" model="ir.actions.act_window.view">
<field eval="10" name="sequence"/>
<field name="view_mode">tree</field>
<field name="view_id" ref="view_users_tree"/>
<field name="act_window_id" ref="action_res_users"/>
</record>
<record id="action_res_users_view2" model="ir.actions.act_window.view">
<field eval="20" name="sequence"/>
<field name="view_mode">form</field>
<field name="view_id" ref="view_users_form"/>
<field name="act_window_id" ref="action_res_users"/>
</record>
<menuitem action="action_res_users" id="menu_action_res_users" parent="base.menu_users"/>
<record id="view_users_form_simple_modif" model="ir.ui.view">
<field name="name">res.users.preferences.form</field>
<field name="model">res.users</field>
<field eval="18" name="priority"/>
<field name="arch" type="xml">
<form string="Users">
<field name="image" readonly="0" widget='image' class="oe_right oe_avatar" options='{"preview_image": "image_small"}'/>
<h1>
<field name="name" readonly="1" class="oe_inline"/>
</h1>
<button name="preference_change_password" type="object" string="Change password" class="oe_link"/>
<group name="preferences" col="4">
<field name="lang" readonly="0"/>
<field name="tz" readonly="0"/>
<field name="company_id" options="{'no_create': True}" readonly="0"
groups="base.group_multi_company"/>
</group>
<group string="Email Preferences">
<field name="email" widget="email" readonly="0"/>
<field name="signature" readonly="0"/>
</group>
<footer>
<button name="preference_save" type="object" string="Save" class="oe_highlight"/>
or
<button name="preference_cancel" string="Cancel" special="cancel" class="oe_link"/>
</footer>
</form>
</field>
</record>
<record id="action_res_users_my" model="ir.actions.act_window">
<field name="name">Change My Preferences</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">res.users</field>
<field name="target">new</field>
<field name="view_type">form</field>
<field name="view_mode">form</field>
</record>
<record id="action_res_users_my_view2" model="ir.actions.act_window.view">
<field eval="10" name="sequence"/>
<field name="view_mode">form</field>
<field name="view_id" ref="view_users_form_simple_modif"/>
<field name="act_window_id" ref="action_res_users_my"/>
</record>
</data>
</openerp>