From 36ed0af6068757b93cc21116bbfa2fe56915af5e Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 17 Mar 2010 17:00:22 +0530 Subject: [PATCH 001/188] [ADD]:Added SQL view for Analyatic Accounts. bzr revid: apa@tinyerp.com-20100317113022-idk8rcm184pqcizq --- addons/account/__terp__.py | 1 + addons/account/report/__init__.py | 1 + .../account/report/account_analytic_report.py | 84 ++++++++++++++ .../report/account_analytic_report_view.xml | 108 ++++++++++++++++++ 4 files changed, 194 insertions(+) create mode 100644 addons/account/report/account_analytic_report.py create mode 100644 addons/account/report/account_analytic_report_view.xml diff --git a/addons/account/__terp__.py b/addons/account/__terp__.py index 3fabb495ba1..ac20eee16b5 100644 --- a/addons/account/__terp__.py +++ b/addons/account/__terp__.py @@ -63,6 +63,7 @@ 'account_installer.xml', 'report/account_invoice_report_view.xml', 'report/account_report_view.xml', + 'report/account_analytic_report_view.xml', ], 'demo_xml': [ #'demo/price_accuracy00.yml', diff --git a/addons/account/report/__init__.py b/addons/account/report/__init__.py index 71f612e0329..09ff866d1a8 100644 --- a/addons/account/report/__init__.py +++ b/addons/account/report/__init__.py @@ -36,6 +36,7 @@ import account_balance_landscape import compare_account_balance import account_invoice_report import account_report +import account_analytic_report # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/account/report/account_analytic_report.py b/addons/account/report/account_analytic_report.py new file mode 100644 index 00000000000..6f08bd193f2 --- /dev/null +++ b/addons/account/report/account_analytic_report.py @@ -0,0 +1,84 @@ +# -*- 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 . +# +############################################################################## + +import tools +from osv import fields,osv + +class analytic_report(osv.osv): + _name = "analytic.report" + _description = "Analytic Accounts Statistics" + _auto = False + _columns = { + 'date_start': fields.date('Date Start', readonly=True), + 'date_end': fields.date('Date End',readonly=True), + 'name' : fields.char('Account', size=128, readonly=True), + 'partner_id' : fields.many2one('res.partner', 'Associated Partner',readonly=True), + 'journal_id' : fields.many2one('account.analytic.journal', 'Analytic Journal', readonly=True), + 'parent_id': fields.many2one('account.analytic.account', 'Parent Analytic Account', readonly=True), + 'user_id' : fields.many2one('res.users', 'Account Manager',readonly=True), + 'product_id' : fields.many2one('product.product', 'Product',readonly=True), + 'quantity': fields.float('Quantity',readonly=True), + 'debit' : fields.float('Debit',readonly=True), + 'credit' : fields.float('Credit',readonly=True), + 'balance' : fields.float('Balance',readonly=True), + 'year': fields.char('Year', size=4, readonly=True), + 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), + ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), + ('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True), + 'state': fields.selection([('draft','Draft'), + ('open','Open'), + ('pending','Pending'), + ('cancelled', 'Cancelled'), + ('close','Close'), + ('template', 'Template')], + 'State', readonly=True), + } + _order = 'date_start desc' + def init(self, cr): + tools.drop_view_if_exists(cr, 'analytic_report') + cr.execute(""" + create or replace view analytic_report as ( + select + min(s.id) as id, + to_char(s.create_date, 'YYYY') as year, + to_char(s.create_date, 'MM') as month, + l.journal_id, + l.product_id, + s.parent_id, + s.date_start, + s.date as date_end, + s.user_id, + s.name, + s.partner_id, + s.quantity, + s.debit, + s.credit, + s.balance, + count(*) as nbr, + s.state + from account_analytic_account s + left join account_analytic_line l on (s.id=l.account_id) + GROUP BY s.create_date,s.state,l.journal_id,s.name, + s.partner_id,s.date_start,s.date,s.user_id,s.quantity, + s.debit,s.credit,s.balance,s.parent_id,l.product_id + ) + """) +analytic_report() diff --git a/addons/account/report/account_analytic_report_view.xml b/addons/account/report/account_analytic_report_view.xml new file mode 100644 index 00000000000..543b18aa6ad --- /dev/null +++ b/addons/account/report/account_analytic_report_view.xml @@ -0,0 +1,108 @@ + + + + + analytic.report.tree + analytic.report + tree + + + + + + + + + + + + + + + + + + + + + + + analytic.report.search + analytic.report + search + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Analytic Accounts + analytic.report + form + tree + + + + + + + From bf233b4f1c52814b8fa2a5e14313e77f6b7d7c47 Mon Sep 17 00:00:00 2001 From: "RCH(Open ERP)" <> Date: Wed, 17 Mar 2010 17:11:00 +0530 Subject: [PATCH 002/188] [IMP] crm : modification in fundraising and opportunity reports, add group_operator=avg attribute in for probeblity field bzr revid: vir@tinyerp.com-20100317114100-3ndbw5m37y2hg7ri --- addons/crm/report/crm_fundraising_report.py | 8 ++++---- addons/crm/report/crm_opportunity_report.py | 16 ++++++++-------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/addons/crm/report/crm_fundraising_report.py b/addons/crm/report/crm_fundraising_report.py index a778223ca0c..2acbc475c9f 100644 --- a/addons/crm/report/crm_fundraising_report.py +++ b/addons/crm/report/crm_fundraising_report.py @@ -7,12 +7,12 @@ class crm_fundraising_report(osv.osv): _inherit = "crm.case.report" _columns = { 'categ_id': fields.many2one('crm.case.categ', 'Category', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.fundraising')]"), - 'probability': fields.float('Avg. Probability', readonly=True), + 'probability': fields.float('Avg. Probability', readonly=True ,group_operator='avg'), 'amount_revenue': fields.float('Est.Revenue', readonly=True), 'amount_revenue_prob': fields.float('Est. Rev*Prob.', readonly=True), 'delay_close': fields.char('Delay to close', size=20, readonly=True), - 'partner_id': fields.many2one('res.partner', 'Partner'), - 'company_id': fields.many2one('res.company','Company'), + 'partner_id': fields.many2one('res.partner', 'Partner'), + 'company_id': fields.many2one('res.company','Company'), } def init(self, cr): tools.drop_view_if_exists(cr, 'crm_fundraising_report') @@ -32,7 +32,7 @@ class crm_fundraising_report(osv.osv): 0 as avg_answers, 0.0 as perc_done, 0.0 as perc_cancel, - sum(planned_revenue) as amount_revenue, + sum(planned_revenue) as amount_revenue, sum(planned_revenue*probability)::decimal(16,2) as amount_revenue_prob, avg(probability)::decimal(16,2) as probability, to_char(avg(date_closed-c.create_date), 'DD"d" HH24:MI:SS') as delay_close diff --git a/addons/crm/report/crm_opportunity_report.py b/addons/crm/report/crm_opportunity_report.py index 5aa2a91e555..c9e9e69e815 100644 --- a/addons/crm/report/crm_opportunity_report.py +++ b/addons/crm/report/crm_opportunity_report.py @@ -2,19 +2,19 @@ from osv import fields,osv import tools class crm_opportunity_report(osv.osv): - _name = "crm.opportunity.report" + _name = "crm.opportunity.report" _auto = False - _inherit = "crm.case.report" - + _inherit = "crm.case.report" + _columns = { - 'probability': fields.float('Avg. Probability', readonly=True), - 'amount_revenue': fields.float('Est.Revenue', readonly=True), + 'probability': fields.float('Avg. Probability', readonly=True,group_operator='avg'), + 'amount_revenue': fields.float('Est.Revenue', readonly=True), 'amount_revenue_prob': fields.float('Est. Rev*Prob.', readonly=True), 'delay_close': fields.char('Delay to close', size=20, readonly=True), 'categ_id': fields.many2one('crm.case.categ', 'Category', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.opportunity')]", readonly=True), 'stage_id':fields.many2one('crm.case.stage', 'Stage', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.opportunity')]", readonly=True), - 'partner_id': fields.many2one('res.partner', 'Partner',readonly=True), - 'company_id': fields.many2one('res.company', 'Company',readonly=True), + 'partner_id': fields.many2one('res.partner', 'Partner',readonly=True), + 'company_id': fields.many2one('res.company', 'Company',readonly=True), } def init(self, cr): tools.drop_view_if_exists(cr, 'crm_opportunity_report') @@ -35,7 +35,7 @@ class crm_opportunity_report(osv.osv): 0 as avg_answers, 0.0 as perc_done, 0.0 as perc_cancel, - sum(planned_revenue) as amount_revenue, + sum(planned_revenue) as amount_revenue, sum((planned_revenue*probability)/100.0)::decimal(16,2) as amount_revenue_prob, avg(probability)::decimal(16,2) as probability, to_char(avg(date_closed-c.create_date), 'DD"d" HH24:MI:SS') as delay_close From 512000f92faa466919f148dfc9f4944add963888 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 17 Mar 2010 17:26:13 +0530 Subject: [PATCH 003/188] [IMP]:improved code for Analytic Account report. bzr revid: apa@tinyerp.com-20100317115613-v06pywjyfeot9bc2 --- addons/analytic/project.py | 44 +++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/addons/analytic/project.py b/addons/analytic/project.py index e9558f7a101..52c61cd4288 100644 --- a/addons/analytic/project.py +++ b/addons/analytic/project.py @@ -63,13 +63,13 @@ class account_analytic_account(osv.osv): res = {} ids2 = self.search(cr, uid, [('parent_id', 'child_of', ids)]) acc_set = ",".join(map(str, ids2)) - + for i in ids: res.setdefault(i,0.0) - + if not ids2: return res - + where_date = '' if context.get('from_date',False): where_date += " AND l.date >= '" + context['from_date'] + "'" @@ -78,18 +78,18 @@ class account_analytic_account(osv.osv): cr.execute("SELECT a.id, COALESCE(SUM(l.amount_currency),0) FROM account_analytic_account a LEFT JOIN account_analytic_line l ON (a.id=l.account_id "+where_date+") WHERE l.amount_currency<0 and a.id =ANY(%s) GROUP BY a.id",(ids2,)) r = dict(cr.fetchall()) return self._compute_currency_for_level_tree(cr, uid, ids, ids2, r, acc_set, context) - + def _debit_calc(self, cr, uid, ids, name, arg, context={}): res = {} ids2 = self.search(cr, uid, [('parent_id', 'child_of', ids)]) acc_set = ",".join(map(str, ids2)) - + for i in ids: res.setdefault(i,0.0) - + if not ids2: return res - + where_date = '' if context.get('from_date',False): where_date += " AND l.date >= '" + context['from_date'] + "'" @@ -98,48 +98,48 @@ class account_analytic_account(osv.osv): cr.execute("SELECT a.id, COALESCE(SUM(l.amount_currency),0) FROM account_analytic_account a LEFT JOIN account_analytic_line l ON (a.id=l.account_id "+where_date+") WHERE l.amount_currency>0 and a.id =ANY(%s) GROUP BY a.id" ,(ids2,)) r= dict(cr.fetchall()) return self._compute_currency_for_level_tree(cr, uid, ids, ids2, r, acc_set, context) - + def _balance_calc(self, cr, uid, ids, name, arg, context={}): res = {} ids2 = self.search(cr, uid, [('parent_id', 'child_of', ids)]) acc_set = ",".join(map(str, ids2)) - + for i in ids: res.setdefault(i,0.0) - + if not ids2: return res - + where_date = '' if context.get('from_date',False): where_date += " AND l.date >= '" + context['from_date'] + "'" if context.get('to_date',False): where_date += " AND l.date <= '" + context['to_date'] + "'" cr.execute("SELECT a.id, COALESCE(SUM(l.amount_currency),0) FROM account_analytic_account a LEFT JOIN account_analytic_line l ON (a.id=l.account_id "+where_date+") WHERE a.id =ANY(%s) GROUP BY a.id",(ids2,)) - + for account_id, sum in cr.fetchall(): res[account_id] = sum return self._compute_currency_for_level_tree(cr, uid, ids, ids2, res, acc_set, context) - + def _quantity_calc(self, cr, uid, ids, name, arg, context={}): #XXX must convert into one uom res = {} ids2 = self.search(cr, uid, [('parent_id', 'child_of', ids)]) acc_set = ",".join(map(str, ids2)) - + for i in ids: res.setdefault(i,0.0) - + if not ids2: return res - + where_date = '' if context.get('from_date',False): where_date += " AND l.date >= '" + context['from_date'] + "'" if context.get('to_date',False): where_date += " AND l.date <= '" + context['to_date'] + "'" - + cr.execute('SELECT a.id, COALESCE(SUM(l.unit_amount), 0) \ FROM account_analytic_account a \ LEFT JOIN account_analytic_line l ON (a.id = l.account_id ' + where_date + ') \ @@ -182,7 +182,7 @@ class account_analytic_account(osv.osv): def _get_account_currency(self, cr, uid, ids, field_name, arg, context={}): result=self._get_company_currency(cr, uid, ids, field_name, arg, context={}) return result - + _columns = { 'name' : fields.char('Account Name', size=128, required=True), 'complete_name': fields.function(_complete_name_calc, method=True, type='char', string='Full Account Name'), @@ -192,10 +192,10 @@ class account_analytic_account(osv.osv): 'parent_id': fields.many2one('account.analytic.account', 'Parent Analytic Account', select=2), 'child_ids': fields.one2many('account.analytic.account', 'parent_id', 'Child Accounts'), 'line_ids': fields.one2many('account.analytic.line', 'account_id', 'Analytic Entries'), - 'balance' : fields.function(_balance_calc, method=True, type='float', string='Balance'), - 'debit' : fields.function(_debit_calc, method=True, type='float', string='Debit'), - 'credit' : fields.function(_credit_calc, method=True, type='float', string='Credit'), - 'quantity': fields.function(_quantity_calc, method=True, type='float', string='Quantity'), + 'balance' : fields.function(_balance_calc, method=True, type='float', string='Balance',store=True), + 'debit' : fields.function(_debit_calc, method=True, type='float', string='Debit',store=True), + 'credit' : fields.function(_credit_calc, method=True, type='float', string='Credit',store=True), + 'quantity': fields.function(_quantity_calc, method=True, type='float', string='Quantity',store=True), 'quantity_max': fields.float('Maximum Quantity', help='Sets the higher limit of quantity of hours.'), 'partner_id' : fields.many2one('res.partner', 'Associated Partner'), 'contact_id' : fields.many2one('res.partner.address', 'Contact'), From 21690f0ceaa4cbc5b848db93672aff6a06ddd95c Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Thu, 18 Mar 2010 12:44:46 +0530 Subject: [PATCH 004/188] [MOD] Removed unused dependancy, and changed the references bzr revid: vir@tinyerp.com-20100318071446-x35jzi3bc67ytpvg --- addons/board_account/__terp__.py | 10 +++++----- addons/board_account/board_account_view.xml | 2 +- addons/board_crm_configuration/__terp__.py | 2 +- addons/board_document/__terp__.py | 6 +++--- addons/board_document/board_document_view.xml | 14 +++++++------- addons/board_hr/board_hr_view.xml | 4 ++-- addons/board_project/__terp__.py | 3 --- .../board_project/board_project_manager_view.xml | 15 +++++++-------- 8 files changed, 26 insertions(+), 30 deletions(-) diff --git a/addons/board_account/__terp__.py b/addons/board_account/__terp__.py index 82ecb16fa37..b22221ae1e3 100644 --- a/addons/board_account/__terp__.py +++ b/addons/board_account/__terp__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- ############################################################################## -# +# # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (). # @@ -15,7 +15,7 @@ # 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 . +# along with this program. If not, see . # ############################################################################## @@ -38,9 +38,9 @@ 'account', 'hr_timesheet_invoice', 'board', - 'report_account', - 'report_analytic', - 'report_analytic_line', +# 'report_account', +# 'report_analytic', +# 'report_analytic_line', 'account_report' ], 'update_xml': ['board_account_view.xml'], diff --git a/addons/board_account/board_account_view.xml b/addons/board_account/board_account_view.xml index 068e18bcf02..fc0ee491f31 100644 --- a/addons/board_account/board_account_view.xml +++ b/addons/board_account/board_account_view.xml @@ -41,7 +41,7 @@ - + diff --git a/addons/board_crm_configuration/__terp__.py b/addons/board_crm_configuration/__terp__.py index 3c303ee2d1c..09bd6e25bc1 100644 --- a/addons/board_crm_configuration/__terp__.py +++ b/addons/board_crm_configuration/__terp__.py @@ -34,7 +34,7 @@ This module implements a dashboard for CRM that includes: * Jobs Tracking (graph) """, 'author': 'Tiny', - 'depends': ['board', 'crm', 'report_crm'], + 'depends': ['board', 'crm'], 'update_xml': ['board_crm_statistical_view.xml', 'board_crm_view.xml'], 'demo_xml': ['board_crm_demo.xml'], 'installable': True, diff --git a/addons/board_document/__terp__.py b/addons/board_document/__terp__.py index 0ba8552fb51..112ab335db7 100644 --- a/addons/board_document/__terp__.py +++ b/addons/board_document/__terp__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- ############################################################################## -# +# # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (). # @@ -15,7 +15,7 @@ # 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 . +# along with this program. If not, see . # ############################################################################## @@ -26,7 +26,7 @@ 'category': 'Board/Document', 'description': """ This module implements a dashboard for Document """, 'author': 'Tiny', - 'depends': ['board', 'document', 'report_document'], + 'depends': ['board', 'document'], 'update_xml': ['board_document_view.xml'], 'demo_xml': ['board_document_demo.xml'], 'installable': True, diff --git a/addons/board_document/board_document_view.xml b/addons/board_document/board_document_view.xml index a35e6f9efe7..57bacb00226 100644 --- a/addons/board_document/board_document_view.xml +++ b/addons/board_document/board_document_view.xml @@ -15,24 +15,24 @@ @@ -75,19 +75,19 @@ diff --git a/addons/board_hr/board_hr_view.xml b/addons/board_hr/board_hr_view.xml index 2e84eff0749..0d8fb63e8ee 100644 --- a/addons/board_hr/board_hr_view.xml +++ b/addons/board_hr/board_hr_view.xml @@ -28,10 +28,10 @@ My Leaves ir.actions.act_window - hr.holidays.per.user + hr.holidays form tree,form - + diff --git a/addons/board_project/__terp__.py b/addons/board_project/__terp__.py index 92a8aeb1518..b6ab4ba25b7 100644 --- a/addons/board_project/__terp__.py +++ b/addons/board_project/__terp__.py @@ -34,11 +34,8 @@ This module implements a dashboard for project member that includes: 'author': 'Tiny', 'depends': [ 'project', - 'report_timesheet', 'board', 'project_planning', - 'report_analytic_line', - 'report_task', 'hr_timesheet_sheet', 'project_issue', 'resource' diff --git a/addons/board_project/board_project_manager_view.xml b/addons/board_project/board_project_manager_view.xml index 893a3a7df68..7151d37d790 100644 --- a/addons/board_project/board_project_manager_view.xml +++ b/addons/board_project/board_project_manager_view.xml @@ -13,13 +13,13 @@ - - Pipeline of tasks - report.task.user.pipeline.open - form - graph,tree - [('user_id','in',department_users_get())] - + + + + + + + hr.timesheet.sheet.tree.simplified.board @@ -66,7 +66,6 @@ - From e3166d455d636765426db5861bd938930d66ce46 Mon Sep 17 00:00:00 2001 From: "apa,rch" <> Date: Thu, 18 Mar 2010 14:59:45 +0530 Subject: [PATCH 005/188] [IMP]:Improved dashboard for crm.Commented nonused report field in cmm reports. bzr revid: apa@tinyerp.com-20100318092945-ovhboctc9q7huofu --- .../board_crm_statistical_view.xml | 12 ++++----- .../board_crm_view.xml | 12 ++++----- addons/crm/report/crm_lead_report.py | 14 ++++++++-- addons/crm/report/crm_opportunity_report.py | 12 ++++++++- addons/crm/report/crm_report.py | 26 +++++++++---------- 5 files changed, 47 insertions(+), 29 deletions(-) diff --git a/addons/board_crm_configuration/board_crm_statistical_view.xml b/addons/board_crm_configuration/board_crm_statistical_view.xml index 8dbe05735f0..3a320b64e0d 100644 --- a/addons/board_crm_configuration/board_crm_statistical_view.xml +++ b/addons/board_crm_configuration/board_crm_statistical_view.xml @@ -6,40 +6,38 @@ --> Leads By Stage - Graph - report.crm.lead.section.stage + crm.lead.report graph - report.crm.opportunity.categ.graph - report.crm.opportunity.categ + crm.opportunity.report graph - - report.crm.lead.section.stage + crm.lead.report form graph,tree,form @@ -48,7 +46,7 @@ CRM Configuration - + crm.opportunity.user.graph1 - report.crm.opportunity.user + crm.opportunity.report graph @@ -32,7 +32,7 @@ [('user_id','=',uid),('state','!=','pending'),('state','!=','cancel')] - + - report.crm.lead.section.stage + crm.lead.report form graph,tree,form @@ -49,7 +49,7 @@ - report.crm.opportunity.user + crm.opportunity.report form graph,tree,form @@ -78,7 +78,7 @@ name="%(act_my_meetings)d" height="150" colspan="4"/> - + Date: Thu, 18 Mar 2010 15:30:28 +0530 Subject: [PATCH 006/188] [IMP]:improved hr_holidays report. bzr revid: apa@tinyerp.com-20100318100028-m8rbrahaizuwbi6y --- addons/hr_holidays/__terp__.py | 3 + addons/hr_holidays/hr_holidays_report.xml | 71 ----------------- addons/hr_holidays/report/__init__.py | 5 +- .../hr_holidays/report/available_holidays.py | 32 ++++++-- .../report/available_holidays_view.xml | 77 +++++++++++++++++++ .../hr_holidays/report/hr_holidays_report.py | 1 + .../report/hr_holidays_report_view.xml | 2 +- 7 files changed, 111 insertions(+), 80 deletions(-) create mode 100644 addons/hr_holidays/report/available_holidays_view.xml diff --git a/addons/hr_holidays/__terp__.py b/addons/hr_holidays/__terp__.py index 26dc78675cc..4f7c736425c 100644 --- a/addons/hr_holidays/__terp__.py +++ b/addons/hr_holidays/__terp__.py @@ -55,6 +55,9 @@ 'hr_view.xml', 'hr_holidays_wizard.xml', 'hr_holidays_report.xml', + 'report/hr_holidays_report_view.xml', + 'report/available_holidays_view.xml' + #'process/hr_holidays_process.xml' ], 'demo_xml': [], diff --git a/addons/hr_holidays/hr_holidays_report.xml b/addons/hr_holidays/hr_holidays_report.xml index 66669bd2f51..23d1e1a75bf 100644 --- a/addons/hr_holidays/hr_holidays_report.xml +++ b/addons/hr_holidays/hr_holidays_report.xml @@ -9,77 +9,6 @@ auto="False" menu="False"/> - - - - - - - hr.holidays.report.tree - hr.holidays.report - tree - - - - - - - - - - - hr.holidays.report.form - hr.holidays.report - form - - - - - - - - - - hr.holiday.report.graph - hr.holidays.report - graph - - - - - - - - - - - Available Holidays - hr.holidays.report - form - tree,graph - - - - - - - tree - - - - - - - - graph - - - - - - - - diff --git a/addons/hr_holidays/report/__init__.py b/addons/hr_holidays/report/__init__.py index 00783721fe3..a617b4b6d8a 100644 --- a/addons/hr_holidays/report/__init__.py +++ b/addons/hr_holidays/report/__init__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- ############################################################################## -# +# # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (). # @@ -15,11 +15,12 @@ # 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 . +# along with this program. If not, see . # ############################################################################## import holidays_summary_report import available_holidays +import hr_holidays_report # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/hr_holidays/report/available_holidays.py b/addons/hr_holidays/report/available_holidays.py index 259aea0dec9..2b9441ccddb 100644 --- a/addons/hr_holidays/report/available_holidays.py +++ b/addons/hr_holidays/report/available_holidays.py @@ -1,20 +1,40 @@ +# -*- 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 osv import fields,osv import tools -class hr_holidays_report(osv.osv): - _name = "hr.holidays.report" +class available_holidays_report(osv.osv): + _name = "available.holidays.report" _auto = False _columns = { 'employee_id': fields.many2one ('hr.employee', 'Employee', readonly=True), 'holiday_status_id': fields.many2one('hr.holidays.status', 'Leave Type', readonly=True), # 'max_leave': fields.float('Allocated Leaves', readonly=True), # 'taken_leaves': fields.float('Taken Leaves', readonly=True), - 'remaining_leave': fields.float('Remaining Leaves',readonly=True), + 'remaining_leave': fields.float('Remaining Leaves',readonly=True), } def init(self, cr): - tools.drop_view_if_exists(cr, 'hr_holidays_report') + tools.drop_view_if_exists(cr, 'available_holidays_report') cr.execute(""" - create or replace view hr_holidays_report as ( + create or replace view available_holidays_report as ( select min(h.id) as id, h.employee_id as employee_id, @@ -28,6 +48,6 @@ class hr_holidays_report(osv.osv): and s.active <> 'f' group by h.holiday_status_id, h.employee_id )""") -hr_holidays_report() +available_holidays_report() # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/hr_holidays/report/available_holidays_view.xml b/addons/hr_holidays/report/available_holidays_view.xml new file mode 100644 index 00000000000..bfd009361ee --- /dev/null +++ b/addons/hr_holidays/report/available_holidays_view.xml @@ -0,0 +1,77 @@ + + + + + + + + available.holidays.report.tree + available.holidays.report + tree + + + + + + + + + + + available.holidays.report.form + available.holidays.report + form + + + + + + + + + + available.holidays.report.graph + available.holidays.report + graph + + + + + + + + + + + + + Available Holidays + available.holidays.report + form + tree,graph + + + + + + + tree + + + + + + + + graph + + + + + + + + + + + diff --git a/addons/hr_holidays/report/hr_holidays_report.py b/addons/hr_holidays/report/hr_holidays_report.py index 59a0a361eeb..f9b41b638f1 100644 --- a/addons/hr_holidays/report/hr_holidays_report.py +++ b/addons/hr_holidays/report/hr_holidays_report.py @@ -63,6 +63,7 @@ class hr_holidays_report(osv.osv): s.state from hr_holidays s + where type='remove' group by s.create_date,s.state,s.date_from,s.date_to, s.number_of_days_temp,s.employee_id,s.user_id diff --git a/addons/hr_holidays/report/hr_holidays_report_view.xml b/addons/hr_holidays/report/hr_holidays_report_view.xml index 6a8d1461799..1d756986ded 100644 --- a/addons/hr_holidays/report/hr_holidays_report_view.xml +++ b/addons/hr_holidays/report/hr_holidays_report_view.xml @@ -81,7 +81,7 @@ - + From b94cba849fdd9cf696711c2349b2a3723b4f7bc9 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 18 Mar 2010 16:30:50 +0530 Subject: [PATCH 007/188] [IMP]:hr_holidays:Improved Available holidays report. bzr revid: apa@tinyerp.com-20100318110050-lmkbwstxy99tx383 --- .../hr_holidays/report/available_holidays.py | 37 +++++++++++--- .../report/available_holidays_view.xml | 50 ++++++++++++++++++- 2 files changed, 79 insertions(+), 8 deletions(-) diff --git a/addons/hr_holidays/report/available_holidays.py b/addons/hr_holidays/report/available_holidays.py index 2b9441ccddb..4a1972f1f7d 100644 --- a/addons/hr_holidays/report/available_holidays.py +++ b/addons/hr_holidays/report/available_holidays.py @@ -25,11 +25,17 @@ class available_holidays_report(osv.osv): _name = "available.holidays.report" _auto = False _columns = { + 'date': fields.datetime('Date', readonly=True), + 'year': fields.char('Year', size=4, readonly=True), + 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), + ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), + ('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True), 'employee_id': fields.many2one ('hr.employee', 'Employee', readonly=True), 'holiday_status_id': fields.many2one('hr.holidays.status', 'Leave Type', readonly=True), - # 'max_leave': fields.float('Allocated Leaves', readonly=True), -# 'taken_leaves': fields.float('Taken Leaves', readonly=True), + 'max_leave': fields.float('Allocated Leaves', readonly=True), + 'taken_leaves': fields.float('Taken Leaves', readonly=True), 'remaining_leave': fields.float('Remaining Leaves',readonly=True), + 'user_id':fields.many2one('res.users', 'User', readonly=True), } def init(self, cr): tools.drop_view_if_exists(cr, 'available_holidays_report') @@ -37,16 +43,33 @@ class available_holidays_report(osv.osv): create or replace view available_holidays_report as ( select min(h.id) as id, + date_trunc('day',h.create_date) as date, + to_char(s.create_date, 'YYYY') as year, + to_char(s.create_date, 'MM') as month, h.employee_id as employee_id, + h.user_id as user_id, + h.state as state, h.holiday_status_id as holiday_status_id, - sum(number_of_days) as remaining_leave - from - hr_holidays h + sum(number_of_days) as remaining_leave, + (select sum(number_of_days_temp) from hr_holidays + where type='remove' + and employee_id=h.employee_id + and holiday_status_id=h.holiday_status_id + and state='validate') as taken_leaves, + (select sum(number_of_days_temp) from hr_holidays + where type='add' + and employee_id=h.employee_id + and holiday_status_id=h.holiday_status_id + and state='validate') as max_leave + from hr_holidays h left join hr_holidays_status s on (s.id = h.holiday_status_id) - where h.state = 'validate' + where h.state='validate' and h.employee_id is not null and s.active <> 'f' - group by h.holiday_status_id, h.employee_id + group by h.holiday_status_id, h.employee_id, + date_trunc('day',h.create_date),to_char(s.create_date, 'YYYY'), + to_char(s.create_date, 'MM'),h.user_id,h.state + )""") available_holidays_report() diff --git a/addons/hr_holidays/report/available_holidays_view.xml b/addons/hr_holidays/report/available_holidays_view.xml index bfd009361ee..4587cc1f84a 100644 --- a/addons/hr_holidays/report/available_holidays_view.xml +++ b/addons/hr_holidays/report/available_holidays_view.xml @@ -12,7 +12,13 @@ + + + + + + @@ -42,6 +48,48 @@ + + available.holidays.report.search + available.holidays.report + search + + + + + + + + + + + + + + + + + + + + + + @@ -49,7 +97,7 @@ available.holidays.report form tree,graph - + From 3d8b6315b7b11cce52d0938b2977b7c261b52a99 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 18 Mar 2010 16:51:54 +0530 Subject: [PATCH 008/188] [IMP]:hr_holidays:Improved Leaves report. bzr revid: apa@tinyerp.com-20100318112154-n5m12958bo7z3tya --- addons/hr_holidays/report/available_holidays_view.xml | 9 +-------- addons/hr_holidays/report/hr_holidays_report_view.xml | 11 +++++++++-- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/addons/hr_holidays/report/available_holidays_view.xml b/addons/hr_holidays/report/available_holidays_view.xml index 4587cc1f84a..1155e21a33e 100644 --- a/addons/hr_holidays/report/available_holidays_view.xml +++ b/addons/hr_holidays/report/available_holidays_view.xml @@ -62,14 +62,7 @@ string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Leaves of this month"/> - + + + + From d1c818f1f1c2c2310b1b2eff79c5c8c61511f900 Mon Sep 17 00:00:00 2001 From: "RCH(Open ERP)" <> Date: Thu, 18 Mar 2010 16:55:02 +0530 Subject: [PATCH 009/188] [FIX] dashboard_warehouse problem of id bzr revid: vir@tinyerp.com-20100318112502-o62g2l712cxss5uk --- addons/stock/stock.py | 116 +++++++++++++++++++++--------------------- 1 file changed, 58 insertions(+), 58 deletions(-) diff --git a/addons/stock/stock.py b/addons/stock/stock.py index a403c141be4..57898b317e1 100644 --- a/addons/stock/stock.py +++ b/addons/stock/stock.py @@ -223,7 +223,7 @@ class stock_location(osv.osv): # Take the user company and pricetype price_type_id=self.pool.get('res.users').browse(cr,uid,uid).company_id.property_valuation_price_type.id pricetype=self.pool.get('product.price.type').browse(cr,uid,price_type_id) - + if not product_ids: product_ids = product_obj.search(cr, uid, []) @@ -254,10 +254,10 @@ class stock_location(osv.osv): continue product = products_by_id[product_id] quantity_total += qty[product_id] - + # Compute based on pricetype # Choose the right filed standard_price to read - amount_unit=product.price_get(pricetype.field, context)[product.id] + amount_unit=product.price_get(pricetype.field, context)[product.id] price = qty[product_id] * amount_unit # price = qty[product_id] * product.standard_price @@ -666,8 +666,8 @@ class stock_picking(osv.osv): if type in ('in_invoice', 'in_refund'): # Take the user company and pricetype price_type_id=self.pool.get('res.users').browse(cr,users,users).company_id.property_valuation_price_type.id - pricetype=self.pool.get('product.price.type').browse(cr,uid,price_type_id) - amount_unit=move_line.product_id.price_get(pricetype.field, context)[move_line.product_id.id] + pricetype=self.pool.get('product.price.type').browse(cr,uid,price_type_id) + amount_unit=move_line.product_id.price_get(pricetype.field, context)[move_line.product_id.id] return amount_unit else: return move_line.product_id.list_price @@ -1383,12 +1383,12 @@ class stock_move(osv.osv): # Base computation on valuation price type else: company_id=move.company_id.id - + pricetype=self.pool.get('product.price.type').browse(cr,uid,move.company_id.property_valuation_price_type.id) amount_unit=move.product_id.price_get(pricetype.field, context)[move.product_id.id] amount=amount_unit * q or 1.0 # amount = q * move.product_id.standard_price - + partner_id = False if move.picking_id: partner_id = move.picking_id.address_id and (move.picking_id.address_id.partner_id and move.picking_id.address_id.partner_id.id or False) or False @@ -1434,7 +1434,7 @@ class stock_move(osv.osv): raise osv.except_osv(_('UserError'), _('You can only delete draft moves.')) return super(stock_move, self).unlink( - cr, uid, ids, context=context) + cr, uid, ids, context=context) def _create_lot(self, cr, uid, ids, product_id, prefix=False): prodlot_obj = self.pool.get('stock.production.lot') @@ -1443,22 +1443,22 @@ class stock_move(osv.osv): if not sequence: raise wizard.except_wizard(_('Error!'), _('No production sequence defined')) prodlot_id = prodlot_obj.create(cr, uid, {'name': sequence, 'prefix': prefix}, {'product_id': product_id}) - prodlot = prodlot_obj.browse(cr, uid, prodlot_id) + prodlot = prodlot_obj.browse(cr, uid, prodlot_id) ref = ','.join(map(lambda x:str(x),ids)) if prodlot.ref: - ref = '%s, %s' % (prodlot.ref, ref) + ref = '%s, %s' % (prodlot.ref, ref) prodlot_obj.write(cr, uid, [prodlot_id], {'ref': ref}) return prodlot_id def split_lines(self, cr, uid, ids, quantity, split_by_qty=1, prefix=False, with_lot=True, context=None): - + if quantity <= 0: raise osv.except_osv(_('Warning!'), _('Please provide Proper Quantity !')) res = [] - for move in self.browse(cr, uid, ids): + for move in self.browse(cr, uid, ids): if split_by_qty <= 0 or quantity == 0: return res @@ -1470,8 +1470,8 @@ class stock_move(osv.osv): update_val = { 'product_qty': split_by_qty, 'product_uos_qty': uos_qty, - } - for idx in range(int(quantity//split_by_qty)): + } + for idx in range(int(quantity//split_by_qty)): if not idx and move.product_qty<=quantity: current_move = move.id else: @@ -1481,89 +1481,89 @@ class stock_move(osv.osv): update_val['prodlot_id'] = self._create_lot(cr, uid, [current_move], move.product_id.id) self.write(cr, uid, [current_move], update_val) - - - if quantity_rest > 0: - idx = int(quantity//split_by_qty) + + + if quantity_rest > 0: + idx = int(quantity//split_by_qty) update_val['product_qty'] = quantity_rest - update_val['product_uos_qty'] = uos_qty_rest - if not idx and move.product_qty<=quantity: - current_move = move.id + update_val['product_uos_qty'] = uos_qty_rest + if not idx and move.product_qty<=quantity: + current_move = move.id else: - current_move = self.copy(cr, uid, move.id, {'state': move.state}) - + current_move = self.copy(cr, uid, move.id, {'state': move.state}) + res.append(current_move) - - - if with_lot: + + + if with_lot: update_val['prodlot_id'] = self._create_lot(cr, uid, [current_move], move.product_id.id) self.write(cr, uid, [current_move], update_val) - return res + return res - def consume_moves(self, cr, uid, ids, quantity, location_id=False, location_dest_id=False, consume=True, context=None): + def consume_moves(self, cr, uid, ids, quantity, location_id=False, location_dest_id=False, consume=True, context=None): if not context: context = {} - + if quantity <= 0: raise osv.except_osv(_('Warning!'), _('Please provide Proper Quantity !')) - res = [] - for move in self.browse(cr, uid, ids, context=context): + res = [] + for move in self.browse(cr, uid, ids, context=context): move_qty = move.product_qty quantity_rest = move.product_qty - quantity_rest -= quantity + quantity_rest -= quantity uos_qty_rest = quantity_rest / move_qty * move.product_uos_qty if quantity_rest <= 0: - quantity_rest = 0 + quantity_rest = 0 uos_qty_rest = 0 quantity = move.product_qty - + uos_qty = quantity / move_qty * move.product_uos_qty - if quantity_rest > 0: + if quantity_rest > 0: default_val = { - 'product_qty': quantity, - 'product_uos_qty': uos_qty, - 'state': move.state, + 'product_qty': quantity, + 'product_uos_qty': uos_qty, + 'state': move.state, } if location_dest_id: - default_val.update({'location_dest_id': location_dest_id}) + default_val.update({'location_dest_id': location_dest_id}) if location_id: - default_val.update({'location_id': location_id}) - + default_val.update({'location_id': location_id}) + if move.product_id.track_production and location_id: res += self.split_lines(cr, uid, [move.id], quantity, split_by_qty=1, context=context) else: current_move = self.copy(cr, uid, move.id, default_val) res += [current_move] - update_val = {} + update_val = {} update_val['product_qty'] = quantity_rest - update_val['product_uos_qty'] = uos_qty_rest - self.write(cr, uid, [move.id], update_val) + update_val['product_uos_qty'] = uos_qty_rest + self.write(cr, uid, [move.id], update_val) - else: - quantity_rest = quantity + else: + quantity_rest = quantity uos_qty_rest = uos_qty - + if move.product_id.track_production and location_id: res += self.split_lines(cr, uid, [move.id], quantity_rest, split_by_qty=1, context=context) - else: - res += [move.id] - update_val = {} + else: + res += [move.id] + update_val = {} update_val['product_qty'] = quantity_rest update_val['product_uos_qty'] = uos_qty_rest if location_dest_id: - update_val.update({'location_dest_id': location_dest_id}) + update_val.update({'location_dest_id': location_dest_id}) if location_id: - update_val.update({'location_id': location_id}) + update_val.update({'location_id': location_id}) self.write(cr, uid, [move.id], update_val) if consume: - self.action_done(cr, uid, res) + self.action_done(cr, uid, res) return res def scrap_moves(self, cr, uid, ids, quantity, location_dest_id, context=None): @@ -1599,7 +1599,7 @@ class stock_inventory(osv.osv): move_line = [] for line in inv.inventory_line_id: pid = line.product_id.id - + # price = line.product_id.standard_price or 0.0 amount = self.pool.get('stock.location')._product_get(cr, uid, line.location_id.id, [pid], {'uom': line.product_uom.id})[pid] change = line.product_qty - amount @@ -1764,7 +1764,7 @@ class report_products_to_received_planned(osv.osv): tools.drop_view_if_exists(cr, 'report_products_to_received_planned') cr.execute(""" create or replace view report_products_to_received_planned as ( - select stock.date, min(stock.id), sum(stock.product_qty) as qty, 0 as planned_qty + select stock.date, min(stock.id) as id, sum(stock.product_qty) as qty, 0 as planned_qty from stock_picking picking inner join stock_move stock on picking.id = stock.picking_id and picking.type = 'in' @@ -1773,7 +1773,7 @@ class report_products_to_received_planned(osv.osv): union - select stock.date_planned, min(stock.id), 0 as actual_qty, sum(stock.product_qty) as planned_qty + select stock.date_planned, min(stock.id) as id, 0 as actual_qty, sum(stock.product_qty) as planned_qty from stock_picking picking inner join stock_move stock on picking.id = stock.picking_id and picking.type = 'in' @@ -1798,7 +1798,7 @@ class report_delivery_products_planned(osv.osv): tools.drop_view_if_exists(cr, 'report_delivery_products_planned') cr.execute(""" create or replace view report_delivery_products_planned as ( - select stock.date, min(stock.id), sum(stock.product_qty) as qty, 0 as planned_qty + select stock.date, min(stock.id) as id, sum(stock.product_qty) as qty, 0 as planned_qty from stock_picking picking inner join stock_move stock on picking.id = stock.picking_id and picking.type = 'out' @@ -1807,7 +1807,7 @@ class report_delivery_products_planned(osv.osv): union - select stock.date_planned, min(stock.id), 0 as actual_qty, sum(stock.product_qty) as planned_qty + select stock.date_planned, min(stock.id) as id, 0 as actual_qty, sum(stock.product_qty) as planned_qty from stock_picking picking inner join stock_move stock on picking.id = stock.picking_id and picking.type = 'out' From 13608a1123b5b4f7fbe291b12c87ebf67a4af67b Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 18 Mar 2010 18:59:37 +0530 Subject: [PATCH 010/188] [IMP]:crm:Commented unused fields in reports. bzr revid: apa@tinyerp.com-20100318132937-71yx45inrei4o48j --- addons/crm/report/crm_lead_report.py | 6 +++--- addons/crm/report/crm_opportunity_report.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/addons/crm/report/crm_lead_report.py b/addons/crm/report/crm_lead_report.py index 1b7ad8c3c05..f07f4618786 100644 --- a/addons/crm/report/crm_lead_report.py +++ b/addons/crm/report/crm_lead_report.py @@ -18,9 +18,9 @@ class crm_lead_report(osv.osv): 'categ_id': fields.many2one('crm.case.categ', 'Category', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.lead')]" ,readonly=True), 'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.lead')]", readonly=True), 'partner_id': fields.many2one('res.partner', 'Partner' ,readonly=True), - 'company_id': fields.many2one('res.company','Company',readonly=True), - 'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True), - 'user_id': fields.many2one('res.user', 'Company',readonly=True), +# 'company_id': fields.many2one('res.company','Company',readonly=True), +# 'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True), +# 'user_id': fields.many2one('res.user', 'Company',readonly=True), } def init(self, cr): tools.drop_view_if_exists(cr, 'crm_lead_report') diff --git a/addons/crm/report/crm_opportunity_report.py b/addons/crm/report/crm_opportunity_report.py index 02f71e845ba..b3753b9bcc4 100644 --- a/addons/crm/report/crm_opportunity_report.py +++ b/addons/crm/report/crm_opportunity_report.py @@ -22,9 +22,9 @@ class crm_opportunity_report(osv.osv): 'categ_id': fields.many2one('crm.case.categ', 'Category', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.opportunity')]", readonly=True), 'stage_id':fields.many2one('crm.case.stage', 'Stage', domain="[('section_id','=',section_id),('object_id.model', '=', 'crm.opportunity')]", readonly=True), 'partner_id': fields.many2one('res.partner', 'Partner',readonly=True), - 'company_id': fields.many2one('res.company', 'Company',readonly=True), - 'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True), - 'user_id': fields.many2one('res.user', 'Company',readonly=True), +# 'company_id': fields.many2one('res.company', 'Company',readonly=True), +# 'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True), +# 'user_id': fields.many2one('res.user', 'Company',readonly=True), } def init(self, cr): tools.drop_view_if_exists(cr, 'crm_opportunity_report') From 3a6f32f3bcbf27eb8f03468e6c0daa4732a18ab8 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Fri, 19 Mar 2010 12:55:08 +0530 Subject: [PATCH 011/188] [IMP]:hr_holidays:improved available holidays report. bzr revid: apa@tinyerp.com-20100319072508-8hy66dws4vlrs0pi --- addons/hr_holidays/report/available_holidays_view.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/hr_holidays/report/available_holidays_view.xml b/addons/hr_holidays/report/available_holidays_view.xml index 1155e21a33e..80e9cf3220b 100644 --- a/addons/hr_holidays/report/available_holidays_view.xml +++ b/addons/hr_holidays/report/available_holidays_view.xml @@ -75,6 +75,7 @@ + From 2e5dac670c8b985f5751323f4739fab4b0da55ca Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Fri, 19 Mar 2010 14:37:40 +0530 Subject: [PATCH 012/188] [IMP]:improved Analytic report as jni sir told me. bzr revid: apa@tinyerp.com-20100319090740-d6ger1w4ci28isca --- addons/account/report/account_analytic_report.py | 2 +- addons/account/report/account_analytic_report_view.xml | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/account/report/account_analytic_report.py b/addons/account/report/account_analytic_report.py index 6f08bd193f2..45057d950bd 100644 --- a/addons/account/report/account_analytic_report.py +++ b/addons/account/report/account_analytic_report.py @@ -29,7 +29,7 @@ class analytic_report(osv.osv): _columns = { 'date_start': fields.date('Date Start', readonly=True), 'date_end': fields.date('Date End',readonly=True), - 'name' : fields.char('Account', size=128, readonly=True), + 'name' : fields.char('Analytic Account', size=128, readonly=True), 'partner_id' : fields.many2one('res.partner', 'Associated Partner',readonly=True), 'journal_id' : fields.many2one('account.analytic.journal', 'Analytic Journal', readonly=True), 'parent_id': fields.many2one('account.analytic.account', 'Parent Analytic Account', readonly=True), diff --git a/addons/account/report/account_analytic_report_view.xml b/addons/account/report/account_analytic_report_view.xml index 543b18aa6ad..db5b669dcfa 100644 --- a/addons/account/report/account_analytic_report_view.xml +++ b/addons/account/report/account_analytic_report_view.xml @@ -7,11 +7,11 @@ tree - + - + @@ -83,8 +83,8 @@ - - + + From b5190402af3e16c94f768d3eb622744784c86843 Mon Sep 17 00:00:00 2001 From: RCH <> Date: Tue, 23 Mar 2010 15:02:53 +0530 Subject: [PATCH 013/188] [IMP]:project:improved report. bzr revid: apa@tinyerp.com-20100323093253-3uvx1s1c9a77p4bl --- .../report/project_issue_report_view.xml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/addons/project_issue/report/project_issue_report_view.xml b/addons/project_issue/report/project_issue_report_view.xml index 72d665cdff0..2f7886670c2 100644 --- a/addons/project_issue/report/project_issue_report_view.xml +++ b/addons/project_issue/report/project_issue_report_view.xml @@ -8,22 +8,22 @@ tree - - - + + + - - + + - - - - + + + + From e9b7e0d3c9cc6331b726f03863690a6b65023f37 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 25 Mar 2010 12:32:47 +0530 Subject: [PATCH 014/188] [IMP]:account,hr_evaluation,hr_expense,hr_holidays:Improved SQL reports. bzr revid: apa@tinyerp.com-20100325070247-jpqqmy8u288n0fge --- .../report/account_analytic_report_view.xml | 40 +++++++-------- .../report/hr_evaluation_report_view.xml | 36 ++++++------- .../report/hr_expense_report_view.xml | 51 ++++++++++--------- .../report/available_holidays_view.xml | 34 +++++++------ 4 files changed, 83 insertions(+), 78 deletions(-) diff --git a/addons/account/report/account_analytic_report_view.xml b/addons/account/report/account_analytic_report_view.xml index db5b669dcfa..e85e77e816e 100644 --- a/addons/account/report/account_analytic_report_view.xml +++ b/addons/account/report/account_analytic_report_view.xml @@ -32,26 +32,26 @@ search - - - - - - - - - - - + + + + + + + + + + + + + search - - - - - - - + + + + + + + + + diff --git a/addons/hr_expense/report/hr_expense_report_view.xml b/addons/hr_expense/report/hr_expense_report_view.xml index 9e30e6688f2..86183693833 100644 --- a/addons/hr_expense/report/hr_expense_report_view.xml +++ b/addons/hr_expense/report/hr_expense_report_view.xml @@ -43,31 +43,32 @@ search - - - - - - - - - - - - + + + + + + + + + + + + + diff --git a/addons/hr_holidays/report/available_holidays_view.xml b/addons/hr_holidays/report/available_holidays_view.xml index 80e9cf3220b..18ea7d58d45 100644 --- a/addons/hr_holidays/report/available_holidays_view.xml +++ b/addons/hr_holidays/report/available_holidays_view.xml @@ -54,22 +54,24 @@ search - - - - - - - + + + + + + + + + From f9a5008bea270a39d863b04f6a023cb05f764962 Mon Sep 17 00:00:00 2001 From: "nel@tinyerp.com" <> Date: Wed, 31 Mar 2010 16:58:35 +0200 Subject: [PATCH 015/188] [FIX] Change names of wizards fix m2m pblems bzr revid: nel@tinyerp.com-20100331145835-hdbmoi82996fvy6w --- addons/board_account/__terp__.py | 3 --- addons/stock/stock.py | 8 ++++---- addons/stock/wizard/__init__.py | 4 ++-- addons/stock/wizard/stock_picking_make.py | 2 +- 4 files changed, 7 insertions(+), 10 deletions(-) diff --git a/addons/board_account/__terp__.py b/addons/board_account/__terp__.py index b22221ae1e3..58de913f2ea 100644 --- a/addons/board_account/__terp__.py +++ b/addons/board_account/__terp__.py @@ -38,9 +38,6 @@ 'account', 'hr_timesheet_invoice', 'board', -# 'report_account', -# 'report_analytic', -# 'report_analytic_line', 'account_report' ], 'update_xml': ['board_account_view.xml'], diff --git a/addons/stock/stock.py b/addons/stock/stock.py index 22c9c5d362f..b28895024f3 100644 --- a/addons/stock/stock.py +++ b/addons/stock/stock.py @@ -2122,7 +2122,7 @@ class report_products_to_received_planned(osv.osv): tools.drop_view_if_exists(cr, 'report_products_to_received_planned') cr.execute(""" create or replace view report_products_to_received_planned as ( - select stock.date, min(stock.id), sum(stock.product_qty) as qty, 0 as planned_qty + select stock.date, min(stock.id) as id, sum(stock.product_qty) as qty, 0 as planned_qty from stock_picking picking inner join stock_move stock on picking.id = stock.picking_id and picking.type = 'in' @@ -2131,7 +2131,7 @@ class report_products_to_received_planned(osv.osv): union - select stock.date_planned, min(stock.id), 0 as actual_qty, sum(stock.product_qty) as planned_qty + select stock.date_planned, min(stock.id) as id, 0 as actual_qty, sum(stock.product_qty) as planned_qty from stock_picking picking inner join stock_move stock on picking.id = stock.picking_id and picking.type = 'in' @@ -2156,7 +2156,7 @@ class report_delivery_products_planned(osv.osv): tools.drop_view_if_exists(cr, 'report_delivery_products_planned') cr.execute(""" create or replace view report_delivery_products_planned as ( - select stock.date, min(stock.id), sum(stock.product_qty) as qty, 0 as planned_qty + select stock.date, min(stock.id) as id, sum(stock.product_qty) as qty, 0 as planned_qty from stock_picking picking inner join stock_move stock on picking.id = stock.picking_id and picking.type = 'out' @@ -2176,4 +2176,4 @@ class report_delivery_products_planned(osv.osv): ) """) report_delivery_products_planned() -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/stock/wizard/__init__.py b/addons/stock/wizard/__init__.py index 6f5a83a07b3..d8702212646 100644 --- a/addons/stock/wizard/__init__.py +++ b/addons/stock/wizard/__init__.py @@ -23,12 +23,12 @@ import stock_traceability import stock_move import stock_partial_picking import stock_partial_move -import wizard_picking_make +import stock_picking_make import wizard_replacement import wizard_return import wizard_split_lot_line import wizard_ups -import inventory_merge +import stock_inventory_merge import stock_inventory_set_stock_zero import stock_fill_inventory import stock_inventory_line_split diff --git a/addons/stock/wizard/stock_picking_make.py b/addons/stock/wizard/stock_picking_make.py index 6ac54ee3bc1..c03b478a3a9 100644 --- a/addons/stock/wizard/stock_picking_make.py +++ b/addons/stock/wizard/stock_picking_make.py @@ -32,7 +32,7 @@ class stock_picking_make(osv.osv_memory): _name = "stock.picking.make" _description = "Make picking" _columns = { - 'pickings': fields.many2many('stock.picking', 'Picking', required=True), + 'pickings': fields.many2many('stock.picking','picking_rel', 'stock_id', 'pick_id', 'Picking', required=True), } ARCH = ''' From a8d3545d7833825d67956cc7bf7e94dc7626a78e Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Fri, 2 Apr 2010 11:03:18 +0530 Subject: [PATCH 016/188] [Fix] Problem of src model is fixed bzr revid: vir@tinyerp.com-20100402053318-ohcx30mqbm7pav0x --- addons/stock/wizard/stock_picking_make.py | 120 +++++++++------------- 1 file changed, 48 insertions(+), 72 deletions(-) diff --git a/addons/stock/wizard/stock_picking_make.py b/addons/stock/wizard/stock_picking_make.py index c03b478a3a9..e6a4c26d0da 100644 --- a/addons/stock/wizard/stock_picking_make.py +++ b/addons/stock/wizard/stock_picking_make.py @@ -20,84 +20,60 @@ ############################################################################## from osv import fields, osv -from service import web_services -from tools.misc import UpdateableStr, UpdateableDict -from tools.translate import _ import netsvc -import pooler -import time -import wizard class stock_picking_make(osv.osv_memory): - _name = "stock.picking.make" - _description = "Make picking" + _name = 'stock.picking.make' + _description = "Make Picking" + _columns = { - 'pickings': fields.many2many('stock.picking','picking_rel', 'stock_id', 'pick_id', 'Picking', required=True), - } - -ARCH = ''' -
- -''' - -FIELDS = { - 'pickings': { - 'string': 'Picking', - 'type': 'many2many', - 'relation': 'stock.picking', - 'readonly': True, - }, -} - -def _get_value(obj, cursor, user, data, context): - pool = pooler.get_pool(cursor.dbname) - picking_obj = pool.get('stock.picking') - - picking_ids = picking_obj.search(cursor, user, [ - ('id', 'in', data['ids']), - ('state', '<>', 'done'), - ('state', '<>', 'cancel')], context=context) - return {'pickings': picking_ids} - -def _make_packing(obj, cursor, user, data, context): - wkf_service = netsvc.LocalService('workflow') - pool = pooler.get_pool(cursor.dbname) - picking_obj = pool.get('stock.picking') - ids = data['form']['pickings'][0][2] - print"-------ids--------",ids - picking_obj.force_assign(cursor, user, ids) - picking_obj.action_move(cursor, user, ids) - for picking_id in ids: - wkf_service.trg_validate(user, 'stock.picking', picking_id, - 'button_done', cursor) - return {} - -class stock_picking_make(wizard.interface): - states = { - 'init': { - 'actions': [_get_value], - 'result': { - 'type': 'form', - 'arch': ARCH, - 'fields': FIELDS, - 'state': [ - ('end', 'Cancel', 'gtk-cancel'), - ('make', 'Ok', 'gtk-apply', True) - ], - }, - }, - 'make': { - 'actions': [_make_packing], - 'result': { - 'type': 'state', - 'state':'end', - }, - }, + 'picking_ids': fields.many2many('stock.picking', 'stock_picking_ids', 'parent_id', 'child_id', 'Pickings'), } -stock_picking_make('stock.picking.make') + def default_get(self, cursor, user, fields, context): + """ + To get default values for the object. + @param self: The object pointer. + @param cr: A database cursor + @param uid: ID of the user currently logged in + @param fields: List of fields for which we want default values + @param context: A standard dictionary + @return: A dictionary which of fields with values. + """ + res = super(stock_picking_make, self).default_get(cursor, user, fields, context=context) + record_ids = context and context.get('active_ids',False) or False + if record_ids: + picking_obj = self.pool.get('stock.picking') + picking_ids = picking_obj.search(cursor, user, [ + ('id', 'in', record_ids), + ('state', '<>', 'done'), + ('state', '<>', 'cancel')], context=context) + res['picking_ids'] = picking_ids + return res + + def make_packing(self, cursor, user, ids, context): + """ + Make Picking. + @param self: The object pointer. + @param cr: A database cursor + @param uid: ID of the user currently logged in + @param fields: List of fields for which we want default values + @param context: A standard dictionary + @return: A dictionary which of fields with values. + """ + record_ids = context and context.get('active_ids',False) or False + wkf_service = netsvc.LocalService('workflow') + picking_obj = self.pool.get('stock.picking') + data = self.read(cursor, user, ids[0]) + pick_ids = data['picking_ids'] + picking_obj.force_assign(cursor, user, pick_ids) + picking_obj.action_move(cursor, user, pick_ids) + for picking_id in ids: + wkf_service.trg_validate(user, 'stock.picking', picking_id, + 'button_done', cursor) + return {} + +stock_picking_make() # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: - From b09da9b87a0450289857204ace0004c79543fb49 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Fri, 2 Apr 2010 11:32:17 +0530 Subject: [PATCH 017/188] [FIX]:Fixed account_vat_declaration problem when load l10n_be module. bzr revid: apa@tinyerp.com-20100402060217-ibbmkgehn53u22pd --- addons/l10n_be/wizard/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/l10n_be/wizard/__init__.py b/addons/l10n_be/wizard/__init__.py index b811c54a6e4..1d2147a871b 100644 --- a/addons/l10n_be/wizard/__init__.py +++ b/addons/l10n_be/wizard/__init__.py @@ -19,7 +19,7 @@ # ############################################################################## -import account_vat_declaration +#import account_vat_declaration import partner_vat_listing import wizard_vat_intra import l10n_be_account_vat_declaration From 0353f4434c197f7b4cbc53e230bd684070bfecc3 Mon Sep 17 00:00:00 2001 From: "RCH(Open ERP)" <> Date: Fri, 2 Apr 2010 11:53:34 +0530 Subject: [PATCH 018/188] [IMP] changes in sales dashboard. bzr revid: vir@tinyerp.com-20100402062334-fgh3r4mhemz9yssr --- addons/board_sale/__terp__.py | 4 +- addons/board_sale/board_sale_view.xml | 16 +-- addons/sale/report/sale_report.py | 122 ++++++++++++++++++++ addons/sale/report/sale_report_view.xml | 143 ++++++++++++++++++++++-- 4 files changed, 269 insertions(+), 16 deletions(-) diff --git a/addons/board_sale/__terp__.py b/addons/board_sale/__terp__.py index bf4e572d031..1c9d01d376a 100644 --- a/addons/board_sale/__terp__.py +++ b/addons/board_sale/__terp__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- ############################################################################## -# +# # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (). # @@ -15,7 +15,7 @@ # 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 . +# along with this program. If not, see . # ############################################################################## diff --git a/addons/board_sale/board_sale_view.xml b/addons/board_sale/board_sale_view.xml index 509bcb5428b..789f1e6f2b1 100644 --- a/addons/board_sale/board_sale_view.xml +++ b/addons/board_sale/board_sale_view.xml @@ -5,7 +5,7 @@ Sales
- + + + board.sales.manager.form board.board form -
+ - - + + - - + +
diff --git a/addons/sale/report/sale_report.py b/addons/sale/report/sale_report.py index 3ba814b438f..9ca34fc2d3d 100644 --- a/addons/sale/report/sale_report.py +++ b/addons/sale/report/sale_report.py @@ -89,3 +89,125 @@ class sale_report(osv.osv): """) sale_report() +class sale_order_by_clients(osv.osv): + _name = "sale.order.by.clients" + _description = "Sales order by clients" + _auto = False + _rec_name = 'partner' + _columns = { + 'total_orders': fields.integer('Total'), + 'partner_id':fields.many2one('res.partner', 'Partner', readonly=True) + } + _order = 'total_orders desc' + def init(self, cr): + tools.drop_view_if_exists(cr, 'sale_order_by_clients') + cr.execute(""" + create or replace view sale_order_by_clients as ( + select + min(s.id) as id, + count(*) as total_orders, + s.partner_id as partner_id + from + sale_order s + where + s.state='manual' or s.state='progress' + group by + s.partner_id + ) + """) +sale_order_by_clients() + +class uninvoiced_lines_per_month(osv.osv): + _name = "uninvoiced.lines.per.month" + _description = "Uninvoiced lines per month" + _auto = False + _rec_name = 'month' + _columns = { + 'number_of_lines': fields.integer('Total Lines', readonly=True), + 'year': fields.char('Year', size=10, readonly=True), + 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), + ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), + ('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True), + + } + _order = 'number_of_lines desc' + def init(self, cr): + tools.drop_view_if_exists(cr, 'uninvoiced_lines_per_month') + cr.execute(""" + create or replace view uninvoiced_lines_per_month as ( + select + min(s.id) as id, + count(*) as number_of_lines, + to_char(s.create_date, 'MM') as month, + to_char(s.create_date, 'YYYY') as year + from + sale_order_line s + where + s.state='draft' + group by + to_char(s.create_date, 'MM'),to_char(s.create_date, 'YYYY') + ) + """) +uninvoiced_lines_per_month() + +class product_bought_by_sale_order(osv.osv): + _name = "product.bought.by.sale.order" + _description = "Product bought by sale order" + _auto = False + _rec_name = 'partner' + _columns = { + 'total_products': fields.integer('Total Products', readonly=True), + 'name': fields.char('Sale order', size=64, readonly=True) + } + _order = 'total_products desc' + def init(self, cr): + tools.drop_view_if_exists(cr, 'product_bought_by_sale_order') + cr.execute(""" + create or replace view product_bought_by_sale_order as ( + select + min(s.id) as id, + count(*) as total_products, + s.name as name + from + sale_order_line l + left join + sale_order s on (s.id=l.order_id) + where + s.state='manual' or s.state='progress' + group by + s.name + ) + """) +product_bought_by_sale_order() + +class sales_by_regions(osv.osv): + _name = "sales.by.regions" + _description = "Sales by regions" + _auto = False + _rec_name = 'name' + _columns = { + 'total_sales': fields.integer('Total Sales', readonly=True), + 'name': fields.char('Country', size=64, readonly=True), + } + _order = 'total_sales desc' + def init(self, cr): + tools.drop_view_if_exists(cr, 'sales_by_regions') + cr.execute(""" + create or replace view sales_by_regions as ( + select + min(s.id) as id, + rc.name as name, + count(s.name) as total_sales + from + sale_order s,res_partner_address p,res_country rc + where + s.partner_id=p.id and + p.country_id=rc.id and + (s.state='manual' or s.state='progress') + group by + rc.name + ) + """) +sales_by_regions() + + diff --git a/addons/sale/report/sale_report_view.xml b/addons/sale/report/sale_report_view.xml index 2e36b7d9923..04d8454553c 100644 --- a/addons/sale/report/sale_report_view.xml +++ b/addons/sale/report/sale_report_view.xml @@ -43,22 +43,22 @@ search - @@ -99,5 +99,134 @@ + + + sale.order.by.clients.tree + sale.order.by.clients + tree + + + + + + + + + + sale.order.by.clients.graph + sale.order.by.clients + graph + + + + + + + + + + Sales Orders + sale.order.by.clients + form + tree,graph + + + + + uninvoiced.lines.per.month.tree + uninvoiced.lines.per.month + tree + + + + + + + + + + + uninvoiced.lines.per.month.graph + uninvoiced.lines.per.month + graph + + + + + + + + + + Uninvoiced Lines + uninvoiced.lines.per.month + form + tree,graph + + + + + product.bought.by.sale.order.tree + product.bought.by.sale.order + tree + + + + + + + + + + product.bought.by.sale.order.graph + product.bought.by.sale.order + graph + + + + + + + + + + Product bought by sale order + product.bought.by.sale.order + form + tree,graph + + + + + sales.by.regions.tree + sales.by.regions + tree + + + + + + + + + + sales.by.regions.graph + sales.by.regions + graph + + + + + + + + + + Sales by regions + sales.by.regions + form + tree,graph + + From 8b783f1274b542f07aebd1835f4d89a84a3e5a55 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Fri, 2 Apr 2010 12:39:38 +0530 Subject: [PATCH 019/188] [IMP]:sale,hr_recruitment,puchase,account:Improved report. bzr revid: apa@tinyerp.com-20100402070938-3jakviebvmay81qd --- addons/account/report/account_invoice_report_view.xml | 3 ++- addons/hr_recruitment/report/hr_recruitment_report_view.xml | 2 ++ addons/purchase/report/purchase_report_view.xml | 3 ++- addons/sale/report/sale_report_view.xml | 3 ++- 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/addons/account/report/account_invoice_report_view.xml b/addons/account/report/account_invoice_report_view.xml index de046de6211..6dbb5f336aa 100644 --- a/addons/account/report/account_invoice_report_view.xml +++ b/addons/account/report/account_invoice_report_view.xml @@ -43,6 +43,7 @@ search + - + search + + search + - + diff --git a/addons/sale/report/sale_report_view.xml b/addons/sale/report/sale_report_view.xml index 04d8454553c..79fd67084d2 100644 --- a/addons/sale/report/sale_report_view.xml +++ b/addons/sale/report/sale_report_view.xml @@ -43,6 +43,7 @@ search + - + From 65050c80fcc74e95d72a57b519e52ebc46e3ac05 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Mon, 5 Apr 2010 12:59:03 +0530 Subject: [PATCH 020/188] [IMP]:purchase:Improved SQL purchase report. bzr revid: apa@tinyerp.com-20100405072903-6xfy9b27wuvs4139 --- addons/purchase/report/purchase_report.py | 4 +-- .../purchase/report/purchase_report_view.xml | 26 +++++++++---------- 2 files changed, 14 insertions(+), 16 deletions(-) diff --git a/addons/purchase/report/purchase_report.py b/addons/purchase/report/purchase_report.py index ac9abaaf590..14c073894b8 100644 --- a/addons/purchase/report/purchase_report.py +++ b/addons/purchase/report/purchase_report.py @@ -52,7 +52,7 @@ class report_purchase_order(osv.osv): 'quantity': fields.float('# of Products', readonly=True), 'price_total': fields.float('Total Price', readonly=True), 'price_average': fields.float('Average Price', readonly=True), - 'count': fields.integer('# of Lines', readonly=True), + 'nbr': fields.integer('# of Lines', readonly=True), 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), ('10','October'), ('11','November'), ('12','December')],'Month',readonly=True), @@ -75,7 +75,7 @@ class report_purchase_order(osv.osv): l.product_id, t.categ_id as category_id, sum(l.product_qty*u.factor) as quantity, - count(*), + count(*) as nbr, sum(l.product_qty*l.price_unit) as price_total, (sum(l.product_qty*l.price_unit)/sum(l.product_qty*u.factor))::decimal(16,2) as price_average from purchase_order s diff --git a/addons/purchase/report/purchase_report_view.xml b/addons/purchase/report/purchase_report_view.xml index 46aa69a6f29..99bf7cce7cc 100644 --- a/addons/purchase/report/purchase_report_view.xml +++ b/addons/purchase/report/purchase_report_view.xml @@ -20,20 +20,19 @@ tree - - - + + + - - - - - - - - - + + + + + + + +
@@ -64,13 +63,13 @@ default="1" domain="[('state','<>','draft'),('state','<>','cancel')]"/> - + @@ -80,7 +79,6 @@ - From 040857a953be64b1073b1b36c8bc225a1d407669 Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Mon, 5 Apr 2010 19:03:32 +0530 Subject: [PATCH 021/188] board_hr : Timesheet by month, graph view added bzr revid: vir@tinyerp.com-20100405133332-4kt3cb7myc8heq45 --- addons/board_hr/board_hr_view.xml | 11 +++- addons/hr_timesheet_sheet/__init__.py | 2 +- addons/hr_timesheet_sheet/__terp__.py | 3 +- addons/hr_timesheet_sheet/report/__init__.py | 25 +++++++++ .../report/timesheet_report.py | 53 +++++++++++++++++++ .../report/timesheet_report_view.xml | 32 +++++++++++ 6 files changed, 123 insertions(+), 3 deletions(-) create mode 100644 addons/hr_timesheet_sheet/report/__init__.py create mode 100644 addons/hr_timesheet_sheet/report/timesheet_report.py create mode 100644 addons/hr_timesheet_sheet/report/timesheet_report_view.xml diff --git a/addons/board_hr/board_hr_view.xml b/addons/board_hr/board_hr_view.xml index 0d8fb63e8ee..6f4e3fdec59 100644 --- a/addons/board_hr/board_hr_view.xml +++ b/addons/board_hr/board_hr_view.xml @@ -33,7 +33,15 @@ tree,form
- + + Timesheets by Month + ir.actions.act_window + timesheet.report + form + graph,tree + [('user_id','=',uid)] + + board.hr.form board.board @@ -43,6 +51,7 @@ + diff --git a/addons/hr_timesheet_sheet/__init__.py b/addons/hr_timesheet_sheet/__init__.py index 46961316bb4..d7635359c74 100644 --- a/addons/hr_timesheet_sheet/__init__.py +++ b/addons/hr_timesheet_sheet/__init__.py @@ -21,6 +21,6 @@ import hr_timesheet_sheet import wizard - +import report # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/hr_timesheet_sheet/__terp__.py b/addons/hr_timesheet_sheet/__terp__.py index 9042d4200f1..44058d048cb 100644 --- a/addons/hr_timesheet_sheet/__terp__.py +++ b/addons/hr_timesheet_sheet/__terp__.py @@ -52,7 +52,8 @@ The validation can be configured in te company: 'security/hr_timesheet_data.xml', 'hr_timesheet_sheet_view.xml', 'hr_timesheet_workflow.xml', - 'process/hr_timesheet_sheet_process.xml' + 'process/hr_timesheet_sheet_process.xml', + 'report/timesheet_report_view.xml', ], 'demo_xml': ['hr_timesheet_sheet_demo.xml'], 'installable': True, diff --git a/addons/hr_timesheet_sheet/report/__init__.py b/addons/hr_timesheet_sheet/report/__init__.py new file mode 100644 index 00000000000..89f12b7c9a6 --- /dev/null +++ b/addons/hr_timesheet_sheet/report/__init__.py @@ -0,0 +1,25 @@ +# -*- 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 . +# +############################################################################## + +import timesheet_report + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: + diff --git a/addons/hr_timesheet_sheet/report/timesheet_report.py b/addons/hr_timesheet_sheet/report/timesheet_report.py new file mode 100644 index 00000000000..a299f099f80 --- /dev/null +++ b/addons/hr_timesheet_sheet/report/timesheet_report.py @@ -0,0 +1,53 @@ +# -*- 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 . +# +############################################################################## + +import tools +from osv import fields,osv + +class timesheet_report(osv.osv): + _name = "timesheet.report" + _description = "Timesheet by month " + _auto = False + _columns = { + 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), + ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), + ('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True), + 'no_of_timesheet': fields.integer('Total Timesheet',readonly=True), + } + + def init(self, cr): + tools.drop_view_if_exists(cr, 'timesheet_report') + cr.execute(""" + create or replace view timesheet_report as ( + select + min(id) as id, + to_char(create_date, 'MM') as month, + user_id, + count(*) as no_of_timesheet + from + hr_timesheet_sheet_sheet + where + to_char(create_date,'YYYY') = to_char(current_date,'YYYY') + group by + to_char(create_date,'MM'),user_id + ) + """) +timesheet_report() \ No newline at end of file diff --git a/addons/hr_timesheet_sheet/report/timesheet_report_view.xml b/addons/hr_timesheet_sheet/report/timesheet_report_view.xml new file mode 100644 index 00000000000..d557c094e5d --- /dev/null +++ b/addons/hr_timesheet_sheet/report/timesheet_report_view.xml @@ -0,0 +1,32 @@ + + + + + + timesheet.report.tree + timesheet.report + tree + + + + + + + + + + timesheet.report.graph + timesheet.report + graph + + + + + + + + + + + + \ No newline at end of file From e1a7630ccb49ac5530eef49b7e41b82abc8583d8 Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Tue, 6 Apr 2010 11:36:22 +0530 Subject: [PATCH 022/188] [ADD] board_hr : Leaves by Type graph view added in hr dash board bzr revid: vir@tinyerp.com-20100406060622-2x28znygyzlgtgaq --- addons/board_hr/board_hr_view.xml | 32 ++++++++++++------- .../hr_holidays/report/hr_holidays_report.py | 26 +++++++++++++++ .../report/hr_holidays_report_view.xml | 23 +++++++++++++ 3 files changed, 70 insertions(+), 11 deletions(-) diff --git a/addons/board_hr/board_hr_view.xml b/addons/board_hr/board_hr_view.xml index 6f4e3fdec59..2a587c03a23 100644 --- a/addons/board_hr/board_hr_view.xml +++ b/addons/board_hr/board_hr_view.xml @@ -33,15 +33,24 @@ tree,form - - Timesheets by Month - ir.actions.act_window - timesheet.report - form - graph,tree - [('user_id','=',uid)] - - + + Timesheets by Month + ir.actions.act_window + timesheet.report + form + graph,tree + [('user_id','=',uid)] + + + + + Leaves by Type + ir.actions.act_window + hr.holidays.by.type + form + graph,tree + + board.hr.form board.board @@ -50,8 +59,9 @@
- - + + + diff --git a/addons/hr_holidays/report/hr_holidays_report.py b/addons/hr_holidays/report/hr_holidays_report.py index f9b41b638f1..5652d32b9d5 100644 --- a/addons/hr_holidays/report/hr_holidays_report.py +++ b/addons/hr_holidays/report/hr_holidays_report.py @@ -71,3 +71,29 @@ class hr_holidays_report(osv.osv): """) hr_holidays_report() +class hr_holidays_by_type(osv.osv): + _name = "hr.holidays.by.type" + _description = "Total holidays by type" + _auto = False + _columns = { + 'name': fields.char('Leave Type',size=64), + 'no_of_leaves' : fields.integer('Total leaves'), + + } + def init(self, cr): + tools.drop_view_if_exists(cr, 'hr_holidays_by_type') + cr.execute(""" + create or replace view hr_holidays_by_type as ( + select + min(hhl.id) as id, + hhs.name as name, + sum(hhl.number_of_days) * -1 as no_of_leaves + from + hr_holidays as hhl,hr_holidays_status as hhs + where + hhs.id = hhl.holiday_status_id and number_of_days < 0 + group by + hhs.name,hhl.holiday_status_id + ) + """) +hr_holidays_by_type() diff --git a/addons/hr_holidays/report/hr_holidays_report_view.xml b/addons/hr_holidays/report/hr_holidays_report_view.xml index 6af57008fcd..a70db034e2b 100644 --- a/addons/hr_holidays/report/hr_holidays_report_view.xml +++ b/addons/hr_holidays/report/hr_holidays_report_view.xml @@ -90,5 +90,28 @@ + + hr.holidays.by.type.tree + hr.holidays.by.type + tree + + + + + + + + + + hr.holidays.by.type.graph + hr.holidays.by.type + graph + + + + + + + From 547c8782cfac57153277551aa772b0a8ed8ddb79 Mon Sep 17 00:00:00 2001 From: "nel@tinyerp.com" <> Date: Tue, 6 Apr 2010 09:24:56 +0200 Subject: [PATCH 023/188] start name of the report with the module name bzr revid: nel@tinyerp.com-20100406072456-wo6eumbs4p980xxq --- addons/purchase/report/purchase_report.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/purchase/report/purchase_report.py b/addons/purchase/report/purchase_report.py index 14c073894b8..86aa400cff0 100644 --- a/addons/purchase/report/purchase_report.py +++ b/addons/purchase/report/purchase_report.py @@ -27,7 +27,7 @@ from osv import fields,osv import tools class report_purchase_order(osv.osv): - _name = "report.purchase.order" + _name = "purchase.report" _description = "Purchases Orders" _auto = False _columns = { From c69545f00d2567c2d49c13028297a3c1107fc803 Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Tue, 6 Apr 2010 16:44:25 +0530 Subject: [PATCH 024/188] [ADD] board_purchase module added bzr revid: vir@tinyerp.com-20100406111425-kca3bssxaj51kltf --- addons/board_purchase/__init__.py | 24 ++++++ addons/board_purchase/__terp__.py | 41 ++++++++++ addons/board_purchase/board_purchase_view.xml | 57 ++++++++++++++ addons/purchase/purchase_view.xml | 16 ++-- addons/purchase/report/purchase_report.py | 66 +++++++++++++++- .../purchase/report/purchase_report_view.xml | 77 +++++++++++++++++-- addons/purchase/security/ir.model.access.csv | 2 +- 7 files changed, 266 insertions(+), 17 deletions(-) create mode 100644 addons/board_purchase/__init__.py create mode 100644 addons/board_purchase/__terp__.py create mode 100644 addons/board_purchase/board_purchase_view.xml diff --git a/addons/board_purchase/__init__.py b/addons/board_purchase/__init__.py new file mode 100644 index 00000000000..3c3121d954a --- /dev/null +++ b/addons/board_purchase/__init__.py @@ -0,0 +1,24 @@ +# -*- 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 . +# +############################################################################## + + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: + diff --git a/addons/board_purchase/__terp__.py b/addons/board_purchase/__terp__.py new file mode 100644 index 00000000000..f5ada7cfe46 --- /dev/null +++ b/addons/board_purchase/__terp__.py @@ -0,0 +1,41 @@ +# -*- 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 . +# +############################################################################## + + +{ + 'name': 'Board for Purchase Management', + 'version': '1.0', + 'category': 'Board/Purchase', + 'description': """ +This module implements a dashboard for purcgase management that includes: + * Current Purchase Orders + * Draft Purchase Orders + * Graph for quantity and amount per month + """, + 'author': 'Tiny', + 'depends': [ 'purchase','board', + ], + 'update_xml': ['board_purchase_view.xml'], + 'demo_xml': [], + 'installable': True, + 'active': False, +} +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/board_purchase/board_purchase_view.xml b/addons/board_purchase/board_purchase_view.xml new file mode 100644 index 00000000000..4838c845cf1 --- /dev/null +++ b/addons/board_purchase/board_purchase_view.xml @@ -0,0 +1,57 @@ + + + + + + + + + Quotation Request + ir.actions.act_window + purchase.order + form + [('state','in',('wait','confirmed'))] + tree,form + + + + + board.purchase.form + board.board + form + + + + + + + + + + + + + + + + + + Purchase Dashboard + board.board + form + form + menu + + + + + + \ No newline at end of file diff --git a/addons/purchase/purchase_view.xml b/addons/purchase/purchase_view.xml index 653238748b9..c7247256bfc 100644 --- a/addons/purchase/purchase_view.xml +++ b/addons/purchase/purchase_view.xml @@ -157,13 +157,13 @@ - + - - + + @@ -176,10 +176,10 @@ purchase.order form [('state','=','draft')] - tree,form - + tree,form +
- @@ -216,7 +216,7 @@ - + @@ -289,7 +289,7 @@ name="Product purchases" res_model="purchase.order.line" src_model="product.product"/> - + + + project.vs.remaining.hour.tree + project.vs.remaining.hours + tree + + + + + + + + + + + project.vs.remaining.hour.graph + project.vs.remaining.hours + graph + + + + + + + + + + Project and remaining hours + project.vs.remaining.hours + form + graph,tree + + + + + task.by.days.tree + task.by.days + tree + + + + + + + + + + task.by.days.graph + task.by.days + graph + + + + + + + + + + Task By Days + task.by.days + form + graph,tree + + + + + + task.by.days.vs.planned.hours.tree + task.by.days.vs.planned.hours + tree + + + + + + + + + + task.by.days.vs.planned.hours.graph + task.by.days.vs.planned.hours + graph + + + + + + + + + + Task By Days vs Planned Hours + task.by.days.vs.planned.hours + form + graph,tree + + diff --git a/addons/project_issue/report/project_issue_report.py b/addons/project_issue/report/project_issue_report.py index ef1e002ae78..3f3c97fc5e0 100644 --- a/addons/project_issue/report/project_issue_report.py +++ b/addons/project_issue/report/project_issue_report.py @@ -35,7 +35,7 @@ class project_issue_report(osv.osv): c.priority as priority, c.project_id as project_id, c.type_id as type_id, - count(*) as nbr, + count(*) as nbr, to_char(avg(date_closed-c.create_date), 'DD"d" HH24:MI:SS') as delay_close from project_issue c @@ -49,4 +49,5 @@ class project_issue_report(osv.osv): project_issue_report() + # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/project_issue/report/project_issue_report_view.xml b/addons/project_issue/report/project_issue_report_view.xml index 2f7886670c2..52b6f336d58 100644 --- a/addons/project_issue/report/project_issue_report_view.xml +++ b/addons/project_issue/report/project_issue_report_view.xml @@ -117,5 +117,7 @@ + + From 859d60a716ad67c2081f1f1748648c23ec37fdfb Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Tue, 6 Apr 2010 18:54:56 +0530 Subject: [PATCH 027/188] [MOD] board_hr : remaining holidays by user, instead of leaves by type bzr revid: vir@tinyerp.com-20100406132456-kfz5d1fkyc26p42d --- addons/board_hr/board_hr_view.xml | 17 +++++------ .../hr_holidays/report/hr_holidays_report.py | 28 ++++++++++--------- .../report/hr_holidays_report_view.xml | 12 ++++---- 3 files changed, 30 insertions(+), 27 deletions(-) diff --git a/addons/board_hr/board_hr_view.xml b/addons/board_hr/board_hr_view.xml index 2a587c03a23..b2c105691fe 100644 --- a/addons/board_hr/board_hr_view.xml +++ b/addons/board_hr/board_hr_view.xml @@ -43,13 +43,14 @@ - - Leaves by Type + + Remaining Leaves by User ir.actions.act_window - hr.holidays.by.type + hr.holidays.remaining.leaves.user form graph,tree - + [('user_id','=',uid)] + board.hr.form @@ -60,12 +61,12 @@ - - + + - - + + diff --git a/addons/hr_holidays/report/hr_holidays_report.py b/addons/hr_holidays/report/hr_holidays_report.py index 5652d32b9d5..4bae007f281 100644 --- a/addons/hr_holidays/report/hr_holidays_report.py +++ b/addons/hr_holidays/report/hr_holidays_report.py @@ -71,29 +71,31 @@ class hr_holidays_report(osv.osv): """) hr_holidays_report() -class hr_holidays_by_type(osv.osv): - _name = "hr.holidays.by.type" +class hr_holidays_remaining_leaves_user(osv.osv): + _name = "hr.holidays.remaining.leaves.user" _description = "Total holidays by type" _auto = False _columns = { - 'name': fields.char('Leave Type',size=64), - 'no_of_leaves' : fields.integer('Total leaves'), + 'name': fields.char('Employee',size=64), + 'no_of_leaves' : fields.integer('Remaining leaves'), + 'user_id':fields.many2one('res.users','User'), } def init(self, cr): - tools.drop_view_if_exists(cr, 'hr_holidays_by_type') + tools.drop_view_if_exists(cr, 'hr_holidays_remaining_leaves_user') cr.execute(""" - create or replace view hr_holidays_by_type as ( + create or replace view hr_holidays_remaining_leaves_user as ( select - min(hhl.id) as id, - hhs.name as name, - sum(hhl.number_of_days) * -1 as no_of_leaves + min(hrs.id) as id, + rr.name as name, + sum(hrs.number_of_days) as no_of_leaves, + hrs.user_id from - hr_holidays as hhl,hr_holidays_status as hhs + hr_holidays as hrs, hr_employee as hre, resource_resource as rr where - hhs.id = hhl.holiday_status_id and number_of_days < 0 + hrs.employee_id = hre.id and hre.resource_id = rr.id group by - hhs.name,hhl.holiday_status_id + rr.name,hrs.user_id ) """) -hr_holidays_by_type() +hr_holidays_remaining_leaves_user() diff --git a/addons/hr_holidays/report/hr_holidays_report_view.xml b/addons/hr_holidays/report/hr_holidays_report_view.xml index a70db034e2b..7c15f77da72 100644 --- a/addons/hr_holidays/report/hr_holidays_report_view.xml +++ b/addons/hr_holidays/report/hr_holidays_report_view.xml @@ -90,9 +90,9 @@ - - hr.holidays.by.type.tree - hr.holidays.by.type + + hr.holidays.remaining.leaves.user.tree + hr.holidays.remaining.leaves.user tree @@ -102,9 +102,9 @@ - - hr.holidays.by.type.graph - hr.holidays.by.type + + hr.holidays.remaining.leaves.user.graph + hr.holidays.remaining.leaves.user graph From 3a13731d0777a25260f3628f3647d2c1122e6dfa Mon Sep 17 00:00:00 2001 From: "RCH(Open ERP)" <> Date: Wed, 7 Apr 2010 11:29:42 +0530 Subject: [PATCH 028/188] [MOD] Small changes in project issue and purchase dashboard bzr revid: vir@tinyerp.com-20100407055942-6v8u0ocm8a1lpv9f --- addons/board_purchase/board_purchase_view.xml | 4 ++-- addons/project/report/project_report.py | 6 ++++-- addons/project/report/project_report_view.xml | 3 +++ addons/purchase/report/purchase_report_view.xml | 4 ++-- 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/addons/board_purchase/board_purchase_view.xml b/addons/board_purchase/board_purchase_view.xml index 4838c845cf1..d1ac01b9e7f 100644 --- a/addons/board_purchase/board_purchase_view.xml +++ b/addons/board_purchase/board_purchase_view.xml @@ -30,8 +30,8 @@
- - + + diff --git a/addons/project/report/project_report.py b/addons/project/report/project_report.py index a8d2f0a550a..af3eae3365a 100644 --- a/addons/project/report/project_report.py +++ b/addons/project/report/project_report.py @@ -119,6 +119,7 @@ class task_by_days(osv.osv): _auto = False _columns = { 'day': fields.char('Day', size=128, required=True), + 'state': fields.selection([('draft', 'Draft'),('open', 'In Progress'),('pending', 'Pending'), ('cancelled', 'Cancelled'), ('done', 'Done')], 'State', readonly=True, required=True), 'total_task': fields.float('Total tasks', readonly=True) } _order = 'day desc' @@ -129,11 +130,12 @@ class task_by_days(osv.osv): select min(pt.id) as id, to_char(pt.create_date, 'YYYY-MM-DD') as day, - count(*) as total_task + count(*) as total_task, + pt.state as state from project_task as pt group by - to_char(pt.create_date, 'YYYY-MM-DD') + to_char(pt.create_date, 'YYYY-MM-DD'),pt.state ) """) task_by_days() diff --git a/addons/project/report/project_report_view.xml b/addons/project/report/project_report_view.xml index 11419be662e..a318df67832 100644 --- a/addons/project/report/project_report_view.xml +++ b/addons/project/report/project_report_view.xml @@ -88,6 +88,7 @@ + @@ -109,6 +110,7 @@ + @@ -120,6 +122,7 @@ + diff --git a/addons/purchase/report/purchase_report_view.xml b/addons/purchase/report/purchase_report_view.xml index 9482cef716d..19f13755083 100644 --- a/addons/purchase/report/purchase_report_view.xml +++ b/addons/purchase/report/purchase_report_view.xml @@ -139,8 +139,8 @@ graph - - + + From 3681d53a9150f66dcb4c7b901aed0b1b5027bc5e Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 7 Apr 2010 13:04:57 +0530 Subject: [PATCH 029/188] [IMP]:sale,purchase:Improved SQL Reports. bzr revid: apa@tinyerp.com-20100407073457-ht3odfppeo46fim3 --- addons/purchase/report/purchase_report.py | 18 ++++++++++------ .../purchase/report/purchase_report_view.xml | 21 ++++++++++++++++++- addons/sale/report/sale_report.py | 6 +++++- addons/sale/report/sale_report_view.xml | 15 +++++++++++++ 4 files changed, 52 insertions(+), 8 deletions(-) diff --git a/addons/purchase/report/purchase_report.py b/addons/purchase/report/purchase_report.py index f447fd598f9..f5338e93723 100644 --- a/addons/purchase/report/purchase_report.py +++ b/addons/purchase/report/purchase_report.py @@ -43,9 +43,15 @@ class report_purchase_order(osv.osv): ('done','Done'), ('cancel','Cancel') ], 'Order State', readonly=True), + 'invoice_method': fields.selection([ + ('manual','Manual'), + ('order','From Order'), + ('picking','From Picking') + ],'Invoicing Control', readonly=True), 'product_id':fields.many2one('product.product', 'Product', readonly=True), 'warehouse_id': fields.many2one('stock.warehouse', 'Warehouse', readonly=True), - 'category_id': fields.many2one('product.category', 'Categories', readonly=True), + 'location_id': fields.many2one('stock.location', 'Destination', readonly=True), + 'fiscal_position': fields.many2one('account.fiscal.position', 'Fiscal Position',readonly=True), 'partner_id':fields.many2one('res.partner', 'Partner', readonly=True), 'company_id':fields.many2one('res.company', 'Company', readonly=True), 'user_id':fields.many2one('res.users', 'Responsible', readonly=True), @@ -70,24 +76,24 @@ class report_purchase_order(osv.osv): s.state, s.warehouse_id as warehouse_id, s.partner_id as partner_id, + s.fiscal_position, s.create_uid as user_id, s.company_id as company_id, + s.invoice_method, l.product_id, - t.categ_id as category_id, + s.location_id as location_id, sum(l.product_qty*u.factor) as quantity, count(*) as nbr, sum(l.product_qty*l.price_unit) as price_total, (sum(l.product_qty*l.price_unit)/sum(l.product_qty*u.factor))::decimal(16,2) as price_average from purchase_order s left join purchase_order_line l on (s.id=l.order_id) - left join product_product p on (p.id=l.product_id) - left join product_template t on (t.id=p.product_tmpl_id) left join product_uom u on (u.id=l.product_uom) where l.product_id is not null group by s.company_id,s.create_uid,s.partner_id, - t.categ_id,l.product_id,s.date_order, + s.location_id,l.product_id,s.date_order, to_char(s.date_order, 'YYYY'),to_char(s.date_order, 'MM'),s.state, - s.warehouse_id + s.warehouse_id,s.fiscal_position,s.invoice_method ) """) report_purchase_order() diff --git a/addons/purchase/report/purchase_report_view.xml b/addons/purchase/report/purchase_report_view.xml index 19f13755083..5fe1330dcae 100644 --- a/addons/purchase/report/purchase_report_view.xml +++ b/addons/purchase/report/purchase_report_view.xml @@ -33,6 +33,8 @@ + + @@ -72,16 +74,32 @@ + + + + + + + + + + + + + + - + + + @@ -95,6 +113,7 @@ form tree,graph + {'search_default_user_id':True} diff --git a/addons/sale/report/sale_report.py b/addons/sale/report/sale_report.py index 9ca34fc2d3d..77cdb4d4cc3 100644 --- a/addons/sale/report/sale_report.py +++ b/addons/sale/report/sale_report.py @@ -39,6 +39,8 @@ class sale_report(osv.osv): 'partner_id':fields.many2one('res.partner', 'Partner', readonly=True), 'shop_id':fields.many2one('sale.shop', 'Shop', readonly=True), 'company_id':fields.many2one('res.company', 'Company', readonly=True), + 'payment_term': fields.many2one('account.payment.term', 'Payment Term',readonly=True), + 'fiscal_position': fields.many2one('account.fiscal.position', 'Fiscal Position',readonly=True), 'user_id':fields.many2one('res.users', 'Salesman', readonly=True), 'price_total':fields.float('Total Price', readonly=True), 'delay':fields.float('Avg Closing Days', digits=(16,2), readonly=True), @@ -70,6 +72,8 @@ class sale_report(osv.osv): s.partner_id as partner_id, s.user_id as user_id, s.shop_id as shop_id, + s.fiscal_position as fiscal_position, + s.payment_term as payment_term, s.company_id as company_id, extract(epoch from avg(s.date_confirm-s.create_date))/(24*60*60)::decimal(16,2) as delay, sum(l.product_uom_qty*l.price_unit) as price_total, @@ -84,7 +88,7 @@ class sale_report(osv.osv): group by s.date_order, s.partner_id, l.product_id, l.product_uom, s.user_id, s.state, s.shop_id, - s.company_id + s.company_id,s.fiscal_position,s.payment_term ) """) sale_report() diff --git a/addons/sale/report/sale_report_view.xml b/addons/sale/report/sale_report_view.xml index 79fd67084d2..9b927a7d7a0 100644 --- a/addons/sale/report/sale_report_view.xml +++ b/addons/sale/report/sale_report_view.xml @@ -21,6 +21,8 @@ + + @@ -72,6 +74,17 @@ + + + + + + + + + + + @@ -80,8 +93,10 @@ + + From c5c66ed258e5d33c4967a6ed712f933c53cd367a Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 7 Apr 2010 14:37:16 +0530 Subject: [PATCH 030/188] [IMP]:sale,purchase,account:Improved SQL reports. bzr revid: apa@tinyerp.com-20100407090716-t2mf8cd54peqs4pp --- .../account/report/account_invoice_report.py | 26 ++++++++++++++++--- .../report/account_invoice_report_view.xml | 11 ++++++++ addons/purchase/report/purchase_report.py | 17 +++++++++--- addons/sale/report/sale_report.py | 13 +++++++--- 4 files changed, 57 insertions(+), 10 deletions(-) diff --git a/addons/account/report/account_invoice_report.py b/addons/account/report/account_invoice_report.py index 0d4ac30323d..548e6eb50a6 100644 --- a/addons/account/report/account_invoice_report.py +++ b/addons/account/report/account_invoice_report.py @@ -35,6 +35,11 @@ class account_invoice_report(osv.osv): ('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True), 'product_id':fields.many2one('product.product', 'Product', readonly=True), 'product_qty':fields.float('Qty', readonly=True), + 'payment_term': fields.many2one('account.payment.term', 'Payment Term',readonly=True), + 'period_id': fields.many2one('account.period', 'Force Period', domain=[('state','<>','done')],readonly=True), + 'fiscal_position': fields.many2one('account.fiscal.position', 'Fiscal Position',readonly=True), + 'currency_id': fields.many2one('res.currency', 'Currency', readonly=True), + 'journal_id': fields.many2one('account.journal', 'Journal',readonly=True), 'partner_id':fields.many2one('res.partner', 'Partner', readonly=True), 'company_id':fields.many2one('res.company', 'Company', readonly=True), 'user_id':fields.many2one('res.users', 'Salesman', readonly=True), @@ -69,6 +74,11 @@ class account_invoice_report(osv.osv): l.product_id as product_id, sum(l.quantity * u.factor) as product_qty, s.partner_id as partner_id, + s.payment_term as payment_term, + s.period_id as period_id, + s.currency_id as currency_id, + s.journal_id as journal_id, + s.fiscal_position as fiscal_position, s.user_id as user_id, s.company_id as company_id, sum(l.quantity*l.price_unit) as price_total, @@ -82,9 +92,19 @@ class account_invoice_report(osv.osv): account_invoice s on (s.id=l.invoice_id) left join product_uom u on (u.id=l.uos_id) group by - s.type,s.date_invoice, s.partner_id, l.product_id, - l.uos_id, s.user_id, s.state, - s.company_id + s.type, + s.date_invoice, + s.partner_id, + l.product_id, + l.uos_id, + s.user_id, + s.state, + s.company_id, + s.payment_term, + s.period_id, + s.fiscal_position, + s.currency_id, + s.journal_id ) """) account_invoice_report() diff --git a/addons/account/report/account_invoice_report_view.xml b/addons/account/report/account_invoice_report_view.xml index 6dbb5f336aa..00dd2b1304d 100644 --- a/addons/account/report/account_invoice_report_view.xml +++ b/addons/account/report/account_invoice_report_view.xml @@ -21,6 +21,11 @@ + + + + + @@ -88,11 +93,17 @@ + + + + + + diff --git a/addons/purchase/report/purchase_report.py b/addons/purchase/report/purchase_report.py index f5338e93723..d357e7c9aa5 100644 --- a/addons/purchase/report/purchase_report.py +++ b/addons/purchase/report/purchase_report.py @@ -90,10 +90,19 @@ class report_purchase_order(osv.osv): left join purchase_order_line l on (s.id=l.order_id) left join product_uom u on (u.id=l.product_uom) where l.product_id is not null - group by s.company_id,s.create_uid,s.partner_id, - s.location_id,l.product_id,s.date_order, - to_char(s.date_order, 'YYYY'),to_char(s.date_order, 'MM'),s.state, - s.warehouse_id,s.fiscal_position,s.invoice_method + group by + s.company_id, + s.create_uid, + s.partner_id, + s.location_id, + l.product_id, + s.date_order, + to_char(s.date_order, 'YYYY'), + to_char(s.date_order, 'MM'), + s.state, + s.warehouse_id, + s.fiscal_position, + s.invoice_method ) """) report_purchase_order() diff --git a/addons/sale/report/sale_report.py b/addons/sale/report/sale_report.py index 77cdb4d4cc3..6db3b9e044b 100644 --- a/addons/sale/report/sale_report.py +++ b/addons/sale/report/sale_report.py @@ -86,9 +86,16 @@ class sale_report(osv.osv): sale_order s on (s.id=l.order_id) left join product_uom u on (u.id=l.product_uom) group by - s.date_order, s.partner_id, l.product_id, - l.product_uom, s.user_id, s.state, s.shop_id, - s.company_id,s.fiscal_position,s.payment_term + s.date_order, + s.partner_id, + l.product_id, + l.product_uom, + s.user_id, + s.state, + s.shop_id, + s.company_id, + s.fiscal_position, + s.payment_term ) """) sale_report() From 9dd55852fec02872ddd9183df77c59ceb5c70e7a Mon Sep 17 00:00:00 2001 From: "nel@tinyerp.com" <> Date: Wed, 7 Apr 2010 12:36:13 +0200 Subject: [PATCH 031/188] indent bzr revid: nel@tinyerp.com-20100407103613-k3afaw3oynghw7sk --- addons/hr_holidays/hr_holidays.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/hr_holidays/hr_holidays.py b/addons/hr_holidays/hr_holidays.py index 6c11cbdf7a6..e49f6d91b63 100755 --- a/addons/hr_holidays/hr_holidays.py +++ b/addons/hr_holidays/hr_holidays.py @@ -256,7 +256,7 @@ class hr_holidays(osv.osv): 'number_of_days': nb, 'user_id': user_id }) - return True + return True def holidays_refuse(self, cr, uid, ids, *args): vals = { From 331f35ecd2ccf5a2933ed509b7d370560a65346a Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 7 Apr 2010 17:58:12 +0530 Subject: [PATCH 032/188] [IMP]:account:Improved SQL report.(Invoice) bzr revid: apa@tinyerp.com-20100407122812-c8bvo3zasnb1kkz2 --- addons/account/report/account_invoice_report_view.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/addons/account/report/account_invoice_report_view.xml b/addons/account/report/account_invoice_report_view.xml index 02cdeebf1a5..3e70983b8d4 100644 --- a/addons/account/report/account_invoice_report_view.xml +++ b/addons/account/report/account_invoice_report_view.xml @@ -98,7 +98,6 @@ - From 83874de62403aeaca95742bd2147d359b7975c0d Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Wed, 7 Apr 2010 18:47:58 +0530 Subject: [PATCH 033/188] [MOD] board_hr : Remaining leaves by user changed, leave type added bzr revid: vir@tinyerp.com-20100407131758-ckkdouqczlzb0ztw --- addons/board_hr/board_hr_view.xml | 2 +- addons/hr_holidays/report/hr_holidays_report.py | 17 +++++++++++------ .../report/hr_holidays_report_view.xml | 7 ++++--- 3 files changed, 16 insertions(+), 10 deletions(-) diff --git a/addons/board_hr/board_hr_view.xml b/addons/board_hr/board_hr_view.xml index b2c105691fe..432bcdac639 100644 --- a/addons/board_hr/board_hr_view.xml +++ b/addons/board_hr/board_hr_view.xml @@ -66,7 +66,7 @@ - + diff --git a/addons/hr_holidays/report/hr_holidays_report.py b/addons/hr_holidays/report/hr_holidays_report.py index 4bae007f281..a9ad1e0b161 100644 --- a/addons/hr_holidays/report/hr_holidays_report.py +++ b/addons/hr_holidays/report/hr_holidays_report.py @@ -77,8 +77,9 @@ class hr_holidays_remaining_leaves_user(osv.osv): _auto = False _columns = { 'name': fields.char('Employee',size=64), - 'no_of_leaves' : fields.integer('Remaining leaves'), - 'user_id':fields.many2one('res.users','User'), + 'no_of_leaves': fields.integer('Remaining leaves'), + 'user_id': fields.many2one('res.users','User'), + 'leave_type': fields.char('Leave Type',size=64), } def init(self, cr): @@ -89,13 +90,17 @@ class hr_holidays_remaining_leaves_user(osv.osv): min(hrs.id) as id, rr.name as name, sum(hrs.number_of_days) as no_of_leaves, - hrs.user_id + hrs.user_id, + hhs.name as leave_type from - hr_holidays as hrs, hr_employee as hre, resource_resource as rr + hr_holidays as hrs, hr_employee as hre, + resource_resource as rr,hr_holidays_status as hhs where - hrs.employee_id = hre.id and hre.resource_id = rr.id + hrs.employee_id = hre.id and + hre.resource_id = rr.id and + hhs.id = hrs.holiday_status_id group by - rr.name,hrs.user_id + rr.name,hrs.user_id,hhs.name ) """) hr_holidays_remaining_leaves_user() diff --git a/addons/hr_holidays/report/hr_holidays_report_view.xml b/addons/hr_holidays/report/hr_holidays_report_view.xml index 1ec3ed71a83..5314224ecfb 100644 --- a/addons/hr_holidays/report/hr_holidays_report_view.xml +++ b/addons/hr_holidays/report/hr_holidays_report_view.xml @@ -96,7 +96,8 @@ tree - + + @@ -108,9 +109,9 @@ graph - + + - From da25c77aa6c142d942d223620fb83677a694aea0 Mon Sep 17 00:00:00 2001 From: "Vir (Open ERP)" Date: Wed, 7 Apr 2010 19:07:31 +0530 Subject: [PATCH 034/188] [ADD] access rules for holiday reports bzr revid: vir@tinyerp.com-20100407133731-6599szskqnsso9de --- addons/hr_holidays/security/ir.model.access.csv | 3 +++ 1 file changed, 3 insertions(+) diff --git a/addons/hr_holidays/security/ir.model.access.csv b/addons/hr_holidays/security/ir.model.access.csv index a7426724594..246c84ec24a 100644 --- a/addons/hr_holidays/security/ir.model.access.csv +++ b/addons/hr_holidays/security/ir.model.access.csv @@ -3,3 +3,6 @@ "access_hr_holidays_user","hr holidays user","model_hr_holidays","hr.group_hr_user",1,1,1,0 "access_hr_holydays_status_manager","hr.holidays.status manager","model_hr_holidays_status","hr.group_hr_manager",1,1,1,1 "access_hr_holidays_manager","hr holidays manager","model_hr_holidays","hr.group_hr_manager",1,1,1,1 +"access_hr_holidays_report","hr.holidays.report","model_hr_holidays_report","hr.group_hr_manager",1,1,1,1 +"access_hr_holidays_remaining_leaves_user","hr.hr.holidays.remaining.leaves.user","model_hr_holidays_remaining_leaves_user","hr.group_hr_manager",1,1,1,1 +"access_available_holidays_report","hr.available.holidays.report","model_available_holidays_report","hr.group_hr_manager",1,1,1,1 From b905f21203b1383a33dbd5fbb2c7ee91519843d0 Mon Sep 17 00:00:00 2001 From: "RCH(Open ERP)" <> Date: Thu, 8 Apr 2010 14:32:26 +0530 Subject: [PATCH 035/188] [MOD] board_project : small changes in Project Dashboard bzr revid: vir@tinyerp.com-20100408090226-3uux8t24vd3qpuj3 --- addons/board_project/board_project_issue_view.xml | 2 +- addons/board_project/board_project_view.xml | 10 ++++++++-- addons/board_project/board_scrum_view.xml | 6 +++--- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/addons/board_project/board_project_issue_view.xml b/addons/board_project/board_project_issue_view.xml index 074adceef80..eaf3a2f8612 100644 --- a/addons/board_project/board_project_issue_view.xml +++ b/addons/board_project/board_project_issue_view.xml @@ -22,7 +22,7 @@ - + diff --git a/addons/board_project/board_project_view.xml b/addons/board_project/board_project_view.xml index 700f65e6dec..1825df2b043 100644 --- a/addons/board_project/board_project_view.xml +++ b/addons/board_project/board_project_view.xml @@ -103,8 +103,14 @@ - - + + + + + + + + diff --git a/addons/board_project/board_scrum_view.xml b/addons/board_project/board_scrum_view.xml index b07e565563d..112da0e6215 100644 --- a/addons/board_project/board_scrum_view.xml +++ b/addons/board_project/board_scrum_view.xml @@ -2,7 +2,7 @@ - Sprints List + Sprint's List scrum.sprint form tree,form @@ -16,14 +16,14 @@
- +
- Project Dashboard + Scrum Dashboard board.board form form From 05749150d35d29dd539f40581a49afadfdcd90e0 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 8 Apr 2010 14:53:29 +0530 Subject: [PATCH 036/188] [IMP]:mrp:Improved SQL report.(Production). bzr revid: apa@tinyerp.com-20100408092329-dkoyfzi1v1c6m67w --- addons/mrp/report/mrp_production_order.py | 80 ++++++++++++++----- .../mrp/report/mrp_production_order_view.xml | 74 +++++++++++------ 2 files changed, 111 insertions(+), 43 deletions(-) diff --git a/addons/mrp/report/mrp_production_order.py b/addons/mrp/report/mrp_production_order.py index d2299a19731..6a6c97f1409 100644 --- a/addons/mrp/report/mrp_production_order.py +++ b/addons/mrp/report/mrp_production_order.py @@ -30,14 +30,32 @@ class mrp_production_order(osv.osv): 'name': fields.char('Year',size=64,required=False, readonly=True), 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), ('10','October'), ('11','November'), ('12','December')],'Month',readonly=True), - 'reference': fields.char('Reference', size=64, required=True), 'origin': fields.char('Source Document', size=64), 'nbr': fields.integer('# of Orders', readonly=True), - 'product_id': fields.many2one('product.product', 'Product', required=True, domain=[('type','<>','service')]), - 'state': fields.selection([('draft','Draft'),('picking_except', 'Picking Exception'),('confirmed','Waiting Goods'),('ready','Ready to Produce'),('in_production','In Production'),('cancel','Cancelled'),('done','Done')],'State', readonly=True), - 'scheduled_date':fields.date('Scheduled Date'), + 'product_id': fields.many2one('product.product', 'Product', readonly=True, domain=[('type','<>','service')]), + 'product_qty': fields.float('Product Qty', readonly=True), + 'state': fields.selection([('draft','Draft'), + ('picking_except', 'Picking Exception'), + ('confirmed','Waiting Goods'), + ('ready','Ready to Produce'), + ('in_production','In Production'), + ('cancel','Cancelled'), + ('done','Done')], + 'State', readonly=True), + 'date_planned':fields.date('Scheduled Date'), 'location_src_id': fields.many2one('stock.location', 'Raw Materials Location', required=True), + 'date_start': fields.datetime('Start Date',readonly=True), + 'date_finnished': fields.datetime('End Date',readonly=True), 'location_dest_id': fields.many2one('stock.location', 'Finished Products Location', required=True), + 'company_id': fields.many2one('res.company','Company',readonly=True), + 'bom_id': fields.many2one('mrp.bom', 'Bill of Material', domain=[('bom_id','=',False)],readonly=True), + 'routing_id': fields.many2one('mrp.routing', string='Routing', on_delete='set null',readonly=True), + 'picking_id': fields.many2one('stock.picking', 'Picking list', readonly=True), + 'priority': fields.selection([('0','Not urgent'), + ('1','Normal'), + ('2','Urgent'), + ('3','Very Urgent')], + 'Priority',readonly=True), } @@ -46,20 +64,46 @@ class mrp_production_order(osv.osv): cr.execute(""" create or replace view mrp_production_order as ( select - min(c.id) as id, - to_char(c.create_date, 'YYYY') as name, - to_char(c.create_date, 'MM') as month, - c.state, - c.product_id, - count(*) as nbr, - to_date(to_char(c.date_planned, 'dd-MM-YYYY'),'dd-MM-YYYY') as scheduled_date, - c.name as reference, - c.origin, - c.location_src_id, - c.location_dest_id - from - mrp_production c - group by to_char(c.create_date, 'YYYY'), to_char(c.create_date, 'MM'), c.state,c.product_id,to_date(to_char(c.date_planned, 'dd-MM-YYYY'),'dd-MM-YYYY'),c.name,c.location_src_id,c.location_dest_id,c.origin + min(l.id) as id, + to_char(s.create_date, 'YYYY') as name, + to_char(s.create_date, 'MM') as month, + l.product_id as product_id, + sum(l.product_qty * u.factor) as product_qty, + s.company_id as company_id, + count(*) as nbr, + s.location_src_id, + s.location_dest_id, + s.bom_id, + s.routing_id, + s.picking_id, + s.date_start, + s.date_finnished, + s.date_planned, + s.origin, + s.priority, + s.state + from + mrp_production_product_line l + left join + mrp_production s on (s.id=l.production_id) + left join product_uom u on (u.id=l.product_uom) + group by + to_char(s.create_date, 'YYYY'), + to_char(s.create_date, 'MM'), + l.product_id, + l.product_uom, + s.bom_id, + s.routing_id, + s.picking_id, + s.priority, + s.location_src_id, + s.location_dest_id, + s.state, + s.date_planned, + s.origin, + s.date_start, + s.date_finnished, + s.company_id )""") mrp_production_order() # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/mrp/report/mrp_production_order_view.xml b/addons/mrp/report/mrp_production_order_view.xml index abb046bd685..6198cf0e109 100644 --- a/addons/mrp/report/mrp_production_order_view.xml +++ b/addons/mrp/report/mrp_production_order_view.xml @@ -11,20 +11,24 @@ tree - - - - - + + + + - - - + + + + + + + + - + mrp.production.order.graph @@ -59,28 +63,48 @@ - - + + - - + - + - + + + + + + + + + + + + + + + + + + + + + - - - - - + + + - - - - + + + + + + + From 47f9a817670022e1ac085fd55338340f4387ae17 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 8 Apr 2010 15:02:40 +0530 Subject: [PATCH 037/188] [IMP]:mrp:Improved code for SQL report.(Production). bzr revid: apa@tinyerp.com-20100408093240-3o374ys4gtz31bpf --- .../mrp/report/mrp_production_order_view.xml | 21 +++---------------- 1 file changed, 3 insertions(+), 18 deletions(-) diff --git a/addons/mrp/report/mrp_production_order_view.xml b/addons/mrp/report/mrp_production_order_view.xml index 6198cf0e109..32a1ef4d0b8 100644 --- a/addons/mrp/report/mrp_production_order_view.xml +++ b/addons/mrp/report/mrp_production_order_view.xml @@ -14,9 +14,9 @@ - - - + + + @@ -28,21 +28,6 @@ - mrp.production.order.graph From 297dae367cc5b74033c23ba1c50c3b1aa3bd00c7 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 8 Apr 2010 15:14:38 +0530 Subject: [PATCH 038/188] [IMP]:mrp:Improved code for SQL report.(Production). bzr revid: apa@tinyerp.com-20100408094438-q2srxncz04x8a4kg --- addons/mrp/report/mrp_production_order.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/mrp/report/mrp_production_order.py b/addons/mrp/report/mrp_production_order.py index 6a6c97f1409..7f48b111d43 100644 --- a/addons/mrp/report/mrp_production_order.py +++ b/addons/mrp/report/mrp_production_order.py @@ -78,7 +78,7 @@ class mrp_production_order(osv.osv): s.picking_id, s.date_start, s.date_finnished, - s.date_planned, + to_date(to_char(s.date_planned, 'dd-MM-YYYY'),'dd-MM-YYYY') as date_planned, s.origin, s.priority, s.state @@ -99,7 +99,7 @@ class mrp_production_order(osv.osv): s.location_src_id, s.location_dest_id, s.state, - s.date_planned, + to_date(to_char(s.date_planned, 'dd-MM-YYYY'),'dd-MM-YYYY'), s.origin, s.date_start, s.date_finnished, From 9c7b31e5969d024e3f0279b7c6b2e712a63b5249 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 8 Apr 2010 17:05:21 +0530 Subject: [PATCH 039/188] [IMP]:project:Improved SQL report.(Tasks). bzr revid: apa@tinyerp.com-20100408113521-5l5wsjekpi6pxnhm --- addons/project/report/project_report.py | 37 +++++++++++--- addons/project/report/project_report_view.xml | 51 ++++++++++++++----- 2 files changed, 68 insertions(+), 20 deletions(-) diff --git a/addons/project/report/project_report.py b/addons/project/report/project_report.py index e0b93c12d68..9fcebc27842 100644 --- a/addons/project/report/project_report.py +++ b/addons/project/report/project_report.py @@ -29,23 +29,35 @@ class report_project_task_user(osv.osv): _columns = { 'name': fields.char('Year',size=64,required=False, readonly=True), 'user_id':fields.many2one('res.users', 'User', readonly=True), - 'date_start': fields.datetime('Starting Date'), - 'date_end': fields.datetime('Ending Date'), - 'date_deadline': fields.date('Deadline'), + 'date_start': fields.datetime('Starting Date',readonly=True), + 'date_end': fields.datetime('Ending Date',readonly=True), + 'date_deadline': fields.date('Deadline',readonly=True), 'project_id':fields.many2one('project.project', 'Project', readonly=True), 'hours_planned': fields.float('Planned Hours', readonly=True), 'hours_effective': fields.float('Effective Hours', readonly=True), 'hours_delay': fields.float('Avg. Plan.-Eff.', readonly=True), 'closing_days': fields.char('Avg Closing Delay', size=64, readonly=True), 'nbr': fields.integer('#Number of tasks', readonly=True), + 'priority' : fields.selection([('4','Very Low'), + ('3','Low'), + ('2','Medium'), + ('1','Urgent'), + ('0','Very urgent')], + 'Importance',readonly=True), 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), ('10','October'), ('11','November'), ('12','December')],'Month',readonly=True), - 'state': fields.selection([('draft', 'Draft'), + 'state': fields.selection([ + ('draft', 'Draft'), ('open', 'In Progress'), ('pending', 'Pending'), ('cancelled', 'Cancelled'), ('done', 'Done')], 'State', readonly=True), + 'company_id': fields.many2one('res.company', 'Company',readonly=True), + 'partner_id': fields.many2one('res.partner', 'Partner',readonly=True), + 'type': fields.many2one('project.task.type', 'Stage',readonly=True), + + } _order = 'name desc, project_id' @@ -60,10 +72,14 @@ class report_project_task_user(osv.osv): count(distinct t.id) as nbr, date_trunc('day',t.date_start) as date_start, date_trunc('day',t.date_end) as date_end, - date_trunc('day',t.date_deadline) as date_deadline, + to_date(to_char(t.date_deadline, 'dd-MM-YYYY'),'dd-MM-YYYY') as date_deadline, t.user_id, t.project_id, t.state, + t.priority, + t.company_id, + t.partner_id, + t.type, sum(planned_hours) as hours_planned, to_char(avg(date_end::abstime-t.create_date::timestamp), 'DD"d" HH24:MI:SS') as closing_days, sum(w.hours) as hours_effective, @@ -73,8 +89,15 @@ class report_project_task_user(osv.osv): group by to_char(date_start, 'YYYY'), to_char(date_start, 'MM'), - t.user_id,t.state,t.date_end, - t.date_deadline,t.date_start, + t.priority, + t.user_id, + t.state, + t.date_end, + to_date(to_char(t.date_deadline, 'dd-MM-YYYY'),'dd-MM-YYYY'), + t.date_start, + t.company_id, + t.partner_id, + t.type, t.project_id ) """) diff --git a/addons/project/report/project_report_view.xml b/addons/project/report/project_report_view.xml index f3c619abe58..2d5d0f000c5 100644 --- a/addons/project/report/project_report_view.xml +++ b/addons/project/report/project_report_view.xml @@ -9,19 +9,23 @@ tree - - - - + + + + + + + + - - - - - - + + + + + + @@ -32,23 +36,44 @@ search + - - - + + + + + + + + + + + + + + + + + + + + + + + From 2263b035dae8c31b4b7e451bf0b440847eb835dd Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 8 Apr 2010 18:30:56 +0530 Subject: [PATCH 040/188] [IMP]:purchase:Improved SQL report.(Purchase). bzr revid: apa@tinyerp.com-20100408130056-0vfxahq44byou20c --- addons/purchase/report/purchase_report_view.xml | 1 - 1 file changed, 1 deletion(-) diff --git a/addons/purchase/report/purchase_report_view.xml b/addons/purchase/report/purchase_report_view.xml index 9fe66e1511d..2e6c393271d 100644 --- a/addons/purchase/report/purchase_report_view.xml +++ b/addons/purchase/report/purchase_report_view.xml @@ -89,7 +89,6 @@ - From 16e468b01bc1aaffe379140afaaef214d0e3dfc1 Mon Sep 17 00:00:00 2001 From: "nel@tinyerp.com" <> Date: Thu, 8 Apr 2010 16:29:24 +0200 Subject: [PATCH 041/188] [IMP] search views bzr revid: nel@tinyerp.com-20100408142924-j4vvkcbcw20gdtzy --- addons/board_hr/board_hr_view.xml | 2 +- addons/board_project/board_scrum_view.xml | 2 +- addons/hr_holidays/report/hr_holidays_report_view.xml | 6 +++--- addons/hr_holidays/security/ir.model.access.csv | 3 +++ addons/mrp/report/mrp_production_order_view.xml | 2 +- addons/project/project_view.xml | 6 +++--- addons/project/report/project_report_view.xml | 2 +- 7 files changed, 13 insertions(+), 10 deletions(-) diff --git a/addons/board_hr/board_hr_view.xml b/addons/board_hr/board_hr_view.xml index 432bcdac639..ed27a93a326 100644 --- a/addons/board_hr/board_hr_view.xml +++ b/addons/board_hr/board_hr_view.xml @@ -21,7 +21,7 @@ hr_timesheet_sheet.sheet form - [('date_to','>=',time.strftime('%Y-%m-01')),('date_from','<=',time.strftime('%Y-%m-01'))] + [('date_to','>=',time.strftime('%Y-%m-01')),('date_from','<=',time.strftime('%Y-%m-01')),('user_id','=',uid)] diff --git a/addons/board_project/board_scrum_view.xml b/addons/board_project/board_scrum_view.xml index 112da0e6215..45628733ad3 100644 --- a/addons/board_project/board_scrum_view.xml +++ b/addons/board_project/board_scrum_view.xml @@ -32,7 +32,7 @@ diff --git a/addons/hr_holidays/report/hr_holidays_report_view.xml b/addons/hr_holidays/report/hr_holidays_report_view.xml index 5314224ecfb..f0d33bc7b98 100644 --- a/addons/hr_holidays/report/hr_holidays_report_view.xml +++ b/addons/hr_holidays/report/hr_holidays_report_view.xml @@ -109,9 +109,9 @@ graph - - - + + + diff --git a/addons/hr_holidays/security/ir.model.access.csv b/addons/hr_holidays/security/ir.model.access.csv index 246c84ec24a..d928a8dcb9b 100644 --- a/addons/hr_holidays/security/ir.model.access.csv +++ b/addons/hr_holidays/security/ir.model.access.csv @@ -3,6 +3,9 @@ "access_hr_holidays_user","hr holidays user","model_hr_holidays","hr.group_hr_user",1,1,1,0 "access_hr_holydays_status_manager","hr.holidays.status manager","model_hr_holidays_status","hr.group_hr_manager",1,1,1,1 "access_hr_holidays_manager","hr holidays manager","model_hr_holidays","hr.group_hr_manager",1,1,1,1 +"access_hr_holidays_remain","hr holidays user","model_hr_holidays_remaining_leaves_user","hr.group_hr_user",1,0,0,0 "access_hr_holidays_report","hr.holidays.report","model_hr_holidays_report","hr.group_hr_manager",1,1,1,1 "access_hr_holidays_remaining_leaves_user","hr.hr.holidays.remaining.leaves.user","model_hr_holidays_remaining_leaves_user","hr.group_hr_manager",1,1,1,1 "access_available_holidays_report","hr.available.holidays.report","model_available_holidays_report","hr.group_hr_manager",1,1,1,1 +"access_hr_holidays_report_user","hr.holidays.report","model_hr_holidays_report","hr.group_hr_user",1,0,0,0 +"access_available_holidays_report_user","hr.available.holidays.report","model_available_holidays_report","hr.group_hr_user",1,0,0,0 diff --git a/addons/mrp/report/mrp_production_order_view.xml b/addons/mrp/report/mrp_production_order_view.xml index 32a1ef4d0b8..75838557d9f 100644 --- a/addons/mrp/report/mrp_production_order_view.xml +++ b/addons/mrp/report/mrp_production_order_view.xml @@ -84,7 +84,7 @@ - + diff --git a/addons/project/project_view.xml b/addons/project/project_view.xml index 62e1ecc3c62..3eb78f59faf 100644 --- a/addons/project/project_view.xml +++ b/addons/project/project_view.xml @@ -30,7 +30,7 @@ - + @@ -119,7 +119,7 @@ - + @@ -420,7 +420,7 @@ - + diff --git a/addons/project/report/project_report_view.xml b/addons/project/report/project_report_view.xml index f3c619abe58..f904f38b88c 100644 --- a/addons/project/report/project_report_view.xml +++ b/addons/project/report/project_report_view.xml @@ -46,7 +46,7 @@ - + From 1b2c83c8fb5b5c200f22ae622f3bdb2e53f5e0f5 Mon Sep 17 00:00:00 2001 From: "nel@tinyerp.com" <> Date: Fri, 9 Apr 2010 10:22:51 +0200 Subject: [PATCH 042/188] revert merge bzr revid: nel@tinyerp.com-20100409082251-xf1r7upp83566a30 --- addons/account/__terp__.py | 4 +- .../{test => demo}/price_accuracy00.yml | 10 +- addons/account/i18n/cs.po | 232 +++--- .../report/account_invoice_report_view.xml | 65 +- addons/account/test/test_parent_structure.py | 54 ++ addons/account/test/test_parent_structure.yml | 11 +- addons/account_payment/i18n/cs.po | 44 +- addons/audittrail/i18n/it.po | 18 +- addons/base_contact/i18n/ko.po | 2 +- addons/base_setup/i18n/fa.po | 283 ------- addons/crm/crm_claims_menu.xml | 1 - addons/crm/crm_claims_view.xml | 16 +- addons/crm/crm_fund_menu.xml | 1 - addons/crm/crm_fund_view.xml | 14 +- addons/crm/crm_helpdesk_menu.xml | 1 - addons/crm/crm_helpdesk_view.xml | 11 +- addons/crm/crm_lead_menu.xml | 2 - addons/crm/crm_lead_view.xml | 9 +- addons/crm/crm_meeting_menu.xml | 38 +- addons/crm/crm_meeting_view.xml | 10 +- addons/crm/crm_opportunity.py | 2 +- addons/crm/crm_opportunity_menu.xml | 1 - addons/crm/crm_opportunity_view.xml | 24 +- addons/crm/crm_phonecall_menu.xml | 3 +- addons/crm/crm_phonecall_view.xml | 9 +- addons/crm/crm_report_view.xml | 1 + addons/crm/crm_view.xml | 12 +- addons/crm/i18n/fi.po | 2 +- addons/crm/report/crm_claim_report_view.xml | 1 - .../report/crm_fundraising_report_view.xml | 1 - .../crm/report/crm_helpdesk_report_view.xml | 9 +- addons/crm/report/crm_lead_report_view.xml | 1 - .../report/crm_opportunity_report_view.xml | 1 - .../crm/report/crm_phonecall_report_view.xml | 1 - addons/crm/report/crm_report_view.xml | 8 +- addons/crm/wizard/crm_send_email.py | 2 +- addons/crm/wizard/crm_send_email_view.xml | 1 - addons/hr/hr_view.xml | 2 +- addons/hr_evaluation/hr_evaluation.py | 45 -- addons/hr_evaluation/hr_evaluation_view.xml | 16 +- addons/hr_expense/hr_expense_view.xml | 9 +- .../report/hr_expense_report_view.xml | 11 +- addons/hr_holidays/hr_holidays_report.xml | 89 +-- addons/hr_holidays/hr_holidays_view.xml | 10 +- .../hr_holidays/report/available_holidays.py | 20 + .../report/hr_holidays_report_view.xml | 6 +- addons/hr_recruitment/hr_recruitment.py | 137 +--- addons/hr_recruitment/hr_recruitment_menu.xml | 1 - addons/hr_recruitment/hr_recruitment_view.xml | 40 +- .../hr_recruitment/hr_recruitment_wizard.xml | 8 + .../report/hr_recruitment_report_view.xml | 4 +- .../wizard/hr_recruitment_wizard.py | 55 ++ addons/hr_timesheet/i18n/de.po | 2 +- .../hr_timesheet_sheet_view.xml | 2 +- addons/mrp/mrp_view.xml | 11 +- addons/mrp/mrp_workflow.xml | 24 +- .../mrp/report/mrp_production_order_view.xml | 5 +- addons/olap_extract/i18n/zh_CN.po | 56 -- addons/product/partner_view.xml | 2 +- addons/product/pricelist_view.xml | 5 +- addons/project/project_view.xml | 59 +- addons/project/report/project_report.py | 37 +- addons/project/report/project_report_view.xml | 72 +- addons/project_issue/project_issue_menu.xml | 5 +- addons/project_issue/project_issue_view.xml | 20 +- .../project_long_term_view.xml | 5 +- .../report/task_report_view.xml | 10 +- addons/purchase/partner_view.xml | 2 +- .../purchase/report/purchase_report_view.xml | 12 +- addons/purchase_tender/__terp__.py | 2 +- addons/purchase_tender/purchase_tender.py | 49 +- .../purchase_tender/purchase_tender_view.xml | 142 ++-- addons/report_purchase/i18n/ko.po | 2 +- addons/resource/resource_view.xml | 5 +- addons/sale/report/sale_report_view.xml | 16 +- addons/sale/sale_view.xml | 23 +- addons/scrum/i18n/ko.po | 2 +- addons/scrum/scrum_view.xml | 18 +- addons/stock/__terp__.py | 1 + .../report/report_stock_picking_view.xml | 11 +- addons/stock/report/report_stock_view.xml | 6 +- addons/stock/security/ir.model.access.csv | 4 +- addons/stock/stock.py | 44 ++ addons/stock/stock_view.xml | 248 +++++-- addons/stock/wizard/__init__.py | 1 + addons/stock/wizard/stock_partial_move.py | 108 +-- addons/stock/wizard/stock_split_move.py | 125 ++++ addons/stock/wizard/stock_split_move_view.xml | 17 +- addons/survey/i18n/zh_CN.po | 695 ------------------ addons/survey/survey.py | 40 - addons/survey/survey_view.xml | 8 +- addons/thunderbird/i18n/zh_CN.po | 85 --- 92 files changed, 1126 insertions(+), 2213 deletions(-) rename addons/account/{test => demo}/price_accuracy00.yml (91%) create mode 100644 addons/account/test/test_parent_structure.py delete mode 100644 addons/base_setup/i18n/fa.po delete mode 100644 addons/olap_extract/i18n/zh_CN.po create mode 100644 addons/stock/wizard/stock_split_move.py delete mode 100644 addons/survey/i18n/zh_CN.po delete mode 100644 addons/thunderbird/i18n/zh_CN.po diff --git a/addons/account/__terp__.py b/addons/account/__terp__.py index 7f317257ab0..dfc22a2d5fe 100644 --- a/addons/account/__terp__.py +++ b/addons/account/__terp__.py @@ -80,15 +80,13 @@ module named account_voucherss 'report/account_analytic_report_view.xml', ], 'demo_xml': [ + #'demo/price_accuracy00.yml', 'account_demo.xml', 'project/project_demo.xml', 'project/analytic_account_demo.xml', 'demo/account_minimal.xml', 'account_unit_test.xml', ], - 'test': [ - 'test/price_accuracy00.yml', - ], 'installable': True, 'active': False, 'certificate': '0080331923549', diff --git a/addons/account/test/price_accuracy00.yml b/addons/account/demo/price_accuracy00.yml similarity index 91% rename from addons/account/test/price_accuracy00.yml rename to addons/account/demo/price_accuracy00.yml index a3cfc154ad9..81023395141 100644 --- a/addons/account/test/price_accuracy00.yml +++ b/addons/account/demo/price_accuracy00.yml @@ -44,6 +44,7 @@ Then I should see an account entry linked to this invoice. - !assert {model: account.invoice, id: invoice1}: + test: - bool(move_id) - # This is not working, find a way to do that in YAML, *qty is not @@ -52,12 +53,14 @@ equal to *qty x *price x (1 + *tax) - !assert {model: account.invoice, id: invoice1}: - - abs(sum(x.credit for x in move_id.line_id) - 163.97) < 0.000001 + test: + - abs(sum(x.credit for x in move_id.line_id) - 163.97) < 0.000001 - And this account entry must have a credit equals to the debit - !assert {model: account.invoice, id: invoice1}: - - abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001 + test: + - abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001 - Then, I change the precision of numbers to 3 digits. - @@ -77,7 +80,8 @@ Then this account entry must have a credit equals to the debit - !assert {model: account.invoice, id: invoice2}: - - abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001 + test: + - abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001 - And this account entry must have a credit equals to 163.968€ which is equal to *qty x *price x (1 + *tax) diff --git a/addons/account/i18n/cs.po b/addons/account/i18n/cs.po index 889f5b746b8..faff571118c 100644 --- a/addons/account/i18n/cs.po +++ b/addons/account/i18n/cs.po @@ -7,13 +7,13 @@ msgstr "" "Project-Id-Version: OpenERP Server 5.0.0\n" "Report-Msgid-Bugs-To: support@openerp.com\n" "POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-04-08 18:06+0000\n" +"PO-Revision-Date: 2010-04-01 22:39+0000\n" "Last-Translator: mitev.dmitry \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n" +"X-Launchpad-Export-Date: 2010-04-03 03:54+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: account @@ -115,7 +115,7 @@ msgstr "Rodič" #. module: account #: selection:account.move,type:0 msgid "Journal Voucher" -msgstr "Rada" +msgstr "" #. module: account #: field:account.invoice,residual:0 @@ -134,7 +134,7 @@ msgstr "Základní kódová značka" #: model:ir.actions.wizard,name:account.wizard_unreconcile_select #: model:ir.ui.menu,name:account.menu_unreconcile_select msgid "Unreconcile entries" -msgstr "Nepotvrzené záznamy" +msgstr "" #. module: account #: constraint:account.period:0 @@ -159,7 +159,7 @@ msgstr "Debetní Centralizace" #. module: account #: model:ir.actions.wizard,name:account.wizard_invoice_state_confirm msgid "Confirm draft invoices" -msgstr "Potvrdit návrh faktury" +msgstr "" #. module: account #: help:account.payment.term.line,days2:0 @@ -182,7 +182,7 @@ msgstr "Grafy účtu" #. module: account #: model:ir.actions.wizard,name:account.wizard_move_line_select msgid "Move line select" -msgstr "Přesun řádku vyberte" +msgstr "" #. module: account #: rml:account.journal.period.print:0 @@ -310,7 +310,7 @@ msgstr "Původ" #. module: account #: rml:account.analytic.account.journal:0 msgid "Move Name" -msgstr "Název Pohybu" +msgstr "" #. module: account #: xsl:account.transfer:0 @@ -325,7 +325,7 @@ msgstr "Vypočítat předpaltné(Subscription Compute)" #. module: account #: rml:account.central.journal:0 msgid "Account Num." -msgstr "Číslo účtu" +msgstr "" #. module: account #: rml:account.analytic.account.analytic.check:0 @@ -337,12 +337,12 @@ msgstr "" #: field:account.invoice,amount_tax:0 #: field:account.move.line,account_tax_id:0 msgid "Tax" -msgstr "Daň" +msgstr "" #. module: account #: rml:account.general.journal:0 msgid "Debit Trans." -msgstr "Debetní transakce" +msgstr "" #. module: account #: field:account.analytic.line,account_id:0 @@ -356,24 +356,24 @@ msgstr "Analytický účet" #: field:account.tax,child_depend:0 #: field:account.tax.template,child_depend:0 msgid "Tax on Children" -msgstr "Daň z dětí" +msgstr "" #. module: account #: rml:account.central.journal:0 #: rml:account.general.journal:0 #: field:account.journal,name:0 msgid "Journal Name" -msgstr "Název časopisu" +msgstr "" #. module: account #: view:account.payment.term:0 msgid "Description on invoices" -msgstr "Popis na fakturách" +msgstr "" #. module: account #: constraint:account.analytic.account:0 msgid "Error! You can not create recursive analytic accounts." -msgstr "Chyba! Nemůžete vytvářet rekurzivní analytické účty." +msgstr "" #. module: account #: field:account.bank.statement.reconcile,total_entry:0 @@ -389,13 +389,13 @@ msgstr "Zdroj účtu" #. module: account #: field:account.journal,update_posted:0 msgid "Allow Cancelling Entries" -msgstr "Povolit Zrušení Příspěvky" +msgstr "" #. module: account #: model:process.transition,name:account.process_transition_paymentorderbank0 #: model:process.transition,name:account.process_transition_paymentorderreconcilation0 msgid "Payment Reconcilation" -msgstr "Platba usmíření" +msgstr "" #. module: account #: model:account.journal,name:account.expenses_journal @@ -425,7 +425,7 @@ msgstr "(Účet / Partner) Název" #. module: account #: selection:account.move,type:0 msgid "Contra" -msgstr "Kontraindikace" +msgstr "" #. module: account #: field:account.analytic.account,state:0 @@ -447,7 +447,7 @@ msgstr "" #: view:account.tax:0 #: view:account.tax.template:0 msgid "Special Computation" -msgstr "Speciální výpočetní" +msgstr "" #. module: account #: model:process.transition,note:account.process_transition_confirmstatementfromdraft0 @@ -506,7 +506,7 @@ msgstr "" #. module: account #: view:account.invoice:0 msgid "Supplier invoice" -msgstr "Dodavatele uvedený na faktuře" +msgstr "" #. module: account #: model:process.transition,name:account.process_transition_reconcilepaid0 @@ -533,7 +533,7 @@ msgstr "" #. module: account #: field:account.account.type,close_method:0 msgid "Deferral Method" -msgstr "Metoda zpoždění" +msgstr "" #. module: account #: field:account.tax.template,include_base_amount:0 @@ -560,7 +560,7 @@ msgstr "" #: selection:account.tax,applicable_type:0 #: selection:account.tax.template,applicable_type:0 msgid "True" -msgstr "Pravda" +msgstr "" #. module: account #: help:account.payment.term.line,days:0 @@ -577,7 +577,7 @@ msgstr "" #. module: account #: rml:account.central.journal:0 msgid "Printing Date" -msgstr "Datum vydání" +msgstr "" #. module: account #: rml:account.general.ledger:0 @@ -593,7 +593,7 @@ msgstr "" #. module: account #: view:account.journal:0 msgid "Entry Controls" -msgstr "Vstupní kontrolou" +msgstr "" #. module: account #: help:account.model.line,sequence:0 @@ -616,13 +616,13 @@ msgstr "" #. module: account #: field:account.analytic.account,contact_id:0 msgid "Contact" -msgstr "Kontakt" +msgstr "" #. module: account #: selection:account.model.line,date:0 #: selection:account.model.line,date_maturity:0 msgid "Partner Payment Term" -msgstr "Partner splatnosti" +msgstr "" #. module: account #: view:account.move.reconcile:0 @@ -637,13 +637,13 @@ msgstr "Otevřeno pro bankovní vyrovnání(Open for bank reconciliation)" #. module: account #: field:account.invoice.line,discount:0 msgid "Discount (%)" -msgstr "Sleva (%)" +msgstr "" #. module: account #: wizard_field:account.move.line.reconcile,init_full,writeoff:0 #: wizard_field:account.move.line.reconcile,init_partial,writeoff:0 msgid "Write-Off amount" -msgstr "Odpis části" +msgstr "" #. module: account #: help:account.fiscalyear,company_id:0 @@ -653,7 +653,7 @@ msgstr "" #. module: account #: model:ir.ui.menu,name:account.menu_analytic_accounting msgid "Analytic Accounting" -msgstr "Analytické účetnictví" +msgstr "" #. module: account #: rml:account.overdue:0 @@ -666,22 +666,22 @@ msgstr "" #: model:ir.actions.act_window,name:account.action_account_analytic_line_form #: model:ir.ui.menu,name:account.next_id_41 msgid "Analytic Entries" -msgstr "Analytická Příspěvky" +msgstr "" #. module: account #: selection:account.subscription,period_type:0 msgid "month" -msgstr "měsíc" +msgstr "" #. module: account #: field:account.analytic.account,partner_id:0 msgid "Associated Partner" -msgstr "Přidruženého partnera" +msgstr "" #. module: account #: field:account.invoice,comment:0 msgid "Additional Information" -msgstr "Další informace" +msgstr "" #. module: account #: selection:account.invoice,type:0 @@ -719,18 +719,18 @@ msgstr "" #. module: account #: model:process.transition,name:account.process_transition_supplieranalyticcost0 msgid "Analytic Invoice" -msgstr "Analytická faktury" +msgstr "" #. module: account #: field:account.journal.column,field:0 msgid "Field Name" -msgstr "Název pole" +msgstr "" #. module: account #: field:account.tax.code,sign:0 #: field:account.tax.code.template,sign:0 msgid "Sign for parent" -msgstr "Přihlaste se na mateřské" +msgstr "" #. module: account #: field:account.fiscalyear,end_journal_period_id:0 @@ -741,7 +741,7 @@ msgstr "" #: view:product.product:0 #: view:product.template:0 msgid "Purchase Properties" -msgstr "Nákup Nemovitosti" +msgstr "" #. module: account #: model:process.node,note:account.process_node_paymententries0 @@ -751,12 +751,12 @@ msgstr "" #. module: account #: wizard_button:account.invoice.pay,init,reconcile:0 msgid "Partial Payment" -msgstr "Částečná platba" +msgstr "" #. module: account #: wizard_view:account_use_models,create:0 msgid "Move Lines Created." -msgstr "Přesun vytvořených linek." +msgstr "" #. module: account #: field:account.fiscalyear,state:0 @@ -766,18 +766,18 @@ msgstr "Přesun vytvořených linek." #: field:account.period,state:0 #: field:account.subscription,state:0 msgid "Status" -msgstr "Stav" +msgstr "" #. module: account #: rml:account.analytic.account.cost_ledger:0 #: rml:account.analytic.account.quantity_cost_ledger:0 msgid "Period to" -msgstr "Období do" +msgstr "" #. module: account #: field:account.account.type,partner_account:0 msgid "Partner account" -msgstr "Partner účet" +msgstr "" #. module: account #: wizard_view:account.subscription.generate,init:0 @@ -803,7 +803,7 @@ msgstr "" #. module: account #: field:account.invoice,move_lines:0 msgid "Move Lines" -msgstr "Přesun Linky" +msgstr "" #. module: account #: model:ir.model,name:account.model_account_config_wizard @@ -831,26 +831,26 @@ msgstr "" #. module: account #: model:ir.ui.menu,name:account.next_id_30 msgid "Bank Reconciliation" -msgstr "Bankovní usmíření" +msgstr "" #. module: account #: model:ir.model,name:account.model_account_account_template msgid "Templates for Accounts" -msgstr "Šablony pro účty" +msgstr "" #. module: account #: model:ir.actions.act_window,name:account.action_account_analytic_account_form #: model:ir.model,name:account.model_account_analytic_account #: model:ir.ui.menu,name:account.account_analytic_def_account msgid "Analytic Accounts" -msgstr "Analytické účty" +msgstr "" #. module: account #: wizard_view:account.print.journal.report,init:0 #: model:ir.actions.wizard,name:account.wizard_print_journal #: model:ir.ui.menu,name:account.menu_print_journal msgid "Print Journal" -msgstr "Tisk věstníku" +msgstr "" #. module: account #: model:ir.model,name:account.model_account_bank_accounts_wizard @@ -861,39 +861,39 @@ msgstr "" #: field:account.move.line,date_created:0 #: field:account.move.reconcile,create_date:0 msgid "Creation date" -msgstr "Datum vytvoření" +msgstr "" #. module: account #: wizard_button:account.invoice.refund,init,cancel_invoice:0 msgid "Cancel Invoice" -msgstr "Zrušit účet" +msgstr "" #. module: account #: field:account.journal.column,required:0 msgid "Required" -msgstr "Požadované" +msgstr "" #. module: account #: field:product.category,property_account_expense_categ:0 #: field:product.template,property_account_expense:0 msgid "Expense Account" -msgstr "Cestovní účet" +msgstr "" #. module: account #: wizard_field:account.move.line.reconcile,addendum,journal_id:0 msgid "Write-Off Journal" -msgstr "Odpis věstníku" +msgstr "" #. module: account #: field:account.model.line,amount_currency:0 #: field:account.move.line,amount_currency:0 msgid "Amount Currency" -msgstr "Částka měny" +msgstr "" #. module: account #: field:account.chart.template,property_account_expense_categ:0 msgid "Expense Category Account" -msgstr "Kategorie výdajů účtu" +msgstr "" #. module: account #: wizard_field:account.fiscalyear.close,init,fy2_id:0 @@ -910,7 +910,7 @@ msgstr "" #. module: account #: wizard_field:account.open_closed_fiscalyear,init,fyear_id:0 msgid "Fiscal Year to Open" -msgstr "Fiskální rok otevřena" +msgstr "" #. module: account #: view:account.config.wizard:0 @@ -928,7 +928,7 @@ msgstr "" #: field:account.model.line,quantity:0 #: field:account.move.line,quantity:0 msgid "Quantity" -msgstr "Množství" +msgstr "" #. module: account #: wizard_field:account.account.balance.report,checktype,date_to:0 @@ -936,7 +936,7 @@ msgstr "Množství" #: wizard_field:account.partner.balance.report,init,date2:0 #: wizard_field:account.third_party_ledger.report,init,date2:0 msgid "End date" -msgstr "Datum ukončení" +msgstr "" #. module: account #: field:account.invoice.tax,base_amount:0 @@ -957,12 +957,12 @@ msgstr "" #: model:ir.actions.act_window,name:account.action_bank_statement_tree #: model:ir.ui.menu,name:account.menu_bank_statement_tree msgid "Entries by Statements" -msgstr "Příspěvky výroky" +msgstr "" #. module: account #: model:process.transition,name:account.process_transition_analyticinvoice0 msgid "analytic Invoice" -msgstr "analytické faktury" +msgstr "" #. module: account #: wizard_field:account.automatic.reconcile,init,period_id:0 @@ -981,22 +981,22 @@ msgstr "analytické faktury" #: wizard_field:account.print.journal.report,init,period_id:0 #: field:account.subscription,period_nbr:0 msgid "Period" -msgstr "Perioda" +msgstr "" #. module: account #: rml:account.partner.balance:0 msgid "Grand total" -msgstr "Úhrn" +msgstr "" #. module: account #: model:ir.ui.menu,name:account.menu_finance_accounting msgid "Financial Accounting" -msgstr "Finanční účetnictví" +msgstr "" #. module: account #: rml:account.invoice:0 msgid "Net Total:" -msgstr "Čistá celkem:" +msgstr "" #. module: account #: view:account.fiscal.position:0 @@ -1010,7 +1010,7 @@ msgstr "Čistá celkem:" #: model:ir.model,name:account.model_account_fiscal_position #: field:res.partner,property_account_position:0 msgid "Fiscal Position" -msgstr "Fiskální pozice" +msgstr "" #. module: account #: field:account.analytic.line,product_uom_id:0 @@ -1027,7 +1027,7 @@ msgstr "" #: field:account.account,child_parent_ids:0 #: field:account.account.template,child_parent_ids:0 msgid "Children" -msgstr "Děti" +msgstr "" #. module: account #: model:ir.model,name:account.model_account_fiscal_position_tax @@ -1038,35 +1038,35 @@ msgstr "" #: model:ir.actions.act_window,name:account.action_invoice_tree2_new #: model:ir.ui.menu,name:account.menu_action_invoice_tree2_new msgid "New Supplier Invoice" -msgstr "Nového dodavatele faktury" +msgstr "" #. module: account #: wizard_field:account.invoice.pay,init,amount:0 msgid "Amount paid" -msgstr "Zaplacené částky" +msgstr "" #. module: account #: selection:account.invoice,type:0 #: model:process.transition,name:account.process_transition_customerinvoice0 #: model:process.transition,name:account.process_transition_suppliercustomerinvoice0 msgid "Customer Invoice" -msgstr "Zákazník faktury" +msgstr "" #. module: account #: wizard_view:account.open_closed_fiscalyear,init:0 msgid "Choose Fiscal Year" -msgstr "Vyberte si fiskální rok" +msgstr "" #. module: account #: field:account.sequence.fiscalyear,sequence_main_id:0 msgid "Main Sequence" -msgstr "Hlavní posloupnosti" +msgstr "" #. module: account #: model:ir.actions.act_window,name:account.action_account_analytic_journal_tree #: model:ir.ui.menu,name:account.account_analytic_journal_print msgid "Print Analytic Journals" -msgstr "Tisk Analytické Časopisy" +msgstr "" #. module: account #: rml:account.tax.code.entries:0 @@ -1083,7 +1083,7 @@ msgstr "" #. module: account #: field:account.bank.statement.reconcile,total_new:0 msgid "Total write-off" -msgstr "Celkem odpis" +msgstr "" #. module: account #: view:account.tax.template:0 @@ -1095,14 +1095,14 @@ msgstr "" #: model:ir.actions.act_window,name:account.action_tax_code_list #: model:ir.ui.menu,name:account.menu_action_tax_code_list msgid "Tax codes" -msgstr "Daňové kódy" +msgstr "" #. module: account #: field:account.fiscal.position.template,chart_template_id:0 #: field:account.tax.template,chart_template_id:0 #: field:wizard.multi.charts.accounts,chart_template_id:0 msgid "Chart Template" -msgstr "Graf šablony" +msgstr "" #. module: account #: field:account.chart.template,property_account_income_categ:0 @@ -1113,24 +1113,24 @@ msgstr "" #: model:ir.actions.act_window,name:account.analytic_account_form #: model:ir.ui.menu,name:account.account_analytic_form msgid "New Analytic Account" -msgstr "Nový analitickiý účet" +msgstr "" #. module: account #: model:ir.actions.act_window,name:account.action_account_fiscal_position_template_form #: model:ir.ui.menu,name:account.menu_action_account_fiscal_position_form_template msgid "Fiscal Position Templates" -msgstr "Fiskální pozice Šablony" +msgstr "" #. module: account #: rml:account.invoice:0 #: field:account.invoice.line,price_unit:0 msgid "Unit Price" -msgstr "Cena za kus" +msgstr "" #. module: account #: rml:account.analytic.account.journal:0 msgid "Period from :" -msgstr "Období od:" +msgstr "" #. module: account #: model:ir.model,name:account.model_wizard_multi_charts_accounts @@ -1140,7 +1140,7 @@ msgstr "" #. module: account #: model:account.journal,name:account.sales_journal msgid "Journal de vente" -msgstr "Prodej věstníku" +msgstr "" #. module: account #: help:account.model.line,amount_currency:0 @@ -1151,23 +1151,23 @@ msgstr "" #: view:account.fiscal.position.template:0 #: field:account.fiscal.position.template,name:0 msgid "Fiscal Position Template" -msgstr "Fiskální pozice šablony" +msgstr "" #. module: account #: field:account.payment.term,line_ids:0 msgid "Terms" -msgstr "Podmínky" +msgstr "" #. module: account #: rml:account.vat.declaration:0 msgid "Tax Report" -msgstr "Daňové Report" +msgstr "" #. module: account #: wizard_button:account.analytic.account.chart,init,open:0 #: wizard_button:account.chart,init,open:0 msgid "Open Charts" -msgstr "Zobrazit Grafy" +msgstr "" #. module: account #: wizard_view:account.fiscalyear.close.state,init:0 @@ -1177,7 +1177,7 @@ msgstr "" #. module: account #: selection:account.move,type:0 msgid "Bank Receipt" -msgstr "Bankovní Příjem" +msgstr "" #. module: account #: view:res.partner:0 @@ -1187,17 +1187,17 @@ msgstr "Bankovní účet" #. module: account #: field:account.chart.template,tax_template_ids:0 msgid "Tax Template List" -msgstr "Daňové seznamu šablon" +msgstr "" #. module: account #: model:process.transition,name:account.process_transition_invoiceimport0 msgid "Invoice import" -msgstr "Faktura import" +msgstr "" #. module: account #: model:ir.actions.wizard,name:account.action_move_journal_line_form_select msgid "Standard entry" -msgstr "Standardní vstupní" +msgstr "" #. module: account #: help:account.account,currency_mode:0 @@ -1212,7 +1212,7 @@ msgstr "" #. module: account #: field:account.account,company_currency_id:0 msgid "Company Currency" -msgstr "Společnost měny" +msgstr "" #. module: account #: model:ir.model,name:account.model_account_fiscal_position_account_template @@ -1222,7 +1222,7 @@ msgstr "" #. module: account #: field:account.analytic.account,parent_id:0 msgid "Parent Analytic Account" -msgstr "Parent Analytická účtu" +msgstr "" #. module: account #: wizard_button:account.move.line.reconcile,init_partial,addendum:0 @@ -1242,22 +1242,22 @@ msgstr "" #. module: account #: field:account.bank.statement,balance_end_real:0 msgid "Ending Balance" -msgstr "Konečný zůstatek" +msgstr "" #. module: account #: view:product.product:0 msgid "Purchase Taxes" -msgstr "Nákup Daně" +msgstr "" #. module: account #: field:account.payment.term.line,name:0 msgid "Line Name" -msgstr "Název řádku" +msgstr "" #. module: account #: selection:account.payment.term.line,value:0 msgid "Fixed Amount" -msgstr "Pevná částka" +msgstr "" #. module: account #: rml:account.analytic.account.analytic.check:0 @@ -1285,24 +1285,24 @@ msgstr "" #. module: account #: view:account.config.wizard:0 msgid "Continue" -msgstr "Pokračovat" +msgstr "" #. module: account #: field:account.payment.term.line,value:0 msgid "Value" -msgstr "Hodnota" +msgstr "" #. module: account #: wizard_field:account.invoice.pay,addendum,writeoff_acc_id:0 #: wizard_field:account.move.line.reconcile,addendum,writeoff_acc_id:0 msgid "Write-Off account" -msgstr "Odpis účet" +msgstr "" #. module: account #: field:account.model.line,model_id:0 #: field:account.subscription,model_id:0 msgid "Model" -msgstr "Vzor" +msgstr "" #. module: account #: model:ir.actions.wizard,name:account.wizard_fiscalyear_close_state @@ -1313,12 +1313,12 @@ msgstr "" #. module: account #: field:account.journal,centralisation:0 msgid "Centralised counterpart" -msgstr "Centralizované protějšek" +msgstr "" #. module: account #: view:wizard.company.setup:0 msgid "Message" -msgstr "Zpráva" +msgstr "" #. module: account #: model:process.node,note:account.process_node_supplierpaymentorder0 @@ -1332,7 +1332,7 @@ msgstr "" #: selection:account.analytic.account,type:0 #: field:account.journal,view_id:0 msgid "View" -msgstr "Pohled" +msgstr "" #. module: account #: selection:account.account.balance.report,checktype,display_account:0 @@ -1340,13 +1340,13 @@ msgstr "Pohled" #: selection:account.tax,type_tax_use:0 #: selection:account.tax.template,type_tax_use:0 msgid "All" -msgstr "Vše" +msgstr "" #. module: account #: field:account.move.line,analytic_lines:0 #: model:ir.model,name:account.model_account_analytic_line msgid "Analytic lines" -msgstr "Analytická linky" +msgstr "" #. module: account #: help:account.tax,type:0 @@ -1370,28 +1370,28 @@ msgstr "" #. module: account #: model:process.node,name:account.process_node_electronicfile0 msgid "Electronic File" -msgstr "Elektronický soubor" +msgstr "" #. module: account #: view:res.partner:0 msgid "Customer Credit" -msgstr "Odběratelský úvěr" +msgstr "" #. module: account #: field:account.invoice,tax_line:0 msgid "Tax Lines" -msgstr "Daňové Linky" +msgstr "" #. module: account #: field:ir.sequence,fiscal_ids:0 msgid "Sequences" -msgstr "Posloupnosti" +msgstr "" #. module: account #: model:ir.actions.act_window,name:account.action_account_type_form #: model:ir.ui.menu,name:account.menu_action_account_type_form msgid "Account Types" -msgstr "Typy účtů" +msgstr "" #. module: account #: wizard_field:account.automatic.reconcile,init,journal_id:0 @@ -1413,18 +1413,18 @@ msgstr "Typy účtů" #: wizard_field:populate_statement_from_inv,init,journal_id:0 #: field:report.hr.timesheet.invoice.journal,journal_id:0 msgid "Journal" -msgstr "Časopis" +msgstr "" #. module: account #: field:account.account,child_id:0 #: field:account.analytic.account,child_ids:0 msgid "Child Accounts" -msgstr "Dětská konta" +msgstr "" #. module: account #: field:account.account,check_history:0 msgid "Display History" -msgstr "Zobrazení historie" +msgstr "" #. module: account #: wizard_field:account.third_party_ledger.report,init,date1:0 @@ -1454,7 +1454,7 @@ msgstr "" #: wizard_view:account.move.line.reconcile,init_full:0 #: wizard_view:account.move.line.reconcile,init_partial:0 msgid "Write-Off" -msgstr "Odpis" +msgstr "" #. module: account #: help:account.invoice,partner_bank:0 @@ -1466,12 +1466,12 @@ msgstr "" #. module: account #: field:res.partner,debit:0 msgid "Total Payable" -msgstr "Celkem za poplatek" +msgstr "" #. module: account #: wizard_button:account.fiscalyear.close.state,init,close:0 msgid "Close states" -msgstr "Zavřít státy" +msgstr "" #. module: account #: model:ir.model,name:account.model_wizard_company_setup @@ -1486,22 +1486,22 @@ msgstr "" #. module: account #: field:account.journal,refund_journal:0 msgid "Refund Journal" -msgstr "Refundace věstníku" +msgstr "" #. module: account #: model:account.account.type,name:account.account_type_income msgid "Income" -msgstr "Příjem" +msgstr "" #. module: account #: selection:account.bank.statement.line,type:0 msgid "Supplier" -msgstr "Dodavatel" +msgstr "" #. module: account #: rml:account.invoice:0 msgid "Tel. :" -msgstr "Telefonní číslo:" +msgstr "" #. module: account #: field:account.invoice.tax,tax_amount:0 diff --git a/addons/account/report/account_invoice_report_view.xml b/addons/account/report/account_invoice_report_view.xml index e11a839b2fb..3e70983b8d4 100644 --- a/addons/account/report/account_invoice_report_view.xml +++ b/addons/account/report/account_invoice_report_view.xml @@ -49,39 +49,40 @@ - - - - - - - - - - - - - - + + + + + + + + + + + + + + - + + domain="[('type','=','out_invoice')]" + default="1"/> @@ -94,9 +95,9 @@ domain="[('type','=','in_refund')]"/> - + - + diff --git a/addons/account/test/test_parent_structure.py b/addons/account/test/test_parent_structure.py new file mode 100644 index 00000000000..ba27d91c87c --- /dev/null +++ b/addons/account/test/test_parent_structure.py @@ -0,0 +1,54 @@ +# -*- 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 . +# +############################################################################## + +# +# TODO: move this in a YAML test with !python tag +# + +import xmlrpclib + +DB = 'training3' +USERID = 1 +USERPASS = 'admin' + + +sock = xmlrpclib.ServerProxy('http://%s:%s/xmlrpc/object' % ('localhost',8069)) + +ids = sock.execute(DB, USERID, USERPASS, 'account.account', 'search', [], {}) +account_lists = sock.execute(DB, USERID, USERPASS, 'account.account', 'read', ids, ['parent_id','parent_left','parent_right']) + +accounts = dict(map(lambda x: (x['id'],x), account_lists)) +for a in account_lists: + if a['parent_id']: + assert a['parent_left'] > accounts[a['parent_id'][0]]['parent_left'] + assert a['parent_right'] < accounts[a['parent_id'][0]]['parent_right'] + assert a['parent_left'] < a['parent_right'] + for a2 in account_lists: + assert not ((a2['parent_right']>a['parent_left']) and + (a2['parent_left']a['parent_left']) and (a2['parent_right'] parent_right of all childs - . if an account is a child it is included in parent_left-parent_right - . if an account is not a child it is not included in parent_left-parent_right +- + We retrieve all accounts and test they are in a tree data structure. - !python {model: account.account}: | ids = self.search(cr, uid, []) diff --git a/addons/account_payment/i18n/cs.po b/addons/account_payment/i18n/cs.po index 307e7372453..efe3a9ada7d 100644 --- a/addons/account_payment/i18n/cs.po +++ b/addons/account_payment/i18n/cs.po @@ -7,13 +7,13 @@ msgstr "" "Project-Id-Version: OpenERP Server 5.0.4\n" "Report-Msgid-Bugs-To: support@openerp.com\n" "POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-04-07 22:24+0000\n" -"Last-Translator: mitev.dmitry \n" +"PO-Revision-Date: 2009-02-03 06:24+0000\n" +"Last-Translator: <>\n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n" +"X-Launchpad-Export-Date: 2010-03-30 04:07+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: account_payment @@ -46,7 +46,7 @@ msgstr "" #: field:payment.line,info_owner:0 #: view:payment.order:0 msgid "Owner Account" -msgstr "Majitel účtu" +msgstr "" #. module: account_payment #: help:account.invoice,amount_to_pay:0 @@ -65,17 +65,17 @@ msgstr "" #. module: account_payment #: field:payment.order,date_prefered:0 msgid "Preferred date" -msgstr "Preferované datum" +msgstr "" #. module: account_payment #: selection:payment.line,state:0 msgid "Free" -msgstr "Volný" +msgstr "" #. module: account_payment #: wizard_field:populate_payment,search,entries:0 msgid "Entries" -msgstr "Příspěvky" +msgstr "" #. module: account_payment #: wizard_field:populate_payment,init,duedate:0 @@ -96,7 +96,7 @@ msgstr "" #: rml:payment.order:0 #: view:payment.order:0 msgid "Amount" -msgstr "Částka" +msgstr "" #. module: account_payment #: rml:payment.order:0 @@ -111,7 +111,7 @@ msgstr "" #. module: account_payment #: selection:payment.order,state:0 msgid "Cancelled" -msgstr "Zrušeno" +msgstr "" #. module: account_payment #: model:ir.actions.act_window,name:account_payment.action_payment_order_tree_new @@ -123,7 +123,7 @@ msgstr "" #: rml:payment.order:0 #: field:payment.order,reference:0 msgid "Reference" -msgstr "Odkaz" +msgstr "" #. module: account_payment #: model:ir.actions.act_window,name:account_payment.action_payment_order_tree @@ -134,7 +134,7 @@ msgstr "" #. module: account_payment #: selection:payment.order,date_prefered:0 msgid "Directly" -msgstr "Přímo" +msgstr "" #. module: account_payment #: model:ir.actions.act_window,name:account_payment.action_payment_line_form @@ -157,7 +157,7 @@ msgstr "" #. module: account_payment #: selection:payment.order,state:0 msgid "Confirmed" -msgstr "Potvrzeno" +msgstr "" #. module: account_payment #: help:payment.line,ml_date_created:0 @@ -177,12 +177,12 @@ msgstr "" #. module: account_payment #: selection:payment.line,state:0 msgid "Structured" -msgstr "Strukturované" +msgstr "" #. module: account_payment #: field:payment.order,state:0 msgid "State" -msgstr "Stav" +msgstr "" #. module: account_payment #: view:payment.line:0 @@ -223,17 +223,17 @@ msgstr "" #. module: account_payment #: field:payment.order,date_done:0 msgid "Execution date" -msgstr "Datum představení" +msgstr "" #. module: account_payment #: selection:payment.order,date_prefered:0 msgid "Fixed date" -msgstr "Pevné datum" +msgstr "" #. module: account_payment #: field:payment.line,info_partner:0 msgid "Destination Account" -msgstr "Protiúčet" +msgstr "" #. module: account_payment #: view:payment.line:0 @@ -251,12 +251,12 @@ msgstr "" #: wizard_button:populate_payment,search,end:0 #: wizard_button:populate_statement,init,end:0 msgid "_Cancel" -msgstr "Zrušit" +msgstr "" #. module: account_payment #: field:payment.line,create_date:0 msgid "Created" -msgstr "Vytvořeno" +msgstr "" #. module: account_payment #: view:payment.line:0 @@ -281,12 +281,12 @@ msgstr "" #. module: account_payment #: field:payment.line,communication:0 msgid "Communication" -msgstr "Komunikace" +msgstr "" #. module: account_payment #: selection:payment.order,date_prefered:0 msgid "Due date" -msgstr "Termín dokončení" +msgstr "" #. module: account_payment #: field:account.invoice,amount_to_pay:0 @@ -307,7 +307,7 @@ msgstr "" #: view:payment.type:0 #: help:payment.type,name:0 msgid "Payment Type" -msgstr "Typ platby" +msgstr "" #. module: account_payment #: help:payment.line,amount_currency:0 diff --git a/addons/audittrail/i18n/it.po b/addons/audittrail/i18n/it.po index 7300efc8c8d..ef0956d2e0a 100644 --- a/addons/audittrail/i18n/it.po +++ b/addons/audittrail/i18n/it.po @@ -7,19 +7,19 @@ msgstr "" "Project-Id-Version: OpenERP Server 5.0.4\n" "Report-Msgid-Bugs-To: support@openerp.com\n" "POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-04-07 08:27+0000\n" -"Last-Translator: iTuxer \n" +"PO-Revision-Date: 2009-02-03 12:33+0000\n" +"Last-Translator: Fabien (Open ERP) \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n" +"X-Launchpad-Export-Date: 2010-03-30 04:13+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: audittrail #: model:ir.module.module,shortdesc:audittrail.module_meta_information msgid "Audit Trail" -msgstr "Audit Trail" +msgstr "" #. module: audittrail #: constraint:ir.model:0 @@ -32,22 +32,22 @@ msgstr "" #. module: audittrail #: field:audittrail.log.line,log_id:0 msgid "Log" -msgstr "Log" +msgstr "" #. module: audittrail #: selection:audittrail.rule,state:0 msgid "Subscribed" -msgstr "Iscritto" +msgstr "" #. module: audittrail #: view:audittrail.log:0 msgid "Old Value : " -msgstr "Valore precendente : " +msgstr "" #. module: audittrail #: selection:audittrail.log,method:0 msgid "Create" -msgstr "Crea" +msgstr "" #. module: audittrail #: wizard_view:audittrail.view.log,init:0 @@ -67,7 +67,7 @@ msgstr "" #. module: audittrail #: field:audittrail.log.line,old_value:0 msgid "Old Value" -msgstr "Valore precedente" +msgstr "" #. module: audittrail #: constraint:ir.actions.act_window:0 diff --git a/addons/base_contact/i18n/ko.po b/addons/base_contact/i18n/ko.po index 6089514cbc6..698c28484c7 100644 --- a/addons/base_contact/i18n/ko.po +++ b/addons/base_contact/i18n/ko.po @@ -14,7 +14,7 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n" +"X-Launchpad-Export-Date: 2010-04-07 03:46+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: base_contact diff --git a/addons/base_setup/i18n/fa.po b/addons/base_setup/i18n/fa.po deleted file mode 100644 index 421b6550250..00000000000 --- a/addons/base_setup/i18n/fa.po +++ /dev/null @@ -1,283 +0,0 @@ -# Persian translation for openobject-addons -# Copyright (c) 2010 Rosetta Contributors and Canonical Ltd 2010 -# This file is distributed under the same license as the openobject-addons package. -# FIRST AUTHOR , 2010. -# -msgid "" -msgstr "" -"Project-Id-Version: openobject-addons\n" -"Report-Msgid-Bugs-To: FULL NAME \n" -"POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-04-08 14:27+0000\n" -"Last-Translator: Sadegh Ismael Nattaj \n" -"Language-Team: Persian \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n" -"X-Generator: Launchpad (build Unknown)\n" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,city:0 -#: wizard_field:base_setup.base_setup,init,city:0 -#: wizard_field:base_setup.base_setup,update,city:0 -msgid "City" -msgstr "شهر" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,finish:0 -msgid "" -"You can start configuring the system or connect directly to the database " -"using the default setup." -msgstr "" -"شما می‌توانید با بکارگیری از سوارسازی پیش‌فرض آغاز به پیکربندی سامانه کنید و " -"یا یک‌راست به دادگان متصل شوید." - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,zip:0 -#: wizard_field:base_setup.base_setup,init,zip:0 -#: wizard_field:base_setup.base_setup,update,zip:0 -msgid "Zip code" -msgstr "کد پستی" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,init:0 -msgid "Select a Profile" -msgstr "یک پروفایل را برگزینید" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,company:0 -msgid "Report header" -msgstr "سرنویس گزارش" - -#. module: base_setup -#: wizard_button:base_setup.base_setup,finish,config:0 -msgid "Start Configuration" -msgstr "آغاز پیکربندی" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,init:0 -msgid "" -"You'll be able to install more modules later through the Administration menu." -msgstr "" -"شما می‌توانید از طریق منوی راهبری پیمانه‌های بیشتری را در آینده برپاسازی " -"نمایید." - -#. module: base_setup -#: wizard_view:base_setup.base_setup,init:0 -msgid "" -"A profile sets a pre-selection of modules for specific needs. These profiles " -"have been setup to help you discover the different aspects of OpenERP. This " -"is just an overview, we have 300+ available modules." -msgstr "" -"یک پروفایل دارای پیمانه‌های از پیش گزینش شده برای نیازهای خاص است. این " -"پروفایل‌ها برای این سوار می‌شوند تا به شما برای شناخت بیشتر جنبه‌های متفاوت " -"اپن ای‌آر‌پی کمک نماید. این تنها یک پیش‌نمایش است، ما بیش از ۳۰۰ پیمانه " -"آماده داریم." - -#. module: base_setup -#: wizard_button:base_setup.base_setup,company,update:0 -#: wizard_button:base_setup.base_setup,init,company:0 -msgid "Next" -msgstr "پس" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,email:0 -#: wizard_field:base_setup.base_setup,init,email:0 -#: wizard_field:base_setup.base_setup,update,email:0 -msgid "E-mail" -msgstr "ایمیل" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,state_id:0 -#: wizard_field:base_setup.base_setup,init,state_id:0 -#: wizard_field:base_setup.base_setup,update,state_id:0 -msgid "State" -msgstr "استان" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,finish:0 -msgid "Your new database is now fully installed." -msgstr "دادگان نو شما بطور کامل برپاسازی گردید." - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,profile:0 -#: wizard_field:base_setup.base_setup,init,profile:0 -#: wizard_field:base_setup.base_setup,update,profile:0 -msgid "Profile" -msgstr "پروفایل" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,rml_footer1:0 -#: wizard_field:base_setup.base_setup,init,rml_footer1:0 -#: wizard_field:base_setup.base_setup,update,rml_footer1:0 -msgid "Report Footer 1" -msgstr "پانویس گزارش ۱" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,rml_footer2:0 -#: wizard_field:base_setup.base_setup,init,rml_footer2:0 -#: wizard_field:base_setup.base_setup,update,rml_footer2:0 -msgid "Report Footer 2" -msgstr "پانویس گزارش ۲" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,company:0 -msgid "General Information" -msgstr "آگهگان عمومی" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,street2:0 -#: wizard_field:base_setup.base_setup,init,street2:0 -#: wizard_field:base_setup.base_setup,update,street2:0 -msgid "Street2" -msgstr "خیابان۲" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,company:0 -msgid "Report Information" -msgstr "آگهگان گزارش" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,phone:0 -#: wizard_field:base_setup.base_setup,init,phone:0 -#: wizard_field:base_setup.base_setup,update,phone:0 -msgid "Phone" -msgstr "تلفن" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,company:0 -msgid "Define Main Company" -msgstr "تعریف شرکت اصلی" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,name:0 -#: wizard_field:base_setup.base_setup,init,name:0 -#: wizard_field:base_setup.base_setup,update,name:0 -msgid "Company Name" -msgstr "نام شرکت" - -#. module: base_setup -#: help:base_setup.base_setup,company,rml_footer2:0 -#: help:base_setup.base_setup,init,rml_footer2:0 -#: help:base_setup.base_setup,update,rml_footer2:0 -msgid "" -"This sentence will appear at the bottom of your reports.\n" -"We suggest you to put bank information here:\n" -"IBAN: BE74 1262 0121 6907 - SWIFT: CPDF BE71 - VAT: BE0477.472.701" -msgstr "" -"این جمله در پایین گزارش‌های شما ظاهر خواهد شد.\n" -"پیشنهاد می‌کنیم آگهگان بانکی را اینجا وارد نمایید:\n" -"IBAN: BE74 1262 0121 6907 - SWIFT: CPDF BE71 - VAT: BE0477.472.701" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,country_id:0 -#: wizard_field:base_setup.base_setup,init,country_id:0 -#: wizard_field:base_setup.base_setup,update,country_id:0 -msgid "Country" -msgstr "کشور" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,company:0 -#: wizard_view:base_setup.base_setup,finish:0 -#: wizard_view:base_setup.base_setup,init:0 -#: wizard_view:base_setup.base_setup,update:0 -#: model:ir.actions.wizard,name:base_setup.action_wizard_setup -#: model:ir.actions.wizard,name:base_setup.wizard_base_setup -msgid "Setup" -msgstr "سوارکردن" - -#. module: base_setup -#: help:base_setup.base_setup,company,rml_footer1:0 -#: help:base_setup.base_setup,init,rml_footer1:0 -#: help:base_setup.base_setup,update,rml_footer1:0 -msgid "" -"This sentence will appear at the bottom of your reports.\n" -"We suggest you to write legal sentences here:\n" -"Web: http://openerp.com - Fax: +32.81.73.35.01 - Fortis Bank: 126-2013269-07" -msgstr "" -"این جمله در پایین گزارش‌های شما ظاهر خواهد شد.\n" -"پیشنهاد می‌کنیم تا از عبارات قانونی در اینجا بکار ببرید:\n" -"Web: http://openerp.com - Fax: +32.81.73.35.01 - Fortis Bank: 126-2013269-07" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,update:0 -msgid "Summary" -msgstr "چکیده" - -#. module: base_setup -#: wizard_button:base_setup.base_setup,update,finish:0 -msgid "Install" -msgstr "برپایی" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,finish:0 -msgid "Installation Done" -msgstr "برپایی انجام شد" - -#. module: base_setup -#: help:base_setup.base_setup,company,rml_header1:0 -#: help:base_setup.base_setup,init,rml_header1:0 -#: help:base_setup.base_setup,update,rml_header1:0 -msgid "" -"This sentence will appear at the top right corner of your reports.\n" -"We suggest you to put a slogan here:\n" -"\"Open Source Business Solutions\"." -msgstr "" -"این جمله در گوشه بالا سمت راست گزارش‌های شما ظاهر خواهد شد.\n" -"پیشنهاد می‌کنیم شعار خود را اینجا قرار دهید:\n" -"\"راهکارهای بازمتن برای تجارت\"." - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,rml_header1:0 -#: wizard_field:base_setup.base_setup,init,rml_header1:0 -#: wizard_field:base_setup.base_setup,update,rml_header1:0 -msgid "Report Header" -msgstr "سرنویس گزارش" - -#. module: base_setup -#: wizard_view:base_setup.base_setup,company:0 -msgid "Your Logo - Use a size of about 450x150 pixels." -msgstr "نشان شما - اندازه تصویری ۱۵۰×۴۵۰ پیکسل را بکار برید." - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,currency:0 -#: wizard_field:base_setup.base_setup,init,currency:0 -#: wizard_field:base_setup.base_setup,update,currency:0 -msgid "Currency" -msgstr "ارز" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,street:0 -#: wizard_field:base_setup.base_setup,init,street:0 -#: wizard_field:base_setup.base_setup,update,street:0 -msgid "Street" -msgstr "خیابان" - -#. module: base_setup -#: wizard_button:base_setup.base_setup,finish,menu:0 -msgid "Use Directly" -msgstr "بکارگیری آنی" - -#. module: base_setup -#: wizard_button:base_setup.base_setup,init,menu:0 -msgid "Cancel" -msgstr "لغو" - -#. module: base_setup -#: wizard_field:base_setup.base_setup,company,logo:0 -#: wizard_field:base_setup.base_setup,init,logo:0 -#: wizard_field:base_setup.base_setup,update,logo:0 -msgid "Logo" -msgstr "نشان" - -#. module: base_setup -#: model:ir.module.module,shortdesc:base_setup.module_meta_information -msgid "Base Setup" -msgstr "سوارکردن پایه" - -#. module: base_setup -#: wizard_button:base_setup.base_setup,company,init:0 -#: wizard_button:base_setup.base_setup,update,company:0 -msgid "Previous" -msgstr "پیش" diff --git a/addons/crm/crm_claims_menu.xml b/addons/crm/crm_claims_menu.xml index f235c9ae637..1eac8e007a3 100755 --- a/addons/crm/crm_claims_menu.xml +++ b/addons/crm/crm_claims_menu.xml @@ -13,7 +13,6 @@ form tree,calendar,form,graph - {"search_default_section_id":section_id,"search_default_current":1,"search_default_my_claims":1} diff --git a/addons/crm/crm_claims_view.xml b/addons/crm/crm_claims_view.xml index c7409006d78..f791a1b86cc 100755 --- a/addons/crm/crm_claims_view.xml +++ b/addons/crm/crm_claims_view.xml @@ -161,7 +161,7 @@ - + @@ -183,7 +183,7 @@