title: how can I use functions as well as variables in the expression for ng-options in Angularjs
body: <p>I have 2 select boxes, one to choose the user type (e.g. groups or individual) and the 2nd to the out put of the 1st one to display the options to choose the user/group. 
  is there anyway that in my expressions for <code>ng-options</code> I could pass it a function instead of a variable like so :</p>
  
  <pre><code>ng-options="user.id as user.description for user in getUserList(userType)"
  </code></pre>
  
  <p>where userType is the ng-model of the first select box</p>
  
  <p>I'm under the impression from my own trials that this is not possible (seem's to crash the the current tab in chrome and the entire application in firefox).</p>
  
  <p>what would be the best approach to this. I have a lot of selects that use this kind of 2 select box setup so it would be nice If I could avoid copying and pasting.</p>