fix($urlRouter): resolve clashing of routes

Sometimes url can be matched by several different rules. Now it will be handled by the first rule in order of appearance. So it causes some issues. It would be better to match states from more specified to common.

Angular-route already has same issue https://github.com/angular/angular.js/issues/8266

So, I propose include this fixes here, because is ui-router more powerful and flexible library.