Skip to content

Commit

Permalink
Merge pull request #366 from dreautall/develop
Browse files Browse the repository at this point in the history
v1.0.2
  • Loading branch information
dreautall authored Apr 19, 2024
2 parents 7edfcee + afeb388 commit fd469e2
Show file tree
Hide file tree
Showing 21 changed files with 1,436 additions and 1,047 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ jobs:
# Call setup_env action to setup workspace
- uses: ./.github/actions/setup_env
with:
java-version: ${{ vars.JAVA_VERSION }}
flutter-channel: ${{ vars.FLUTTER_CHANNEL }}
java-version: 17.x
flutter-channel: stable

# Check for any formatting issues in the code.
- run: dart format --set-exit-if-changed .
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ jobs:
# Call setup_env action to setup workspace
- uses: ./.github/actions/setup_env
with:
java-version: ${{ vars.JAVA_VERSION }}
flutter-channel: ${{ vars.FLUTTER_CHANNEL }}
java-version: 17.x
flutter-channel: stable

# Generate keystore
- uses: timheuer/[email protected]
Expand All @@ -49,9 +49,10 @@ jobs:
sed -i 's/^\(version: [0-9\.]\{1,\}\(-[a-z]\{1,\}\)\{0,1\}\)$/\1+${{ github.run_number }}/m' pubspec.yaml
# Build apk.
- run: flutter build apk --obfuscate --split-debug-info=build/app/outputs/symbols/apk --release --split-per-abi
- run: flutter build apk --obfuscate --split-debug-info=build/app/outputs/symbols/apk --release --split-per-abi --dart-define=cronetHttpNoPlay=true

# Build aab
# Since the aab is only distributed to the play store and never uploaded somewhere else, we can use the Google Play Services cronet here.
- run: flutter build appbundle --obfuscate --split-debug-info=build/app/outputs/symbols/aab --release

# Zip symbols
Expand Down
6 changes: 6 additions & 0 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@
<package android:name="com.marcus.android"/>
<package android:name="com.marcus.android.uk"/>
<package android:name="com.mashreq.NeoApp"/>
<package android:name="com.maybank2u.life"/>
<package android:name="com.mercadolibre"/>
<package android:name="com.mercadopago.wallet"/>
<package android:name="com.microsoft.android.smsorganizer"/>
Expand Down Expand Up @@ -195,6 +196,7 @@
<package android:name="com.softteco.bsbank"/>
<package android:name="com.starlingbank.android"/>
<package android:name="com.taxis99"/>
<package android:name="com.tpaay.bigpay"/>
<package android:name="com.transferwise.android"/>
<package android:name="com.ukrsibbank.client.android"/>
<package android:name="com.unicredit"/>
Expand All @@ -207,10 +209,12 @@
<package android:name="com.zen.application"/>
<package android:name="consumer.cbsa.smartapp"/>
<package android:name="cz.mbank"/>
<package android:name="de.c24.bankapp"/>
<package android:name="de.dkb.portalapp"/>
<package android:name="de.dwins.financeguru"/>
<package android:name="de.ingdiba.bankingapp"/>
<package android:name="de.number26.android"/>
<package android:name="de.traderepublic.app"/>
<package android:name="es.bancosantander.apps"/>
<package android:name="eu.netinfo.colpatria.system"/>
<package android:name="fi.danskebank.mobilepay"/>
Expand All @@ -237,6 +241,8 @@
<package android:name="in.codeseed.undonotification.pro"/>
<package android:name="md.maib.maibank"/>
<package android:name="mx.com.hsbc.controltotal"/>
<package android:name="my.com.myboost"/>
<package android:name="my.com.tngdigital.ewallet"/>
<package android:name="net.easypark.android"/>
<package android:name="nl.rabomobiel"/>
<package android:name="om.nu.production"/>
Expand Down
4 changes: 4 additions & 0 deletions fastlane/metadata/android/de-DE/changelogs/289.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
- Zeige Schlagwörter in der Transaktions-Liste
- Update der Übersetzungen
- Unterstützung für zusätzliche Banking-Apps
- Fehlerbehebungen
4 changes: 4 additions & 0 deletions fastlane/metadata/android/en-US/changelogs/289.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
- Show tags on transaction screen
- Translation updates
- Add support for additional banking apps
- Bugfixes
17 changes: 17 additions & 0 deletions fastlane/metadata/android/pt-PT/full_description.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Waterfly III é um aplicativo não oficial para sua própria instância do Firefly III, um gerenciador financeiro gratuito e de código aberto.

Este aplicativo requer uma instância do Firefly III auto-hospedada em seu próprio servidor. É apenas um aplicativo complementar e não pode ser executado de forma independente!

Características:

- Painel com gráficos e visão geral do orçamento
- Lista de transações com filtros
- Adicione e edite transações com preenchimento automático, incluindo anexos, transações divididas e suporte a várias moedas
- Suporte ao Piggy Bank (visualizar e adicionar dinheiro)
- Serviço de ouvinte de notificação para criar facilmente novas transações com base em notificações recebidas (por exemplo, do Google Pay ou de seu aplicativo bancário)
- Código totalmente aberto: https://github.com/dreutall/waterfly-iii
- Sem anúncios ou rastreadores

Contribuição:

Se você encontrar uma falha ou sentir falta de um recurso, sinta-se à vontade para dar opinião na Play Store, enviar-me um e-mail ou abrir um chamado no GitHub.
1 change: 1 addition & 0 deletions fastlane/metadata/android/pt-PT/short_description.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Aplicativo não oficial para Firefly III, um gerenciador de finanças pessoais de código aberto.
18 changes: 9 additions & 9 deletions fastlane/metadata/android/sv-SE/full_description.txt
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
Waterfly III är en inofficiell app för din egna instans av Firefly III, en fri och öppen finanshanterare.

Denna app kräver en egen Firefly III instans på din egna server, besök https://www.firefly-iii.org/ för mer information om programvaran. Detta är endast en medföljande app och kan inte köra utan en Firefly III instans!
Denna app kräver en självhostad Firefly III-instans på din egen server, vänligen besök https://www.firefly-iii.org/ för mer information om programvaran. Detta appen kan inte köras fristående!

Funktioner:

- Kontrollpanel med diagram & budgetöversikt
- En dashboard med diagram & budgetöversikt
- Transaktionslista med filter
- Lägg till och redigera transaktioner med autocomplete, inklusive bilagor, delade transaktioner och stöd för flera valutor
- Stöd för spargrisar (visa och lägg till pengar)
- Notifikationslyssnartjänsten kan enkelt skapa nya transaktioner baserat på inkommande meddelanden (t.ex. från Google Pay eller din bankapp)
- Helt öppen källkod: https://github.com/dreautall/waterfly-iii
- Inga annonser eller trackers
- Lägg till & redigera transaktioner med autokomplettering, inklusive bilagor, delade transaktioner & stöd för flera valutor
- Stöd för "Piggy Bank" (visa & lägg till pengar)
- Tjänst för att lyssna av notifikationer för att enkelt skapa nya transaktioner baserade på inkommande notifikationer (t.ex. från Google Pay eller din bankapp)
- Fullständigt öppen källkod: https://github.com/dreautall/waterfly-iii
- Inga annonser eller spårare

Bidra:
Bidrag:

Om du stöter på en bugg eller saknar en funktion, får du gärna ge feedback i play store, skicka mig ett mail eller öppna ett ärende på GitHub.
Om du stöter på ett fel eller saknar en funktion, tveka inte att ge feedback i Play Store, skicka ett e-postmeddelande till mig eller öppna ett ärende på GitHub.
4 changes: 2 additions & 2 deletions fastlane/metadata/android/version.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
versionName=1.0.1
versionCode=271
versionName=1.0.2
versionCode=289
40 changes: 26 additions & 14 deletions lib/auth.dart
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import 'dart:convert';
import 'dart:io';

import 'package:cronet_http/cronet_http.dart';
import 'package:flutter/material.dart';
import 'package:flutter_gen/gen_l10n/app_localizations.dart';
import 'package:http/http.dart' as http;
import 'package:logging/logging.dart';

import 'package:chopper/chopper.dart'
show Request, Response, StripStringExtension;
show HttpMethod, Request, Response, StripStringExtension;
import 'package:flutter_secure_storage/flutter_secure_storage.dart';
import 'package:shared_preferences/shared_preferences.dart';
import 'package:version/version.dart';
Expand Down Expand Up @@ -103,6 +105,16 @@ class AuthErrorNoInstance extends AuthError {
final String host;
}

http.Client get httpClient {
// Only for Android
return CronetClient.fromCronetEngine(
CronetEngine.build(
cacheMode: CacheMode.memory,
cacheMaxSize: 2 * 1024 * 1024,
),
);
}

class AuthUser {
late Uri _host;
late String _apiKey;
Expand All @@ -123,6 +135,7 @@ class AuthUser {

_api = FireflyIii.create(
baseUrl: _host,
httpClient: httpClient,
interceptors: <dynamic>[
(Request request) async {
log.finest(() => "API query to ${request.url}");
Expand All @@ -141,6 +154,7 @@ class AuthUser {

_apiV2 = FireflyIiiV2.create(
baseUrl: _host,
httpClient: httpClient,
interceptors: <dynamic>[
(Request request) async {
log.finest(() => "APIv2 query to ${request.url}");
Expand Down Expand Up @@ -170,7 +184,7 @@ class AuthUser {
log.config("AuthUser->create($host)");

// This call is on purpose not using the Swagger API
final HttpClient client = HttpClient();
final http.Client client = httpClient;
late Uri uri;

try {
Expand All @@ -187,10 +201,10 @@ class AuthUser {
]);

try {
HttpClientRequest request = await client.getUrl(aboutUri);
request.headers.add(HttpHeaders.authorizationHeader, "Bearer $apiKey");
final http.Request request = http.Request(HttpMethod.Get, aboutUri);
request.headers[HttpHeaders.authorizationHeader] = "Bearer $apiKey";
request.followRedirects = false;
HttpClientResponse response = await request.close();
final http.StreamedResponse response = await request.send();

if (response.isRedirect) {
throw const AuthErrorApiKey();
Expand All @@ -199,7 +213,7 @@ class AuthUser {
throw AuthErrorStatusCode(response.statusCode);
}

final String stringData = await response.transform(utf8.decoder).join();
final String stringData = await response.stream.bytesToString();

try {
SystemInfo.fromJson(json.decode(stringData));
Expand Down Expand Up @@ -327,21 +341,19 @@ class FireflyService with ChangeNotifier {
}

// Manual API query as the Swagger type doesn't resolve in Flutter :(
final HttpClient client = HttpClient();
final http.Client client = httpClient;
Uri tzUri = user!.host.replace(pathSegments: <String>[
...user!.host.pathSegments,
"v1",
"configuration",
ConfigValueFilter.appTimezone.value!
]);
try {
HttpClientRequest request = await client.getUrl(tzUri);
user!.headers().forEach(
(String key, String value) => request.headers.add(key, value),
);
HttpClientResponse response = await request.close();
final String stringData = await response.transform(utf8.decoder).join();
final APITZReply reply = APITZReply.fromJson(json.decode(stringData));
final http.Response response = await client.get(
tzUri,
headers: user!.headers(),
);
final APITZReply reply = APITZReply.fromJson(json.decode(response.body));
tzHandler = TimeZoneHandler(reply.data.value);
} finally {
client.close();
Expand Down
2 changes: 1 addition & 1 deletion lib/l10n/app_de.arb
Original file line number Diff line number Diff line change
Expand Up @@ -812,7 +812,7 @@
"@settingsDialogDebugMailCreate": {
"description": "Button to confirm mail creation after privacy disclaimer is shown."
},
"settingsDialogDebugMailDisclaimer": "ACHTUNG: Ein E-Mail Entwurf wird mit angehängtem Fehlerprotokoll erstellt. Das Fehlerprotokoll kann sensible Informationen wie zum Beispiel die URL deiner Firefly-Instanz enthalten (auch wenn ich versuche, geheime Informationen wie den API-Schlüssel nicht zu protokollieren). Bitte lese vor dem Senden der Mail das Protokoll durch und zensiere alle Informationen, die du nicht teilen möchtest.\n\nBitte sende keine Fehlerprotokolle ohne vorherige Absprache mit mir via Mail/GitHub. Ich werde alle ohne Kontext eingesendete Protokolle aus Datenschutzgründen löschen. Lade die Protokolle nie auf GitHub oder anderswo hoch.",
"settingsDialogDebugMailDisclaimer": "ACHTUNG: Ein E-Mail Entwurf wird mit angehängtem Fehlerprotokoll (einer Textdatei) erstellt. Das Fehlerprotokoll kann sensible Informationen, wie zum Beispiel die URL deiner Firefly-Instanz, enthalten (auch wenn ich versuche, geheime Informationen wie den API-Schlüssel nicht zu protokollieren). Bitte lese vor dem Senden der Mail das Protokoll durch und zensiere alle Informationen, die du nicht teilen möchtest.\n\nBitte sende keine Fehlerprotokolle ohne vorherige Absprache mit mir via Mail/GitHub. Ich werde alle ohne Kontext eingesendete Protokolle aus Datenschutzgründen löschen. Lade die Protokolle nie auf GitHub oder anderswo hoch.",
"@settingsDialogDebugMailDisclaimer": {
"description": "Privacy disclaimer shown before sending logs"
},
Expand Down
Loading

0 comments on commit fd469e2

Please sign in to comment.