Add patch that fixes a crash when checking vies and the party has no country vat.

This commit is contained in:
Albert Cervera i Areny 2015-04-02 17:25:43 +02:00
parent f7c05e07fd
commit b4c34a1de6
2 changed files with 15 additions and 0 deletions

View File

@ -0,0 +1,13 @@
diff -r acda45bb0d0e party.py
--- .a/trytond/trytond/modules/party/party.py Sun Mar 15 15:58:42 2015 +0100
+++ .b/trytond/trytond/modules/party/party.py Thu Apr 02 17:19:58 2015 +0200
@@ -318,7 +318,8 @@
if not party.vat_code:
continue
try:
- if not vatnumber.check_vies(party.vat_code):
+ if (not party.vat_country
+ or not vatnumber.check_vies(party.vat_code)):
parties_failed.append(party.id)
else:
parties_succeed.append(party.id)

2
series
View File

@ -42,3 +42,5 @@ issue9911002_80001.diff
issue6021003_1.diff
issue6951002_20001.diff
issue92001_42002_52002_wsgi_protocol.diff
check-vies-issue12101002.patch