add open source filter
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
This commit is contained in:
@@ -39,7 +39,9 @@ ResourceAPI::SearchArgs ModModel::createSearchArguments()
|
||||
|
||||
auto sort = getCurrentSortingMethodByIndex();
|
||||
|
||||
return { ModPlatform::ResourceType::MOD, m_next_search_offset, m_search_term, sort, loaders, versions, side, categories };
|
||||
return {
|
||||
ModPlatform::ResourceType::MOD, m_next_search_offset, m_search_term, sort, loaders, versions, side, categories, m_filter->openSource
|
||||
};
|
||||
}
|
||||
|
||||
ResourceAPI::VersionSearchArgs ModModel::createVersionsArguments(QModelIndex& entry)
|
||||
|
||||
@@ -189,7 +189,7 @@ void ListModel::performPaginatedSearch()
|
||||
|
||||
auto netJob = makeShared<NetJob>("Flame::Search", APPLICATION->network());
|
||||
auto searchUrl = FlameAPI().getSearchURL({ ModPlatform::ResourceType::MODPACK, nextSearchOffset, currentSearchTerm, sort,
|
||||
m_filter->loaders, m_filter->versions, "", m_filter->categoryIds });
|
||||
m_filter->loaders, m_filter->versions, "", m_filter->categoryIds, m_filter->openSource });
|
||||
|
||||
netJob->addNetAction(Net::ApiDownload::makeByteArray(QUrl(searchUrl.value()), response));
|
||||
jobPtr = netJob;
|
||||
|
||||
@@ -155,7 +155,7 @@ void ModpackListModel::performPaginatedSearch()
|
||||
ResourceAPI::SortingMethod sort{};
|
||||
sort.name = currentSort;
|
||||
auto searchUrl = ModrinthAPI().getSearchURL({ ModPlatform::ResourceType::MODPACK, nextSearchOffset, currentSearchTerm, sort,
|
||||
m_filter->loaders, m_filter->versions, "", m_filter->categoryIds });
|
||||
m_filter->loaders, m_filter->versions, "", m_filter->categoryIds, m_filter->openSource });
|
||||
|
||||
auto netJob = makeShared<NetJob>("Modrinth::SearchModpack", APPLICATION->network());
|
||||
netJob->addNetAction(Net::ApiDownload::makeByteArray(QUrl(searchUrl.value()), m_allResponse));
|
||||
|
||||
Reference in New Issue
Block a user