@@ -1,8 +1,8 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -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 account
|
||||
import installer
|
||||
import project
|
||||
import partner
|
||||
import invoice
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
|
||||
{
|
||||
"name" : "Accounting and financial management",
|
||||
"name" : "Accounting and Financial Management",
|
||||
"version" : "1.1",
|
||||
"depends" : ["product", "base", "process"],
|
||||
"author" : "Tiny",
|
||||
@@ -58,6 +58,7 @@
|
||||
'process/supplier_invoice_process.xml',
|
||||
'sequence_view.xml',
|
||||
'company_view.xml',
|
||||
'account_installer.xml',
|
||||
],
|
||||
'demo_xml': [
|
||||
'account_demo.xml',
|
||||
|
||||
+57
-55
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -416,15 +416,27 @@ class account_account(osv.osv):
|
||||
default['child_parent_ids'] = False
|
||||
return super(account_account, self).copy(cr, uid, id, default, context=context)
|
||||
|
||||
def _check_moves(self, cr, uid, ids, method, context):
|
||||
line_obj = self.pool.get('account.move.line')
|
||||
account_ids = self.search(cr, uid, [('id', 'child_of', ids)])
|
||||
if line_obj.search(cr, uid, [('account_id', 'in', account_ids)]):
|
||||
if method == 'write':
|
||||
raise osv.except_osv(_('Error !'), _('You cannot deactivate an account that contains account moves.'))
|
||||
elif method == 'unlink':
|
||||
raise osv.except_osv(_('Error !'), _('You cannot remove an account which has account entries!. '))
|
||||
return True
|
||||
|
||||
def write(self, cr, uid, ids, vals, context=None):
|
||||
if not context:
|
||||
context = {}
|
||||
if 'active' in vals and not vals['active']:
|
||||
line_obj = self.pool.get('account.move.line')
|
||||
account_ids = self.search(cr, uid, [('id', 'child_of', ids)])
|
||||
if line_obj.search(cr, uid, [('account_id', 'in', account_ids)]):
|
||||
raise osv.except_osv(_('Error !'), _('You can not deactivate an account that contains Ledger Postings.'))
|
||||
self._check_moves(cr, uid, ids, "write", context)
|
||||
return super(account_account, self).write(cr, uid, ids, vals, context=context)
|
||||
|
||||
def unlink(self, cr, uid, ids, context={}):
|
||||
self._check_moves(cr, uid, ids, "unlink", context)
|
||||
return super(account_account, self).unlink(cr, uid, ids, context)
|
||||
|
||||
account_account()
|
||||
|
||||
class account_journal_view(osv.osv):
|
||||
@@ -767,6 +779,23 @@ class account_move(osv.osv):
|
||||
for id in ids:
|
||||
result.setdefault(id, 0.0)
|
||||
return result
|
||||
|
||||
def _search_amount(self, cr, uid, obj, name, args, context):
|
||||
ids = []
|
||||
cr.execute('select move_id,sum(debit) from account_move_line group by move_id')
|
||||
result = dict(cr.fetchall())
|
||||
|
||||
for item in args:
|
||||
if item[1] == '>=':
|
||||
res = [('id', 'in', [k for k,v in result.iteritems() if v >= item[2]])]
|
||||
else:
|
||||
res = [('id', 'in', [k for k,v in result.iteritems() if v <= item[2]])]
|
||||
ids += res
|
||||
|
||||
if not ids:
|
||||
return [('id', '>', '0')]
|
||||
|
||||
return ids
|
||||
|
||||
_columns = {
|
||||
'name': fields.char('Number', size=64, required=True),
|
||||
@@ -778,7 +807,7 @@ class account_move(osv.osv):
|
||||
'line_id': fields.one2many('account.move.line', 'move_id', 'Entries', states={'posted':[('readonly',True)]}),
|
||||
'to_check': fields.boolean('To Be Verified'),
|
||||
'partner_id': fields.related('line_id', 'partner_id', type="many2one", relation="res.partner", string="Partner"),
|
||||
'amount': fields.function(_amount_compute, method=True, string='Amount', digits=(16,int(config['price_accuracy']))),
|
||||
'amount': fields.function(_amount_compute, method=True, string='Amount', digits=(16,int(config['price_accuracy'])), type='float', fnct_search=_search_amount),
|
||||
'date': fields.date('Date', required=True),
|
||||
'type': fields.selection([
|
||||
('pay_voucher','Cash Payment'),
|
||||
@@ -956,7 +985,7 @@ class account_move(osv.osv):
|
||||
else:
|
||||
context.update({'journal_id': move.journal_id.id, 'period_id': move.period_id.id})
|
||||
line_id = self.pool.get('account.move.line').create(cr, uid, {
|
||||
'name': _t(cr, None, 'selection', context.get('lang'), source=(mode.capitalize()+' Centralisation')) or (mode.capitalize()+' Centralisation'),
|
||||
'name': _(mode.capitalize()+' Centralisation'),
|
||||
'centralisation': mode,
|
||||
'account_id': account_id,
|
||||
'move_id': move.id,
|
||||
@@ -1084,8 +1113,8 @@ class account_move_reconcile(osv.osv):
|
||||
'name': lambda self,cr,uid,ctx={}: self.pool.get('ir.sequence').get(cr, uid, 'account.reconcile') or '/',
|
||||
}
|
||||
def reconcile_partial_check(self, cr, uid, ids, type='auto', context={}):
|
||||
total = 0.0
|
||||
for rec in self.browse(cr, uid, ids, context):
|
||||
total = 0.0
|
||||
for line in rec.line_partial_ids:
|
||||
total += (line.debit or 0.0) - (line.credit or 0.0)
|
||||
if not total:
|
||||
@@ -1546,7 +1575,8 @@ class account_model(osv.osv):
|
||||
def generate(self, cr, uid, ids, datas={}, context={}):
|
||||
move_ids = []
|
||||
for model in self.browse(cr, uid, ids, context):
|
||||
period_id = self.pool.get('account.period').find(cr,uid, context=context)
|
||||
context.update({'date':datas['date']})
|
||||
period_id = self.pool.get('account.period').find(cr, uid, dt=context.get('date',False))
|
||||
if not period_id:
|
||||
raise osv.except_osv(_('No period found !'), _('Unable to find a valid period !'))
|
||||
period_id = period_id[0]
|
||||
@@ -1554,6 +1584,7 @@ class account_model(osv.osv):
|
||||
'ref': model.ref,
|
||||
'period_id': period_id,
|
||||
'journal_id': model.journal_id.id,
|
||||
'date': context.get('date',time.strftime('%Y-%m-%d'))
|
||||
})
|
||||
move_ids.append(move_id)
|
||||
for line in model.lines_id:
|
||||
@@ -1571,7 +1602,7 @@ class account_model(osv.osv):
|
||||
'move_id': move_id,
|
||||
'ref': line.ref,
|
||||
'partner_id': line.partner_id.id,
|
||||
'date': time.strftime('%Y-%m-%d'),
|
||||
'date': context.get('date',time.strftime('%Y-%m-%d')),
|
||||
'date_maturity': time.strftime('%Y-%m-%d')
|
||||
})
|
||||
c = context.copy()
|
||||
@@ -1608,8 +1639,8 @@ class account_model_line(osv.osv):
|
||||
}
|
||||
_order = 'sequence'
|
||||
_sql_constraints = [
|
||||
('credit_debit1', 'CHECK (credit*debit=0)', 'Wrong credit or debit value in model !'),
|
||||
('credit_debit2', 'CHECK (credit+debit>=0)', 'Wrong credit or debit value in model !'),
|
||||
('credit_debit1', 'CHECK (credit*debit=0)', 'Wrong credit or debit value in model (Credit Or Debit Must Be "0")!'),
|
||||
('credit_debit2', 'CHECK (credit+debit>=0)', 'Wrong credit or debit value in model (Credit + Debit Must Be greater "0")!'),
|
||||
]
|
||||
account_model_line()
|
||||
|
||||
@@ -1716,21 +1747,28 @@ account_subscription_line()
|
||||
|
||||
class account_config_wizard(osv.osv_memory):
|
||||
_name = 'account.config.wizard'
|
||||
_inherit = 'res.config'
|
||||
|
||||
def _get_charts(self, cr, uid, context):
|
||||
module_obj=self.pool.get('ir.module.module')
|
||||
ids=module_obj.search(cr, uid, [('category_id', '=', 'Account Charts'), ('state', '<>', 'installed')])
|
||||
ids=module_obj.search(cr, uid, [('category_id', '=', 'Account Charts'),
|
||||
('state', '<>', 'installed')])
|
||||
res=[(m.id, m.shortdesc) for m in module_obj.browse(cr, uid, ids)]
|
||||
res.append((-1, 'None'))
|
||||
res.sort(key=lambda x: x[1])
|
||||
return res
|
||||
|
||||
_columns = {
|
||||
'name':fields.char('Name', required=True, size=64, help="Name of the fiscal year as displayed on screens."),
|
||||
'code':fields.char('Code', required=True, size=64, help="Name of the fiscal year as displayed in reports."),
|
||||
'name':fields.char(
|
||||
'Name', required=True, size=64,
|
||||
help="Name of the fiscal year as displayed on screens."),
|
||||
'code':fields.char(
|
||||
'Code', required=True, size=64,
|
||||
help="Name of the fiscal year as displayed in reports."),
|
||||
'date1': fields.date('Start Date', required=True),
|
||||
'date2': fields.date('End Date', required=True),
|
||||
'period':fields.selection([('month','Month'),('3months','3 Months')], 'Periods', required=True),
|
||||
'period':fields.selection([('month','Month'), ('3months','3 Months')],
|
||||
'Periods', required=True),
|
||||
'charts' : fields.selection(_get_charts, 'Charts of Account',required=True)
|
||||
}
|
||||
_defaults = {
|
||||
@@ -1740,15 +1778,6 @@ class account_config_wizard(osv.osv_memory):
|
||||
'date2': lambda *a: time.strftime('%Y-12-31'),
|
||||
'period':lambda *a:'month',
|
||||
}
|
||||
def action_cancel(self,cr,uid,ids,conect=None):
|
||||
return {
|
||||
'view_type': 'form',
|
||||
"view_mode": 'form',
|
||||
'res_model': 'ir.actions.configuration.wizard',
|
||||
'type': 'ir.actions.act_window',
|
||||
'target':'new',
|
||||
}
|
||||
|
||||
def install_account_chart(self, cr, uid, ids, context=None):
|
||||
for res in self.read(cr,uid,ids):
|
||||
chart_id = res['charts']
|
||||
@@ -1758,7 +1787,7 @@ class account_config_wizard(osv.osv_memory):
|
||||
cr.commit()
|
||||
db, pool = pooler.restart_pool(cr.dbname, update_module=True)
|
||||
|
||||
def action_create(self, cr, uid,ids, context=None):
|
||||
def execute(self, cr, uid, ids, context=None):
|
||||
for res in self.read(cr,uid,ids):
|
||||
if 'date1' in res and 'date2' in res:
|
||||
res_obj = self.pool.get('account.fiscalyear')
|
||||
@@ -1777,16 +1806,6 @@ class account_config_wizard(osv.osv_memory):
|
||||
elif res['period']=='3months':
|
||||
res_obj.create_period3(cr,uid,[new_id])
|
||||
self.install_account_chart(cr,uid,ids)
|
||||
return {
|
||||
'view_type': 'form',
|
||||
"view_mode": 'form',
|
||||
'res_model': 'ir.actions.configuration.wizard',
|
||||
'type': 'ir.actions.act_window',
|
||||
'target':'new',
|
||||
}
|
||||
|
||||
|
||||
|
||||
account_config_wizard()
|
||||
|
||||
|
||||
@@ -2125,6 +2144,7 @@ class wizard_multi_charts_accounts(osv.osv_memory):
|
||||
* generates all accounting properties and assigns them correctly
|
||||
"""
|
||||
_name='wizard.multi.charts.accounts'
|
||||
_inherit = 'res.config'
|
||||
|
||||
_columns = {
|
||||
'company_id':fields.many2one('res.company','Company',required=True),
|
||||
@@ -2145,7 +2165,7 @@ class wizard_multi_charts_accounts(osv.osv_memory):
|
||||
'code_digits': lambda *a:6,
|
||||
}
|
||||
|
||||
def action_create(self, cr, uid, ids, context=None):
|
||||
def execute(self, cr, uid, ids, context=None):
|
||||
obj_multi = self.browse(cr,uid,ids[0])
|
||||
obj_acc = self.pool.get('account.account')
|
||||
obj_acc_tax = self.pool.get('account.tax')
|
||||
@@ -2408,24 +2428,6 @@ class wizard_multi_charts_accounts(osv.osv_memory):
|
||||
'position_id' : new_fp,
|
||||
}
|
||||
obj_ac_fp.create(cr, uid, vals_acc)
|
||||
|
||||
return {
|
||||
'view_type': 'form',
|
||||
"view_mode": 'form',
|
||||
'res_model': 'ir.actions.configuration.wizard',
|
||||
'type': 'ir.actions.act_window',
|
||||
'target':'new',
|
||||
}
|
||||
def action_cancel(self,cr,uid,ids,conect=None):
|
||||
return {
|
||||
'view_type': 'form',
|
||||
"view_mode": 'form',
|
||||
'res_model': 'ir.actions.configuration.wizard',
|
||||
'type': 'ir.actions.act_window',
|
||||
'target':'new',
|
||||
}
|
||||
|
||||
|
||||
wizard_multi_charts_accounts()
|
||||
|
||||
class account_bank_accounts_wizard(osv.osv_memory):
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -143,8 +143,7 @@ class account_bank_statement(osv.osv):
|
||||
'period_id': _get_period,
|
||||
}
|
||||
|
||||
def button_confirm(self, cr, uid, ids, context=None):
|
||||
context = context or {}
|
||||
def button_confirm(self, cr, uid, ids, context={}):
|
||||
done = []
|
||||
res_currency_obj = self.pool.get('res.currency')
|
||||
res_users_obj = self.pool.get('res.users')
|
||||
@@ -166,7 +165,7 @@ class account_bank_statement(osv.osv):
|
||||
_('The expected balance (%.2f) is different than the computed one. (%.2f)') % (st.balance_end_real, st.balance_end))
|
||||
if (not st.journal_id.default_credit_account_id) \
|
||||
or (not st.journal_id.default_debit_account_id):
|
||||
raise osv.except_osv(_('Configration Error !'),
|
||||
raise osv.except_osv(_('Configuration Error !'),
|
||||
_('Please verify that an account is defined in the journal.'))
|
||||
|
||||
for line in st.move_line_ids:
|
||||
@@ -178,10 +177,10 @@ class account_bank_statement(osv.osv):
|
||||
# in bank stat.rec we get line_new_ids on bank.stat.rec.line
|
||||
for move in st.line_ids:
|
||||
context.update({'date':move.date})
|
||||
|
||||
move_id = account_move_obj.create(cr, uid, {
|
||||
'journal_id': st.journal_id.id,
|
||||
'period_id': st.period_id.id,
|
||||
'date': move.date,
|
||||
}, context=context)
|
||||
account_bank_statement_line_obj.write(cr, uid, [move.id], {
|
||||
'move_ids': [(4,move_id, False)]
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
<openerp>
|
||||
<data>
|
||||
<record id="view_account_installer" model="ir.ui.view">
|
||||
<field name="name">account.installer.view</field>
|
||||
<field name="model">account.installer</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.res_config_view_base"/>
|
||||
<field name="arch" type="xml">
|
||||
<data>
|
||||
<form position="attributes"><attribute name="string">
|
||||
Accounting Modules Installation
|
||||
</attribute></form>
|
||||
|
||||
<group string="res_config_contents" position="replace">
|
||||
<separator string="Configure Your Accounting System" colspan="4"/>
|
||||
<image name="gtk-dialog-info"/>
|
||||
<newline/>
|
||||
<label align="0.0" string=" Lorem ipsum dolor
|
||||
sit amet, consectetur adipiscing elit. Cras metus
|
||||
augue, ultricies et vehicula id, fringilla quis
|
||||
mauris. Vestibulum fringilla ipsum sit amet est
|
||||
adipiscing eget euismod velit semper. Proin non mauris
|
||||
velit. Donec malesuada nisi sed augue viverra commodo
|
||||
sagittis nisi rutrum. Cras vitae libero nunc, a
|
||||
molestie sapien. Proin et augue sit amet est egestas
|
||||
fermentum ut eu lacus. Etiam nisi orci, volutpat
|
||||
aliquam viverra interdum, vehicula iaculis
|
||||
lectus. Mauris ligula sapien, auctor in pharetra non,
|
||||
ultrices quis odio."/>
|
||||
<group>
|
||||
<separator string="Accounting" colspan="4"/>
|
||||
<field name="account_analytic_default"/>
|
||||
<field name="account_analytic_plans"/>
|
||||
<!-- insert suppliers payment management here -->
|
||||
<field name="account_followup"/>
|
||||
<field name="account_asset"/>
|
||||
</group>
|
||||
</group>
|
||||
|
||||
<xpath expr='//button[@name="action_skip"]' position='replace'/>
|
||||
<xpath expr='//button[@name="action_next"]' position='attributes'>
|
||||
<attribute name='string'>Install Modules</attribute>
|
||||
</xpath>
|
||||
</data>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_account_installer" model="ir.actions.act_window">
|
||||
<field name="name">Accounting Modules Installation</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">account.installer</field>
|
||||
<field name="view_id" ref="view_account_installer"/>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<record id="account_installer_todo" model="ir.actions.todo">
|
||||
<field name="action_id" ref="action_account_installer"/>
|
||||
<field name="sequence">1</field>
|
||||
</record>
|
||||
</data>
|
||||
</openerp>
|
||||
@@ -349,6 +349,18 @@
|
||||
<field name="context">{'type':'out_invoice'}</field>
|
||||
<field name="search_view_id" ref="view_account_invoice_filter"/>
|
||||
</record>
|
||||
|
||||
<record id="action_invoice_tree_panding_invoice" model="ir.actions.act_window">
|
||||
<field name="name">Panding Invoice</field>
|
||||
<field name="res_model">account.invoice</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form,calendar,graph</field>
|
||||
<field name="view_id" ref="invoice_tree"/>
|
||||
<field name="context">{'type':'out_invoice'}</field>
|
||||
<field name="domain">[('state','=','draft')]</field>
|
||||
<!-- <field name="search_view_id" ref="view_account_invoice_filter"/>-->
|
||||
</record>
|
||||
|
||||
<record id="action_invoice_tree_view1" model="ir.actions.act_window.view">
|
||||
<field eval="1" name="sequence"/>
|
||||
<field name="view_mode">tree</field>
|
||||
@@ -360,7 +372,7 @@
|
||||
<field name="view_id" ref="invoice_form"/>
|
||||
<field name="act_window_id" ref="action_invoice_tree"/>
|
||||
</record>
|
||||
<menuitem action="action_invoice_tree" id="menu_finance_invoice" parent="account.menu_finance"/>
|
||||
<menuitem action="action_invoice_tree" id="menu_finance_invoice" parent="account.menu_finance" sequence="2"/>
|
||||
|
||||
<record id="action_invoice_tree1" model="ir.actions.act_window">
|
||||
<field name="name">Customer Invoices</field>
|
||||
|
||||
@@ -3,16 +3,17 @@
|
||||
<data>
|
||||
|
||||
<menuitem icon="terp-account" id="menu_finance" name="Financial Management"/>
|
||||
<menuitem id="menu_finance_configuration" name="Configuration" parent="menu_finance" sequence="1"/>
|
||||
<menuitem id="menu_finance_configuration" name="Configuration" parent="menu_finance" sequence="8"/>
|
||||
<menuitem id="base.menu_action_currency_form" parent="menu_finance_configuration" sequence="20"/>
|
||||
<menuitem id="menu_finance_accounting" name="Financial Accounting" parent="menu_finance_configuration"/>
|
||||
<menuitem id="menu_analytic_accounting" name="Analytic Accounting" parent="menu_finance_configuration"/>
|
||||
|
||||
<menuitem id="menu_finance_reporting" name="Reporting" parent="account.menu_finance" sequence="8"/>
|
||||
<menuitem id="menu_finance_legal_statement" name="Legal Statements" parent="account.menu_finance" sequence="8"/>
|
||||
<menuitem id="menu_finance_reporting" name="Reporting" parent="account.menu_finance" sequence="7"/>
|
||||
<menuitem id="menu_finance_generic_reporting" name="Generic Reporting" parent="account.menu_finance_reporting" sequence="1"/>
|
||||
<menuitem id="menu_finance_legal_statement" name="Legal Statements" parent="account.menu_finance_reporting" sequence="2"/>
|
||||
<menuitem id="menu_generic_report" name="Generic Reports" parent="account.menu_finance_legal_statement" sequence="8"/>
|
||||
|
||||
<menuitem id="menu_finance_entries" name="Making Entries" parent="account.menu_finance" sequence="2"
|
||||
<menuitem id="menu_finance_entries" name="Accounting" parent="account.menu_finance" sequence="1"
|
||||
groups="group_account_user"/>
|
||||
<menuitem id="account.menu_finance_recurrent_entries" name="Recurrent Entries" parent="account.menu_finance_entries" sequence="15"/>
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -294,7 +294,7 @@ class account_move_line(osv.osv):
|
||||
return [('id', '=', '0')]
|
||||
return [('id', 'in', [x[0] for x in res])]
|
||||
|
||||
def _invoice_search(self, cursor, user, obj, name, args):
|
||||
def _invoice_search(self, cursor, user, obj, name, args, context):
|
||||
if not len(args):
|
||||
return []
|
||||
invoice_obj = self.pool.get('account.invoice')
|
||||
|
||||
@@ -28,8 +28,8 @@
|
||||
|
||||
<menuitem
|
||||
id="menu_tax_report"
|
||||
name="Taxes Reports"
|
||||
parent="account.menu_finance_reporting"/>
|
||||
name="Taxes"
|
||||
parent="account.menu_finance_generic_reporting" sequence="3"/>
|
||||
|
||||
<wizard
|
||||
id="wizard_vat_declaration"
|
||||
|
||||
@@ -955,7 +955,7 @@
|
||||
<field name="view_id" ref="view_move_tree"/>
|
||||
<field name="search_view_id" ref="view_account_move_filter"/>
|
||||
</record>
|
||||
<menuitem id="next_id_29" name="Search Entries" parent="account.menu_finance_reporting"/>
|
||||
<menuitem id="next_id_29" name="Search Entries" parent="account.menu_finance_entries" sequence="40"/>
|
||||
<menuitem action="action_move_line_form" id="menu_action_move_line_form" parent="next_id_29"/>
|
||||
|
||||
<record id="action_move_line_form_encode_by_move" model="ir.actions.act_window">
|
||||
@@ -991,7 +991,7 @@
|
||||
</record>
|
||||
<menuitem action="action_move_line_search" id="menu_action_move_line_search" parent="account.next_id_29"/>
|
||||
|
||||
<menuitem id="menu_finance_charts" name="Charts" parent="account.menu_finance" sequence="7"/>
|
||||
<menuitem id="menu_finance_charts" name="Charts" parent="account.menu_finance" sequence="4"/>
|
||||
<wizard id="wizard_account_chart" menu="False" model="account.account" name="account.chart" string="Chart of Accounts"/>
|
||||
<menuitem icon="STOCK_INDENT" action="wizard_account_chart" id="menu_action_account_tree2" parent="account.menu_finance_charts" type="wizard"/>
|
||||
|
||||
@@ -1111,7 +1111,7 @@
|
||||
<field name="res_model">account.journal.period</field>
|
||||
<field name="view_type">tree</field>
|
||||
</record>
|
||||
<menuitem action="action_account_journal_period_tree" id="menu_action_account_journal_period_tree" parent="account.menu_finance_reporting"/>
|
||||
<menuitem action="action_account_journal_period_tree" id="menu_action_account_journal_period_tree" parent="account.menu_finance_generic_reporting" sequence="2"/>
|
||||
|
||||
|
||||
<!--
|
||||
@@ -1447,8 +1447,13 @@
|
||||
<field name="name">Account Configure wizard</field>
|
||||
<field name="model">account.config.wizard</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.res_config_view_base"/>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Account Configure">
|
||||
<data>
|
||||
<form position="attributes"><attribute name="string">
|
||||
Account Configure
|
||||
</attribute></form>
|
||||
<group string="res_config_contents" position="replace">
|
||||
<separator col="4" colspan="4" string="Create a Fiscal Year"/>
|
||||
<field name="name"/>
|
||||
<field name="code"/>
|
||||
@@ -1457,13 +1462,9 @@
|
||||
<field name="period" colspan="4"/>
|
||||
<separator col="4" colspan="4" string="Select Chart of Accounts"/>
|
||||
<field name="charts"/>
|
||||
<separator string="" colspan="4"/>
|
||||
<label string="" colspan="2"/>
|
||||
<group col="2" colspan="2">
|
||||
<button icon="gtk-cancel" special="cancel" string="Skip" name="action_cancel" type="object"/>
|
||||
<button icon="gtk-ok" name="action_create" string="Continue" type="object"/>
|
||||
</group>
|
||||
</form>
|
||||
</group>
|
||||
<xpath expr='//button[@name="action_skip"]' position="replace"/>
|
||||
</data>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -1471,11 +1472,16 @@
|
||||
<field name="name">Account Configure Wizard </field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">account.config.wizard</field>
|
||||
<field name="view_id" ref="view_account_config_wizard_form"/>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<!-- register configuration wizard -->
|
||||
<record id="config_fiscalyear" model="ir.actions.todo">
|
||||
<field name="action_id" ref="action_account_config_wizard_form"/>
|
||||
</record>
|
||||
|
||||
<record id="view_account_addtmpl_wizard_form" model="ir.ui.view">
|
||||
<field name="name">Account Add wizard</field>
|
||||
@@ -1500,16 +1506,6 @@
|
||||
src_model="account.account.template"
|
||||
view_type="form" view_mode="form"/>
|
||||
|
||||
<!-- register configuration wizard -->
|
||||
|
||||
<record id="config_fiscalyear" model="ir.actions.todo">
|
||||
<field name="name">Account Configure Wizard</field>
|
||||
<field name="note">Define Fiscal Years and Select Charts of Account</field>
|
||||
<field name="action_id" ref="action_account_config_wizard_form"/>
|
||||
</record>
|
||||
|
||||
|
||||
|
||||
<!-- Account Templates -->
|
||||
<menuitem
|
||||
id="account_template_folder"
|
||||
@@ -1586,6 +1582,8 @@
|
||||
<field name="property_account_payable"/>
|
||||
<field name="property_account_expense_categ" />
|
||||
<field name="property_account_income_categ"/>
|
||||
<field name="property_account_expense"/>
|
||||
<field name="property_account_income"/>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
@@ -1732,31 +1730,38 @@
|
||||
<field name="name">Generate Chart of Accounts from a Chart Template</field>
|
||||
<field name="model">wizard.multi.charts.accounts</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.res_config_view_base"/>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Generate Chart of Accounts from a Chart Template">
|
||||
<separator col="4" colspan="4" string="Generate Chart of Accounts from a Chart Template"/>
|
||||
<label align="0.0" string="This will automatically configure your chart of accounts, bank accounts, taxes and journals according to the selected template" colspan="4"/>
|
||||
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
|
||||
<field name ="code_digits" />
|
||||
<field name="chart_template_id"/>
|
||||
<field name ="seq_journal" />
|
||||
<field colspan="4" mode="tree" name="bank_accounts_id" nolabel="1" widget="one2many_list">
|
||||
<form string="Bank Information">
|
||||
<field name="acc_no"/>
|
||||
<field name="currency_id"/>
|
||||
</form>
|
||||
<tree editable="bottom" string="Bank Information">
|
||||
<field name="acc_no"/>
|
||||
<field name="currency_id"/>
|
||||
</tree>
|
||||
</field>
|
||||
<separator string="" colspan="4"/>
|
||||
<label string="" colspan="2"/>
|
||||
<group col="2" colspan="2">
|
||||
<button icon="gtk-cancel" special="cancel" type="object" name="action_cancel" string="Cancel"/>
|
||||
<button icon="gtk-ok" name="action_create" string="Create" type="object"/>
|
||||
</group>
|
||||
</form>
|
||||
<data>
|
||||
<form position="attributes"><attribute name="string">
|
||||
Generate Chart of Accounts from a Chart Template
|
||||
</attribute></form>
|
||||
<group string="res_config_contents" position="replace">
|
||||
<separator col="4" colspan="4" string="
|
||||
Generate Chart of Accounts from a Chart Template"/>
|
||||
<label align="0.0" colspan="4" string="
|
||||
This will automatically configure your chart of accounts,
|
||||
bank accounts, taxes and journals according to the selected
|
||||
template"/>
|
||||
<field name="company_id" widget="selection"
|
||||
groups="base.group_multi_company"/>
|
||||
<field name ="code_digits" />
|
||||
<field name="chart_template_id"/>
|
||||
<field name ="seq_journal" />
|
||||
<field colspan="4" mode="tree" name="bank_accounts_id"
|
||||
nolabel="1" widget="one2many_list">
|
||||
<form string="Bank Information">
|
||||
<field name="acc_no"/>
|
||||
<field name="currency_id"/>
|
||||
</form>
|
||||
<tree editable="bottom" string="Bank Information">
|
||||
<field name="acc_no"/>
|
||||
<field name="currency_id"/>
|
||||
</tree>
|
||||
</field>
|
||||
</group>
|
||||
<xpath expr='//button[@name="action_skip"]' position='replace'/>
|
||||
</data>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -1764,6 +1769,7 @@
|
||||
<field name="name">Generate Chart of Accounts from a Chart Template</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">wizard.multi.charts.accounts</field>
|
||||
<field name="view_id" ref="view_wizard_multi_chart"/>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
|
||||
<!-- Aged partner balance -->
|
||||
<wizard id="wizard_aged_trial_balance" menu="False" model="res.partner" name="account.aged.trial.balance" string="Aged Partner Balance"/>
|
||||
<menuitem id="next_id_22" name="Partner Accounts" parent="menu_finance_reporting"/>
|
||||
<menuitem id="next_id_22" name="Partner Accounts" parent="menu_finance_generic_reporting" sequence="1"/>
|
||||
<menuitem icon="STOCK_PRINT" action="wizard_aged_trial_balance" id="menu_aged_trial_balance" parent="next_id_22" type="wizard"/>
|
||||
|
||||
<!-- report-related wizards -->
|
||||
@@ -114,7 +114,7 @@
|
||||
|
||||
<wizard id="wizard_general_journal" menu="False" model="account.journal.period" name="account.general.journal.report" string="Print General Journal" />
|
||||
<menuitem icon="STOCK_PRINT" action="wizard_general_journal" id="menu_general_journal" parent="account.menu_generic_report" type="wizard" />
|
||||
|
||||
|
||||
<wizard id="wizard_invoice_currency_change" model="account.invoice" name="account.invoice.currency_change" string="Change Currency" groups="base.group_user"/>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
+16
-30
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -42,10 +42,10 @@ class company_setup(osv.osv_memory):
|
||||
* Insert a suitable message for Overdue Payment Report.
|
||||
"""
|
||||
_name='wizard.company.setup'
|
||||
_inherit = 'res.config'
|
||||
|
||||
_columns = {
|
||||
'company_id':fields.many2one('res.company','Company',required=True),
|
||||
'partner_id':fields.many2one('res.partner','Partner'),
|
||||
'overdue_msg': fields.text('Overdue Payment Message'),
|
||||
}
|
||||
def get_message(self,cr,uid,context={}):
|
||||
@@ -57,42 +57,28 @@ class company_setup(osv.osv_memory):
|
||||
|
||||
_defaults = {
|
||||
'company_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr,uid,[uid],c)[0].company_id.id,
|
||||
'partner_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr,uid,[uid],c)[0].company_id.partner_id.id,
|
||||
'overdue_msg': get_message,
|
||||
}
|
||||
|
||||
def onchange_company_id(self, cr, uid, ids, company, context=None):
|
||||
res = {}
|
||||
if not company:
|
||||
return {}
|
||||
comp_obj = self.pool.get('res.company').browse(cr,uid,company)
|
||||
res['partner_id'] = comp_obj.partner_id.id
|
||||
phone = comp_obj.partner_id.address and (comp_obj.partner_id.address[0].phone and ' at ' + str(comp_obj.partner_id.address[0].phone) + '.' or '.') or '.'
|
||||
res['overdue_msg'] = comp_obj.overdue_msg + str(phone)
|
||||
|
||||
return {'value': res }
|
||||
partner_address = comp_obj.partner_id.address
|
||||
if partner_address and partner_address[0].phone:
|
||||
msg_tail = ' at %s.'%(partner_address[0].phone)
|
||||
else:
|
||||
msg_tail = '.'
|
||||
|
||||
def action_create(self, cr, uid, ids, context=None):
|
||||
content_wiz = self.pool.get('wizard.company.setup').read(cr,uid,ids,['company_id','overdue_msg'])
|
||||
return {'value': {'overdue_msg': comp_obj.overdue_msg + msg_tail } }
|
||||
|
||||
def execute(self, cr, uid, ids, context=None):
|
||||
content_wiz = self.pool.get('wizard.company.setup')\
|
||||
.read(cr,uid,ids,['company_id','overdue_msg'])
|
||||
if content_wiz:
|
||||
wiz_data = content_wiz[0]
|
||||
self.pool.get('res.company').write(cr, uid, [wiz_data['company_id']], {'overdue_msg':wiz_data['overdue_msg']})
|
||||
|
||||
return {
|
||||
'view_type': 'form',
|
||||
"view_mode": 'form',
|
||||
'res_model': 'ir.actions.configuration.wizard',
|
||||
'type': 'ir.actions.act_window',
|
||||
'target':'new',
|
||||
}
|
||||
|
||||
def action_cancel(self,cr,uid,ids,conect=None):
|
||||
return {
|
||||
'view_type': 'form',
|
||||
"view_mode": 'form',
|
||||
'res_model': 'ir.actions.configuration.wizard',
|
||||
'type': 'ir.actions.act_window',
|
||||
'target':'new',
|
||||
}
|
||||
|
||||
self.pool.get('res.company').write(
|
||||
cr, uid,
|
||||
[wiz_data['company_id']],
|
||||
{'overdue_msg':wiz_data['overdue_msg']})
|
||||
company_setup()
|
||||
|
||||
@@ -22,17 +22,21 @@
|
||||
<field name="name">wizard.company.setup.form</field>
|
||||
<field name="model">wizard.company.setup</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.res_config_view_base"/>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Overdue Payment Report Message">
|
||||
<field name="company_id" select="1" on_change="onchange_company_id(company_id)" groups="base.group_multi_company"/>
|
||||
<field name="partner_id" select="1" readonly="1"/>
|
||||
<data>
|
||||
<form position="attributes"><attribute name="string">
|
||||
Overdue Payment Report Message
|
||||
</attribute></form>
|
||||
<group string="res_config_contents" position="replace">
|
||||
<field name="company_id" select="1"
|
||||
on_change="onchange_company_id(company_id)"
|
||||
groups="base.group_multi_company"/>
|
||||
<separator string="Message" colspan="4"/>
|
||||
<field name="overdue_msg" nolabel="1" colspan="4"/>
|
||||
<group col="2" colspan="4">
|
||||
<button icon="gtk-cancel" special="cancel" type="object" name="action_cancel" string="Cancel"/>
|
||||
<button icon="gtk-ok" name="action_create" string="Create" type="object"/>
|
||||
</group>
|
||||
</form>
|
||||
</group>
|
||||
<xpath expr='//button[@name="action_skip"]' position='replace'/>
|
||||
</data>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -40,6 +44,7 @@
|
||||
<field name="name">Overdue Payment Report Message</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">wizard.company.setup</field>
|
||||
<field name="view_id" ref="wizard_company_setup_form"/>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
@@ -48,8 +53,6 @@
|
||||
<!-- register configuration wizard -->
|
||||
|
||||
<record id="config_wizard_account_base_setup_form" model="ir.actions.todo">
|
||||
<field name="name">Overdue Payment Report Message</field>
|
||||
<field name="note">Specify The Message for the Overdue Payment Report.</field>
|
||||
<field name="action_id" ref="action_wizard_company_setup_form"/>
|
||||
</record>
|
||||
</data>
|
||||
|
||||
@@ -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-02-03 06:32+0000\n"
|
||||
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
|
||||
"PO-Revision-Date: 2010-01-15 14:07+0000\n"
|
||||
"Last-Translator: DenisD <denis_delismajlovic@yahoo.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: 2009-12-16 05:10+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-16 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -50,7 +50,7 @@ msgstr ""
|
||||
#. module: account
|
||||
#: model:account.account.type,name:account.account_type_asset
|
||||
msgid "Asset"
|
||||
msgstr ""
|
||||
msgstr "Sredstvo"
|
||||
|
||||
#. module: account
|
||||
#: constraint:ir.actions.act_window: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 16:45+0000\n"
|
||||
"Last-Translator: Kuvaly <kuvaly@seznam.cz>\n"
|
||||
"PO-Revision-Date: 2010-01-13 11:48+0000\n"
|
||||
"Last-Translator: Kuvaly [LCT] <kuvaly@seznam.cz>\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: 2009-12-16 05:10+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-14 04:49+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -50,7 +50,7 @@ msgstr ""
|
||||
#. module: account
|
||||
#: model:account.account.type,name:account.account_type_asset
|
||||
msgid "Asset"
|
||||
msgstr ""
|
||||
msgstr "Aktiva"
|
||||
|
||||
#. module: account
|
||||
#: constraint:ir.actions.act_window:0
|
||||
@@ -5850,7 +5850,7 @@ msgstr ""
|
||||
#. module: account
|
||||
#: field:account.analytic.account,code:0
|
||||
msgid "Account Code"
|
||||
msgstr ""
|
||||
msgstr "Kód účtu"
|
||||
|
||||
#. module: account
|
||||
#: help:account.config.wizard,name:0
|
||||
@@ -5901,7 +5901,7 @@ msgstr ""
|
||||
#. module: account
|
||||
#: field:account.journal.column,name:0
|
||||
msgid "Column Name"
|
||||
msgstr ""
|
||||
msgstr "Název sloupce"
|
||||
|
||||
#. module: account
|
||||
#: wizard_view:account.account.balance.report,checktype:0
|
||||
@@ -5909,12 +5909,12 @@ msgstr ""
|
||||
#: wizard_view:account.partner.balance.report,init:0
|
||||
#: wizard_view:account.third_party_ledger.report,init:0
|
||||
msgid "Filters"
|
||||
msgstr ""
|
||||
msgstr "Filtry"
|
||||
|
||||
#. module: account
|
||||
#: wizard_button:account.wizard_paid_open,init,yes:0
|
||||
msgid "Yes"
|
||||
msgstr ""
|
||||
msgstr "Ano"
|
||||
|
||||
#. module: account
|
||||
#: help:account.account,reconcile:0
|
||||
|
||||
@@ -7,13 +7,13 @@ msgstr ""
|
||||
"Project-Id-Version: OpenERP Server 5.0.1\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2009-12-08 14:44+0000\n"
|
||||
"PO-Revision-Date: 2010-01-14 09:09+0000\n"
|
||||
"Last-Translator: Olivier Dony (OpenERP) <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: 2009-12-16 05:11+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-15 04:34+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -25,7 +25,7 @@ msgstr "Écritures non réconciliées"
|
||||
#: model:ir.actions.wizard,name:account.wizard_unreconcile_select
|
||||
#: model:ir.ui.menu,name:account.menu_unreconcile_select
|
||||
msgid "Unreconcile entries"
|
||||
msgstr "Annuler lettrage d'un compte"
|
||||
msgstr "Dé-lettrer les écritures"
|
||||
|
||||
#. module: account
|
||||
#: wizard_view:account.aged.trial.balance,init:0
|
||||
@@ -126,12 +126,6 @@ msgstr "Écriture standard"
|
||||
msgid "No. of Digits to use for account code"
|
||||
msgstr "Nombre de chiffres dans les numéros des comptes"
|
||||
|
||||
#. module: account
|
||||
#: model:ir.actions.wizard,name:account.wizard_fiscalyear_close_state
|
||||
#: model:ir.ui.menu,name:account.menu_wizard_fy_close_state
|
||||
msgid "Close a Fiscal Year"
|
||||
msgstr "Clôturer un exercice fiscal"
|
||||
|
||||
#. module: account
|
||||
#: field:account.invoice,move_id:0
|
||||
msgid "Invoice Movement"
|
||||
@@ -1687,6 +1681,12 @@ msgstr "Compte de pertes et profits"
|
||||
msgid "Model"
|
||||
msgstr "Modèle"
|
||||
|
||||
#. module: account
|
||||
#: model:ir.actions.wizard,name:account.wizard_fiscalyear_close_state
|
||||
#: model:ir.ui.menu,name:account.menu_wizard_fy_close_state
|
||||
msgid "Close a Fiscal Year"
|
||||
msgstr "Clôturer un exercice fiscal"
|
||||
|
||||
#. module: account
|
||||
#: field:account.journal,centralisation:0
|
||||
msgid "Centralised counterpart"
|
||||
|
||||
+302
-298
File diff suppressed because it is too large
Load Diff
@@ -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-06 18:48+0000\n"
|
||||
"Last-Translator: eLBati <elbaddy@gmail.com>\n"
|
||||
"PO-Revision-Date: 2010-01-17 16:07+0000\n"
|
||||
"Last-Translator: Davide Corio <davide.corio@domsense.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-01-07 04:49+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-18 04:44+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -40,7 +40,7 @@ msgstr "Codifica delle registrazioni"
|
||||
#. module: account
|
||||
#: model:ir.actions.todo,note:account.config_wizard_account_base_setup_form
|
||||
msgid "Specify The Message for the Overdue Payment Report."
|
||||
msgstr ""
|
||||
msgstr "Specificare il messaggio per il Report Pagamenti Scaduti."
|
||||
|
||||
#. module: account
|
||||
#: model:process.transition,name:account.process_transition_confirmstatementfromdraft0
|
||||
@@ -73,11 +73,14 @@ msgid ""
|
||||
"This account will be used to value incoming stock for the current product "
|
||||
"category"
|
||||
msgstr ""
|
||||
"Questo conto verrà utilizzato per valorizzare le merci in entrata per la "
|
||||
"categoria di prodotti corrente"
|
||||
|
||||
#. module: account
|
||||
#: help:account.invoice,period_id:0
|
||||
msgid "Keep empty to use the period of the validation(invoice) date."
|
||||
msgstr ""
|
||||
"Lasciare vuoto per usare il periodo della data di validazione (fattura)."
|
||||
|
||||
#. module: account
|
||||
#: wizard_view:account.automatic.reconcile,reconcile:0
|
||||
@@ -115,7 +118,7 @@ msgstr "Mastro"
|
||||
#. module: account
|
||||
#: selection:account.move,type:0
|
||||
msgid "Journal Voucher"
|
||||
msgstr ""
|
||||
msgstr "Giornale Ricevute"
|
||||
|
||||
#. module: account
|
||||
#: field:account.invoice,residual:0
|
||||
@@ -128,7 +131,7 @@ msgstr "Rimanenze"
|
||||
#: field:account.tax.template,base_sign:0
|
||||
#: field:account.tax.template,ref_base_sign:0
|
||||
msgid "Base Code Sign"
|
||||
msgstr ""
|
||||
msgstr "Segno imponibile"
|
||||
|
||||
#. module: account
|
||||
#: model:ir.actions.wizard,name:account.wizard_unreconcile_select
|
||||
@@ -215,7 +218,7 @@ msgstr "Codice calcolo (se tipo=codice)"
|
||||
#: view:account.move:0
|
||||
#: view:account.move.line:0
|
||||
msgid "Account Entry Line"
|
||||
msgstr ""
|
||||
msgstr "Registrazione contabile"
|
||||
|
||||
#. module: account
|
||||
#: wizard_view:account.aged.trial.balance,init:0
|
||||
@@ -270,6 +273,11 @@ msgid ""
|
||||
"in which order. You can create your own view for a faster encoding in each "
|
||||
"journal."
|
||||
msgstr ""
|
||||
"Imposta la vista da utilizzare quando si inseriscono o si consultano le "
|
||||
"registrazioni in questo Giornale. La vista dice a Open ERP quali campi "
|
||||
"dovranno essere visibili, richiesti o di sola lettura e in quale ordine. "
|
||||
"Puoi creare la tua vista personale per velocizzare l'inserimento dei dati in "
|
||||
"ogni giornale."
|
||||
|
||||
#. module: account
|
||||
#: help:account.invoice,date_due: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-12-15 16:09+0000\n"
|
||||
"Last-Translator: Grzegorz Grzelak (Cirrus) <Unknown>\n"
|
||||
"PO-Revision-Date: 2010-01-16 18:36+0000\n"
|
||||
"Last-Translator: Andrzej MoST (Marcin Ostajewski) <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: 2009-12-16 05:12+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-17 04:46+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -1607,7 +1607,7 @@ msgstr "Nr konta"
|
||||
#: view:account.tax:0
|
||||
#: view:account.tax.template:0
|
||||
msgid "Keep empty to use the expense account"
|
||||
msgstr "Zostaw puste żeby używać konto wydatków"
|
||||
msgstr "Zostaw puste żeby używać konta kosztowego"
|
||||
|
||||
#. module: account
|
||||
#: wizard_field:account.automatic.reconcile,init,account_ids:0
|
||||
@@ -2600,7 +2600,7 @@ msgstr "Nazwa typu konta"
|
||||
#: help:account.tax.template,ref_tax_code_id:0
|
||||
#: help:account.tax.template,tax_code_id:0
|
||||
msgid "Use this code for the VAT declaration."
|
||||
msgstr "Urzyj ten kod do deklaracji VAT-a."
|
||||
msgstr "Użyj tego kodu do deklaracji VAT."
|
||||
|
||||
#. module: account
|
||||
#: field:account.move.line,blocked: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-12-07 18:34+0000\n"
|
||||
"Last-Translator: Pedro_Maschio <pedro.bicudo@tgtconsult.com.br>\n"
|
||||
"PO-Revision-Date: 2010-01-14 10:44+0000\n"
|
||||
"Last-Translator: Carlos Paiva <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: 2009-12-16 05:13+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-15 04:34+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -793,7 +793,7 @@ msgstr "Posição"
|
||||
#: rml:account.analytic.account.cost_ledger:0
|
||||
#: rml:account.analytic.account.quantity_cost_ledger:0
|
||||
msgid "Period to"
|
||||
msgstr "Período para"
|
||||
msgstr "Período até"
|
||||
|
||||
#. module: account
|
||||
#: field:account.account.type,partner_account:0
|
||||
@@ -1969,7 +1969,7 @@ msgstr "Ordenar por"
|
||||
#. module: account
|
||||
#: field:account.move,to_check:0
|
||||
msgid "To Be Verified"
|
||||
msgstr "Para ser verificado"
|
||||
msgstr "Pendente de Verificação"
|
||||
|
||||
#. module: account
|
||||
#: help:res.partner,debit:0
|
||||
@@ -3774,7 +3774,7 @@ msgstr "Inscriçãoda conta"
|
||||
#: field:account.move.line,date_maturity:0
|
||||
#: rml:account.overdue:0
|
||||
msgid "Maturity date"
|
||||
msgstr "Dada de vencimento"
|
||||
msgstr "Data de vencimento"
|
||||
|
||||
#. module: account
|
||||
#: view:account.subscription: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-12-23 08:28+0000\n"
|
||||
"Last-Translator: Andrei Andreyanau <Unknown>\n"
|
||||
"PO-Revision-Date: 2010-01-15 22:28+0000\n"
|
||||
"Last-Translator: Alex Mr.Brightside Demurine <extrimall90@mail.ru>\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: 2009-12-24 04:40+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-16 04:35+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -1696,7 +1696,7 @@ msgstr "Расходы и доходы"
|
||||
#. module: account
|
||||
#: constraint:account.account:0
|
||||
msgid "Error ! You can not create recursive accounts."
|
||||
msgstr ""
|
||||
msgstr "Ошибка! Вы не можете создать рекурсивные счета."
|
||||
|
||||
#. module: account
|
||||
#: rml:account.tax.code.entries:0
|
||||
@@ -1831,7 +1831,7 @@ msgstr "Персональный менеджер"
|
||||
#. module: account
|
||||
#: rml:account.analytic.account.journal:0
|
||||
msgid "to :"
|
||||
msgstr ""
|
||||
msgstr "к :"
|
||||
|
||||
#. module: account
|
||||
#: wizard_field:account.move.line.reconcile,init_full,debit:0
|
||||
@@ -1931,7 +1931,7 @@ msgstr "Позиция счета подписки"
|
||||
#: selection:account.partner.balance.report,init,state:0
|
||||
#: selection:account.third_party_ledger.report,init,state:0
|
||||
msgid "No Filter"
|
||||
msgstr ""
|
||||
msgstr "Без Фильтра"
|
||||
|
||||
#. module: account
|
||||
#: field:account.payment.term.line,days:0
|
||||
@@ -1997,7 +1997,7 @@ msgstr "Неправильный XML для просмотра архитект
|
||||
#. module: account
|
||||
#: wizard_field:account.partner.balance.report,init,date1:0
|
||||
msgid " Start date"
|
||||
msgstr ""
|
||||
msgstr " Начать дату"
|
||||
|
||||
#. module: account
|
||||
#: wizard_view:account.analytic.account.journal.report,init:0
|
||||
|
||||
+14
-11
@@ -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-17 03:24+0000\n"
|
||||
"Last-Translator: pdqt <Unknown>\n"
|
||||
"PO-Revision-Date: 2010-01-11 07:51+0000\n"
|
||||
"Last-Translator: Nguyễn Thịnh <thinhnverp@gmail.com>\n"
|
||||
"Language-Team: Vietnamese <vi@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: 2009-12-18 04:32+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-01-12 04:46+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: account
|
||||
@@ -73,34 +73,35 @@ msgstr ""
|
||||
msgid ""
|
||||
"This account will be used to value incoming stock for the current product "
|
||||
"category"
|
||||
msgstr ""
|
||||
msgstr "tài khoản này sẽ được dùng cho giá của sản phẩm đưa vào danh mục"
|
||||
|
||||
#. module: account
|
||||
#: help:account.invoice,period_id:0
|
||||
msgid "Keep empty to use the period of the validation(invoice) date."
|
||||
msgstr ""
|
||||
"Giữ sản phẩm nào để sử dụng khoảng thời gian xác nhận của (hoá đơn) ngày"
|
||||
|
||||
#. module: account
|
||||
#: wizard_view:account.automatic.reconcile,reconcile:0
|
||||
msgid "Reconciliation result"
|
||||
msgstr ""
|
||||
msgstr "kết quả hòa giả"
|
||||
|
||||
#. module: account
|
||||
#: model:ir.actions.act_window,name:account.act_account_acount_move_line_open_unreconciled
|
||||
msgid "Unreconciled entries"
|
||||
msgstr ""
|
||||
msgstr "không thể hòa giải"
|
||||
|
||||
#. module: account
|
||||
#: field:account.invoice.tax,base_code_id:0
|
||||
#: field:account.tax,base_code_id:0
|
||||
#: field:account.tax.template,base_code_id:0
|
||||
msgid "Base Code"
|
||||
msgstr ""
|
||||
msgstr "mã số cơ bản"
|
||||
|
||||
#. module: account
|
||||
#: view:account.account:0
|
||||
msgid "Account Statistics"
|
||||
msgstr ""
|
||||
msgstr "thống kê tài chính"
|
||||
|
||||
#. module: account
|
||||
#: model:ir.actions.wizard,name:account.wizard_vat_declaration
|
||||
@@ -121,7 +122,7 @@ msgstr ""
|
||||
#. module: account
|
||||
#: field:account.invoice,residual:0
|
||||
msgid "Residual"
|
||||
msgstr ""
|
||||
msgstr "số dư"
|
||||
|
||||
#. module: account
|
||||
#: field:account.tax,base_sign:0
|
||||
@@ -610,6 +611,8 @@ msgid ""
|
||||
"The sequence field is used to order the resources from lower sequences to "
|
||||
"higher ones"
|
||||
msgstr ""
|
||||
"Các lĩnh vực chuỗi được dùng để sắp các nguồn lực từ các chuỗi thấp hơn cho "
|
||||
"những người cao"
|
||||
|
||||
#. module: account
|
||||
#: wizard_view:account.analytic.account.chart,init:0
|
||||
@@ -657,12 +660,12 @@ msgstr ""
|
||||
#. module: account
|
||||
#: help:account.fiscalyear,company_id:0
|
||||
msgid "Keep empty if the fiscal year belongs to several companies."
|
||||
msgstr ""
|
||||
msgstr "Hãy bỏ trống nếu năm tài chính thuộc về một số công ty"
|
||||
|
||||
#. module: account
|
||||
#: model:ir.ui.menu,name:account.menu_analytic_accounting
|
||||
msgid "Analytic Accounting"
|
||||
msgstr ""
|
||||
msgstr "phân tích tài chính kế toán"
|
||||
|
||||
#. module: account
|
||||
#: rml:account.overdue:0
|
||||
|
||||
@@ -0,0 +1,38 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# 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
|
||||
# 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
|
||||
|
||||
class account_installer(osv.osv_memory):
|
||||
_name = 'account.installer'
|
||||
_inherit = 'res.config.installer'
|
||||
|
||||
_columns = {
|
||||
# Accounting
|
||||
'account_analytic_default':fields.boolean('Analytic Accounting'),
|
||||
'account_analytic_plans':fields.boolean('Multiple Analytic Plans'),
|
||||
'account_payment':fields.boolean('Suppliers Payment Management'),
|
||||
'account_followup':fields.boolean('Followups Management'),
|
||||
'account_asset':fields.boolean('Assets Management')
|
||||
}
|
||||
_defaults = {
|
||||
'account_analytic_default':True,
|
||||
}
|
||||
account_installer()
|
||||
+29
-20
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -29,17 +29,17 @@ from mx.DateTime import RelativeDateTime
|
||||
from tools import config
|
||||
from tools.translate import _
|
||||
|
||||
class fiscalyear_seq(osv.osv):
|
||||
_name = "fiscalyear.seq"
|
||||
_description = "Maintains Invoice sequences with Fiscal Year"
|
||||
_rec_name = 'fiscalyear_id'
|
||||
_columns = {
|
||||
'journal_id': fields.many2one('account.journal', 'Journal'),
|
||||
'fiscalyear_id': fields.many2one('account.fiscalyear', 'Fiscal Year',required=True),
|
||||
'sequence_id':fields.many2one('ir.sequence', 'Sequence',required=True),
|
||||
}
|
||||
|
||||
fiscalyear_seq()
|
||||
#class fiscalyear_seq(osv.osv):
|
||||
# _name = "fiscalyear.seq"
|
||||
# _description = "Maintains Invoice sequences with Fiscal Year"
|
||||
# _rec_name = 'fiscalyear_id'
|
||||
# _columns = {
|
||||
# 'journal_id': fields.many2one('account.journal', 'Journal'),
|
||||
# 'fiscalyear_id': fields.many2one('account.fiscalyear', 'Fiscal Year',required=True),
|
||||
# 'sequence_id':fields.many2one('ir.sequence', 'Sequence',required=True),
|
||||
# }
|
||||
#
|
||||
#fiscalyear_seq()
|
||||
|
||||
class account_invoice(osv.osv):
|
||||
def _amount_all(self, cr, uid, ids, name, args, context=None):
|
||||
@@ -153,7 +153,9 @@ class account_invoice(osv.osv):
|
||||
if not move_lines:
|
||||
res[id] = []
|
||||
continue
|
||||
res[id] = []
|
||||
data_lines = self.pool.get('account.move.line').browse(cr,uid,move_lines)
|
||||
partial_ids = []# Keeps the track of ids where partial payments are done with payment terms
|
||||
for line in data_lines:
|
||||
ids_line = []
|
||||
if line.reconcile_id:
|
||||
@@ -161,7 +163,8 @@ class account_invoice(osv.osv):
|
||||
elif line.reconcile_partial_id:
|
||||
ids_line = line.reconcile_partial_id.line_partial_ids
|
||||
l = map(lambda x: x.id, ids_line)
|
||||
res[id]=[x for x in l if x <> line.id]
|
||||
partial_ids.append(line.id)
|
||||
res[id] =[x for x in l if x <> line.id and x not in partial_ids]
|
||||
return res
|
||||
|
||||
def _get_invoice_line(self, cr, uid, ids, context=None):
|
||||
@@ -183,11 +186,14 @@ class account_invoice(osv.osv):
|
||||
src = []
|
||||
lines = []
|
||||
for m in self.pool.get('account.move.line').browse(cr, uid, moves, context):
|
||||
temp_lines = []#Added temp list to avoid duplicate records
|
||||
if m.reconcile_id:
|
||||
lines += map(lambda x: x.id, m.reconcile_id.line_id)
|
||||
temp_lines = map(lambda x: x.id, m.reconcile_id.line_id)
|
||||
elif m.reconcile_partial_id:
|
||||
lines += map(lambda x: x.id, m.reconcile_partial_id.line_partial_ids)
|
||||
temp_lines = map(lambda x: x.id, m.reconcile_partial_id.line_partial_ids)
|
||||
lines += [x for x in temp_lines if x not in lines]
|
||||
src.append(m.id)
|
||||
|
||||
lines = filter(lambda x: x not in src, lines)
|
||||
result[invoice.id] = lines
|
||||
return result
|
||||
@@ -415,7 +421,7 @@ class account_invoice(osv.osv):
|
||||
def onchange_currency_id(self, cr, uid, ids, curr_id, company_id):
|
||||
if curr_id:
|
||||
currency = self.pool.get('res.currency').browse(cr, uid, curr_id)
|
||||
if currency.company_id != company_id:
|
||||
if currency.company_id.id != company_id:
|
||||
raise osv.except_osv(_('Configration Error !'),
|
||||
_('Can not select currency that is not related to current company.\nPlease select accordingly !.'))
|
||||
return {}
|
||||
@@ -991,14 +997,17 @@ class account_invoice(osv.osv):
|
||||
else:
|
||||
amount_currency = False
|
||||
currency_id = False
|
||||
|
||||
if invoice.type in ('in_invoice', 'in_refund'):
|
||||
ref = invoice.reference
|
||||
else:
|
||||
ref = self._convert_ref(cr, uid, invoice.number)
|
||||
# Pay attention to the sign for both debit/credit AND amount_currency
|
||||
l1 = {
|
||||
'debit': direction * pay_amount>0 and direction * pay_amount,
|
||||
'credit': direction * pay_amount<0 and - direction * pay_amount,
|
||||
'account_id': src_account_id,
|
||||
'partner_id': invoice.partner_id.id,
|
||||
'ref':invoice.number,
|
||||
'ref':ref,
|
||||
'date': date,
|
||||
'currency_id':currency_id,
|
||||
'amount_currency':amount_currency and direction * amount_currency or 0.0,
|
||||
@@ -1009,7 +1018,7 @@ class account_invoice(osv.osv):
|
||||
'credit': direction * pay_amount>0 and direction * pay_amount,
|
||||
'account_id': pay_account_id,
|
||||
'partner_id': invoice.partner_id.id,
|
||||
'ref':invoice.number,
|
||||
'ref':ref,
|
||||
'date': date,
|
||||
'currency_id':currency_id,
|
||||
'amount_currency':amount_currency and - direction * amount_currency or 0.0,
|
||||
@@ -1022,7 +1031,7 @@ class account_invoice(osv.osv):
|
||||
l2['name'] = name
|
||||
|
||||
lines = [(0, 0, l1), (0, 0, l2)]
|
||||
move = {'ref': invoice.number, 'line_id': lines, 'journal_id': pay_journal_id, 'period_id': period_id, 'date': date}
|
||||
move = {'ref': ref, 'line_id': lines, 'journal_id': pay_journal_id, 'period_id': period_id, 'date': date}
|
||||
move_id = self.pool.get('account.move').create(cr, uid, move, context=context)
|
||||
|
||||
line_ids = []
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -117,7 +117,7 @@ class res_partner(osv.osv):
|
||||
res[pid][maps[type]] = (type=='receivable') and val or -val
|
||||
return res
|
||||
|
||||
def _credit_search(self, cr, uid, obj, name, args):
|
||||
def _credit_search(self, cr, uid, obj, name, args, context):
|
||||
if not len(args):
|
||||
return []
|
||||
where = ' and '.join(map(lambda x: '(sum(debit-credit)'+x[1]+str(x[2])+')',args))
|
||||
@@ -128,7 +128,7 @@ class res_partner(osv.osv):
|
||||
return [('id','=','0')]
|
||||
return [('id','in',map(lambda x:x[0], res))]
|
||||
|
||||
def _debit_search(self, cr, uid, obj, name, args):
|
||||
def _debit_search(self, cr, uid, obj, name, args, context):
|
||||
if not len(args):
|
||||
return []
|
||||
query = self.pool.get('account.move.line')._query_get(cr, uid, context={})
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -129,7 +129,7 @@
|
||||
<wizard id="wizard_analytic_account_chart" menu="False" model="account.analytic.account" name="account.analytic.account.chart" string="Analytic Chart of Accounts"/>
|
||||
<menuitem icon="STOCK_INDENT" action="wizard_analytic_account_chart" id="menu_action_analytic_account_tree2" parent="account.menu_finance_charts" type="wizard"/>
|
||||
|
||||
<menuitem id="next_id_40" name="Analytic" parent="account.menu_finance_reporting"/>
|
||||
<menuitem id="next_id_40" name="Analytic" parent="account.menu_finance_generic_reporting" sequence="4"/>
|
||||
<menuitem action="action_account_analytic_account_tree2" id="account_analytic_chart_balance" parent="next_id_40"/>
|
||||
|
||||
<record id="view_account_analytic_line_form" model="ir.ui.view">
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -16,7 +16,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/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
@@ -47,15 +47,15 @@ def _record_to_report_line(record):
|
||||
}
|
||||
|
||||
class account_tax_code_report(rml_parse.rml_parse):
|
||||
#_name = 'report.account.tax.code.entries'
|
||||
|
||||
_name = 'report.account.tax.code.entries'
|
||||
|
||||
def __init__(self, cr, uid, name, context):
|
||||
super(account_tax_code_report, self).__init__(cr, uid, name, context=context)
|
||||
self.localcontext.update({
|
||||
'time': time,
|
||||
'get_line':self.get_line,
|
||||
})
|
||||
|
||||
|
||||
def get_line(self, obj):
|
||||
line_ids = self.pool.get('account.move.line').search(self.cr, self.uid, [('tax_code_id','=',obj.id)])
|
||||
if not line_ids: return []
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -82,7 +82,6 @@
|
||||
"access_account_fiscal_position","account.fiscal.position all","model_account_fiscal_position","base.group_user",1,0,0,0
|
||||
"access_account_fiscal_position_tax","account.fiscal.position.tax all","model_account_fiscal_position_tax","base.group_user",1,0,0,0
|
||||
"access_account_fiscal_position_account","account.fiscal.position all","model_account_fiscal_position_account","base.group_user",1,0,0,0
|
||||
"access_fiscalyear_seq","fiscalyear.seq","model_fiscalyear_seq","account.group_account_invoice",1,1,1,1
|
||||
"access_account_fiscal_position_template","account.fiscal.position.template","model_account_fiscal_position_template","account.group_account_manager",1,1,1,1
|
||||
"access_account_fiscal_position_tax_template","account.fiscal.position.tax.template","model_account_fiscal_position_tax_template","account.group_account_manager",1,1,1,1
|
||||
"access_account_fiscal_position_account_template","account.fiscal.position.account.template","model_account_fiscal_position_account_template","account.group_account_manager",1,1,1,1
|
||||
|
||||
|
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -79,10 +79,12 @@ def _data_save(self, cr, uid, data, context):
|
||||
if move_ids:
|
||||
raise wizard.except_wizard(_('UserError'),
|
||||
_('The opening journal must not have any entry in the new fiscal year !'))
|
||||
|
||||
|
||||
query = "SELECT id FROM account_fiscalyear WHERE date_stop < '" + str(new_fyear.date_start) + "'"
|
||||
cr.execute(query)
|
||||
result = cr.dictfetchall()
|
||||
fy_ids = ','.join([str(x['id']) for x in result])
|
||||
query_line = pool.get('account.move.line')._query_get(cr, uid,
|
||||
obj='account_move_line', context={'fiscalyear': fy_id})
|
||||
obj='account_move_line', context={'fiscalyear': fy_ids})
|
||||
cr.execute('select id from account_account WHERE active')
|
||||
ids = map(lambda x: x[0], cr.fetchall())
|
||||
for account in pool.get('account.account').browse(cr, uid, ids,
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -58,15 +58,35 @@ def _search_invoices(obj, cr, uid, data, context):
|
||||
journal_obj = pool.get('account.journal')
|
||||
|
||||
statement = statement_obj.browse(cr, uid, data['id'], context=context)
|
||||
args_move_line = []
|
||||
repeated_move_line_ids = []
|
||||
# Creating a group that is unique for importing move lines(move lines, once imported into statement lines, should not appear again)
|
||||
for st_line in statement.line_ids:
|
||||
args_move_line = []
|
||||
args_move_line.append(('name','=', st_line.name))
|
||||
args_move_line.append(('ref','=',st_line.ref))
|
||||
if st_line.partner_id:
|
||||
args_move_line.append(('partner_id','=',st_line.partner_id.id))
|
||||
args_move_line.append(('account_id','=',st_line.account_id.id))
|
||||
|
||||
move_line_id = line_obj.search(cr, uid, args_move_line,context=context)
|
||||
if move_line_id:
|
||||
repeated_move_line_ids.append(move_line_id)
|
||||
|
||||
journal_ids = data['form']['journal_id'][0][2]
|
||||
|
||||
if journal_ids == []:
|
||||
journal_ids = journal_obj.search(cr, uid, [('type', 'in', ('sale','cash','purchase'))], context=context)
|
||||
|
||||
line_ids = line_obj.search(cr, uid, [
|
||||
|
||||
args = [
|
||||
('reconcile_id', '=', False),
|
||||
('journal_id', 'in', journal_ids),
|
||||
('account_id.reconcile', '=', True)],
|
||||
('account_id.reconcile', '=', True)]
|
||||
|
||||
if repeated_move_line_ids:
|
||||
args.append(('id','not in',repeated_move_line_ids))
|
||||
|
||||
line_ids = line_obj.search(cr, uid, args,
|
||||
#order='date DESC, id DESC', #doesn't work
|
||||
context=context)
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
@@ -29,7 +29,7 @@ import pooler
|
||||
|
||||
_subscription_form = '''<?xml version="1.0"?>
|
||||
<form string="%s">
|
||||
<seperator string="Generate entries before:" colspan="4"/>
|
||||
<separator string="Generate entries before:" colspan="4"/>
|
||||
<field name="date"/>
|
||||
</form>''' % ('Subscription Compute',)
|
||||
|
||||
@@ -38,7 +38,7 @@ _subscription_fields = {
|
||||
}
|
||||
|
||||
class wiz_subscription(wizard.interface):
|
||||
def _action_generate(self, cr, uid, data, context):
|
||||
def _action_generate(self, cr, uid, data, context={}):
|
||||
cr.execute('select id from account_subscription_line where date<%s and move_id is null', (data['form']['date'],))
|
||||
ids = map(lambda x: x[0], cr.fetchall())
|
||||
pooler.get_pool(cr.dbname).get('account.subscription.line').move_create(cr, uid, ids)
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# 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
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user