Answer the question
In order to leave comments, you need to log in
How to be case sensitive when searching?
Hello.
The question is. How to be case sensitive when searching by title?
Let's say the title consists of 2 words: Case in Text. If you write in the search field Case in the text - does not find. If to specify the case - finds.
Any ideas? Thank you.
$ionicModal.fromTemplateUrl('templates/search.html', {
scope: $scope,
focusFirstInput: true
}).then(function(modal) {
$scope.modalSearch = modal;
});
$scope.openSearch = function() {
$scope.modalSearch.show();
$scope.itemsFilter = function(item) {
var f = true;
if (f && $scope.filter.query.length) {
f = (item.title.indexOf($scope.filter.query) !== -1) || (item.article.indexOf($scope.filter.query) !== -1);
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question