fixing Date issue and filtering