Fleet version:
main at f836722
Web browser and operating system:
N/A
💥 Actual behavior
On the host page, software tab, filtering by "Available for install" only shows the installers (packages or VPP apps) that have never been requested to install on that host, instead of all the available installers.
🧑💻 Steps to reproduce
- Create a team, add a software installer (or VPP app) to that team,
- Enroll a host in that team
- In that host's page, software tab, filter by Available for install -> that software should show up.
- Request an install for that software.
- Refresh the host's page, filter by Available for install, that software installer does not show up anymore. Remove the filter to view all software, it shows up in "Pending" state (or installed/failed).
🕯️ More info (optional)
Currently, there's a AvailableForInstall field that controls this filter. I'd suggest renaming it to OnlyAvailableForInstall to avoid confusion with the other IncludeAvailableForInstall filter (without changing the query string that sets it, so it's only an internal implementation change).
When OnlyAvailableForInstall is set, both the stmtInstalled and stmtAvailable queries must be executed (with the UNION), but a condition must be added to stmtInstalled so that only rows corresponding to an installer (( hsi.host_id IS NOT NULL OR hvsi.host_id IS NOT NULL )) must be returned.
Currently, only the stmtAvailable query is used, which excludes all installers where an install request has been recorded.
Fleet version:
mainat f836722Web browser and operating system:
N/A
💥 Actual behavior
On the host page, software tab, filtering by "Available for install" only shows the installers (packages or VPP apps) that have never been requested to install on that host, instead of all the available installers.
🧑💻 Steps to reproduce
🕯️ More info (optional)
Currently, there's a
AvailableForInstallfield that controls this filter. I'd suggest renaming it toOnlyAvailableForInstallto avoid confusion with the otherIncludeAvailableForInstallfilter (without changing the query string that sets it, so it's only an internal implementation change).When
OnlyAvailableForInstallis set, both thestmtInstalledandstmtAvailablequeries must be executed (with the UNION), but a condition must be added tostmtInstalledso that only rows corresponding to an installer (( hsi.host_id IS NOT NULL OR hvsi.host_id IS NOT NULL )) must be returned.Currently, only the
stmtAvailablequery is used, which excludes all installers where an install request has been recorded.