diff --git a/addons/account/report/account_balance.py b/addons/account/report/account_balance.py index 379e01cdf6f..64db67efea5 100644 --- a/addons/account/report/account_balance.py +++ b/addons/account/report/account_balance.py @@ -57,7 +57,7 @@ class account_balance(report_sxw.rml_parse): def get_periods(self, form): result='' - if form.has_key('periods'): + if form.has_key('periods') and form['periods'][0][2]: period_ids = ",".join([str(x) for x in form['periods'][0][2] if x]) self.cr.execute("select name from account_period where id in (%s)" % (period_ids)) res=self.cr.fetchall() diff --git a/addons/account/wizard/wizard_pay_invoice.py b/addons/account/wizard/wizard_pay_invoice.py index a87ba6047e2..2baba87e51d 100644 --- a/addons/account/wizard/wizard_pay_invoice.py +++ b/addons/account/wizard/wizard_pay_invoice.py @@ -1,7 +1,7 @@ # -*- encoding: utf-8 -*- ############################################################################## # -# OpenERP, Open Source Management Solution +# OpenERP, Open Source Management Solution # Copyright (C) 2004-2009 Tiny SPRL (). All Rights Reserved # $Id$ # @@ -111,8 +111,8 @@ def _get_period(self, cr, uid, data, context={}): if len(ids): period_id = ids[0] invoice = pool.get('account.invoice').browse(cr, uid, data['id'], context) - if invoice.state == 'draft': - raise wizard.except_wizard(_('Error !'), _('Can not pay draft invoice.')) + if invoice.state in ['draft', 'proforma2', 'cancel']: + raise wizard.except_wizard(_('Error !'), _('Can not pay draft/proforma/cancel invoice.')) return { 'period_id': period_id, 'amount': invoice.residual, diff --git a/addons/base_vat/partner.py b/addons/base_vat/partner.py index 7abf5a7df63..fc05376a2ce 100644 --- a/addons/base_vat/partner.py +++ b/addons/base_vat/partner.py @@ -47,7 +47,8 @@ class res_partner(osv.osv): continue #FIXME return False? empty vat numbre is invalid? vat_country, vat_number = partner.vat[:2].lower(), partner.vat[2:] - + if vat_number.find(' ') != -1: + return False check = getattr(self, 'check_vat_' + vat_country, lambda vn: False) if not check(vat_number): return False diff --git a/addons/hr_contract/hr_contract.py b/addons/hr_contract/hr_contract.py index c8b43897c6c..424819a062f 100644 --- a/addons/hr_contract/hr_contract.py +++ b/addons/hr_contract/hr_contract.py @@ -39,11 +39,8 @@ class hr_employee(osv.osv): _inherit = "hr.employee" _columns = { 'manager' : fields.boolean('Manager'), - 'soc_security' : fields.char('Social security number', size=50, select=True), 'medic_exam' : fields.date('Medical examination date'), 'audiens_num' : fields.char('AUDIENS Number', size=30), - 'nationality' : fields.many2one('res.country', 'Nationality'), - 'birth_date' : fields.date('Birth Date'), 'place_of_birth' : fields.char('Place of Birth', size=30), 'marital_status' : fields.many2one('hr.employee.marital.status', 'Marital Status'), 'children' : fields.integer('Number of children'), diff --git a/addons/hr_contract/hr_contract_view.xml b/addons/hr_contract/hr_contract_view.xml index 01a9f8e20ed..1b512f52fcf 100644 --- a/addons/hr_contract/hr_contract_view.xml +++ b/addons/hr_contract/hr_contract_view.xml @@ -109,11 +109,8 @@ - - - diff --git a/addons/l10n_fr/l10n_fr_pcg_account_report.xml b/addons/l10n_fr/l10n_fr_pcg_account_report.xml index 22606850ca6..3e195d4f8f4 100644 --- a/addons/l10n_fr/l10n_fr_pcg_account_report.xml +++ b/addons/l10n_fr/l10n_fr_pcg_account_report.xml @@ -55,17 +55,6 @@ - - - - - - - - - - - diff --git a/addons/mrp/mrp_report.xml b/addons/mrp/mrp_report.xml index eb97477f687..ee552abad59 100644 --- a/addons/mrp/mrp_report.xml +++ b/addons/mrp/mrp_report.xml @@ -1,9 +1,9 @@ - + - + - + diff --git a/addons/mrp/report/bom_structure.rml b/addons/mrp/report/bom_structure.rml index 349e9379ad3..7601e490eec 100644 --- a/addons/mrp/report/bom_structure.rml +++ b/addons/mrp/report/bom_structure.rml @@ -1,3 +1,138 @@ -BOM Structure
[[ repeatIn(objects, 'o') ]]BOMProduct NameQuantityUoMCode[[ o.name ]][[ o.product_id.name ]][[ o.product_qty ]][[ o.product_uom.name ]][[ o.code ]][[ repeatIn(o.bom_lines, 'l') ]]- [[ l.name ]][[ l.product_id.name ]][[ l.product_qty ]][[ l.product_uom.name ]][[ l.code ]]
- + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + BOM Structure +
+ [[ repeatIn(objects, 'o') ]] + + + + BOM + + + Product Name + + + Quantity + + + Code + + + + + + + [[ o.name ]] + + + [[ o.product_id.name ]] + + + [[ o.product_qty ]] [[ o.product_uom.name ]] + + + [[ o.code ]] + + + +
+ [[ repeatIn(o.bom_lines, 'l') ]] + + + + - [[ l.name ]] + + + [[ l.product_id.name ]] + + + [[ l.product_qty ]] [[ l.product_uom.name ]] + + + [[ l.code ]] + + + + + + +
+
+
+
diff --git a/addons/report_sale/report_sale_view.xml b/addons/report_sale/report_sale_view.xml index eba8fe71223..1cfb0509ae1 100644 --- a/addons/report_sale/report_sale_view.xml +++ b/addons/report_sale/report_sale_view.xml @@ -149,9 +149,28 @@ [('date_order','>=',time.strftime('%Y-%m-01')),('state','<>','draft'),('state','<>','cancel')]
+ + + sale.order.dashboard.graph + sale.order + graph + + + + + + + - - - + + Sales by State + sale.order + form + graph,tree + + [('state','<>','done')] + + +