Add view logic