1
私は角に新しいですし、私はこだわっていて、検索フィールドに検索したい...
私はthis image場所のプレースホルダに示すようにドロップダウンを作成したいですテキストボックスは、ドロップダウンから選択したオプションによって異なります。:ドロップダウンからオプションを選択する上で、私はその値
私のHTMLは私のコントローラのように定義されて
<select class="selectpicker" ng-options="search for search in searchCriteria" ng-model="searchWith">
<option value="">Select : </option>
</select>
<input type="text" ng-model="searchName" class="form-control" placeholder="Search with {{searchWith}}" />
です:
var companyInfo = angular.module('companyInfo', []);
companyInfo.controller('searchExample', ['$scope', '$http',function($scope, $http){
$scope.searchCriteria = ['Name', 'Employee Id', 'Designation', 'Email','Phone No']
$http.get("data/data.json").then(function(data){
$scope.employeeDetails= data.data;
});
$scope.searchInTable = function(searchName){
$scope.searchVal = searchName;
}
}]);