diff --git a/CHANGELOG.md b/CHANGELOG.md index 69f2ecf..eeaf579 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Fixed +- **Software Versions**: Show all software updates instead of only the first 100 + ## [0.6.1] - 2025-12-22 ### Fixed diff --git a/app/src/main/java/com/matedroid/data/api/TeslamateApi.kt b/app/src/main/java/com/matedroid/data/api/TeslamateApi.kt index 9569184..95f3651 100644 --- a/app/src/main/java/com/matedroid/data/api/TeslamateApi.kt +++ b/app/src/main/java/com/matedroid/data/api/TeslamateApi.kt @@ -69,6 +69,8 @@ interface TeslamateApi { @GET("api/v1/cars/{carId}/updates") suspend fun getUpdates( - @Path("carId") carId: Int + @Path("carId") carId: Int, + @Query("page") page: Int? = null, + @Query("show") show: Int? = null ): Response } diff --git a/app/src/main/java/com/matedroid/data/repository/TeslamateRepository.kt b/app/src/main/java/com/matedroid/data/repository/TeslamateRepository.kt index 56be477..96e6d12 100644 --- a/app/src/main/java/com/matedroid/data/repository/TeslamateRepository.kt +++ b/app/src/main/java/com/matedroid/data/repository/TeslamateRepository.kt @@ -187,7 +187,7 @@ class TeslamateRepository @Inject constructor( suspend fun getUpdates(carId: Int): ApiResult> { return try { val api = getApi() ?: return ApiResult.Error("Server not configured") - val response = api.getUpdates(carId) + val response = api.getUpdates(carId, page = 1, show = 50000) if (response.isSuccessful) { val updates = response.body()?.data?.updates ?: emptyList() ApiResult.Success(updates)