[MERGE] sync with latest trunk

bzr revid: odo@openerp.com-20110929110856-tto1jwqaievdr3d4
This commit is contained in:
Olivier Dony 2011-09-29 13:08:56 +02:00
commit b4d35641bd
699 changed files with 59589 additions and 30288 deletions

View File

@ -98,6 +98,7 @@ module named account_voucher.
'wizard/account_reconcile_view.xml',
'wizard/account_reconcile_partner_process_view.xml',
'wizard/account_automatic_reconcile_view.xml',
'wizard/account_financial_report_view.xml',
'project/wizard/project_account_analytic_line_view.xml',
'account_end_fy.xml',
'account_invoice_view.xml',

View File

@ -139,7 +139,7 @@ class account_account_type(osv.osv):
'Balance' will generally be used for cash accounts.
'Detail' will copy each existing journal item of the previous year, even the reconciled ones.
'Unreconciled' will copy only the journal items that were unreconciled on the first day of the new fiscal year."""),
'sign': fields.selection([(-1, 'Negative'), (1, 'Positive')], 'Sign on Reports', required=True, help='Allows you to change the sign of the balance amount displayed in the reports, so that you can see positive figures instead of negative ones in expenses accounts.'),
'sign': fields.selection([(-1, 'Reverse balance sign'), (1, 'Preserve balance sign')], 'Sign on Reports', required=True, help='For accounts that are typically more debited than credited and that you would like to print as negative amounts in your reports, you should reverse the sign of the balance; e.g.: Expense account. The same applies for accounts that are typically more credited than debited and that you would like to print as positive amounts in your reports; e.g.: Income account.'),
'report_type':fields.selection([
('none','/'),
('income','Profit & Loss (Income Accounts)'),
@ -250,6 +250,7 @@ class account_account(osv.osv):
#compute for each account the balance/debit/credit from the move lines
accounts = {}
res = {}
null_result = dict((fn, 0.0) for fn in field_names)
if children_and_consolidated:
aml_query = self.pool.get('account.move.line')._query_get(cr, uid, context=context)
@ -306,12 +307,11 @@ class account_account(osv.osv):
sums[current.id][fn] += sums[child.id][fn]
else:
sums[current.id][fn] += currency_obj.compute(cr, uid, child.company_id.currency_id.id, current.company_id.currency_id.id, sums[child.id][fn], context=context)
null_result = dict((fn, 0.0) for fn in field_names)
for id in ids:
res[id] = sums.get(id, null_result)
else:
for id in ids:
res[id] = 0.0
res[id] = null_result
return res
def _get_company_currency(self, cr, uid, ids, field_name, arg, context=None):
@ -431,9 +431,16 @@ class account_account(osv.osv):
return False
return True
def _check_account_type(self, cr, uid, ids, context=None):
for account in self.browse(cr, uid, ids, context=context):
if account.type in ('receivable', 'payable') and account.user_type.close_method != 'unreconciled':
return False
return True
_constraints = [
(_check_recursion, 'Error ! You can not create recursive accounts.', ['parent_id']),
(_check_type, 'Configuration Error! \nYou cannot define children to an account with internal type different of "View"! ', ['type']),
(_check_type, 'Configuration Error! \nYou can not define children to an account with internal type different of "View"! ', ['type']),
(_check_account_type, 'Configuration Error! \nYou can not select an account type with a deferral method different of "Unreconciled" for accounts with internal type "Payable/Receivable"! ', ['user_type','type']),
]
_sql_constraints = [
('code_company_uniq', 'unique (code,company_id)', 'The code of the account must be unique per company !')
@ -509,14 +516,14 @@ class account_account(osv.osv):
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.'))
raise osv.except_osv(_('Error !'), _('You can not desactivate an account that contains some journal items.'))
elif method == 'unlink':
raise osv.except_osv(_('Error !'), _('You cannot remove an account which has account entries!. '))
raise osv.except_osv(_('Error !'), _('You can not remove an account containing journal items!. '))
#Checking whether the account is set as a property to any Partner or not
value = 'account.account,' + str(ids[0])
partner_prop_acc = self.pool.get('ir.property').search(cr, uid, [('value_reference','=',value)], context=context)
if partner_prop_acc:
raise osv.except_osv(_('Warning !'), _('You cannot remove/deactivate an account which is set as a property to any Partner.'))
raise osv.except_osv(_('Warning !'), _('You can not remove/desactivate an account which is set on a customer or supplier.'))
return True
def _check_allow_type_change(self, cr, uid, ids, new_type, context=None):
@ -529,15 +536,20 @@ class account_account(osv.osv):
if line_obj.search(cr, uid, [('account_id', 'in', account_ids)]):
#Check for 'Closed' type
if old_type == 'closed' and new_type !='closed':
raise osv.except_osv(_('Warning !'), _("You cannot change the type of account from 'Closed' to any other type which contains account entries!"))
raise osv.except_osv(_('Warning !'), _("You cannot change the type of account from 'Closed' to any other type which contains journal items!"))
#Check for change From group1 to group2 and vice versa
if (old_type in group1 and new_type in group2) or (old_type in group2 and new_type in group1):
raise osv.except_osv(_('Warning !'), _("You cannot change the type of account from '%s' to '%s' type as it contains account entries!") % (old_type,new_type,))
raise osv.except_osv(_('Warning !'), _("You cannot change the type of account from '%s' to '%s' type as it contains journal items!") % (old_type,new_type,))
return True
def write(self, cr, uid, ids, vals, context=None):
if context is None:
context = {}
if not ids:
return True
if isinstance(ids, (int, long)):
ids = [ids]
# Dont allow changing the company_id when account_move_line already exist
if 'company_id' in vals:
@ -623,7 +635,7 @@ class account_journal(osv.osv):
'currency': fields.many2one('res.currency', 'Currency', help='The currency used to enter statement'),
'entry_posted': fields.boolean('Skip \'Draft\' State for Manual Entries', help='Check this box if you don\'t want new journal entries to pass through the \'draft\' state and instead goes directly to the \'posted state\' without any manual validation. \nNote that journal entries that are automatically created by the system are always skipping that state.'),
'company_id': fields.many2one('res.company', 'Company', required=True, select=1, help="Company related to this journal"),
'allow_date':fields.boolean('Check Date not in the Period', help= 'If set to True then do not accept the entry if the entry date is not into the period dates'),
'allow_date':fields.boolean('Check Date in Period', help= 'If set to True then do not accept the entry if the entry date is not into the period dates'),
}
_defaults = {
@ -650,11 +662,13 @@ class account_journal(osv.osv):
def write(self, cr, uid, ids, vals, context=None):
if context is None:
context = {}
if isinstance(ids, (int, long)):
ids = [ids]
for journal in self.browse(cr, uid, ids, context=context):
if 'company_id' in vals and journal.company_id.id != vals['company_id']:
move_lines = self.pool.get('account.move.line').search(cr, uid, [('journal_id', 'in', ids)])
if move_lines:
raise osv.except_osv(_('Warning !'), _('You cannot modify company of this journal as its related record exist in Entry Lines'))
raise osv.except_osv(_('Warning !'), _('You can not modify the company of this journal as its related record exist in journal items'))
return super(account_journal, self).write(cr, uid, ids, vals, context=context)
def create_sequence(self, cr, uid, vals, context=None):
@ -708,8 +722,6 @@ class account_journal(osv.osv):
name = rs.name
if rs.currency:
name = "%s (%s)" % (rs.name, rs.currency.name)
else:
name = "%s (%s)" % (rs.name, rs.company_id.currency_id.name)
res += [(rs.id, name)]
return res
@ -800,8 +812,8 @@ class account_fiscalyear(osv.osv):
return True
_constraints = [
(_check_duration, 'Error! The duration of the Fiscal Year is invalid. ', ['date_stop']),
(_check_fiscal_year, 'Error! You cannot define overlapping fiscal years',['date_start', 'date_stop'])
(_check_duration, 'Error! The start date of the fiscal year must be before his end date.', ['date_start','date_stop']),
(_check_fiscal_year, 'Error! You can not define overlapping fiscal years for the same company.',['date_start', 'date_stop'])
]
def create_period3(self, cr, uid, ids, context=None):
@ -879,7 +891,10 @@ class account_period(osv.osv):
'state': 'draft',
}
_order = "date_start, special desc"
_sql_constraints = [
('name_company_uniq', 'unique(name, company_id)', 'The name of the period must be unique per company!'),
]
def _check_duration(self,cr,uid,ids,context=None):
obj_period = self.browse(cr, uid, ids[0], context=context)
if obj_period.date_stop < obj_period.date_start:
@ -915,17 +930,10 @@ class account_period(osv.osv):
return False
def find(self, cr, uid, dt=None, context=None):
if context is None: context = {}
if not dt:
dt = time.strftime('%Y-%m-%d')
#CHECKME: shouldn't we check the state of the period?
args = [('date_start', '<=' ,dt), ('date_stop', '>=', dt)]
if context.get('company_id', False):
args.append(('company_id', '=', context['company_id']))
else:
company_id = self.pool.get('res.users').browse(cr, uid, uid, context=context).company_id.id
args.append(('company_id', '=', company_id))
ids = self.search(cr, uid, args, context=context)
ids = self.search(cr, uid, [('date_start','<=',dt),('date_stop','>=',dt)])
if not ids:
raise osv.except_osv(_('Error !'), _('No period defined for this date: %s !\nPlease create one.')%dt)
return ids
@ -952,7 +960,7 @@ class account_period(osv.osv):
if 'company_id' in vals:
move_lines = self.pool.get('account.move.line').search(cr, uid, [('period_id', 'in', ids)])
if move_lines:
raise osv.except_osv(_('Warning !'), _('You cannot modify company of this period as its related record exist in Entry Lines'))
raise osv.except_osv(_('Warning !'), _('You can not modify company of this period as some journal items exists.'))
return super(account_period, self).write(cr, uid, ids, vals, context=context)
def build_ctx_periods(self, cr, uid, period_from_id, period_to_id):
@ -1180,10 +1188,10 @@ class account_move(osv.osv):
_constraints = [
(_check_centralisation,
'You cannot create more than one move per period on centralized journal',
'You can not create more than one move per period on centralized journal',
['journal_id']),
(_check_period_journal,
'You cannot create entries on different periods/journals in the same move',
'You can not create journal items on different periods/journals in the same journal entry',
['line_id']),
]
@ -1194,7 +1202,7 @@ class account_move(osv.osv):
valid_moves = self.validate(cr, uid, ids, context)
if not valid_moves:
raise osv.except_osv(_('Integrity Error !'), _('You cannot validate a non-balanced entry !\nMake sure you have configured Payment Term properly !\nIt should contain atleast one Payment Term Line with type "Balance" !'))
raise osv.except_osv(_('Integrity Error !'), _('You can not validate a non-balanced entry !\nMake sure you have configured payment terms properly !\nThe latest payment term line should be of the type "Balance" !'))
obj_sequence = self.pool.get('ir.sequence')
for move in self.browse(cr, uid, valid_moves, context=context):
if move.name =='/':
@ -1230,7 +1238,7 @@ class account_move(osv.osv):
if not top:
top = account2.id
elif top<>account2.id:
raise osv.except_osv(_('Error !'), _('You cannot validate a Journal Entry unless all journal items are in same chart of accounts !'))
raise osv.except_osv(_('Error !'), _('You can not validate a journal entry unless all journal items belongs to the same chart of accounts !'))
return self.post(cursor, user, ids, context=context)
def button_cancel(self, cr, uid, ids, context=None):
@ -1248,7 +1256,7 @@ class account_move(osv.osv):
context = {}
c = context.copy()
c['novalidate'] = True
result = super(osv.osv, self).write(cr, uid, ids, vals, c)
result = super(account_move, self).write(cr, uid, ids, vals, c)
self.validate(cr, uid, ids, context=context)
return result
@ -1317,7 +1325,7 @@ class account_move(osv.osv):
for move in self.browse(cr, uid, ids, context=context):
if move['state'] != 'draft':
raise osv.except_osv(_('UserError'),
_('You can not delete posted movement: "%s"!') % \
_('You can not delete a posted journal entry "%s"!') % \
move['name'])
line_ids = map(lambda x: x.id, move.line_id)
context['journal_id'] = move.journal_id.id
@ -1337,7 +1345,7 @@ class account_move(osv.osv):
def _centralise(self, cr, uid, move, mode, context=None):
assert mode in ('debit', 'credit'), 'Invalid Mode' #to prevent sql injection
currency_obj = self.pool.get('res.currency')
currency_obj = self.pool.get('res.currency')
if context is None:
context = {}
@ -1599,7 +1607,7 @@ class account_tax_code(osv.osv):
(parent_ids,) + where_params)
res=dict(cr.fetchall())
obj_precision = self.pool.get('decimal.precision')
res2 = {}
res2 = {}
for record in self.browse(cr, uid, ids, context=context):
def _rec_get(record):
amount = res.get(record.id, 0.0)
@ -1768,6 +1776,9 @@ class account_tax(osv.osv):
'type_tax_use': fields.selection([('sale','Sale'),('purchase','Purchase'),('all','All')], 'Tax Application', required=True)
}
_sql_constraints = [
('name_company_uniq', 'unique(name, company_id)', 'Tax Name must be unique per company!'),
]
def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=80):
"""
@ -2126,7 +2137,11 @@ class account_model(osv.osv):
period_id = period_id[0]
for model in self.browse(cr, uid, ids, context=context):
entry['name'] = model.name%{'year':time.strftime('%Y'), 'month':time.strftime('%m'), 'date':time.strftime('%Y-%m')}
try:
entry['name'] = model.name%{'year':time.strftime('%Y'), 'month':time.strftime('%m'), 'date':time.strftime('%Y-%m')}
except:
raise osv.except_osv(_('Wrong model !'), _('You have a wrong expression "%(...)s" in your model !'))
move_id = account_move_obj.create(cr, uid, {
'ref': entry['name'],
'period_id': period_id,
@ -2198,8 +2213,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 Or Debit Must Be "0")!'),
('credit_debit2', 'CHECK (credit+debit>=0)', 'Wrong credit or debit value in model (Credit + Debit Must Be greater "0")!'),
('credit_debit1', 'CHECK (credit*debit=0)', 'Wrong credit or debit value in model, they must be positive!'),
('credit_debit2', 'CHECK (credit+debit>=0)', 'Wrong credit or debit value in model, they must be positive!'),
]
account_model_line()
@ -2365,7 +2380,7 @@ class account_account_template(osv.osv):
_check_recursion = check_cycle
_constraints = [
(_check_recursion, 'Error ! You can not create recursive account templates.', ['parent_id']),
(_check_type, 'Configuration Error! \nYou cannot define children to an account with internal type different of "View"! ', ['type']),
(_check_type, 'Configuration Error!\nYou can not define children to an account with internal type different of "View"! ', ['type']),
]
@ -2398,7 +2413,7 @@ class account_add_tmpl_wizard(osv.osv_memory):
ptids = tmpl_obj.read(cr, uid, [tids[0]['parent_id'][0]], ['code'])
res = None
if not ptids or not ptids[0]['code']:
raise osv.except_osv(_('Error !'), _('Cannot locate parent code for template account!'))
raise osv.except_osv(_('Error !'), _('I can not locate a parent code for the template account!'))
res = acc_obj.search(cr, uid, [('code','=',ptids[0]['code'])])
return res and res[0] or False
@ -2613,7 +2628,88 @@ class account_fiscal_position_account_template(osv.osv):
account_fiscal_position_account_template()
# Multi charts of Accounts wizard
# ---------------------------------------------------------
# Account Financial Report
# ---------------------------------------------------------
class account_financial_report(osv.osv):
_name = "account.financial.report"
_description = "Account Report"
def _get_level(self, cr, uid, ids, field_name, arg, context=None):
res = {}
for report in self.browse(cr, uid, ids, context=context):
level = 0
if report.parent_id:
level = report.parent_id.level + 1
res[report.id] = level
return res
def _get_children_by_order(self, cr, uid, ids, context=None):
res = []
for id in ids:
res.append(id)
ids2 = self.search(cr, uid, [('parent_id', '=', id)], order='sequence ASC', context=context)
res += self._get_children_by_order(cr, uid, ids2, context=context)
return res
def _get_balance(self, cr, uid, ids, name, args, context=None):
res = {}
res_all = {}
for report in self.browse(cr, uid, ids, context=context):
balance = 0.0
if report.id in res_all:
balance = res_all[report.id]
elif report.type == 'accounts':
# it's the sum of balance of the linked accounts
for a in report.account_ids:
balance += a.balance
elif report.type == 'account_report' and report.account_report_id:
# it's the amount of the linked report
res2 = self._get_balance(cr, uid, [report.account_report_id.id], 'balance', False, context=context)
res_all.update(res2)
for key, value in res2.items():
balance += value
elif report.type == 'sum':
# it's the sum of balance of the children of this account.report
#for child in report.children_ids:
res2 = self._get_balance(cr, uid, [rec.id for rec in report.children_ids], 'balance', False, context=context)
res_all.update(res2)
for key, value in res2.items():
balance += value
res[report.id] = balance
res_all[report.id] = balance
return res
_columns = {
'name': fields.char('Report Name', size=128, required=True),
'parent_id': fields.many2one('account.financial.report', 'Parent'),
'children_ids': fields.one2many('account.financial.report', 'parent_id', 'Account Report'),
'sequence': fields.integer('Sequence'),
'note': fields.text('Notes'),
'balance': fields.function(_get_balance, 'Balance'),
'level': fields.function(_get_level, string='Level', store=True, type='integer'),
'type': fields.selection([
('sum','View'),
('accounts','Accounts'),
('account_type','Account Type'),
('account_report','Report Value'),
],'Type'),
'account_ids': fields.many2many('account.account', 'account_account_financial_report', 'report_line_id', 'account_id', 'Accounts'),
'display_detail': fields.boolean('Display details', help='Display every account with its balance instead of the sum.'),
'account_report_id': fields.many2one('account.financial.report', 'Report Value'),
'account_type_ids': fields.many2many('account.account.type', 'account_account_financial_report_type', 'report_id', 'account_type_id', 'Account Types'),
}
_defaults = {
'type': 'sum',
}
account_financial_report()
# ---------------------------------------------------------
# Account generation from template wizards
# ---------------------------------------------------------
class wizard_multi_charts_accounts(osv.osv_memory):
"""
@ -2706,7 +2802,7 @@ class wizard_multi_charts_accounts(osv.osv_memory):
unconfigured_cmp = list(set(company_ids)-set(configured_cmp))
for field in res['fields']:
if field == 'company_id':
res['fields'][field]['domain'] = unconfigured_cmp
res['fields'][field]['domain'] = [('id','in',unconfigured_cmp)]
res['fields'][field]['selection'] = [('', '')]
if unconfigured_cmp:
cmp_select = [(line.id, line.name) for line in self.pool.get('res.company').browse(cr, uid, unconfigured_cmp)]

View File

@ -58,13 +58,6 @@ class account_bank_statement(osv.osv):
journal_id = ids[0]
return journal_id
def _default_balance_start(self, cr, uid, context=None):
cr.execute('select id from account_bank_statement where journal_id=%s order by date desc limit 1', (1,))
res = cr.fetchone()
if res:
return self.browse(cr, uid, res[0], context=context).balance_end
return 0.0
def _end_balance(self, cursor, user, ids, name, attr, context=None):
res_currency_obj = self.pool.get('res.currency')
res_users_obj = self.pool.get('res.users')
@ -90,7 +83,8 @@ class account_bank_statement(osv.osv):
res[statement.id] -= res_currency_obj.compute(cursor,
user, company_currency_id, currency_id,
line.credit, context=context)
if statement.state == 'draft':
if statement.state in ('draft', 'open'):
for line in statement.line_ids:
res[statement.id] += line.amount
for r in res:
@ -123,11 +117,17 @@ class account_bank_statement(osv.osv):
res[statement_id] = (currency_id, currency_names[currency_id])
return res
def _get_statement(self, cr, uid, ids, context=None):
result = {}
for line in self.pool.get('account.bank.statement.line').browse(cr, uid, ids, context=context):
result[line.statement_id.id] = True
return result.keys()
_order = "date desc, id desc"
_name = "account.bank.statement"
_description = "Bank Statement"
_columns = {
'name': fields.char('Name', size=64, required=True, help='if you give the Name other then /, its created Accounting Entries Move will be with same name as statement name. This allows the statement entries to have the same references than the statement itself', states={'confirm': [('readonly', True)]}),
'name': fields.char('Name', size=64, required=True, states={'draft': [('readonly', False)]}, readonly=True, help='if you give the Name other then /, its created Accounting Entries Move will be with same name as statement name. This allows the statement entries to have the same references than the statement itself'), # readonly for account_cash_statement
'date': fields.date('Date', required=True, states={'confirm': [('readonly', True)]}),
'journal_id': fields.many2one('account.journal', 'Journal', required=True,
readonly=True, states={'draft':[('readonly',False)]}),
@ -136,19 +136,25 @@ class account_bank_statement(osv.osv):
'balance_start': fields.float('Starting Balance', digits_compute=dp.get_precision('Account'),
states={'confirm':[('readonly',True)]}),
'balance_end_real': fields.float('Ending Balance', digits_compute=dp.get_precision('Account'),
states={'confirm':[('readonly', True)]}),
'balance_end': fields.function(_end_balance, string='Balance'),
states={'confirm': [('readonly', True)]}),
'balance_end': fields.function(_end_balance,
store = {
'account.bank.statement': (lambda self, cr, uid, ids, c={}: ids, ['line_ids','move_line_ids'], 10),
'account.bank.statement.line': (_get_statement, ['amount'], 10),
},
string="Computed Balance", help='Balance as calculated based on Starting Balance and transaction lines'),
'company_id': fields.related('journal_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True),
'line_ids': fields.one2many('account.bank.statement.line',
'statement_id', 'Statement lines',
states={'confirm':[('readonly', True)]}),
'move_line_ids': fields.one2many('account.move.line', 'statement_id',
'Entry lines', states={'confirm':[('readonly',True)]}),
'state': fields.selection([('draft', 'Draft'),('confirm', 'Confirmed')],
'State', required=True,
states={'confirm': [('readonly', True)]}, readonly="1",
help='When new statement is created the state will be \'Draft\'. \
\n* And after getting confirmation from the bank it will be in \'Confirmed\' state.'),
'state': fields.selection([('draft', 'New'),
('open','Open'), # used by cash statements
('confirm', 'Closed')],
'State', required=True, readonly="1",
help='When new statement is created the state will be \'Draft\'.\n'
'And after getting confirmation from the bank it will be in \'Confirmed\' state.'),
'currency': fields.function(_currency, string='Currency',
type='many2one', relation='res.currency'),
'account_id': fields.related('journal_id', 'default_debit_account_id', type='many2one', relation='account.account', string='Account used in this journal', readonly=True, help='used in statement reconciliation domain, but shouldn\'t be used elswhere.'),
@ -158,7 +164,6 @@ class account_bank_statement(osv.osv):
'name': "/",
'date': lambda *a: time.strftime('%Y-%m-%d'),
'state': 'draft',
'balance_start': _default_balance_start,
'journal_id': _default_journal_id,
'period_id': _get_period,
'company_id': lambda self,cr,uid,c: self.pool.get('res.company')._company_default_get(cr, uid, 'account.bank.statement',context=c),
@ -311,7 +316,7 @@ class account_bank_statement(osv.osv):
return self.write(cr, uid, ids, {'state':'confirm'}, context=context)
def check_status_condition(self, cr, uid, state, journal_type='bank'):
return state=='draft'
return state in ('draft','open')
def button_confirm_bank(self, cr, uid, ids, context=None):
obj_seq = self.pool.get('ir.sequence')
@ -386,7 +391,7 @@ class account_bank_statement(osv.osv):
if t['state'] in ('draft'):
unlink_ids.append(t['id'])
else:
raise osv.except_osv(_('Invalid action !'), _('Cannot delete bank statement(s) which are already confirmed !'))
raise osv.except_osv(_('Invalid action !'), _('In order to delete a bank statement, you must first cancel it to delete related journal items.'))
osv.osv.unlink(self, cr, uid, unlink_ids, context=context)
return True
@ -470,7 +475,7 @@ class account_bank_statement_line(osv.osv):
}
_defaults = {
'name': lambda self,cr,uid,context={}: self.pool.get('ir.sequence').get(cr, uid, 'account.bank.statement.line'),
'date': lambda *a: time.strftime('%Y-%m-%d'),
'date': lambda self,cr,uid,context={}: context.get('date', time.strftime('%Y-%m-%d')),
'type': 'general',
}

View File

@ -119,39 +119,6 @@ class account_cash_statement(osv.osv):
res2[statement.id] = encoding_total
return res2
def _end_balance(self, cursor, user, ids, name, attr, context=None):
res_currency_obj = self.pool.get('res.currency')
res_users_obj = self.pool.get('res.users')
res = {}
company_currency_id = res_users_obj.browse(cursor, user, user,
context=context).company_id.currency_id.id
statements = self.browse(cursor, user, ids, context=context)
for statement in statements:
res[statement.id] = statement.balance_start
currency_id = statement.currency.id
for line in statement.move_line_ids:
if line.debit > 0:
if line.account_id.id == \
statement.journal_id.default_debit_account_id.id:
res[statement.id] += res_currency_obj.compute(cursor,
user, company_currency_id, currency_id,
line.debit, context=context)
else:
if line.account_id.id == \
statement.journal_id.default_credit_account_id.id:
res[statement.id] -= res_currency_obj.compute(cursor,
user, company_currency_id, currency_id,
line.credit, context=context)
if statement.state in ('draft', 'open'):
for line in statement.line_ids:
res[statement.id] += line.amount
for r in res:
res[r] = round(res[r], 2)
return res
def _get_company(self, cr, uid, context=None):
user_pool = self.pool.get('res.users')
company_pool = self.pool.get('res.company')
@ -217,38 +184,33 @@ class account_cash_statement(osv.osv):
res['end'] = end_l
return res
def _get_statement(self, cr, uid, ids, context=None):
result = {}
for line in self.pool.get('account.bank.statement.line').browse(cr, uid, ids, context=context):
result[line.statement_id.id] = True
return result.keys()
_columns = {
'balance_end_real': fields.float('Closing Balance', digits_compute=dp.get_precision('Account'), states={'confirm': [('readonly', True)]}, help="closing balance entered by the cashbox verifier"),
'state': fields.selection(
[('draft', 'Draft'),
('confirm', 'Closed'),
('open','Open')], 'State', required=True, states={'confirm': [('readonly', True)]}, readonly="1"),
'total_entry_encoding': fields.function(_get_sum_entry_encoding, store=True, string="Cash Transaction", help="Total cash transactions"),
'total_entry_encoding': fields.function(_get_sum_entry_encoding, string="Cash Transaction", help="Total cash transactions",
store = {
'account.bank.statement': (lambda self, cr, uid, ids, c={}: ids, ['line_ids','move_line_ids'], 10),
'account.bank.statement.line': (_get_statement, ['amount'], 10),
}),
'closing_date': fields.datetime("Closed On"),
'balance_end': fields.function(_end_balance, store=True, string='Balance', help="Closing balance based on Starting Balance and Cash Transactions"),
'balance_end_cash': fields.function(_balance_end_cash, store=True, string='Balance', help="Closing balance based on cashBox"),
'balance_end_cash': fields.function(_balance_end_cash, store=True, string='Closing Balance', help="Closing balance based on cashBox"),
'starting_details_ids': fields.one2many('account.cashbox.line', 'starting_id', string='Opening Cashbox'),
'ending_details_ids': fields.one2many('account.cashbox.line', 'ending_id', string='Closing Cashbox'),
'name': fields.char('Name', size=64, required=True, states={'draft': [('readonly', False)]}, readonly=True, help='if you give the Name other then /, its created Accounting Entries Move will be with same name as statement name. This allows the statement entries to have the same references than the statement itself'),
'user_id': fields.many2one('res.users', 'Responsible', required=False),
}
_defaults = {
'state': 'draft',
'date': lambda *a: time.strftime("%Y-%m-%d %H:%M:%S"),
'date': lambda self,cr,uid,context={}: context.get('date', time.strftime("%Y-%m-%d %H:%M:%S")),
'user_id': lambda self, cr, uid, context=None: uid,
'starting_details_ids': _get_cash_open_box_lines,
'ending_details_ids': _get_default_cash_close_box_lines
}
def create(self, cr, uid, vals, context=None):
sql = [
('journal_id', '=', vals.get('journal_id', False)),
('state', '=', 'open')
]
open_jrnl = self.search(cr, uid, sql)
if open_jrnl:
raise osv.except_osv(_('Error'), _('You can not have two open register for the same journal'))
if self.pool.get('account.journal').browse(cr, uid, vals['journal_id'], context=context).type == 'cash':
open_close = self._get_cash_open_close_box_lines(cr, uid, context)
if vals.get('starting_details_ids', False):
@ -340,7 +302,6 @@ class account_cash_statement(osv.osv):
})
vals.update({
'date': time.strftime("%Y-%m-%d %H:%M:%S"),
'state': 'open',
})
self.write(cr, uid, [statement.id], vals, context=context)
@ -350,7 +311,7 @@ class account_cash_statement(osv.osv):
if journal_type == 'bank':
return super(account_cash_statement, self).balance_check(cr, uid, cash_id, journal_type, context)
if not self._equal_balance(cr, uid, cash_id, context):
raise osv.except_osv(_('Error !'), _('CashBox Balance is not matching with Calculated Balance !'))
raise osv.except_osv(_('Error !'), _('The closing balance should be the same than the computed balance !'))
return True
def statement_close(self, cr, uid, ids, journal_type='bank', context=None):

View File

@ -23,7 +23,7 @@
<attribute name="rowspan">23</attribute>
<attribute name="string"/>
</xpath>
<group colspan="8">
<group colspan="8" position="inside">
<group colspan="4" width="600">
<field name="charts"/>
<group colspan="4" groups="base.group_extended">
@ -85,5 +85,58 @@
<field name="type">automatic</field>
</record>
<record id="action_bank_account_configuration_installer" model="ir.actions.act_window">
<field name="name">Define your Bank Account</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">res.partner.bank</field>
<field name="view_type">form</field>
<field name="view_mode">form</field>
</record>
<record id="bank_account_configuration_todo" model="ir.actions.todo">
<field name="action_id" ref="action_bank_account_configuration_installer" />
<field name="category_id" ref="category_accounting_configuration" />
</record>
<record id="action_view_financial_accounts_installer" model="ir.actions.act_window">
<field name="name">Review your Financial Accounts</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">account.account</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
</record>
<record id="view_financial_accounts_todo" model="ir.actions.todo">
<field name="action_id" ref="action_view_financial_accounts_installer" />
<field name="category_id" ref="category_accounting_configuration" />
<field name="groups_id" eval="[(6, 0, [ref('account.group_account_user')])]" />
</record>
<record id="action_review_financial_journals_installer" model="ir.actions.act_window">
<field name="name">Review your Financial Journal</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">account.journal</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
</record>
<record id="review_financial_journals_todo" model="ir.actions.todo">
<field name="action_id" ref="action_review_financial_journals_installer" />
<field name="category_id" ref="category_accounting_configuration" />
<field name="groups_id" eval="[(6, 0, [ref('account.group_account_user')])]" />
</record>
<record id="action_review_payment_terms_installer" model="ir.actions.act_window">
<field name="name">Review your Payment Terms</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">account.payment.term</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
</record>
<record id="review_payment_terms_todo" model="ir.actions.todo">
<field name="action_id" ref="action_review_payment_terms_installer" />
<field name="category_id" ref="category_accounting_configuration" />
<field name="groups_id" eval="[(6, 0, [ref('account.group_account_user')])]" />
</record>
</data>
</openerp>

View File

@ -205,7 +205,7 @@
<field name="amount_tax"/>
<field name="reconciled"/>
<field name="amount_total"/>
<field name="state"/>
<field name="state" widget="statusbar" statusbar_visible="draft,open,paid" statusbar_colors='{"proforma":"blue","proforma2":"blue"}'/>
<field name="residual"/>
<group col="6" colspan="4">
<button name="invoice_cancel" states="draft,proforma2,sale,open" string="Cancel" icon="gtk-cancel"/>
@ -234,7 +234,6 @@
<field name="payment_ids" colspan="4" nolabel="1" >
<tree string="Payments">
<field name="date" string="Payment Date"/>
<field name="move_id"/>
<field name="ref"/>
<field name="name" groups="base.group_extended"/>
<field name="journal_id"/>
@ -294,13 +293,13 @@
</field>
</group>
<group col="4" colspan="2">
<button colspan="2" name="button_reset_taxes" states="draft" string="Compute Taxes" type="object" groups="base.group_user" icon="terp-stock_format-scientific" help="This action will erase taxes"/>
<button colspan="2" name="button_reset_taxes" states="draft,proforma2" string="Compute Taxes" type="object" groups="base.group_user" icon="terp-stock_format-scientific" help="This action will erase taxes"/>
<field name="amount_untaxed"/>
<label string="" colspan="2"/>
<field name="amount_tax"/>
<field name="reconciled"/>
<field name="amount_total"/>
<field name="state"/>
<field name="state" widget="statusbar" statusbar_visible="draft,open,paid" statusbar_colors='{"proforma":"blue","proforma2":"blue"}'/>
<field name="residual"/>
<group col="8" colspan="4" groups="base.group_user">
<button name="invoice_cancel" states="draft,proforma2,sale,open" string="Cancel" icon="gtk-cancel"/>
@ -333,7 +332,6 @@
<field name="payment_ids" colspan="4" nolabel="1">
<tree string="Payments">
<field name="date"/>
<field name="move_id"/>
<field name="ref"/>
<field name="name"/>
<field name="journal_id" groups="base.group_user"/>
@ -355,7 +353,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Invoice">
<group col="10" colspan="4">
<group>
<filter name="draft" icon="terp-document-new" string="Draft" domain="[('state','=','draft')]" help="Draft Invoices"/>
<filter name="proforma" icon="terp-gtk-media-pause" string="Proforma" domain="[('state','=','proforma2')]" help="Proforma Invoices"/>
<filter name="invoices" icon="terp-dolar" string="Invoices" domain="[('state','not in',['draft','cancel'])]" help="Proforma/Open/Paid Invoices"/>
@ -364,16 +362,16 @@
<separator orientation="vertical"/>
<field name="number"/>
<field name="partner_id"/>
<field name="user_id" select="1" widget="selection" string="Salesman">
<filter domain="[('user_id','=',uid)]" help="My invoices" icon="terp-personal" separator="1"/>
<field name="user_id" widget="selection" string="Salesman">
<filter domain="[('user_id','=',uid)]" help="My invoices" icon="terp-personal" />
</field>
<field name="origin"/>
<field name="amount_total"/>
</group>
<newline/>
<group col="10" colspan="4">
<field name="journal_id" widget="selection" select='1'/>
<field name="period_id" select='1' string="Period"/>
<group>
<field name="journal_id" widget="selection"/>
<field name="period_id" string="Period"/>
</group>
<newline/>
<group expand="0" string="Group By...">

View File

@ -30,6 +30,7 @@
<menuitem id="base.menu_action_currency_form" parent="menu_configuration_misc" sequence="20"/>
<menuitem id="menu_finance_generic_reporting" name="Generic Reporting" parent="menu_finance_reporting" sequence="100"/>
<menuitem id="menu_finance_entries" name="Journal Entries" parent="menu_finance" sequence="5" groups="group_account_user,group_account_manager"/>
<menuitem id="menu_account_reports" name="Financial Reports" parent="menu_finance_accounting" sequence="18"/>
<menuitem id="account.menu_finance_recurrent_entries" name="Recurring Entries"
parent="menu_finance_periodical_processing" sequence="15"

View File

@ -588,10 +588,18 @@ class account_move_line(osv.osv):
return False
return True
def _check_date(self, cr, uid, ids, context=None):
for l in self.browse(cr, uid, ids, context=context):
if l.journal_id.allow_date:
if not time.strptime(l.date[:10],'%Y-%m-%d') >= time.strptime(l.period_id.date_start, '%Y-%m-%d') or not time.strptime(l.date[:10], '%Y-%m-%d') <= time.strptime(l.period_id.date_stop, '%Y-%m-%d'):
return False
return True
_constraints = [
(_check_no_view, 'You can not create move line on view account.', ['account_id']),
(_check_no_closed, 'You can not create move line on closed account.', ['account_id']),
(_check_company_id, 'Company must be same for its related account and period.',['company_id'] ),
(_check_date, 'The date of your Journal Entry is not in the defined period!',['date'] ),
]
#TODO: ONCHANGE_ACCOUNT_ID: set account_tax_id
@ -642,14 +650,15 @@ class account_move_line(osv.osv):
id2 = part.property_account_receivable.id
if journal:
jt = journal_obj.browse(cr, uid, journal).type
#FIXME: Bank and cash journal are such a journal we can not assume a account based on this 2 journals
# Bank and cash journal can have a payment or receipt transaction, and in both type partner account
# will not be same id payment then payable, and if receipt then receivable
#if jt in ('sale', 'purchase_refund', 'bank', 'cash'):
if jt in ('sale', 'purchase_refund'):
val['account_id'] = fiscal_pos_obj.map_account(cr, uid, part and part.property_account_position or False, id2)
elif jt in ('purchase', 'sale_refund', 'expense', 'bank', 'cash'):
elif jt in ('purchase', 'sale_refund'):
val['account_id'] = fiscal_pos_obj.map_account(cr, uid, part and part.property_account_position or False, id1)
elif jt in ('general', 'bank', 'cash'):
if part.customer:
val['account_id'] = fiscal_pos_obj.map_account(cr, uid, part and part.property_account_position or False, id2)
elif part.supplier:
val['account_id'] = fiscal_pos_obj.map_account(cr, uid, part and part.property_account_position or False, id1)
if val.get('account_id', False):
d = self.onchange_account_id(cr, uid, ids, val['account_id'])
val.update(d['value'])
@ -709,7 +718,7 @@ class account_move_line(osv.osv):
)
return cr.fetchone()
def reconcile_partial(self, cr, uid, ids, type='auto', context=None):
def reconcile_partial(self, cr, uid, ids, type='auto', context=None, writeoff_acc_id=False, writeoff_period_id=False, writeoff_journal_id=False):
move_rec_obj = self.pool.get('account.move.reconcile')
merges = []
unmerge = []
@ -738,7 +747,7 @@ class account_move_line(osv.osv):
unmerge.append(line.id)
total += (line.debit or 0.0) - (line.credit or 0.0)
if self.pool.get('res.currency').is_zero(cr, uid, company_currency_id, total):
res = self.reconcile(cr, uid, merges+unmerge, context=context)
res = self.reconcile(cr, uid, merges+unmerge, context=context, writeoff_acc_id=writeoff_acc_id, writeoff_period_id=writeoff_period_id, writeoff_journal_id=writeoff_journal_id)
return res
r_id = move_rec_obj.create(cr, uid, {
'type': type,
@ -803,7 +812,7 @@ class account_move_line(osv.osv):
if (not currency_obj.is_zero(cr, uid, account.company_id.currency_id, writeoff)) or \
(account.currency_id and (not currency_obj.is_zero(cr, uid, account.currency_id, currency))):
if not writeoff_acc_id:
raise osv.except_osv(_('Warning'), _('You have to provide an account for the write off entry !'))
raise osv.except_osv(_('Warning'), _('You have to provide an account for the write off/exchange difference entry !'))
if writeoff > 0:
debit = writeoff
credit = 0.0
@ -1013,7 +1022,7 @@ class account_move_line(osv.osv):
attrs.append("context=\"{'journal_id': journal_id}\"")
elif field == 'account_id' and journal.id:
attrs.append('domain="[(\'journal_id\', \'=\', '+str(journal.id)+'),(\'type\',\'&lt;&gt;\',\'view\'), (\'type\',\'&lt;&gt;\',\'closed\')]" on_change="onchange_account_id(account_id, partner_id)"')
attrs.append('domain="[(\'journal_id\', \'=\', journal_id),(\'type\',\'&lt;&gt;\',\'view\'), (\'type\',\'&lt;&gt;\',\'closed\')]" on_change="onchange_account_id(account_id, partner_id)"')
elif field == 'partner_id':
attrs.append('on_change="onchange_partner_id(move_id, partner_id, account_id, debit, credit, date, journal_id)"')
@ -1098,35 +1107,6 @@ class account_move_line(osv.osv):
move_obj.validate(cr, uid, move_ids, context=context)
return result
def _check_date(self, cr, uid, vals, context=None, check=True):
if context is None:
context = {}
move_obj = self.pool.get('account.move')
journal_obj = self.pool.get('account.journal')
period_obj = self.pool.get('account.period')
journal_id = False
if 'date' in vals.keys():
if 'journal_id' in vals and 'journal_id' not in context:
journal_id = vals['journal_id']
if 'period_id' in vals and 'period_id' not in context:
period_id = vals['period_id']
elif 'journal_id' not in context and 'move_id' in vals:
if vals.get('move_id', False):
m = move_obj.browse(cr, uid, vals['move_id'])
journal_id = m.journal_id.id
period_id = m.period_id.id
else:
journal_id = context.get('journal_id', False)
period_id = context.get('period_id', False)
if journal_id:
journal = journal_obj.browse(cr, uid, journal_id, context=context)
if journal.allow_date and period_id:
period = period_obj.browse(cr, uid, period_id, context=context)
if not time.strptime(vals['date'][:10],'%Y-%m-%d') >= time.strptime(period.date_start, '%Y-%m-%d') or not time.strptime(vals['date'][:10], '%Y-%m-%d') <= time.strptime(period.date_stop, '%Y-%m-%d'):
raise osv.except_osv(_('Error'),_('The date of your Journal Entry is not in the defined period!'))
else:
return True
def write(self, cr, uid, ids, vals, context=None, check=True, update_check=True):
if context is None:
context={}
@ -1137,7 +1117,6 @@ class account_move_line(osv.osv):
ids = [ids]
if vals.get('account_tax_id', False):
raise osv.except_osv(_('Unable to change tax !'), _('You can not change the tax, you should remove and recreate lines !'))
self._check_date(cr, uid, vals, context, check)
if ('account_id' in vals) and not account_obj.read(cr, uid, vals['account_id'], ['active'])['active']:
raise osv.except_osv(_('Bad account!'), _('You can not use an inactive account!'))
if update_check:
@ -1221,7 +1200,6 @@ class account_move_line(osv.osv):
company_id = self.pool.get('account.move').read(cr, uid, vals['move_id'], ['company_id']).get('company_id', False)
if company_id:
vals['company_id'] = company_id[0]
self._check_date(cr, uid, vals, context, check)
if ('account_id' in vals) and not account_obj.read(cr, uid, vals['account_id'], ['active'])['active']:
raise osv.except_osv(_('Bad account!'), _('You can not use an inactive account!'))
if 'journal_id' in vals:
@ -1232,7 +1210,6 @@ class account_move_line(osv.osv):
m = move_obj.browse(cr, uid, vals['move_id'])
context['journal_id'] = m.journal_id.id
context['period_id'] = m.period_id.id
self._update_journal_check(cr, uid, context['journal_id'], context['period_id'], context)
move_id = vals.get('move_id', False)
journal = journal_obj.browse(cr, uid, context['journal_id'], context=context)
@ -1255,7 +1232,7 @@ class account_move_line(osv.osv):
move_id = move_obj.create(cr, uid, v, context)
vals['move_id'] = move_id
else:
raise osv.except_osv(_('No piece number !'), _('Can not create an automatic sequence for this piece !\n\nPut a sequence in the journal definition for automatic numbering or create a sequence manually for this piece.'))
raise osv.except_osv(_('No piece number !'), _('Can not create an automatic sequence for this piece!\nPut a sequence in the journal definition for automatic numbering or create a sequence manually for this piece.'))
ok = not (journal.type_control_ids or journal.account_control_ids)
if ('account_id' in vals):
account = account_obj.browse(cr, uid, vals['account_id'], context=context)
@ -1272,7 +1249,7 @@ class account_move_line(osv.osv):
break
# Automatically convert in the account's secondary currency if there is one and
# the provided values were not already multi-currency
if account.currency_id and 'amount_currency' not in vals and account.currency_id.id != account.company_id.currency_id.id:
if account.currency_id and not vals.get('ammount_currency') and account.currency_id.id != account.company_id.currency_id.id:
vals['currency_id'] = account.currency_id.id
ctx = {}
if 'date' in vals:
@ -1280,7 +1257,7 @@ class account_move_line(osv.osv):
vals['amount_currency'] = cur_obj.compute(cr, uid, account.company_id.currency_id.id,
account.currency_id.id, vals.get('debit', 0.0)-vals.get('credit', 0.0), context=ctx)
if not ok:
raise osv.except_osv(_('Bad account !'), _('You can not use this general account in this journal !'))
raise osv.except_osv(_('Bad account !'), _('You can not use this general account in this journal, check the tab \'Entry Controls\' on the related journal !'))
if vals.get('analytic_account_id',False):
if journal.analytic_journal_id:
@ -1296,7 +1273,7 @@ class account_move_line(osv.osv):
'user_id': uid
})]
result = super(osv.osv, self).create(cr, uid, vals, context=context)
result = super(account_move_line, self).create(cr, uid, vals, context=context)
# CREATE Taxes
if vals.get('account_tax_id', False):
tax_id = tax_obj.browse(cr, uid, vals['account_tax_id'])

View File

@ -202,7 +202,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Accounts">
<group col="10" colspan="4">
<group>
<filter icon="terp-sale" string="Receivable Accounts" domain="[('type','=','receivable')]"/>
<filter icon="terp-purchase" string="Payable Accounts" domain="[('type','=','payable')]"/>
<separator orientation="vertical"/>
@ -387,7 +387,7 @@
<field name="model">account.journal</field>
<field name="type">search</field>
<field name="arch" type="xml">
<tree string="Search Account Journal">
<search string="Search Account Journal">
<group>
<filter domain="['|', ('type', '=', 'sale'), ('type', '=', 'sale_refund')]" string="Sale" icon="terp-camera_test"/>
<filter domain="['|', ('type', '=', 'purchase'), ('type', '=', 'purchase_refund')]" string="Purchase" icon="terp-purchase"/>
@ -404,7 +404,7 @@
<separator orientation="vertical"/>
<filter string="Type" context="{'group_by':'type'}" icon="terp-stock_symbol-selection"/>
</group>
</tree>
</search>
</field>
</record>
<record id="view_account_journal_form" model="ir.ui.view">
@ -482,7 +482,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Bank Statements">
<group col="8" colspan="4">
<group>
<filter string="Draft" domain="[('state','=','draft')]" icon="terp-document-new"/>
<filter string="Confirmed" domain="[('state','=','confirm')]" icon="terp-camera_test"/>
<separator orientation="vertical"/>
@ -526,7 +526,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Bank Statements">
<group col="8" colspan="4">
<group>
<filter string="Draft" domain="[('state','=','draft')]" icon="terp-document-new"/>
<filter string="Confirmed" domain="[('state','=','confirm')]" icon="terp-camera_test"/>
<separator orientation="vertical"/>
@ -564,7 +564,7 @@
</group>
<notebook colspan="4">
<page string="Transaction" name="statement_line_ids">
<field colspan="4" name="line_ids" nolabel="1">
<field colspan="4" name="line_ids" nolabel="1" context="{'date':date}">
<tree editable="bottom" string="Statement lines">
<field name="sequence" readonly="1" invisible="1"/>
<field name="date" groups="base.group_extended"/>
@ -596,7 +596,7 @@
</page>
</notebook>
<group col="8" colspan="4">
<field name="state"/>
<field name="state" widget="statusbar" statusbar_visible="draft,confirm"/>
<field name="balance_end"/>
<button name="button_cancel" states="confirm" string="Cancel" type="object" icon="gtk-cancel"/>
<button name="button_dummy" states="draft" string="Compute" type="object" icon="terp-stock_format-scientific"/>
@ -749,6 +749,7 @@
<group col="2" colspan="2">
<separator string="Reporting Configuration" colspan="4"/>
<field name="report_type" select="2"/>
<field name="sign" />
</group>
<group col="2" colspan="2">
<separator string="Closing Method" colspan="4"/>
@ -907,7 +908,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Taxes">
<group col="10" colspan="4">
<group>
<field name="name"/>
<field name="description"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
@ -1102,7 +1103,7 @@
<separator string="Internal Note" colspan="4"/>
<field name="narration" colspan="4" nolabel="1"/>
</page>
<page string="Analytic Lines" groups="base.group_analytic_accounting">
<page string="Analytic Lines" groups="analytic.group_analytic_accounting">
<field colspan="4" name="analytic_lines" nolabel="1" context="{'default_general_account_id':account_id, 'default_name': name, 'default_date':date, 'amount': (debit or 0.0)-(credit or 0.0)}"/>
</page>
</notebook>
@ -1149,7 +1150,7 @@
<field name="reconcile_partial_id"/>
<field name="state"/>
</page>
<page string="Analytic Lines" groups="base.group_analytic_accounting">
<page string="Analytic Lines" groups="analytic.group_analytic_accounting">
<field colspan="4" name="analytic_lines" nolabel="1" />
</page>
</notebook>
@ -1176,7 +1177,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Journal Items">
<group col='10' colspan='4'>
<group>
<filter icon="terp-document-new" string="Unbalanced" domain="[('state','=','draft')]" help="Unbalanced Journal Items"/>
<separator orientation="vertical"/>
<filter icon="terp-document-new" string="Unposted" domain="[('move_id.state','=','draft')]" help="Unposted Journal Items"/>
@ -1188,20 +1189,20 @@
domain="[('reconcile_id','=',False), ('account_id.reconcile','=',True)]" help="Unreconciled Journal Items"
name="unreconciled"/>
<separator orientation="vertical"/>
<field name="move_id" select="1" string="Number (Move)"/>
<field name="date" select='1'/>
<field name="account_id" select='1'/>
<field name="partner_id" select='1'>
<field name="move_id" string="Number (Move)"/>
<field name="date"/>
<field name="account_id"/>
<field name="partner_id">
<filter help="Next Partner Entries to reconcile" name="next_partner" string="Next Partner to reconcile" context="{'next_partner_only': 1}" icon="terp-gtk-jump-to-ltr" domain="[('account_id.reconcile','=',True),('reconcile_id','=',False)]"/>
</field>
</group>
<newline/>
<group col="10" colspan="4">
<group>
<field name="journal_id" widget="selection" context="{'journal_id':self, 'visible_id':self, 'normal_view':False}"/>
<field name="period_id" context="{'period_id':self, 'search_default_period_id':self}"/>
</group>
<newline/>
<group expand="0" string="Group By..." colspan="12" col="10">
<group expand="0" string="Group By...">
<filter string="Partner" icon="terp-partner" domain="[]" context="{'group_by':'partner_id'}"/>
<separator orientation="vertical"/>
<filter string="Journal" icon="terp-folder-orange" domain="[]" context="{'group_by':'journal_id'}"/>
@ -1390,7 +1391,7 @@
<separator string="Internal Note" colspan="4"/>
<field name="narration" colspan="4" nolabel="1"/>
</page>
<page string="Analytic Lines" groups="base.group_analytic_accounting">
<page string="Analytic Lines" groups="analytic.group_analytic_accounting">
<field colspan="4" name="analytic_lines" nolabel="1" context="{'default_general_account_id':account_id, 'default_name': name, 'default_date':date, 'amount': (debit or 0.0)-(credit or 0.0)}"/>
</page>
</notebook>
@ -1433,7 +1434,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Move">
<group col='8' colspan='4'>
<group>
<filter icon="terp-document-new" string="Unposted" domain="[('state','=','draft')]" help="Unposted Journal Entries"/>
<filter icon="terp-camera_test" string="Posted" domain="[('state','=','posted')]" help="Posted Journal Entries"/>
<separator orientation="vertical"/>
@ -1445,12 +1446,12 @@
<field name="date"/>
</group>
<newline/>
<group col='8' colspan='4'>
<group>
<field name="journal_id" widget="selection"/>
<field name="period_id"/>
</group>
<newline/>
<group expand="0" string="Group By..." colspan="12" col="10">
<group expand="0" string="Group By...">
<filter string="Partner" icon="terp-partner" domain="[]" context="{'group_by':'partner_id'}"/>
<separator orientation="vertical"/>
<filter string="Journal" icon="terp-folder-orange" domain="[]" context="{'group_by':'journal_id'}"/>
@ -1832,7 +1833,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Entry Subscription">
<group col="8" colspan="4">
<group>
<filter icon="terp-document-new" string="Draft" domain="[('state','=','draft')]" help="Draft Subscription"/>
<filter icon="terp-camera_test" string="Running" domain="[('state','=','running')]" help="Running Subscription"/>
<separator orientation="vertical"/>
@ -2278,7 +2279,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Tax Templates">
<group col="10" colspan="4">
<group>
<filter icon="terp-sale" string="Sale" domain="[('type_tax_use','=','sale')]" help="Taxes used in Sales"/>
<filter icon="terp-purchase" string="Purchase" domain="[('type_tax_use','=','purchase')]" help="Taxes used in Purchases"/>
<separator orientation="vertical"/>
@ -2555,7 +2556,7 @@ action = pool.get('res.config').next(cr, uid, [], context)
<group col="6" colspan="4">
<field name="name" select="1"/>
<field name="company_id" select="1" groups="base.group_multi_company"/>
<field name="journal_id" on_change="onchange_journal_id(journal_id)" domain="[('type','=','cash')]" select="1" widget="selection"/>
<field name="journal_id" on_change="onchange_journal_id(journal_id)" select="1" widget="selection"/>
<field name="user_id" select="1" readonly="1"/>
<field name="period_id" select="1"/>
<field name="currency" invisible="1"/>
@ -2563,7 +2564,7 @@ action = pool.get('res.config').next(cr, uid, [], context)
<notebook colspan="4">
<page string="Cash Transactions" attrs="{'invisible': [('state','=','draft')]}">
<field colspan="4" name="line_ids" nolabel="1">
<field colspan="4" name="line_ids" nolabel="1" context="{'date':date}">
<tree editable="bottom" string="Statement lines">
<field name="sequence" invisible="1"/>
<field name="date" groups="base.group_extended"/>
@ -2637,12 +2638,12 @@ action = pool.get('res.config').next(cr, uid, [], context)
</group>
<group col="2" colspan="2">
<separator string="Closing Balance" colspan="4"/>
<field name="balance_end" string="Calculated Balance"/>
<field name="balance_end_cash" string="CashBox Balance"/>
<field name="balance_end"/>
<field name="balance_end_cash"/>
</group>
</group>
<group col="8" colspan="4">
<field name="state" colspan="4"/>
<field name="state" widget="statusbar" statusbar_visible="draft,confirm" colspan="4"/>
<button name="button_cancel" states="confirm,open" string="Cancel" icon="terp-gtk-stop" type="object" groups="base.group_extended"/>
<button name="button_confirm_cash" states="open" string="Close CashBox" icon="terp-dialog-close" type="object"/>
<button name="button_open" states="draft" string="Open CashBox" icon="gtk-go-forward" type="object"/>
@ -2703,5 +2704,113 @@ action = pool.get('res.config').next(cr, uid, [], context)
parent="menu_finance_payables"
action="base.action_partner_supplier_form" sequence="100"/>
<!--
Account Reports
-->
<record id="view_account_financial_report_form" model="ir.ui.view">
<field name="name">account.financial.report.form</field>
<field name="model">account.financial.report</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Account Report">
<group col="6" colspan="4">
<field name="name"/>
<field name="parent_id"/>
<field name="sequence"/>
<field name="type"/>
</group>
<notebook colspan="4">
<page string="Report" attrs="{'invisible': [('state','!=','confirm')]}">
<field name="display_detail" attrs="{'invisible': [('type','!=','accounts')]}"/>
<newline/>
<field name="account_ids" nolabel="1" colspan="6" attrs="{'invisible': [('type', '!=', 'accounts')]}"/>
<newline/>
<field name="account_report_id" attrs="{'invisible': [('type', '!=', 'account_report')]}"/>
<newline/>
<field name="account_type_ids" nolabel="1" attrs="{'invisible': [('type', '!=', 'account_type')]}"/>
<newline/>
</page>
<page string="Notes" attrs="{'invisible': [('state','!=','confirm')]}">
<field name="note" nolabel="1" colspan="4"/>
</page>
</notebook>
</form>
</field>
</record>
<record id="view_account_financial_report_tree" model="ir.ui.view">
<field name="name">account.financial.report.tree</field>
<field name="model">account.financial.report</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<tree string="Account Report">
<field name="name"/>
<field name="parent_id" invisible="1"/>
<field name="type"/>
<field name="account_report_id"/>
</tree>
</field>
</record>
<record id="view_account_financial_report_search" model="ir.ui.view">
<field name="name">account.financial.report.search</field>
<field name="model">account.financial.report</field>
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Account Report">
<group>
<field name="name"/>
<field name="type"/>
<field name="account_report_id"/>
</group>
<newline/>
<group expand="0" string="Group By...">
<filter string="Parent Report" icon="terp-folder-orange" domain="" context="{'group_by':'parent_id'}"/>
<separator orientation="vertical"/>
<filter string="Report Type" icon="terp-stock_symbol-selection" domain="[]" context="{'group_by':'type'}"/>
</group>
</search>
</field>
</record>
<record id="action_account_financial_report_tree" model="ir.actions.act_window">
<field name="name">Financial Reports</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">account.financial.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="search_view_id" ref="view_account_financial_report_search"/>
<field name="view_id" ref="view_account_financial_report_tree"/>
<field name="help">Makes a generic system to draw financial reports easily.</field>
</record>
<menuitem id="menu_account_financial_reports_tree" name="Account Reports" parent="menu_account_reports" action="action_account_financial_report_tree"/>
<record id="view_account_report_tree_hierarchy" model="ir.ui.view">
<field name="name">account.report.hierarchy</field>
<field name="model">account.financial.report</field>
<field name="type">tree</field>
<field name="field_parent">children_ids</field>
<field name="arch" type="xml">
<tree string="Account Reports Hierarchy">
<field name="name"/>
<field name="type"/>
<field name="parent_id" invisible="1"/>
<field name="account_report_id"/>
</tree>
</field>
</record>
<record id="action_account_report_tree_hierarchy" model="ir.actions.act_window">
<field name="name">Financial Reports Hierarchy</field>
<field name="res_model">account.financial.report</field>
<field name="view_type">tree</field>
<field name="view_id" ref="view_account_report_tree_hierarchy"/>
<field name="domain">[('parent_id','=',False)]</field>
</record>
<menuitem id="menu_account_report_tree_hierarchy" name="Account Reports Hierarchy"
parent="menu_account_reports" action="action_account_report_tree_hierarchy"/>
</data>
</openerp>

View File

@ -33,7 +33,7 @@ class res_company(osv.osv):
string="Reserve and Profit/Loss Account",
view_load=True,
domain="[('type', '=', 'other')]",
help="This Account is used for transferring Profit/Loss(If It is Profit: Amount will be added, Loss : Amount will be deducted.), Which is calculated from Profit & Loss Report"),
help="This account is used for transferring Profit/Loss (If It is Profit: Amount will be added, Loss : Amount will be deducted.), as calculated in Profit & Loss Report"),
}
_defaults = {

View File

@ -7,7 +7,7 @@
<field name="model">res.company</field>
<field name="type">form</field>
<field name="arch" type="xml">
<notebook>
<notebook position="inside">
<page string="Overdue Payments" position="inside">
<separator string="Overdue Payments Message" colspan="4"/>
<field name="overdue_msg" nolabel="1" colspan ="4"/>

View File

@ -87,7 +87,7 @@
<record model="account.account.type" id="conf_account_type_equity">
<field name="name">Equity</field>
<field name="code">equity</field>
<field name="report_type">asset</field>
<field name="report_type">liability</field>
<field name="close_method">balance</field>
</record>
@ -186,8 +186,8 @@
<field name="code">1104</field>
<field name="name">Bank Current Account</field>
<field ref="conf_cas" name="parent_id"/>
<field name="type">liquidity</field>
<field name="user_type" ref="conf_account_type_asset"/>
<field name="type">view</field>
<field name="user_type" ref="account_type_asset_view1"/>
</record>
<record id="conf_o_income" model="account.account.template">
@ -446,7 +446,7 @@
<field name="property_account_expense_categ" ref="conf_a_expense"/>
<field name="property_account_income_categ" ref="conf_a_sale"/>
<field name="property_account_income_opening" ref="conf_o_income"/>
<field name="property_account_expense_opening" ref="conf_o_expense"/>
<field name="property_account_expense_opening" ref="conf_o_expense"/>
<field name="property_reserve_and_surplus_account" ref="conf_a_reserve_and_surplus"/>
</record>
@ -611,7 +611,7 @@
<record id="conf_a_expense" model="account.account.template">
<field name="tax_ids" eval="[(6,0,[ref('otaxs')])]"/>
</record>
<record id="action_wizard_multi_chart_todo" model="ir.actions.todo">
<field name="name">Generate Chart of Accounts from a Chart Template</field>
<field name="action_id" ref="account.action_wizard_multi_chart"/>

View File

@ -49,7 +49,7 @@
<record id="account_type_cash_equity" model="account.account.type">
<field name="name">Equity</field>
<field name="code">equity</field>
<field name="report_type">asset</field>
<field name="report_type">liability</field>
<field name="close_method">balance</field>
</record>
<record id="account_type_cash_moves" model="account.account.type">

View File

@ -451,8 +451,6 @@ msgstr ""
#: field:account.move.bank.reconcile,journal_id:0
#: view:account.move.line:0
#: field:account.move.line,journal_id:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: code:addons/account/account_move_line.py:983
#: view:analytic.entries.report:0
#: field:analytic.entries.report,journal_id:0
@ -1071,6 +1069,7 @@ msgstr ""
#. module: account
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:account.tax.code.entries:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
@ -1258,6 +1257,16 @@ msgstr ""
#: selection:account.partner.balance,display_partner:0
#: selection:account.pl.report,display_account:0
#: selection:account.report.general.ledger,display_account:0
#: report:account.account.balance:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "With balance is not equal to 0"
msgstr ""
@ -1980,6 +1989,9 @@ msgstr ""
#. module: account
#: report:account.journal.period.print:0
#: field:account.print.journal,sort_selection:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
msgid "Entries Sorted By"
msgstr ""
@ -2001,11 +2013,16 @@ msgstr ""
#. module: account
#: report:account.account.balance:0
#: report:account.central.journal:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
#: view:account.entries.report:0
#: field:account.entries.report,fiscalyear_id:0
#: field:account.fiscalyear,name:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: field:account.journal.period,fiscalyear_id:0
#: report:account.journal.period.print:0
#: report:account.partner.balance:0
@ -2305,6 +2322,7 @@ msgstr ""
#. module: account
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:account.journal.period.print:0
#: report:account.overdue:0
#: report:account.third_party_ledger:0
@ -2537,6 +2555,8 @@ msgstr ""
#. module: account
#: view:account.pl.report:0
#: model:ir.ui.menu,name:account.menu_account_pl_report
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Profit And Loss"
msgstr ""
@ -2786,7 +2806,6 @@ msgstr ""
#: report:account.general.journal:0
#: field:account.general.journal,journal_ids:0
#: view:account.journal.period:0
#: report:account.partner.balance:0
#: field:account.partner.balance,journal_ids:0
#: field:account.partner.ledger,journal_ids:0
#: field:account.pl.report,journal_ids:0
@ -2800,6 +2819,17 @@ msgstr ""
#: model:ir.ui.menu,name:account.menu_action_account_journal_form
#: model:ir.ui.menu,name:account.menu_journals
#: model:ir.ui.menu,name:account.menu_journals_report
#: report:account.account.balance:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.central.journal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Journals"
msgstr ""
@ -3001,6 +3031,7 @@ msgstr ""
#. module: account
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
msgid "Counterpart"
msgstr ""
@ -3059,6 +3090,16 @@ msgstr ""
#: model:ir.actions.act_window,name:account.action_account_chart
#: model:ir.actions.act_window,name:account.action_account_tree
#: model:ir.ui.menu,name:account.menu_action_account_tree2
#: report:account.account.balance:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Chart of Accounts"
msgstr ""
@ -3477,11 +3518,10 @@ msgid "Analytic Balance"
msgstr ""
#. module: account
#: code:addons/account/report/account_balance_sheet.py:76
#: code:addons/account/report/account_balance_sheet.py:122
#: code:addons/account/report/account_profit_loss.py:76
#: code:addons/account/report/account_profit_loss.py:124
#, python-format
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Net Loss"
msgstr ""
@ -4267,7 +4307,6 @@ msgid "Analytic Balance -"
msgstr ""
#. module: account
#: report:account.account.balance:0
#: field:account.aged.trial.balance,target_move:0
#: field:account.balance.report,target_move:0
#: field:account.bs.report,target_move:0
@ -4280,10 +4319,8 @@ msgstr ""
#: field:account.common.report,target_move:0
#: report:account.general.journal:0
#: field:account.general.journal,target_move:0
#: report:account.general.ledger:0
#: report:account.journal.period.print:0
#: field:account.move.journal,target_move:0
#: report:account.partner.balance:0
#: field:account.partner.balance,target_move:0
#: field:account.partner.ledger,target_move:0
#: field:account.pl.report,target_move:0
@ -4293,6 +4330,16 @@ msgstr ""
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: field:account.vat.declaration,target_move:0
#: report:account.account.balance:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Target Moves"
msgstr ""
@ -4408,6 +4455,8 @@ msgstr ""
#: view:account.bs.report:0
#: model:ir.actions.act_window,name:account.action_account_bs_report
#: model:ir.ui.menu,name:account.menu_account_bs_report
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
msgid "Balance Sheet"
msgstr ""
@ -5081,6 +5130,19 @@ msgstr ""
#. module: account
#: code:addons/account/report/common_report_header.py:100
#, python-format
#: report:account.account.balance:0
#: report:account.central.journal:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
#: report:account.vat.declaration:0
msgid "No Filter"
msgstr ""
@ -5938,6 +6000,7 @@ msgstr ""
#. module: account
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: view:account.report.general.ledger:0
#: model:ir.actions.act_window,name:account.action_account_general_ledger_menu
#: model:ir.actions.report.xml,name:account.account_general_ledger
@ -6756,6 +6819,7 @@ msgstr ""
#: view:account.entries.report:0
#: field:account.entries.report,partner_id:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: view:account.invoice:0
#: field:account.invoice,partner_id:0
#: field:account.invoice.line,partner_id:0
@ -6997,6 +7061,19 @@ msgstr ""
#: field:account.tax.chart,period_id:0
#: code:addons/account/account_move_line.py:982
#: field:validate.account.move,period_id:0
#: report:account.account.balance:0
#: report:account.central.journal:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
#: report:account.vat.declaration:0
#, python-format
msgid "Period"
msgstr ""
@ -7067,14 +7144,6 @@ msgstr ""
msgid "Company Currency"
msgstr ""
#. module: account
#: report:account.general.ledger:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
msgid "Chart of Account"
msgstr ""
#. module: account
#: model:process.node,name:account.process_node_paymententries0
#: model:process.transition,name:account.process_transition_reconcilepaid0
@ -7181,6 +7250,12 @@ msgstr ""
#: report:account.central.journal:0
#: report:account.general.journal:0
#: report:account.partner.balance:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Filter By"
msgstr ""
@ -7405,6 +7480,7 @@ msgstr ""
#: field:account.entries.report,currency_id:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: field:account.invoice,currency_id:0
#: field:account.invoice.report,currency_id:0
#: field:account.journal,currency:0
@ -7658,12 +7734,17 @@ msgstr ""
#: report:account.account.balance:0
#: report:account.central.journal:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.journal.period.print:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.vat.declaration:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Start Period"
msgstr ""
@ -7775,7 +7856,12 @@ msgstr ""
#: report:account.central.journal:0
#: field:account.entries.report,balance:0
#: report:account.general.journal:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
#: field:account.move.line,balance:0
#: report:account.partner.balance:0
#: selection:account.payment.term.line,value:0
@ -7794,6 +7880,15 @@ msgstr ""
#. module: account
#: report:account.account.balance:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Display Account"
msgstr ""
@ -7991,12 +8086,17 @@ msgstr ""
#: report:account.account.balance:0
#: report:account.central.journal:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.journal.period.print:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.vat.declaration:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "End Period"
msgstr ""
@ -8186,6 +8286,7 @@ msgstr ""
#: field:account.entries.report,credit:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:account.journal.period.print:0
#: field:account.model.line,credit:0
#: field:account.move.line,credit:0
@ -8262,6 +8363,18 @@ msgstr ""
#: selection:account.pl.report,filter:0
#: selection:account.print.journal,filter:0
#: selection:account.report.general.ledger,filter:0
#: report:account.account.balance:0
#: report:account.central.journal:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
#: report:account.vat.declaration:0
#: view:account.vat.declaration:0
#: selection:account.vat.declaration,filter:0
@ -8463,13 +8576,10 @@ msgid "Tax Source"
msgstr ""
#. module: account
#: code:addons/account/report/account_balance_sheet.py:71
#: code:addons/account/report/account_balance_sheet.py:116
#: code:addons/account/report/account_balance_sheet.py:119
#: code:addons/account/report/account_balance_sheet.py:120
#: code:addons/account/report/account_profit_loss.py:71
#: code:addons/account/report/account_profit_loss.py:127
#, python-format
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "Net Profit"
msgstr ""
@ -8493,7 +8603,7 @@ msgstr ""
#: report:account.general.ledger:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
msgid "JNRL"
msgid "JRNL"
msgstr ""
#. module: account
@ -8695,6 +8805,7 @@ msgstr ""
#: field:account.entries.report,debit:0
#: report:account.general.journal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:account.journal.period.print:0
#: field:account.model.line,debit:0
#: field:account.move.line,debit:0
@ -8764,6 +8875,16 @@ msgstr ""
#: selection:account.common.account.report,display_account:0
#: selection:account.pl.report,display_account:0
#: selection:account.report.general.ledger,display_account:0
#: report:account.account.balance:0
#: report:account.partner.balance:0
#: report:account.third_party_ledger:0
#: report:account.third_party_ledger_other:0
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
#: report:account.general.ledger:0
#: report:account.general.ledger_landscape:0
#: report:pl.account:0
#: report:pl.account.horizontal:0
msgid "With movements"
msgstr ""
@ -9115,3 +9236,14 @@ msgstr ""
msgid "The residual amount on a receivable or payable of a journal entry expressed in its currency (maybe different of the company currency)."
msgstr ""
#. module: account
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
msgid "Assets"
msgstr ""
#. module: account
#: report:account.balancesheet:0
#: report:account.balancesheet.horizontal:0
msgid "Liabilities"
msgstr ""

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -65,21 +65,6 @@ class account_installer(osv.osv_memory):
user = self.pool.get('res.users').browse(cr, uid, uid, context=context)
return user.company_id and user.company_id.id or False
def _get_default_charts(self, cr, uid, context=None):
module_name = False
company_id = self._default_company(cr, uid, context=context)
company = self.pool.get('res.company').browse(cr, uid, company_id, context=context)
address_id = self.pool.get('res.partner').address_get(cr, uid, [company.partner_id.id])
if address_id['default']:
address = self.pool.get('res.partner.address').browse(cr, uid, address_id['default'], context=context)
code = address.country_id.code
module_name = (code and 'l10n_' + code.lower()) or False
if module_name:
module_id = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', module_name)], context=context)
if module_id:
return module_name
return 'configurable'
_defaults = {
'date_start': lambda *a: time.strftime('%Y-01-01'),
'date_stop': lambda *a: time.strftime('%Y-12-31'),
@ -87,7 +72,7 @@ class account_installer(osv.osv_memory):
'sale_tax': 0.0,
'purchase_tax': 0.0,
'company_id': _default_company,
'charts': _get_default_charts
'charts': 'configurable'
}
def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
@ -100,7 +85,7 @@ class account_installer(osv.osv_memory):
unconfigured_cmp = list(set(company_ids)-set(configured_cmp))
for field in res['fields']:
if field == 'company_id':
res['fields'][field]['domain'] = unconfigured_cmp
res['fields'][field]['domain'] = [('id','in',unconfigured_cmp)]
res['fields'][field]['selection'] = [('', '')]
if unconfigured_cmp:
cmp_select = [(line.id, line.name) for line in self.pool.get('res.company').browse(cr, uid, unconfigured_cmp)]

View File

@ -209,7 +209,7 @@ class account_invoice(osv.osv):
\n* The \'Open\' state is used when user create invoice,a invoice number is generated.Its in open state till user does not pay invoice. \
\n* The \'Paid\' state is set automatically when invoice is paid.\
\n* The \'Cancelled\' state is used when user cancel invoice.'),
'date_invoice': fields.date('Invoice Date', readonly=True, states={'draft':[('readonly',False)]}, select=True, help="Keep empty to use the current date"),
'date_invoice': fields.date('Invoice Date', states={'paid':[('readonly',True)], 'open':[('readonly',True)], 'close':[('readonly',True)]}, select=True, help="Keep empty to use the current date"),
'date_due': fields.date('Due Date', states={'paid':[('readonly',True)], 'open':[('readonly',True)], 'close':[('readonly',True)]}, select=True,
help="If you use payment terms, the due date will be computed automatically at the generation "\
"of accounting entries. If you keep the payment term and the due date empty, it means direct payment. The payment term may compute several due dates, for example 50% now, 50% in one month."),
@ -375,7 +375,7 @@ class account_invoice(osv.osv):
if t['state'] in ('draft', 'cancel') and t['internal_number']== False:
unlink_ids.append(t['id'])
else:
raise osv.except_osv(_('Invalid action !'), _('Cannot delete invoice(s) that are already opened(or been in opened state ever) or paid!'))
raise osv.except_osv(_('Invalid action !'), _('You can not delete an invoice which is open or paid. We suggest you to refund it instead.'))
osv.osv.unlink(self, cr, uid, unlink_ids, context=context)
return True
@ -828,7 +828,7 @@ class account_invoice(osv.osv):
total_percent += line.value_amount
total_fixed = (total_fixed * 100) / (inv.amount_total or 1.0)
if (total_fixed + total_percent) > 100:
raise osv.except_osv(_('Error !'), _("Cannot create the invoice !\nThe payment term defined gives a computed amount greater than the total invoiced amount."))
raise osv.except_osv(_('Error !'), _("Can not create the invoice !\nThe related payment term is probably misconfigured as it gives a computed amount greater than the total invoiced amount."))
# one move line per tax line
iml += ait_obj.move_line_get(cr, uid, inv.id)
@ -860,10 +860,10 @@ class account_invoice(osv.osv):
if totlines:
res_amount_currency = total_currency
i = 0
ctx.update({'date': inv.date_invoice})
for t in totlines:
if inv.currency_id.id != company_currency:
amount_currency = cur_obj.compute(cr, uid,
company_currency, inv.currency_id.id, t[1])
amount_currency = cur_obj.compute(cr, uid, company_currency, inv.currency_id.id, t[1], context=ctx)
else:
amount_currency = False
@ -910,7 +910,7 @@ class account_invoice(osv.osv):
journal = self.pool.get('account.journal').browse(cr, uid, journal_id)
if journal.centralisation:
raise osv.except_osv(_('UserError'),
_('Cannot create invoice move on centralised journal'))
_('You cannot create an invoice on a centralised journal. Uncheck the centralised counterpart box in the related journal from the configuration menu.'))
line = self.finalize_invoice_move_lines(cr, uid, inv, line)
@ -1019,7 +1019,7 @@ class account_invoice(osv.osv):
pay_ids = account_move_line_obj.browse(cr, uid, i['payment_ids'])
for move_line in pay_ids:
if move_line.reconcile_partial_id and move_line.reconcile_partial_id.line_partial_ids:
raise osv.except_osv(_('Error !'), _('You cannot cancel the Invoice which is Partially Paid! You need to unreconcile concerned payment entries!'))
raise osv.except_osv(_('Error !'), _('You can not cancel an invoice which is partially paid! You need to unreconcile related payment entries first!'))
# First, set the invoices as cancelled and detach the move ids
self.write(cr, uid, ids, {'state':'cancel', 'move_id':False})
@ -1241,6 +1241,7 @@ class account_invoice(osv.osv):
account_invoice()
class account_invoice_line(osv.osv):
def _amount_line(self, cr, uid, ids, prop, unknow_none, unknow_dict):
res = {}
tax_obj = self.pool.get('account.tax')

View File

@ -28,12 +28,17 @@ class account_fiscal_position(osv.osv):
_description = 'Fiscal Position'
_columns = {
'name': fields.char('Fiscal Position', size=64, required=True),
'active': fields.boolean('Active', help="By unchecking the active field, you may hide a fiscal position without deleting it."),
'company_id': fields.many2one('res.company', 'Company'),
'account_ids': fields.one2many('account.fiscal.position.account', 'position_id', 'Account Mapping'),
'tax_ids': fields.one2many('account.fiscal.position.tax', 'position_id', 'Tax Mapping'),
'note': fields.text('Notes', translate=True),
}
_defaults = {
'active': True,
}
def map_tax(self, cr, uid, fposition_id, taxes, context=None):
if not taxes:
return []

View File

@ -8,8 +8,11 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Fiscal Position">
<field name="name" select="1"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<group colspan="4" col="6">
<field name="name" select="1"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<field name="active" groups="base.group_extended"/>
</group>
<separator string="Mapping" colspan="4"/>
<newline/>
<field name="tax_ids" colspan="2" widget="one2many_list" nolabel="1">

View File

@ -28,15 +28,15 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Analytic Account">
<group col="8" colspan="4">
<group>
<filter icon="terp-gtk-media-pause" string="Pending" domain="[('state','=','pending')]" help="Pending Accounts"/>
<filter icon="terp-camera_test" string="Current" domain="[('state','=','open')]" help="Current Accounts"/>
<separator orientation="vertical"/>
<filter icon="terp-go-today" string="Overdue Account" domain="[('date','&lt;',time.strftime('%%Y-%%m-%%d'))]" help="Analytic Accounts with a past deadline."/>
<separator orientation="vertical"/>
<field name="name" select="1"/>
<field name="code" select="1"/>
<field name="partner_id" select="1"/>
<field name="name"/>
<field name="code"/>
<field name="partner_id"/>
<field name="user_id" widget="selection"/>
</group>
<newline/>
@ -204,7 +204,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Analytic Lines">
<group col='6' colspan='4'>
<group>
<filter name="sales" string="Sales" domain="[('journal_id.type','=','sale')]" icon="terp-camera_test" help="Analytic Journal Items related to a sale journal."/>
<filter name="purchases" string="Purchases" domain="[('journal_id.type','=','purchase')]" icon="terp-purchase" help="Analytic Journal Items related to a purchase journal."/>
<filter name="others" string="Others" domain="[('journal_id.type','in',('cash','general','situation'))]" icon="terp-folder-orange"/>
@ -430,13 +430,13 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Analytic Entries Stats">
<group col="8" colspan="4">
<group>
<filter icon="terp-go-year" string="This Year" domain="[('name','=',time.strftime('%%Y'))]" help="Sale journal in this year"/>
<filter icon="terp-go-month" string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Sale journal in this month"/>
<separator orientation="vertical"/>
<field name="name" select="1"/>
<field name="month" select="1"/>
<field name="account_id" select="1"/>
<field name="name"/>
<field name="month"/>
<field name="account_id"/>
</group>
</search>
</field>

View File

@ -29,7 +29,7 @@ class account_analytic_cost_ledger_journal_report(osv.osv_memory):
_columns = {
'date1': fields.date('Start of period', required=True),
'date2': fields.date('End of period', required=True),
'journal': fields.many2many('account.analytic.journal', 'ledger_journal_rel', 'ledger_id', 'Journal_id', 'Journals'),
'journal': fields.many2many('account.analytic.journal', 'ledger_journal_rel', 'ledger_id', 'journal_id', 'Journals'),
}
_defaults = {

View File

@ -42,6 +42,7 @@ import account_analytic_entries_report
import account_balance_sheet
import account_profit_loss
import account_treasury_report
import account_financial_report
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -112,7 +112,7 @@
<blockTable colWidths="110.0,110.0,110.0,110.0,128.0,93.0,110.0" style="Table8">
<tr>
<td>
<para style="terp_tblheader_General_Centre">Chart of Account</para>
<para style="terp_tblheader_General_Centre">Chart of Accounts</para>
</td>
<td>
<para style="terp_tblheader_General_Centre">Fiscal Year</para>
@ -196,25 +196,25 @@
<para style="Total">Account Total</para>
</td>
<td>
<para style="Total_right">[[ formatLang(get_direction('6')) ]] [[ company.currency_id.symbol ]]</para>
<para style="Total_right">[[ formatLang(get_direction('6'), currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="Total_right">[[ formatLang(get_for_period('4')) ]] [[ company.currency_id.symbol ]]</para>
<para style="Total_right">[[ formatLang(get_for_period('4'), currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="Total_right">[[ formatLang(get_for_period('3')) ]] [[ company.currency_id.symbol ]]</para>
<para style="Total_right">[[ formatLang(get_for_period('3'), currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="Total_right">[[ formatLang(get_for_period('2')) ]] [[ company.currency_id.symbol ]]</para>
<para style="Total_right">[[ formatLang(get_for_period('2'), currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="Total_right">[[ formatLang(get_for_period('1')) ]] [[ company.currency_id.symbol ]]</para>
<para style="Total_right">[[ formatLang(get_for_period('1'), currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="Total_right">[[ formatLang(get_for_period('0')) ]] [[ company.currency_id.symbol ]]</para>
<para style="Total_right">[[ formatLang(get_for_period('0'), currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="Total_right">[[ formatLang(get_total('5')) ]] [[ company.currency_id.symbol ]]</para>
<para style="Total_right">[[ formatLang(get_total('5'), currency_obj=company.currency_id) ]]</para>
</td>
</tr>
@ -224,25 +224,25 @@
<para style="P2_content">[[ partner['name'] ]]</para>
</td>
<td>
<para style="content">[[ formatLang(partner['direction']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(partner['direction'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(partner['4'])]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(partner['4'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(partner['3'])]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(partner['3'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(partner['2']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(partner['2'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(partner['1']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(partner['1'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(partner['0']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(partner['0'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(partner['total']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(partner['total'], currency_obj=company.currency_id) ]]</para>
</td>
</tr>
<tr>
@ -251,25 +251,25 @@
<para style="P2_content">[[ not_partner['name'] ]]</para>
</td>
<td>
<para style="content">[[ formatLang(not_partner['direction']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(not_partner['direction'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(not_partner['4'])]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(not_partner['4'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(not_partner['3'])]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(not_partner['3'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(not_partner['2']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(not_partner['2'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(not_partner['1']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(not_partner['1'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(not_partner['0']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(not_partner['0'], currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="content">[[ formatLang(not_partner['total']) ]] [[ company.currency_id.symbol ]]</para>
<para style="content">[[ formatLang(not_partner['total'], currency_obj=company.currency_id) ]]</para>
</td>
</tr>
</blockTable>

View File

@ -34,7 +34,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Analytic Entries Analysis">
<group col="10" colspan="12">
<group>
<filter icon="terp-go-year" string=" 365 Days "
domain="[('day','&lt;=', time.strftime('%%Y-%%m-%%d')),('day','&gt;',(datetime.date.today()-datetime.timedelta(days=365)).strftime('%%Y-%%m-%%d'))]"
help="Analytic Entries of last 365 days"/>
@ -44,7 +44,6 @@
help="Analytic Entries of last 30 days"/>
<filter icon="terp-go-week"
string=" 7 Days "
separator="1"
domain="[('day','&lt;=', time.strftime('%%Y-%%m-%%d')), ('day','&gt;',(datetime.date.today()-datetime.timedelta(days=7)).strftime('%%Y-%%m-%%d'))]"
help="Analytic Entries during last 7 days"/>
<separator orientation="vertical"/>

View File

@ -212,7 +212,7 @@
<blockTable colWidths="130.0,80.0,100.0,140.0,90.0" style="Table8">
<tr>
<td><para style="terp_tblheader_General_Centre">[[ data['model']=='account.account' and 'Company'or removeParentNode('para') ]]</para>
<para style="terp_tblheader_General_Centre"> [[ data['model']=='ir.ui.menu' and 'Chart of Account' or removeParentNode('para') ]]</para></td>
<para style="terp_tblheader_General_Centre"> [[ data['model']=='ir.ui.menu' and 'Chart of Accounts' or removeParentNode('para') ]]</para></td>
<td>
<para style="terp_tblheader_General_Centre">Fiscal Year</para>
</td>
@ -296,7 +296,7 @@
<td><para style="P14"><font>[[ (a['type']&lt;&gt;'view' and setTag('para','para',{'fontName':"Helvetica"})) or removeParentNode('font') ]]</font><font color="white">[[ '..'*(a['level']-1) ]]</font><font>[[ a['name'] ]]</font> </para></td>
<td><para style="P3"><font>[[ (a['type']&lt;&gt;'view' and setTag('para','para',{'fontName':"Helvetica"})) or removeParentNode('font') ]]</font><font>[[ a['type']=='view' and removeParentNode('font') ]][[ formatLang(a['debit']) ]]</font><font>[[ a['type']&lt;&gt;'view' and removeParentNode('font') ]] [[formatLang(a['debit']) ]]</font></para></td>
<td><para style="P3"><font>[[ (a['type']&lt;&gt;'view' and setTag('para','para',{'fontName':"Helvetica"})) or removeParentNode('font')]]</font><font>[[ a['type']=='view' and removeParentNode('font') ]][[ formatLang(a['credit']) ]]</font><font>[[ a['type']&lt;&gt;'view' and removeParentNode('font') ]] [[ formatLang(a['credit']) ]]</font> </para></td>
<td><para style="P3"><font>[[ (a['type']&lt;&gt;'view' and setTag('para','para',{'fontName':"Helvetica"})) or removeParentNode('font') ]]</font><font>[[ a['type']=='view' and removeParentNode('font') ]][[ formatLang(a['balance']) ]] [[ company.currency_id.symbol ]]</font><font>[[ a['type']&lt;&gt;'view' and removeParentNode('font') ]] [[ formatLang(a['balance']) ]] [[ company.currency_id.symbol ]]</font> </para></td>
<td><para style="P3"><font>[[ (a['type']&lt;&gt;'view' and setTag('para','para',{'fontName':"Helvetica"})) or removeParentNode('font') ]]</font><font>[[ a['type']=='view' and removeParentNode('font') ]][[ formatLang(a['balance'], currency_obj=company.currency_id) ]]</font><font>[[ a['type']&lt;&gt;'view' and removeParentNode('font') ]] [[ formatLang(a['balance'], currency = company.currency_id) ]]</font> </para></td>
</tr>
</blockTable>
<para style="P11">

View File

@ -136,7 +136,7 @@ class report_balancesheet_horizontal(report_sxw.rml_parse, common_report_header)
'code': account.code,
'name': account.name,
'level': account.level,
'balance':account.balance,
'balance': account.balance != 0 and account.balance * account.user_type.sign or account.balance,
'type': account.type,
}
currency = account.currency_id and account.currency_id or account.company_id.currency_id

View File

@ -172,9 +172,9 @@
</para>
<blockTable colWidths="120.0,100.0,140.0,90.0,90.0" style="Table2_header" >
<tr>
<td><para style="terp_tblheader_General_Centre">Chart of Account </para></td>
<td><para style="terp_tblheader_General_Centre">Chart of Accounts</para></td>
<td><para style="terp_tblheader_General_Centre">Fiscal Year</para></td>
<td><para style="terp_tblheader_General_Centre">Filter By <font>[[ get_filter(data)!='No Filter' and '' or removeParentNode('font') ]]</font></para></td>
<td><para style="terp_tblheader_General_Centre">Filter By [[ get_filter(data)!='No Filter' and get_filter(data) ]]</para></td>
<td><para style="terp_tblheader_General_Centre">Display Account</para></td>
<td><para style="terp_tblheader_General_Centre">Target Moves</para></td>
</tr>
@ -236,12 +236,12 @@
</td>
</tr>
<tr style="Table3">
[[ repeatIn(get_lines_another('asset'),'a' ) ]]
[[ repeatIn(get_lines_another('asset'),'a' ) ]]
[[ setTag('tr','tr',{'style': 'Table'+str(min(3,a['level']))}) ]]
<td><para style="terp_level_3_code">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_3_code_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_code'}) ]]<i>[[ a['code'] ]]</i></para></td>
<td><para style="terp_level_3_name">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_name_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(4,a['level']))+'_name'}) ]][[ a['name'] ]]</para></td>
<td>[[ (a['level'] &lt;&gt;2) or removeParentNode('td') ]]<para style="terp_level_3_balance">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_3_balance_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_balance'}) ]][[ formatLang(a['balance']) ]] [[company.currency_id.symbol ]]</para></td>
<td>[[ a['level'] == 2 or removeParentNode('td') ]]<para style="terp_level_2_balance"><u>[[ formatLang(a['balance']) ]] [[company.currency_id.symbol ]]</u></para></td>
<td>[[ (a['level'] &lt;&gt;2) or removeParentNode('td') ]]<para style="terp_level_3_balance">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_3_balance_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_balance'}) ]][[ formatLang(a['balance'], currency_obj = company.currency_id) ]]</para></td>
<td>[[ a['level'] == 2 or removeParentNode('td') ]]<para style="terp_level_2_balance"><u>[[ formatLang(a['balance'], currency_obj = company.currency_id) ]]</u></para></td>
</tr>
</blockTable>
<blockTable colWidths="426.0,113.0" style="Table_Net_Profit_Loss">
@ -250,7 +250,7 @@
<para style="terp_default_Bold_9">Balance:</para>
</td>
<td>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_cr()) ]] [[ company.currency_id.symbol ]]</u></para>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_cr(), currency_obj = company.currency_id) ]]</u></para>
</td>
</tr>
</blockTable>
@ -278,12 +278,12 @@
</td>
</tr>
<tr style="Table3">
[[ repeatIn(get_lines_another('liability'),'a' ) ]]
[[ repeatIn(get_lines_another('liability'),'a' ) ]]
[[ setTag('tr','tr',{'style': 'Table'+str(min(3,a['level']))}) ]]
<td><para style="terp_level_3_code">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_3_code_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_code'}) ]]<i>[[ a['code'] ]]</i></para></td>
<td><para style="terp_level_3_name">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_name_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(4,a['level']))+'_name'}) ]][[ a['name'] ]]</para></td>
<td>[[ (a['level'] &lt;&gt;2) or removeParentNode('td') ]]<para style="terp_level_3_balance">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_3_balance_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_balance'}) ]][[ formatLang(a['balance']) ]] [[company.currency_id.symbol ]]</para></td>
<td>[[ a['level'] == 2 or removeParentNode('td') ]]<para style="terp_level_2_balance"><u>[[ formatLang(a['balance']) ]] [[company.currency_id.symbol ]]</u></para></td>
<td>[[ (a['level'] &lt;&gt;2) or removeParentNode('td') ]]<para style="terp_level_3_balance">[[ (a['type'] =='view' and a['level'] &gt;= 3) and setTag('para','para',{'style': 'terp_level_3_balance_bold'}) or setTag('para','para',{'style': 'terp_level_'+str(min(3,a['level']))+'_balance'}) ]][[ formatLang(a['balance'], currency_obj = company.currency_id) ]]</para></td>
<td>[[ a['level'] == 2 or removeParentNode('td') ]]<para style="terp_level_2_balance"><u>[[ formatLang(a['balance'], currency_obj = company.currency_id) ]]</u></para></td>
</tr>
</blockTable>
<blockTable colWidths="426.0,113.0" style="Table_Net_Profit_Loss">
@ -292,7 +292,7 @@
<para style="terp_default_Bold_9">Balance:</para>
</td>
<td>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_dr()) ]] [[ company.currency_id.symbol ]]</u></para>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_dr(), currency_obj = company.currency_id) ]]</u></para>
</td>
</tr>
</blockTable>

View File

@ -132,7 +132,7 @@
<blockTable colWidths="250.0,100.0,150.0,120.0,150.0" style="Table2_header" >
<tr>
<td><para style="terp_tblheader_General_Centre">Chart of Account </para></td>
<td><para style="terp_tblheader_General_Centre">Chart of Accounts</para></td>
<td><para style="terp_tblheader_General_Centre">Fiscal Year</para></td>
<td><para style="terp_tblheader_General_Centre">Filter By [[ get_filter(data)!='No Filter' and get_filter(data) ]]</para></td>
<td><para style="terp_tblheader_General_Centre">Display Account</para></td>
@ -196,40 +196,52 @@
</tr>
<tr>
<td>
<para style="terp_default_9"><font>[[ a['level']&lt;4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]]</font><font>[[ a['code1'] ]]</font></para>
<para style="terp_default_9">
<font>[[ repeatIn(get_lines(),'a' ) ]] </font>[[ a['code1'] ]]<font>[[ a['level1']&lt;4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]]</font>
</para>
</td>
<td>
<para style="terp_default_9"><font color="white">[[ '. '*(a['level1']-1) ]]</font><font>[[ a['level1']&lt;4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name1'] ]]</font></para>
<para style="terp_default_9">
<font color="white">[[ '. '*(a['level1']-1) ]]</font><font>[[ a['level1']&lt;4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name1'] ]]</font>
</para>
</td>
<td>
<para style="terp_default_Right_9"><font>[[ a['level1']&lt;4 and ( setTag('para','para',{'style':'terp_default_Right_9_Bold'})) or removeParentNode('font') ]]</font><font>[[ formatLang(a['balance1']) ]] [[ company.currency_id.symbol ]]</font></para>
<para style="terp_default_Right_9">
<font>[[ a['level1']&lt;4 and ( setTag('para','para',{'style':'terp_default_Right_9_Bold'})) or removeParentNode('font') ]]</font><font>[[ formatLang(a['balance1'], currency_obj=company.currency_id) ]]</font>
</para>
</td>
<td>
<para style="terp_default_9"><font face="Times-Roman">[[ repeatIn(get_lines(), 'a') ]]</font> <font>[[ a['level']&lt;4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]]</font><font>[[ a['code'] ]]</font><font>[[ a['name']=='Net Profit' and setTag('para','para',{'style':'terp_default_Bold_9'}) or removeParentNode('font') ]]</font></para>
<para style="terp_default_9">
[[ a['code'] ]]<font>[[ ( a['level']&lt;4 or a['name']=='Net Profit') and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]]</font>
</para>
</td>
<td>
<para style="terp_default_9"><font color="white">[[ '. '*(a['level']-1) ]]</font><font>[[ a['level']&lt;4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name'] ]]</font><font>[[ a['name']=='Net Profit' and setTag('para','para',{'style':'terp_default_Bold_9'}) or removeParentNode('font') ]]</font></para>
<para style="terp_default_9">
<font color="white">[[ '. '*(a['level']-1) ]]</font>
<font>[[ ( a['level']&lt;4 or a['name']=='Net Profit') and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name'] ]]</font>
</para>
</td>
<td>
<para style="terp_default_Right_9"><font>[[ a['level1']&lt;4 and ( setTag('para','para',{'style':'terp_default_Right_9_Bold'})) or removeParentNode('font') ]]</font>
<font>[[ a['name']=='Net Profit' and setTag('para','para',{'style':'terp_default_Right_9_Bold'}) or removeParentNode('font') ]]</font>
<font> [[(a['code'] and a['name']) and formatLang(a['balance']) or removeParentNode('font')]] [[ company.currency_id.symbol ]]</font></para>
<para style="terp_default_Right_9">
<font>[[ ( a['level']&lt;4 or a['name']=='Net Profit') and ( setTag('para','para',{'style':'terp_default_Right_9_Bold'})) or removeParentNode('font') ]]</font>
<font>[[(a['code'] and a['name']) and formatLang(a['balance'], currency_obj=company.currency_id) or removeParentNode('font')]]</font>
</para>
</td>
</tr>
</blockTable>
<blockTable colWidths="290.16,100.32,290.16,100.32" style="Table_Net_Profit_Loss">
</tr>
</blockTable>
<blockTable colWidths="290.16,100.32,290.16,100.32" style="Table_Net_Profit_Loss">
<tr>
<td>
<para style="terp_default_Bold_9">Balance:</para>
</td>
<td>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_cr()) ]] [[ company.currency_id.symbol ]]</u></para>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_cr(), currency_obj=company.currency_id) ]]</u></para>
</td>
<td>
<para style="terp_default_Bold_9">Balance:</para>
</td>
<td>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_dr()) ]] [[ company.currency_id.symbol ]]</u></para>
<para style="terp_default_Right_9_Bold"><u>[[ formatLang(sum_dr(), currency_obj=company.currency_id) ]]</u></para>
</td>
</tr>
</blockTable>

View File

@ -235,8 +235,7 @@
</blockTable>
<blockTable colWidths="130.0,80.0,100.0,130.0,100.0" style="Table2">
<tr>
<td><para style="terp_tblheader_General_Centre">[[ data['model']=='account.journal.period' and 'Company' or removeParentNode('para') ]]</para>
<para style="terp_tblheader_General_Centre"> [[ data['model']=='ir.ui.menu' and 'Chart of Account' or removeParentNode('para') ]]</para></td>
<td><para style="terp_tblheader_General_Centre">Chart of Accounts</para></td>
<td><para style="terp_tblheader_General_Centre">Fiscal Year</para></td>
<td><para style="terp_tblheader_General_Centre">Journal</para></td>
<td><para style="terp_tblheader_General_Centre">Filter By [[get_filter(data)!='No Filter' and get_filter(data) ]]</para></td>
@ -299,7 +298,7 @@
<td><para style="terp_default_Bold_9"><font color="white"> </font></para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_debit(o.period_id.id, o.journal_id.id)) ]] </para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit(o.period_id.id, o.journal_id.id)) ]] </para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit(o.period_id.id, o.journal_id.id)-sum_debit(o.period_id.id, o.journal_id.id) ) ]] [[ company.currency_id.symbol ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit(o.period_id.id, o.journal_id.id)-sum_debit(o.period_id.id, o.journal_id.id), currency_obj=company.currency_id ) ]]</para></td>
</tr>
</blockTable>
<blockTable colWidths="50.0,180.0,80.0,80.0,80.0,80.0" style="Table_Final_Total_currency">[[ display_currency(data) or removeParentNode('blockTable') ]]
@ -308,7 +307,7 @@
<td><para style="terp_default_Bold_9"><font color="white"> </font></para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_debit(o.period_id.id, o.journal_id.id)) ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit(o.period_id.id, o.journal_id.id)) ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit(o.period_id.id, o.journal_id.id)-sum_debit(o.period_id.id, o.journal_id.id) ) ]] [[ company.currency_id.symbol ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit(o.period_id.id, o.journal_id.id)-sum_debit(o.period_id.id, o.journal_id.id), currency_obj=company.currency_id ) ]]</para></td>
<td><para style="terp_default_Bold_9"><font color="white"> </font></para></td>
</tr>
</blockTable>
@ -320,7 +319,7 @@
<td><para style="terp_default_9">[[ line['name'] ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['debit']) ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit'])]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit']) ]] [[ company.currency_id.symbol ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit'], currency_obj=company.currency_id ) ]]</para></td>
</tr>
</blockTable>
<blockTable colWidths="50.0,180.0,80.0,80.0,80.0,80.0" style="Table_Journal_Line_Content_currency">[[ display_currency(data) or removeParentNode('blockTable') ]]
@ -329,7 +328,7 @@
<td><para style="terp_default_9">[[ line['name'] ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['debit']) ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit'])]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit']) ]] [[ company.currency_id.symbol ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit'], currency_obj=company.currency_id ) ]]</para></td>
<td><para style="terp_default_Right_9"><font>[[ (line['currency_id']==None or line['amount_currency']==None) and removeParentNode('font') ]] [[ formatLang(line['amount_currency'] ) ]] [[ line['currency_code'] or '' ]]</font></para></td>
</tr>
</blockTable>

View File

@ -67,7 +67,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Entries Analysis">
<group colspan="10" col="12">
<group>
<filter icon="terp-go-year" string="This F.Year"
name="thisyear"
context="{'year':'current_year'}"

View File

@ -0,0 +1,94 @@
##############################################################################
#
# 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/>.
#
##############################################################################
import time
from report import report_sxw
from common_report_header import common_report_header
from tools.translate import _
class report_account_common(report_sxw.rml_parse, common_report_header):
def __init__(self, cr, uid, name, context=None):
super(report_account_common, self).__init__(cr, uid, name, context=context)
self.localcontext.update( {
'get_lines': self.get_lines,
'time': time,
'get_fiscalyear': self._get_fiscalyear,
'get_account': self._get_account,
'get_start_period': self.get_start_period,
'get_end_period': self.get_end_period,
'get_filter': self._get_filter,
'get_start_date':self._get_start_date,
'get_end_date':self._get_end_date,
})
self.context = context
def set_context(self, objects, data, ids, report_type=None):
new_ids = ids
if (data['model'] == 'ir.ui.menu'):
new_ids = 'chart_account_id' in data['form'] and [data['form']['chart_account_id']] or []
objects = self.pool.get('account.account').browse(self.cr, self.uid, new_ids)
return super(report_account_common, self).set_context(objects, data, new_ids, report_type=report_type)
def get_lines(self, data):
lines = []
account_obj = self.pool.get('account.account')
currency_obj = self.pool.get('res.currency')
ids2 = self.pool.get('account.financial.report')._get_children_by_order(self.cr, self.uid, [data['form']['account_report_id'][0]], context=data['form']['used_context'])
for report in self.pool.get('account.financial.report').browse(self.cr, self.uid, ids2, context=data['form']['used_context']):
vals = {
'name': report.name,
'balance': report.balance,
'type': 'report',
'level': report.level,
}
if data['form']['enable_filter']:
vals['balance_cmp'] = self.pool.get('account.financial.report').browse(self.cr, self.uid, report.id, context=data['form']['comparison_context']).balance
lines.append(vals)
account_ids = []
if report.type == 'accounts' and report.display_detail and report.account_ids:
account_ids = account_obj._get_children_and_consol(self.cr, self.uid, [x.id for x in report.account_ids])
elif report.type == 'account_type' and report.account_type_ids:
account_ids = account_obj.search(self.cr, self.uid, [('user_type','in', [x.id for x in report.account_type_ids])])
if account_ids:
for account in account_obj.browse(self.cr, self.uid, account_ids, context=data['form']['used_context']):
if account.type != 'view':
flag = False
vals = {
'name': account.code + ' ' + account.name,
'balance': account.balance != 0 and account.balance * account.user_type.sign or account.balance,
'type': 'account',
'level': 6,
'account_type': account.type,
}
if not currency_obj.is_zero(self.cr, self.uid, account.company_id.currency_id, vals['balance']):
flag = True
if data['form']['enable_filter']:
vals['balance_cmp'] = account_obj.browse(self.cr, self.uid, account.id, context=data['form']['comparison_context']).balance
if not currency_obj.is_zero(self.cr, self.uid, account.company_id.currency_id, vals['balance_cmp']):
flag = True
if flag:
lines.append(vals)
return lines
report_sxw.report_sxw('report.account.financial.report', 'account.financial.report',
'addons/account/report/account_financial_report.rml', parser=report_account_common, header='internal')

View File

@ -0,0 +1,272 @@
<?xml version="1.0"?>
<document filename="Financial Report.pdf">
<template pageSize="(595.0,842.0)" title="Financial Report" author="OpenERP S.A. (sales@openerp.com)" allowSplitting="20">
<pageTemplate id="first">
<frame id="first" x1="28.0" y1="28.0" width="539" height="786"/>
</pageTemplate>
</template>
<stylesheet>
<blockTableStyle id="Standard_Outline">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
</blockTableStyle>
<blockTableStyle id="Table_Heading">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
</blockTableStyle>
<blockTableStyle id="Table_Company_Name">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
</blockTableStyle>
<blockTableStyle id="Table_Date_from_To">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
</blockTableStyle>
<blockTableStyle id="Table_Account_Line_Title">
<blockAlignment value="LEFT"/>
<blockValign value="MIDDLE"/>
<lineStyle kind="LINEBELOW" colorName="#000000" start="0,0" stop="-1,0"/>
</blockTableStyle>
<blockTableStyle id="Table3">
<blockAlignment value="LEFT"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="1,0" stop="1,-1"/>
</blockTableStyle>
<blockTableStyle id="Table6">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
</blockTableStyle>
<blockTableStyle id="Table_Net_Profit_Loss">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="0,0" stop="-1,-1"/>
</blockTableStyle>
<blockTableStyle id="Table4">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="0,0" stop="-1,-1"/>
</blockTableStyle>
<blockTableStyle id="Table_Final_Result">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="0,0" stop="0,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="0,0" stop="0,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="0,-1" stop="0,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="1,0" stop="1,-1"/>
<lineStyle kind="LINEAFTER" colorName="#cccccc" start="1,0" stop="1,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="1,0" stop="1,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="1,-1" stop="1,-1"/>
</blockTableStyle>
<blockTableStyle id="Table2_header">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="0,0" stop="-1,0"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="0,0" stop="0,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="0,0" stop="0,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="0,-1" stop="0,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="1,0" stop="1,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="1,0" stop="1,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="1,-1" stop="1,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="2,0" stop="2,-1"/>
<lineStyle kind="LINEAFTER" colorName="#cccccc" start="2,0" stop="2,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="2,0" stop="2,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="2,-1" stop="2,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="3,0" stop="3,-1"/>
<lineStyle kind="LINEAFTER" colorName="#cccccc" start="3,0" stop="3,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="3,0" stop="3,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="3,-1" stop="3,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="4,0" stop="4,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="4,0" stop="4,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="4,-1" stop="4,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="5,0" stop="5,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="5,0" stop="5,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="5,-1" stop="5,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="6,0" stop="6,-1"/>
<lineStyle kind="LINEAFTER" colorName="#cccccc" start="6,0" stop="6,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="6,0" stop="6,0"/>
<lineStyle kind="LINEBELOW" colorName="#cccccc" start="6,-1" stop="6,-1"/>
<lineStyle kind="LINEBEFORE" colorName="#cccccc" start="7,0" stop="7,-1"/>
<lineStyle kind="LINEAFTER" colorName="#cccccc" start="7,0" stop="7,-1"/>
<lineStyle kind="LINEABOVE" colorName="#cccccc" start="7,0" stop="7,0"/>
</blockTableStyle>
<initialize>
<paraStyle name="all" alignment="justify"/>
</initialize>
<paraStyle name="P1" rightIndent="2.0" leftIndent="0.0" fontName="Helvetica-Bold" fontSize="9.0" leading="11" alignment="RIGHT" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="P2" fontName="Helvetica" fontSize="9.0" leading="11" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="Standard" fontName="Times-Roman"/>
<paraStyle name="Heading" fontName="Helvetica" fontSize="12.0" leading="15" spaceBefore="12.0" spaceAfter="6.0"/>
<paraStyle name="Text body" fontName="Times-Roman" spaceBefore="0.0" spaceAfter="6.0"/>
<paraStyle name="List" fontName="Helvetica" spaceBefore="0.0" spaceAfter="6.0"/>
<paraStyle name="Caption" fontName="Helvetica-Oblique" fontSize="8.0" leading="10" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="Index" fontName="Helvetica" fontSize="9.0" leading="11"/>
<paraStyle name="Footer" fontName="Times-Roman"/>
<paraStyle name="Table Contents" fontName="Times-Roman"/>
<paraStyle name="Table Heading" fontName="Times-Roman" alignment="CENTER"/>
<paraStyle name="Horizontal Line" fontName="Times-Roman" fontSize="6.0" leading="8" spaceBefore="0.0" spaceAfter="14.0"/>
<paraStyle name="terp_header" fontName="Helvetica-Bold" fontSize="15.0" leading="19" alignment="LEFT" spaceBefore="12.0" spaceAfter="6.0"/>
<paraStyle name="Heading 9" fontName="Helvetica-Bold" fontSize="75%" leading="NaN" spaceBefore="12.0" spaceAfter="6.0"/>
<paraStyle name="terp_tblheader_General" fontName="Helvetica-Bold" fontSize="8.0" leading="10" alignment="LEFT" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="terp_tblheader_Details" fontName="Helvetica-Bold" fontSize="9.0" leading="11" alignment="LEFT" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="terp_default_8" fontName="Helvetica" fontSize="8.0" leading="10" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_Bold_8" fontName="Helvetica-Bold" fontSize="8.0" leading="10" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_tblheader_General_Centre" fontName="Helvetica-Bold" fontSize="8.0" leading="10" alignment="CENTER" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="terp_tblheader_General_Right" fontName="Helvetica-Bold" fontSize="8.0" leading="10" alignment="RIGHT" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="terp_tblheader_Details_Centre" fontName="Helvetica-Bold" fontSize="9.0" leading="11" alignment="CENTER" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="terp_tblheader_Details_Right" fontName="Helvetica-Bold" fontSize="9.0" leading="11" alignment="RIGHT" spaceBefore="6.0" spaceAfter="6.0"/>
<paraStyle name="terp_default_Right_8" fontName="Helvetica" fontSize="8.0" leading="10" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_Centre_8" fontName="Helvetica" fontSize="8.0" leading="10" alignment="CENTER" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_header_Right" fontName="Helvetica-Bold" fontSize="15.0" leading="19" alignment="LEFT" spaceBefore="12.0" spaceAfter="6.0"/>
<paraStyle name="terp_header_Centre" fontName="Helvetica-Bold" fontSize="15.0" leading="19" alignment="CENTER" spaceBefore="12.0" spaceAfter="6.0"/>
<paraStyle name="terp_default_address" fontName="Helvetica" fontSize="10.0" leading="13" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_9" fontName="Helvetica" fontSize="9.0" leading="11" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_Bold_9" fontName="Helvetica-Bold" fontSize="9.0" leading="11" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_Centre_9" fontName="Helvetica" fontSize="9.0" leading="11" alignment="CENTER" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_Right_9" fontName="Helvetica" fontSize="9.0" leading="11" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_Right_9_Bold" fontName="Helvetica-Bold" fontSize="9.0" leading="11" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_default_2" fontName="Helvetica" fontSize="2.0" leading="3" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_0_name" fontName="Helvetica-Bold" fontSize="9.0" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_0_balance" fontName="Helvetica-Bold" fontSize="9.0" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_1_name" fontName="Helvetica-Bold" fontSize="9.0" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_1_balance" fontName="Helvetica-Bold" fontSize="9.0" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_2_name" fontName="Helvetica-Bold" fontSize="8.0" leftIndent="10.0" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_2_balance" fontName="Helvetica-Bold" fontSize="8.0" leftIndent=".0" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_3_name" fontName="Helvetica-Bold" fontSize="8.0" leftIndent="20.0" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_3_balance" fontName="Helvetica-Bold" fontSize="8.0" leftIndent=".0" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_4_name" fontName="Helvetica" fontSize="8.0" leftIndent="30.0" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_4_balance" fontName="Helvetica" fontSize="8.0" leftIndent="0.0" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_5_name" fontName="Helvetica" fontSize="8.0" leftIndent="40.0" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_5_balance" fontName="Helvetica-Oblique" fontSize="8.0" leftIndent="0.0" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_6_name" fontName="Helvetica" fontSize="8.0" leftIndent="50.0" alignment="LEFT" spaceBefore="0.0" spaceAfter="0.0"/>
<paraStyle name="terp_level_6_balance" fontName="Helvetica" fontSize="8.0" leftIndent="0.0" alignment="RIGHT" spaceBefore="0.0" spaceAfter="0.0"/>
<blockTableStyle id="Table1">
<blockTopPadding start="0,0" stop="-1,0" length="15"/>
<blockFont name="Helvetica-Bold" size="10.0" />
<lineStyle kind="LINEBELOW" colorName="#000000" start="0,0" stop="-1,1" thickness="1"/>
</blockTableStyle>
<blockTableStyle id="Table2">
<blockTopPadding start="0,0" stop="-1,0" length="10"/>
<blockAlignment value="LEFT"/>
<lineStyle kind="LINEBELOW" colorName="#666666" start="1,1" stop="1,1"/>
</blockTableStyle>
<blockTableStyle id="Table3">
<blockValign value="TOP"/>
</blockTableStyle>
<blockTableStyle id="Table2_Report">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
<lineStyle kind="GRID" colorName="#cccccc"/>
</blockTableStyle>
<blockTableStyle id="Table1_main">
<blockAlignment value="LEFT"/>
<blockValign value="TOP"/>
</blockTableStyle>
</stylesheet>
<images/>
<story>
<blockTable colWidths="539.0" style="Table_Company_Name">
<tr>
<td>
<para style="terp_header_Centre">[[ data['form']['account_report_id'][1] ]]</para>
</td>
</tr>
</blockTable>
<para style="Standard">
<font color="white"> </font>
</para>
<blockTable colWidths="163.0,163.0,163.0" style="Table2_header">
<tr>
<td><para style="terp_tblheader_General_Centre">Chart of Account </para></td>
<td><para style="terp_tblheader_General_Centre">Fiscal Year</para></td>
<td><para style="terp_tblheader_General_Centre">Filter By [[ get_filter(data)!='No Filter' and get_filter(data) ]]</para></td>
</tr>
<tr>
<td><para style="terp_default_Centre_8">[[ get_account(data) or removeParentNode('para') ]]</para></td>
<td><para style="terp_default_Centre_8">[[ get_fiscalyear(data) or '' ]]</para></td>
<td><para style="terp_default_Centre_8">[[ get_filter(data)=='No Filter' and get_filter(data) or removeParentNode('para') ]] </para>
<blockTable colWidths="60.0,60.0" style="Table3">[[ get_filter(data)=='Date' or removeParentNode('blockTable') ]]
<tr>
<td><para style="terp_tblheader_General_Centre">Start Date</para></td>
<td><para style="terp_tblheader_General_Centre">End Date</para></td>
</tr>
<tr>
<td><para style="terp_default_Centre_8">[[ formatLang(get_start_date(data),date=True) ]]</para></td>
<td><para style="terp_default_Centre_8">[[ formatLang(get_end_date(data),date=True) ]]</para></td>
</tr>
</blockTable>
<blockTable colWidths="65.0,60.0" style="Table3">[[ get_filter(data)=='Periods' or removeParentNode('blockTable') ]]
<tr>
<td><para style="terp_tblheader_General_Centre">Start Period</para></td>
<td><para style="terp_tblheader_General_Centre">End Period</para></td>
</tr>
<tr>
<td><para style="terp_default_Centre_8">[[ get_start_period(data) or removeParentNode('para') ]]</para></td>
<td><para style="terp_default_Centre_8">[[ get_end_period(data) or removeParentNode('para') ]]</para></td>
</tr>
</blockTable>
</td>
</tr>
</blockTable>
<para style="Standard">
<font color="white"> </font>
</para>
<para style="Standard">
<font color="white"> </font>
</para>
<blockTable colWidths="390.0,100.0" style="Table_Account_Line_Title">
[[ data['form']['enable_filter'] == 0 or removeParentNode('blockTable') ]]
<tr>
<td>
<para style="terp_default_Bold_9">Name</para>
</td>
<td>
<para style="terp_tblheader_Details_Right">Balance</para>
</td>
</tr>
<tr style="Table1">
[[ repeatIn(get_lines(data), 'a') ]]
[[ (a.get('level') &lt;&gt; 0) or removeParentNode('tr') ]]
[[ setTag('tr','tr',{'style': 'Table'+str(min(3,'level' in a and a.get('level') or 1))}) ]]
<td><para style="terp_level_1_name">[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_name'}) ]] [[ a.get('name') ]]</para></td>
<td>[[ a.get('level') == 4 or removeParentNode('td') ]]<para style="terp_level_1_balance"><u>[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_balance'}) ]][[ formatLang(a.get('balance'))]] [[company.currency_id.symbol]]</u></para></td>
<td>[[ a.get('level') &lt;&gt; 4 or removeParentNode('td') ]]<para style="terp_level_1_balance">[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_balance'}) ]][[ formatLang(a.get('balance'))]] [[company.currency_id.symbol]]</para></td>
</tr>
</blockTable>
<para style="Standard">
<font color="white"> </font>
</para>
<blockTable colWidths="263.0,100.0,100" style="Table_Account_Line_Title">
[[ data['form']['enable_filter'] == 1 or removeParentNode('blockTable') ]]
<tr>
<td>
<para style="terp_default_Bold_9">Name</para>
</td>
<td>
<para style="terp_tblheader_Details_Right">Balance</para>
</td>
<td>
<para style="terp_tblheader_Details_Right">[[ data['form']['label_filter'] ]]</para>
</td>
</tr>
<tr style="Table3">
[[ repeatIn(get_lines(data), 'a') ]]
[[ (a.get('level') &lt;&gt; 0) or removeParentNode('tr') ]]
[[ setTag('tr','tr',{'style': 'Table'+str(min(3,'level' in a and a.get('level') or 1))}) ]]
<td><para style="terp_level_1_name">[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_name'}) ]] [[ a.get('name') ]]</para></td>
<td>[[ a.get('level') == 4 or removeParentNode('td') ]]<para style="terp_level_1_balance"><u>[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_balance'}) ]][[ formatLang(a.get('balance'))]] [[company.currency_id.symbol]]</u></para></td>
<td>[[ a.get('level') &lt;&gt; 4 or removeParentNode('td') ]]<para style="terp_level_1_balance">[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_balance'}) ]][[ formatLang(a.get('balance'))]] [[company.currency_id.symbol]]</para></td>
<td>[[ a.get('level') == 4 or removeParentNode('td') ]]<para style="terp_level_1_balance"><u>[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_balance'}) ]][[ formatLang(a.get('balance_cmp'))]] [[company.currency_id.symbol]]</u></para></td>
<td>[[ a.get('level') &lt;&gt; 4 or removeParentNode('td') ]]<para style="terp_level_1_balance">[[ setTag('para','para',{'style': 'terp_level_'+str(min(6,a['level']))+'_balance'}) ]][[ formatLang(a.get('balance_cmp'))]] [[company.currency_id.symbol]]</para></td>
</tr>
</blockTable>
<para style="Standard">
<font color="white"> </font>
</para>
</story>
</document>

View File

@ -221,7 +221,7 @@
<blockTable colWidths="80.0,100,80.0,150.0,100.0" style="Table2">
<tr>
<td><para style="terp_tblheader_General_Centre">[[ data['model']=='account.journal.period' and 'Company' or removeParentNode('para') ]]</para>
<para style="terp_tblheader_General_Centre"> [[ data['model']=='ir.ui.menu' and 'Chart of Account' or removeParentNode('para') ]]</para></td>
<para style="terp_tblheader_General_Centre"> [[ data['model']=='ir.ui.menu' and 'Chart of Accounts' or removeParentNode('para') ]]</para></td>
<td><para style="terp_tblheader_General_Centre">Fiscal Year</para></td>
<td><para style="terp_tblheader_General_Centre">Journals</para></td>
<td><para style="terp_tblheader_General_Centre">Filter By [[ get_filter(data)!='No Filter' and get_filter(data) ]]</para></td>
@ -273,7 +273,7 @@
<td><para style="terp_default_Bold_9"><font color="white"> </font></para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang(sum_debit()) ]] </para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit()) ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_debit()- sum_credit()) ]] [[ company.currency_id.symbol ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_debit()- sum_credit(), currency_obj=company.currency_id) ]]</para></td>
</tr>
</blockTable>
<blockTable colWidths="100.0,100.0,73.0,80.0,80.0,80.0" style="Table_Journal_Title" repeatRows="1">[[ display_currency(data) or removeParentNode('blockTable') ]]
@ -290,7 +290,7 @@
<td><para style="terp_default_Bold_9"><font color="white"> </font></para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang(sum_debit()) ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit()) ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit()- sum_debit()) ]] [[ company.currency_id.symbol ]]</para></td>
<td><para style="terp_default_Bold_9_Right">[[ formatLang( sum_credit()- sum_debit(), currency_obj=company.currency_id) ]]</para></td>
</tr>
</blockTable>
@ -311,7 +311,7 @@
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_period(o.id)) ]]</para>
</td>
<td>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_period(o.id)-sum_debit_period(o.id)) ]] [[ company.currency_id.symbol ]]</para>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_period(o.id)-sum_debit_period(o.id), currency_obj=company.currency_id) ]] </para>
</td>
<td>
@ -337,7 +337,7 @@
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_period(o.id)) ]] </para>
</td>
<td>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_period(o.id)-sum_debit_period(o.id)) ]] [[ company.currency_id.symbol ]]</para>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_period(o.id)-sum_debit_period(o.id), currency_obj=company.currency_id) ]]</para>
</td>
</tr>
</blockTable>
@ -358,7 +358,7 @@
<para style="terp_default_Right_9">[[ formatLang(line['credit']) ]]</para>
</td>
<td>
<para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit'] ) ]] [[ company.currency_id.symbol ]]</para>
<para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit'], currency_obj=company.currency_id ) ]]</para>
</td>
</tr>
</blockTable>
@ -371,7 +371,7 @@
<td><para style="terp_default_9">[[ line['name'] ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['debit'] )]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit']) ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit'] ) ]] [[ company.currency_id.symbol ]]</para></td>
<td><para style="terp_default_Right_9">[[ formatLang(line['credit']-line['debit'], currency_obj=company.currency_id ) ]]</para></td>
<td><para style="terp_default_Right_9"><font>[[ (line['currency_id']==None or line['amount_currency']==None) and removeParentNode('font') ]] [[ formatLang(line['amount_currency'] ) ]] [[ line['currency_code'] or '' ]]</font></para></td>
</tr>
</blockTable>

View File

@ -270,7 +270,7 @@
<para style="terp_tblheader_Details">Date</para>
</td>
<td>
<para style="terp_tblheader_Details">JNRL</para>
<para style="terp_tblheader_Details">JRNL</para>
</td>
<td>
<para style="terp_tblheader_Details">Partner</para>
@ -304,7 +304,7 @@
<para style="terp_tblheader_Details">Date</para>
</td>
<td>
<para style="terp_tblheader_Details">JNRL</para>
<para style="terp_tblheader_Details">JRNL</para>
</td>
<td>
<para style="terp_tblheader_Details">Partner</para>
@ -344,16 +344,16 @@
<blockTable colWidths="102.0,102.0,102.0,130.0,102.0" style="Table13">
<tr>
<td>
<para style="terp_tblheader_General_Centre">Chart of Account</para>
<para style="terp_tblheader_General_Centre">Chart of Accounts</para>
</td>
<td>
<para style="terp_tblheader_General_Centre">Fiscal Year</para>
</td>
<td>
<para style="terp_tblheader_General_Centre">Journal</para>
<para style="terp_tblheader_General_Centre">Journals</para>
</td>
<td>
<para style="terp_tblheader_General_Centre">Filters By [[ get_filter(data)!='No Filter' and get_filter(data) ]]</para>
<para style="terp_tblheader_General_Centre">Filter By [[ get_filter(data)!='No Filter' and get_filter(data) ]]</para>
</td>
<td>
<para style="terp_tblheader_General_Centre">Target Moves</para>
@ -431,7 +431,7 @@
<para style="terp_tblheader_Details">Date</para>
</td>
<td>
<para style="terp_tblheader_Details">JNRL</para>
<para style="terp_tblheader_Details">JRNL</para>
</td>
<td>
<para style="terp_tblheader_Details">Partner</para>
@ -476,10 +476,10 @@
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_account(o), digits=get_digits(dp='Account')) ]]</para>
</td>
<td>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_balance_account(o), digits=get_digits(dp='Account')) ]] [[ company.currency_id.symbol ]]</para>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_balance_account(o), digits=get_digits(dp='Account'),currency_obj=company.currency_id) ]]</para>
</td>
<td>
<para style="terp_default_Bold_9_Right">[[ o.currency_id and formatLang(sum_currency_amount_account(o), digits=get_digits(dp='Account')) + o.currency_id.symbol or '' ]]</para>
<para style="terp_default_Bold_9_Right">[[ o.currency_id and formatLang(sum_currency_amount_account(o), digits=get_digits(dp='Account'),currency_obj=o.currency_id) or '' ]]</para>
</td>
</tr>
</blockTable>
@ -515,7 +515,7 @@
<para style="terp_default_Right_8">[[ formatLang(line['credit'], digits=get_digits(dp='Account')) ]]</para>
</td>
<td>
<para style="terp_default_Right_8">[[ formatLang(line['progress'], digits=get_digits(dp='Account')) ]] [[ company.currency_id.symbol ]]</para>
<para style="terp_default_Right_8">[[ formatLang(line['progress'], digits=get_digits(dp='Account'),currency_obj=company.currency_id) ]] </para>
</td>
<td>
<para style="terp_default_Right_8"><font>[[ (line.has_key('currency_id') and line['currency_id']==None or line['amount_currency']==None) and removeParentNode('font') ]] [[ formatLang(line['amount_currency'])]] [[ line['currency_code'] or '']]</font></para>
@ -530,7 +530,7 @@
<para style="terp_tblheader_Details">Date</para>
</td>
<td>
<para style="terp_tblheader_Details">JNRL</para>
<para style="terp_tblheader_Details">JRNL</para>
</td>
<td>
<para style="terp_tblheader_Details">Partner</para>
@ -572,7 +572,7 @@
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_credit_account(o), digits=get_digits(dp='Account')) ]]</para>
</td>
<td>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_balance_account(o), digits=get_digits(dp='Account')) ]] [[ company.currency_id.symbol ]]</para>
<para style="terp_default_Bold_9_Right">[[ formatLang(sum_balance_account(o), digits=get_digits(dp='Account'),currency_obj=company.currency_id) ]]</para>
</td>
</tr>
</blockTable>
@ -608,7 +608,7 @@
<para style="terp_default_Right_8">[[ formatLang(line['credit'], digits=get_digits(dp='Account')) ]]</para>
</td>
<td>
<para style="terp_default_Right_8">[[ formatLang(line['progress'], digits=get_digits(dp='Account')) ]] [[ company.currency_id.symbol ]]</para>
<para style="terp_default_Right_8">[[ formatLang(line['progress'], digits=get_digits(dp='Account'),currency_obj=company.currency_id) ]]</para>
</td>
</tr>
</blockTable>

Some files were not shown because too many files have changed in this diff Show More