diff --git a/addons/web/controllers/main.py b/addons/web/controllers/main.py index ce5bd3d81b0..4b7634da132 100644 --- a/addons/web/controllers/main.py +++ b/addons/web/controllers/main.py @@ -636,6 +636,7 @@ class Database(http.Controller): d['insecure'] = openerp.tools.config['admin_passwd'] == 'admin' d['list_db'] = openerp.tools.config['list_db'] d['langs'] = openerp.service.db.exp_list_lang() + d['countries'] = openerp.service.db.exp_list_countries() # databases list d['databases'] = [] try: @@ -657,7 +658,9 @@ class Database(http.Controller): @http.route('/web/database/create', type='http', auth="none", methods=['POST'], csrf=False) def create(self, master_pwd, name, lang, password, **post): try: - request.session.proxy("db").create_database(master_pwd, name, bool(post.get('demo')), lang, password) + # country code could be = "False" which is actually True in python + country_code = post.get('country_code') or False + request.session.proxy("db").create_database(master_pwd, name, bool(post.get('demo')), lang, password, post.get('login'), country_code) request.session.authenticate(name, 'admin', password) return http.local_redirect('/web/') except Exception, e: diff --git a/addons/web/views/database_manager.html b/addons/web/views/database_manager.html index 6602ed5635c..1dc5030c6c9 100644 --- a/addons/web/views/database_manager.html +++ b/addons/web/views/database_manager.html @@ -37,38 +37,58 @@ {% else %} - + {% endif %} {%- endmacro %} {% macro create_form() -%} -
Fill in this form to create an Odoo database. You may create - databases for different companies or for different goals (testing, - production). Once the database is created, you will be able to - install your first application.
+Odoo is up and running!
+ Create a new database by filling out the form,
+ you'll be able to install your first app in a minute.