[IMP] fixed the error and improved the user interface

bzr revid: bde@tinyerp.com-20120130071059-9gg0ust85uzh8yb0
This commit is contained in:
Bharat Devnani (OpenERP)
2012-01-30 12:40:59 +05:30
parent 583aa5f59d
commit 5510e7a083
2 changed files with 13 additions and 11 deletions
@@ -158,7 +158,7 @@ class partner_vat_list_13(osv.osv_memory):
_defaults={
# TODO the referenced model has been deleted at revno 4672.1.2.
# 'partner_ids': _get_partners
'partner_ids': _get_partners,
'identification_type' : 'tin'
}
@@ -223,7 +223,7 @@ class partner_vat_list_13(osv.osv_memory):
'phone': phone,
'SenderId': SenderId,
'period': context['year'],
'comments': data['comments']
'comments': data['comments'] or ''
}
data_file = """<?xml version="1.0"?>
@@ -270,6 +270,12 @@ class partner_vat_list_13(osv.osv_memory):
sum_turnover = 0.00
if len(error_message):
return 'Exception : \n' +'-'*50+'\n'+ '\n'.join(error_message)
amount_data = {
'seq': str(seq),
'dnum': dnum,
'sum_tax': str(0),
'sum_turnover': str(0),
}
for line in datas:
vat_issued = line['vat'][:2]
if vat_issued == 'BE':
@@ -40,18 +40,15 @@
<field name="arch" type="xml">
<form string="Select Fiscal Year">
<notebook colspan="4">
<page string="Partners">
<page string="Details">
<field name="identification_type"/>
<newline/>
<field name="other" attrs="{'invisible':[('identification_type','!=','other')], 'required': [('identification_type','=','other')]}"/>
<label string="You can remove customers which you do not want in exported xml file" colspan="4"/>
<separator string="Customers" colspan="4"/>
<field name="partner_ids" colspan="4" nolabel="1" default_focus="1" height="200" width="500"/>
</page>
<page string="Details">
<group colspan="4">
<field name="identification_type"/>
<newline/>
<field name="other" attrs="{'invisible':[('identification_type','!=','other')], 'required': [('identification_type','=','other')]}"/>
</group>
<separator string="Comments" colspan="4"/>
<page string="Comments">
<field name="comments" colspan="4" nolabel="1"/>
</page>
</notebook>
@@ -63,7 +60,6 @@
<separator string="XML File has been Created." colspan="4"/>
<field name="msg" colspan="4" nolabel="1"/>
<field name="name"/>
<newline/>
<field name="file_save"/>
<separator colspan="4"/>
<button special="cancel" string="Close" icon="gtk-cancel"/>