This commit is contained in:
adi.bk 2017-06-01 19:14:49 -07:00
parent 8865f4a8aa
commit be8310350e
4 changed files with 2 additions and 7 deletions

View File

@ -74,6 +74,7 @@ public class FilterOptionsModel implements Parcelable {
queryMap.clear();
}
queryMap.put(TYPE, type.toLowerCase());
//Not supported for organization repo
if (!isOrg) {
if (sort.contains(" ")) {
//full name should be full_name

View File

@ -134,7 +134,6 @@ refresh.setRefreshing(true);
@Override
public void onRepoFilterClicked() {
dialog.setCurrentFilterOptions(getPresenter().getFilterOptions());
dialog.setOrg(true);
dialog.show(getChildFragmentManager(), "OrgReposFragment");
}

View File

@ -32,7 +32,6 @@ public class ProfileReposFilterBottomSheetDialog extends BaseBottomSheetDialog {
private ProfileReposFilterChangeListener listener;
private FilterOptionsModel currentFilterOptions;
private boolean isOrg;
@Override
protected int layoutRes() {
@ -115,10 +114,6 @@ public class ProfileReposFilterBottomSheetDialog extends BaseBottomSheetDialog {
this.currentFilterOptions = currentFilterOptions;
}
public void setOrg(boolean org) {
isOrg = org;
}
public interface ProfileReposFilterChangeListener {
void onFilterApply();
void onTypeSelected(String selectedType);

View File

@ -75,7 +75,7 @@ class ProfileReposPresenter extends BasePresenter<ProfileReposMvp.View> implemen
filterOptions.setIsPersonalProfile(TextUtils.equals(currentLoggedIn, username));
makeRestCall(TextUtils.equals(currentLoggedIn, username)
? RestProvider.getUserService().getRepos(filterOptions.getQueryMap(), page)
: RestProvider.getUserService().getRepos(filterOptions.getQueryMap(), parameter, page),
: RestProvider.getUserService().getRepos(parameter, filterOptions.getQueryMap(), page),
repoModelPageable -> {
lastPage = repoModelPageable.getLast();
if (getCurrentPage() == 1) {