templateUrl can be use as function with returning generated URL. We can manipulate url with passing argument which takes routeParams.
See the example.
.when('/:screenName/list',{
templateUrl: function(params){
return params.screenName +'/listUI'
}
})
Hope this help.