-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow array values in api filter paramaters #7933
Allow array values in api filter paramaters #7933
Conversation
Hi there! We now want to integrate your contribution in the Mautic 3 roadmap as 3.1.0 candidate. How to do?
Please report results by commenting on your PR to make us administration easier. You can more information on how to do all of that on this blog post "Getting you PR ready for Mautic 3". |
@galvani This PR is still based on Mautic 2. Could you please rebase it against the |
Bumping to 3.2 as this PR requires updating for 3.x and rebasing. cc @escopecz @alanhartless |
@cla-bot check |
We require contributors to sign our Contributor License Agreement, and we do not have a record of your signature on file. In order for us to review and merge your code, please head over to https://www.mautic.org/contributor-agreement and complete the form. There may be a short delay while the team add you as a contributor - please be patient :). Any problems contact @RCheesley. CLA has not been signed by @galvani. |
The CLA Bot has been sent on a mission to check against the latest list and will be back shortly with its findings! |
@cla-bot check |
The CLA Bot has been sent on a mission to check against the latest list and will be back shortly with its findings! |
@mautic/acquia-po is it still actual and relevant for M3 ? |
Codecov Report
@@ Coverage Diff @@
## features #7933 +/- ##
===========================================
Coverage 38.33% 38.34%
- Complexity 33939 33941 +2
===========================================
Files 1982 1982
Lines 104948 104952 +4
===========================================
+ Hits 40236 40246 +10
+ Misses 64712 64706 -6
|
@npracht yes, it is. |
56f2897
to
85d83ae
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works for me 👍
@escopecz any chance you could offer a query to use with sample data to test this? |
Here is CURL. Paste it to a command line but update the values in capital letters: curl "https://URL/index_dev.php/api/contacts?where%5B0%5D%5Bcol%5D=firstname&where%5B0%5D%5Bexpr%5D=in&where%5B0%5D%5Bval%5D=John,Jane" \
-u 'USERNAME:PASSWORD' In order to get some contacts in the response you have to have some contacts with first name of John and/or Jane |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
Works for me
Unit test included
Then approve it 👍
Please be sure you are submitting this against the staging branch.
Description:
We do not allow for API calls to use multiple arguments for anything but ids. The goal of this PR is to allow them.
Steps to test and reproduce this PR:
/api/contacts?where[0][col]=global_customer_id&where[0][expr]=in&where[0][val]="10","11"
/api/contacts?where[0][col]=global_customer_id&where[0][expr]=in&where[0][val]=10,11