2016-11-21 2 views
1

Wie Zugriff auf $ Scope Variable in Filter-Option bitte helfen Sie mir.

 $scope.Profile = Auth.getCurrentUserSync(); 

HTML

<select class="form-control" name="customer" id="customer" ng-model="postjobcustomerCtrl.selectedCustomer" ng-options="customer.full_name for customer in postjobcustomerCtrl.atlasCustomers | filter:{full_name:"+Profile.full_name+"} track by customer.user_id" 
              ng-change="postjobcustomerCtrl.selectDefaultAddress()" required></select> 

Antwort

2

Verwenden Sie einfach die $scope Variable ohne Interpolation:

filter:{full_name: Profile.full_name } 
+0

wenn ich Filter eingeben: {full_name: 'Rischard'} ITS adaequat, aber Ihre Antwort anzeigen mir alle Kundenliste, –

+0

Entschuldigung mein Fehler, es funktioniert gut danke –

Verwandte Themen