Tools4everBV / HelloID-Conn-Prov-Source-Visma.net-HRM-API

HelloID-Conn-Prov-Source-Visma.net-HRM-API
0 stars 0 forks source link

Deleted contracts #20

Open bvandervoorn opened 6 months ago

bvandervoorn commented 6 months ago

When a contract is deleted, it becomes a ghost record in the API. A contract without start or enddate. I would like to change line 357, to make sure these ghost records don't enter HelloID.

My suggestion: ($.Enddate -as [datetime] -ge (Get-Date).AddDays(-$cutOffDays) -or ([string]::IsNullOrEmpty($.Enddate) -and -not [string]::IsNullOrEmpty($_.Startdate)) )

Rick-Jongbloed commented 4 months ago

if we are going to remove records, we should have a way to log the counts. Also log the array of removed employeeIds as debug message.