addded view logic