Skip to content
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

feat(sorted-by-name): apps and libraries are sorted by name #86

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .idea/modules.xml

This file was deleted.

12 changes: 0 additions & 12 deletions .idea/stackzy.iml

This file was deleted.

2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ plugins {
}

val daggerVersion by extra("2.39.1")
val stackzyVersion by extra("1.1.3") // TODO : Change in App.kt also
val stackzyVersion by extra("1.2.0") // TODO : Change in App.kt also

group = "com.theapache64"
version = stackzyVersion
Expand Down
2 changes: 1 addition & 1 deletion data/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ plugins {
}

group = "com.theapache64.stackzy"
version = "1.1.3"
version = "1.2.0"

repositories {
mavenCentral()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class NetworkModule {
)
.addForm(
TABLE_UNTRACKED_LIBS,
"https://docs.google.com/forms/d/e/1FAIpQLSdWuRkjXqBkL-w5NfktA_ju_sI2bJTDVb4LoYco4mxEpskU9g/viewform?usp=sf_link"
"https://docs.google.com/forms/d/e/1FAIpQLSdWuRkjXqBkL-w5NfktA_ju_sI2bJTDVb4LoYco4mxEpskU9g/viewform?usp=sf_link", // TODO: Change this
)
.addSheet(
sheetName = TABLE_RESULTS,
Expand All @@ -73,7 +73,7 @@ class NetworkModule {
)
.addForm(
endPoint = TABLE_RESULTS,
formLink = "https://docs.google.com/forms/d/e/1FAIpQLSdiTZz47N2FHUXLSvsdzAxVRKqzWq30xjkpCOQugKbHLJuRGg/viewform?usp=sf_link"
formLink = "https://docs.google.com/forms/d/e/1FAIpQLSdTiqu2iS-dRLV106uvcKnrZUPnX2x-qF1FlWUjxsfmkNJ0-A/viewform?usp=sf_link"
)
.build()
}
Expand All @@ -100,7 +100,7 @@ class NetworkModule {

return Retrofit.Builder()
.client(okHttpClient)
.baseUrl("https://docs.google.com/spreadsheets/d/1KBxVO5tXySbezBr-9rb2Y3qWo5PCMrvkD1aWQxZRepI/")
.baseUrl("https://docs.google.com/spreadsheets/d/1DZ_s2aSJZ4WsgsfZnVQIB1us7Dq7WfxDdpbvLo07pMg/")
.addConverterFactory(MoshiConverterFactory.create(moshi))
.addCallAdapterFactory(FlowResourceCallAdapterFactory())
.build()
Expand Down
2 changes: 1 addition & 1 deletion src/main/kotlin/com/theapache64/stackzy/App.kt
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ fun main() {
// Parsing application arguments
val appArgs = AppArgs(
appName = "Stackzy",
version = "v1.1.3",
version = "v1.2.0",
versionCode = 20210724
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@ class AppDetailViewModel @Inject constructor(
trackUntrackedLibs(report)
_analysisReport.value = AnalysisReportWrapper(
report,
report.libraries.sortedBy { it.id }.map { library ->
report.libraries.sortedBy { it.name }.map { library ->
LibraryWrapper(library, prevResult)
}
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ class AppListViewModel @Inject constructor(
}
?: listOf()

_apps.value = Resource.Success(filteredApps.map { AndroidAppWrapper(it) })
_apps.value = Resource.Success(filteredApps.map { AndroidAppWrapper(it) }.sortedBy { app-> app.getTitle() })
}
is ApkSource.PlayStore -> {
if (isPlayStoreUrl(newKeyword)) {
Expand All @@ -151,7 +151,7 @@ class AppListViewModel @Inject constructor(
val app = playStoreRepo.find(packageName, api)
if (app != null) {
// found app in playstore
_apps.value = Resource.Success(listOf(AndroidAppWrapper(app)))
_apps.value = Resource.Success(listOf(AndroidAppWrapper(app)).sortedBy { it->it.getTitle() })
} else {
_apps.value = Resource.Error("Invalid PlayStore URL")
}
Expand Down