[FIX]Groups technical for CODA Notes and bank statement lines, form added to view mode for views after import, coda note information reference
bzr revid: dle@openerp.com-20121207145519-4vbb1otng09wj3kg
This commit is contained in:
parent
8825ea3ae6
commit
fbcdfed860
|
@ -7,7 +7,7 @@
|
|||
<field name="inherit_id" ref="account.view_bank_statement_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<page name="statement_line_ids" position="after">
|
||||
<page string="CODA Notes" name="coda_note">
|
||||
<page string="CODA Notes" name="coda_note" groups="base.group_no_one">
|
||||
<field name="coda_note"/>
|
||||
</page>
|
||||
</page>
|
||||
|
@ -91,7 +91,7 @@
|
|||
<field name="view_id" ref="view_account_bank_statement_line_coda_tree"/>
|
||||
</record>
|
||||
|
||||
<menuitem name="Bank Statement Lines" parent="account.menu_finance_bank_and_cash" id="menu_account_bank_statement_line_coda" action="action_account_bank_statement_line_coda" sequence="8"/>
|
||||
<menuitem name="Bank Statement Lines" parent="account.menu_finance_bank_and_cash" id="menu_account_bank_statement_line_coda" action="action_account_bank_statement_line_coda" sequence="8" groups="base.group_no_one"/>
|
||||
<menuitem name="Import CODA File" parent="account.menu_finance_bank_and_cash" id="menu_account_coda_import" action="action_account_coda_import" sequence="10"/>
|
||||
</data>
|
||||
</openerp>
|
|
@ -8,15 +8,15 @@
|
|||
<field name="priority">1</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Import CODA File" version="7.0">
|
||||
<header>
|
||||
<button name="coda_parsing" string="_Import" type="object" class="oe_highlight"/>
|
||||
or
|
||||
<button string="Cancel" class="oe_link" special="cancel"/>
|
||||
</header>
|
||||
<group col="2">
|
||||
<field name="coda_data" filename="coda_fname"/>
|
||||
<field name="coda_fname"/>
|
||||
</group>
|
||||
<footer>
|
||||
<button name="coda_parsing" string="_Import" type="object" class="oe_highlight"/>
|
||||
or
|
||||
<button string="Cancel" class="oe_link" special="cancel"/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
@ -246,9 +246,9 @@ class account_coda_import(osv.osv_memory):
|
|||
line['transaction_family'] = transaction_family[0]
|
||||
if line['transaction_code'] in transaction_family[1]:
|
||||
line['transaction_code'] = transaction_family[1][line['transaction_code']]
|
||||
statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Date: ' + str(line['entryDate']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'], '\n'])
|
||||
statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' with Ref. ' + str(line['ref']), 'Date: ' + str(line['entryDate']), 'Communication: ' + line['communication'], ''])
|
||||
elif line['type'] == 'communication':
|
||||
statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'], '\n'])
|
||||
statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' with Ref. ' + str(line['ref']), 'Ref: ', 'Communication: ' + line['communication'], ''])
|
||||
elif line['type'] == 'normal':
|
||||
note = []
|
||||
if 'counterpartyName' in line and line['counterpartyName'] != '':
|
||||
|
@ -385,7 +385,7 @@ class account_coda_import(osv.osv_memory):
|
|||
self.pool.get('account.bank.statement').write(cr, uid, [statement['id']], {'coda_note': statement['coda_note']}, context=context)
|
||||
return {
|
||||
'view_type': 'form',
|
||||
'view_mode': 'tree',
|
||||
'view_mode': 'tree,form',
|
||||
'res_model': 'account.bank.statement',
|
||||
'view_id': False,
|
||||
'context': context,
|
||||
|
|
Loading…
Reference in New Issue