Comments (1)
Found out the issue, the package has a method called dropId inside Model/index.js, if that is true then when the camelCase method is called, the id from each method is removed.
static get dropId () {
return true
}
Removing the Id from the end of the filter.js method will solve the issue.
params = {
'account_id'
}
account(accountId){
return this.where('account_id', accountId)
}
This should be added to the docs. Two examples with camelCase methods, one with Id and one without.
from adonis-lucid-filter.
Related Issues (20)
- Open to sql injections? HOT 1
- Relationship based filtering HOT 4
- Can't use filter in User model HOT 5
- Filtering relationships with 'OR' HOT 1
- Is it possible to add OrderBy to supported method of query builder? HOT 1
- pass currentUser details from request middleware to filter? HOT 1
- V5 relatioship query HOT 1
- .related() queries can't use the filter method HOT 1
- Adonis 5 installation help needed. HOT 3
- Global filters HOT 1
- Add deleted_at in where to link tables HOT 1
- Critical bug: values are being cached HOT 2
- Do not apply filter to query HOT 6
- How to add check based on 2 fields. HOT 1
- filter seems not working when combined with wherehas HOT 2
- Filters with uppercase and underscores HOT 1
- Async support in `setup` and `filter method`s HOT 3
- Is it working with latest @adonisjs/lucid v18.3.0? HOT 1
- Filter pattern HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from adonis-lucid-filter.