Skip to content

Commit

Permalink
checkpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
namidan committed Oct 14, 2022
1 parent b14df94 commit 1c0991e
Show file tree
Hide file tree
Showing 8 changed files with 133 additions and 129 deletions.
2 changes: 1 addition & 1 deletion sdk/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version '3.0.0-alpha.01'

buildscript {
ext.kotlin_version = '1.5.31'
ext.nami_sdk_version = '3.0.0-alpha.07'
ext.nami_sdk_version = '3.0.0-alpha.08'
repositories {
mavenCentral()
google()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,9 @@ class FlutterNamiSdkPlugin : FlutterPlugin, MethodCallHandler, ActivityAware {
"loggedInId" -> {
result.success(NamiCustomerManager.loggedInId())
}
"isLoggedIn" -> {
result.success(NamiCustomerManager.isLoggedIn())
}
"launch" -> {
val callback = { launchResult: LaunchCampaignResult ->
when (launchResult) {
Expand Down Expand Up @@ -271,6 +274,9 @@ class FlutterNamiSdkPlugin : FlutterPlugin, MethodCallHandler, ActivityAware {
)
}
}
"dismiss" -> {
result.notImplemented()
}
"journeyState" -> {
val stateMap = NamiCustomerManager.journeyState()?.convertToMap()
result.success(stateMap)
Expand Down Expand Up @@ -327,15 +333,6 @@ class FlutterNamiSdkPlugin : FlutterPlugin, MethodCallHandler, ActivityAware {
result.success(NamiPurchaseManager.anySKUIDPurchased(it))
}
}
"buySKU" -> {
val skuRefId = call.arguments as? String
val activity = currentActivityWeakReference?.get()
if (skuRefId != null && activity != null) {
NamiPurchaseManager.buySKU(activity, skuRefId) {
result.success(it.convertToMap())
}
}
}
"consumePurchasedSKU" -> {
val skuRefId = call.arguments as? String
if (skuRefId != null) {
Expand Down
16 changes: 8 additions & 8 deletions sdk/example/ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
PODS:
- Flutter (1.0.0)
- Nami (2.9.3)
- nami_flutter (1.0.0):
- Nami (3.0.0-rc.03)
- nami_flutter (3.0.0-alpha.01):
- Flutter
- Nami (= 2.9.3)
- Nami (= 3.0.0-rc.03)

DEPENDENCIES:
- Flutter (from `Flutter`)
Expand All @@ -20,10 +20,10 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/nami_flutter/ios"

SPEC CHECKSUMS:
Flutter: 50d75fe2f02b26cc09d224853bb45737f8b3214a
Nami: 65926f3a18c836faffcc7eb1ed103ff076bbb7cc
nami_flutter: dc2fb5802766b013161b434dd480913c63229abc
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
Nami: 2668736ea8003575ce29ea9afa328b65c5a31674
nami_flutter: 8072cba2622342f446726f483628b8f5e5576926

PODFILE CHECKSUM: aafe91acc616949ddb318b77800a7f51bffa2a4c
PODFILE CHECKSUM: ef19549a9bc3046e7bb7d2fab4d021637c0c58a3

COCOAPODS: 1.10.1
COCOAPODS: 1.11.3
6 changes: 6 additions & 0 deletions sdk/example/ios/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -358,12 +358,14 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = K6APTMK8Y8;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
);
INFOPLIST_FILE = Runner/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down Expand Up @@ -496,12 +498,14 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = K6APTMK8Y8;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
);
INFOPLIST_FILE = Runner/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand All @@ -526,12 +530,14 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
DEVELOPMENT_TEAM = K6APTMK8Y8;
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
);
INFOPLIST_FILE = Runner/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
Expand Down
7 changes: 4 additions & 3 deletions sdk/example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,12 @@ class MyApp extends StatefulWidget {

class _MyAppState extends State<MyApp> with WidgetsBindingObserver {
static const _testExternalIdentifier = "9a9999a9-99aa-99a9-aa99-999a999999a8";
// TODO: uncomment release
// prod
// static const _androidAppPlatformId = "3d062066-9d3c-430e-935d-855e2c56dd8e";
// TODO: delete this before release
// static const _iosAppPlatformId = "002e2c49-7f66-4d22-a05c-1dc9f2b7f2af";
// nami staging
static const _androidAppPlatformId = "aaf69dba-ef67-40f5-82ec-c7623a2848a6";
static const _iosAppPlatformId = "002e2c49-7f66-4d22-a05c-1dc9f2b7f2af";
static const _iosAppPlatformId = "1b3f8f1f-c471-448e-b5c1-23059ee65bac";

@override
Widget build(BuildContext context) {
Expand Down
Loading

0 comments on commit 1c0991e

Please sign in to comment.