Toggle navigation
Toggle navigation
This project
Loading...
Sign in
open-source
/
warply_android_sdk_maven_plugin
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
Panagiotis Triantafyllou
2025-01-21 11:22:33 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
db376f75d506cdb82712f09aaa99dd7ea04ad620
db376f75
1 parent
8c427ef5
minor fixes
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
16 deletions
warply_android_sdk/src/main/java/ly/warp/sdk/io/models/Coupon.java
warply_android_sdk/src/main/java/ly/warp/sdk/io/models/MarketPassDetailsModel.java
warply_android_sdk/src/main/java/ly/warp/sdk/io/models/Coupon.java
View file @
db376f7
...
...
@@ -272,18 +272,10 @@ public class Coupon implements Parcelable, Serializable {
public
RedeemMerchantDetails
(
JSONObject
json
)
{
if
(
json
!=
null
)
{
if
(
json
.
optJSONObject
(
IMG_PREVIEW
)
!=
null
)
{
this
.
imgPreview
=
json
.
optString
(
IMG_PREVIEW
);
}
if
(
json
.
optJSONObject
(
NAME
)
!=
null
)
{
this
.
name
=
json
.
optString
(
NAME
);
}
if
(
json
.
optJSONObject
(
UUID
)
!=
null
)
{
this
.
uuid
=
json
.
optString
(
UUID
);
}
if
(
json
.
optJSONObject
(
REDEEMED_DATE
)
!=
null
)
{
this
.
redeemedDate
=
json
.
optString
(
REDEEMED_DATE
);
}
this
.
imgPreview
=
json
.
isNull
(
IMG_PREVIEW
)
?
""
:
json
.
optString
(
IMG_PREVIEW
);
this
.
name
=
json
.
isNull
(
NAME
)
?
""
:
json
.
optString
(
NAME
);
this
.
uuid
=
json
.
isNull
(
UUID
)
?
""
:
json
.
optString
(
UUID
);
this
.
redeemedDate
=
json
.
isNull
(
REDEEMED_DATE
)
?
""
:
json
.
optString
(
REDEEMED_DATE
);
}
}
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/io/models/MarketPassDetailsModel.java
View file @
db376f7
...
...
@@ -82,7 +82,7 @@ public class MarketPassDetailsModel {
}
}
}
this
.
barcode
=
json
.
optString
(
BARCODE
);
this
.
barcode
=
json
.
isNull
(
BARCODE
)
?
""
:
json
.
optString
(
BARCODE
);
this
.
totalDiscount
=
json
.
optDouble
(
TOTAL_DISCOUNT
);
this
.
newOffers
=
json
.
optInt
(
NEW_OFFERS
);
}
...
...
@@ -153,9 +153,9 @@ public class MarketPassDetailsModel {
public
Supermarkets
(
JSONObject
json
)
{
if
(
json
!=
null
)
{
this
.
logo
=
json
.
optString
(
LOGO
);
this
.
name
=
json
.
optString
(
NAME
);
this
.
uuid
=
json
.
optString
(
UUID
);
this
.
logo
=
json
.
isNull
(
LOGO
)
?
""
:
json
.
optString
(
LOGO
);
this
.
name
=
json
.
isNull
(
NAME
)
?
""
:
json
.
optString
(
NAME
);
this
.
uuid
=
json
.
isNull
(
UUID
)
?
""
:
json
.
optString
(
UUID
);
}
}
...
...
Please
register
or
login
to post a comment