enforce salesorder start/end date rules in database

also, fix bug with removing VAT from products
fixes #128
fixes #161