add some logic and views