Compare commits

...

13 Commits

Author SHA1 Message Date
Sylvia van Os
4bf6f6cd5f Release Catima 2.16.3 2022-04-15 18:51:42 +02:00
Sylvia van Os
1872bea0c3 Stocard: Ignore cards with missing card data
Stocard appears to keep images for deleted cards, which causes some
cards to have only images and no data, making them impossible to import.

This is most likely a bug on Stocard's side. As a workaround, we ignore
cards with no data file.
2022-04-14 22:25:46 +02:00
Sylvia van Os
665ef5f712 Merge pull request #864 from CatimaLoyalty/create-pull-request/patch-1649961053
Update Fastlane changelogs
2022-04-14 20:31:52 +02:00
TheLastProject
9fbcb23465 Update Fastlane changelogs 2022-04-14 18:30:52 +00:00
Sylvia van Os
25c35acd6d Import Stocard GS1_128 as CODE_128
GS1_128 seems to be an implementation of CODE_128. ZXING doesn't
explicitly support GS1_128, but CODE_128 should work probably.
2022-04-14 20:30:35 +02:00
Sylvia van Os
35747b7d9f Fix import getting stuck on unexpected exception 2022-04-14 20:20:36 +02:00
Sylvia van Os
eea5cdfdd0 Merge pull request #862 from CatimaLoyalty/create-pull-request/patch-1649567192
Update contributors
2022-04-10 11:16:32 +02:00
TheLastProject
e0c28830ab Update contributors 2022-04-10 05:06:31 +00:00
bors[bot]
e714d98ae6 Merge #860
860: Translations update from Hosted Weblate r=TheLastProject a=weblate

Translations update from [Hosted Weblate](https://hosted.weblate.org) for [Catima/Android](https://hosted.weblate.org/projects/catima/catima/).


It also includes following components:

* [Catima/Android (Fastlane)](https://hosted.weblate.org/projects/catima/fastlane/)



Current translation status:

![Weblate translation status](https://hosted.weblate.org/widgets/catima/-/catima/horizontal-auto.svg)


Co-authored-by: 109247019824 <stoyan@gmx.com>
Co-authored-by: Quentin PAGÈS <quentinantonin@free.fr>
2022-04-08 20:03:02 +00:00
Sylvia van Os
bbfba92de0 Merge pull request #859 from CatimaLoyalty/create-pull-request/patch-1648963016
Update contributors
2022-04-08 22:02:32 +02:00
Quentin PAGÈS
efda8f9f10 Translated using Weblate (Occitan)
Currently translated at 39.5% (96 of 243 strings)

Translation: Catima/Android
Translate-URL: https://hosted.weblate.org/projects/catima/catima/oc/
2022-04-04 09:10:40 +02:00
109247019824
041472b44b Translated using Weblate (Bulgarian)
Currently translated at 4.7% (5 of 105 strings)

Translation: Catima/Android (Fastlane)
Translate-URL: https://hosted.weblate.org/projects/catima/fastlane/bg/
2022-04-04 09:10:40 +02:00
TheLastProject
92f79e9d3e Update contributors 2022-04-03 05:16:56 +00:00
9 changed files with 27 additions and 8 deletions

View File

@@ -1,5 +1,9 @@
# Changelog
## v2.16.3 - 107 (2022-04-15)
- Stocard import fixes
## v2.16.2 - 106 (2022-03-31)
- Fix some character sequences being shown as a single character

View File

@@ -18,8 +18,8 @@ android {
applicationId "me.hackerchick.catima"
minSdkVersion 21
targetSdkVersion 31
versionCode 106
versionName "2.16.2"
versionCode 107
versionName "2.16.3"
vectorDrawables.useSupportLibrary true
multiDexEnabled true

View File

@@ -55,7 +55,7 @@ public class MultiFormatImporter {
return new ImportExportResult(ImportExportResultType.Success);
} catch (ZipException e) {
return new ImportExportResult(ImportExportResultType.BadPassword);
} catch (IOException | FormatException | InterruptedException | JSONException | ParseException | NullPointerException e) {
} catch (Exception e) {
Log.e(TAG, "Failed to import data", e);
error = e.toString();
} finally {

View File

@@ -3,6 +3,7 @@ package protect.card_locker.importexport;
import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.graphics.Bitmap;
import android.util.Log;
import com.google.zxing.BarcodeFormat;
@@ -39,6 +40,8 @@ import protect.card_locker.ZipUtils;
* A header is expected for the each table showing the names of the columns.
*/
public class StocardImporter implements Importer {
private static final String TAG = "Catima";
public void importData(Context context, SQLiteDatabase database, InputStream input, char[] password) throws IOException, FormatException, JSONException, ParseException {
HashMap<String, HashMap<String, Object>> loyaltyCardHashMap = new HashMap<>();
HashMap<String, HashMap<String, Object>> providers = new HashMap<>();
@@ -201,6 +204,12 @@ public class StocardImporter implements Importer {
for (HashMap<String, Object> loyaltyCardData : loyaltyCardHashMap.values()) {
String providerId = (String) loyaltyCardData.get("_providerId");
if (providerId == null) {
Log.d(TAG, "Missing providerId for card " + loyaltyCardData + ", ignoring...");
continue;
}
HashMap<String, Object> providerData = providers.get(providerId);
String store = providerData != null ? providerData.get("name").toString() : providerId;
@@ -211,6 +220,8 @@ public class StocardImporter implements Importer {
if (barcodeTypeString != null && !barcodeTypeString.isEmpty()) {
if (barcodeTypeString.equals("RSS_DATABAR_EXPANDED")) {
barcodeType = CatimaBarcode.fromBarcode(BarcodeFormat.RSS_EXPANDED);
} else if (barcodeTypeString.equals("GS1_128")) {
barcodeType = CatimaBarcode.fromBarcode(BarcodeFormat.CODE_128);
} else {
barcodeType = CatimaBarcode.fromName(barcodeTypeString);
}

View File

@@ -9,8 +9,8 @@ mondstern
Oğuz Ersen
Altonss
IllusiveMan196
Petr Novák
StoyanDimitrov
Petr Novák
Joel A
Taco
Gediminas Murauskas
@@ -23,12 +23,12 @@ Sergio Paredes
huuhaa
laralem
arshbeerSingh
Quentin PAGÈS
Miha Frangež
sr093906
mdvhimself
Maciej Błędkowski
Olivia (Zoe)
Quentin PAGÈS
betsythefc
Silvério Santos
waffshappen
@@ -83,10 +83,11 @@ Ronak Upadhyay
Rose Liverman
Simone Dotto
Subhashish Anand
darkodo
Tymofii Lytvynenko
Tjipke van der Heide
Yevgeny M
avikkundu
Avik Kundu
opsik
psa-jforestier
Robin

View File

@@ -66,4 +66,6 @@
<string name="groups">Grops</string>
<string name="groupsList">Grops: <xliff:g>%s</xliff:g></string>
<string name="settings_max_font_size_scale">Talha max. de la poliça</string>
<string name="settings_theme_color">Color del tèma</string>
<string name="settings_locale">Lenga</string>
</resources>

View File

@@ -1 +1 @@
За щрихкодове, членства, програми за лоялност, талони и билети.
За щрихкодове, карти за членства и лоялност, талони и билети.

View File

@@ -1 +1 @@
Catima
Catima портфейл за карти

View File

@@ -0,0 +1 @@
- Stocard import fixes