Export via membership dashboard exports all contacts in db, not the selection
Overview
If we go to CiviMember dashboard on /civicrm/member and click on one of the numbers in the last column of the table of memberships. We get a list of all the contacts with that active membership. But if we want to export this list by selecting the "all xxxx contacts" radio button and running the export action in the dropdown we eventually get a csv export of all our contacts in civicrm. Not just the selection we just made.
I also noticed that on the result list in the search criteria fieldset there is nothing prefilled. Maybe this is why our selection does not appear to work.
Reproduction steps
- go to CiviMember dashboard on /civicrm/member
- click on one of the numbers in the last column of the table of memberships
- select the "all xxxx contacts" radio button
- run the export action in the dropdown.
- select the primary fields option (but the same happens if you select some fields)
- run export
Current behaviour
This results in a csv of all the contacts in CiviCRM.
Expected behaviour
We should get a csv of the selection we just made.
Environment information
- Browser: Chrome 80.0.3987.149
- CiviCRM: tested on 5.21.2 and 5.23.4
- PHP: 7.2.26_
- CMS: Drupal 8.8.1
- Database: MySQL 5.7.23
- Web Server: nginx/1.16.1