created custom json encoder to process dateswq