import hr_timesheet
import wizard
+import report
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
'security/hr_timesheet_security.xml',
'hr_timesheet_view.xml',
'wizard/hr_timesheet_sign_in_out_view.xml',
+ 'report/hr_timesheet_report_view.xml',
'hr_timesheet_installer.xml',
'hr_timesheet_data.xml'
],
--- /dev/null
+import hr_timesheet_report
--- /dev/null
+
+from openerp import tools
+from openerp.osv import fields,osv
+from openerp.addons.decimal_precision import decimal_precision as dp
+
+class hr_timesheet_report(osv.osv):
+ _name = "hr.timesheet.report"
+ _description = "Timesheet"
+ _auto = False
+ _columns = {
+ 'year': fields.char('Year',size=64,required=False, readonly=True),
+ 'day': fields.char('Day', size=128, 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': fields.date('Date', readonly=True),
+ 'name': fields.char('Description', size=64,readonly=True),
+ 'product_id' : fields.many2one('product.product', 'Product',readonly=True),
+ 'journal_id' : fields.many2one('account.analytic.journal', 'Journal',readonly=True),
+ 'general_account_id' : fields.many2one('account.account', 'General Account', readonly=True),
+ 'user_id': fields.many2one('res.users', 'User',readonly=True),
+ 'account_id': fields.many2one('account.analytic.account', 'Analytic Account',readonly=True),
+ 'company_id': fields.many2one('res.company', 'Company',readonly=True),
+ 'cost': fields.float('#Cost',readonly=True, digits_compute=dp.get_precision('Account')),
+ 'quantity': fields.float('Time',readonly=True),
+ }
+
+ def _select(self):
+ select_str = """
+ SELECT min(hat.id) as id,
+ aal.date as date,
+ to_char(aal.date, 'YYYY-MM-DD') as day,
+ to_char(aal.date,'YYYY') as year,
+ to_char(aal.date,'MM') as month,
+ sum(aal.amount) as cost,
+ sum(aal.unit_amount) as quantity,
+ aal.account_id as account_id,
+ aal.journal_id as journal_id,
+ aal.product_id as product_id,
+ aal.general_account_id as general_account_id,
+ aal.user_id as user_id,
+ aal.company_id as company_id,
+ aal.currency_id as currency_id
+ """
+ return select_str
+
+ def _from(self):
+ from_str = """
+ account_analytic_line as aal
+ left join hr_analytic_timesheet as hat ON (hat.line_id=aal.id)
+ """
+ return from_str
+
+ def _group_by(self):
+ group_by_str = """
+ GROUP BY aal.date,
+ aal.account_id,
+ aal.product_id,
+ aal.general_account_id,
+ aal.journal_id,
+ aal.user_id,
+ aal.company_id,
+ aal.currency_id
+ """
+ return group_by_str
+
+ def init(self, cr):
+ # self._table = hr_timesheet_report
+ tools.drop_view_if_exists(cr, self._table)
+ cr.execute("""CREATE or REPLACE VIEW %s as (
+ %s
+ FROM ( %s )
+ %s
+ )""" % (self._table, self._select(), self._from(), self._group_by()))
+
+# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<openerp>
+ <data>
+ <record id="view_hr_timesheet_report_graph" model="ir.ui.view">
+ <field name="name">hr.timesheet.report.graph</field>
+ <field name="model">hr.timesheet.report</field>
+ <field name="arch" type="xml">
+ <graph string="Timesheet" type="pivot">
+ <field name="user_id" type="row"/>
+ <field name="date" interval="day" type="col"/>
+ <field name="quantity" type="measure"/>
+ <field name="cost" type="measure"/>
+ </graph>
+ </field>
+ </record>
+
+ <record id="view_hr_timesheet_report_search" model="ir.ui.view">
+ <field name="name">hr.timesheet.report.search</field>
+ <field name="model">hr.timesheet.report</field>
+ <field name="arch" type="xml">
+ <search string="Timesheet">
+ <field name="account_id"/>
+ <field name="user_id"/>
+ <filter string="This Month" name="month" icon="terp-go-year" domain="[('date','<=', time.strftime('%Y-%m-%d')),('date','>=',time.strftime('%Y-%m-01'))]" help="month"/>
+ <group expand="0" string="Extended Filters...">
+ <field name="general_account_id"/>
+ <field name="product_id"/>
+ <field name="journal_id"/>
+ <field name="company_id" groups="base.group_multi_company"/>
+ <field name="date"/>
+ </group>
+ <group expand="1" string="Group By">
+ <filter string="User" name="group_user_id" icon="terp-personal" context="{'group_by':'user_id'}"/>
+ <filter string="Product" name="product" icon="terp-accessories-archiver" context="{'group_by':'product_id'}"/>
+ <filter string="Analytic Account" name="analytic_account" icon="terp-folder-green" context="{'group_by':'account_id'}"/>
+ <filter string="General Account" name="general_account" icon="terp-folder-orange" context="{'group_by':'general_account_id'}"/>
+ <filter string="Company" icon="terp-go-home" context="{'group_by':'company_id'}" groups="base.group_multi_company"/>
+ <filter string="Day" icon="terp-go-today" context="{'group_by':'day'}" help="Group by day of date"/>
+ <filter string="Month" icon="terp-go-month" context="{'group_by':'month'}" help="Group by month of date"/>
+ <filter string="Year" icon="terp-go-year" context="{'group_by':'year'}" help="Group by year of date"/>
+ </group>
+ </search>
+ </field>
+ </record>
+
+ <record id="action_hr_timesheet_report_stat_all" model="ir.actions.act_window">
+ <field name="name">Timesheet Analysis</field>
+ <field name="res_model">hr.timesheet.report</field>
+ <field name="view_type">form</field>
+ <field name="view_mode">graph</field>
+ <field name="context">{'search_default_year':1,'search_default_month':1,'search_default_group_user_id':1,'group_by_no_leaf':1,'group_by':[]}</field>
+ </record>
+
+ <menuitem action="action_hr_timesheet_report_stat_all" id="menu_hr_timesheet_report_all"
+ parent="hr.menu_hr_reporting" groups="base.group_hr_manager" sequence="3"/>
+
+ </data>
+</openerp>
'hr_timesheet_sheet_view.xml',
'hr_timesheet_workflow.xml',
'report/hr_timesheet_report_view.xml',
- 'report/timesheet_report_view.xml',
'wizard/hr_timesheet_current_view.xml',
'hr_timesheet_sheet_data.xml',
'res_config_view.xml',
#
##############################################################################
-import timesheet_report
import hr_timesheet_report
+
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
from openerp import tools
from openerp.osv import fields,osv
-from openerp.addons.decimal_precision import decimal_precision as dp
-
class hr_timesheet_report(osv.osv):
- _name = "hr.timesheet.report"
- _description = "Timesheet"
- _auto = False
+ _inherit = "hr.timesheet.report"
_columns = {
- 'date': fields.date('Date', readonly=True),
- 'name': fields.char('Description', size=64,readonly=True),
- 'product_id' : fields.many2one('product.product', 'Product',readonly=True),
- 'journal_id' : fields.many2one('account.analytic.journal', 'Journal',readonly=True),
- 'general_account_id' : fields.many2one('account.account', 'General Account', readonly=True),
- 'user_id': fields.many2one('res.users', 'User',readonly=True),
- 'account_id': fields.many2one('account.analytic.account', 'Analytic Account',readonly=True),
- 'company_id': fields.many2one('res.company', 'Company',readonly=True),
- 'cost': fields.float('Cost',readonly=True, digits_compute=dp.get_precision('Account')),
- 'quantity': fields.float('Time',readonly=True),
- }
+ 'to_invoice': fields.many2one('hr_timesheet_invoice.factor', 'Type of Invoicing',readonly=True),
+ 'nbr': fields.integer('#Nbr',readonly=True),
+ 'total_diff': fields.float('#Total Diff',readonly=True),
+ 'total_timesheet': fields.float('#Total Timesheet',readonly=True),
+ 'total_attendance': fields.float('#Total Attendance',readonly=True),
+ 'department_id':fields.many2one('hr.department','Department',readonly=True),
+ 'date_from': fields.date('Date from',readonly=True,),
+ 'date_to': fields.date('Date to',readonly=True),
+ 'date_current': fields.date('Current date', required=True),
+ 'state' : fields.selection([
+ ('new', 'New'),
+ ('draft','Draft'),
+ ('confirm','Confirmed'),
+ ('done','Done')], 'Status', readonly=True),
+ }
+
+ def _select(self):
+ return super(hr_timesheet_report, self)._select() + """,
+ htss.name,
+ htss.date_from,
+ htss.date_to,
+ count(*) as nbr,
+ (SELECT sum(day.total_difference)
+ FROM hr_timesheet_sheet_sheet AS sheet
+ LEFT JOIN hr_timesheet_sheet_sheet_day AS day
+ ON (sheet.id = day.sheet_id) where sheet.id=htss.id) as total_diff,
+ (SELECT sum(day.total_timesheet)
+ FROM hr_timesheet_sheet_sheet AS sheet
+ LEFT JOIN hr_timesheet_sheet_sheet_day AS day
+ ON (sheet.id = day.sheet_id) where sheet.id=htss.id) as total_timesheet,
+ (SELECT sum(day.total_attendance)
+ FROM hr_timesheet_sheet_sheet AS sheet
+ LEFT JOIN hr_timesheet_sheet_sheet_day AS day
+ ON (sheet.id = day.sheet_id) where sheet.id=htss.id) as total_attendance,
+ aal.to_invoice,
+ htss.department_id,
+ htss.state"""
+
+ def _from(self):
+ return super(hr_timesheet_report, self)._from() + "left join hr_timesheet_sheet_sheet as htss ON (hat.sheet_id=htss.id)"
+
+ def _group_by(self):
+ return super(hr_timesheet_report, self)._group_by() + """,
+ htss.date_from,
+ htss.date_to,
+ aal.unit_amount,
+ aal.amount,
+ aal.to_invoice,
+ htss.name,
+ htss.state,
+ htss.id,
+ htss.department_id"""
- def init(self, cr):
- tools.drop_view_if_exists(cr, 'hr_timesheet_report')
- cr.execute("""
- create or replace view hr_timesheet_report as (
- select
- min(t.id) as id,
- l.date as date,
- sum(l.amount) as cost,
- sum(l.unit_amount) as quantity,
- l.account_id as account_id,
- l.journal_id as journal_id,
- l.product_id as product_id,
- l.general_account_id as general_account_id,
- l.user_id as user_id,
- l.company_id as company_id,
- l.currency_id as currency_id
- from
- hr_analytic_timesheet as t
- left join account_analytic_line as l ON (t.line_id=l.id)
- group by
- l.date,
- l.account_id,
- l.product_id,
- l.general_account_id,
- l.journal_id,
- l.user_id,
- l.company_id,
- l.currency_id
- )
- """)
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
- <record id="view_hr_timesheet_report_graph" model="ir.ui.view">
- <field name="name">hr.timesheet.report.graph</field>
+ <record id="view_timesheet_report_graph" model="ir.ui.view">
+ <field name="name">timesheet.report.graph</field>
<field name="model">hr.timesheet.report</field>
+ <field name="inherit_id" ref="hr_timesheet.view_hr_timesheet_report_graph"/>
<field name="arch" type="xml">
- <graph string="Timesheet" type="pivot">
- <field name="user_id" type="row"/>
- <field name="date" interval="day" type="col"/>
- <field name="quantity" type="measure"/>
- <field name="cost" type="measure"/>
- </graph>
+ <field name="user_id" position="after">
+ <field name="state" type="row"/>
+ </field>
+ <field name="cost" position="after">
+ <field name="total_diff" type="measure"/>
+ <field name="total_timesheet" type="measure"/>
+ <field name="total_attendance" type="measure"/>
+ </field>
</field>
</record>
- <record id="view_hr_timesheet_report_search" model="ir.ui.view">
- <field name="name">hr.timesheet.report.search</field>
+
+ <record id="view_timesheet_report_search" model="ir.ui.view">
+ <field name="name">timesheet.report.search</field>
<field name="model">hr.timesheet.report</field>
+ <field name="inherit_id" ref="hr_timesheet.view_hr_timesheet_report_search"/>
<field name="arch" type="xml">
- <search string="Timesheet">
- <filter icon="terp-go-year" string="This Month" name="month" domain="[('date','<=', time.strftime('%Y-%m-%d')),('date','>=',time.strftime('%Y-%m-01'))]" help="month"/>
- <field name="account_id" groups="analytic.group_analytic_accounting"/>
- <field name="user_id"/>
- <group expand="0" string="Extended Filters...">
- <field name="general_account_id"/>
- <field name="product_id"/>
- <field name="journal_id"/>
- <field name="company_id" groups="base.group_multi_company"/>
- <field name="date" />
- </group>
- <group expand="1" string="Group By">
- <filter string="User" name="group_user_id" icon="terp-personal" context="{'group_by':'user_id'}"/>
- <filter string="Product" icon="terp-accessories-archiver" context="{'group_by':'product_id'}"/>
- <filter string="Analytic Account" icon="terp-folder-green" context="{'group_by':'account_id'}" groups="analytic.group_analytic_accounting"/>
- <filter string="General Account" icon="terp-folder-orange" context="{'group_by':'general_account_id'}"/>
- <filter string="Company" icon="terp-go-home" context="{'group_by':'company_id'}" groups="base.group_multi_company"/>
- <filter string="Date (day)" context="{'group_by':'date:day'}" help="Group by day of date"/>
- <filter string="Date (month)" context="{'group_by':'date:month'}" help="Group by month of date"/>
- <filter string="Date (year)" context="{'group_by':'date:year'}" help="Group by year of date"/>
- </group>
- </search>
+ <field name="account_id" position="before">
+ <filter icon="terp-document-new" string="Draft" domain="[('state','=','draft')]"/>
+ <filter icon="terp-camera_test" string="Confirmed" domain="[('state','=','confirm')]"/>
+ <filter icon="terp-dialog-close" string="Done" domain="[('state','=','done')]"/>
+ </field>
+ <field name="general_account_id" position="after">
+ <field name="to_invoice"/>
+ <field name="department_id"/>
+ <field name="date_to"/>
+ <field name="date_from"/>
+ </field>
+ <filter name="product" position="before">
+ <filter string="Department" icon="terp-personal+" context="{'group_by':'department_id'}"/>
+ </filter>
+ <filter name="analytic_account" position="before">
+ <filter string="Type of Invoicing" icon="terp-stock_symbol-selection" context="{'group_by':'to_invoice'}"/>
+ </filter>
+ <filter name="general_account" position="after">
+ <filter string="Status" icon="terp-stock_effects-object-colorize" context="{'group_by':'state'}"/>
+ </filter>
</field>
</record>
- <record id="action_hr_timesheet_report_stat_all" model="ir.actions.act_window">
- <field name="name">Timesheet Analysis</field>
- <field name="res_model">hr.timesheet.report</field>
- <field name="view_type">form</field>
- <field name="view_mode">graph</field>
- <field name="context">{'search_default_month':1,'search_default_group_user_id':1,'group_by_no_leaf':1,'group_by':[]}</field>
- <field name="help" type="html">
- <p>
- This report performs analysis on timesheets created by your
- human resources in the system. It allows you to have a full
- overview of entries done by your employees. You can group them
- by specific selection criteria thanks to the search tool.
- </p>
- </field>
- </record>
- <menuitem
- action="action_hr_timesheet_report_stat_all"
- id="menu_hr_timesheet_report_all"
- parent="hr.menu_hr_reporting" sequence="3"/>
</data>
</openerp>
+++ /dev/null
-# -*- 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 openerp import tools
-from openerp.osv import fields,osv
-
-class timesheet_report(osv.osv):
- _name = "timesheet.report"
- _description = "Timesheet"
- _auto = False
- _columns = {
- '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),
- 'day': fields.char('Day', size=128, readonly=True),
- 'date': fields.date('Date', readonly=True),
- 'name': fields.char('Description', size=64,readonly=True),
- 'product_id' : fields.many2one('product.product', 'Product'),
- 'general_account_id' : fields.many2one('account.account', 'General Account', readonly=True),
- 'user_id': fields.many2one('res.users', 'User',readonly=True),
- 'to_invoice': fields.many2one('hr_timesheet_invoice.factor', 'Type of Invoicing',readonly=True),
- 'account_id': fields.many2one('account.analytic.account', 'Analytic Account',readonly=True),
- 'nbr': fields.integer('#Nbr',readonly=True),
- 'total_diff': fields.float('#Total Diff',readonly=True),
- 'total_timesheet': fields.float('#Total Timesheet',readonly=True),
- 'total_attendance': fields.float('#Total Attendance',readonly=True),
- 'company_id': fields.many2one('res.company', 'Company',readonly=True),
- 'department_id':fields.many2one('hr.department','Department',readonly=True),
- 'date_from': fields.date('Date from',readonly=True,),
- 'date_to': fields.date('Date to',readonly=True),
- 'date_current': fields.date('Current date', required=True),
- 'state' : fields.selection([
- ('new', 'New'),
- ('draft','Draft'),
- ('confirm','Confirmed'),
- ('done','Done')], 'Status', readonly=True),
- 'quantity': fields.float('Time',readonly=True),
- 'cost': fields.float('#Cost',readonly=True),
- }
-
- def init(self, cr):
- tools.drop_view_if_exists(cr, 'timesheet_report')
- cr.execute("""
- create or replace view timesheet_report as (
- select
- min(aal.id) as id,
- htss.name,
- aal.date as date,
- htss.date_from,
- htss.date_to,
- to_char(htss.date_from, 'YYYY-MM-DD') as day,
- to_char(htss.date_from, 'YYYY') as year,
- to_char(htss.date_from, 'MM') as month,
- count(*) as nbr,
- aal.unit_amount as quantity,
- aal.amount as cost,
- aal.account_id,
- aal.product_id,
- (SELECT sum(day.total_difference)
- FROM hr_timesheet_sheet_sheet AS sheet
- LEFT JOIN hr_timesheet_sheet_sheet_day AS day
- ON (sheet.id = day.sheet_id) where sheet.id=htss.id) as total_diff,
- (SELECT sum(day.total_timesheet)
- FROM hr_timesheet_sheet_sheet AS sheet
- LEFT JOIN hr_timesheet_sheet_sheet_day AS day
- ON (sheet.id = day.sheet_id) where sheet.id=htss.id) as total_timesheet,
- (SELECT sum(day.total_attendance)
- FROM hr_timesheet_sheet_sheet AS sheet
- LEFT JOIN hr_timesheet_sheet_sheet_day AS day
- ON (sheet.id = day.sheet_id) where sheet.id=htss.id) as total_attendance,
- aal.to_invoice,
- aal.general_account_id,
- htss.user_id,
- htss.company_id,
- htss.department_id,
- htss.state
- from account_analytic_line as aal
- left join hr_analytic_timesheet as hat ON (hat.line_id=aal.id)
- left join hr_timesheet_sheet_sheet as htss ON (hat.sheet_id=htss.id)
- group by
- aal.account_id,
- aal.date,
- htss.date_from,
- htss.date_to,
- aal.unit_amount,
- aal.amount,
- aal.to_invoice,
- aal.product_id,
- aal.general_account_id,
- htss.name,
- htss.company_id,
- htss.state,
- htss.id,
- htss.department_id,
- htss.user_id
- )
- """)
-
-# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
+++ /dev/null
-<?xml version="1.0" encoding="utf-8"?>
-<openerp>
- <data>
- <record id="view_timesheet_report_graph" model="ir.ui.view">
- <field name="name">timesheet.report.graph</field>
- <field name="model">timesheet.report</field>
- <field name="arch" type="xml">
- <graph string="Timesheet" type="pivot" stacked="True">
- <field name="user_id" type="row"/>
- <field name="state" type="row"/>
- <field name="quantity" type="measure"/>
- <field name="cost" type="measure"/>
- <field name="total_diff" type="measure"/>
- <field name="total_timesheet" type="measure"/>
- <field name="total_attendance" type="measure"/>
- </graph>
- </field>
- </record>
- <record id="view_timesheet_report_search" model="ir.ui.view">
- <field name="name">timesheet.report.search</field>
- <field name="model">timesheet.report</field>
- <field name="arch" type="xml">
- <search string="Timesheet">
- <filter icon="terp-document-new" string="Draft" domain="[('state','=','draft')]"/>
- <filter icon="terp-camera_test" string="Confirmed" domain="[('state','=','confirm')]"/>
- <filter icon="terp-dialog-close" string="Done" domain="[('state','=','done')]"/>
- <field name="account_id"/>
- <field name="user_id" />
- <group expand="0" string="Extended Filters...">
- <field name="general_account_id"/>
- <field name="to_invoice"/>
- <field name="product_id"/>
- <field name="department_id"/>
- <field name="company_id" groups="base.group_multi_company"/>
- <field name="date_to"/>
- <field name="date_from"/>
- </group>
- <group expand="1" string="Group By">
- <filter string="User" name="User_id" icon="terp-personal" context="{'group_by':'user_id'}"/>
- <filter string="Department" icon="terp-personal+" context="{'group_by':'department_id'}"/>
- <filter string="Product" icon="terp-accessories-archiver" context="{'group_by':'product_id'}"/>
- <filter string="Type of Invoicing" icon="terp-stock_symbol-selection" context="{'group_by':'to_invoice'}"/>
- <filter string="Analytic Account" icon="terp-folder-green" context="{'group_by':'account_id'}"/>
- <filter string="General Account" icon="terp-folder-orange" context="{'group_by':'general_account_id'}"/>
- <filter string="Status" icon="terp-stock_effects-object-colorize" context="{'group_by':'state'}"/>
- <filter string="Company" icon="terp-go-home" context="{'group_by':'company_id'}" groups="base.group_multi_company"/>
- <filter string="Day" icon="terp-go-today" context="{'group_by':'day'}" help="Group by day of date"/>
- <filter string="Month" icon="terp-go-month" context="{'group_by':'month'}" help="Group by month of date"/>
- <filter string="Year" icon="terp-go-year" context="{'group_by':'year'}" help="Group by year of date"/>
- </group>
- </search>
- </field>
- </record>
-
- <record id="action_timesheet_report_stat_all" model="ir.actions.act_window">
- <field name="name">Timesheet Sheet Analysis</field>
- <field name="res_model">timesheet.report</field>
- <field name="view_type">form</field>
- <field name="view_mode">graph</field>
- <field name="context">{'search_default_year':1,'search_default_month':1,'search_default_User_id':1,'group_by_no_leaf':1,'group_by':[]}</field>
- <field name="search_view_id" ref="view_timesheet_report_search"/>
- </record>
- <menuitem action="action_timesheet_report_stat_all" id="menu_timesheet_report_all"
- parent="hr.menu_hr_reporting" sequence="4" groups="base.group_hr_manager"/>
- </data>
-</openerp>
-id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink\r
-access_hr_timesheet_sheet_sheet_user,hr_timesheet_sheet.sheet.user,model_hr_timesheet_sheet_sheet,base.group_user,1,1,1,1\r
-access_hr_timesheet_sheet_sheet_system_employee,hr_timesheet_sheet.sheet.system.employee,model_hr_timesheet_sheet_sheet,base.group_user,1,1,1,0\r
-access_hr_timesheet_sheet_sheet_day,hr_timesheet_sheet.sheet.day,model_hr_timesheet_sheet_sheet_day,base.group_hr_user,1,1,1,1\r
-access_hr_timesheet_sheet_sheet_account,hr_timesheet_sheet.sheet.account,model_hr_timesheet_sheet_sheet_account,base.group_hr_user,1,1,1,1\r
-access_hr_timesheet_report,hr.timesheet.report,model_hr_timesheet_report,base.group_hr_manager,1,1,0,0\r
-access_hr_analytic_timesheet_system_user,hr.analytic.timesheet.system.user,model_hr_analytic_timesheet,base.group_user,1,0,0,0\r
-access_hr_timesheet_sheet_sheet_day,hr.timesheet.sheet.sheet.day.user,model_hr_timesheet_sheet_sheet_day,base.group_user,1,1,1,0\r
-access_timesheet_report,timesheet.report,model_timesheet_report,base.group_hr_manager,1,1,0,0\r
+id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
+access_hr_timesheet_sheet_sheet_user,hr_timesheet_sheet.sheet.user,model_hr_timesheet_sheet_sheet,base.group_user,1,1,1,1
+access_hr_timesheet_sheet_sheet_system_employee,hr_timesheet_sheet.sheet.system.employee,model_hr_timesheet_sheet_sheet,base.group_user,1,1,1,0
+access_hr_timesheet_sheet_sheet_day,hr_timesheet_sheet.sheet.day,model_hr_timesheet_sheet_sheet_day,base.group_hr_user,1,1,1,1
+access_hr_timesheet_sheet_sheet_account,hr_timesheet_sheet.sheet.account,model_hr_timesheet_sheet_sheet_account,base.group_hr_user,1,1,1,1
+access_hr_timesheet_report,hr.timesheet.report,model_hr_timesheet_report,base.group_hr_manager,1,1,0,0
+access_hr_analytic_timesheet_system_user,hr.analytic.timesheet.system.user,model_hr_analytic_timesheet,base.group_user,1,0,0,0
+access_hr_timesheet_sheet_sheet_day,hr.timesheet.sheet.sheet.day.user,model_hr_timesheet_sheet_sheet_day,base.group_user,1,1,1,0