unit view logic