Improvement in Config Wizards

bzr revid: fp@tinyerp.com-20080824171028-ul98prnl13wl1y13
This commit is contained in:
Fabien Pinckaers 2008-08-24 19:10:28 +02:00
parent 082e6f9707
commit fdb4812d33
3 changed files with 45 additions and 52 deletions

View File

@ -2,10 +2,10 @@
<terp>
<data>
<!--
======================
Languages
======================
-->
======================
Languages
======================
-->
<record id="view_lang" model="ir.ui.view">
<field name="name">Languages</field>
<field name="model">res.lang</field>
@ -28,10 +28,10 @@
<menuitem id="next_id_2" name="Interface" parent="base.menu_custom"/><menuitem action="action_lang" id="menu_action_lang" parent="next_id_2"/>
<!--
======================
Groups
======================
-->
======================
Groups
======================
-->
<record id="view_groups_form" model="ir.ui.view">
<field name="name">res.groups.form</field>
<field name="model">res.groups</field>
@ -67,10 +67,10 @@
</record>
<!--
======================
Users
======================
-->
======================
Users
======================
-->
<record id="view_users_form_simple_modif" model="ir.ui.view">
<field name="name">res.users.form.modif</field>
<field name="model">res.users</field>
@ -129,10 +129,10 @@
</record>
<!--
======================
Company
======================
-->
======================
Company
======================
-->
<record id="view_company_form" model="ir.ui.view">
<field name="name">res.company.form</field>
<field name="model">res.company</field>
@ -174,35 +174,27 @@
</field>
</record>
<record id="view_users_configuration_form" model="ir.ui.view">
<field name="name">res.users.confirm.form</field>
<field name="model">res.users</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Configure User">
<notebook colspan="4">
<page string="User Definition">
<separator col="4" colspan="4" string="Define a New User"/>
<field name="name" select="1"/>
<newline/>
<field name="login" select="1"/>
<field name="password"/>
<field colspan="4" name="signature"/>
</page><page string="Access Rights">
<label string="Assign groups to set objects available for this user" colspan="4"/>
<field colspan="4" name="groups_id" nolabel="1"/>
</page>
</notebook>
<separator string="" colspan="4"/>
<label string="" colspan="2"/>
<group col="3" colspan="3">
<button icon='gtk-cancel' special="cancel" name="action_next" type='object' string='Skip &amp; Continue'/>
<button name='action_new' icon='gtk-ok' type='object' string='Add Another User'/>
<button name='action_continue' icon='gtk-ok' type='object' string='Continue'/>
</group>
<separator col="4" colspan="4" string="Define a New User"/>
<field name="name" select="1"/>
<newline/>
<field name="login" select="1"/>
<field name="password" required="1"/>
<field colspan="4" name="signature"/>
<separator string="Assign Groups to Define Access Rights" colspan="4"/>
<field colspan="4" name="groups_id" nolabel="1"/>
<separator string="" colspan="4"/>
<label string="" colspan="1"/>
<group col="3" colspan="2">
<button icon='gtk-cancel' special="cancel" name="action_next" type='object' string='Skip &amp; Continue'/>
<button name='action_new' icon='gtk-ok' type='object' string='Add New User'/>
<button name='action_continue' icon='gtk-go-forward' type='object' string='Add &amp; Continue'/>
</group>
</form>
</field>
</record>
@ -217,18 +209,18 @@
<field name="target">new</field>
</record>
<record id="view_confirm_simple_view_form" model="ir.ui.view">
<field name="name">res.users.confirm.simple_view</field>
<field name="model">res.config.view</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Configure simple view">
<separator string="Choose the simple or extended views" colspan="4"/>
<field colspan="2" name="view"/>
<separator string="Choose Your Mode" colspan="4"/>
<field colspan="2" name="view"/>
<label string="Choose the simplified interface if you are testing OpenERP for the first time. Less used options or fields are automatically hidden. You will be able to change this, later, through the Administration menu." colspan="4" align="0.0"/>
<newline/>
<separator string="" colspan="4"/>
<label string="" colspan="2"/>
<label string="" colspan="2"/>
<group colspan="2" col="1">
<button icon="gtk-ok" name="action_set" string="Set" type="object"/>
</group>
@ -251,18 +243,20 @@
<record id="config_wizard_step_user" model="ir.module.module.configuration.step">
<field name="name">Create User</field>
<field name="note">Create your different users.
<field name="note">Create your users.
You will be able to assign groups to users. Groups define the access rights of each users on the different objects of the system.
</field>
</field>
<field name="action_id" ref="action_config_user_form"/>
<field name="state">open</field>
<field name="sequence">10</field>
</record>
<record id="config_wizard_simple_view" model="ir.module.module.configuration.step">
<field name="name">Select between the simplified views or the extended views.</field>
<field name="note">Select between the simplified views or the extended views.
If you are testing or using OpenERP for the first time, we suggest you to use the simplified view, which has less features but is easier to understand. You will be able to switch to the extended view later.
<field name="name">Select Your Interface</field>
<field name="note">Choose between the "Simplified Interface" or the extended one.
If you are testing or using OpenERP for the first time, we suggest you to use
the simplified interface, which has less options and fields but is easier to
understand. You will be able to switch to the extended view later.
</field>
<field name="action_id" ref="action_config_simple_view_form"/>
<field name="state">open</field>

View File

@ -578,7 +578,7 @@ class module_configuration(osv.osv_memory):
item = item_obj.browse(cr, uid, item_ids[0], context=context)
return item.note
else:
return "Your database is now fully configured.\n\nClick 'Continue' and enyoy your OpenERP experience..."
return "Your database is now fully configured.\n\nClick 'Continue' and enjoy your OpenERP experience..."
return False
def _get_action(self, cr, uid, context={}):

View File

@ -237,12 +237,11 @@ class res_config_view(osv.osv_memory):
_name='res.config.view'
_columns = {
'name':fields.char('Name', size=64),
'view': fields.selection([('simple','Simple'),('extended','Extended')], 'View', required=True ),
'view': fields.selection([('simple','Simplified Interface'),('extended','Extended Interface')], 'View Mode', required=True ),
}
_defaults={
'view':lambda *args: 'simple',
}
}
def action_cancel(self,cr,uid,ids,conect=None):
print ' Cancel action'