Post.find(
{ where: {title: { like: ''.*'+query.toLowerCase()+'.*''} } },
function (err, posts) { ... }
);--
You received this message because you are subscribed to the Google Groups "LoopbackJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to loopbackjs+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
var pattern = new RegExp('.*'+query+'.*', "i"); /* case-insensitive RegExp search */
Post.find(
{ where: {title: { like: pattern} } },
function (err, posts) { ... }
);
You can plug in a beforeRemote hook to transform the filter object.