added working controller for visit table page