Reworked ui-router a bit.