[IMP] account, fiscalyear end of year entries generation: small misc improvments

bzr revid: qdp-launchpad@tinyerp.com-20101116121658-31enzyskxpceo312
This commit is contained in:
qdp-launchpad@tinyerp.com 2010-11-16 13:16:58 +01:00
parent 3a50c2e24c
commit 014cd44400
3 changed files with 8 additions and 12 deletions

View File

@ -8,14 +8,14 @@
date_stop: !eval "'%s-12-31' %(datetime.now().year+1)"
name: !eval "'Fiscal Year %s' %(datetime.now().year+1)"
-
I create a period for the month of january for the new fiscalyear
I create a period for the opening entries for the new fiscalyear
-
!record {model: account.period, id: account_period_jan11}:
company_id: base.main_company
date_start: !eval "'%s-01-01'% (datetime.now().year+1)"
date_stop: !eval "'%s-12-31'% (datetime.now().year+1)"
date_stop: !eval "'%s-01-01'% (datetime.now().year+1)"
fiscalyear_id: account_fiscalyear_fiscalyear0
name: !eval "'Jan%s' %(datetime.now().year+1)"
name: !eval "'OP %s' %(datetime.now().year+1)"
special: 1
-
@ -91,4 +91,4 @@
# self.action_open_window(cr, uid, [ref("account_move_journal_2")], {"lang": 'en_US',
# "active_model": "ir.ui.menu", "active_ids": [ref("account.menu_action_move_journal_line_form")],
# "tz": False, "active_id": ref("account.menu_action_move_journal_line_form"),
# })
# })

View File

@ -14,8 +14,6 @@
!record {model: account.tax, id: tax196}:
name: Tax 19.6%
amount: &tax 0.196
account_collected_id: account.a_recv
account_paid_id: account.a_recv
-
And we define an invoice with one invoice line with a tax of *tax
-

View File

@ -33,14 +33,12 @@ class account_fiscalyear_close(osv.osv_memory):
'Fiscal Year to close', required=True, help="Select a Fiscal year to close"),
'fy2_id': fields.many2one('account.fiscalyear', \
'New Fiscal Year', required=True),
'journal_id': fields.many2one('account.journal', \
'Opening Entries Journal', required=True, help='The best practice here is to use a journal dedicated to contain the opening entries of all fiscal years. Note that you should define it with default debit/credit accounts and with a centralized counterpart.'),
'period_id': fields.many2one('account.period', \
'Opening Entries Period', required=True),
'journal_id': fields.many2one('account.journal', 'Opening Entries Journal', domain="[('type','=','situation')]", required=True, help='The best practice here is to use a journal dedicated to contain the opening entries of all fiscal years. Note that you should define it with default debit/credit accounts, of type \'situation\' and with a centralized counterpart.'),
'period_id': fields.many2one('account.period', 'Opening Entries Period', required=True),
'report_name': fields.char('Name of new entries',size=64, required=True, help="Give name of the new entries"),
}
_defaults = {
'report_name':'End of Fiscal Year Entry',
'report_name': _('End of Fiscal Year Entry'),
}
def data_save(self, cr, uid, ids, context=None):
@ -221,4 +219,4 @@ class account_fiscalyear_close(osv.osv_memory):
account_fiscalyear_close()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: