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
2022-10-13 15:19:10 +0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
66869a02fcd2a949f7da543f1f4405326d7644fe
66869a02
1 parent
12f1cf86
new keys
Show whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
55 additions
and
54 deletions
warply_android_sdk/build.gradle
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ActiveCouponsActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ActiveGiftsActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ContextualActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponInfoActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponShareActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponsetInfoActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/GiftsForYouActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/LoyaltyAnalysisActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/LoyaltyWallet.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/MoreForYouActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ShopsActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/activities/TelcoActivity.java
warply_android_sdk/src/main/java/ly/warp/sdk/utils/WarplyManagerHelper.java
warply_android_sdk/src/main/java/ly/warp/sdk/utils/managers/WarplyAnalyticsManager.java
warply_android_sdk/build.gradle
View file @
66869a0
...
...
@@ -2,7 +2,7 @@ apply plugin: 'com.android.library'
ext
{
PUBLISH_GROUP_ID
=
'ly.warp'
PUBLISH_VERSION
=
'4.5.4-cosbeta9
1
'
PUBLISH_VERSION
=
'4.5.4-cosbeta9
2
'
PUBLISH_ARTIFACT_ID
=
'warply-android-sdk'
}
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ActiveCouponsActivity.java
View file @
66869a0
...
...
@@ -61,7 +61,7 @@ public class ActiveCouponsActivity extends Activity implements View.OnClickListe
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"ActiveCouponsScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"ActiveCouponsScreen"
);
filterItems
();
}
...
...
@@ -110,7 +110,7 @@ public class ActiveCouponsActivity extends Activity implements View.OnClickListe
mRecyclerCoupons
.
setAdapter
(
mAdapterCoupons
);
mAdapterCoupons
.
getPositionClicks
()
.
doOnNext
(
coupon
->
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Coupon"
).
concat
(
":"
).
concat
(
coupon
.
getName
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Coupon"
).
concat
(
":"
).
concat
(
coupon
.
getName
()));
Intent
intent
=
new
Intent
(
ActiveCouponsActivity
.
this
,
CouponInfoActivity
.
class
);
intent
.
putExtra
(
"coupon"
,
(
Serializable
)
coupon
);
startActivity
(
intent
);
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ActiveGiftsActivity.java
View file @
66869a0
...
...
@@ -61,7 +61,7 @@ public class ActiveGiftsActivity extends Activity implements View.OnClickListene
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"ActiveGiftsScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"ActiveGiftsScreen"
);
}
@Override
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ContextualActivity.java
View file @
66869a0
...
...
@@ -78,7 +78,7 @@ public class ContextualActivity extends Activity implements View.OnClickListener
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"ContextualScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"ContextualScreen"
);
// new Thread(() -> {
// if (!Thread.currentThread().isInterrupted()) {
...
...
@@ -187,7 +187,7 @@ public class ContextualActivity extends Activity implements View.OnClickListener
}
private
void
activateGift
()
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"ActivateContextual"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"ActivateContextual"
)
.
concat
(
":"
)
.
concat
(
mCCMS
.
getSessionId
()));
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponInfoActivity.java
View file @
66869a0
...
...
@@ -90,7 +90,7 @@ public class CouponInfoActivity extends Activity implements View.OnClickListener
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"CouponScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"CouponScreen"
);
}
@Override
...
...
@@ -111,7 +111,7 @@ public class CouponInfoActivity extends Activity implements View.OnClickListener
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
ll_gift_it
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"ShareCoupon"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"ShareCoupon"
)
.
concat
(
":"
)
.
concat
(
mCoupon
.
getName
()));
...
...
@@ -125,7 +125,7 @@ public class CouponInfoActivity extends Activity implements View.OnClickListener
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
ll_shops
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
"SeeShops"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
"SeeShops"
);
Intent
intent
=
new
Intent
(
CouponInfoActivity
.
this
,
ShopsActivity
.
class
);
intent
.
putExtra
(
"couponset"
,
(
Serializable
)
mCouponset
);
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponShareActivity.java
View file @
66869a0
...
...
@@ -93,7 +93,7 @@ public class CouponShareActivity extends Activity implements View.OnClickListene
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"CouponShareScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"CouponShareScreen"
);
WarplyManager
.
getConsumer
(
new
WarplyConsumerRequest
()
,
mConsumerCallback
);
...
...
@@ -275,7 +275,7 @@ public class CouponShareActivity extends Activity implements View.OnClickListene
.
setTitle
(
R
.
string
.
cos_dlg_positive_coupon_title
)
.
setMessage
(
R
.
string
.
cos_dlg_positive_coupon_subtitle
)
.
setPositiveButton
(
R
.
string
.
cos_dlg_negative_button3
,
(
dialogPositive
,
whichPositive
)
->
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"ShareCoupon"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"ShareCoupon"
)
.
concat
(
":"
)
.
concat
(
mCoupon
.
getName
()));
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/CouponsetInfoActivity.java
View file @
66869a0
...
...
@@ -98,7 +98,7 @@ public class CouponsetInfoActivity extends Activity implements View.OnClickListe
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"CouponsetScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"CouponsetScreen"
);
}
@Override
...
...
@@ -109,7 +109,7 @@ public class CouponsetInfoActivity extends Activity implements View.OnClickListe
}
if
(
view
.
getId
()
==
R
.
id
.
ll_get_gift
)
{
mPbLoading
.
setVisibility
(
View
.
VISIBLE
);
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"RetrieveCoupon"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"RetrieveCoupon"
)
.
concat
(
":"
)
.
concat
(
mCouponset
.
getUuid
()));
if
(
mCcms
==
null
)
{
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/GiftsForYouActivity.java
View file @
66869a0
...
...
@@ -95,7 +95,7 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"GiftsForYouScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"GiftsForYouScreen"
);
mTimer
=
0
;
mSecondsHandler
.
post
(
new
Runnable
()
{
@Override
...
...
@@ -249,7 +249,7 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
analyticsEvent
.
setParameter
(
"type"
,
"coupon"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyManager
.
getSingleCampaign
(
dataItem
.
getCampaign
().
getSessionUUID
());
Intent
intent
=
new
Intent
(
GiftsForYouActivity
.
this
,
CouponsetInfoActivity
.
class
);
intent
.
putExtra
(
"couponset"
,
(
Serializable
)
cpns
);
...
...
@@ -260,7 +260,7 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
}
}
}
else
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCampaignUrl
(
dataItem
.
getCampaign
())),
1004
);
}
}
...
...
@@ -285,7 +285,7 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
analyticsEvent
.
setParameter
(
"type"
,
"coupon"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyManager
.
getSingleCampaign
(
dataItem
.
getCampaign
().
getSessionUUID
());
Intent
intent
=
new
Intent
(
GiftsForYouActivity
.
this
,
CouponsetInfoActivity
.
class
);
intent
.
putExtra
(
"couponset"
,
(
Serializable
)
cpns
);
...
...
@@ -295,7 +295,7 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
}
}
}
else
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCampaignUrl
(
dataItem
.
getCampaign
())),
1004
);
}
}
...
...
@@ -318,7 +318,7 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
analyticsEvent
.
setParameter
(
"type"
,
"gift"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Telco"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Telco"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
WarplyManager
.
getSingleCampaign
(
dataItem
.
getCampaign
().
getSessionUUID
());
Intent
intent
=
new
Intent
(
GiftsForYouActivity
.
this
,
TelcoActivity
.
class
);
intent
.
putExtra
(
"ccms"
,
ccms
);
...
...
@@ -332,18 +332,18 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
if
(
extraFields
.
has
(
"ccms_offer"
)
&&
extraFields
.
optString
(
"ccms_offer"
).
equals
(
"true"
))
{
for
(
LoyaltyContextualOfferModel
ccms
:
WarplyManagerHelper
.
getCCMSLoyaltyCampaigns
())
{
if
(
ccms
.
getLoyaltyCampaignId
().
equals
(
dataItem
.
getCampaign
().
getSessionUUID
()))
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCcmsUrl
(
dataItem
.
getCampaign
(),
ccms
)),
1004
);
break
;
}
}
}
else
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCampaignUrl
(
dataItem
.
getCampaign
())),
1004
);
}
}
}
catch
(
Exception
exception
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
dataItem
.
getCampaign
().
getSessionUUID
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCampaignUrl
(
dataItem
.
getCampaign
())),
1004
);
}
}
else
if
(
dataItem
.
getDataType
()
==
2
)
{
...
...
@@ -366,7 +366,7 @@ public class GiftsForYouActivity extends AppCompatActivity implements View.OnCli
analyticsEvent
.
setParameter
(
"type"
,
"gift"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
dataItem
.
getCCMS
().
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
dataItem
.
getCCMS
().
getSessionId
()));
Intent
intent
=
new
Intent
(
GiftsForYouActivity
.
this
,
ContextualActivity
.
class
);
intent
.
putExtra
(
"ccms"
,
dataItem
.
getCCMS
());
startActivity
(
intent
);
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/LoyaltyAnalysisActivity.java
View file @
66869a0
...
...
@@ -92,7 +92,7 @@ public class LoyaltyAnalysisActivity extends Activity implements View.OnClickLis
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"LoyaltyHistoryScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"LoyaltyHistoryScreen"
);
mTimer
=
0
;
mSecondsHandler
.
post
(
new
Runnable
()
{
@Override
...
...
@@ -139,7 +139,7 @@ public class LoyaltyAnalysisActivity extends Activity implements View.OnClickLis
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
ll_tab_expired
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"LoyaltyHistoryScreen"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"LoyaltyHistoryScreen"
)
.
concat
(
":"
)
.
concat
(
"TabExpired"
));
...
...
@@ -166,7 +166,7 @@ public class LoyaltyAnalysisActivity extends Activity implements View.OnClickLis
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
ll_tab_shared
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"LoyaltyHistoryScreen"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"LoyaltyHistoryScreen"
)
.
concat
(
":"
)
.
concat
(
"TabShared"
));
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/LoyaltyWallet.java
View file @
66869a0
...
...
@@ -157,7 +157,7 @@ public class LoyaltyWallet extends Activity implements View.OnClickListener, Vie
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"LoyaltyWalletScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"LoyaltyWalletScreen"
);
mTimer
=
0
;
mSecondsHandler
.
post
(
new
Runnable
()
{
@Override
...
...
@@ -189,7 +189,7 @@ public class LoyaltyWallet extends Activity implements View.OnClickListener, Vie
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
ll_user_questionnaire
||
view
.
getId
()
==
R
.
id
.
ll_user_badge
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"LoyaltyWalletScreen"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"LoyaltyWalletScreen"
)
.
concat
(
":"
)
.
concat
(
"Questionnaire"
));
...
...
@@ -197,7 +197,7 @@ public class LoyaltyWallet extends Activity implements View.OnClickListener, Vie
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
cl_deals_cos
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"LoyaltyWalletScreen"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"LoyaltyWalletScreen"
)
.
concat
(
":"
)
.
concat
(
"DealsBanner"
));
...
...
@@ -213,7 +213,7 @@ public class LoyaltyWallet extends Activity implements View.OnClickListener, Vie
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
cl_deals_win
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"LoyaltyWalletScreen"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"LoyaltyWalletScreen"
)
.
concat
(
":"
)
.
concat
(
"LoyaltyBanner"
));
...
...
@@ -227,7 +227,7 @@ public class LoyaltyWallet extends Activity implements View.OnClickListener, Vie
return
;
}
if
(
view
.
getId
()
==
R
.
id
.
cl_mygifts
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"LoyaltyWalletScreen"
)
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"LoyaltyWalletScreen"
)
.
concat
(
":"
)
.
concat
(
"ActiveDealsBanner"
));
...
...
@@ -296,7 +296,7 @@ public class LoyaltyWallet extends Activity implements View.OnClickListener, Vie
mRecyclerCoupons
.
setAdapter
(
mAdapterCoupons
);
mAdapterCoupons
.
getPositionClicks
()
.
doOnNext
(
coupon
->
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Coupon"
).
concat
(
":"
).
concat
(
coupon
.
getName
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Coupon"
).
concat
(
":"
).
concat
(
coupon
.
getName
()));
Intent
intent
=
new
Intent
(
LoyaltyWallet
.
this
,
CouponInfoActivity
.
class
);
intent
.
putExtra
(
"coupon"
,
(
Serializable
)
coupon
);
intent
.
putExtra
(
"isFromWallet"
,
true
);
...
...
@@ -350,7 +350,7 @@ public class LoyaltyWallet extends Activity implements View.OnClickListener, Vie
mRecyclerCoupons
.
setAdapter
(
mAdapterCoupons
);
mAdapterCoupons
.
getPositionClicks
()
.
doOnNext
(
coupon
->
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Coupon"
).
concat
(
":"
).
concat
(
coupon
.
getName
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Coupon"
).
concat
(
":"
).
concat
(
coupon
.
getName
()));
Intent
intent
=
new
Intent
(
LoyaltyWallet
.
this
,
CouponInfoActivity
.
class
);
intent
.
putExtra
(
"coupon"
,
(
Serializable
)
coupon
);
intent
.
putExtra
(
"isFromWallet"
,
true
);
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/MoreForYouActivity.java
View file @
66869a0
...
...
@@ -82,6 +82,7 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
private
MoreContextualAdapter
mAdapterContextual
;
private
int
mTimer
=
0
;
private
Handler
mSecondsHandler
;
/**
* New Implementation
*/
...
...
@@ -138,7 +139,7 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"MoreForYouScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"MoreForYouScreen"
);
mTimer
=
0
;
mSecondsHandler
.
post
(
new
Runnable
()
{
@Override
...
...
@@ -417,7 +418,7 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
if
(
extraFields
.
has
(
"type"
)
&&
extraFields
.
optString
(
"type"
).
equals
(
"telco"
))
{
for
(
LoyaltyContextualOfferModel
ccms
:
WarplyManagerHelper
.
getCCMSLoyaltyCampaigns
())
{
if
(
ccms
.
getLoyaltyCampaignId
().
equals
(
moreItem
.
getSessionUUID
()))
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Telco"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Telco"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
LoyaltySDKFirebaseEventModel
analyticsEvent
=
new
LoyaltySDKFirebaseEventModel
();
analyticsEvent
.
setEventName
(
"loyalty_sdk_offer_selected"
);
...
...
@@ -439,18 +440,18 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
for
(
LoyaltyContextualOfferModel
ccms
:
WarplyManagerHelper
.
getCCMSLoyaltyCampaigns
())
{
if
(
ccms
.
getLoyaltyCampaignId
().
equals
(
moreItem
.
getSessionUUID
()))
{
WarpUtils
.
log
(
"CCMS_CLICK "
+
ccms
.
toString
());
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
ccms
.
getSessionId
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCcmsUrl
(
moreItem
,
ccms
)),
1003
);
break
;
}
}
}
else
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
moreItem
.
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
moreItem
.
getSessionUUID
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCampaignUrl
(
moreItem
)),
1003
);
}
}
}
catch
(
Exception
exception
)
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
moreItem
.
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
moreItem
.
getSessionUUID
()));
startActivityForResult
(
WarpViewActivity
.
createIntentFromURL
(
this
,
WarplyManagerHelper
.
constructCampaignUrl
(
moreItem
)),
1003
);
}
}
...
...
@@ -462,7 +463,7 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
analyticsEvent
.
setParameter
(
"type"
,
"gift"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
ccmsItem
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
ccmsItem
.
getSessionId
()));
Intent
intent
=
new
Intent
(
MoreForYouActivity
.
this
,
ContextualActivity
.
class
);
intent
.
putExtra
(
"ccms"
,
ccmsItem
);
startActivity
(
intent
);
...
...
@@ -476,7 +477,7 @@ public class MoreForYouActivity extends Activity implements View.OnClickListener
ArrayList
<
Campaign
>
mfyList
=
new
ArrayList
<>();
if
(
WarplyManagerHelper
.
getCampaignListAll
()
!=
null
&&
WarplyManagerHelper
.
getCampaignListAll
().
size
()
>
0
)
{
final
ArrayList
<
Campaign
>
customs
=
new
ArrayList
<
Campaign
>();
for
(
Campaign
campaignItem
:
WarplyManagerHelper
.
getCampaignListAll
())
{
for
(
Campaign
campaignItem
:
WarplyManagerHelper
.
getCampaignListAll
())
{
if
(!
customs
.
contains
(
campaignItem
))
{
customs
.
add
(
campaignItem
);
}
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/ShopsActivity.java
View file @
66869a0
...
...
@@ -89,7 +89,7 @@ public class ShopsActivity extends FragmentActivity implements View.OnClickListe
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"ShopsScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"ShopsScreen"
);
}
@Override
...
...
@@ -199,7 +199,7 @@ public class ShopsActivity extends FragmentActivity implements View.OnClickListe
public
boolean
onMarkerClick
(
@NonNull
Marker
marker
)
{
for
(
Merchant
merch
:
mMerchantList
)
{
if
(
merch
.
getUuid
().
equals
(
marker
.
getSnippet
()))
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"ShopsScreenMarker"
).
concat
(
":"
).
concat
(
marker
.
getSnippet
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"ShopsScreenMarker"
).
concat
(
":"
).
concat
(
marker
.
getSnippet
()));
final
BottomSheetDialog
bottomSheetDialog
=
new
BottomSheetDialog
(
this
);
bottomSheetDialog
.
setContentView
(
R
.
layout
.
dl_map_pin
);
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/activities/TelcoActivity.java
View file @
66869a0
...
...
@@ -91,7 +91,7 @@ public class TelcoActivity extends Activity implements View.OnClickListener {
@Override
public
void
onResume
()
{
super
.
onResume
();
WarplyAnalyticsManager
.
logTrackersEvent
(
"screen"
,
"TelcoScreen"
);
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"screen"
,
"TelcoScreen"
);
// new Thread(() -> {
// if (!Thread.currentThread().isInterrupted()) {
...
...
@@ -224,7 +224,7 @@ public class TelcoActivity extends Activity implements View.OnClickListener {
}
private
void
activateGift
()
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"ActivateTelco"
).
concat
(
":"
).
concat
(
mCCMS
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
this
,
"click"
,
(
"ActivateTelco"
).
concat
(
":"
).
concat
(
mCCMS
.
getSessionId
()));
new
Thread
(()
->
{
if
(!
Thread
.
currentThread
().
isInterrupted
())
{
WarplyManager
.
submitOrder
(
new
CosmoteSubmitOrderRequest
()
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/utils/WarplyManagerHelper.java
View file @
66869a0
...
...
@@ -655,7 +655,7 @@ public class WarplyManagerHelper {
analyticsEvent
.
setParameter
(
"type"
,
"gift"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
item
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
item
.
getSessionId
()));
Intent
intent
=
new
Intent
(
context
,
ContextualActivity
.
class
);
intent
.
putExtra
(
"ccms"
,
item
);
context
.
startActivity
(
intent
);
...
...
@@ -747,7 +747,7 @@ public class WarplyManagerHelper {
}
WarpUtils
.
setWebviewParams
(
Warply
.
getWarplyContext
(),
params
);
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
item
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Contextual"
).
concat
(
":"
).
concat
(
item
.
getSessionId
()));
context
.
startActivity
(
WarpViewActivity
.
createIntentFromURL
(
context
,
url
));
break
;
}
...
...
@@ -759,7 +759,7 @@ public class WarplyManagerHelper {
analyticsEvent
.
setParameter
(
"type"
,
"gift"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Telco"
).
concat
(
":"
).
concat
(
item
.
getSessionId
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Telco"
).
concat
(
":"
).
concat
(
item
.
getSessionId
()));
WarplyManager
.
getSingleCampaign
(
camp
.
getSessionUUID
());
Intent
intent
=
new
Intent
(
context
,
TelcoActivity
.
class
);
intent
.
putExtra
(
"ccms"
,
item
);
...
...
@@ -803,7 +803,7 @@ public class WarplyManagerHelper {
analyticsEvent
.
setParameter
(
"type"
,
"coupon"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
WarplyManager
.
getSingleCampaign
(
item
.
getSessionUUID
());
Intent
intent
=
new
Intent
(
context
,
CouponsetInfoActivity
.
class
);
intent
.
putExtra
(
"couponset"
,
(
Serializable
)
cpns
);
...
...
@@ -814,7 +814,7 @@ public class WarplyManagerHelper {
}
}
}
else
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
context
.
startActivity
(
WarpViewActivity
.
createIntentFromURL
(
context
,
WarplyManagerHelper
.
constructCampaignUrl
(
item
)));
}
}
...
...
@@ -839,7 +839,7 @@ public class WarplyManagerHelper {
analyticsEvent
.
setParameter
(
"type"
,
"coupon"
);
EventBus
.
getDefault
().
post
(
new
WarplyEventBusManager
(
analyticsEvent
));
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
WarplyManager
.
getSingleCampaign
(
item
.
getSessionUUID
());
Intent
intent
=
new
Intent
(
context
,
CouponsetInfoActivity
.
class
);
intent
.
putExtra
(
"couponset"
,
(
Serializable
)
cpns
);
...
...
@@ -849,7 +849,7 @@ public class WarplyManagerHelper {
}
}
}
else
{
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
context
.
startActivity
(
WarpViewActivity
.
createIntentFromURL
(
context
,
WarplyManagerHelper
.
constructCampaignUrl
(
item
)));
}
}
...
...
@@ -860,7 +860,7 @@ public class WarplyManagerHelper {
return
;
}
WarplyAnalyticsManager
.
logTrackersEvent
(
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
WarplyAnalyticsManager
.
logTrackersEvent
(
context
,
"click"
,
(
"Loyalty"
).
concat
(
":"
).
concat
(
item
.
getSessionUUID
()));
context
.
startActivity
(
WarpViewActivity
.
createIntentFromURL
(
context
,
WarplyManagerHelper
.
constructCampaignUrl
(
item
)));
}
}
...
...
warply_android_sdk/src/main/java/ly/warp/sdk/utils/managers/WarplyAnalyticsManager.java
View file @
66869a0
...
...
@@ -57,8 +57,8 @@ public class WarplyAnalyticsManager {
sendEvent
(
eventPage
,
eventId
,
metadata
,
false
);
}
public
static
void
logTrackersEvent
(
String
eventType
,
String
eventName
)
{
if
(
WarpUtils
.
getTrackersEnabled
(
Warply
.
getWarplyContext
()
))
public
static
void
logTrackersEvent
(
Context
context
,
String
eventType
,
String
eventName
)
{
if
(
WarpUtils
.
getTrackersEnabled
(
context
))
sendEvent
(
null
,
eventType
.
concat
(
":"
).
concat
(
eventName
),
null
,
false
);
}
...
...
Please
register
or
login
to post a comment