title: Getting url param is not working with AngularJS
body: <p>I have this URL and I have no idea how to get that woNum param in Angular controller...</p>
  
  <p>Why $location.search.woNum is undefined in my controllers constructor ??</p>
  
  <blockquote>
    <p>Inbox/Detail?woNum=CIB12717559</p>
  </blockquote>
  
  <pre><code>class DetailController {
      data: any;
      message: string;
  
      static $inject: string[] = ["DataService", "$location", "$filter"];
  
      constructor(private dataService: DataService, private $location, private $filter: ng.IFilterService) {
          var woNum = $location.search.woNum;
          this.message = "Please wait, loading the work order...";
          this.getWorkOrderDetail(woNum);
      }
  }
  </code></pre>