$location.path('/page1').search({id: $scope.id,name:$scope.name});
帶參數跳轉頁面,在新的頁面通過$routeParams接收參數
$scope.id=$routeParams.newNo;
$scope.name=$routeParams.lastBill;
另附官網中關於$location的api文檔:https://code.angularjs.org/1.2.2/docs/api/ng.$location