refactor ProgramHistory Filter