pay changes added
fixed indentation
added termination
changed write functions, fixed bugs
added missing sql query field
added missing cause text in contract expiration
bugfixes
variable name corrected
added check if date exist
fixed sql string
temp values for testing purposes added
temp fix to get test rolling on missing data