Comments (7)
@lukePeavey,
First of all, I like this so much, I use it almost every time that I could.
Is this still open? I am up for this.
from quotable.
@lukePeavey @lein1013 , Awesome,
I'll get right on it.
from quotable.
If you would like to submit a PR for this, please feel free. If not, I can do it next weekend.
quotable/src/controllers/quotes/randomQuote.js
Lines 12 to 14 in 7e85472
Add additional params
-const { minLength, maxLength, tags } = req.query
+const { minLength, maxLength, tags, author, authorId } = req.query
Add the filters for author
and/or authorId
if (authorId) {
filter.authorId = { $in: authorId.split('|') }
}
if (author) {
filter.author = { $in: author.split('|') }
}
from quotable.
That's a good idea. We can definitely do that
from quotable.
One thought....
The tags
param takes a comma separated list, which translates to an AND
query (with "tag-one" AND
"tag-two"), or a |
separated list, which translates to an OR
query (with "tag-one" OR
"tag-two").
For consistency, would it make sense for this param to take a |
separated list since its an OR
query (by "author-one" OR
"author-two").
Let me know what you think.
from quotable.
Nothing done from my side, but I would be happy to see this feature soon :-)
from quotable.
@raxraj did you want to work on this? If so it's all yours
from quotable.
Related Issues (20)
- Implement Automatic SSL Renewal HOT 3
- API is down HOT 1
- API is down HOT 2
- API is down HOT 5
- API is down HOT 13
- API is down HOT 1
- The API is down right now. HOT 2
- API is down HOT 1
- API is down
- API is down HOT 1
- API is down
- API is down
- API is Down ⚠️
- API is down HOT 4
- Not working API, I got this error
- API is down
- API is down
- API is down HOT 1
- API is down HOT 1
- Duplicated tag value for quote
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 quotable.