[MERGE]: Merge with lp:openobject-addons
bzr revid: rpa@tinyerp.com-20100318051757-bsw2454f87yhfref
This commit is contained in:
commit
a4739f750d
|
@ -61,6 +61,8 @@
|
|||
'sequence_view.xml',
|
||||
'company_view.xml',
|
||||
'account_installer.xml',
|
||||
'report/account_invoice_report_view.xml',
|
||||
'report/account_report_view.xml',
|
||||
],
|
||||
'demo_xml': [
|
||||
#'demo/price_accuracy00.yml',
|
||||
|
|
|
@ -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-01-13 11:48+0000\n"
|
||||
"Last-Translator: Kuvaly [LCT] <kuvaly@seznam.cz>\n"
|
||||
"PO-Revision-Date: 2010-03-17 20:55+0000\n"
|
||||
"Last-Translator: mitev.dmitry <Unknown>\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-03-11 04:49+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:34+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
|
@ -154,7 +154,7 @@ msgstr "Položky"
|
|||
#. module: account
|
||||
#: selection:account.move.line,centralisation:0
|
||||
msgid "Debit Centralisation"
|
||||
msgstr ""
|
||||
msgstr "Debetní Centralizace"
|
||||
|
||||
#. module: account
|
||||
#: model:ir.actions.wizard,name:account.wizard_invoice_state_confirm
|
||||
|
@ -257,7 +257,7 @@ msgstr "Celkový dluh"
|
|||
#. module: account
|
||||
#: rml:account.tax.code.entries:0
|
||||
msgid "Accounting Entries-"
|
||||
msgstr ""
|
||||
msgstr "Účetní zápisy"
|
||||
|
||||
#. module: account
|
||||
#: help:account.journal,view_id:0
|
||||
|
@ -299,7 +299,7 @@ msgstr "Zpožděné platby"
|
|||
#: wizard_view:account.analytic.account.quantity_cost_ledger.report,init:0
|
||||
#: wizard_view:account.vat.declaration,init:0
|
||||
msgid "Select period"
|
||||
msgstr ""
|
||||
msgstr "Vyberte období"
|
||||
|
||||
#. module: account
|
||||
#: field:account.invoice,origin:0
|
||||
|
@ -384,7 +384,7 @@ msgstr "Celkové částky"
|
|||
#: field:account.fiscal.position.account,account_src_id:0
|
||||
#: field:account.fiscal.position.account.template,account_src_id:0
|
||||
msgid "Account Source"
|
||||
msgstr ""
|
||||
msgstr "Zdroj účtu"
|
||||
|
||||
#. module: account
|
||||
#: field:account.journal,update_posted:0
|
||||
|
@ -420,7 +420,7 @@ msgstr ""
|
|||
#. module: account
|
||||
#: rml:account.partner.balance:0
|
||||
msgid "(Account/Partner) Name"
|
||||
msgstr ""
|
||||
msgstr "(Účet / Partner) Název"
|
||||
|
||||
#. module: account
|
||||
#: selection:account.move,type:0
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -34,7 +34,8 @@ import general_ledger_landscape
|
|||
import account_tax_code
|
||||
import account_balance_landscape
|
||||
import compare_account_balance
|
||||
|
||||
import account_invoice_report
|
||||
import account_report
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -0,0 +1,90 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import tools
|
||||
from osv import fields,osv
|
||||
|
||||
class account_invoice_report(osv.osv):
|
||||
_name = "account.invoice.report"
|
||||
_description = "Invoices Statistics"
|
||||
_auto = False
|
||||
_rec_name = 'date'
|
||||
_columns = {
|
||||
'date': fields.date('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),
|
||||
'product_id':fields.many2one('product.product', 'Product', readonly=True),
|
||||
'product_qty':fields.float('Qty', 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),
|
||||
'price_total':fields.float('Total Price', readonly=True),
|
||||
'price_average':fields.float('Average Price', readonly=True),
|
||||
'nbr':fields.integer('# of Lines', readonly=True),
|
||||
'type': fields.selection([
|
||||
('out_invoice','Customer Invoice'),
|
||||
('in_invoice','Supplier Invoice'),
|
||||
('out_refund','Customer Refund'),
|
||||
('in_refund','Supplier Refund'),
|
||||
],'Type', readonly=True),
|
||||
'state': fields.selection([
|
||||
('draft','Draft'),
|
||||
('proforma','Pro-forma'),
|
||||
('proforma2','Pro-forma'),
|
||||
('open','Open'),
|
||||
('paid','Done'),
|
||||
('cancel','Cancelled')
|
||||
], 'Order State', readonly=True),
|
||||
}
|
||||
_order = 'date desc'
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'account_invoice_report')
|
||||
cr.execute("""
|
||||
create or replace view account_invoice_report as (
|
||||
select
|
||||
min(l.id) as id,
|
||||
s.date_invoice as date,
|
||||
to_char(s.date_invoice, 'YYYY') as year,
|
||||
to_char(s.date_invoice, 'MM') as month,
|
||||
l.product_id as product_id,
|
||||
sum(l.quantity * u.factor) as product_qty,
|
||||
s.partner_id as partner_id,
|
||||
s.user_id as user_id,
|
||||
s.company_id as company_id,
|
||||
sum(l.quantity*l.price_unit) as price_total,
|
||||
(sum(l.quantity*l.price_unit)/sum(l.quantity * u.factor))::decimal(16,2) as price_average,
|
||||
count(*) as nbr,
|
||||
s.type as type,
|
||||
s.state
|
||||
from
|
||||
account_invoice_line l
|
||||
left join
|
||||
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
|
||||
)
|
||||
""")
|
||||
account_invoice_report()
|
|
@ -0,0 +1,113 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<record id="view_account_invoice_report_tree" model="ir.ui.view">
|
||||
<field name="name">account.invoice.report.tree</field>
|
||||
<field name="model">account.invoice.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Invoices Statistics">
|
||||
<field name="date"/>
|
||||
<field name="user_id"/>
|
||||
<field name="year" invisible="1"/>
|
||||
<field name="month" invisible="1"/>
|
||||
<field name="type" invisible="1"/>
|
||||
<field name="company_id" invisible="1"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="product_id"/>
|
||||
<field name="product_qty"/>
|
||||
<!--field name="delay" avg="Days to Close"/-->
|
||||
<field name="nbr" sum="# of Lines"/>
|
||||
<field name="price_average" avg="Average Price"/>
|
||||
<field name="price_total" sum="Total Price"/>
|
||||
<field name="state" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_account_invoice_report_graph" model="ir.ui.view">
|
||||
<field name="name">account.invoice.report.graph</field>
|
||||
<field name="model">account.invoice.report</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Invoices Statistics" type="bar">
|
||||
<field name="product_id"/>
|
||||
<field name="price_total"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_account_invoice_report_search" model="ir.ui.view">
|
||||
<field name="name">account.invoice.report.search</field>
|
||||
<field name="model">account.invoice.report</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Invoices">
|
||||
<filter icon="terp-account"
|
||||
string="This Year"
|
||||
domain="[('year','=',time.strftime('%%Y'))]"
|
||||
help="Invoices of the year"/>
|
||||
<filter icon="terp-account"
|
||||
string="This Month"
|
||||
domain="[('month','=',time.strftime('%%m'))]"
|
||||
help="Invoices of this month"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter icon="terp-account"
|
||||
string="Draft"
|
||||
domain="[('state','=','draft')]"/>
|
||||
<filter icon="terp-account"
|
||||
string="Invoices"
|
||||
domain="[('state','<>','draft'),('state','<>','cancel')]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="product_id"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<filter icon="terp-account"
|
||||
string="My Invoices"
|
||||
domain="[('user_id','=',uid)]"/>
|
||||
</field>
|
||||
<field name="partner_id"/>
|
||||
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
|
||||
|
||||
<newline/>
|
||||
<group expand="1" string="Extended options..." colspan="10" col="12">
|
||||
<filter icon="terp-account"
|
||||
string="Customer Invoices"
|
||||
domain="[('type','=','out_invoice')]"/>
|
||||
<filter icon="terp-account"
|
||||
string="Supplier Invoices"
|
||||
domain="[('type','=','in_invoice')]"/>
|
||||
<filter icon="terp-account"
|
||||
string="Customer Refunds"
|
||||
domain="[('type','=','out_refund')]"/>
|
||||
<filter icon="terp-account"
|
||||
string="Supplier Refunds"
|
||||
domain="[('type','=','in_refund')]"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="12">
|
||||
<filter string="Company" icon="terp-account" context="{'group_by':'company_id'}"/>
|
||||
<filter string="Salesman" icon="terp-account" context="{'group_by':'user_id'}" default="1"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Product" icon="terp-account" context="{'group_by':'product_id'}"/>
|
||||
<filter string="Partner" icon="terp-account" context="{'group_by':'partner_id'}"/>
|
||||
<filter string="State" icon="terp-account" context="{'group_by':'state'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-account" context="{'group_by':'date'}"/>
|
||||
<filter string="Year" icon="terp-account" context="{'group_by':'year'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_account_invoice_report_all" model="ir.actions.act_window">
|
||||
<field name="name">Invoices</field>
|
||||
<field name="res_model">account.invoice.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="search_view_id" ref="view_account_invoice_report_search"/>
|
||||
</record>
|
||||
|
||||
<menuitem action="action_account_invoice_report_all" id="menu_action_account_invoice_report_all" parent="account.menu_finance_reporting" sequence="0"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
|
@ -88,3 +88,10 @@
|
|||
"access_account_sequence_fiscal_year","account.sequence.fiscalyear","model_account_sequence_fiscalyear","account.group_account_user",1,1,1,1
|
||||
"access_account_sequence_fiscal_year_user","account.sequence.fiscalyear user","model_account_sequence_fiscalyear","base.group_user",1,0,0,0
|
||||
"access_account_installer","account.installer","model_account_installer","base.group_user",1,0,0,0
|
||||
"access_report_account_receivable","report.account.receivable","model_report_account_receivable","account.group_account_manager",1,0,0,0
|
||||
"access_temp_range","temp.range","model_temp_range","account.group_account_manager",1,0,0,0
|
||||
"access_report_aged_receivable","report.aged.receivable","model_report_aged_receivable","account.group_account_manager",1,0,0,0
|
||||
"access_report_invoice_created","report.invoice.created","model_report_invoice_created","account.group_account_manager",1,0,0,0
|
||||
"access_report_account_type_sales","report.account_type.sales","model_report_account_type_sales","account.group_account_manager",1,0,0,0
|
||||
"access_report_account_sales","report.account.sales","model_report_account_sales","account.group_account_manager",1,0,0,0
|
||||
"access_account_invoice_report","account.invoice.report","model_account_invoice_report","account.group_account_manager",1,0,0,0
|
||||
|
|
|
|
@ -0,0 +1,64 @@
|
|||
# Hindi 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 <EMAIL@ADDRESS>, 2010.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-11-24 12:50+0000\n"
|
||||
"PO-Revision-Date: 2010-03-16 23:00+0000\n"
|
||||
"Last-Translator: Neetesh Biswas <Unknown>\n"
|
||||
"Language-Team: Hindi <hi@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account_anglo_saxon
|
||||
#: view:product.category:0
|
||||
msgid " Accounting Property"
|
||||
msgstr ""
|
||||
|
||||
#. module: account_anglo_saxon
|
||||
#: model:ir.module.module,description:account_anglo_saxon.module_meta_information
|
||||
msgid ""
|
||||
"This module will support the Anglo-Saxons accounting methodology by \n"
|
||||
" changing the accounting logic with stock transactions. The difference "
|
||||
"between the Anglo-Saxon accounting countries \n"
|
||||
" and the Rhine or also called Continental accounting countries is the "
|
||||
"moment of taking the Cost of Goods Sold versus Cost of Sales. \n"
|
||||
" Anglo-Saxons accounting does take the cost when sales invoice is "
|
||||
"created, Continental accounting will take the cost at he moment the goods "
|
||||
"are shipped.\n"
|
||||
" This module will add this functionality by using a interim account, to "
|
||||
"store the value of shipped goods and will contra book this interim account \n"
|
||||
" when the invoice is created to transfer this amount to the debtor or "
|
||||
"creditor account."
|
||||
msgstr ""
|
||||
|
||||
#. module: account_anglo_saxon
|
||||
#: model:ir.module.module,shortdesc:account_anglo_saxon.module_meta_information
|
||||
msgid "Stock Account"
|
||||
msgstr ""
|
||||
|
||||
#. module: account_anglo_saxon
|
||||
#: constraint:ir.ui.view:0
|
||||
msgid "Invalid XML for View Architecture!"
|
||||
msgstr "संरचना देखने के लिए अमान्य XML!"
|
||||
|
||||
#. module: account_anglo_saxon
|
||||
#: field:product.category,property_account_creditor_price_difference_categ:0
|
||||
#: field:product.template,property_account_creditor_price_difference:0
|
||||
msgid "Price Difference Account"
|
||||
msgstr ""
|
||||
|
||||
#. module: account_anglo_saxon
|
||||
#: help:product.category,property_account_creditor_price_difference_categ:0
|
||||
#: help:product.template,property_account_creditor_price_difference:0
|
||||
msgid ""
|
||||
"This account will be used to value price difference between purchase price "
|
||||
"and cost price."
|
||||
msgstr ""
|
|
@ -7,13 +7,13 @@ msgstr ""
|
|||
"Project-Id-Version: OpenERP Server 5.0.0_rc3\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2009-09-08 15:49+0000\n"
|
||||
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
|
||||
"PO-Revision-Date: 2010-03-18 02:19+0000\n"
|
||||
"Last-Translator: Zergar <Unknown>\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-03-11 04:53+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:34+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account_balance
|
||||
|
@ -24,56 +24,56 @@ msgstr ""
|
|||
#. module: account_balance
|
||||
#: selection:account.balance.account.balance.report,init,account_choice:0
|
||||
msgid "All accounts"
|
||||
msgstr ""
|
||||
msgstr "Todas as Contas"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_field:account.balance.account.balance.report,init,period_manner:0
|
||||
msgid "Entries Selection Based on"
|
||||
msgstr ""
|
||||
msgstr "Seleção de entradas baseada em"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_view:account.balance.account.balance.report,backtoinit:0
|
||||
#: wizard_view:account.balance.account.balance.report,zero_years:0
|
||||
msgid "Notification"
|
||||
msgstr ""
|
||||
msgstr "Notificação"
|
||||
|
||||
#. module: account_balance
|
||||
#: selection:account.balance.account.balance.report,init,period_manner:0
|
||||
msgid "Financial Period"
|
||||
msgstr ""
|
||||
msgstr "Período Financeiro"
|
||||
|
||||
#. module: account_balance
|
||||
#: model:ir.actions.report.xml,name:account_balance.account_account_balance
|
||||
#: model:ir.actions.report.xml,name:account_balance.account_account_balance_landscape
|
||||
msgid "Account balance"
|
||||
msgstr ""
|
||||
msgstr "Saldo da Conta"
|
||||
|
||||
#. module: account_balance
|
||||
#: rml:account.account.balance.landscape:0
|
||||
#: rml:account.balance.account.balance:0
|
||||
msgid "Account Name"
|
||||
msgstr ""
|
||||
msgstr "Nome da Conta"
|
||||
|
||||
#. module: account_balance
|
||||
#: rml:account.account.balance.landscape:0
|
||||
#: rml:account.balance.account.balance:0
|
||||
msgid "Debit"
|
||||
msgstr ""
|
||||
msgstr "Débito"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_button:account.balance.account.balance.report,init,checkyear:0
|
||||
msgid "Print"
|
||||
msgstr ""
|
||||
msgstr "Impressão"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_view:account.balance.account.balance.report,init:0
|
||||
msgid "Select Period(s)"
|
||||
msgstr ""
|
||||
msgstr "Selecione o(s) Período(s)"
|
||||
|
||||
#. module: account_balance
|
||||
#: selection:account.balance.account.balance.report,init,compare_pattern:0
|
||||
msgid "Percentage"
|
||||
msgstr ""
|
||||
msgstr "Porcentagem"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_field:account.balance.account.balance.report,init,compare_pattern:0
|
||||
|
@ -83,17 +83,17 @@ msgstr ""
|
|||
#. module: account_balance
|
||||
#: wizard_view:account.balance.account.balance.report,init:0
|
||||
msgid "Select Fiscal Year(s)(Maximum Three Years)"
|
||||
msgstr ""
|
||||
msgstr "Selecione Ano(s) Fiscal(is) (máximo três anos)"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_field:account.balance.account.balance.report,init,select_account:0
|
||||
msgid "Select Reference Account(for % comparision)"
|
||||
msgstr ""
|
||||
msgstr "Selecione conta de referência (para comparação %)"
|
||||
|
||||
#. module: account_balance
|
||||
#: model:ir.actions.wizard,name:account_balance.wizard_account_balance_report
|
||||
msgid "Account balance-Compare Years"
|
||||
msgstr ""
|
||||
msgstr "Conta Saldo Comparar Anos"
|
||||
|
||||
#. module: account_balance
|
||||
#: model:ir.module.module,description:account_balance.module_meta_information
|
||||
|
@ -125,70 +125,70 @@ msgstr ""
|
|||
#. module: account_balance
|
||||
#: wizard_field:account.balance.account.balance.report,init,landscape:0
|
||||
msgid "Show Report in Landscape Form"
|
||||
msgstr ""
|
||||
msgstr "Mostrar relatório em formato de paisagem"
|
||||
|
||||
#. module: account_balance
|
||||
#: help:account.balance.account.balance.report,init,periods:0
|
||||
msgid "All periods if empty"
|
||||
msgstr ""
|
||||
msgstr "Todos os períodos se vazio"
|
||||
|
||||
#. module: account_balance
|
||||
#: selection:account.balance.account.balance.report,init,account_choice:0
|
||||
msgid "With balance is not equal to 0"
|
||||
msgstr ""
|
||||
msgstr "Com saldo diferente de zero"
|
||||
|
||||
#. module: account_balance
|
||||
#: rml:account.account.balance.landscape:0
|
||||
#: rml:account.balance.account.balance:0
|
||||
msgid "Total :"
|
||||
msgstr ""
|
||||
msgstr "Total :"
|
||||
|
||||
#. module: account_balance
|
||||
#: rml:account.account.balance.landscape:0
|
||||
#: rml:account.balance.account.balance:0
|
||||
msgid "Account Balance -"
|
||||
msgstr ""
|
||||
msgstr "Saldo da conta -"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_field:account.balance.account.balance.report,init,format_perc:0
|
||||
msgid "Show Comparision in %"
|
||||
msgstr ""
|
||||
msgstr "Mostrar comparação em %"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_view:account.balance.account.balance.report,init:0
|
||||
msgid "Select Period"
|
||||
msgstr ""
|
||||
msgstr "Selecione o Período"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_view:account.balance.account.balance.report,init:0
|
||||
msgid "Report Options"
|
||||
msgstr ""
|
||||
msgstr "Opções de Relatório"
|
||||
|
||||
#. module: account_balance
|
||||
#: selection:account.balance.account.balance.report,init,account_choice:0
|
||||
msgid "With movements"
|
||||
msgstr ""
|
||||
msgstr "Com movimentos"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_button:account.balance.account.balance.report,backtoinit,end:0
|
||||
#: wizard_button:account.balance.account.balance.report,zero_years,end:0
|
||||
msgid "Ok"
|
||||
msgstr ""
|
||||
msgstr "Ok"
|
||||
|
||||
#. module: account_balance
|
||||
#: selection:account.balance.account.balance.report,init,compare_pattern:0
|
||||
msgid "Cash"
|
||||
msgstr ""
|
||||
msgstr "Dinheiro"
|
||||
|
||||
#. module: account_balance
|
||||
#: selection:account.balance.account.balance.report,init,compare_pattern:0
|
||||
msgid "Don't Compare"
|
||||
msgstr ""
|
||||
msgstr "Não Comparar"
|
||||
|
||||
#. module: account_balance
|
||||
#: wizard_field:account.balance.account.balance.report,init,account_choice:0
|
||||
msgid "Show Accounts"
|
||||
msgstr ""
|
||||
msgstr "Mostrar Contas"
|
||||
|
||||
#. module: account_balance
|
||||
#: rml:account.account.balance.landscape:0
|
||||
|
|
|
@ -0,0 +1,53 @@
|
|||
# Finnish 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 <EMAIL@ADDRESS>, 2010.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2010-03-17 10:06+0000\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: Finnish <fi@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:34+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account_tax_include
|
||||
#: constraint:ir.ui.view:0
|
||||
msgid "Invalid XML for View Architecture!"
|
||||
msgstr "Virheellinen XML näkymä-arkkitehtuurille!"
|
||||
|
||||
#. module: account_tax_include
|
||||
#: field:account.invoice,price_type:0
|
||||
msgid "Price method"
|
||||
msgstr "Hinnan tyyppi"
|
||||
|
||||
#. module: account_tax_include
|
||||
#: model:ir.module.module,shortdesc:account_tax_include.module_meta_information
|
||||
msgid "Invoices and prices with taxes included"
|
||||
msgstr "Laskut ja hinnat veroilla"
|
||||
|
||||
#. module: account_tax_include
|
||||
#: selection:account.invoice,price_type:0
|
||||
msgid "Tax included"
|
||||
msgstr "Vero sisältyy"
|
||||
|
||||
#. module: account_tax_include
|
||||
#: selection:account.invoice,price_type:0
|
||||
msgid "Tax excluded"
|
||||
msgstr "Ilman veroa"
|
||||
|
||||
#. module: account_tax_include
|
||||
#: view:account.tax:0
|
||||
msgid "Compute Code for Taxes included prices"
|
||||
msgstr "Laske koodi hinnoille joissa on vero mukana"
|
||||
|
||||
#. module: account_tax_include
|
||||
#: field:account.invoice.line,price_subtotal_incl:0
|
||||
msgid "Subtotal"
|
||||
msgstr "Välisumma"
|
|
@ -342,26 +342,17 @@ class calendar_attendee(osv.osv):
|
|||
result[id][name] = ', '.join(fromdata)
|
||||
if name == 'event_date':
|
||||
if attdata.ref:
|
||||
model, res_id = tuple(attdata.ref.split(','))
|
||||
model_obj = self.pool.get(model)
|
||||
obj = model_obj.read(cr, uid, res_id, ['date'])[0]
|
||||
result[id][name] = obj.get('date')
|
||||
result[id][name] = attdata.ref.date
|
||||
else:
|
||||
result[id][name] = False
|
||||
if name == 'event_end_date':
|
||||
if attdata.ref:
|
||||
model, res_id = tuple(attdata.ref.split(','))
|
||||
model_obj = self.pool.get(model)
|
||||
obj = model_obj.read(cr, uid, res_id, ['date_deadline'])[0]
|
||||
result[id][name] = obj.get('date_deadline')
|
||||
result[id][name] = attdata.ref.date_deadline
|
||||
else:
|
||||
result[id][name] = False
|
||||
if name == 'sent_by_uid':
|
||||
if attdata.ref:
|
||||
model, res_id = tuple(attdata.ref.split(','))
|
||||
model_obj = self.pool.get(model)
|
||||
obj = model_obj.read(cr, uid, res_id, ['user_id'])[0]
|
||||
result[id][name] = obj.get('user_id')
|
||||
result[id][name] = (attdata.ref.user_id.id,attdata.ref.user_id.name)
|
||||
else:
|
||||
result[id][name] = uid
|
||||
if name == 'language':
|
||||
|
@ -458,8 +449,7 @@ request was delegated to"),
|
|||
for att in self.browse(cr, uid, ids, context=context):
|
||||
sign = att.sent_by_uid and att.sent_by_uid.signature or ''
|
||||
sign = '<br>'.join(sign and sign.split('\n') or [])
|
||||
model, res_id = tuple(att.ref.split(','))
|
||||
res_obj = self.pool.get(model).browse(cr, uid, res_id)
|
||||
res_obj = att.ref
|
||||
if res_obj and len(res_obj):
|
||||
res_obj = res_obj[0]
|
||||
sub = '[%s Invitation][%d] %s' % (company, att.id, res_obj.name)
|
||||
|
@ -507,9 +497,7 @@ request was delegated to"),
|
|||
if user:
|
||||
ref = vals.get('ref', None)
|
||||
if ref:
|
||||
model, event = ref.split(',')
|
||||
model_obj = self.pool.get(model)
|
||||
event_ref = model_obj.browse(cr, uid, event, context=context)[0]
|
||||
event_ref = ref
|
||||
if event_ref.user_id.id != user[0]:
|
||||
defaults = {'user_id': user[0]}
|
||||
new_event = model_obj.copy(cr, uid, event, default=defaults, context=context)
|
||||
|
|
|
@ -159,8 +159,8 @@
|
|||
<field name="name" select="1"/>
|
||||
<field name="trigger_interval" select="1"/>
|
||||
<field name="trigger_duration" select="1"/>
|
||||
<field name="trigger_related" select="1"/>
|
||||
<field name="trigger_occurs" select="1"/>
|
||||
<field name="trigger_related" select="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
@ -8,13 +8,13 @@ msgstr ""
|
|||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2009-12-01 15:33+0000\n"
|
||||
"Last-Translator: Wei \"oldrev\" Li <oldrev@gmail.com>\n"
|
||||
"PO-Revision-Date: 2010-03-17 14:08+0000\n"
|
||||
"Last-Translator: 英华 <wantinghard@gmail.com>\n"
|
||||
"Language-Team: Simplified Chinese <zh_CN@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-11 05:04+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: base_module_quality
|
||||
|
@ -86,7 +86,7 @@ msgstr "已跳过"
|
|||
msgid ""
|
||||
"The test will be completed only if the module is installed or if the test "
|
||||
"may be processed on uninstalled module."
|
||||
msgstr ""
|
||||
msgstr "只有模块已经安装或测试能在已卸载的模块上运行的情况下测试才能完成。"
|
||||
|
||||
#. module: base_module_quality
|
||||
#: constraint:ir.ui.view:0
|
||||
|
@ -132,7 +132,7 @@ msgstr "概要"
|
|||
#. module: base_module_quality
|
||||
#: model:ir.actions.wizard,name:base_module_quality.quality_detail_save
|
||||
msgid "Report Save"
|
||||
msgstr ""
|
||||
msgstr "保存报告"
|
||||
|
||||
#. module: base_module_quality
|
||||
#: wizard_view:quality_detail_save,init:0
|
||||
|
|
|
@ -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: 2009-11-18 06:19+0000\n"
|
||||
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
|
||||
"PO-Revision-Date: 2010-03-16 14:28+0000\n"
|
||||
"Last-Translator: goranc <goranc@gmail.com>\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-03-11 05:00+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: base_report_creator
|
||||
|
@ -23,6 +23,8 @@ msgid ""
|
|||
"records.\n"
|
||||
" e.g. res_partner.id=3"
|
||||
msgstr ""
|
||||
"Unesite izraz za polje po kojem želite filtrirati zapise.\n"
|
||||
"npr. res_partner.id=3"
|
||||
|
||||
#. module: base_report_creator
|
||||
#: field:base_report_creator.report,view_graph_type:0
|
||||
|
@ -47,7 +49,7 @@ msgstr "Grafički"
|
|||
#. module: base_report_creator
|
||||
#: constraint:ir.actions.act_window:0
|
||||
msgid "Invalid model name in the action definition."
|
||||
msgstr ""
|
||||
msgstr "Pogrešno ime modela u definiciji akcije."
|
||||
|
||||
#. module: base_report_creator
|
||||
#: view:base_report_creator.report:0
|
||||
|
@ -158,7 +160,7 @@ msgstr "Kreiraj izbornik izvještaja"
|
|||
#: selection:base_report_creator.report,view_type2:0
|
||||
#: selection:base_report_creator.report,view_type3:0
|
||||
msgid "Form"
|
||||
msgstr ""
|
||||
msgstr "Ekran"
|
||||
|
||||
#. module: base_report_creator
|
||||
#: selection:base_report_creator.report,view_type3:0
|
||||
|
@ -335,7 +337,7 @@ msgstr "Potvrdi filter"
|
|||
#. module: base_report_creator
|
||||
#: field:base_report_creator.report.filter,name:0
|
||||
msgid "Filter Name"
|
||||
msgstr ""
|
||||
msgstr "Filter"
|
||||
|
||||
#. module: base_report_creator
|
||||
#: model:ir.actions.wizard,name:base_report_creator.wizard_report_open
|
||||
|
|
|
@ -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: 2009-02-03 06:25+0000\n"
|
||||
"Last-Translator: <>\n"
|
||||
"PO-Revision-Date: 2010-03-16 08:14+0000\n"
|
||||
"Last-Translator: Anders Wallenquist <anders.wallenquist@vertel.se>\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-03-11 05:01+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: board_account
|
||||
#: view:board.board:0
|
||||
msgid "Analytic accounts to close"
|
||||
msgstr ""
|
||||
msgstr "Objektkonton att stänga"
|
||||
|
||||
#. module: board_account
|
||||
#: view:board.board:0
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
* List of procurement in exception
|
||||
""",
|
||||
'author': 'Tiny',
|
||||
'depends': ['board', 'mrp', 'stock', 'report_mrp'],
|
||||
'depends': ['board', 'mrp', 'stock' ],
|
||||
'update_xml': ['board_manufacturing_view.xml'],
|
||||
'demo_xml': ['board_manufacturing_demo.xml'],
|
||||
'installable': True,
|
||||
|
|
|
@ -20,9 +20,9 @@
|
|||
|
||||
|
||||
<child2>
|
||||
<action colspan="4" name="%(report_mrp.action_report_workcenter_load_tree)d" string="Work Center future load"/>
|
||||
<action colspan="4" name="%(mrp.action_report_workcenter_load_tree)d" string="Work Center future load"/>
|
||||
|
||||
<action colspan="4" name="%(report_mrp.action_report_in_out_picking_tree)d" string="Stock value variation"/>
|
||||
<action colspan="4" name="%(mrp.action_report_in_out_picking_tree)d" string="Stock value variation"/>
|
||||
</child2>
|
||||
</hpaned>
|
||||
</form>
|
||||
|
|
|
@ -65,7 +65,7 @@ between mails and Open ERP.""",
|
|||
'wizard/crm_lead_to_opportunity_view.xml',
|
||||
'wizard/crm_phonecall2phonecall.xml',
|
||||
'wizard/phonecall2meeting.xml',
|
||||
'wizard/crm_phonecall_to_partner_view.xml',
|
||||
'wizard/phonecall2partner_view.xml',
|
||||
'wizard/crm_phonecall_to_opportunity_view.xml',
|
||||
'wizard/crm_opportunity_to_meeting_view.xml',
|
||||
'wizard/crm_opportunity_to_phonecall_view.xml',
|
||||
|
@ -117,3 +117,4 @@ between mails and Open ERP.""",
|
|||
'certificate': '0079056041421',
|
||||
}
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -153,6 +153,7 @@ class crm_case_stage(osv.osv):
|
|||
'object_id': fields.many2one('ir.model','Object Name'),
|
||||
'probability': fields.float('Probability (%)', required=True),
|
||||
'on_change': fields.boolean('Change Probability Automatically',help="Change Probability on next and previous stages."),
|
||||
'requirements': fields.text('Requirements')
|
||||
}
|
||||
def _find_object_id(self, cr, uid, context=None):
|
||||
object_id = context and context.get('object_id', False) or False
|
||||
|
@ -353,7 +354,7 @@ class crm_case(osv.osv):
|
|||
'section_id': case.section_id.id
|
||||
}
|
||||
obj = self.pool.get('crm.case.log')
|
||||
if history and case.description:
|
||||
if history:
|
||||
obj = self.pool.get('crm.case.history')
|
||||
data['description'] = details or case.description
|
||||
data['email'] = email or \
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
<field name="model">crm.claim</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Claims" colors="blue:state=='open';red:(date_deadline<=current_date)">
|
||||
<tree string="Claims" colors="blue:state=='pending';black:state=='open';grey:state in ('close', 'cancel')">
|
||||
<field name="id"/>
|
||||
<field name="name"/>
|
||||
<field name="partner_id"/>
|
||||
|
|
|
@ -202,24 +202,24 @@
|
|||
<search string="Search Funds">
|
||||
<group col='6' colspan='4'>
|
||||
<filter icon="terp-partner" string="My Funds"
|
||||
default="1" domain="[('user_id','=',uid)]"
|
||||
separator="1"
|
||||
help="Funds Related to Current User"
|
||||
/>
|
||||
<field name="state" select="1">
|
||||
<filter icon="gtk-new" domain="[('state','in',('draft', 'open'))]" help="Current Funds" default="1"/>
|
||||
<filter icon="gtk-yes" domain="[('state','=','open')]" help="Open Funds"/>
|
||||
<filter icon="gtk-media-pause" domain="[('state','=','pending')]" help="Pending Funds"/>
|
||||
</field>
|
||||
default="1" domain="[('user_id','=',uid)]"
|
||||
separator="1"
|
||||
help="Funds Related to Current User"
|
||||
/>
|
||||
<filter icon="gtk-new" string="Current Funds" domain="[('state','in',('draft', 'open'))]" help="Current Funds" />
|
||||
<filter icon="gtk-yes" string="Open Funds" domain="[('state','=','open')]" help="Open Funds"/>
|
||||
<filter icon="gtk-media-pause" string="Pending Funds" domain="[('state','=','pending')]" help="Pending Funds"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="state" select="1" />
|
||||
<field name="name" select='1' string="Fund Description"/>
|
||||
<field name="user_id" select="1" widget="selection">
|
||||
<filter icon="terp-partner" domain="[('user_id','=', False)]" help="Unassigned" />
|
||||
<filter icon="terp-partner" domain="[('user_id','=', False)]" help="Unassigned" />
|
||||
</field>
|
||||
<field name="section_id" select="1" widget="selection" string="Section" default="context.get('section_id', False)">
|
||||
<filter icon="terp-crm"
|
||||
<field name="section_id" select="1" widget="selection" string="Section" default="context.get('section_id', False)">
|
||||
<filter icon="terp-crm"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
help="My section"
|
||||
/>
|
||||
/>
|
||||
</field>
|
||||
</group>
|
||||
</search>
|
||||
|
|
|
@ -122,7 +122,8 @@
|
|||
<field name="model">crm.helpdesk</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Helpdesk Support Tree" colors="red:state=='open';black:state in ('draft', 'cancel','done','pending')">
|
||||
<tree string="Helpdesk Support Tree"
|
||||
colors="black:state=='open';blue:state=='pending';grey:state in ('cancel','close')">
|
||||
<field name="id"/>
|
||||
<field name="name" string="Query Description" />
|
||||
<field name="partner_id" string="Partner"/>
|
||||
|
|
|
@ -74,17 +74,14 @@ class calendar_attendee(osv.osv):
|
|||
result[id] = {}
|
||||
if name == 'categ_id':
|
||||
if attdata.ref:
|
||||
model, res_id = tuple(attdata.ref.split(','))
|
||||
model_obj = self.pool.get(model)
|
||||
obj = model_obj.read(cr, uid, res_id, ['categ_id'])[0]
|
||||
result[id][name] = obj.get('categ_id')
|
||||
result[id][name] = (attdata.ref.categ_id.id,attdata.ref.categ_id.name,)
|
||||
else:
|
||||
result[id][name] = False
|
||||
return result
|
||||
_columns = {
|
||||
'categ_id': fields.function(_compute_data, method=True, \
|
||||
string='Event Type', type="many2one", \
|
||||
relation="crm.case.categ", multi='categ_id'),
|
||||
relation="crm.case.categ", multi='categ_id'),
|
||||
}
|
||||
calendar_attendee()
|
||||
|
||||
|
|
|
@ -217,24 +217,24 @@
|
|||
/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="name" string="Opportunity"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<filter icon="terp-partner"
|
||||
domain="[('user_id','=',uid)]"
|
||||
help="My Opportunities" default="1"
|
||||
/>
|
||||
</field>
|
||||
<field name="partner_id"/>
|
||||
<field name="state">
|
||||
<filter icon="gtk-media-rewind"
|
||||
string="New and open opportunities"
|
||||
default="1"
|
||||
domain="[('state','in',('draft','open'))]"/>
|
||||
</field>
|
||||
<field name="section_id" default="context.get('section_id', False)" select="1" widget="selection">
|
||||
<filter icon="terp-crm"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
help="My section"/>
|
||||
</field>
|
||||
<field name="state">
|
||||
<filter icon="gtk-media-rewind"
|
||||
help="New and open opportunities"
|
||||
default="1"
|
||||
domain="[('state','in',('draft','open'))]" />
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="4">
|
||||
<filter string="Stage" icon="terp-crm" domain="[]" context="{'group_by':'stage_id'}"/>
|
||||
|
|
|
@ -71,13 +71,15 @@
|
|||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Stage">
|
||||
<separator string="Stage Definition" colspan="4"/>
|
||||
<field name="name" select="1"/>
|
||||
<field name="section_id" select="1" widget="selection"/>
|
||||
<field name="object_id" invisible="1" />
|
||||
<field name="sequence"/>
|
||||
<field name="probability"/>
|
||||
<field name="on_change"/>
|
||||
|
||||
<separator string="Requirements" colspan="4"/>
|
||||
<field name="requirements" nolabel="1" colspan="4"/>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
@ -632,7 +634,7 @@
|
|||
<field eval="18" name="priority"/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="category_id" position="after">
|
||||
<field name="section_id" completion="1" widget="selection"/>
|
||||
<field name="section_id" completion="1" widget="selection"/>
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
@ -26,6 +26,7 @@ import crm_lead_report
|
|||
import crm_phonecall_report
|
||||
import crm_fundraising_report
|
||||
import crm_opportunity_report
|
||||
import crm_helpdesk_report
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -0,0 +1,63 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
from osv import fields,osv
|
||||
import tools
|
||||
|
||||
class crm_helpdesk_report(osv.osv):
|
||||
_name = "crm.helpdesk.report"
|
||||
_description = "Helpdesk report after Sales Services"
|
||||
_auto = False
|
||||
_inherit = "crm.case.report"
|
||||
_columns = {
|
||||
'delay_close': fields.char('Delay to close', size=20, readonly=True),
|
||||
'partner_id': fields.many2one('res.partner', 'Partner' ,readonly=True),
|
||||
'company_id': fields.many2one('res.company','Company',readonly=True),
|
||||
'date_deadline': fields.date('Deadline'),
|
||||
'priority': fields.selection([('5','Lowest'),('4','Low'),('3','Normal'),('2','High'),('1','Highest')], 'Priority'),
|
||||
}
|
||||
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'crm_helpdesk_report')
|
||||
cr.execute("""
|
||||
create or replace view crm_helpdesk_report 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.user_id,
|
||||
c.section_id,
|
||||
c.partner_id,
|
||||
c.company_id,
|
||||
c.priority,
|
||||
c.date_deadline,
|
||||
count(*) as nbr,
|
||||
0 as avg_answers,
|
||||
0.0 as perc_done,
|
||||
0.0 as perc_cancel,
|
||||
to_char(avg(date_closed-c.create_date), 'DD"d" HH24:MI:SS') as delay_close
|
||||
from
|
||||
crm_helpdesk c
|
||||
group by to_char(c.create_date, 'YYYY'), to_char(c.create_date, 'MM'), c.state, c.user_id,c.section_id,c.priority, c.partner_id,c.company_id,c.date_deadline
|
||||
)""")
|
||||
crm_helpdesk_report()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
|
@ -0,0 +1,148 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<!--
|
||||
Helpdesk report after Sales Services
|
||||
-->
|
||||
|
||||
<record id="view_report_crm_helpdesk_tree" model="ir.ui.view">
|
||||
<field name="name">crm.helpdesk.report.tree</field>
|
||||
<field name="model">crm.helpdesk.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Helpdesk">
|
||||
<field name="name" />
|
||||
<field name="month"/>
|
||||
<field name="section_id" />
|
||||
<field name="user_id" />
|
||||
<field name="company_id"/>
|
||||
<field name="partner_id" />
|
||||
<field name="date_deadline" invisible="1"/>
|
||||
<field name="priority" invisible="1"/>
|
||||
<field name="nbr" string="#Helpdesk" />
|
||||
<field name="delay_close"/>
|
||||
<field name="state" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record id="view_report_crm_helpdesk_form" model="ir.ui.view">
|
||||
<field name="name">crm.helpdesk.report.form</field>
|
||||
<field name="model">crm.helpdesk.report</field>
|
||||
<field name="inherit_id" ref="view_crm_case_form"/>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<field name="nbr" position="after">
|
||||
<field name="delay_close"/>
|
||||
<field name="amount_revenue"/>
|
||||
<field name="amount_revenue_prob"/>
|
||||
<field name="probability"/>
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_report_crm_helpdesk_graph" model="ir.ui.view">
|
||||
<field name="name">crm.helpdesk.report.graph</field>
|
||||
<field name="model">crm.helpdesk.report</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph orientation="horizontal" string="Helpdesk" type="bar">
|
||||
<field name="state"/>
|
||||
<field name="nbr" operator="+"/>
|
||||
<field group="True" name="user_id"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_report_crm_helpdesk_filter" model="ir.ui.view">
|
||||
<field name="name">crm.helpdesk.report.select</field>
|
||||
<field name="model">crm.helpdesk.report</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search">
|
||||
<group col="16" colspan="9">
|
||||
<filter string="This Year" icon="terp-hr" domain="[('name','=',time.localtime()[0])]" default="1" />
|
||||
<filter string="This Month" icon="terp-hr" domain="[('month','=',time.strftime('%%m'))]" default="1"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Current" icon="terp-hr" domain="[('state','in',('open','draft'))]"/>
|
||||
<filter string="Won" icon="terp-hr" domain="[('state','=','done')]"/>
|
||||
<filter string="Lost" icon="terp-hr" domain="[('state','=','cancel')]"/>
|
||||
<filter string="Deadline" icon="terp-hr" domain="[('date_deadline','=',time.strftime('%%m/%%d/%%Y'))]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="section_id" default="context.get('section_id', False)" widget="selection"
|
||||
context="{'invisible_section': False}">
|
||||
<filter icon="terp-crm"
|
||||
context="{'invisible_section': False}"
|
||||
domain="[('section_id.user_id','=',uid)]"
|
||||
help="My section"/>
|
||||
</field>
|
||||
<field name="company_id" widget="selection">
|
||||
<filter icon="terp-crm"
|
||||
context="{'invisible_section': False}"
|
||||
domain="[('section_id.user_id.company_id','=',uid)]"
|
||||
help="My company"/>
|
||||
</field>
|
||||
<field name="user_id" widget="selection"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="1" string="Extended options..." colspan="4" col="5">
|
||||
<filter icon="terp-sale"
|
||||
string="Lowest"
|
||||
domain="[('priority','=','5')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="Low"
|
||||
domain="[('priority','=','4')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="Normal"
|
||||
domain="[('priority','=','3')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="High"
|
||||
domain="[('priority','=','2')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="Highest"
|
||||
domain="[('priority','=','1')]"/>
|
||||
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="4" col="8">
|
||||
<filter string="User" icon="terp-sale" domain="[]" context="{'group_by':'user_id'}" default="1" />
|
||||
<filter string="Company" icon="terp-sale" domain="[]" context="{'group_by':'company_id'}"/>
|
||||
<filter string="Section" icon="terp-sale" domain="[]" context="{'group_by':'section_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="State" icon="terp-sale" domain="[]" context="{'group_by':'state'}"/>
|
||||
<filter string="Partner" icon="terp-sale" domain="[]" context="{'group_by':'partner_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-sale" domain="[]" context="{'group_by':'month'}"/>
|
||||
<filter string="Year" icon="terp-sale" domain="[]" context="{'group_by':'name'}"/>
|
||||
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
<record id="action_report_crm_helpdesk" model="ir.actions.act_window">
|
||||
<field name="name">Helpdesk</field>
|
||||
<field name="res_model">crm.helpdesk.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="view_id" ref="view_report_crm_helpdesk_tree"/>
|
||||
<field name="search_view_id" ref="view_report_crm_helpdesk_filter"/>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_report_crm_helpdesk_tree">
|
||||
<field name="sequence" eval="1"/>
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="view_id" ref="view_report_crm_helpdesk_tree"/>
|
||||
<field name="act_window_id" ref="action_report_crm_helpdesk"/>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_report_crm_helpdesk_graph">
|
||||
<field name="sequence" eval="2"/>
|
||||
<field name="view_mode">graph</field>
|
||||
<field name="view_id" ref="view_report_crm_helpdesk_graph"/>
|
||||
<field name="act_window_id" ref="action_report_crm_helpdesk"/>
|
||||
</record>
|
||||
|
||||
<menuitem name="Helpdesk" action="action_report_crm_helpdesk" id="menu_report_crm_helpdesks_tree" parent="base.next_id_64"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<data>
|
||||
|
||||
<record id="view_crm_case_tree" model="ir.ui.view">
|
||||
<field name="name">crm.case.report.tree</field>
|
||||
|
@ -56,11 +56,11 @@
|
|||
<group col="16" colspan="8">
|
||||
<filter string="This Year" icon="terp-hr" domain="[('name','=',time.localtime()[0])]" default="1" />
|
||||
<filter string="This Month" icon="terp-hr" domain="[('month','=',time.strftime('%%m'))]" default="1"/>
|
||||
<separator orientation="vertical"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Current" icon="terp-hr" domain="[('state','in',('open','draft'))]"/>
|
||||
<filter string="Won" icon="terp-hr" domain="[('state','=','done')]"/>
|
||||
<filter string="Lost" icon="terp-hr" domain="[('state','=','cancel')]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="section_id" default="context.get('section_id', False)" widget="selection"
|
||||
context="{'invisible_section': False}">
|
||||
<filter icon="terp-crm"
|
||||
|
@ -74,7 +74,9 @@
|
|||
domain="[('section_id.user_id.company_id','=',uid)]"
|
||||
help="My company"/>
|
||||
</field>
|
||||
<field name="user_id" widget="selection"/>
|
||||
<field name="user_id" select="1" widget="selection">
|
||||
<filter icon="terp-crm" string="My Task" domain="[('user_id','=',uid)]" />
|
||||
</field>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="4" col="8">
|
||||
|
@ -87,12 +89,12 @@
|
|||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-sale" domain="[]" context="{'group_by':'month'}"/>
|
||||
<filter string="Year" icon="terp-sale" domain="[]" context="{'group_by':'name'}"/>
|
||||
|
||||
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
<menuitem id="base.next_id_64" name="Reporting" parent="base.menu_base_partner" sequence="8"/>
|
||||
<menuitem id="base.next_id_64" name="Reporting" parent="base.menu_base_partner" sequence="8"/>
|
||||
|
||||
|
||||
<record id="action_report_crm_case_tree" model="ir.actions.act_window">
|
||||
|
@ -112,7 +114,7 @@
|
|||
|
||||
<act_window domain="[('section_id', '=', active_id)]" id="act_crm_case_section_2_report_crm_case_categ" name="Monthly cases by section" res_model="crm.case.report" src_model="crm.case.section"/>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- Closed & Open CRM Case view for Random Activities dashboard -->
|
||||
|
@ -162,6 +164,6 @@
|
|||
<field name="view_id" ref="board_view_crm_case_open_dashboard_tree"/>
|
||||
<field name="domain">[('state','=','open')]</field>
|
||||
</record>
|
||||
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
|
@ -40,3 +40,4 @@
|
|||
"access_crm_phonecall2partner","crm.phonecall2partner","model_crm_phonecall2partner","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_phonecall2meeting","crm.phonecall2meeting","model_crm_phonecall2meeting","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_phonecall2opportunity","crm.phonecall2opportunity","model_crm_phonecall2opportunity","crm.group_crm_user",1,0,0,0
|
||||
"access_report_crm_helpdesk","report.crm.helpdesk","model_crm_helpdesk_report","crm.group_crm_user",1,0,0,0
|
||||
|
|
|
|
@ -72,11 +72,7 @@ def _mass_mail_send(self, cr, uid, data, context):
|
|||
pool = pooler.get_pool(cr.dbname)
|
||||
case_pool=pool.get(data.get('model'))
|
||||
|
||||
case = case_pool.browse(cr,uid,data['ids'])[0]
|
||||
case_pool.write(cr, uid, [case.id], {
|
||||
#'som': False,
|
||||
'canal_id': False,
|
||||
})
|
||||
case = case_pool.browse(cr,uid,data['ids'])[0]
|
||||
emails = [data['form']['to']] + (data['form']['cc'] or '').split(',')
|
||||
emails = filter(None, emails)
|
||||
body = data['form']['text']
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
|
@ -26,5 +26,6 @@ import document_directory
|
|||
import directory_content
|
||||
import directory_report
|
||||
import document
|
||||
import report
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
|
@ -24,14 +24,14 @@
|
|||
'name': 'Integrated Document Management System',
|
||||
'version': '1.99',
|
||||
'category': 'Generic Modules/Others',
|
||||
'description': """This is a complete document management system:
|
||||
'description': """This is a complete document management system:
|
||||
* User Authentication
|
||||
* Document Indexation
|
||||
|
||||
ATTENTION:
|
||||
- When you install this module in a running company that have already PDF files stored into the database,
|
||||
you will lose them all.
|
||||
- After installing this module PDF's are not longer stored into the database,
|
||||
ATTENTION:
|
||||
- When you install this module in a running company that have already PDF files stored into the database,
|
||||
you will lose them all.
|
||||
- After installing this module PDF's are not longer stored into the database,
|
||||
but in the servers rootpad like /server/bin/filestore.
|
||||
""",
|
||||
'author': 'Tiny',
|
||||
|
@ -42,7 +42,8 @@
|
|||
'document_view.xml',
|
||||
'document_data.xml',
|
||||
'security/document_security.xml',
|
||||
'security/ir.model.access.csv'
|
||||
'security/ir.model.access.csv',
|
||||
'report/document_report_view.xml'
|
||||
],
|
||||
'demo_xml': [ 'document_demo.xml',],
|
||||
'installable': True,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -15,11 +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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import report_mrp
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
import document_report
|
|
@ -11,3 +11,11 @@
|
|||
"access_document_storage_group_system","document.storage group system","model_document_storage","base.group_user",1,0,0,0
|
||||
"access_document_directory_dctx_group_document_manager","document.directory.dctx document manager","model_document_directory_dctx","group_document_manager",1,1,1,1
|
||||
"access_document_directory_dctx_group_system","document.directory.dctx group system","model_document_directory_dctx","base.group_system",1,1,1,1
|
||||
"access_report_document_user_group_document_manager","report.document.user document manager","model_report_document_user","document.group_document_manager",1,0,0,0
|
||||
"access_report_document_user_group_system","report.document.user group system","model_report_document_user","base.group_system",1,0,0,0
|
||||
"access_report_files_partner_group_document_manager","report.files.partner document manager","model_report_files_partner","document.group_document_manager",1,0,0,0
|
||||
"access_report_files_partner_group_system","report.files.partner group system","model_report_files_partner","base.group_system",1,0,0,0
|
||||
"access_report_document_file_group_document_manager","report.document.file document manager","model_report_document_file","document.group_document_manager",1,0,0,0
|
||||
"access_report_document_file_group_system","report.document.file group system","model_report_document_file","base.group_system",1,0,0,0
|
||||
"access_report_document_wall_group_document_manager","report.document.wall document manager","model_report_document_wall","document.group_document_manager",1,0,0,0
|
||||
"access_report_document_wall_group_system","report.document.wall group system","model_report_document_wall","base.group_system",1,0,0,0
|
||||
|
|
|
|
@ -8,19 +8,19 @@ msgstr ""
|
|||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2010-01-15 13:24+0000\n"
|
||||
"Last-Translator: vir (Open ERP) <vir@tinyerp.com>\n"
|
||||
"PO-Revision-Date: 2010-03-16 22:57+0000\n"
|
||||
"Last-Translator: Neetesh Biswas <Unknown>\n"
|
||||
"Language-Team: Hindi <hi@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-11 05:03+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: event_project
|
||||
#: constraint:ir.ui.view:0
|
||||
msgid "Invalid XML for View Architecture!"
|
||||
msgstr ""
|
||||
msgstr "संरचना देखने के लिए अमान्य XML"
|
||||
|
||||
#. module: event_project
|
||||
#: model:ir.actions.wizard,name:event_project.wizard_event_task
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- encoding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import hr_evaluation
|
||||
import report
|
||||
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
|
@ -31,7 +31,9 @@
|
|||
"demo_xml" : ["hr_evaluation_demo.xml"],
|
||||
"update_xml" : [
|
||||
"security/ir.model.access.csv",
|
||||
"hr_evaluation_view.xml"],
|
||||
"hr_evaluation_view.xml",
|
||||
"hr_evaluation_data.xml",
|
||||
"report/hr_evaluation_report_view.xml"],
|
||||
"active": False,
|
||||
"installable": True
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# -*- encoding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
|
@ -15,11 +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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import report_task
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
import hr_evaluation_report
|
|
@ -0,0 +1,74 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import tools
|
||||
from osv import fields,osv
|
||||
|
||||
|
||||
class hr_evaluation_report(osv.osv):
|
||||
_name = "hr.evaluation.report"
|
||||
_description = "Evaluations Statistics"
|
||||
_auto = False
|
||||
_rec_name = 'date'
|
||||
_columns = {
|
||||
'create_date': fields.datetime('Create Date', readonly=True),
|
||||
'deadline': fields.date("Deadline", readonly=True),
|
||||
'closed': fields.date("closed", 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),
|
||||
'nbr':fields.integer('# of Requests', readonly=True),
|
||||
'state': fields.selection([
|
||||
('draft','Draft'),
|
||||
('wait','Plan In Progress'),
|
||||
('progress','Final Validation'),
|
||||
('done','Done'),
|
||||
('cancel','Cancelled'),
|
||||
], 'State',readonly=True),
|
||||
}
|
||||
_order = 'create_date desc'
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'hr_evaluation_report')
|
||||
cr.execute("""
|
||||
create or replace view hr_evaluation_report as (
|
||||
select
|
||||
min(l.id) as id,
|
||||
s.create_date as create_date,
|
||||
s.employee_id,
|
||||
s.date as deadline,
|
||||
s.date_close as closed,
|
||||
to_char(s.create_date, 'YYYY') as year,
|
||||
to_char(s.create_date, 'MM') as month,
|
||||
count(*) as nbr,
|
||||
s.state
|
||||
from
|
||||
hr_evaluation_interview l
|
||||
left join
|
||||
hr_evaluation_evaluation s on (s.id=l.evaluation_id)
|
||||
group by
|
||||
s.create_date,s.state,s.employee_id,
|
||||
s.date,s.date_close
|
||||
)
|
||||
""")
|
||||
hr_evaluation_report()
|
||||
|
|
@ -0,0 +1,70 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<record id="view_evaluation_report_tree" model="ir.ui.view">
|
||||
<field name="name">hr.evaluation.report.tree</field>
|
||||
<field name="model">hr.evaluation.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Evaluations Statistics">
|
||||
<field name="create_date"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="deadline"/>
|
||||
<field name="closed" invisible="1"/>
|
||||
<field name="year" invisible="1"/>
|
||||
<field name="month" invisible="1"/>
|
||||
<field name="nbr" sum="# of Requests"/>
|
||||
<field name="state"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_evaluation_report_search" model="ir.ui.view">
|
||||
<field name="name">hr.evaluation.report.search</field>
|
||||
<field name="model">hr.evaluation.report</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Evaluations">
|
||||
<filter icon="terp-hr"
|
||||
string="This Year"
|
||||
domain="[('year','=',time.strftime('%%Y'))]"
|
||||
help="Evaluations of the year"/>
|
||||
<filter icon="terp-hr"
|
||||
string="This Month"
|
||||
domain="[('month','=',time.strftime('%%m'))]"
|
||||
help="Evaluations of this month"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Deadline"
|
||||
domain="[('deadline','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Closed"
|
||||
domain="[('closed','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="employee_id"/>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="12">
|
||||
<filter string="Employee" icon="terp-hr" context="{'group_by':'employee_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="State" icon="terp-hr" context="{'group_by':'state'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-hr" context="{'group_by':'create_date'}"/>
|
||||
<filter string="Year" icon="terp-hr" context="{'group_by':'year'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_evaluation_report_all" model="ir.actions.act_window">
|
||||
<field name="name">Evaluations</field>
|
||||
<field name="res_model">hr.evaluation.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="search_view_id" ref="view_evaluation_report_search"/>
|
||||
</record>
|
||||
|
||||
<menuitem id="hr.menu_hr_reporting" name="Reporting" parent="hr.menu_hr_root" sequence="8"/>
|
||||
<menuitem action="action_evaluation_report_all" id="menu_evaluation_report_all" parent="hr.menu_hr_reporting" sequence="0"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
|
@ -1,9 +1,10 @@
|
|||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_evaluation_evaluation","hr_evaluation.evaluation","model_hr_evaluation_evaluation",hr.group_hr_user,1,0,0,0
|
||||
"access_hr_evaluation_evaluation_manager","hr_evaluation.evaluation","model_hr_evaluation_evaluation",hr.group_hr_manager,1,1,1,1
|
||||
"access_hr_evaluation_plan","hr_evaluation.plan","model_hr_evaluation_evaluation",hr.group_hr_user,1,0,0,0
|
||||
"access_hr_evaluation_plan_manager","hr_evaluation.plan","model_hr_evaluation_plan",hr.group_hr_manager,1,1,1,1
|
||||
"access_hr_evaluation_plan_phase","hr_evaluation.plan.phase","model_hr_evaluation_plan_phase",hr.group_hr_user,1,0,0,0
|
||||
"access_hr_evaluation_plan_phase_manager","hr_evaluation.plan.phase","model_hr_evaluation_plan_phase",hr.group_hr_manager,1,1,1,1
|
||||
"access_hr_evaluation_interview","hr.evaluation.interview","model_hr_evaluation_interview",hr.group_hr_user,1,0,0,0
|
||||
"access_hr_evaluation_interview_manager","hr.evaluation.interview","model_hr_evaluation_interview",hr.group_hr_manager,1,1,1,1
|
||||
"access_hr_evaluation_evaluation","hr_evaluation.evaluation","model_hr_evaluation_evaluation","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_evaluation_manager","hr_evaluation.evaluation","model_hr_evaluation_evaluation","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_plan","hr_evaluation.plan","model_hr_evaluation_evaluation","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_plan_manager","hr_evaluation.plan","model_hr_evaluation_plan","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_plan_phase","hr_evaluation.plan.phase","model_hr_evaluation_plan_phase","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_plan_phase_manager","hr_evaluation.plan.phase","model_hr_evaluation_plan_phase","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_interview","hr.evaluation.interview","model_hr_evaluation_interview","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_interview_manager","hr.evaluation.interview","model_hr_evaluation_interview","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_report","hr.evaluation.report","model_hr_evaluation_report",,1,0,0,0
|
||||
|
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
|
@ -48,7 +48,8 @@
|
|||
'hr_expense_workflow.xml',
|
||||
'hr_expense_view.xml',
|
||||
'hr_expense_report.xml',
|
||||
'process/hr_expense_process.xml'
|
||||
'process/hr_expense_process.xml',
|
||||
'report/hr_expense_report_view.xml'
|
||||
],
|
||||
'demo_xml': ['hr.expense.expense.csv'],
|
||||
'installable': True,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -15,10 +15,11 @@
|
|||
# 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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
import expense
|
||||
import hr_expense_report
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -0,0 +1,90 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import tools
|
||||
from osv import fields,osv
|
||||
|
||||
|
||||
class hr_expense_report(osv.osv):
|
||||
_name = "hr.expense.report"
|
||||
_description = "Expenses Statistics"
|
||||
_auto = False
|
||||
_rec_name = 'date'
|
||||
_columns = {
|
||||
'date': fields.date('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),
|
||||
'product_id':fields.many2one('product.product', 'Product', readonly=True),
|
||||
'product_qty':fields.float('Qty', readonly=True),
|
||||
'employee_id': fields.many2one('hr.employee', "Employee's Name", readonly=True),
|
||||
'invoice_id': fields.many2one('account.invoice', 'Invoice',readonly=True),
|
||||
'department_id':fields.many2one('hr.department','Department',readonly=True),
|
||||
'company_id':fields.many2one('res.company', 'Company', readonly=True),
|
||||
'user_id':fields.many2one('res.users', 'User', readonly=True),
|
||||
'price_total':fields.float('Total Price', readonly=True),
|
||||
'price_average':fields.float('Average Price', readonly=True),
|
||||
'nbr':fields.integer('# of Lines', readonly=True),
|
||||
'state': fields.selection([
|
||||
('draft', 'Draft'),
|
||||
('confirm', 'Waiting confirmation'),
|
||||
('accepted', 'Accepted'),
|
||||
('invoiced', 'Invoiced'),
|
||||
('paid', 'Reimbursed'),
|
||||
('cancelled', 'Cancelled')],
|
||||
'State', readonly=True),
|
||||
}
|
||||
_order = 'date desc'
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'hr_expense_report')
|
||||
cr.execute("""
|
||||
create or replace view hr_expense_report as (
|
||||
select
|
||||
min(l.id) as id,
|
||||
s.date as date,
|
||||
s.employee_id,
|
||||
s.invoice_id,
|
||||
s.department_id,
|
||||
to_char(s.date, 'YYYY') as year,
|
||||
to_char(s.date, 'MM') as month,
|
||||
l.product_id as product_id,
|
||||
sum(l.unit_quantity * u.factor) as product_qty,
|
||||
s.user_id as user_id,
|
||||
s.company_id as company_id,
|
||||
sum(l.unit_quantity*l.unit_amount) as price_total,
|
||||
(sum(l.unit_quantity*l.unit_amount)/sum(l.unit_quantity * u.factor))::decimal(16,2) as price_average,
|
||||
count(*) as nbr,
|
||||
s.state
|
||||
from
|
||||
hr_expense_line l
|
||||
left join
|
||||
hr_expense_expense s on (s.id=l.expense_id)
|
||||
left join product_uom u on (u.id=l.uom_id)
|
||||
group by
|
||||
s.date, l.product_id,s.invoice_id,
|
||||
s.department_id,
|
||||
l.uom_id, s.user_id, s.state,
|
||||
s.company_id,s.employee_id
|
||||
)
|
||||
""")
|
||||
hr_expense_report()
|
||||
|
|
@ -0,0 +1,100 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<record id="view_hr_expense_report_tree" model="ir.ui.view">
|
||||
<field name="name">hr.expense.report.tree</field>
|
||||
<field name="model">hr.expense.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Expenses Statistics">
|
||||
<field name="date"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="user_id"/>
|
||||
<field name="year" invisible="1"/>
|
||||
<field name="month" invisible="1"/>
|
||||
<field name="invoice_id" invisible="1"/>
|
||||
<field name="department_id" invisible="1"/>
|
||||
<field name="company_id" invisible="1"/>
|
||||
<field name="product_id"/>
|
||||
<field name="product_qty"/>
|
||||
<field name="nbr" sum="# of Lines"/>
|
||||
<field name="price_average" avg="Average Price"/>
|
||||
<field name="price_total" sum="Total Price"/>
|
||||
<field name="state" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_hr_expense_report_graph" model="ir.ui.view">
|
||||
<field name="name">hr.expense.report.graph</field>
|
||||
<field name="model">hr.expense.report</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Expenses Statistics" type="bar">
|
||||
<field name="product_id"/>
|
||||
<field name="price_total"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_hr_expense_report_search" model="ir.ui.view">
|
||||
<field name="name">hr.expense.report.search</field>
|
||||
<field name="model">hr.expense.report</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Expenses">
|
||||
<filter icon="terp-hr"
|
||||
string="This Year"
|
||||
domain="[('year','=',time.strftime('%%Y'))]"
|
||||
help="Expenses of the year"/>
|
||||
<filter icon="terp-hr"
|
||||
string="This Month"
|
||||
domain="[('month','=',time.strftime('%%m'))]"
|
||||
help="Expenses of this month"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Draft"
|
||||
domain="[('state','=','draft')]"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Expenses"
|
||||
default="1"
|
||||
domain="[('state','<>','draft'),('state','<>','cancelled')]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="product_id"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<filter icon="terp-hr"
|
||||
string="My Expenses"
|
||||
domain="[('user_id','=',uid)]"/>
|
||||
</field>
|
||||
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
|
||||
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="12">
|
||||
<filter string="Company" icon="terp-hr" context="{'group_by':'company_id'}"/>
|
||||
<filter string="User" icon="terp-hr" context="{'group_by':'user_id'}" default="1"/>
|
||||
<filter string="Employee" icon="terp-hr" context="{'group_by':'employee_id'}"/>
|
||||
<filter string="Department" icon="terp-hr" context="{'group_by':'department_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Product" icon="terp-hr" context="{'group_by':'product_id'}"/>
|
||||
<filter string="State" icon="terp-hr" context="{'group_by':'state'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-hr" context="{'group_by':'date'}"/>
|
||||
<filter string="Year" icon="terp-hr" context="{'group_by':'year'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_hr_expense_report_all" model="ir.actions.act_window">
|
||||
<field name="name">Expenses</field>
|
||||
<field name="res_model">hr.expense.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="search_view_id" ref="view_hr_expense_report_search"/>
|
||||
</record>
|
||||
|
||||
<menuitem id="hr.menu_hr_reporting" name="Reporting" parent="hr.menu_hr_root" sequence="8"/>
|
||||
<menuitem action="action_hr_expense_report_all" id="menu_hr_expense_report_all" parent="hr.menu_hr_reporting" sequence="0"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
|
@ -53,8 +53,8 @@
|
|||
'security/ir.model.access.csv',
|
||||
'hr_workflow.xml',
|
||||
'hr_view.xml',
|
||||
'hr_holidays_report.xml',
|
||||
'hr_holidays_wizard.xml',
|
||||
'hr_holidays_report.xml',
|
||||
#'process/hr_holidays_process.xml'
|
||||
],
|
||||
'demo_xml': [],
|
||||
|
|
|
@ -37,17 +37,13 @@ class hr_holidays_status(osv.osv):
|
|||
for record in self.browse(cr, uid, ids, context):
|
||||
res[record.id] = {}
|
||||
max_leaves = leaves_taken = 0
|
||||
obj_ids = self.pool.get('hr.holidays.per.user').search(cr, uid, [('user_id','=',uid),('employee_id','=',employee_id),('holiday_status','=',record.id)])
|
||||
if obj_ids:
|
||||
br_ob=self.pool.get('hr.holidays.per.user').browse(cr, uid, obj_ids)[0]
|
||||
max_leaves=br_ob.max_leaves
|
||||
if not return_false:
|
||||
cr.execute("""SELECT type, sum(number_of_days) FROM hr_holidays WHERE employee_id = %s AND state='validate' AND holiday_status_id = %s GROUP BY type""", (str(employee_id), str(record.id)))
|
||||
for line in cr.fetchall():
|
||||
if line[0] =='remove':
|
||||
leaves_taken = -line[1]
|
||||
leaves_taken = -line[1]
|
||||
if line[0] =='add':
|
||||
max_leaves = line[1]
|
||||
max_leaves = line[1]
|
||||
res[record.id]['max_leaves'] = max_leaves
|
||||
res[record.id]['leaves_taken'] = leaves_taken
|
||||
res[record.id]['remaining_leaves'] = max_leaves - leaves_taken
|
||||
|
@ -66,18 +62,19 @@ class hr_holidays_status(osv.osv):
|
|||
employee_id = employee_ids[0]
|
||||
else:
|
||||
return_false = True
|
||||
res = self.get_days(cr, uid, ids, employee_id, return_false, context=context)
|
||||
if employee_id:
|
||||
res = self.get_days(cr, uid, ids, employee_id, return_false, context=context)
|
||||
return res
|
||||
|
||||
_columns = {
|
||||
'name' : fields.char('Name', size=64, required=True, translate=True),
|
||||
'section_id': fields.many2one('crm.case.section', 'CRM Section', help='If you link this type of leave with a section in the CRM, it will synchronize each leave asked with a case in this section, to display it in the company shared calendar for example.'),
|
||||
'categ_id': fields.many2one('crm.case.categ', 'Meeting Category', domain="[('object_id.model', '=', 'crm.meeting')]", help='If you link this type of leave with a category in the CRM, it will synchronize each leave asked with a case in this category, to display it in the company shared calendar for example.'),
|
||||
'color_name' : fields.selection([('red', 'Red'), ('lightgreen', 'Light Green'), ('lightblue','Light Blue'), ('lightyellow', 'Light Yellow'), ('magenta', 'Magenta'),('lightcyan', 'Light Cyan'),('black', 'Black'),('lightpink', 'Light Pink'),('brown', 'Brown'),('violet', 'Violet'),('lightcoral', 'Light Coral'),('lightsalmon', 'Light Salmon'),('lavender', 'Lavender'),('wheat', 'Wheat'),('ivory', 'Ivory')],'Color of the status', required=True, help='This color will be used in the leaves summary located in Reporting\Print Summary of Leaves'),
|
||||
'limit' : fields.boolean('Allow to override Limit', help='If you thick this checkbox, the system will allow, for this section, the employees to take more leaves than the available ones.'),
|
||||
'active' : fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the leave type without removing it."),
|
||||
'active' : fields.boolean('Active', help="If the active field is set to false, it will allow you to hide the leave type without removing it."),
|
||||
'max_leaves' : fields.function(_user_left_days, method=True, string='Maximum Leaves Allowed', help='This value is given by the sum of all holidays requests with a positive value.', multi='user_left_days'),
|
||||
'leaves_taken' : fields.function(_user_left_days, method=True, string='Leaves Already Taken', help='This value is given by the sum of all holidays requests with a negative value.', multi='user_left_days'),
|
||||
'remaining_leaves' : fields.function(_user_left_days, method=True, string='Remaining Leaves', multi='user_left_days'),
|
||||
'remaining_leaves' : fields.function(_user_left_days, method=True, string='Remaining Leaves', help='Maximum Leaves Allowed - Leaves Already Taken', multi='user_left_days'),
|
||||
|
||||
}
|
||||
_defaults = {
|
||||
|
@ -86,48 +83,6 @@ class hr_holidays_status(osv.osv):
|
|||
}
|
||||
hr_holidays_status()
|
||||
|
||||
class hr_holidays_per_user(osv.osv):
|
||||
_name = "hr.holidays.per.user"
|
||||
_description = "Holidays Per User"
|
||||
_rec_name = "user_id"
|
||||
|
||||
def _get_remaining_leaves(self, cr, uid, ids, field_name, arg=None, context={}):
|
||||
obj_holiday = self.pool.get('hr.holidays')
|
||||
result = {}
|
||||
for holiday_user in self.browse(cr, uid, ids):
|
||||
days = 0.0
|
||||
ids_request = obj_holiday.search(cr, uid, [('employee_id', '=', holiday_user.employee_id.id),('state', '=', 'validate'),('holiday_status_id', '=', holiday_user.holiday_status.id)])
|
||||
if ids_request:
|
||||
holidays = obj_holiday.browse(cr, uid, ids_request)
|
||||
for holiday in holidays:
|
||||
days -= holiday.number_of_days
|
||||
days = holiday_user.max_leaves - days
|
||||
result[holiday_user.id] = days
|
||||
return result
|
||||
|
||||
_columns = {
|
||||
'employee_id': fields.many2one('hr.employee', "Employee's Name",required=True),
|
||||
'user_id' : fields.many2one('res.users','User'),
|
||||
'holiday_status' : fields.many2one("hr.holidays.status", "Holiday's Status", required=True),
|
||||
'max_leaves' : fields.float('Maximum Leaves Allowed',required=True),
|
||||
'leaves_taken' : fields.float('Leaves Already Taken',readonly=True),
|
||||
'active' : fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the holidays per user without removing it."),
|
||||
'notes' : fields.text('Notes'),
|
||||
'remaining_leaves': fields.function(_get_remaining_leaves, method=True, string='Remaining Leaves', type='float'),
|
||||
'holiday_ids': fields.one2many('hr.holidays', 'holiday_user_id', 'Holidays')
|
||||
}
|
||||
_defaults = {
|
||||
'active' : lambda *a: True,
|
||||
}
|
||||
|
||||
def create(self, cr, uid, vals, *args, **kwargs):
|
||||
if vals['employee_id']:
|
||||
obj_emp=self.pool.get('hr.employee').browse(cr,uid,vals['employee_id'])
|
||||
vals.update({'user_id': obj_emp.user_id.id})
|
||||
return super(osv.osv,self).create(cr, uid, vals, *args, **kwargs)
|
||||
|
||||
hr_holidays_per_user()
|
||||
|
||||
class hr_holidays(osv.osv):
|
||||
_name = "hr.holidays"
|
||||
_description = "Holidays"
|
||||
|
@ -152,13 +107,12 @@ class hr_holidays(osv.osv):
|
|||
'notes' : fields.text('Notes',readonly=True, states={'draft':[('readonly',False)]}),
|
||||
'number_of_days': fields.float('Number of Days', readonly=True, states={'draft':[('readonly',False)]}),
|
||||
'number_of_days_temp': fields.float('Number of Days', readonly=True, states={'draft':[('readonly',False)]}),
|
||||
'case_id': fields.many2one('crm.case', 'Case'),
|
||||
'case_id': fields.many2one('crm.meeting', 'Case'),
|
||||
'type': fields.selection([('remove','Leave Request'),('add','Allocation Request')], 'Request Type', required=True, readonly=True, states={'draft':[('readonly',False)]}, help="Choose 'Leave Request' if someone wants to take an off-day. \nChoose 'Allocation Request' if you want to increase the number of leaves available for someone"),
|
||||
'allocation_type': fields.selection([('employee','Employee Request'),('company','Company Allocation')], 'Allocation Type', required=True, readonly=True, states={'draft':[('readonly',False)]}, help='This field is only for informative purposes, to depict if the leave request/allocation comes from an employee or from the company'),
|
||||
'parent_id': fields.many2one('hr.holidays', 'Parent'),
|
||||
'linked_request_ids': fields.one2many('hr.holidays', 'parent_id', 'Linked Requests',),
|
||||
'holiday_user_id' : fields.many2one('hr.holidays.per.user', 'User'),
|
||||
'department_id':fields.many2one('hr.department','Department'),
|
||||
'department_id':fields.many2one('hr.department','Department', readonly=True, states={'draft':[('readonly',False)]} ),
|
||||
}
|
||||
|
||||
_defaults = {
|
||||
|
@ -170,6 +124,14 @@ class hr_holidays(osv.osv):
|
|||
}
|
||||
_order = 'date_from desc'
|
||||
|
||||
def create(self, cr, uid, vals, context={}):
|
||||
if context:
|
||||
if context.has_key('type'):
|
||||
vals['type'] = context['type']
|
||||
if context.has_key('allocation_type'):
|
||||
vals['allocation_type'] = context['allocation_type']
|
||||
return super(osv.osv,self).create(cr, uid, vals, context)
|
||||
|
||||
def onchange_date_from(self, cr, uid, ids, date_to, date_from):
|
||||
result = {}
|
||||
if date_to and date_from:
|
||||
|
@ -188,16 +150,14 @@ class hr_holidays(osv.osv):
|
|||
def _update_user_holidays(self, cr, uid, ids):
|
||||
for record in self.browse(cr, uid, ids):
|
||||
if record.state=='validate':
|
||||
holiday_id=self.pool.get('hr.holidays.per.user').search(cr, uid, [('employee_id','=', record.employee_id.id),('holiday_status','=',record.holiday_status_id.id)])
|
||||
if holiday_id:
|
||||
obj_holidays_per_user=self.pool.get('hr.holidays.per.user').browse(cr, uid,holiday_id[0])
|
||||
self.pool.get('hr.holidays.per.user').write(cr,uid,obj_holidays_per_user.id,{'leaves_taken':obj_holidays_per_user.leaves_taken - record.number_of_days})
|
||||
if record.case_id:
|
||||
if record.case_id.state <> 'draft':
|
||||
raise osv.except_osv(_('Warning !'),
|
||||
_('You can not cancel this holiday request. first You have to make its case in draft state.'))
|
||||
else:
|
||||
self.pool.get('crm.case').unlink(cr,uid,[record.case_id.id])
|
||||
self.pool.get('crm.meeting').unlink(cr,uid,[record.case_id.id])
|
||||
if record.linked_request_ids:
|
||||
list_ids = []
|
||||
for id in record.linked_request_ids:
|
||||
list_ids.append(id.id)
|
||||
self.holidays_cancel(cr,uid,list_ids)
|
||||
self.unlink(cr,uid,list_ids)
|
||||
|
||||
def _check_date(self, cr, uid, ids):
|
||||
if ids:
|
||||
|
@ -209,26 +169,11 @@ class hr_holidays(osv.osv):
|
|||
|
||||
_constraints = [(_check_date, 'Start date should not be larger than end date! ', ['number_of_days'])]
|
||||
|
||||
def create(self, cr, uid, vals, *args, **kwargs):
|
||||
id_holiday = super(hr_holidays, self).create(cr, uid, vals, *args, **kwargs)
|
||||
self._create_holiday(cr, uid, [id_holiday])
|
||||
return id_holiday
|
||||
|
||||
def unlink(self, cr, uid, ids, context={}):
|
||||
self._update_user_holidays(cr, uid, ids)
|
||||
return super(hr_holidays, self).unlink(cr, uid, ids, context)
|
||||
|
||||
def _create_holiday(self, cr, uid, ids):
|
||||
holidays_user_obj = self.pool.get('hr.holidays.per.user')
|
||||
holidays_data = self.browse(cr, uid, ids[0])
|
||||
list_holiday = []
|
||||
ids_user_hdays = holidays_user_obj.search(cr, uid, [('employee_id', '=', holidays_data.employee_id.id),('holiday_status', '=', holidays_data.holiday_status_id.id)])
|
||||
for hdays in holidays_user_obj.browse(cr, uid, ids_user_hdays):
|
||||
for req in hdays.holiday_ids:
|
||||
list_holiday.append(req.id)
|
||||
list_holiday.append(ids[0])
|
||||
holidays_user_obj.write(cr, uid, ids_user_hdays, {'holiday_ids': [(6, 0, list_holiday)]})
|
||||
return True
|
||||
|
||||
def onchange_date_to(self, cr, uid, ids, date_from, date_to):
|
||||
result = {}
|
||||
|
@ -249,7 +194,7 @@ class hr_holidays(osv.osv):
|
|||
warning = {}
|
||||
if status:
|
||||
brows_obj = self.pool.get('hr.holidays.status').browse(cr, uid, [status])[0]
|
||||
if brows_obj.section_id and not brows_obj.section_id.allow_unlink:
|
||||
if brows_obj.categ_id and brows_obj.categ_id.section_id and not brows_obj.categ_id.section_id.allow_unlink:
|
||||
warning = {
|
||||
'title': "Warning for ",
|
||||
'message': "You won\'t be able to cancel this leave request because the CRM Section of the leave type disallows."
|
||||
|
@ -283,6 +228,7 @@ class hr_holidays(osv.osv):
|
|||
|
||||
def holidays_confirm(self, cr, uid, ids, *args):
|
||||
for record in self.browse(cr, uid, ids):
|
||||
user_id = False
|
||||
leave_asked = record.number_of_days_temp
|
||||
if record.type == 'remove':
|
||||
if record.employee_id and not record.holiday_status_id.limit:
|
||||
|
@ -300,14 +246,14 @@ class hr_holidays(osv.osv):
|
|||
'number_of_days': nb,
|
||||
'user_id': user_id
|
||||
})
|
||||
vals= {
|
||||
'name':record.name,
|
||||
'date_from':record.date_from,
|
||||
'date_to':record.date_to,
|
||||
'calendar_id':record.employee_id.calendar_id.id,
|
||||
'company_id':record.employee_id.company_id.id,
|
||||
'resource_id':record.employee_id.resource_id.id
|
||||
}
|
||||
#vals= {
|
||||
# 'name':record.name,
|
||||
# 'date_from':record.date_from,
|
||||
# 'date_to':record.date_to,
|
||||
# 'calendar_id':record.employee_id.calendar_id.id,
|
||||
# 'company_id':record.employee_id.company_id.id,
|
||||
# 'resource_id':record.employee_id.resource_id.id
|
||||
# }
|
||||
#self.pool.get('resource.calendar.leaves').create(cr,uid,vals)
|
||||
|
||||
return True
|
||||
|
@ -365,14 +311,17 @@ class hr_holidays(osv.osv):
|
|||
employee_ids = self.pool.get('hr.employee').search(cr, uid, [])
|
||||
for employee in employee_ids:
|
||||
vals['employee_id'] = employee
|
||||
user_id = self.pool.get('hr.employee').search(cr, uid, [('user_id','=',uid)])
|
||||
if user_id:
|
||||
vals['user_id'] = user_id[0]
|
||||
holiday_ids.append(self.create(cr, uid, vals, context={}))
|
||||
self.holidays_confirm(cr, uid, holiday_ids)
|
||||
self.holidays_validate(cr, uid, holiday_ids)
|
||||
|
||||
if record.holiday_status_id.section_id and record.date_from and record.date_to and record.employee_id:
|
||||
if record.holiday_status_id.categ_id and record.date_from and record.date_to and record.employee_id:
|
||||
vals={}
|
||||
vals['name']=record.name
|
||||
vals['section_id']=record.holiday_status_id.section_id.id
|
||||
vals['categ_id']=record.holiday_status_id.categ_id.id
|
||||
epoch_c = time.mktime(time.strptime(record.date_to,'%Y-%m-%d %H:%M:%S'))
|
||||
epoch_d = time.mktime(time.strptime(record.date_from,'%Y-%m-%d %H:%M:%S'))
|
||||
diff_day = (epoch_c - epoch_d)/(3600*24)
|
||||
|
@ -380,7 +329,7 @@ class hr_holidays(osv.osv):
|
|||
vals['note'] = record.notes
|
||||
vals['user_id'] = record.user_id.id
|
||||
vals['date'] = record.date_from
|
||||
case_id = self.pool.get('crm.case').create(cr,uid,vals)
|
||||
case_id = self.pool.get('crm.meeting').create(cr,uid,vals)
|
||||
self.write(cr, uid, ids, {'case_id':case_id})
|
||||
return True
|
||||
hr_holidays()
|
||||
|
|
|
@ -9,6 +9,77 @@
|
|||
auto="False"
|
||||
menu="False"/>
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- available holidays report -->
|
||||
|
||||
<record id="view_report_hr_holiday_tree" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.report.tree</field>
|
||||
<field name="model">hr.holidays.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Available Holidays">
|
||||
<field name="employee_id"/>
|
||||
<field name="holiday_status_id"/>
|
||||
<field name="remaining_leave"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_report_hr_holiday_form" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.report.form</field>
|
||||
<field name="model">hr.holidays.report</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Available Holidays">
|
||||
<field name="employee_id" select="1"/>
|
||||
<field name="holiday_status_id" select="1"/>
|
||||
<field name="remaining_leave"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record id="view_report_hr_holiday_graph" model="ir.ui.view">
|
||||
<field name="name">hr.holiday.report.graph</field>
|
||||
<field name="model">hr.holidays.report</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph orientation="horizontal" string="Available Holidays" type="bar">
|
||||
<field name="holiday_status_id"/>
|
||||
<field name="remaining_leave" operator="+"/>
|
||||
<field group="True" name="employee_id"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_report_hr_holiday" model="ir.actions.act_window">
|
||||
<field name="name">Available Holidays</field>
|
||||
<field name="res_model">hr.holidays.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="view_id" ref="view_report_hr_holiday_tree"/>
|
||||
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_report_hr_holiday_tree">
|
||||
<field name="sequence" eval="1"/>
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="view_id" ref="view_report_hr_holiday_tree"/>
|
||||
<field name="act_window_id" ref="action_report_hr_holiday"/>
|
||||
</record>
|
||||
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_report_hr_holiday_graph">
|
||||
<field name="sequence" eval="2"/>
|
||||
<field name="view_mode">graph</field>
|
||||
<field name="view_id" ref="view_report_hr_holiday_graph"/>
|
||||
<field name="act_window_id" ref="action_report_hr_holiday"/>
|
||||
</record>
|
||||
|
||||
|
||||
<menuitem name="Available Holidays" id="menu_report_hr_holiday_tree" action="action_report_hr_holiday" parent="menu_hr_reporting_holidays"/>
|
||||
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
|
|
|
@ -11,10 +11,11 @@
|
|||
name="Holidays"
|
||||
parent="hr.menu_hr_reporting"
|
||||
sequence="3" />
|
||||
<wizard string="Print Summary of Holidays"
|
||||
<wizard string="Holidays by Departement"
|
||||
name="hr.holidays.summary"
|
||||
id="holidays_summary"/>
|
||||
<menuitem name="Print Summary of Holidays" parent="menu_hr_reporting_holidays"
|
||||
<menuitem name="Holidays by Departement" parent="menu_hr_reporting_holidays"
|
||||
icon="STOCK_PRINT"
|
||||
action="holidays_summary"
|
||||
type="wizard"
|
||||
id="menu_holidays_summary" sequence="20"/>
|
||||
|
@ -24,7 +25,7 @@
|
|||
<field eval="[(6,0,[ref('hr.group_hr_manager')])]" name="groups_id"/>
|
||||
</record>
|
||||
|
||||
<wizard string="Print Summary of Employee's Holidays"
|
||||
<wizard string="Employee's Holidays"
|
||||
model="hr.employee" name="hr.holidays.summary.employee"
|
||||
keyword="client_print_multi" id="wizard_holidays_summary" />
|
||||
</data>
|
||||
|
|
|
@ -1,13 +1,6 @@
|
|||
<?xml version="1.0" ?>
|
||||
<openerp>
|
||||
<data>
|
||||
<!--<menuitem
|
||||
id="menu_hr_reporting"
|
||||
name="Reporting"
|
||||
parent="hr.menu_hr_root"
|
||||
sequence="40" />-->
|
||||
<!-- Menu Items -->
|
||||
|
||||
<record id="view_hr_holidays_filter" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.filter</field>
|
||||
<field name="model">hr.holidays</field>
|
||||
|
@ -38,7 +31,6 @@
|
|||
|
||||
|
||||
<!-- Holidays: Leave Request -->
|
||||
|
||||
<record model="ir.ui.view" id="edit_holiday_new">
|
||||
<field name="name">Leave Request</field>
|
||||
<field name="model">hr.holidays</field>
|
||||
|
@ -73,7 +65,6 @@
|
|||
</record>
|
||||
|
||||
<!-- Holidays: Allocation Request -->
|
||||
|
||||
<record model="ir.ui.view" id="allocation_leave_new">
|
||||
<field name="name">Allocation Request</field>
|
||||
<field name="model">hr.holidays</field>
|
||||
|
@ -104,18 +95,17 @@
|
|||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Holidays: Company Allocation -->
|
||||
|
||||
<!-- Holidays: Leaves Management -->
|
||||
<record model="ir.ui.view" id="allocation_company_new">
|
||||
<field name="name">Company Allocation</field>
|
||||
<field name="name">Leaves Management</field>
|
||||
<field name="model">hr.holidays</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Company Allocation">
|
||||
<form string="Leaves Management">
|
||||
<field name="name" select="1"/>
|
||||
<field name="holiday_status_id" select="1"/>
|
||||
<field name="employee_id" select="1" />
|
||||
<field name="department_id"/>
|
||||
<!--<field name="department_id"/>-->
|
||||
<field name="type"/>
|
||||
<field name="date_from" select="1" on_change="onchange_date_from(date_to, date_from)" attrs="{'readonly':[('type','=','add')], 'required':[('type','=','remove')]}"/>
|
||||
<field name="date_to" select="1" on_change="onchange_date_to(date_from, date_to)" attrs="{'readonly':[('type','=','add')], 'required':[('type','=','remove')]}"/>
|
||||
|
@ -153,13 +143,13 @@
|
|||
<field name="date_to"/>
|
||||
<field name="holiday_status_id"/>
|
||||
<field name="state"/>
|
||||
<!-- <field name="type"/>-->
|
||||
<field name="type"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- My leave dashboard -->
|
||||
<record model="ir.ui.view" id="view_my_leave_board_form">
|
||||
<!-- <record model="ir.ui.view" id="view_my_leave_board_form">
|
||||
<field name="name">hr.holidays.per.user.form</field>
|
||||
<field name="model">hr.holidays.per.user</field>
|
||||
<field name="type">form</field>
|
||||
|
@ -175,33 +165,12 @@
|
|||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="view_my_leave_board_tree">
|
||||
<field name="name">hr.holidays.per.user.tree</field>
|
||||
<field name="model">hr.holidays.per.user</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="My Leaves" editable="top">
|
||||
<tree string="My Leaves" />
|
||||
<field name="employee_id"/>
|
||||
<field name="user_id"/>
|
||||
<field name="holiday_status"/>
|
||||
<field name="max_leaves"/>
|
||||
<field name="leaves_taken" />
|
||||
<field name="remaining_leaves"/>
|
||||
<field name="notes"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- <menuitem
|
||||
name="Holidays Management"
|
||||
parent="hr.menu_hr_root"
|
||||
id="menu_open_ask_holidays"/>-->
|
||||
<menuitem
|
||||
name="Leaves" sequence="7"
|
||||
-->
|
||||
<menuitem
|
||||
name="Holidays Management"
|
||||
parent="hr.menu_hr_root"
|
||||
id="menu_open_ask_holidays"/>
|
||||
|
||||
<record model="ir.actions.act_window" id="open_ask_holidays">
|
||||
<field name="name">Leave Request(s)</field>
|
||||
<field name="res_model">hr.holidays</field>
|
||||
|
@ -226,13 +195,8 @@
|
|||
</record>
|
||||
|
||||
|
||||
<!-- <menuitem
|
||||
name="Holidays Requests"
|
||||
parent="menu_open_ask_holidays"
|
||||
id="menu_open_ask_holidays_new"
|
||||
action="open_ask_holidays"/>-->
|
||||
<menuitem
|
||||
name="Leaves Requests"
|
||||
name="Leave Requests"
|
||||
parent="menu_open_ask_holidays"
|
||||
id="menu_open_ask_holidays_new"
|
||||
action="open_ask_holidays"/>
|
||||
|
@ -256,16 +220,32 @@
|
|||
<record model="ir.actions.act_window.view" id="action_open_allocation_holidays_form">
|
||||
<field name="sequence" eval="2"/>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="view_id" ref="allocation_company_new"/>
|
||||
<field name="view_id" ref="allocation_leave_new"/>
|
||||
<field name="act_window_id" ref="open_allocation_holidays"/>
|
||||
</record>
|
||||
|
||||
|
||||
<!-- <menuitem
|
||||
<menuitem
|
||||
name="Allocation Requests"
|
||||
parent="menu_open_ask_holidays"
|
||||
id="menu_open_allocation_holidays"
|
||||
action="open_allocation_holidays"/>-->
|
||||
action="open_allocation_holidays"/>
|
||||
|
||||
<record model="ir.actions.act_window" id="open_company_allocation">
|
||||
<field name="res_model">hr.holidays</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="allocation_company_new" />
|
||||
<field name="context">{'allocation_type':'company'}</field>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
name="Leaves Management"
|
||||
parent="menu_open_ask_holidays"
|
||||
id="menu_open_company_allocation"
|
||||
action="open_company_allocation"
|
||||
groups="hr.group_hr_manager"
|
||||
sequence="40"/>
|
||||
|
||||
<!-- holidays status -->
|
||||
<record model="ir.ui.view" id="edit_holiday_status_form">
|
||||
|
@ -276,7 +256,7 @@
|
|||
<form string="Leave Type">
|
||||
<field colspan="4" name="name" select="1"/>
|
||||
<field name="color_name" select="2"/>
|
||||
<field name="section_id" select="1" widget="selection"/>
|
||||
<field name="categ_id" select="1" widget="selection"/>
|
||||
<field name="limit" select="2"/>
|
||||
<field name="active" select="2"/>
|
||||
</form>
|
||||
|
@ -303,10 +283,6 @@
|
|||
</record>
|
||||
|
||||
<menuitem sequence="9" id="hr.menu_open_view_attendance_reason_config" parent="hr.menu_hr_configuration" name="Leaves"/>
|
||||
<!--<menuitem
|
||||
action="open_view_holiday_status"
|
||||
id="menu_open_view_holiday_status"
|
||||
parent="hr.menu_hr_configuration"/>-->
|
||||
<menuitem name="Leaves Statuses"
|
||||
action="open_view_holiday_status"
|
||||
id="menu_open_view_holiday_status"
|
||||
|
@ -320,18 +296,5 @@
|
|||
view_id ="eval('edit_holiday_new')"
|
||||
id="act_hr_employee_holiday_request"/>
|
||||
|
||||
<record model="ir.actions.act_window" id="action_holiday_per_user">
|
||||
<field name="name">Holiday Per User</field>
|
||||
<field name="res_model">hr.holidays.per.user</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="view_my_leave_board_tree"/>
|
||||
</record>
|
||||
|
||||
<menuitem name="Holiday Per User"
|
||||
action="action_holiday_per_user"
|
||||
id="menu_holiday_per_user"
|
||||
parent="hr.menu_open_view_attendance_reason_config"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
|
@ -20,5 +20,6 @@
|
|||
##############################################################################
|
||||
|
||||
import holidays_summary_report
|
||||
import available_holidays
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -0,0 +1,33 @@
|
|||
from osv import fields,osv
|
||||
import tools
|
||||
|
||||
class hr_holidays_report(osv.osv):
|
||||
_name = "hr.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),
|
||||
}
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'hr_holidays_report')
|
||||
cr.execute("""
|
||||
create or replace view hr_holidays_report as (
|
||||
select
|
||||
min(h.id) as id,
|
||||
h.employee_id as employee_id,
|
||||
h.holiday_status_id as holiday_status_id,
|
||||
sum(number_of_days) as remaining_leave
|
||||
from
|
||||
hr_holidays h
|
||||
left join hr_holidays_status s on (s.id = h.holiday_status_id)
|
||||
where h.state = 'validate'
|
||||
and h.employee_id is not null
|
||||
and s.active <> 'f'
|
||||
group by h.holiday_status_id, h.employee_id
|
||||
)""")
|
||||
hr_holidays_report()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
|
@ -44,7 +44,6 @@ def strToDate(dt):
|
|||
|
||||
def emp_create_xml(self,cr,uid,dept,holiday_type,row_id,empid,name,som,eom):
|
||||
display={}
|
||||
|
||||
if dept==0:
|
||||
count=0
|
||||
p_id=pooler.get_pool(cr.dbname).get('hr.holidays').search(cr,uid,[('employee_id','in',[empid,False]), ('type', '=', 'remove')])
|
||||
|
|
|
@ -0,0 +1,72 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import tools
|
||||
from osv import fields,osv
|
||||
|
||||
class hr_holidays_report(osv.osv):
|
||||
_name = "hr.holidays.report"
|
||||
_description = "Leaves Statistics"
|
||||
_auto = False
|
||||
_rec_name = 'date'
|
||||
_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),
|
||||
'date_from' : fields.datetime('Start Date', readonly=True),
|
||||
'date_to' : fields.datetime('End Date', readonly=True),
|
||||
'number_of_days_temp': fields.float('Number of Days', readonly=True),
|
||||
'employee_id' : fields.many2one('hr.employee', "Employee's Name",readonly=True),
|
||||
'user_id':fields.many2one('res.users', 'User', readonly=True),
|
||||
'state': fields.selection([('draft', 'Draft'),
|
||||
('confirm', 'Waiting Validation'),
|
||||
('refuse', 'Refused'),
|
||||
('validate', 'Validated'),
|
||||
('cancel', 'Cancelled')]
|
||||
,'State', readonly=True),
|
||||
}
|
||||
_order = 'date desc'
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'hr_holidays_report')
|
||||
cr.execute("""
|
||||
create or replace view hr_holidays_report as (
|
||||
select
|
||||
min(s.id) as id,
|
||||
date_trunc('seconds',s.create_date) as date,
|
||||
date_trunc('day',s.date_from) as date_from,
|
||||
date_trunc('day',s.date_to) as date_to,
|
||||
s.number_of_days_temp,
|
||||
s.employee_id,
|
||||
s.user_id as user_id,
|
||||
to_char(s.create_date, 'YYYY') as year,
|
||||
to_char(s.create_date, 'MM') as month,
|
||||
s.state
|
||||
from
|
||||
hr_holidays s
|
||||
group by
|
||||
s.create_date,s.state,s.date_from,s.date_to,
|
||||
s.number_of_days_temp,s.employee_id,s.user_id
|
||||
)
|
||||
""")
|
||||
hr_holidays_report()
|
||||
|
|
@ -0,0 +1,87 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<record id="view_hr_holidays_report_tree" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.report.tree</field>
|
||||
<field name="model">hr.holidays.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Leaves Statistics">
|
||||
<field name="date"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="date_from"/>
|
||||
<field name="date_to"/>
|
||||
<field name="number_of_days_temp"/>
|
||||
<field name="year" invisible="1"/>
|
||||
<field name="month" invisible="1"/>
|
||||
<field name="state"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_hr_holidays_report_graph" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.report.graph</field>
|
||||
<field name="model">hr.holidays.report</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Leaves Statistics" type="bar">
|
||||
<field name="employee_id"/>
|
||||
<field name="number_of_days_temp" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_hr_holidays_report_search" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.report.search</field>
|
||||
<field name="model">hr.holidays.report</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Leaves">
|
||||
<filter icon="terp-hr"
|
||||
string="This Year"
|
||||
domain="[('year','=',time.strftime('%%Y'))]"
|
||||
help="Leaves of the year"/>
|
||||
<filter icon="terp-hr"
|
||||
string="This Month"
|
||||
domain="[('month','=',time.strftime('%%m'))]"
|
||||
help="Leaves of this month"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Today's Start Leave"
|
||||
domain="[('date_from','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Today's End Leave"
|
||||
domain="[('date_to','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<filter icon="terp-sale"
|
||||
string="My Leaves"
|
||||
default="1"
|
||||
domain="[('user_id','=',uid)]"/>
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="12">
|
||||
<filter string="Employee" icon="terp-hr" context="{'group_by':'employee_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="State" icon="terp-hr" context="{'group_by':'state'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-sale" context="{'group_by':'date'}"/>
|
||||
<filter string="Year" icon="terp-sale" context="{'group_by':'year'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_hr_holidays_report_all" model="ir.actions.act_window">
|
||||
<field name="name">Leaves</field>
|
||||
<field name="res_model">hr.holidays.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="search_view_id" ref="view_hr_holidays_report_search"/>
|
||||
</record>
|
||||
|
||||
<menuitem action="action_hr_holidays_report_all" id="menu_hr_holidays_report_all" parent="hr.menu_hr_reporting" sequence="0"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
|
@ -1,4 +1,5 @@
|
|||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_holydays_status_user","hr.holidays.status user","model_hr_holidays_status","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_holidays_user","hr holidays user","model_hr_holidays","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_holidays_per_user","hr.holidays.per.user","model_hr_holidays_per_user","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_holydays_status_user","hr.holidays.status user","model_hr_holidays_status","hr.group_hr_user",1,0,0,0
|
||||
"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
|
||||
|
|
|
|
@ -42,10 +42,10 @@ system to store and search in your CV base.
|
|||
'hr_hr_wizard.xml',
|
||||
'hr_hr_view.xml',
|
||||
'hr_hr_menu.xml',
|
||||
'report_hr_hr_view.xml',
|
||||
'security/hr_hr_security.xml',
|
||||
'security/ir.model.access.csv',
|
||||
'board_hr_hr_statistical_view.xml',
|
||||
'report/hr_recruitment_report_view.xml'
|
||||
],
|
||||
'demo_xml': [
|
||||
'hr_hr_demo.xml'
|
||||
|
|
|
@ -20,6 +20,6 @@
|
|||
#
|
||||
##############################################################################
|
||||
|
||||
import report_hr_hr
|
||||
import hr_recruitment_report
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
|
@ -0,0 +1,67 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import tools
|
||||
from osv import fields,osv
|
||||
from hr_recruitment import hr_hr
|
||||
|
||||
class hr_recruitment_report(osv.osv):
|
||||
_name = "hr.recruitment.report"
|
||||
_description = "Recruitments Statistics"
|
||||
_inherit = "crm.case.report"
|
||||
_auto = False
|
||||
_rec_name = 'date'
|
||||
_columns = {
|
||||
'date': fields.datetime('Date', readonly=True),
|
||||
'job_id': fields.many2one('hr.job', 'Applied Job',readonly=True),
|
||||
'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('section_id','=',section_id),('object_id.model', '=', 'hr.applicant')]",readonly=True),
|
||||
'type_id': fields.many2one('crm.case.resource.type', 'Degree', domain="[('section_id','=',section_id),('object_id.model', '=', 'hr.applicant')]"),
|
||||
'department_id':fields.many2one('hr.department','Department',readonly=True),
|
||||
'priority': fields.selection(hr_hr.AVAILABLE_PRIORITIES, 'Appreciation'),
|
||||
|
||||
}
|
||||
_order = 'date desc'
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'hr_recruitment_report')
|
||||
cr.execute("""
|
||||
create or replace view hr_recruitment_report as (
|
||||
select
|
||||
min(s.id) as id,
|
||||
s.date as date,
|
||||
to_char(s.date, 'YYYY') as name,
|
||||
to_char(s.date, 'MM') as month,
|
||||
s.state,
|
||||
s.company_id,
|
||||
s.user_id,
|
||||
s.job_id,
|
||||
s.type_id,
|
||||
s.department_id,
|
||||
s.priority,
|
||||
s.stage_id,
|
||||
count(*) as nbr
|
||||
from hr_applicant s
|
||||
group by
|
||||
s.date,s.state,s.company_id,s.user_id,s.stage_id,s.type_id,s.priority,
|
||||
s.job_id,s.department_id
|
||||
)
|
||||
""")
|
||||
hr_recruitment_report()
|
||||
|
|
@ -0,0 +1,110 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<record id="view_hr_recruitment_report_tree" model="ir.ui.view">
|
||||
<field name="name">hr.recruitment.report.tree</field>
|
||||
<field name="model">hr.recruitment.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Recruitments Statistics">
|
||||
<field name="date"/>
|
||||
<field name="user_id"/>
|
||||
<field name="job_id"/>
|
||||
<field name="stage_id"/>
|
||||
<field name="department_id"/>
|
||||
<field name="type_id"/>
|
||||
<field name="company_id"/>
|
||||
<field name="state"/>
|
||||
<field name="name" invisible="1"/>
|
||||
<field name="month" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_hr_recruitment_report_graph" model="ir.ui.view">
|
||||
<field name="name">hr.recruitment.report.graph</field>
|
||||
<field name="model">hr.recruitment.report</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Recruitments Statistics" type="bar">
|
||||
<field name="job_id"/>
|
||||
<field name="nbr" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_hr_recruitment_report_search" model="ir.ui.view">
|
||||
<field name="name">hr.recruitment.report.search</field>
|
||||
<field name="model">hr.recruitment.report</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Recruitments">
|
||||
<filter icon="terp-hr"
|
||||
string="This Year"
|
||||
domain="[('year','=',time.strftime('%%Y'))]"
|
||||
help="Recruitments of the year"/>
|
||||
<filter icon="terp-hr"
|
||||
string="This Month"
|
||||
domain="[('month','=',time.strftime('%%m'))]"
|
||||
help="Recruitments of this month"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Current" icon="terp-hr" domain="[('state','in',('open','draft'))]"/>
|
||||
<filter string="Won" icon="terp-hr" domain="[('state','=','done')]"/>
|
||||
<filter string="Lost" icon="terp-hr" domain="[('state','=','cancel')]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="company_id" widget="selection"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<filter icon="terp-sale"
|
||||
string="My Recruitments"
|
||||
default="1"
|
||||
domain="[('user_id','=',uid)]"/>
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="1" string="Extended options..." colspan="10" col="12">
|
||||
<filter icon="terp-hr"
|
||||
string="Not Good"
|
||||
domain="[('priority','=','5')]"/>
|
||||
<filter icon="terp-hr"
|
||||
string="On Average"
|
||||
domain="[('priority','=','4')]"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Good"
|
||||
domain="[('priority','=','3')]"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Very Good"
|
||||
domain="[('priority','=','2')]"/>
|
||||
<filter icon="terp-hr"
|
||||
string="Excellent"
|
||||
domain="[('priority','=','1')]"/>
|
||||
</group>
|
||||
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="12">
|
||||
<filter string="User" icon="terp-hr" domain="[]" context="{'group_by':'user_id'}" default="1" />
|
||||
<filter string="Company" icon="terp-hr" domain="[]" context="{'group_by':'company_id'}"/>
|
||||
<filter string="Stage" icon="terp-hr" domain="[]" context="{'group_by':'stage_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="State" icon="terp-hr" domain="[]" context="{'group_by':'state'}"/>
|
||||
<filter string="Jobs" icon="terp-sale" domain="[]" context="{'group_by':'job_id'}"/>
|
||||
<filter string="Department" icon="terp-hr" domain="[]" context="{'group_by':'department_id'}"/>
|
||||
<filter string="Degree" icon="terp-hr" domain="[]" context="{'group_by':'type_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-hr" domain="[]" context="{'group_by':'month'}"/>
|
||||
<filter string="Year" icon="terp-hr" domain="[]" context="{'group_by':'name'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_hr_recruitment_report_all" model="ir.actions.act_window">
|
||||
<field name="name">Recruitments</field>
|
||||
<field name="res_model">hr.recruitment.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="search_view_id" ref="view_hr_recruitment_report_search"/>
|
||||
</record>
|
||||
<menuitem id="hr.menu_hr_reporting" name="Reporting" parent="hr.menu_hr_root"/>
|
||||
<menuitem action="action_hr_recruitment_report_all" id="menu_hr_recruitment_report_all" parent="hr.menu_hr_reporting" sequence="0"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
|
@ -1,3 +0,0 @@
|
|||
from osv import fields,osv
|
||||
import tools
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
</data>
|
||||
</openerp>
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
|
@ -36,7 +36,9 @@ reports, eso.""",
|
|||
'security/ir.model.access.csv',
|
||||
'hr_timesheet_invoice_view.xml',
|
||||
'hr_timesheet_invoice_wizard.xml',
|
||||
'hr_timesheet_invoice_report.xml'
|
||||
'hr_timesheet_invoice_report.xml',
|
||||
'report/report_analytic_view.xml',
|
||||
'report/hr_timesheet_invoice_report_view.xml',
|
||||
],
|
||||
'demo_xml': ['hr_timesheet_invoice_demo.xml'],
|
||||
'installable': True,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -15,12 +15,14 @@
|
|||
# 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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import cost_ledger
|
||||
import account_analytic_profit
|
||||
import report_analytic
|
||||
import hr_timesheet_invoice_report
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_timesheet_invoice_factor_hr_user","hr_timesheet_invoice.factor.hr.user","model_hr_timesheet_invoice_factor","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_timesheet_invoice_factor_acc_inv","hr_timesheet_invoice.factor.account.invoice","model_hr_timesheet_invoice_factor","account.group_account_invoice",1,1,1,1
|
||||
"access_report_analytic_account_close","report.analytic.account.close","model_report_analytic_account_close","account.group_account_manager",1,0,0,0
|
||||
"access_report_account_analytic_line_to_invoice","report.account.analytic.line.to.invoice","model_report_account_analytic_line_to_invoice","account.group_account_manager",1,0,0,0
|
||||
"access_report_timesheet_user","report_timesheet.user","model_report_timesheet_user","base.group_user",1,0,0,0
|
||||
"access_report_timesheet_account","report_timesheet.account","model_report_timesheet_account","base.group_user",1,0,0,0
|
||||
"access_report_timesheet_account_date","report_timesheet.account.date","model_report_timesheet_account_date","base.group_user",1,0,0,0
|
||||
"access_report_timesheet_invoice","report_timesheet.invoice","model_report_timesheet_invoice","base.group_user",1,0,0,0
|
||||
"access_report_random_timesheet","report_random_timesheet","model_report_random_timesheet","base.group_user",1,0,0,0
|
||||
"access_report_random_timesheet_lines","random_timesheet_lines","model_random_timesheet_lines","base.group_user",1,0,0,0
|
||||
|
|
|
|
@ -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: 2009-11-17 06:57+0000\n"
|
||||
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
|
||||
"PO-Revision-Date: 2010-03-16 13:31+0000\n"
|
||||
"Last-Translator: George Dumitrescu <Unknown>\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-03-11 04:54+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:34+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: idea
|
||||
|
@ -380,7 +380,7 @@ msgstr "Punctaj mediu"
|
|||
#. module: idea
|
||||
#: view:idea.idea:0
|
||||
msgid "Open"
|
||||
msgstr "Deschidere"
|
||||
msgstr "Deschide"
|
||||
|
||||
#. module: idea
|
||||
#: help:idea.idea,description:0
|
||||
|
|
|
@ -69,6 +69,8 @@
|
|||
'process/service_product_process.xml',
|
||||
'process/procurement_process.xml',
|
||||
'mrp_installer.xml',
|
||||
'report/mrp_report_view.xml',
|
||||
'report/mrp_production_order_view.xml',
|
||||
],
|
||||
'demo_xml': ['mrp_demo.xml', 'mrp_order_point.xml'],
|
||||
'installable': True,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
|
@ -23,6 +23,8 @@ import price
|
|||
import workcenter_load
|
||||
import order
|
||||
import bom_structure
|
||||
import mrp_report
|
||||
import mrp_production_order
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -0,0 +1,66 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
from osv import fields,osv
|
||||
import tools
|
||||
|
||||
|
||||
class mrp_production_order(osv.osv):
|
||||
_name = "mrp.production.order"
|
||||
_description = "Production Order Report"
|
||||
_auto = False
|
||||
_columns = {
|
||||
'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'),
|
||||
'location_src_id': fields.many2one('stock.location', 'Raw Materials Location', required=True),
|
||||
'location_dest_id': fields.many2one('stock.location', 'Finished Products Location', required=True),
|
||||
|
||||
|
||||
}
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'mrp_production_order')
|
||||
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
|
||||
)""")
|
||||
mrp_production_order()
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
@ -0,0 +1,115 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<!--
|
||||
Production Order Report
|
||||
-->
|
||||
|
||||
<record id="view_report_mrp_production_order_tree" model="ir.ui.view">
|
||||
<field name="name">mrp.production.order.tree</field>
|
||||
<field name="model">mrp.production.order</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Production">
|
||||
<field name="name" />
|
||||
<field name="month"/>
|
||||
<field name="product_id" />
|
||||
<field name="scheduled_date"/>
|
||||
<field name="reference" />
|
||||
<field name="origin"/>
|
||||
<field name="nbr" string="#Production Orders" />
|
||||
<field name="location_src_id"/>
|
||||
<field name="location_dest_id" />
|
||||
<field name="state" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record id="view_report_mrp_production_order_form" model="ir.ui.view">
|
||||
<field name="name">mrp.production.order.form</field>
|
||||
<field name="model">mrp.production.order</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Production">
|
||||
<field name="name" />
|
||||
<field name="month"/>
|
||||
<field name="product_id"/>
|
||||
<field name="scheduled_date"/>
|
||||
<field name="reference" />
|
||||
<field name="origin"/>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_report_mrp_production_order_graph" model="ir.ui.view">
|
||||
<field name="name">mrp.production.order.graph</field>
|
||||
<field name="model">mrp.production.order</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph orientation="horizontal" string="Production" type="bar">
|
||||
<field name="state"/>
|
||||
<field name="nbr" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_report_mrp_production_order_filter" model="ir.ui.view">
|
||||
<field name="name">mrp.production.order.select</field>
|
||||
<field name="model">mrp.production.order</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search">
|
||||
<group col="16" colspan="6">
|
||||
<filter string="This Year" icon="terp-hr" domain="[('name','=',time.localtime()[0])]" default="1" />
|
||||
<filter string="This Month" icon="terp-hr" domain="[('month','=',time.strftime('%%m'))]" default="1"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Current" icon="terp-hr" domain="[('state','in',('open','draft'))]"/>
|
||||
<filter string="Scheduled Date" icon="terp-hr" domain="[('scheduled_date',=,time.strftime('%%m/%%d/%%Y'))]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="reference" />
|
||||
<field name="origin"/>
|
||||
</group>
|
||||
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="4" col="6">
|
||||
<filter string="Source Location" icon="terp-sale" domain="[]" context="{'group_by':'location_src_id'}"/>
|
||||
<filter string="Destination Location" icon="terp-sale" domain="[]" context="{'group_by':'location_dest_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="State" icon="terp-sale" domain="[]" context="{'group_by':'state'}"/>
|
||||
<filter string="Product" icon="terp-sale" domain="[]" context="{'group_by':'product_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-sale" domain="[]" context="{'group_by':'month'}"/>
|
||||
<filter string="Year" icon="terp-sale" domain="[]" context="{'group_by':'name'}"/>
|
||||
|
||||
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
<record id="action_report_mrp_production_order" model="ir.actions.act_window">
|
||||
<field name="name">Production Order</field>
|
||||
<field name="res_model">mrp.production.order</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="view_id" ref="view_report_mrp_production_order_tree"/>
|
||||
<field name="search_view_id" ref="view_report_mrp_production_order_filter"/>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_report_mrp_production_order_tree">
|
||||
<field name="sequence" eval="1"/>
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="view_id" ref="view_report_mrp_production_order_tree"/>
|
||||
<field name="act_window_id" ref="action_report_mrp_production_order"/>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_report_mrp_production_order_graph">
|
||||
<field name="sequence" eval="2"/>
|
||||
<field name="view_mode">graph</field>
|
||||
<field name="view_id" ref="view_report_mrp_production_order_graph"/>
|
||||
<field name="act_window_id" ref="action_report_mrp_production_order"/>
|
||||
</record>
|
||||
|
||||
<menuitem name="Production" action="action_report_mrp_production_order" id="menu_report_mrp_production_orders_tree" parent="next_id_77"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
@ -98,7 +98,7 @@
|
|||
<field name="view_type">form</field>
|
||||
<field name="view_mode">graph,tree</field>
|
||||
</record>
|
||||
<menuitem action="action_report_in_out_picking_tree" id="menu_report_in_out_picking" parent="report_mrp.next_id_77"/>
|
||||
<menuitem action="action_report_in_out_picking_tree" id="menu_report_in_out_picking" parent="next_id_77"/>
|
||||
|
||||
|
||||
|
|
@ -32,3 +32,6 @@
|
|||
"access_mrp_production_stock_worker","mrp.production stock_worker","model_mrp_production","stock.group_stock_user",1,0,0,0
|
||||
"access_mrp_installer","mrp.installer","model_mrp_installer","mrp.group_mrp_user",1,0,0,0
|
||||
"access_mrp_product_produce","mrp.product.produce","model_mrp_product_produce","mrp.group_mrp_user",1,0,0,0
|
||||
"access_mrp_production_order","mrp.production.order","model_mrp_production_order","mrp.group_mrp_user",1,0,0,0
|
||||
"access_report_workcenter_load","report.workcenter.load","model_report_workcenter_load","mrp.group_mrp_manager",1,0,0,0
|
||||
"access_report_mrp_inout","report.mrp.inout","model_report_mrp_inout","mrp.group_mrp_manager",1,0,0,0
|
||||
|
|
|
|
@ -0,0 +1,89 @@
|
|||
# Finnish 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 <EMAIL@ADDRESS>, 2010.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2010-03-16 10:41+0000\n"
|
||||
"Last-Translator: smii <Unknown>\n"
|
||||
"Language-Team: Finnish <fi@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: constraint:ir.ui.view:0
|
||||
msgid "Invalid XML for View Architecture!"
|
||||
msgstr "Virheellinen XML näkymä-arkkitehtuurille!"
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: constraint:ir.model:0
|
||||
msgid ""
|
||||
"The Object name must start with x_ and not contain any special character !"
|
||||
msgstr "Objektin nimen tulee alkaa x_ ja se ei saa sisältää erikoismerkkejä!"
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: view:mrp.bom:0
|
||||
msgid "sub products"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: field:mrp.subproduct,product_id:0
|
||||
msgid "Product"
|
||||
msgstr "Tuote"
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: model:ir.model,name:mrp_subproduct.model_mrp_subproduct
|
||||
msgid "Mrp Sub Product"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: field:mrp.subproduct,subproduct_type:0
|
||||
msgid "Quantity Type"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: field:mrp.subproduct,product_qty:0
|
||||
msgid "Product Qty"
|
||||
msgstr "Tuotteen määrä"
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: field:mrp.subproduct,product_uom:0
|
||||
msgid "Product UOM"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: field:mrp.subproduct,bom_id:0
|
||||
msgid "BoM"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: view:mrp.bom:0
|
||||
msgid "Sub Products"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: selection:mrp.subproduct,subproduct_type:0
|
||||
msgid "Variable"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: field:mrp.bom,sub_products:0
|
||||
msgid "sub_products"
|
||||
msgstr ""
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: selection:mrp.subproduct,subproduct_type:0
|
||||
msgid "Fixed"
|
||||
msgstr "Ennalta määrätty"
|
||||
|
||||
#. module: mrp_subproduct
|
||||
#: model:ir.module.module,shortdesc:mrp_subproduct.module_meta_information
|
||||
msgid "MRP Sub Product"
|
||||
msgstr ""
|
|
@ -0,0 +1,192 @@
|
|||
# Finnish 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 <EMAIL@ADDRESS>, 2010.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-12-08 11:46+0000\n"
|
||||
"PO-Revision-Date: 2010-03-16 10:12+0000\n"
|
||||
"Last-Translator: smii <Unknown>\n"
|
||||
"Language-Team: Finnish <fi@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-03-18 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: multi_company
|
||||
#: help:multi_company.default,object_id:0
|
||||
msgid "Object affect by this rules"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:ir.model:0
|
||||
msgid ""
|
||||
"The Object name must start with x_ and not contain any special character !"
|
||||
msgstr "Objektin nimen tulee alkaa x_ ja se ei saa sisältää erikoismerkkejä!"
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:product.template:0
|
||||
msgid ""
|
||||
"Error: The default UOM and the purchase UOM must be in the same category."
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:res.partner:0
|
||||
msgid "The VAT doesn't seem to be correct."
|
||||
msgstr "ALV ei vaikuta olevan oikea."
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:ir.actions.act_window:0
|
||||
msgid "Invalid model name in the action definition."
|
||||
msgstr "Virheellinen mallin nimi toiminnon määrittelyssä."
|
||||
|
||||
#. module: multi_company
|
||||
#: model:res.company,overdue_msg:multi_company.res_company_odoo
|
||||
#: model:res.company,overdue_msg:multi_company.res_company_oerp_be
|
||||
#: model:res.company,overdue_msg:multi_company.res_company_oerp_editor
|
||||
#: model:res.company,overdue_msg:multi_company.res_company_oerp_in
|
||||
#: model:res.company,overdue_msg:multi_company.res_company_oerp_us
|
||||
msgid ""
|
||||
"Would your payment have been carried out after this mail was sent, please "
|
||||
"consider the present one as void. Do not hesitate to contact our accounting "
|
||||
"department"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: field:multi_company.default,company_dest_id:0
|
||||
msgid "Default Company"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: field:multi_company.default,object_id:0
|
||||
msgid "Object"
|
||||
msgstr "Objekti"
|
||||
|
||||
#. module: multi_company
|
||||
#: model:ir.module.module,shortdesc:multi_company.module_meta_information
|
||||
#: view:multi_company.default:0
|
||||
msgid "Multi Company"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: model:ir.module.module,description:multi_company.module_meta_information
|
||||
msgid ""
|
||||
"This module add the possibility to easily manage \n"
|
||||
" the default value for each object\n"
|
||||
" "
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: field:multi_company.default,company_id:0
|
||||
msgid "Main Company"
|
||||
msgstr "Pääyritys"
|
||||
|
||||
#. module: multi_company
|
||||
#: view:multi_company.default:0
|
||||
msgid "Condition"
|
||||
msgstr "Ehto"
|
||||
|
||||
#. module: multi_company
|
||||
#: help:multi_company.default,company_dest_id:0
|
||||
msgid "Company to store the current record"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:ir.ui.view:0
|
||||
msgid "Invalid XML for View Architecture!"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: field:multi_company.default,name:0
|
||||
msgid "Name"
|
||||
msgstr "Nimi"
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:product.template:0
|
||||
msgid "Error: UOS must be in a different category than the UOM"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: model:product.category,name:multi_company.Odoo1
|
||||
msgid "Odoo Offers"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:res.company:0
|
||||
msgid "Error! You can not create recursive companies."
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: help:multi_company.default,name:0
|
||||
msgid "Name it to easily find a record"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: model:ir.ui.menu,name:multi_company.menu_custom_multicompany
|
||||
msgid "Multi company"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: model:ir.model,name:multi_company.model_multi_company_default
|
||||
msgid "multi_company.default"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: help:multi_company.default,company_id:0
|
||||
msgid "Company where the user is connected"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: model:ir.actions.act_window,name:multi_company.action_inventory_form
|
||||
msgid "Default Company per Object"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: field:multi_company.default,expression:0
|
||||
msgid "Expression"
|
||||
msgstr "Ilmaus"
|
||||
|
||||
#. module: multi_company
|
||||
#: model:product.template,name:multi_company.product_product_odoo1_product_template
|
||||
msgid "Odoo Offer"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: field:multi_company.default,sequence:0
|
||||
msgid "Sequence"
|
||||
msgstr "Jakso"
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:product.category:0
|
||||
msgid "Error ! You can not create recursive categories."
|
||||
msgstr "Virhe! Et voi luoda rekursiivisia kategorioita."
|
||||
|
||||
#. module: multi_company
|
||||
#: constraint:product.product:0
|
||||
msgid "Error: Invalid ean code"
|
||||
msgstr "Virhe: Virheellinen EAN-koodi"
|
||||
|
||||
#. module: multi_company
|
||||
#: help:multi_company.default,expression:0
|
||||
msgid "Expression, must be True to match"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: model:ir.ui.menu,name:multi_company.menu_action_inventory_form
|
||||
msgid "Default company per Object"
|
||||
msgstr ""
|
||||
|
||||
#. module: multi_company
|
||||
#: code:addons/multi_company/multi_company.py:0
|
||||
#, python-format
|
||||
msgid " (copy)"
|
||||
msgstr " (kopio)"
|
||||
|
||||
#. module: multi_company
|
||||
#: view:multi_company.default:0
|
||||
msgid "Matching"
|
||||
msgstr "Vastaavuus"
|
|
@ -36,7 +36,7 @@ Main features :
|
|||
|
||||
""",
|
||||
'author': 'Tiny',
|
||||
'depends': ['sale', 'delivery','report_mrp'],
|
||||
'depends': ['sale', 'delivery'],
|
||||
# 'depends': ['sale', 'purchase', 'account', 'account_tax_include','board','mrp','board_manufacturing','delivery','profile_manufacturing','account','multi_company'],
|
||||
'init_xml': [
|
||||
'security/point_of_sale_security.xml',
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
<field eval="1" name="global"/>
|
||||
</record>
|
||||
<record id="point_of_sale.res_groups_posuser0" model="res.groups">
|
||||
<field eval="[(6,0,[ref('product.menu_config_product'),ref('product.menu_product_category_action_form'),ref('point_of_sale.menu_point_ofsale'),ref('point_of_sale.menu_point_config'),ref('point_of_sale.menu_statement_tree_all'),ref('stock.menu_stock_root'),ref('stock.menu_action_location_form'),ref('stock.menu_action_location_tree'),ref('stock.menu_picking_waiting'),ref('stock.menu_action_picking_tree3'),ref('stock.menu_action_picking_tree5'),ref('stock.menu_action_picking_form'),ref('stock.menu_action_picking_tree7'),ref('stock.menu_action_picking_tree8'),ref('stock.menu_action_picking_tree9'),ref('mrp.menu_mrp_procurement_action3'),ref('mrp.menu_mrp_procurement_new'),ref('report_mrp.next_id_77'),ref('report_mrp.menu_report_workcenter_load'),ref('report_mrp.menu_report_in_out_picking'),ref('base.menu_sales'),ref('sale.menu_action_shop_form'),ref('sale.menu_sale_order'),ref('sale.menu_action_order_tree'),ref('sale.menu_action_order_tree_all'),ref('sale.menu_action_order_tree2'),ref('sale.menu_action_order_tree3'),ref('sale.menu_action_order_tree7'),ref('sale.menu_action_order_tree8'),ref('sale.menu_action_order_line_tree1'),ref('delivery.menu_action_delivery_carrier_form'),ref('delivery.menu_action_delivery_grid_form'),ref('point_of_sale.menu_point_root')])]" name="menu_access"/>
|
||||
<field eval="[(6,0,[ref('product.menu_config_product'),ref('product.menu_product_category_action_form'),ref('point_of_sale.menu_point_ofsale'),ref('point_of_sale.menu_point_config'),ref('point_of_sale.menu_statement_tree_all'),ref('stock.menu_stock_root'),ref('stock.menu_action_location_form'),ref('stock.menu_action_location_tree'),ref('stock.menu_picking_waiting'),ref('stock.menu_action_picking_tree3'),ref('stock.menu_action_picking_tree5'),ref('stock.menu_action_picking_form'),ref('stock.menu_action_picking_tree7'),ref('stock.menu_action_picking_tree8'),ref('stock.menu_action_picking_tree9'),ref('mrp.menu_mrp_procurement_action3'),ref('mrp.menu_mrp_procurement_new'),ref('mrp.next_id_77'),ref('mrp.menu_report_workcenter_load'),ref('mrp.menu_report_in_out_picking'),ref('base.menu_sales'),ref('sale.menu_action_shop_form'),ref('sale.menu_sale_order'),ref('sale.menu_action_order_tree'),ref('sale.menu_action_order_tree_all'),ref('sale.menu_action_order_tree2'),ref('sale.menu_action_order_tree3'),ref('sale.menu_action_order_tree7'),ref('sale.menu_action_order_tree8'),ref('sale.menu_action_order_line_tree1'),ref('delivery.menu_action_delivery_carrier_form'),ref('delivery.menu_action_delivery_grid_form'),ref('point_of_sale.menu_point_root')])]" name="menu_access"/>
|
||||
<field eval="[(6,0,[ref('ir_rule_group_bankstatementcompany0'),ref('ir_rule_group_bankstatementlinecompany0'),ref('point_of_sale.ir_rule_group_point0'),ref('point_of_sale.ir_rule_group_poslinecompany0'),ref('point_of_sale.ir_rule_group_posreporting0')])]" name="rule_groups"/>
|
||||
<field eval=""""POS_user"""" name="name"/>
|
||||
</record>
|
||||
|
|
|
@ -104,6 +104,7 @@
|
|||
<field name="name"/>
|
||||
<field name="type"/>
|
||||
<field name="currency_id"/>
|
||||
<field name="active" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
@ -344,8 +344,8 @@
|
|||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Packaging">
|
||||
<field name="name"/>
|
||||
<field name="type"/>
|
||||
<field name="name" select="1" />
|
||||
<field name="type" select="1" />
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
@ -40,6 +40,7 @@ works done on tasks, eso. It is able to render planning, order tasks, eso.
|
|||
"project_report.xml",
|
||||
"process/task_process.xml",
|
||||
"project_installer.xml",
|
||||
"report/project_report_view.xml"
|
||||
],
|
||||
'demo_xml': [
|
||||
'project_demo.xml'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -15,9 +15,9 @@
|
|||
# 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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import project_report
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -29,14 +29,23 @@ 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'),
|
||||
'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),
|
||||
'task_closed': fields.integer('Task Closed', readonly=True),
|
||||
'nbr': fields.integer('#Number of tasks', 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', 'In Progress'),
|
||||
('pending', 'Pending'),
|
||||
('cancelled', 'Cancelled'),
|
||||
('done', 'Done')],
|
||||
'State', readonly=True),
|
||||
|
||||
}
|
||||
_order = 'name desc, project_id'
|
||||
|
@ -46,70 +55,30 @@ class report_project_task_user(osv.osv):
|
|||
create or replace view report_project_task_user as (
|
||||
select
|
||||
min(t.id) as id,
|
||||
to_char(date_end, 'YYYY') as name,
|
||||
to_char(date_end, 'MM') as month,
|
||||
count(distinct t.id) as task_closed,
|
||||
to_char(date_start, 'YYYY') as name,
|
||||
to_char(date_start, 'MM') as month,
|
||||
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,
|
||||
t.user_id,
|
||||
t.project_id,
|
||||
t.state,
|
||||
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,
|
||||
((sum(planned_hours)-sum(w.hours))/count(distinct t.id))::decimal(16,2) as hours_delay
|
||||
from project_task t
|
||||
left join project_task_work w on (t.id=w.task_id)
|
||||
where
|
||||
t.state='done'
|
||||
group by
|
||||
to_char(date_end, 'YYYY'),to_char(date_end, 'MM'),t.user_id,project_id
|
||||
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.project_id
|
||||
)
|
||||
""")
|
||||
report_project_task_user()
|
||||
|
||||
|
||||
class report_project_task(osv.osv):
|
||||
_name = "report.project.task"
|
||||
_description = "Tasks by project"
|
||||
_auto = False
|
||||
_columns = {
|
||||
'name': fields.char('Year',size=64,required=False, 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),
|
||||
'task_closed': fields.integer('Task Closed', 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 = 'name desc, project_id'
|
||||
def init(self, cr):
|
||||
tools.sql.drop_view_if_exists(cr, 'report_project_task')
|
||||
cr.execute("""
|
||||
create or replace view report_project_task as (
|
||||
select
|
||||
min(t.id) as id,
|
||||
to_char(date_end, 'YYYY') as name,
|
||||
to_char(date_end, 'MM') as month,
|
||||
count(distinct t.id) as task_closed,
|
||||
t.project_id,
|
||||
sum(planned_hours) as hours_planned,
|
||||
to_char(avg(date_end::abstime-t.create_date::timestamp), 'DD"d" HH12:MI:SS') as closing_days,
|
||||
sum(w.hours) as hours_effective,
|
||||
((sum(planned_hours)-sum(w.hours))/count(distinct t.id))::decimal(16,2) as hours_delay
|
||||
from project_task t
|
||||
left join project_task_work w on (t.id=w.task_id)
|
||||
where
|
||||
t.state='done'
|
||||
group by
|
||||
to_char(date_end, 'YYYY'),to_char(date_end, 'MM'),project_id
|
||||
)
|
||||
""")
|
||||
report_project_task()
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
@ -0,0 +1,73 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<menuitem id="base.menu_project_report" name="Reporting" parent="base.menu_main_pm" sequence="50"/>
|
||||
|
||||
<record id="view_task_project_user_tree" model="ir.ui.view">
|
||||
<field name="name">report.project.task.user.tree</field>
|
||||
<field name="model">report.project.task.user</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Tasks">
|
||||
<field name="name" invisible="1"/>
|
||||
<field name="month" invisible="1"/>
|
||||
<field name="user_id"/>
|
||||
<field name="project_id"/>
|
||||
<field name="nbr"/>
|
||||
<field name="date_start" invisible="1"/>
|
||||
<field name="date_end" invisible="1"/>
|
||||
<field name="date_deadline" invisible="1"/>
|
||||
<field name="hours_planned"/>
|
||||
<field name="hours_effective"/>
|
||||
<field name="hours_delay"/>
|
||||
<field name="closing_days"/>
|
||||
<field name="state"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_task_project_user_search" model="ir.ui.view">
|
||||
<field name="name">report.project.task.user.search</field>
|
||||
<field name="model">report.project.task.user</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Tasks">
|
||||
<group col="10" colspan="4">
|
||||
<filter icon="terp-project" string="This Year" domain="[('name','=',time.strftime('%%Y'))]" help="Tasks performed in this year"/>
|
||||
<filter icon="terp-project" string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Tasks performed in this month"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Start" icon="terp-project" domain="[('date_start','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<filter string="End" icon="terp-project" domain="[('date_end','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<filter string="Deadline" icon="terp-project" domain="[('date_deadline','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<filter string="Closed" icon="terp-project" domain="[('state','=','done')]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="project_id" select="1"/>
|
||||
<field name="user_id" select="1" widget="selection">
|
||||
<filter icon="terp-project" string="My Task" domain="[('user_id','=',uid)]" default="1"/>
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="11">
|
||||
<filter string="User" icon="terp-project" context="{'group_by':'user_id'}" />
|
||||
<filter string="Project" icon="terp-project" context="{'group_by':'project_id'}" />
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="State" icon="terp-project" context="{'group_by':'state'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-project" context="{'group_by':'month'}"/>
|
||||
<filter string="Year" icon="terp-project" context="{'group_by':'name'}"/>
|
||||
</group>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_project_task_user_tree" model="ir.actions.act_window">
|
||||
<field name="name">Tasks</field>
|
||||
<field name="res_model">report.project.task.user</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="search_view_id" ref="view_task_project_user_search"/>
|
||||
</record>
|
||||
<menuitem action="action_project_task_user_tree" id="menu_project_task_user_tree" parent="base.menu_project_report"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
|
@ -12,4 +12,5 @@
|
|||
"access_config_compute_remaining","project.config.compute.remaining","model_config_compute_remaining","project.group_project_user",1,1,1,1
|
||||
"access_config_compute_remaining_manager","project.config.compute.remaining.manager","model_config_compute_remaining","project.group_project_manager",1,1,1,1
|
||||
"access_project_message","project.message","model_project_message","project.group_project_user",1,0,0,0
|
||||
"access_project_installer","project.installer","model_project_installer","project.group_project_user",1,0,0,0
|
||||
"access_project_installer","project.installer","model_project_installer","project.group_project_user",1,0,0,0
|
||||
"access_report_project_task_user","report.project.task.user","model_report_project_task_user","project.group_project_manager",1,0,0,0
|
||||
|
|
|
|
@ -1,15 +1,21 @@
|
|||
from osv import fields,osv
|
||||
import tools
|
||||
from crm import crm
|
||||
|
||||
class project_issue_report(osv.osv):
|
||||
_name = "project.issue.report"
|
||||
_name = "project.issue.report"
|
||||
_auto = False
|
||||
_inherit = "crm.case.report"
|
||||
_columns = {
|
||||
'categ_id': fields.many2one('crm.case.categ', 'Category', domain="[('section_id','=',section_id),('object_id.model', '=', 'project.issue.report')]"),
|
||||
'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('object_id.model', '=', 'project.issue.report')]"),
|
||||
'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('object_id.model', '=', 'project.issue.report')]"),
|
||||
'nbr': fields.integer('# of Issues', reaadonly=True),
|
||||
'delay_close': fields.char('Delay to close', size=20, readonly=True),
|
||||
'company_id' : fields.many2one('res.company', 'Company'),
|
||||
'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'),
|
||||
'project_id':fields.many2one('project.project', 'Project'),
|
||||
'type_id': fields.many2one('crm.case.resource.type', 'Bug Type', domain="[('object_id.model', '=', 'project.issue')]"),
|
||||
'date_closed': fields.datetime('Close Date', readonly=True),
|
||||
}
|
||||
def init(self, cr):
|
||||
tools.drop_view_if_exists(cr, 'project_issue_report')
|
||||
|
@ -24,11 +30,19 @@ class project_issue_report(osv.osv):
|
|||
c.section_id,
|
||||
c.categ_id,
|
||||
c.stage_id,
|
||||
to_char(c.date_closed, 'YYYY/mm/dd') as date_closed,
|
||||
u.company_id as company_id,
|
||||
c.priority as priority,
|
||||
c.project_id as project_id,
|
||||
c.type_id as type_id,
|
||||
count(*) as nbr,
|
||||
to_char(avg(date_closed-c.create_date), 'DD"d" HH24:MI:SS') as delay_close
|
||||
from
|
||||
project_issue c
|
||||
left join
|
||||
res_users u on (c.id = u.id)
|
||||
group by to_char(c.create_date, 'YYYY'), to_char(c.create_date, 'MM'), c.state, c.user_id,c.section_id,c.categ_id,c.stage_id
|
||||
,c.date_closed,u.company_id,c.priority,c.project_id,c.type_id
|
||||
)""")
|
||||
|
||||
|
||||
|
|
|
@ -1,9 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<!--
|
||||
Project Bug
|
||||
-->
|
||||
<!-- Report for project issue -->
|
||||
<record id="view_project_issue_report_tree" model="ir.ui.view">
|
||||
<field name="name">project.issue.report.tree</field>
|
||||
<field name="model">project.issue.report</field>
|
||||
|
@ -12,19 +10,22 @@
|
|||
<tree string="Project Issue">
|
||||
<field name="name" />
|
||||
<field name="month"/>
|
||||
<field name="priority" />
|
||||
<field name="stage_id" />
|
||||
<field name="type_id" string="Type"/>
|
||||
<field name="project_id" invisible="1"/>
|
||||
<field name="company_id" invisible="1"/>
|
||||
<field name="nbr" string="#Project Issue"/>
|
||||
<field name="amount_revenue"/>
|
||||
<field name="probability"/>
|
||||
<field name="amount_revenue_prob" widget="progress"/>
|
||||
<field name="delay_close"/>
|
||||
<field name="state" invisible="1"/>
|
||||
<field name="section_id" invisible="1"/>
|
||||
<field name="user_id" invisible="1"/>
|
||||
<field name="stage_id" invisible="1"/>
|
||||
<field name="categ_id" invisible="1"/>
|
||||
<field name="date_closed" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
</record>
|
||||
<record id="view_project_issue_report_graph" model="ir.ui.view">
|
||||
<field name="name">project.issue.report.graph</field>
|
||||
<field name="model">project.issue.report</field>
|
||||
|
@ -43,22 +44,64 @@
|
|||
<field name="inherit_id" ref="crm.view_crm_case_filter"/>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr='//search[@string="Search"]/group[@string="Group By..."]/filter[@string="State"]' position='after'>
|
||||
<filter string="Stage" icon="terp-sale" domain="[]" context="{'group_by':'stage_id'}"/>
|
||||
<data>
|
||||
<xpath expr='//search[@string="Search"]/group[1]/filter[@string="This Year"]' position='replace'>
|
||||
<filter string="This Year" icon="terp-sale" domain="[('name','=',time.strftime('%%Y'))]"/>
|
||||
</xpath>
|
||||
<xpath expr='//search[@string="Search"]/group[1]/filter[@string="This Month"]' position='replace'>
|
||||
<filter string="This Month" icon="terp-sale" domain="[('month','=',time.strftime('%%m'))]" />
|
||||
</xpath>
|
||||
<xpath expr='//search[@string="Search"]/group[1]/filter[@string="Lost"]' position='after'>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Closed Today" icon="terp-sale" domain="[('date_closed','=',time.strftime('%%Y/%%m/%%d'))]" />
|
||||
</xpath>
|
||||
<xpath expr='//search[@string="Search"]/group[1]/field[3]' position='after'>
|
||||
<field name="project_id" widget="selection"/>
|
||||
</xpath>
|
||||
<xpath expr='//search[@string="Search"]/group[@string="Group By..."]' position='before'>
|
||||
<newline/>
|
||||
<group expand="1" string="Extended options..." colspan="10" col="12">
|
||||
<filter icon="terp-sale"
|
||||
string="Highest"
|
||||
domain="[('priority','=','1')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="High"
|
||||
domain="[('priority','=','2')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="Normal"
|
||||
domain="[('priority','=','3')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="Low"
|
||||
domain="[('priority','=','4')]"/>
|
||||
<filter icon="terp-sale"
|
||||
string="Lowest"
|
||||
domain="[('priority','=','5')]"/>
|
||||
</group>
|
||||
<newline/>
|
||||
</xpath>
|
||||
<xpath expr='//search[@string="Search"]/group[@string="Group By..."]/filter[@string="Company"]' position='replace'>
|
||||
<filter string="Company" icon="terp-sale" domain="[]" context="{'group_by':'company_id'}"/>
|
||||
</xpath>
|
||||
<xpath expr='//search[@string="Search"]/group[@string="Group By..."]/filter[@string="Category"]' position='after'>
|
||||
<filter string="Stage" icon="terp-sale" domain="[]" context="{'group_by':'stage_id'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Project" icon="terp-sale" domain="[]" context="{'group_by':'project_id'}"/>
|
||||
<filter string="Type" icon="terp-sale" domain="[]" context="{'group_by':'type_id'}"/>
|
||||
</xpath>
|
||||
</data>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_project_issue_report" model="ir.actions.act_window">
|
||||
<field name="name">Project Issue Report</field>
|
||||
<field name="name">Project Issue</field>
|
||||
<field name="res_model">project.issue.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">graph,tree</field>
|
||||
<field name="view_id" ref="view_project_issue_report_tree"/>
|
||||
<field name="search_view_id" ref="view_project_issue_report_filter"/>
|
||||
</record>
|
||||
|
||||
|
||||
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_project_issue_report_tree">
|
||||
<field name="sequence" eval="1"/>
|
||||
<field name="view_mode">tree</field>
|
||||
|
@ -70,9 +113,9 @@
|
|||
<field name="view_mode">graph</field>
|
||||
<field name="view_id" ref="view_project_issue_report_graph"/>
|
||||
<field name="act_window_id" ref="action_project_issue_report"/>
|
||||
</record>
|
||||
</record>
|
||||
<menuitem icon="terp-project" id="base.menu_main_pm" name="Project Management" sequence="1"/>
|
||||
<menuitem id="base.menu_project_report" name="Reporting" parent="base.menu_main_pm" sequence="50"/>
|
||||
<menuitem id="base.menu_project_report" name="Reporting" parent="base.menu_main_pm" sequence="50"/>
|
||||
<menuitem action="action_project_issue_report" id="menu_project_issue_report_tree" parent="base.menu_project_report"/>
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -15,9 +15,10 @@
|
|||
# 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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
import project_timesheet
|
||||
import report
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
'website': 'http://www.openerp.com',
|
||||
'depends': ['base', 'project', 'hr_timesheet_sheet'],
|
||||
'init_xml': [],
|
||||
'update_xml': ["process/project_timesheet_process.xml"],
|
||||
'update_xml': ["process/project_timesheet_process.xml", "report/task_report_view.xml"],
|
||||
'demo_xml': [],
|
||||
'installable': True,
|
||||
'active': False,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
|
@ -15,10 +15,9 @@
|
|||
# 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 <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
|
||||
import task_report
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
@ -0,0 +1,159 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# 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 <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
from osv import fields,osv
|
||||
import mx.DateTime
|
||||
import tools
|
||||
|
||||
#class task_report(osv.osv):
|
||||
# _name = "task.report"
|
||||
# _description = "Project task report"
|
||||
# _auto = False
|
||||
# _columns = {
|
||||
# 'name': fields.char('Task',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),
|
||||
# 'user_id':fields.many2one('res.users', 'User', readonly=True),
|
||||
# 'task_nbr': fields.float('Task Number', readonly=True),
|
||||
# 'task_hrs': fields.float('Task Hours', readonly=True),
|
||||
# 'task_progress': fields.float('Task Progress', readonly=True),
|
||||
# 'company_id' : fields.many2one('res.company', 'Company'),
|
||||
# 'task_state': fields.selection([('draft', 'Draft'),('open', 'Open'),('pending', 'Pending'), ('cancelled', 'Cancelled'), ('done', 'Done'),('no','No Task')], 'Status', readonly=True),
|
||||
# 'project_id':fields.many2one('project.project', 'Project'),
|
||||
# 'year': fields.char('Year',size=64,required=False, readonly=True),
|
||||
# 'date_start': fields.datetime('Starting Date',readonly=True),
|
||||
# 'date_end': fields.datetime('Ending Date',readonly=True),
|
||||
# 'date_deadline': fields.date('Deadline',readonly=True),
|
||||
# 'type': fields.many2one('project.task.type', 'Stage'),
|
||||
# 'priority' : fields.selection([('4','Very Low'), ('3','Low'), ('2','Medium'), ('1','Urgent'), ('0','Very urgent')], 'Importance'),
|
||||
# 'assign_to': fields.many2one('res.users', 'Assigned to', readonly=True),
|
||||
# 'remaining_hrs': fields.float('Remaining Hours', readonly=True),
|
||||
# }
|
||||
#
|
||||
# def init(self, cr):
|
||||
# tools.sql.drop_view_if_exists(cr, 'task_report')
|
||||
# cr.execute('''
|
||||
# create or replace view task_report as (
|
||||
# select
|
||||
# min(t.id) as id,
|
||||
# to_char(t.create_date, 'YYYY') as year,
|
||||
# to_char(t.create_date,'MM') as month,
|
||||
# u.id as user_id,
|
||||
# u.company_id as company_id,
|
||||
# t.name as name,
|
||||
# t.project_id as project_id,
|
||||
# to_char(t.date_start,'YYYY/mm/dd') as date_start,
|
||||
# to_char(t.date_end,'YYYY/mm/dd') as date_end,
|
||||
# to_char(t.date_deadline,'YYYY/mm/dd') as date_deadline,
|
||||
# t.type as type,
|
||||
# t.priority as priority,
|
||||
# t.user_id as assign_to,
|
||||
# t.remaining_hours as remaining_hrs,
|
||||
# count(t.*) as task_nbr,
|
||||
# sum(t.planned_hours) as task_hrs,
|
||||
# sum(t.planned_hours * (100 - t.progress) / 100) as task_progress,
|
||||
# case when t.state is null then 'no' else t.state end as task_state
|
||||
# from
|
||||
# res_users u
|
||||
# left join
|
||||
# project_task t on (u.id = t.user_id)
|
||||
# where
|
||||
# u.active
|
||||
# group by
|
||||
# to_char(t.create_date, 'YYYY'),to_char(t.create_date,'MM'),u.id, u.company_id, t.state
|
||||
# ,t.name,t.project_id,t.type,t.priority,
|
||||
# t.user_id,t.remaining_hours,to_char(t.date_start,'YYYY/mm/dd'),to_char(t.date_end,'YYYY/mm/dd'),to_char(t.date_deadline,'YYYY/mm/dd')
|
||||
# )
|
||||
# ''')
|
||||
#task_report()
|
||||
|
||||
class report_timesheet_task_user(osv.osv):
|
||||
_name = "report.timesheet.task.user"
|
||||
_auto = False
|
||||
_order = "name"
|
||||
|
||||
def _get_task_hours(self, cr, uid, ids, name,args,context):
|
||||
result = {}
|
||||
for record in self.browse(cr, uid, ids,context):
|
||||
last_date = mx.DateTime.strptime(record.name, '%Y-%m-%d') + mx.DateTime.RelativeDateTime(months=1) - 1
|
||||
task_obj=self.pool.get('project.task.work')
|
||||
task_ids = task_obj.search(cr,uid,[('user_id','=',record.user_id.id),('date','>=',record.name),('date','<=',last_date.strftime('%Y-%m-%d'))])
|
||||
tsk_hrs = task_obj.read(cr,uid,task_ids,['hours','date','user_id'])
|
||||
total = 0.0
|
||||
for hrs in tsk_hrs:
|
||||
total += hrs['hours']
|
||||
result[record.id] = total
|
||||
return result
|
||||
|
||||
def get_hrs_timesheet(self, cr, uid, ids, name,args,context):
|
||||
result = {}
|
||||
sum = 0.0
|
||||
for record in self.browse(cr, uid, ids, context):
|
||||
last_date = mx.DateTime.strptime(record.name, '%Y-%m-%d') + mx.DateTime.RelativeDateTime(months=1) - 1
|
||||
obj=self.pool.get('hr_timesheet_sheet.sheet.day')
|
||||
sheet_ids = obj.search(cr,uid,[('sheet_id.user_id','=',record.user_id.id),('name','>=',record.name),('name','<=',last_date.strftime('%Y-%m-%d'))])
|
||||
data_days = obj.read(cr,uid,sheet_ids,['name','sheet_id.user_id','total_attendance'])
|
||||
total = 0.0
|
||||
for day_attendance in data_days:
|
||||
total += day_attendance['total_attendance']
|
||||
result[record.id] = total
|
||||
return result
|
||||
|
||||
_columns = {
|
||||
'name': fields.char('Name',size=64),
|
||||
'year': 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),
|
||||
'user_id': fields.many2one('res.users', 'User',readonly=True),
|
||||
'timesheet_hrs': fields.function(get_hrs_timesheet, method=True, string="Timesheet Hours"),
|
||||
'task_hrs': fields.function(_get_task_hours, method=True, string="Task Hours"),
|
||||
|
||||
}
|
||||
|
||||
|
||||
def init(self, cr):
|
||||
cr.execute(""" create or replace view report_timesheet_task_user as (
|
||||
select
|
||||
((r.id*12)+to_number(months.m_id,'99'))::integer as id,
|
||||
months.name as name,
|
||||
r.id as user_id,
|
||||
to_char(to_date(months.name, 'YYYY/MM/DD'),'YYYY') as year,
|
||||
to_char(to_date(months.name, 'YYYY/MM/DD'),'MM') as month
|
||||
from res_users r,
|
||||
(select to_char(p.date,'YYYY-MM-01') as name,
|
||||
to_char(p.date,'MM') as m_id
|
||||
from project_task_work p
|
||||
|
||||
union
|
||||
select to_char(h.name,'YYYY-MM-01') as name,
|
||||
to_char(h.name,'MM') as m_id
|
||||
from hr_timesheet_sheet_sheet_day h) as months
|
||||
|
||||
group by
|
||||
r.id,months.m_id,months.name,
|
||||
to_char(to_date(months.name, 'YYYY/MM/DD'),'YYYY') ,
|
||||
to_char(to_date(months.name, 'YYYY/MM/DD'),'MM')
|
||||
) """)
|
||||
|
||||
report_timesheet_task_user()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
@ -0,0 +1,182 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<menuitem
|
||||
id="hr.menu_hr_reporting"
|
||||
name="Reporting"
|
||||
parent="hr.menu_hr_root"
|
||||
sequence="40" />
|
||||
|
||||
<!-- Tasks by projects and users
|
||||
|
||||
|
||||
<record id="view_task_project_form" model="ir.ui.view">
|
||||
<field name="name">task.report.form</field>
|
||||
<field name="model">task.report</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Tasks by User">
|
||||
<field name="user_id" select="1"/>
|
||||
<field name="company_id" select="1" widget="selection" groups="base.group_multi_company"/>
|
||||
<field name="task_nbr" select="2"/>
|
||||
<field name="task_hrs" select="2"/>
|
||||
<field name="task_progress" select="2"/>
|
||||
<field name="task_state" select="1"/>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_task_project_graph" model="ir.ui.view">
|
||||
<field name="name">task.report.graph</field>
|
||||
<field name="model">task.report</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Tasks by User" type="bar">
|
||||
<field name="user_id"/>
|
||||
<field name="task_progress" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_task_project_tree" model="ir.ui.view">
|
||||
<field name="name">task.report.tree</field>
|
||||
<field name="model">task.report</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Tasks by User">
|
||||
<field name="date_start" select="1" invisible="1"/>
|
||||
<field name="name" select="1"/>
|
||||
<field name="project_id" select="1"/>
|
||||
<field name="assign_to" select="1"/>
|
||||
<field name="type" select="1" invisible="1"/>
|
||||
<field name="priority" select="1" invisible="1"/>
|
||||
<field name="date_end" select="1" invisible="1"/>
|
||||
<field name="month" select="1" invisible="1"/>
|
||||
<field name="year" select="1" invisible="1"/>
|
||||
<field name="user_id" invisible="1"/>
|
||||
<field name="remaining_hrs"/>
|
||||
<field name="date_deadline" invisible="1"/>
|
||||
<field name="company_id" groups="base.group_multi_company"/>
|
||||
<field name="task_nbr"/>
|
||||
<field name="task_hrs"/>
|
||||
<field name="task_progress"/>
|
||||
<field name="task_state"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_report_task_search" model="ir.ui.view">
|
||||
<field name="name">task.report.search</field>
|
||||
<field name="model">task.report</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Tasks by User">
|
||||
<group col="10" colspan="4">
|
||||
<filter icon="terp-project" string="This Year" domain="[('year','=',time.strftime('%%Y'))]" help="Tasks performed in this year"/>
|
||||
<filter icon="terp-project" string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Tasks performed in this month"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Start Date" icon="terp-project" domain="[('date_start','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<filter string="End Date" icon="terp-project" domain="[('date_end','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<filter string="Deadline Date" icon="terp-project" domain="[('date_deadline','=',time.strftime('%%Y/%%m/%%d'))]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="project_id" select="1"/>
|
||||
<field name="user_id" select="1" widget="selection">
|
||||
<filter icon="terp-project" string="My Task" domain="[('user_id','=',uid)]" default="1"/>
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="1" string="Extended options..." colspan="10" col="12">
|
||||
<filter icon="terp-project"
|
||||
string="Very urgent"
|
||||
domain="[('priority','=','0')]"/>
|
||||
<filter icon="terp-project"
|
||||
string="Urgent"
|
||||
domain="[('priority','=','1')]"/>
|
||||
<filter icon="terp-project"
|
||||
string="Medium"
|
||||
domain="[('priority','=','2')]"/>
|
||||
<filter icon="terp-project"
|
||||
string="Low"
|
||||
domain="[('priority','=','3')]"/>
|
||||
<filter icon="terp-project"
|
||||
string="Very Low"
|
||||
domain="[('priority','=','4')]"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="10" col="11">
|
||||
<filter string="User" icon="terp-project" context="{'group_by':'user_id'}" />
|
||||
<filter string="Project" icon="terp-project" context="{'group_by':'project_id'}" />
|
||||
<filter string="Company" icon="terp-project" context="{'group_by':'company_id'}" />
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="State" icon="terp-project" context="{'group_by':'task_state'}"/>
|
||||
<filter string="Stage" icon="terp-project" context="{'group_by':'type'}"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter string="Month" icon="terp-project" context="{'group_by':'month'}"/>
|
||||
<filter string="Year" icon="terp-project" context="{'group_by':'year'}"/>
|
||||
</group>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_project_task" model="ir.actions.act_window">
|
||||
<field name="name">Tasks</field>
|
||||
<field name="res_model">task.report</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,graph</field>
|
||||
<field name="domain">[]</field>
|
||||
<field name="search_view_id" ref="view_report_task_search"/>
|
||||
</record>
|
||||
<menuitem id="base.menu_project_report" name="Reporting" parent="base.menu_main_pm" sequence="50"/>
|
||||
<menuitem action="action_project_task" id="menu_project_task_user_tree" parent="base.menu_project_report"/>
|
||||
-->
|
||||
<!-- Report for Users' Timesheet and Task Hours per Month -->
|
||||
|
||||
<record id="view_report_timesheet_task_user_tree" model="ir.ui.view">
|
||||
<field name="name">report.timesheet.task.user.tree</field>
|
||||
<field name="model">report.timesheet.task.user</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Timesheet/Task hours Report Per Month" >
|
||||
<field name="name" select="1"/>
|
||||
<field name="year" select="1" invisible="1"/>
|
||||
<field name="month" select="1" invisible="1"/>
|
||||
<field name="user_id" select="1"/>
|
||||
<field name="timesheet_hrs" widget="float_time" />
|
||||
<field name="task_hrs" widget="float_time"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record id="view_report_timesheet_task_user_search" model="ir.ui.view">
|
||||
<field name="name">report.timesheet.task.user.search</field>
|
||||
<field name="model">report.timesheet.task.user</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Tasks by User">
|
||||
<group colspan="4" col="3">
|
||||
<filter icon="terp-project" string="This Year" domain="[('year','=',time.strftime('%%Y'))]" />
|
||||
<filter icon="terp-project" string="This Month" domain="[('month','=',time.strftime('%%m'))]" />
|
||||
<separator orientation="vertical"/>
|
||||
<field name="user_id" select="1" widget="selection">
|
||||
<filter icon="terp-project" string="My Task" domain="[('user_id','=',uid)]" />
|
||||
</field>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="1" string="Group By..." colspan="4" col="3">
|
||||
<filter string="User" icon="terp-project" context="{'group_by':'user_id'}" default="1" />
|
||||
<filter string="Year" icon="terp-project" context="{'group_by':'year'}" />
|
||||
<filter string="Month" icon="terp-project" context="{'group_by':'month'}" />
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
<record id="action_report_timesheet_task_user" model="ir.actions.act_window">
|
||||
<field name="name">Timesheet / Task Hours Per Month</field>
|
||||
<field name="res_model">report.timesheet.task.user</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="search_view_id" ref="view_report_timesheet_task_user_search"/>
|
||||
</record>
|
||||
<menuitem id="menu_timesheet_task_user" parent="hr.menu_hr_reporting" action="action_report_timesheet_task_user"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue