Skip to content

Commit

Permalink
Merge pull request #24 from dseichter/small_fixes
Browse files Browse the repository at this point in the history
Small fixes and UI improvements
  • Loading branch information
Daniel Seichter authored Jul 31, 2024
2 parents fa2eb3d + 701fe8e commit cf1fc37
Show file tree
Hide file tree
Showing 9 changed files with 233 additions and 44 deletions.
25 changes: 17 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,30 @@
# VATValidation

Validate VAT number using the interfaces of BZSt, VIES and/or HMRC. Provides single or batch validation with support for CSV, XLSX and JSON.

This is the successor of my VAT-Validation, released as commercial software. After closing my company I proceeded with the migration to Python.

If you like this software, please don't hesitate to give it a :star: or send me a :moneybag: donation in the amount you think the software is worth.

![pep8](https://github.com/dseichter/VATValidation/actions/workflows/pep8.yml/badge.svg)
![bandit](https://github.com/dseichter/VATValidation/actions/workflows/bandit.yml/badge.svg)
![trivy](https://github.com/dseichter/VATValidation/actions/workflows/trivy.yml/badge.svg)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=dseichter_VATValidation&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=dseichter_VATValidation)

[![SonarCloud](https://sonarcloud.io/images/project_badges/sonarcloud-white.svg)](https://sonarcloud.io/summary/new_code?id=dseichter_VATValidation)
Validate VAT numbers using the interfaces of BZSt, VIES and/or HMRC. Provides single or batch validation with support for CSV, XLSX and JSON.

## Features

* Single validation
* Batch processing of CSV, JSON or XLSX
* Validation using BZSt (if your vat is located at `DE`)
* Validation using VIES (configurable as default)
* Validation using HMRC (if you want to validate a vat starting with `UK`)
* Provides a graphical user interface
* Batch processing can be run using CLI interface
* **NO** dependencies needed

This is the successor of my VAT-Validation. Now released as Open Source.

If you like this software, please don't hesitate to give it a :star: or send me a :moneybag: donation in the amount you think the software is worth.

## About

VAT Validation supports you in checking and validating your master data. Whether you want to check a VAT number directly at your workplace or integrate it into your ERP/CRM applications.
VAT Validation supports you in validating your vat numbers based on your master data. Whether you want to check a VAT number directly at your workplace or integrate it into your ERP/CRM applications.

## Command Line tool

Expand Down
Binary file added icons/Broom.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icons/Fry.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added icons/Opened_Folder.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 16 additions & 16 deletions src/VATValidation.fbp
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@
</object>
<object class="sizeritem" expanded="false">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="flag">wxALIGN_CENTER</property>
<property name="proportion">0</property>
<object class="wxButton" expanded="false">
<property name="BottomDockable">1</property>
Expand Down Expand Up @@ -367,7 +367,7 @@
<property name="gripper">0</property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Clear entries</property>
<property name="label">Clear</property>
<property name="margins"></property>
<property name="markup">0</property>
<property name="max_size"></property>
Expand Down Expand Up @@ -604,8 +604,8 @@
</object>
<object class="sizeritem" expanded="false">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<property name="flag">wxALL|wxEXPAND</property>
<property name="proportion">1</property>
<object class="wxTextCtrl" expanded="false">
<property name="BottomDockable">1</property>
<property name="LeftDockable">1</property>
Expand Down Expand Up @@ -741,7 +741,7 @@
</object>
<object class="sizeritem" expanded="false">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="flag">wxALL|wxEXPAND</property>
<property name="proportion">0</property>
<object class="wxTextCtrl" expanded="false">
<property name="BottomDockable">1</property>
Expand Down Expand Up @@ -1015,7 +1015,7 @@
</object>
<object class="sizeritem" expanded="false">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="flag">wxALL|wxEXPAND</property>
<property name="proportion">0</property>
<object class="wxTextCtrl" expanded="false">
<property name="BottomDockable">1</property>
Expand Down Expand Up @@ -1100,8 +1100,8 @@
</object>
<object class="sizeritem" expanded="false">
<property name="border">5</property>
<property name="flag">wxALL|wxEXPAND</property>
<property name="proportion">1</property>
<property name="flag">wxALIGN_CENTER</property>
<property name="proportion">0</property>
<object class="wxButton" expanded="false">
<property name="BottomDockable">1</property>
<property name="LeftDockable">1</property>
Expand Down Expand Up @@ -1137,8 +1137,8 @@
<property name="gripper">0</property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Validate</property>
<property name="margins"></property>
<property name="label">Validate your entries</property>
<property name="margins">-1,-1</property>
<property name="markup">0</property>
<property name="max_size"></property>
<property name="maximize_button">0</property>
Expand Down Expand Up @@ -1985,8 +1985,8 @@
</object>
<object class="sizeritem" expanded="false">
<property name="border">5</property>
<property name="flag">wxEXPAND|wxALL</property>
<property name="proportion">1</property>
<property name="flag">wxALIGN_LEFT</property>
<property name="proportion">0</property>
<object class="wxButton" expanded="false">
<property name="BottomDockable">1</property>
<property name="LeftDockable">1</property>
Expand Down Expand Up @@ -2022,7 +2022,7 @@
<property name="gripper">0</property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Start Validation</property>
<property name="label">Start processing file</property>
<property name="margins"></property>
<property name="markup">0</property>
<property name="max_size"></property>
Expand Down Expand Up @@ -2610,10 +2610,10 @@
<property name="max_size"></property>
<property name="maximize_button">0</property>
<property name="maximum_size"></property>
<property name="maxlength">0</property>
<property name="min_size"></property>
<property name="maxlength">1</property>
<property name="min_size">-1,-1</property>
<property name="minimize_button">0</property>
<property name="minimum_size"></property>
<property name="minimum_size">20,-1</property>
<property name="moveable">1</property>
<property name="name">textConfigCSVdelimiter</property>
<property name="pane_border">1</property>
Expand Down
25 changes: 14 additions & 11 deletions src/gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ def __init__( self, parent ):
self.textOwnvat = wx.TextCtrl( self.panelSingle, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.textOwnvat, 0, wx.ALL, 5 )

self.buttonClear = wx.Button( self.panelSingle, wx.ID_ANY, _(u"Clear entries"), wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.buttonClear, 0, wx.ALL, 5 )
self.buttonClear = wx.Button( self.panelSingle, wx.ID_ANY, _(u"Clear"), wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.buttonClear, 0, wx.ALIGN_CENTER, 5 )

self.staticText_foreignvat = wx.StaticText( self.panelSingle, wx.ID_ANY, _(u"Foreign VAT"), wx.DefaultPosition, wx.DefaultSize, 0 )
self.staticText_foreignvat.Wrap( -1 )
Expand All @@ -67,7 +67,7 @@ def __init__( self, parent ):
fgSizer2.Add( self.staticText_company, 0, wx.ALL, 5 )

self.textCompany = wx.TextCtrl( self.panelSingle, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.textCompany, 0, wx.ALL, 5 )
fgSizer2.Add( self.textCompany, 1, wx.ALL|wx.EXPAND, 5 )


fgSizer2.Add( ( 0, 0), 1, wx.EXPAND, 5 )
Expand All @@ -78,7 +78,7 @@ def __init__( self, parent ):
fgSizer2.Add( self.staticText_street, 0, wx.ALL, 5 )

self.textStreet = wx.TextCtrl( self.panelSingle, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.textStreet, 0, wx.ALL, 5 )
fgSizer2.Add( self.textStreet, 0, wx.ALL|wx.EXPAND, 5 )


fgSizer2.Add( ( 0, 0), 1, wx.EXPAND, 5 )
Expand All @@ -100,16 +100,16 @@ def __init__( self, parent ):
fgSizer2.Add( self.staticText_town, 0, wx.ALL, 5 )

self.textTown = wx.TextCtrl( self.panelSingle, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.textTown, 0, wx.ALL, 5 )
fgSizer2.Add( self.textTown, 0, wx.ALL|wx.EXPAND, 5 )


fgSizer2.Add( ( 0, 0), 1, wx.EXPAND, 5 )


fgSizer2.Add( ( 0, 0), 1, wx.EXPAND, 5 )

self.buttonValidateSingle = wx.Button( self.panelSingle, wx.ID_ANY, _(u"Validate"), wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.buttonValidateSingle, 1, wx.ALL|wx.EXPAND, 5 )
self.buttonValidateSingle = wx.Button( self.panelSingle, wx.ID_ANY, _(u"Validate your entries"), wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer2.Add( self.buttonValidateSingle, 0, wx.ALIGN_CENTER, 5 )


bSizer3.Add( fgSizer2, 1, wx.EXPAND, 5 )
Expand Down Expand Up @@ -189,14 +189,14 @@ def __init__( self, parent ):

fgSizer3.Add( ( 0, 0), 1, wx.EXPAND, 5 )

self.buttonValidateBatch = wx.Button( self.panelBatch, wx.ID_ANY, _(u"Start Validation"), wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer3.Add( self.buttonValidateBatch, 1, wx.EXPAND|wx.ALL, 5 )
self.buttonValidateBatch = wx.Button( self.panelBatch, wx.ID_ANY, _(u"Start processing file"), wx.DefaultPosition, wx.DefaultSize, 0 )
fgSizer3.Add( self.buttonValidateBatch, 0, wx.ALIGN_LEFT, 5 )


self.panelBatch.SetSizer( fgSizer3 )
self.panelBatch.Layout()
fgSizer3.Fit( self.panelBatch )
self.m_notebook3.AddPage( self.panelBatch, _(u"Batch"), False )
self.m_notebook3.AddPage( self.panelBatch, _(u"Batch"), True )
self.panelConfig = wx.Panel( self.m_notebook3, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.TAB_TRAVERSAL )
fgSizer31 = wx.FlexGridSizer( 0, 2, 0, 0 )
fgSizer31.AddGrowableCol( 1 )
Expand Down Expand Up @@ -237,6 +237,9 @@ def __init__( self, parent ):
fgSizer31.Add( self.staticTextConfigCSVDelimiter, 0, wx.ALL, 5 )

self.textConfigCSVdelimiter = wx.TextCtrl( self.panelConfig, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 )
self.textConfigCSVdelimiter.SetMaxLength( 1 )
self.textConfigCSVdelimiter.SetMinSize( wx.Size( 20,-1 ) )

fgSizer31.Add( self.textConfigCSVdelimiter, 0, wx.ALL, 5 )

self.buttonSaveConfig = wx.Button( self.panelConfig, wx.ID_ANY, _(u"Save"), wx.DefaultPosition, wx.DefaultSize, 0 )
Expand All @@ -246,7 +249,7 @@ def __init__( self, parent ):
self.panelConfig.SetSizer( fgSizer31 )
self.panelConfig.Layout()
fgSizer31.Fit( self.panelConfig )
self.m_notebook3.AddPage( self.panelConfig, _(u"Configuration"), True )
self.m_notebook3.AddPage( self.panelConfig, _(u"Configuration"), False )

bSizer2.Add( self.m_notebook3, 1, wx.EXPAND |wx.ALL, 5 )

Expand Down
Loading

0 comments on commit cf1fc37

Please sign in to comment.