diff --git a/addons/account/__openerp__.py b/addons/account/__openerp__.py index 19662ea2f33..9445688ec6d 100644 --- a/addons/account/__openerp__.py +++ b/addons/account/__openerp__.py @@ -22,7 +22,7 @@ "name" : "Accounting and Financial Management", "version" : "1.1", "author" : "OpenERP SA", - "category": 'Finance', + "category": 'Accounting & Finance', 'complexity': "normal", "description": """ Accounting and Financial Management. diff --git a/addons/account/account_installer.xml b/addons/account/account_installer.xml index b7bf5d89fe2..b35b37aa972 100644 --- a/addons/account/account_installer.xml +++ b/addons/account/account_installer.xml @@ -43,26 +43,6 @@ - - account.installer.modules.form - base.setup.installer - form - - - - - - - - - - - - - - - - Install your Chart of Accounts ir.actions.act_window diff --git a/addons/account/account_move_line.py b/addons/account/account_move_line.py index ce349fc4f4e..92d71339168 100644 --- a/addons/account/account_move_line.py +++ b/addons/account/account_move_line.py @@ -23,8 +23,10 @@ import time from datetime import datetime from operator import itemgetter +from lxml import etree + import netsvc -from osv import fields, osv +from osv import fields, osv, orm from tools.translate import _ import decimal_precision as dp import tools @@ -970,7 +972,6 @@ class account_move_line(osv.osv): fields = {} flds = [] title = _("Accounting Entries") #self.view_header_get(cr, uid, view_id, view_type, context) - xml = '''\n\n\t''' % (title) ids = journal_pool.search(cr, uid, []) journals = journal_pool.browse(cr, uid, ids, context=context) @@ -982,14 +983,14 @@ class account_move_line(osv.osv): for field in journal.view_id.columns_id: if not field.field in fields: fields[field.field] = [journal.id] - fld.append((field.field, field.sequence, field.name)) + fld.append((field.field, field.sequence)) flds.append(field.field) common_fields[field.field] = 1 else: fields.get(field.field).append(journal.id) common_fields[field.field] = common_fields[field.field] + 1 - fld.append(('period_id', 3, _('Period'))) - fld.append(('journal_id', 10, _('Journal'))) + fld.append(('period_id', 3)) + fld.append(('journal_id', 10)) flds.append('period_id') flds.append('journal_id') fields['period_id'] = all_journal @@ -1001,62 +1002,71 @@ class account_move_line(osv.osv): 'tax_code_id': 50, 'move_id': 40, } - for field_it in fld: - field = field_it[0] + + document = etree.Element('tree', string=title, editable="top", + refresh="5", on_write="on_create_write", + colors="red:state=='draft';black:state=='valid'") + fields_get = self.fields_get(cr, uid, flds, context) + for field, _seq in fld: if common_fields.get(field) == total: fields.get(field).append(None) -# if field=='state': -# state = 'colors="red:state==\'draft\'"' - attrs = [] + # if field=='state': + # state = 'colors="red:state==\'draft\'"' + f = etree.SubElement(document, 'field', name=field) + if field == 'debit': - attrs.append('sum = "%s"' % _("Total debit")) + f.set('sum', _("Total debit")) elif field == 'credit': - attrs.append('sum = "%s"' % _("Total credit")) + f.set('sum', _("Total credit")) elif field == 'move_id': - attrs.append('required = "False"') + f.set('required', 'False') elif field == 'account_tax_id': - attrs.append('domain="[(\'parent_id\', \'=\' ,False)]"') - attrs.append("context=\"{'journal_id': journal_id}\"") + f.set('domain', "[('parent_id', '=' ,False)]") + f.set('context', "{'journal_id': journal_id}") elif field == 'account_id' and journal.id: - attrs.append('domain="[(\'journal_id\', \'=\', journal_id),(\'type\',\'<>\',\'view\'), (\'type\',\'<>\',\'closed\')]" on_change="onchange_account_id(account_id, partner_id)"') + f.set('domain', "[('journal_id', '=', journal_id),('type','!=','view'), ('type','!=','closed')]") + f.set('on_change', 'onchange_account_id(account_id, partner_id)') elif field == 'partner_id': - attrs.append('on_change="onchange_partner_id(move_id, partner_id, account_id, debit, credit, date, journal_id)"') + f.set('on_change', 'onchange_partner_id(move_id, partner_id, account_id, debit, credit, date, journal_id)') elif field == 'journal_id': - attrs.append("context=\"{'journal_id': journal_id}\"") + f.set('context', "{'journal_id': journal_id}") elif field == 'statement_id': - attrs.append("domain=\"[('state', '!=', 'confirm'),('journal_id.type', '=', 'bank')]\"") + f.set('domain', "[('state', '!=', 'confirm'),('journal_id.type', '=', 'bank')]") elif field == 'date': - attrs.append('on_change="onchange_date(date)"') + f.set('on_change', 'onchange_date(date)') elif field == 'analytic_account_id': - attrs.append('''groups="analytic.group_analytic_accounting"''') # Currently it is not working due to framework problem may be .. + # Currently it is not working due to being executed by superclass's fields_view_get + # f.set('groups', 'analytic.group_analytic_accounting') + pass if field in ('amount_currency', 'currency_id'): - attrs.append('on_change="onchange_currency(account_id, amount_currency, currency_id, date, journal_id)"') - attrs.append('''attrs="{'readonly': [('state', '=', 'valid')]}"''') + f.set('on_change', 'onchange_currency(account_id, amount_currency, currency_id, date, journal_id)') + f.set('attrs', "{'readonly': [('state', '=', 'valid')]}") if field in widths: - attrs.append('width="'+str(widths[field])+'"') + f.set('width', str(widths[field])) if field in ('journal_id',): - attrs.append("invisible=\"context.get('journal_id', False)\"") + f.set("invisible", "context.get('journal_id', False)") elif field in ('period_id',): - attrs.append("invisible=\"context.get('period_id', False)\"") + f.set("invisible", "context.get('period_id', False)") else: - attrs.append("invisible=\"context.get('visible_id') not in %s\"" % (fields.get(field))) - xml += '''\n''' % (field,' '.join(attrs)) + f.set('invisible', "context.get('visible_id') not in %s" % (fields.get(field))) - xml += '''''' - result['arch'] = xml - result['fields'] = self.fields_get(cr, uid, flds, context) + orm.setup_modifiers(f, fields_get[field], context=context, + in_tree_view=True) + + result['arch'] = etree.tostring(document, pretty_print=True) + result['fields'] = fields_get return result def _check_moves(self, cr, uid, context=None): diff --git a/addons/account/account_view.xml b/addons/account/account_view.xml index 888c2cd7f2b..2ae910a36b3 100644 --- a/addons/account/account_view.xml +++ b/addons/account/account_view.xml @@ -1196,7 +1196,7 @@ - + diff --git a/addons/account/installer.py b/addons/account/installer.py index 417ac2f0461..bed92df4fd2 100644 --- a/addons/account/installer.py +++ b/addons/account/installer.py @@ -224,26 +224,4 @@ class account_installer(osv.osv_memory): account_installer() -class account_installer_modules(osv.osv_memory): - _inherit = 'base.setup.installer' - _columns = { - 'account_analytic_plans': fields.boolean('Multiple Analytic Plans', - help="Allows invoice lines to impact multiple analytic accounts " - "simultaneously."), - 'account_payment': fields.boolean('Suppliers Payment Management', - help="Streamlines invoice payment and creates hooks to plug " - "automated payment systems in."), - 'account_followup': fields.boolean('Followups Management', - help="Helps you generate reminder letters for unpaid invoices, " - "including multiple levels of reminding and customized " - "per-partner policies."), - 'account_anglo_saxon': fields.boolean('Anglo-Saxon Accounting', - help="This module will support the Anglo-Saxons accounting methodology by " - "changing the accounting logic with stock transactions."), - 'account_asset': fields.boolean('Assets Management', - help="Helps you to manage your assets and their depreciation entries."), - } - -account_installer_modules() - # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/account_accountant/__openerp__.py b/addons/account_accountant/__openerp__.py index c018d277d46..d808a38fa18 100644 --- a/addons/account_accountant/__openerp__.py +++ b/addons/account_accountant/__openerp__.py @@ -22,7 +22,7 @@ "name" : "Accountant Access", "version" : "1.1", "author" : "OpenERP SA", - "category": 'Finance', + "category": 'Hidden', 'complexity': "normal", "description": """ Accounting Access Rights. diff --git a/addons/account_analytic_analysis/__openerp__.py b/addons/account_analytic_analysis/__openerp__.py index 5e93307865c..f75fe3d1615 100644 --- a/addons/account_analytic_analysis/__openerp__.py +++ b/addons/account_analytic_analysis/__openerp__.py @@ -23,7 +23,7 @@ { 'name' : 'Analytic Account View', 'version' : '1.1', - 'category' : 'Finance', + 'category' : 'Hidden', 'complexity': "normal", 'description': """ This module is for modifying account analytic view to show important data to project manager of services companies. diff --git a/addons/account_analytic_default/__openerp__.py b/addons/account_analytic_default/__openerp__.py index 07cde53d003..e46f285d9c6 100644 --- a/addons/account_analytic_default/__openerp__.py +++ b/addons/account_analytic_default/__openerp__.py @@ -22,7 +22,7 @@ { 'name' : 'Account Analytic Defaults', 'version' : '1.0', - 'category' : 'Finance', + 'category' : 'Hidden', 'complexity': "normal", 'description': """Set default values for your analytic accounts Allows to automatically select analytic accounts based on criterions: diff --git a/addons/account_analytic_plans/__openerp__.py b/addons/account_analytic_plans/__openerp__.py index d6a5834517e..ffb20ffe3e8 100644 --- a/addons/account_analytic_plans/__openerp__.py +++ b/addons/account_analytic_plans/__openerp__.py @@ -21,9 +21,9 @@ { - 'name' : 'Manage multiple plans in Analytic Accounting', + 'name' : 'Multiple Analytic Plans', 'version' : '1.0', - 'category' : 'Finance', + 'category' : 'Accounting & Finance', 'complexity': "normal", 'description': """ This module allows to use several analytic plans, according to the general journal. diff --git a/addons/account_anglo_saxon/__openerp__.py b/addons/account_anglo_saxon/__openerp__.py index 79afb26ab26..8cf6a37c3fc 100644 --- a/addons/account_anglo_saxon/__openerp__.py +++ b/addons/account_anglo_saxon/__openerp__.py @@ -19,7 +19,7 @@ ############################################################################## { - "name" : "Stock Accounting for Anglo-Saxon countries", + "name" : "Anglo-Saxon Accouting", "version" : "1.2", "author" : "OpenERP SA, Veritos", "website" : "http://tinyerp.com - http://veritos.nl", @@ -36,7 +36,7 @@ when the invoice is created to transfer this amount to the debtor or creditor ac Secondly, price differences between actual purchase price and fixed product standard price are booked on a separate account""", "images" : ["images/account_anglo_saxon.jpeg"], "depends" : ["product", "purchase"], - "category" : "Warehouse", + "category" : "Accounting & Finance", "init_xml" : [], "demo_xml" : [], "update_xml" : ["product_view.xml",], diff --git a/addons/account_asset/__openerp__.py b/addons/account_asset/__openerp__.py index 4cad6f74af3..dd1161e1a14 100644 --- a/addons/account_asset/__openerp__.py +++ b/addons/account_asset/__openerp__.py @@ -20,16 +20,16 @@ ############################################################################## { - "name" : "Asset management", + "name" : "Assets Management", "version" : "1.0", "depends" : ["account"], - "author" : "Tiny", + "author" : "OpenERP S.A.", "description": """Financial and accounting asset management. This Module manages the assets owned by a company or an individual. It will keep track of depreciation's occurred on those assets. And it allows to create Move's of the depreciation lines. """, "website" : "http://www.openerp.com", - "category" : "Generic Modules/Accounting", + "category" : "Accounting & Finance", "init_xml" : [ ], "demo_xml" : [ 'account_asset_demo.xml' diff --git a/addons/account_budget/__openerp__.py b/addons/account_budget/__openerp__.py index 9ff5964637a..e4782ee0d2a 100644 --- a/addons/account_budget/__openerp__.py +++ b/addons/account_budget/__openerp__.py @@ -21,9 +21,9 @@ { - 'name': 'Budget Management', + 'name': 'Budgets', 'version': '1.0', - 'category': 'Finance', + 'category': 'Project Management', 'complexity': "normal", 'description': """ This module allows accountants to manage analytic and crossovered budgets. diff --git a/addons/account_cancel/__openerp__.py b/addons/account_cancel/__openerp__.py index 469033ac56e..ac73a2b8c31 100644 --- a/addons/account_cancel/__openerp__.py +++ b/addons/account_cancel/__openerp__.py @@ -23,7 +23,7 @@ "name" : "Cancel Entries", "version" : "1.1", "author" : "OpenERP SA", - "category": 'Finance', + "category": 'Hidden', 'complexity': "normal", "description": """ Allows cancelling accounting entries. diff --git a/addons/account_chart/__openerp__.py b/addons/account_chart/__openerp__.py index 2b958c4a943..948f13b5dcb 100644 --- a/addons/account_chart/__openerp__.py +++ b/addons/account_chart/__openerp__.py @@ -23,7 +23,7 @@ { 'name': 'Charts of Accounts', 'version': '1.1', - 'category': 'Finance', + 'category': 'Hidden', 'description': """ Remove minimal account chart. ============================= diff --git a/addons/account_coda/__openerp__.py b/addons/account_coda/__openerp__.py index fb39bc4c5ba..dd604e41aca 100644 --- a/addons/account_coda/__openerp__.py +++ b/addons/account_coda/__openerp__.py @@ -23,7 +23,7 @@ "name" : "Account CODA - import bank statements from coda file", "version" : "1.0", "author" : "OpenERP SA", - "category" : "Finance", + "category" : "Hidden", 'complexity': "normal", "description": """ Module provides functionality to import bank statements from coda files. diff --git a/addons/account_followup/__openerp__.py b/addons/account_followup/__openerp__.py index 9df99b720a2..ca6321d5672 100644 --- a/addons/account_followup/__openerp__.py +++ b/addons/account_followup/__openerp__.py @@ -20,9 +20,9 @@ ############################################################################## { - 'name': 'Reminders', + 'name': 'Followups Management', 'version': '1.0', - 'category': 'Finance', + 'category': 'Accounting & Finance', 'complexity': "normal", 'description': """ Modules to automate letters for unpaid invoices, with multi-level recalls. diff --git a/addons/account_invoice_layout/__openerp__.py b/addons/account_invoice_layout/__openerp__.py index b045b7b0b5d..557f3c2e02c 100644 --- a/addons/account_invoice_layout/__openerp__.py +++ b/addons/account_invoice_layout/__openerp__.py @@ -23,7 +23,7 @@ { 'name': 'Improve Invoice Layout', 'version': '1.0', - 'category': 'Finance', + 'category': 'Hidden', 'complexity': "easy", 'description': """ This module provides some features to improve the layout of the invoices. diff --git a/addons/account_invoice_layout/account_invoice_layout_view.xml b/addons/account_invoice_layout/account_invoice_layout_view.xml index c8bb5e84031..6bdabae9326 100644 --- a/addons/account_invoice_layout/account_invoice_layout_view.xml +++ b/addons/account_invoice_layout/account_invoice_layout_view.xml @@ -10,7 +10,7 @@ form - + @@ -23,6 +23,7 @@ tree + diff --git a/addons/account_payment/__openerp__.py b/addons/account_payment/__openerp__.py index 8a90a140558..1912dfa5198 100644 --- a/addons/account_payment/__openerp__.py +++ b/addons/account_payment/__openerp__.py @@ -20,10 +20,10 @@ ############################################################################## { - "name": "Payment Management", + "name": "Suppliers Payment Management", "version": "1.1", "author": "OpenERP SA", - "category": "Finance", + "category": "Accounting & Finance", 'complexity': "easy", "description": """ Module to manage invoice payment. diff --git a/addons/account_sequence/__openerp__.py b/addons/account_sequence/__openerp__.py index f7ab18f3e7e..31d4f373e2f 100644 --- a/addons/account_sequence/__openerp__.py +++ b/addons/account_sequence/__openerp__.py @@ -22,7 +22,7 @@ { 'name': 'Entries Sequence Numbering', 'version': '1.1', - 'category': 'Finance', + 'category': 'Hidden', 'complexity': "easy", 'description': """ This module maintains internal sequence number for accounting entries. diff --git a/addons/account_voucher/__openerp__.py b/addons/account_voucher/__openerp__.py index 7da2b2da99c..97ac9950efb 100644 --- a/addons/account_voucher/__openerp__.py +++ b/addons/account_voucher/__openerp__.py @@ -32,7 +32,7 @@ Account Voucher module includes all the basic requirements of Voucher Entries fo * Voucher Receipt * Cheque Register """, - "category" : "Finance", + "category" : "Hidden", "website" : "http://tinyerp.com", "images" : ["images/customer_payment.jpeg","images/journal_voucher.jpeg","images/sales_receipt.jpeg","images/supplier_voucher.jpeg"], "depends" : ["account"], diff --git a/addons/analytic/__openerp__.py b/addons/analytic/__openerp__.py index 30712a78167..65f6588a1e3 100644 --- a/addons/analytic/__openerp__.py +++ b/addons/analytic/__openerp__.py @@ -24,7 +24,7 @@ "version": "1.1", "author" : "OpenERP SA", "website" : "http://www.openerp.com", - "category" : "Finance", + "category" : "Hidden", "depends" : ["base", "decimal_precision"], "description": """ Module for defining analytic accounting object. diff --git a/addons/analytic_journal_billing_rate/__openerp__.py b/addons/analytic_journal_billing_rate/__openerp__.py index a9241213251..059e85d9367 100644 --- a/addons/analytic_journal_billing_rate/__openerp__.py +++ b/addons/analytic_journal_billing_rate/__openerp__.py @@ -22,7 +22,7 @@ { 'name': 'Analytic Journal Billing Rate, Define the default invoicing rate for a specific journal', 'version': '1.0', - 'category': 'Human Resources', + 'category': 'Hidden', 'description': """ This module allows you to define what is the default invoicing rate for a specific journal on a given account. ============================================================================================================== diff --git a/addons/analytic_user_function/__openerp__.py b/addons/analytic_user_function/__openerp__.py index 9716495aabc..bb3ca084be7 100644 --- a/addons/analytic_user_function/__openerp__.py +++ b/addons/analytic_user_function/__openerp__.py @@ -23,7 +23,7 @@ { 'name': 'Human Resources', 'version': '1.0', - 'category': 'Generic Modules/Others', + 'category': 'Hidden', 'description': """ This module allows you to define what is the default function of a specific user on a given account. ==================================================================================================== diff --git a/addons/anonymization/__openerp__.py b/addons/anonymization/__openerp__.py index 842b774eb9c..41e906c078a 100644 --- a/addons/anonymization/__openerp__.py +++ b/addons/anonymization/__openerp__.py @@ -24,7 +24,7 @@ { 'name': 'Database Anonymization', 'version': '1.0', - 'category': 'Tools', + 'category': 'Hidden', 'complexity': "easy", 'description': """ This module allows you to anonymize a database. diff --git a/addons/association/__init__.py b/addons/association/__init__.py index 5b34f17fec9..4716d0d109b 100644 --- a/addons/association/__init__.py +++ b/addons/association/__init__.py @@ -18,6 +18,5 @@ # along with this program. If not, see . # ############################################################################## -import profile_association # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/association/__openerp__.py b/addons/association/__openerp__.py index 51d44bf681d..0251eb68d02 100644 --- a/addons/association/__openerp__.py +++ b/addons/association/__openerp__.py @@ -23,8 +23,7 @@ { 'name': 'Association profile', 'version': '0.1', - 'category': 'General', - 'category': 'Profile', + 'category': 'Vertical Applications', 'complexity': "normal", 'description': """ This module is to configure modules related to an association. diff --git a/addons/association/profile_association.py b/addons/association/profile_association.py deleted file mode 100644 index 0e66af14a1d..00000000000 --- a/addons/association/profile_association.py +++ /dev/null @@ -1,53 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# Copyright (C) 2004-2010 Tiny SPRL (). -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## -from lxml import etree -from osv import fields, osv - -class profile_association_config_install_modules_wizard(osv.osv_memory): - _inherit = 'base.setup.installer' - - _columns = { - 'hr_expense':fields.boolean('Resources Management: Expenses Tracking', help="Tracks and manages employee expenses, and can " - "automatically re-invoice clients if the expenses are " - "project-related."), - 'event_project':fields.boolean('Event Management: Events', help="Helps you to manage and organize your events."), - 'project_gtd':fields.boolean('Getting Things Done', - help="GTD is a methodology to efficiently organise yourself and your tasks. This module fully integrates GTD principle with OpenERP's project management."), - 'wiki': fields.boolean('Wiki', help="Lets you create wiki pages and page groups in order " - "to keep track of business knowledge and share it with " - "and between your employees."), - } - - # Will be removed when rd-v61-al-config-depends will be done - def fields_view_get(self, cr, user, view_id=None, view_type='form', context=None, toolbar=False, submenu=False): - res = super(profile_association_config_install_modules_wizard, self).fields_view_get(cr, user, view_id, view_type, context, toolbar=toolbar, submenu=submenu) - doc = etree.XML(res['arch']) - for module in ['project_gtd','hr_expense']: - count = 0 - for node in doc.xpath("//field[@name='%s']" % (module)): - count = count + 1 - if count > 1: - node.set('invisible', '1') - res['arch'] = etree.tostring(doc) - return res - -profile_association_config_install_modules_wizard() -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/association/profile_association.xml b/addons/association/profile_association.xml index 12222ecbd90..8ce97cb2e43 100644 --- a/addons/association/profile_association.xml +++ b/addons/association/profile_association.xml @@ -1,24 +1,6 @@ - - Association Application Configuration - base.setup.installer - form - - - - - - - - - - - - - - \n" "POT-Creation-Date: 2011-01-11 11:14+0000\n" -"PO-Revision-Date: 2011-06-06 18:09+0000\n" -"Last-Translator: doingit.cl \n" +"PO-Revision-Date: 2011-10-03 17:17+0000\n" +"Last-Translator: David Acevedo Toledo \n" "Language-Team: Spanish (Chile) \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-09-05 05:58+0000\n" -"X-Generator: Launchpad (build 13830)\n" +"X-Launchpad-Export-Date: 2011-10-04 05:02+0000\n" +"X-Generator: Launchpad (build 14071)\n" #. module: base_crypt #: sql_constraint:res.users:0 msgid "You can not have two users with the same login !" -msgstr "" +msgstr "¡No puede tener dos usuarios con el mismo nombre!" #. module: base_crypt #: model:ir.model,name:base_crypt.model_res_users @@ -31,18 +31,19 @@ msgstr "res.users" #: constraint:res.users:0 msgid "The chosen company is not in the allowed companies for this user" msgstr "" -"La compañía seleccionada no está autorizada como compañía para este usuario" +"La compañía seleccionada no está dentro de las compañías autorizadas para " +"este usuario" #. module: base_crypt #: code:addons/base_crypt/crypt.py:132 #, python-format msgid "Please specify the password !" -msgstr "" +msgstr "¡Por favor, escriba una contraseña!" #. module: base_crypt #: model:ir.module.module,shortdesc:base_crypt.module_meta_information msgid "Base - Password Encryption" -msgstr "" +msgstr "Base - Encriptación de la Contraseña" #. module: base_crypt #: code:addons/base_crypt/crypt.py:132 @@ -70,3 +71,19 @@ msgid "" "unless you are using a secure protocol such as XML-RPCS.\n" " " msgstr "" +"Este módulo sustituye la contraseña escrita en texto plano por una " +"codificada,\n" +"previniendo que alguien pueda leer la contraseña original.\n" +"Para un usuario existente, el sustitución de la contraseña en texto plano se " +"realiza la primera vez\n" +"que el usuario se conecte después de instalar base_crypt.\n" +"Después de instalar este módulo los usuarios no podrán recuperar su " +"contraseña olvidada,\n" +"un administrador tendrá que cambiarla por una nueva.\n" +"\n" +"Nota: instalar este módulo no significa que pueda ignorar las medidas " +"básicas de seguridad,\n" +"como la contraseña que es enviada por el cliente que sigue sin ser " +"codificada en la red,\n" +"a menos que utilice un protocolo seguro como XML-RPCS.\n" +" " diff --git a/addons/base_crypt/i18n/sr@latin.po b/addons/base_crypt/i18n/sr@latin.po new file mode 100644 index 00000000000..8b205c0ea97 --- /dev/null +++ b/addons/base_crypt/i18n/sr@latin.po @@ -0,0 +1,85 @@ +# Serbian Latin translation for openobject-addons +# Copyright (c) 2011 Rosetta Contributors and Canonical Ltd 2011 +# This file is distributed under the same license as the openobject-addons package. +# FIRST AUTHOR , 2011. +# +msgid "" +msgstr "" +"Project-Id-Version: openobject-addons\n" +"Report-Msgid-Bugs-To: FULL NAME \n" +"POT-Creation-Date: 2011-01-11 11:14+0000\n" +"PO-Revision-Date: 2011-10-05 13:25+0000\n" +"Last-Translator: Milan Milosevic \n" +"Language-Team: Serbian Latin \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"X-Launchpad-Export-Date: 2011-10-06 04:36+0000\n" +"X-Generator: Launchpad (build 14085)\n" + +#. module: base_crypt +#: sql_constraint:res.users:0 +msgid "You can not have two users with the same login !" +msgstr "Ne možete imati dva korisnika sa istom prijavom!" + +#. module: base_crypt +#: model:ir.model,name:base_crypt.model_res_users +msgid "res.users" +msgstr "res.users" + +#. module: base_crypt +#: constraint:res.users:0 +msgid "The chosen company is not in the allowed companies for this user" +msgstr "Odabrana firma nije u dozvoljena firmama za ovog korisnika" + +#. module: base_crypt +#: code:addons/base_crypt/crypt.py:132 +#, python-format +msgid "Please specify the password !" +msgstr "Molimo odredite lozinku" + +#. module: base_crypt +#: model:ir.module.module,shortdesc:base_crypt.module_meta_information +msgid "Base - Password Encryption" +msgstr "Baza - Šifrovanje lozinke" + +#. module: base_crypt +#: code:addons/base_crypt/crypt.py:132 +#, python-format +msgid "Error" +msgstr "Greška" + +#. module: base_crypt +#: model:ir.module.module,description:base_crypt.module_meta_information +msgid "" +"This module replaces the cleartext password in the database with a password " +"hash,\n" +"preventing anyone from reading the original password.\n" +"For your existing user base, the removal of the cleartext passwords occurs " +"the first time\n" +"a user logs into the database, after installing base_crypt.\n" +"After installing this module it won't be possible to recover a forgotten " +"password for your\n" +"users, the only solution is for an admin to set a new password.\n" +"\n" +"Note: installing this module does not mean you can ignore basic security " +"measures,\n" +"as the password is still transmitted unencrypted on the network (by the " +"client),\n" +"unless you are using a secure protocol such as XML-RPCS.\n" +" " +msgstr "" +"Ovaj modul zamenjuje vidljivu lozinku u bazi podataka znacima,\n" +"što onemogućava bilo koga da pročita originalnu lozinku.\n" +"Što se tiče Vaše baze podataka, ukidanje vidljive lozinke dešava se prvi put " +"pošto se korisnik prijavi u bazu podataka, po instalaciji base_crypt.\n" +"Po instalaciji ovog modula neće biti moguće izmeniti zaboravljenu lozinku za " +"Vaše korisnike, jedino rešenje će biti da im administrator postavi novu " +"lozinku.\n" +"\n" +"Beleška: Instaliranje ovog modula ne znači da možete ignorisati osnovne " +"sigurnosne mere,\n" +"budući da se lozinka i dalje prenosi nešifrovana u mreži (od strane " +"klijenta),\n" +"ukoliko ne koristite siguran protokol kao XML-RPCS.\n" +" " diff --git a/addons/base_iban/__openerp__.py b/addons/base_iban/__openerp__.py index 370ca6c93f2..c9bc3866b4f 100644 --- a/addons/base_iban/__openerp__.py +++ b/addons/base_iban/__openerp__.py @@ -21,7 +21,7 @@ { 'name': 'Create IBAN bank accounts', 'version': '1.0', - 'category': 'Finance', + 'category': 'Hidden', 'complexity': "easy", 'description': """ This module installs the base for IBAN (International Bank Account Number) bank accounts and checks for its validity. diff --git a/addons/base_iban/i18n/sr@latin.po b/addons/base_iban/i18n/sr@latin.po index d1017c9f6ef..f25a93fc270 100644 --- a/addons/base_iban/i18n/sr@latin.po +++ b/addons/base_iban/i18n/sr@latin.po @@ -8,19 +8,19 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2011-01-11 11:14+0000\n" -"PO-Revision-Date: 2010-12-23 15:48+0000\n" -"Last-Translator: OpenERP Administrators \n" +"PO-Revision-Date: 2011-10-05 13:32+0000\n" +"Last-Translator: Milan Milosevic \n" "Language-Team: Serbian latin \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-09-05 04:58+0000\n" -"X-Generator: Launchpad (build 13830)\n" +"X-Launchpad-Export-Date: 2011-10-06 04:36+0000\n" +"X-Generator: Launchpad (build 14085)\n" #. module: base_iban #: model:ir.module.module,shortdesc:base_iban.module_meta_information msgid "Create IBAN bank accounts" -msgstr "Kreiraj IBAN nalog banke" +msgstr "Napravi IBAN nalog banke" #. module: base_iban #: code:addons/base_iban/base_iban.py:120 @@ -28,7 +28,7 @@ msgstr "Kreiraj IBAN nalog banke" msgid "" "The IBAN does not seems to be correct. You should have entered something " "like this %s" -msgstr "IBAN izgleda da nije ispravan. TRebas uneti nesto nalik na %s" +msgstr "IBAN izgleda da nije ispravan. Trebalo je uneti nešto kao %s" #. module: base_iban #: model:res.partner.bank.type.field,name:base_iban.bank_zip_field @@ -43,7 +43,7 @@ msgstr "Međunarodni broj Bankovnog računa" #. module: base_iban #: model:ir.model,name:base_iban.model_res_partner_bank msgid "Bank Accounts" -msgstr "Bankovni Računi" +msgstr "Bankovni računi" #. module: base_iban #: model:res.partner.bank.type.field,name:base_iban.bank_country_field @@ -64,7 +64,7 @@ msgstr "iban" #: code:addons/base_iban/base_iban.py:121 #, python-format msgid "The IBAN is invalid, It should begin with the country code" -msgstr "IBAN je neispravan, trebalo bi da pocinje sa kodom zemlje" +msgstr "IBAN je neispravan, trebalo bi da počinje sa kodom zemlje" #. module: base_iban #: field:res.partner.bank,iban:0 @@ -74,7 +74,7 @@ msgstr "IBAN" #. module: base_iban #: model:res.partner.bank.type,name:base_iban.bank_iban msgid "IBAN Account" -msgstr "IBAN konto" +msgstr "IBAN račun" #. module: base_iban #: model:ir.module.module,description:base_iban.module_meta_information @@ -85,11 +85,16 @@ msgid "" "\n" " " msgstr "" +"\n" +"Ovaj modul instalira bazu za IBAN (Međunarodni broj bankovnog računa) " +"bankovne račune i proverava im validnost.\n" +"\n" +" " #. module: base_iban #: model:res.partner.bank.type.field,name:base_iban.bank_acc_number_field msgid "acc_number" -msgstr "Broj konta" +msgstr "acc_number" #~ msgid "Invalid XML for View Architecture!" #~ msgstr "Nevažeći XML za pregled arhitekture" diff --git a/addons/base_module_doc_rst/__openerp__.py b/addons/base_module_doc_rst/__openerp__.py index c2c5ca30a91..41425f77749 100644 --- a/addons/base_module_doc_rst/__openerp__.py +++ b/addons/base_module_doc_rst/__openerp__.py @@ -22,7 +22,7 @@ { 'name': 'Module Technical Guide in Restructured Text ', 'version': '1.0', - 'category': 'Tools', + 'category': 'Hidden', 'description': """ This module generates the Technical Guides of selected modules in Restructured Text format (RST). ================================================================================================= diff --git a/addons/base_module_quality/__openerp__.py b/addons/base_module_quality/__openerp__.py index ec9ec1191d2..af258685629 100644 --- a/addons/base_module_quality/__openerp__.py +++ b/addons/base_module_quality/__openerp__.py @@ -23,7 +23,7 @@ { 'name': 'Base module quality - To check the quality of other modules' , 'version': '1.0', - 'category': 'Tools', + 'category': 'Hidden', 'description': """ The aim of this module is to check the quality of other modules. ================================================================ diff --git a/addons/base_module_record/__openerp__.py b/addons/base_module_record/__openerp__.py index fdb576e0ddd..3e1cf79792a 100644 --- a/addons/base_module_record/__openerp__.py +++ b/addons/base_module_record/__openerp__.py @@ -23,7 +23,7 @@ { 'name': 'Module Record', 'version': '1.0', - 'category': 'Tools', + 'category': 'Hidden', 'description': """ This module allows you to create a new module without any development. ====================================================================== diff --git a/addons/base_module_record/i18n/sr@latin.po b/addons/base_module_record/i18n/sr@latin.po index 02ad1d3664d..01596dacd24 100644 --- a/addons/base_module_record/i18n/sr@latin.po +++ b/addons/base_module_record/i18n/sr@latin.po @@ -8,24 +8,24 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2011-01-11 11:14+0000\n" -"PO-Revision-Date: 2010-12-23 10:53+0000\n" -"Last-Translator: qdp (OpenERP) \n" +"PO-Revision-Date: 2011-10-05 13:53+0000\n" +"Last-Translator: Milan Milosevic \n" "Language-Team: Serbian \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2011-09-05 05:10+0000\n" -"X-Generator: Launchpad (build 13830)\n" +"X-Launchpad-Export-Date: 2011-10-06 04:36+0000\n" +"X-Generator: Launchpad (build 14085)\n" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,category:0 msgid "Category" -msgstr "Категорија" +msgstr "Kategorija" #. module: base_module_record #: wizard_view:base_module_record.module_record_objects,save:0 msgid "Information" -msgstr "Informacija" +msgstr "Informacije" #. module: base_module_record #: wizard_view:base_module_record.module_record_objects,save:0 @@ -34,9 +34,9 @@ msgid "" "publish it on OpenERP.com, in the 'Modules' section. You can do it through " "the website or using features of the 'base_module_publish' module." msgstr "" -"Ako mislite da vas modul moze zainteresovati i druge ljude, mozete ga " -"publikovati na OpenERP.com u sekciji 'Moduli'. To mozete uciniti preko " -"websajta ili koristeci mogucnosti modula 'base_module_publish' ." +"Ako mislite da Vaš modul može zainteresovati i druge ljude, Voleli bismo da " +"ga objabvite na OpenERP.com u sekciji 'Moduli'. To možete učiniti preko " +"vebsajta ili koristeći mogućnosti modula 'base_module_publish' ." #. module: base_module_record #: wizard_button:base_module_record.module_record_data,info,end:0 @@ -48,7 +48,7 @@ msgstr "Kraj" #: wizard_view:base_module_record.module_record_data,init:0 #: wizard_view:base_module_record.module_record_objects,init:0 msgid "Choose objects to record" -msgstr "Izaberi objekat za cuvanje" +msgstr "Izaberi stavke za čuvanje" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,author:0 @@ -58,13 +58,13 @@ msgstr "Autor" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,directory_name:0 msgid "Directory Name" -msgstr "Ime Direktorijuma" +msgstr "Ime fascikle" #. module: base_module_record #: wizard_field:base_module_record.module_record_data,init,filter_cond:0 #: wizard_field:base_module_record.module_record_objects,init,filter_cond:0 msgid "Records only" -msgstr "Samo Zapisi" +msgstr "Samo zapisi" #. module: base_module_record #: model:ir.model,name:base_module_record.model_ir_module_record @@ -74,12 +74,12 @@ msgstr "ir.module.record" #. module: base_module_record #: selection:base_module_record.module_record_objects,info,data_kind:0 msgid "Demo Data" -msgstr "Demo Podaci" +msgstr "Demo podaci" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,save,module_filename:0 msgid "Filename" -msgstr "Ime Fajla" +msgstr "Ime datoteke" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,version:0 @@ -92,7 +92,7 @@ msgstr "Verzija" #: wizard_view:base_module_record.module_record_data,save_yaml:0 #: wizard_view:base_module_record.module_record_objects,init:0 msgid "Objects Recording" -msgstr "Objekti se Snimaju" +msgstr "Zapisi stavki" #. module: base_module_record #: wizard_field:base_module_record.module_record_data,init,check_date:0 @@ -107,29 +107,29 @@ msgstr "Zapis od Datuma" #: wizard_view:base_module_record.module_record_objects,save:0 #: wizard_view:base_module_record.module_record_objects,save_yaml:0 msgid "Module Recording" -msgstr "Snimanje Modula" +msgstr "Zapisivanje modula" #. module: base_module_record #: model:ir.actions.wizard,name:base_module_record.wizard_base_module_record_objects #: model:ir.ui.menu,name:base_module_record.menu_wizard_base_module_record_objects msgid "Export Customizations As a Module" -msgstr "Izvezi Podesavanja kao Modul" +msgstr "Izvezi podešavanja kao modul" #. module: base_module_record #: wizard_view:base_module_record.module_record_objects,save:0 msgid "Thanks in advance for your contribution." -msgstr "Hvala unaprijed na Vašem Doprinosu" +msgstr "Hvala unapred na Vašem doprinosu" #. module: base_module_record #: help:base_module_record.module_record_data,init,objects:0 #: help:base_module_record.module_record_objects,init,objects:0 msgid "List of objects to be recorded" -msgstr "Lista Objekata za zapis" +msgstr "Spisak stavki za zapis" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,description:0 msgid "Full Description" -msgstr "Puni Opis" +msgstr "Puni opis" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,name:0 @@ -140,63 +140,63 @@ msgstr "Naziv Modula" #: wizard_field:base_module_record.module_record_data,init,objects:0 #: wizard_field:base_module_record.module_record_objects,init,objects:0 msgid "Objects" -msgstr "Objekti" +msgstr "Stavka" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,save,module_file:0 #: wizard_field:base_module_record.module_record_objects,save_yaml,yaml_file:0 msgid "Module .zip File" -msgstr ".zip datoteka Modula" +msgstr ".zip datoteka modula" #. module: base_module_record #: wizard_view:base_module_record.module_record_objects,save:0 msgid "Module successfully created !" -msgstr "Modul uspješno kreiran !" +msgstr "Modul uspešno napravljen !" #. module: base_module_record #: wizard_view:base_module_record.module_record_objects,save_yaml:0 msgid "YAML file successfully created !" -msgstr "YAML fajl je uspesno kreiran !" +msgstr "YAML datoteka uspešno napravljena !" #. module: base_module_record #: wizard_view:base_module_record.module_record_data,info:0 #: wizard_view:base_module_record.module_record_data,save_yaml:0 msgid "Result, paste this to your module's xml" -msgstr "Rezultat, zalepi ovo u tvoj xml modul" +msgstr "Rezultat, zalepite ovo u Vaš xml modul" #. module: base_module_record #: selection:base_module_record.module_record_data,init,filter_cond:0 #: selection:base_module_record.module_record_objects,init,filter_cond:0 msgid "Created" -msgstr "Kreirano" +msgstr "Napravljeno" #. module: base_module_record #: wizard_view:base_module_record.module_record_data,end:0 #: wizard_view:base_module_record.module_record_objects,end:0 msgid "Thanks For using Module Recorder" -msgstr "Hvala što ste koristili Snimač Modula" +msgstr "Hvala što ste koristili Zapisivač modula" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,website:0 msgid "Documentation URL" -msgstr "URL Dokumentacije" +msgstr "URL Dokumentacija" #. module: base_module_record #: selection:base_module_record.module_record_data,init,filter_cond:0 #: selection:base_module_record.module_record_objects,init,filter_cond:0 msgid "Modified" -msgstr "Izmenjen" +msgstr "Izmenjeno" #. module: base_module_record #: wizard_button:base_module_record.module_record_data,init,record:0 #: wizard_button:base_module_record.module_record_objects,init,record:0 msgid "Record" -msgstr "Snima" +msgstr "Zapis" #. module: base_module_record #: model:ir.module.module,shortdesc:base_module_record.module_meta_information msgid "Module Record" -msgstr "Snimanje Modula" +msgstr "Zapisivanje modula" #. module: base_module_record #: wizard_button:base_module_record.module_record_objects,info,save:0 @@ -207,13 +207,13 @@ msgstr "Nastavi" #: model:ir.actions.wizard,name:base_module_record.wizard_base_module_record_data #: model:ir.ui.menu,name:base_module_record.menu_wizard_base_module_record_data msgid "Export Customizations As Data File" -msgstr "Eksportuj POdesavanja kao Data fajl" +msgstr "Izvezi podešavanja kao data datoteku" #. module: base_module_record #: code:addons/base_module_record/wizard/base_module_save.py:129 #, python-format msgid "Error" -msgstr "Greska" +msgstr "Greška" #. module: base_module_record #: selection:base_module_record.module_record_objects,info,data_kind:0 @@ -224,12 +224,12 @@ msgstr "Obični podaci" #: wizard_button:base_module_record.module_record_data,end,end:0 #: wizard_button:base_module_record.module_record_objects,end,end:0 msgid "OK" -msgstr "U redu" +msgstr "OK" #. module: base_module_record #: model:ir.ui.menu,name:base_module_record.menu_wizard_base_mod_rec msgid "Module Creation" -msgstr "Kreacija Modula" +msgstr "Pravljenje Modula" #. module: base_module_record #: wizard_field:base_module_record.module_record_objects,info,data_kind:0 @@ -239,7 +239,7 @@ msgstr "Tip Podataka" #. module: base_module_record #: wizard_view:base_module_record.module_record_objects,info:0 msgid "Module Information" -msgstr "Informacija o Modulu" +msgstr "Informacija o modulu" #. module: base_module_record #: wizard_field:base_module_record.module_record_data,init,info_yaml:0 @@ -296,6 +296,26 @@ msgid "" "module.\n" " " msgstr "" +"\n" +"Ovaj modul omogućava da napravite novi modul bez ikakvog razvoja.\n" +"Zapisuje sve operacije na stavkama za vreme sesija zapisivanaj i\n" +"pravi .ZIP modul. Tako da možete napraviti sopstvene module direknto iz\n" +"OpenERP klijenta.\n" +"\n" +"Ova verzija radi za pravljenje i izmenu postojećih zapisa. Iznova " +"obračunava\n" +"međuzavisnosti i veze između svih tipova vidžeta (man2one, many2many, ...).\n" +"\n" +"Ovo bi trebalo da Vam pomogne da lako pravite ponovo upotrebljive module, " +"koje možete ponovo objaviti,\n" +"za korisnička podešavanja i demo/testiranje podataka.\n" +"\n" +"Kako ga koristiti:\n" +"Pokrenite Administration/Customization/Module Creation/Export Customizations " +"kao pomoćni modul.\n" +"Izaberite datum i vreme kao kriterijume za zapis i stavke za zapis i " +"zapišite modul.\n" +" " #~ msgid "" #~ "The Object name must start with x_ and not contain any special character !" diff --git a/addons/base_report_creator/__openerp__.py b/addons/base_report_creator/__openerp__.py index 6c0a01f78fd..5e8bed72d03 100644 --- a/addons/base_report_creator/__openerp__.py +++ b/addons/base_report_creator/__openerp__.py @@ -21,9 +21,9 @@ { - 'name': 'Statistical Report Creator', + 'name': 'Query Builder', 'version': '1.0', - 'category': 'Tools', + 'category': 'Advanced Reporting', 'complexity': "expert", 'description': """ This module allows you to create any statistic report on several objects. diff --git a/addons/base_report_designer/__openerp__.py b/addons/base_report_designer/__openerp__.py index c5bbbbd34ec..a95235d8017 100644 --- a/addons/base_report_designer/__openerp__.py +++ b/addons/base_report_designer/__openerp__.py @@ -21,9 +21,9 @@ { - 'name': 'OpenOffice Report Designer Interface', + 'name': 'OpenOffice Report Designer', 'version': '0.1', - 'category': 'Tools', + 'category': 'Advanced Reporting', 'complexity': "normal", 'description': """ This module is used along with OpenERP OpenOffice Plugin. diff --git a/addons/base_setup/__openerp__.py b/addons/base_setup/__openerp__.py index c483b4324c1..4417ebf2439 100644 --- a/addons/base_setup/__openerp__.py +++ b/addons/base_setup/__openerp__.py @@ -23,7 +23,7 @@ { 'name': 'Base Setup', 'version': '1.0', - 'category': 'Tools', + 'category': 'Hidden', 'complexity': "easy", 'description': """ This module helps to configure the system at the installation of a new database. diff --git a/addons/base_setup/base_setup.py b/addons/base_setup/base_setup.py index a87e4e24e39..3610c227142 100644 --- a/addons/base_setup/base_setup.py +++ b/addons/base_setup/base_setup.py @@ -20,123 +20,300 @@ ############################################################################## import pytz +import simplejson +import cgi import pooler import tools from osv import fields, osv from tools.translate import _ +from lxml import etree #Application and feature chooser, this could be done by introspecting ir.modules +DEFAULT_MODULES = { + 'Customer Relationship Management' : ['crm',], + 'Sales Management' : ['sale',], + 'Project Management' : ['project',], + 'Knowledge Management' : ['document',], + 'Warehouse Management' : ['stock',], + 'Manufacturing' : ['mrp', 'procurement'], + 'Accounting & Finance' : ['account'], + 'Purchase Management' : ['purchase'], + 'Human Resources' : ['hr',], + 'Point of Sales' : ['pos',], + 'Marketing' : ['marketing',], +} class base_setup_installer(osv.osv_memory): _name = 'base.setup.installer' + _inherit = 'res.config.installer' - _install_if = { - ('sale','crm'): ['sale_crm'], - ('sale','project'): ['project_mrp'], - } _columns = { - # Generic modules - 'crm':fields.boolean('Customer Relationship Management', - help="Helps you track and manage relations with customers such as" - " leads, requests or issues. Can automatically send " - "reminders, escalate requests or trigger business-specific " - "actions based on standard events."), - 'sale':fields.boolean('Sales Management', - help="Helps you handle your quotations, sale orders and invoicing" - "."), - 'project':fields.boolean('Project Management', - help="Helps you manage your projects and tasks by tracking them, " - "generating plannings, etc..."), - 'knowledge':fields.boolean('Knowledge Management', - help="Lets you install addons geared towards sharing knowledge " - "with and between your employees."), - 'stock':fields.boolean('Warehouse Management', - help="Helps you manage your inventory and main stock operations: delivery orders, receptions, etc."), - 'mrp':fields.boolean('Manufacturing', - help="Helps you manage your manufacturing processes and generate " - "reports on those processes."), - 'account_voucher':fields.boolean('Invoicing & Payments', - help="Allows you to create your invoices and track the payments. It is an easier version of the accounting module for managers who are not accountants."), - 'account_accountant':fields.boolean('Accounting & Finance', - help="Helps you handle your accounting needs, if you are not an accountant, we suggest you to install only the Invoicing "), - 'purchase':fields.boolean('Purchase Management', - help="Helps you manage your purchase-related processes such as " - "requests for quotations, supplier invoices, etc..."), - 'hr':fields.boolean('Human Resources', - help="Helps you manage your human resources by encoding your employees structure, generating work sheets, tracking attendance and more."), - 'point_of_sale':fields.boolean('Point of Sales', - help="Helps you get the most out of your points of sales with " - "fast sale encoding, simplified payment mode encoding, " - "automatic picking lists generation and more."), - 'marketing':fields.boolean('Marketing', - help="Helps you manage your marketing campaigns step by step."), - 'profile_tools':fields.boolean('Extra Tools', - help="Lets you install various interesting but non-essential tools " - "like Survey, Lunch and Ideas box."), - 'report_designer':fields.boolean('Advanced Reporting', - help="Lets you install various tools to simplify and enhance " - "OpenERP's report creation."), - # Vertical modules - 'product_expiry':fields.boolean('Food Industry', - help="Installs a preselected set of OpenERP applications " - "which will help you manage your industry."), - 'association':fields.boolean('Associations', - help="Installs a preselected set of OpenERP " - "applications which will help you manage your association " - "more efficiently."), - 'auction':fields.boolean('Auction Houses', - help="Installs a preselected set of OpenERP " - "applications selected to help you manage your auctions " - "as well as the business processes around them."), + 'selection' : fields.text('Selection'), + } + + def fields_get(self, cr, uid, fields=None, context=None): + if context is None: + context = {} + if fields is None: + fields = {} + + fields = {} + category_proxy = self.pool.get('ir.module.category') + domain = [('parent_id', '=', False), + ('name', '!=', 'Uncategorized'), + ('visible', '=', True)] + category_ids = category_proxy.search(cr, uid, domain, context=context) + for category in category_proxy.browse(cr, uid, category_ids, context=context): + category_name = 'category_%d' % (category.id,) + fields[category_name] = { + 'type' : 'boolean', + 'string' : category.name, + 'name' : category_name, + 'help' : category.description, + } + + module_proxy = self.pool.get('ir.module.module') + module_ids = module_proxy.search(cr, uid, [], context=context) + for module in module_proxy.browse(cr, uid, module_ids, context=context): + module_name = 'module_%d' % (module.id,) + module_is_installed = module.state == 'installed' + + fields[module_name] = { + 'type' : 'boolean', + 'string' : module.shortdesc, + 'name' : module_name, + 'help' : module.description, + } + + return fields + + def default_get(self, cr, uid, fields=None, context=None): + if context is None: + context = {} + if fields is None: + fields = {} + + result = {} + + if 'dont_compute_virtual_attributes' not in context: + module_proxy = self.pool.get('ir.module.module') + module_ids = module_proxy.search(cr, uid, [], context=context) + for module in module_proxy.browse(cr, uid, module_ids, context=context): + result['module_%d' % (module.id,)] = module.state == 'installed' + + cat_proxy = self.pool.get('ir.module.category') + cat_ids = cat_proxy.search(cr, uid, [], context=context) + for cat in cat_proxy.browse(cr, uid, cat_ids, context=context): + m = DEFAULT_MODULES.get(cat.name,[]) + r = module_proxy.search(cr, uid, [('state','=','installed'),('name','in',m)]) + result['category_%d' % (cat.id,)] = bool(r) + + return result + + def fields_view_get(self, cr, uid, view_id=None, view_type='from', context=None, toolbar=False, submenu=False): + def in_extended_view_group(cr, uid, context=None): + try: + model, group_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, 'base', 'group_extended') + except ValueError: + return False + return group_id in self.pool.get('res.users').read(cr, uid, uid, ['groups_id'], context=context)['groups_id'] + + result = super(base_setup_installer, self).fields_view_get(cr, uid, view_id, view_type, context, toolbar, submenu) + + module_category_proxy = self.pool.get('ir.module.category') + domain = [('parent_id', '=', False), + ('name', '!=', 'Uncategorized'), + ('visible', '=', True)] + module_category_ids = module_category_proxy.search(cr, uid, domain, context=context, order='sequence asc') + + arch = ['
' % _('Automatic Base Setup')] + arch.append('' % _('Install Applications')) + module_proxy = self.pool.get('ir.module.module') + + extended_view = in_extended_view_group(cr, uid, context=context) + + for module_category in module_category_proxy.browse(cr, uid, module_category_ids, context=context): + domain = [('category_id', '=', module_category.id)] + if not extended_view: + domain.append(('complexity', '!=', 'expert')) + + modules = module_proxy.browse(cr, uid, module_proxy.search(cr, uid, domain, context=context), context=context) + if not modules: + continue + + m = DEFAULT_MODULES.get(module_category.name, []) + r = module_proxy.search(cr, uid, [('state', '=', 'installed'),('name', 'in', m)], context=context) + readonly = bool(r) + + attributes = { + 'name' : 'category_%d' % (module_category.id,), + 'on_change' : 'on_change_%s_%d(category_%d)' % ('category', module_category.id, module_category.id,), + } + if readonly: + attributes['modifiers'] = simplejson.dumps({'readonly' : True}) + + arch.append("""""" % (" ".join(["%s='%s'" % (key, value,) + for key, value in attributes.iteritems()]),)) + + # Compute the modules to show + for module_category in module_category_proxy.browse(cr, uid, module_category_ids, context=context): + domain = [('category_id', '=', module_category.id)] + + if not extended_view: + domain.append(('complexity', '!=', 'expert')) + + default_modules = DEFAULT_MODULES.get(module_category.name, False) + if default_modules: + domain.append(('name', 'not in', default_modules)) + + modules = module_proxy.browse(cr, uid, module_proxy.search(cr, uid, domain, context=context), context=context) + + if not modules: + continue + + modifiers = { + 'invisible' : [('category_%d' % (module_category.id), '=', False)], + } + module_modifiers = dict(modifiers) + + arch.append("""""" % ( + cgi.escape(module_category.name), + simplejson.dumps(modifiers)) + ) + + for module in modules: + #module_modifiers['readonly'] = module.state == 'installed' + + arch.append("""""" % ( + module.id, + simplejson.dumps(module_modifiers)) + ) + + arch.append( + '' + '' + '