iamport-react-native 2.0.15 → 3.0.1-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/README.md +12 -2
- package/lib/module/components/Certification/index.js +75 -72
- package/lib/module/components/Certification/index.js.map +1 -1
- package/lib/module/components/ErrorOnParams/index.js +13 -9
- package/lib/module/components/ErrorOnParams/index.js.map +1 -1
- package/lib/module/components/Loading/index.js +13 -9
- package/lib/module/components/Loading/index.js.map +1 -1
- package/lib/module/components/Payment/index.js +111 -93
- package/lib/module/components/Payment/index.js.map +1 -1
- package/lib/module/constants/index.js +2 -0
- package/lib/module/constants/index.js.map +1 -1
- package/lib/module/index.js +6 -4
- package/lib/module/index.js.map +1 -1
- package/lib/module/package.json +1 -0
- package/lib/module/styles.js +2 -0
- package/lib/module/styles.js.map +1 -1
- package/lib/module/utils/IamportUrl.js +51 -29
- package/lib/module/utils/IamportUrl.js.map +1 -1
- package/lib/module/utils/Validation.js +3 -2
- package/lib/module/utils/Validation.js.map +1 -1
- package/lib/module/utils/ValidationForPayment.js +4 -2
- package/lib/module/utils/ValidationForPayment.js.map +1 -1
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/{components → src/components}/Certification/index.d.ts +1 -2
- package/lib/typescript/src/components/Certification/index.d.ts.map +1 -0
- package/lib/typescript/src/components/ErrorOnParams/index.d.ts +6 -0
- package/lib/typescript/src/components/ErrorOnParams/index.d.ts.map +1 -0
- package/lib/typescript/src/components/Loading/index.d.ts +3 -0
- package/lib/typescript/src/components/Loading/index.d.ts.map +1 -0
- package/lib/typescript/{components → src/components}/Payment/index.d.ts +1 -2
- package/lib/typescript/src/components/Payment/index.d.ts.map +1 -0
- package/lib/typescript/src/constants/index.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/{styles.d.ts → src/styles.d.ts} +2 -2
- package/lib/typescript/src/styles.d.ts.map +1 -0
- package/lib/typescript/{utils → src/utils}/IamportUrl.d.ts +8 -7
- package/lib/typescript/src/utils/IamportUrl.d.ts.map +1 -0
- package/lib/typescript/src/utils/Validation.d.ts.map +1 -0
- package/lib/typescript/src/utils/ValidationForPayment.d.ts.map +1 -0
- package/package.json +81 -74
- package/src/components/Certification/index.tsx +7 -7
- package/src/components/ErrorOnParams/index.tsx +1 -2
- package/src/components/Loading/index.tsx +1 -2
- package/src/components/Payment/index.tsx +31 -7
- package/src/utils/IamportUrl.ts +54 -26
- package/.circleci/config.yml +0 -98
- package/.editorconfig +0 -15
- package/.gitattributes +0 -3
- package/.gitignore +0 -69
- package/.yarnrc +0 -3
- package/.yarnrc.yml +0 -1
- package/android/.gradle/8.9/checksums/checksums.lock +0 -0
- package/android/.gradle/8.9/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/8.9/checksums/sha1-checksums.bin +0 -0
- package/android/.gradle/8.9/dependencies-accessors/gc.properties +0 -0
- package/android/.gradle/8.9/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/8.9/fileChanges/last-build.bin +0 -0
- package/android/.gradle/8.9/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/8.9/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +0 -2
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/build.gradle +0 -128
- package/android/gradle.properties +0 -4
- package/android/src/main/AndroidManifest.xml +0 -4
- package/android/src/main/java/com/iamportreactnative/IamportReactNativePackage.kt +0 -17
- package/android/src/main/java/com/iamportreactnative/IamportReactNativeViewManager.kt +0 -20
- package/babel.config.js +0 -3
- package/example/.gitignore +0 -69
- package/example/README.md +0 -44
- package/example/android/.gradle/7.5.1/checksums/checksums.lock +0 -0
- package/example/android/.gradle/7.5.1/checksums/md5-checksums.bin +0 -0
- package/example/android/.gradle/7.5.1/checksums/sha1-checksums.bin +0 -0
- package/example/android/.gradle/7.5.1/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/example/android/.gradle/7.5.1/dependencies-accessors/gc.properties +0 -0
- package/example/android/.gradle/7.5.1/executionHistory/executionHistory.lock +0 -0
- package/example/android/.gradle/7.5.1/fileChanges/last-build.bin +0 -0
- package/example/android/.gradle/7.5.1/fileHashes/fileHashes.bin +0 -0
- package/example/android/.gradle/7.5.1/fileHashes/fileHashes.lock +0 -0
- package/example/android/.gradle/7.5.1/gc.properties +0 -0
- package/example/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/example/android/.gradle/buildOutputCleanup/cache.properties +0 -2
- package/example/android/.gradle/vcs-1/gc.properties +0 -0
- package/example/android/app/build.gradle +0 -183
- package/example/android/app/debug.keystore +0 -0
- package/example/android/app/proguard-rules.pro +0 -10
- package/example/android/app/src/debug/AndroidManifest.xml +0 -8
- package/example/android/app/src/debug/java/com/example/iamportreactnative/ReactNativeFlipper.java +0 -69
- package/example/android/app/src/main/AndroidManifest.xml +0 -34
- package/example/android/app/src/main/java/com/example/iamportreactnative/MainActivity.java +0 -15
- package/example/android/app/src/main/java/com/example/iamportreactnative/MainApplication.java +0 -80
- package/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
- package/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
- package/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
- package/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
- package/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
- package/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
- package/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
- package/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
- package/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
- package/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
- package/example/android/app/src/main/res/values/strings.xml +0 -3
- package/example/android/app/src/main/res/values/styles.xml +0 -9
- package/example/android/build.gradle +0 -21
- package/example/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/example/android/gradle/wrapper/gradle-wrapper.properties +0 -6
- package/example/android/gradle.properties +0 -44
- package/example/android/gradlew +0 -183
- package/example/android/gradlew.bat +0 -103
- package/example/android/settings.gradle +0 -9
- package/example/app.json +0 -4
- package/example/babel.config.js +0 -11
- package/example/index.js +0 -5
- package/example/ios/File.swift +0 -8
- package/example/ios/Gemfile +0 -7
- package/example/ios/Gemfile.lock +0 -99
- package/example/ios/IamportReactNativeExample/AppDelegate.h +0 -15
- package/example/ios/IamportReactNativeExample/AppDelegate.mm +0 -138
- package/example/ios/IamportReactNativeExample/Images.xcassets/AppIcon.appiconset/Contents.json +0 -53
- package/example/ios/IamportReactNativeExample/Images.xcassets/Contents.json +0 -6
- package/example/ios/IamportReactNativeExample/Info.plist +0 -121
- package/example/ios/IamportReactNativeExample/LaunchScreen.storyboard +0 -58
- package/example/ios/IamportReactNativeExample/main.m +0 -16
- package/example/ios/IamportReactNativeExample-Bridging-Header.h +0 -3
- package/example/ios/IamportReactNativeExample.xcodeproj/project.pbxproj +0 -969
- package/example/ios/IamportReactNativeExample.xcodeproj/xcshareddata/xcschemes/IamportReactNativeExample.xcscheme +0 -99
- package/example/ios/IamportReactNativeExample.xcworkspace/contents.xcworkspacedata +0 -10
- package/example/ios/IamportReactNativeExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +0 -8
- package/example/ios/Podfile +0 -57
- package/example/ios/Podfile.lock +0 -756
- package/example/metro.config.js +0 -66
- package/example/package.json +0 -40
- package/example/src/App.tsx +0 -17
- package/example/src/Certification/index.tsx +0 -30
- package/example/src/CertificationResult/index.tsx +0 -79
- package/example/src/CertificationTest/index.tsx +0 -214
- package/example/src/Home/index.tsx +0 -87
- package/example/src/Loading/index.tsx +0 -12
- package/example/src/NavigationService.tsx +0 -127
- package/example/src/Payment/index.tsx +0 -28
- package/example/src/PaymentResult/index.tsx +0 -96
- package/example/src/PaymentTest/index.tsx +0 -383
- package/example/src/Picker/index.tsx +0 -60
- package/example/src/constants.ts +0 -274
- package/example/src/utils.ts +0 -83
- package/example/yarn.lock +0 -7358
- package/exampleForExpo/.buckconfig +0 -6
- package/exampleForExpo/.expo/README.md +0 -8
- package/exampleForExpo/.expo/devices.json +0 -3
- package/exampleForExpo/.gitattributes +0 -1
- package/exampleForExpo/.gitignore +0 -125
- package/exampleForExpo/.idea/.gitignore +0 -3
- package/exampleForExpo/.idea/caches/deviceStreaming.xml +0 -549
- package/exampleForExpo/.idea/exampleForExpo.iml +0 -9
- package/exampleForExpo/.idea/misc.xml +0 -6
- package/exampleForExpo/.idea/modules.xml +0 -8
- package/exampleForExpo/.idea/vcs.xml +0 -6
- package/exampleForExpo/.idea/workspace.xml +0 -53
- package/exampleForExpo/README.md +0 -58
- package/exampleForExpo/__tests__/App.js +0 -10
- package/exampleForExpo/android/.gitignore +0 -21
- package/exampleForExpo/android/.gradle/7.5.1/checksums/checksums.lock +0 -0
- package/exampleForExpo/android/.gradle/7.5.1/fileChanges/last-build.bin +0 -0
- package/exampleForExpo/android/.gradle/7.5.1/fileHashes/fileHashes.lock +0 -0
- package/exampleForExpo/android/.gradle/7.5.1/gc.properties +0 -0
- package/exampleForExpo/android/.gradle/vcs-1/gc.properties +0 -0
- package/exampleForExpo/android/app/BUCK +0 -55
- package/exampleForExpo/android/app/build.gradle +0 -362
- package/exampleForExpo/android/app/build_defs.bzl +0 -19
- package/exampleForExpo/android/app/debug.keystore +0 -0
- package/exampleForExpo/android/app/proguard-rules.pro +0 -14
- package/exampleForExpo/android/app/src/debug/AndroidManifest.xml +0 -7
- package/exampleForExpo/android/app/src/debug/java/kr/iamport/exampleForExpo/ReactNativeFlipper.java +0 -69
- package/exampleForExpo/android/app/src/main/AndroidManifest.xml +0 -34
- package/exampleForExpo/android/app/src/main/java/kr/iamport/exampleForExpo/MainActivity.java +0 -83
- package/exampleForExpo/android/app/src/main/java/kr/iamport/exampleForExpo/MainApplication.java +0 -106
- package/exampleForExpo/android/app/src/main/java/kr/iamport/exampleForExpo/newarchitecture/MainApplicationReactNativeHost.java +0 -117
- package/exampleForExpo/android/app/src/main/java/kr/iamport/exampleForExpo/newarchitecture/components/MainComponentsRegistry.java +0 -36
- package/exampleForExpo/android/app/src/main/java/kr/iamport/exampleForExpo/newarchitecture/modules/MainApplicationTurboModuleManagerDelegate.java +0 -48
- package/exampleForExpo/android/app/src/main/jni/CMakeLists.txt +0 -7
- package/exampleForExpo/android/app/src/main/jni/MainApplicationModuleProvider.cpp +0 -32
- package/exampleForExpo/android/app/src/main/jni/MainApplicationModuleProvider.h +0 -16
- package/exampleForExpo/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.cpp +0 -45
- package/exampleForExpo/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.h +0 -38
- package/exampleForExpo/android/app/src/main/jni/MainComponentsRegistry.cpp +0 -65
- package/exampleForExpo/android/app/src/main/jni/MainComponentsRegistry.h +0 -32
- package/exampleForExpo/android/app/src/main/jni/OnLoad.cpp +0 -11
- package/exampleForExpo/android/app/src/main/res/drawable/rn_edit_text_material.xml +0 -36
- package/exampleForExpo/android/app/src/main/res/drawable/splashscreen.xml +0 -4
- package/exampleForExpo/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
- package/exampleForExpo/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
- package/exampleForExpo/android/app/src/main/res/values/colors.xml +0 -4
- package/exampleForExpo/android/app/src/main/res/values/strings.xml +0 -3
- package/exampleForExpo/android/app/src/main/res/values/styles.xml +0 -17
- package/exampleForExpo/android/app/src/main/res/values-night/colors.xml +0 -1
- package/exampleForExpo/android/build.gradle +0 -65
- package/exampleForExpo/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/exampleForExpo/android/gradle/wrapper/gradle-wrapper.properties +0 -5
- package/exampleForExpo/android/gradle.properties +0 -53
- package/exampleForExpo/android/gradlew +0 -240
- package/exampleForExpo/android/gradlew.bat +0 -91
- package/exampleForExpo/android/settings.gradle +0 -17
- package/exampleForExpo/app.json +0 -16
- package/exampleForExpo/babel.config.js +0 -11
- package/exampleForExpo/index.js +0 -9
- package/exampleForExpo/ios/.gitignore +0 -30
- package/exampleForExpo/ios/.xcode.env +0 -11
- package/exampleForExpo/ios/Podfile +0 -61
- package/exampleForExpo/ios/Podfile.lock +0 -734
- package/exampleForExpo/ios/Podfile.properties.json +0 -3
- package/exampleForExpo/ios/exampleForExpo/AppDelegate.h +0 -9
- package/exampleForExpo/ios/exampleForExpo/AppDelegate.mm +0 -166
- package/exampleForExpo/ios/exampleForExpo/Images.xcassets/AppIcon.appiconset/Contents.json +0 -38
- package/exampleForExpo/ios/exampleForExpo/Images.xcassets/Contents.json +0 -6
- package/exampleForExpo/ios/exampleForExpo/Images.xcassets/SplashScreenBackground.imageset/Contents.json +0 -21
- package/exampleForExpo/ios/exampleForExpo/Images.xcassets/SplashScreenBackground.imageset/image.png +0 -0
- package/exampleForExpo/ios/exampleForExpo/Info.plist +0 -118
- package/exampleForExpo/ios/exampleForExpo/SplashScreen.storyboard +0 -43
- package/exampleForExpo/ios/exampleForExpo/Supporting/Expo.plist +0 -16
- package/exampleForExpo/ios/exampleForExpo/exampleForExpo.entitlements +0 -8
- package/exampleForExpo/ios/exampleForExpo/main.m +0 -10
- package/exampleForExpo/ios/exampleForExpo/noop-file.swift +0 -4
- package/exampleForExpo/ios/exampleForExpo.xcodeproj/project.pbxproj +0 -544
- package/exampleForExpo/ios/exampleForExpo.xcodeproj/xcshareddata/xcschemes/exampleForExpo.xcscheme +0 -88
- package/exampleForExpo/ios/exampleForExpo.xcworkspace/contents.xcworkspacedata +0 -10
- package/exampleForExpo/ios/exampleForExpo.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +0 -8
- package/exampleForExpo/metro.config.js +0 -62
- package/exampleForExpo/package.json +0 -40
- package/exampleForExpo/src/App.js +0 -14
- package/exampleForExpo/src/Certification/index.js +0 -25
- package/exampleForExpo/src/CertificationResult/index.js +0 -61
- package/exampleForExpo/src/CertificationTest/index.js +0 -151
- package/exampleForExpo/src/Home/index.js +0 -80
- package/exampleForExpo/src/Loading/index.js +0 -10
- package/exampleForExpo/src/NavigationService.js +0 -102
- package/exampleForExpo/src/Payment/index.js +0 -23
- package/exampleForExpo/src/PaymentResult/index.js +0 -82
- package/exampleForExpo/src/PaymentTest/index.js +0 -313
- package/exampleForExpo/src/Picker/index.js +0 -19
- package/exampleForExpo/src/constants.js +0 -322
- package/exampleForExpo/src/utils.js +0 -116
- package/exampleForExpo/yarn.lock +0 -9498
- package/exampleForManagedExpo/.expo-shared/assets.json +0 -4
- package/exampleForManagedExpo/.gitignore +0 -22
- package/exampleForManagedExpo/App.js +0 -11
- package/exampleForManagedExpo/README.md +0 -33
- package/exampleForManagedExpo/app.json +0 -90
- package/exampleForManagedExpo/assets/adaptive-icon.png +0 -0
- package/exampleForManagedExpo/assets/favicon.png +0 -0
- package/exampleForManagedExpo/assets/icon.png +0 -0
- package/exampleForManagedExpo/assets/splash.png +0 -0
- package/exampleForManagedExpo/babel.config.js +0 -11
- package/exampleForManagedExpo/metro.config.js +0 -62
- package/exampleForManagedExpo/package.json +0 -36
- package/exampleForManagedExpo/src/Certification/index.js +0 -25
- package/exampleForManagedExpo/src/CertificationResult/index.js +0 -61
- package/exampleForManagedExpo/src/CertificationTest/index.js +0 -151
- package/exampleForManagedExpo/src/Home/index.js +0 -80
- package/exampleForManagedExpo/src/Loading/index.js +0 -10
- package/exampleForManagedExpo/src/NavigationService.js +0 -102
- package/exampleForManagedExpo/src/Payment/index.js +0 -23
- package/exampleForManagedExpo/src/PaymentResult/index.js +0 -82
- package/exampleForManagedExpo/src/PaymentTest/index.js +0 -313
- package/exampleForManagedExpo/src/Picker/index.js +0 -19
- package/exampleForManagedExpo/src/constants.js +0 -322
- package/exampleForManagedExpo/src/utils.js +0 -116
- package/exampleForManagedExpo/yarn.lock +0 -9411
- package/exampleForWebView/.buckconfig +0 -6
- package/exampleForWebView/.eslintrc.js +0 -4
- package/exampleForWebView/.gitattributes +0 -3
- package/exampleForWebView/.gitignore +0 -68
- package/exampleForWebView/.prettierrc.js +0 -7
- package/exampleForWebView/.watchmanconfig +0 -1
- package/exampleForWebView/README.md +0 -77
- package/exampleForWebView/__tests__/App-test.tsx +0 -14
- package/exampleForWebView/_editorconfig +0 -3
- package/exampleForWebView/android/.gradle/7.5.1/checksums/checksums.lock +0 -0
- package/exampleForWebView/android/.gradle/7.5.1/fileChanges/last-build.bin +0 -0
- package/exampleForWebView/android/.gradle/7.5.1/fileHashes/fileHashes.lock +0 -0
- package/exampleForWebView/android/.gradle/7.5.1/gc.properties +0 -0
- package/exampleForWebView/android/.gradle/vcs-1/gc.properties +0 -0
- package/exampleForWebView/android/app/BUCK +0 -55
- package/exampleForWebView/android/app/build.gradle +0 -313
- package/exampleForWebView/android/app/build_defs.bzl +0 -19
- package/exampleForWebView/android/app/debug.keystore +0 -0
- package/exampleForWebView/android/app/proguard-rules.pro +0 -10
- package/exampleForWebView/android/app/src/debug/AndroidManifest.xml +0 -13
- package/exampleForWebView/android/app/src/debug/java/com/exampleforwebview/ReactNativeFlipper.java +0 -73
- package/exampleForWebView/android/app/src/main/AndroidManifest.xml +0 -26
- package/exampleForWebView/android/app/src/main/java/com/exampleforwebview/MainActivity.java +0 -48
- package/exampleForWebView/android/app/src/main/java/com/exampleforwebview/MainApplication.java +0 -91
- package/exampleForWebView/android/app/src/main/java/com/exampleforwebview/newarchitecture/MainApplicationReactNativeHost.java +0 -116
- package/exampleForWebView/android/app/src/main/java/com/exampleforwebview/newarchitecture/components/MainComponentsRegistry.java +0 -36
- package/exampleForWebView/android/app/src/main/java/com/exampleforwebview/newarchitecture/modules/MainApplicationTurboModuleManagerDelegate.java +0 -48
- package/exampleForWebView/android/app/src/main/jni/CMakeLists.txt +0 -7
- package/exampleForWebView/android/app/src/main/jni/MainApplicationModuleProvider.cpp +0 -32
- package/exampleForWebView/android/app/src/main/jni/MainApplicationModuleProvider.h +0 -16
- package/exampleForWebView/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.cpp +0 -45
- package/exampleForWebView/android/app/src/main/jni/MainApplicationTurboModuleManagerDelegate.h +0 -38
- package/exampleForWebView/android/app/src/main/jni/MainComponentsRegistry.cpp +0 -65
- package/exampleForWebView/android/app/src/main/jni/MainComponentsRegistry.h +0 -32
- package/exampleForWebView/android/app/src/main/jni/OnLoad.cpp +0 -11
- package/exampleForWebView/android/app/src/main/res/drawable/rn_edit_text_material.xml +0 -36
- package/exampleForWebView/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
- package/exampleForWebView/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
- package/exampleForWebView/android/app/src/main/res/values/strings.xml +0 -3
- package/exampleForWebView/android/app/src/main/res/values/styles.xml +0 -9
- package/exampleForWebView/android/build.gradle +0 -51
- package/exampleForWebView/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/exampleForWebView/android/gradle/wrapper/gradle-wrapper.properties +0 -5
- package/exampleForWebView/android/gradle.properties +0 -40
- package/exampleForWebView/android/gradlew +0 -234
- package/exampleForWebView/android/gradlew.bat +0 -89
- package/exampleForWebView/android/settings.gradle +0 -11
- package/exampleForWebView/app.json +0 -4
- package/exampleForWebView/babel.config.js +0 -11
- package/exampleForWebView/index.js +0 -9
- package/exampleForWebView/ios/.xcode.env +0 -11
- package/exampleForWebView/ios/Podfile +0 -43
- package/exampleForWebView/ios/Podfile.lock +0 -748
- package/exampleForWebView/ios/exampleForWebView/AppDelegate.h +0 -8
- package/exampleForWebView/ios/exampleForWebView/AppDelegate.mm +0 -133
- package/exampleForWebView/ios/exampleForWebView/Images.xcassets/AppIcon.appiconset/Contents.json +0 -53
- package/exampleForWebView/ios/exampleForWebView/Images.xcassets/Contents.json +0 -6
- package/exampleForWebView/ios/exampleForWebView/Info.plist +0 -96
- package/exampleForWebView/ios/exampleForWebView/LaunchScreen.storyboard +0 -47
- package/exampleForWebView/ios/exampleForWebView/main.m +0 -10
- package/exampleForWebView/ios/exampleForWebView.xcodeproj/project.pbxproj +0 -723
- package/exampleForWebView/ios/exampleForWebView.xcodeproj/xcshareddata/xcschemes/exampleForWebView.xcscheme +0 -88
- package/exampleForWebView/ios/exampleForWebView.xcworkspace/contents.xcworkspacedata +0 -10
- package/exampleForWebView/ios/exampleForWebView.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +0 -8
- package/exampleForWebView/ios/exampleForWebViewTests/Info.plist +0 -24
- package/exampleForWebView/ios/exampleForWebViewTests/exampleForWebViewTests.m +0 -66
- package/exampleForWebView/manuals/CERTIFICATION.md +0 -223
- package/exampleForWebView/manuals/PAYMENT.md +0 -232
- package/exampleForWebView/metro.config.js +0 -61
- package/exampleForWebView/package.json +0 -54
- package/exampleForWebView/src/App.tsx +0 -50
- package/exampleForWebView/src/Certification.tsx +0 -54
- package/exampleForWebView/src/Home.tsx +0 -49
- package/exampleForWebView/src/Loading.tsx +0 -23
- package/exampleForWebView/src/Payment.tsx +0 -65
- package/exampleForWebView/yarn.lock +0 -7362
- package/iamport-react-native.podspec +0 -19
- package/ios/IamportReactNative-Bridging-Header.h +0 -1
- package/ios/IamportReactNative.xcodeproj/project.pbxproj +0 -293
- package/ios/IamportReactNativeViewManager.m +0 -12
- package/ios/IamportReactNativeViewManager.swift +0 -32
- package/lib/commonjs/components/Certification/index.js +0 -121
- package/lib/commonjs/components/Certification/index.js.map +0 -1
- package/lib/commonjs/components/ErrorOnParams/index.js +0 -50
- package/lib/commonjs/components/ErrorOnParams/index.js.map +0 -1
- package/lib/commonjs/components/Loading/index.js +0 -34
- package/lib/commonjs/components/Loading/index.js.map +0 -1
- package/lib/commonjs/components/Payment/index.js +0 -225
- package/lib/commonjs/components/Payment/index.js.map +0 -1
- package/lib/commonjs/constants/index.js +0 -114
- package/lib/commonjs/constants/index.js.map +0 -1
- package/lib/commonjs/img/iamport-logo.png +0 -0
- package/lib/commonjs/index.js +0 -29
- package/lib/commonjs/index.js.map +0 -1
- package/lib/commonjs/styles.js +0 -27
- package/lib/commonjs/styles.js.map +0 -1
- package/lib/commonjs/utils/IamportUrl.js +0 -289
- package/lib/commonjs/utils/IamportUrl.js.map +0 -1
- package/lib/commonjs/utils/Validation.js +0 -109
- package/lib/commonjs/utils/Validation.js.map +0 -1
- package/lib/commonjs/utils/ValidationForPayment.js +0 -112
- package/lib/commonjs/utils/ValidationForPayment.js.map +0 -1
- package/lib/typescript/components/Certification/index.d.ts.map +0 -1
- package/lib/typescript/components/ErrorOnParams/index.d.ts +0 -7
- package/lib/typescript/components/ErrorOnParams/index.d.ts.map +0 -1
- package/lib/typescript/components/Loading/index.d.ts +0 -4
- package/lib/typescript/components/Loading/index.d.ts.map +0 -1
- package/lib/typescript/components/Payment/index.d.ts.map +0 -1
- package/lib/typescript/constants/index.d.ts.map +0 -1
- package/lib/typescript/index.d.ts.map +0 -1
- package/lib/typescript/styles.d.ts.map +0 -1
- package/lib/typescript/utils/IamportUrl.d.ts.map +0 -1
- package/lib/typescript/utils/Validation.d.ts.map +0 -1
- package/lib/typescript/utils/ValidationForPayment.d.ts.map +0 -1
- package/manuals/CALLBACK.md +0 -72
- package/manuals/EXAMPLE.md +0 -168
- package/manuals/EXPO.md +0 -246
- package/manuals/INSTALL.md +0 -31
- package/manuals/SETTING.md +0 -140
- package/manuals/SUPPORT.md +0 -35
- package/manuals/TRANS.md +0 -77
- package/manuals/VERSION.md +0 -187
- package/manuals/assets/after-linking-iamport.png +0 -0
- package/manuals/assets/after-linking-webview.png +0 -0
- package/manuals/assets/allow-arbitrary.gif +0 -0
- package/manuals/assets/android-studio-avd-manager.png +0 -0
- package/manuals/assets/android-studio-build.png +0 -0
- package/manuals/assets/app-scheme-registry.gif +0 -0
- package/manuals/assets/expo-eject.png +0 -0
- package/manuals/assets/ios-emulator-certification.png +0 -0
- package/manuals/assets/ios-emulator-home.png +0 -0
- package/manuals/assets/ios-emulator-payment.png +0 -0
- package/manuals/assets/ios-trans-create-header-file-1.png +0 -0
- package/manuals/assets/ios-trans-create-header-file-2.png +0 -0
- package/manuals/assets/ios-trans-create-objectivec-file-1.png +0 -0
- package/manuals/assets/ios-trans-create-objectivec-file-2.png +0 -0
- package/manuals/assets/ios-trans-result.png +0 -0
- package/manuals/assets/webview-peer-dependency.png +0 -0
- package/scripts/bootstrap.js +0 -24
- package/tsconfig.build.json +0 -9
- package/tsconfig.json +0 -26
- package/yarn.lock +0 -6174
- /package/lib/typescript/{constants → src/constants}/index.d.ts +0 -0
- /package/lib/typescript/{index.d.ts → src/index.d.ts} +0 -0
- /package/lib/typescript/{utils → src/utils}/Validation.d.ts +0 -0
- /package/lib/typescript/{utils → src/utils}/ValidationForPayment.d.ts +0 -0
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { NavigationContainer } from '@react-navigation/native';
|
|
3
|
-
import { createStackNavigator } from '@react-navigation/stack';
|
|
4
|
-
import Home from './Home';
|
|
5
|
-
import Certification from './Certification';
|
|
6
|
-
import CertificationTest from './CertificationTest';
|
|
7
|
-
import CertificationResult from './CertificationResult';
|
|
8
|
-
import Payment from './Payment';
|
|
9
|
-
import PaymentTest from './PaymentTest';
|
|
10
|
-
import PaymentResult from './PaymentResult';
|
|
11
|
-
|
|
12
|
-
const RootStack = createStackNavigator();
|
|
13
|
-
|
|
14
|
-
export default function IamportNavigation() {
|
|
15
|
-
return (
|
|
16
|
-
<NavigationContainer>
|
|
17
|
-
<RootStack.Navigator
|
|
18
|
-
initialRouteName="Home"
|
|
19
|
-
// screenOptions={{ headerShown: false }}
|
|
20
|
-
>
|
|
21
|
-
<RootStack.Screen
|
|
22
|
-
options={{ headerShown: false }}
|
|
23
|
-
name="Home"
|
|
24
|
-
component={Home}
|
|
25
|
-
/>
|
|
26
|
-
<RootStack.Screen
|
|
27
|
-
options={{ headerShown: false }}
|
|
28
|
-
name="Certification"
|
|
29
|
-
component={Certification}
|
|
30
|
-
/>
|
|
31
|
-
<RootStack.Screen
|
|
32
|
-
options={{
|
|
33
|
-
headerTitle: '아임포트 본인인증 테스트',
|
|
34
|
-
headerTitleAlign: 'center',
|
|
35
|
-
headerStyle: {
|
|
36
|
-
backgroundColor: '#344e81',
|
|
37
|
-
},
|
|
38
|
-
headerTitleStyle: {
|
|
39
|
-
color: '#fff',
|
|
40
|
-
},
|
|
41
|
-
headerTintColor: '#fff',
|
|
42
|
-
headerBackTitle: ' ',
|
|
43
|
-
}}
|
|
44
|
-
name="CertificationTest"
|
|
45
|
-
component={CertificationTest}
|
|
46
|
-
/>
|
|
47
|
-
<RootStack.Screen
|
|
48
|
-
options={{
|
|
49
|
-
headerTitle: '아임포트 본인인증 결과',
|
|
50
|
-
headerTitleAlign: 'center',
|
|
51
|
-
headerStyle: {
|
|
52
|
-
backgroundColor: '#344e81',
|
|
53
|
-
},
|
|
54
|
-
headerTitleStyle: {
|
|
55
|
-
color: '#fff',
|
|
56
|
-
},
|
|
57
|
-
headerLeft: () => null,
|
|
58
|
-
}}
|
|
59
|
-
name="CertificationResult"
|
|
60
|
-
component={CertificationResult}
|
|
61
|
-
/>
|
|
62
|
-
<RootStack.Screen
|
|
63
|
-
options={{ headerShown: false }}
|
|
64
|
-
name="Payment"
|
|
65
|
-
component={Payment}
|
|
66
|
-
/>
|
|
67
|
-
<RootStack.Screen
|
|
68
|
-
options={{
|
|
69
|
-
headerTitle: '아임포트 결제 테스트',
|
|
70
|
-
headerTitleAlign: 'center',
|
|
71
|
-
headerStyle: {
|
|
72
|
-
backgroundColor: '#344e81',
|
|
73
|
-
},
|
|
74
|
-
headerTitleStyle: {
|
|
75
|
-
color: '#fff',
|
|
76
|
-
},
|
|
77
|
-
headerTintColor: '#fff',
|
|
78
|
-
headerBackTitle: ' ',
|
|
79
|
-
}}
|
|
80
|
-
name="PaymentTest"
|
|
81
|
-
component={PaymentTest}
|
|
82
|
-
/>
|
|
83
|
-
<RootStack.Screen
|
|
84
|
-
options={{
|
|
85
|
-
headerTitle: '아임포트 결제 결과',
|
|
86
|
-
headerTitleAlign: 'center',
|
|
87
|
-
headerStyle: {
|
|
88
|
-
backgroundColor: '#344e81',
|
|
89
|
-
},
|
|
90
|
-
headerTitleStyle: {
|
|
91
|
-
color: '#fff',
|
|
92
|
-
},
|
|
93
|
-
headerTintColor: '#fff',
|
|
94
|
-
headerLeft: () => null,
|
|
95
|
-
}}
|
|
96
|
-
name="PaymentResult"
|
|
97
|
-
component={PaymentResult}
|
|
98
|
-
/>
|
|
99
|
-
</RootStack.Navigator>
|
|
100
|
-
</NavigationContainer>
|
|
101
|
-
);
|
|
102
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import IMP from 'iamport-react-native';
|
|
3
|
-
import { SafeAreaView } from 'react-native-safe-area-context';
|
|
4
|
-
import { getUserCode } from '../utils';
|
|
5
|
-
import Loading from '../Loading';
|
|
6
|
-
|
|
7
|
-
export default function Payment({ route, navigation }) {
|
|
8
|
-
const params = route.params.params;
|
|
9
|
-
const tierCode = route.params.tierCode;
|
|
10
|
-
const userCode = getUserCode(params.pg, tierCode);
|
|
11
|
-
|
|
12
|
-
return (
|
|
13
|
-
<SafeAreaView style={{ flex: 1, justifyContent: 'center' }}>
|
|
14
|
-
<IMP.Payment
|
|
15
|
-
userCode={userCode}
|
|
16
|
-
tierCode={tierCode}
|
|
17
|
-
loading={<Loading />}
|
|
18
|
-
data={params}
|
|
19
|
-
callback={(response) => navigation.replace('PaymentResult', response)}
|
|
20
|
-
/>
|
|
21
|
-
</SafeAreaView>
|
|
22
|
-
);
|
|
23
|
-
}
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Icon, IconButton, List, Text } from 'native-base';
|
|
3
|
-
import { SafeAreaView } from 'react-native-safe-area-context';
|
|
4
|
-
import { FontAwesome } from '@expo/vector-icons';
|
|
5
|
-
|
|
6
|
-
function getBoolean(value) {
|
|
7
|
-
if (typeof value === 'boolean') return value;
|
|
8
|
-
if (typeof value === 'string') return value === 'true';
|
|
9
|
-
return undefined;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export default function PaymentResult({ route, navigation }) {
|
|
13
|
-
const imp_success = route.params?.imp_success;
|
|
14
|
-
const success = route.params?.success;
|
|
15
|
-
const imp_uid = route.params?.imp_uid;
|
|
16
|
-
const tx_id = route.params?.txId;
|
|
17
|
-
const merchant_uid = route.params?.merchant_uid;
|
|
18
|
-
const payment_id = route.params?.paymentId;
|
|
19
|
-
const error_code = route.params?.error_code;
|
|
20
|
-
const code = route.params?.code;
|
|
21
|
-
const message = route.params?.message;
|
|
22
|
-
const error_msg = route.params?.error_msg;
|
|
23
|
-
|
|
24
|
-
// [WARNING: 이해를 돕기 위한 것일 뿐, imp_success 또는 success 파라미터로 결제 성공 여부를 장담할 수 없습니다.]
|
|
25
|
-
// 아임포트 서버로 결제내역 조회(GET /payments/${imp_uid})를 통해 그 응답(status)에 따라 결제 성공 여부를 판단하세요.
|
|
26
|
-
const isSuccess =
|
|
27
|
-
getBoolean(imp_success) ??
|
|
28
|
-
getBoolean(success) ??
|
|
29
|
-
(error_code == null && code == null);
|
|
30
|
-
|
|
31
|
-
return (
|
|
32
|
-
<SafeAreaView
|
|
33
|
-
style={{
|
|
34
|
-
flex: 1,
|
|
35
|
-
justifyContent: 'center',
|
|
36
|
-
margin: 10,
|
|
37
|
-
backgroundColor: '#fff',
|
|
38
|
-
alignItems: 'center',
|
|
39
|
-
}}
|
|
40
|
-
>
|
|
41
|
-
{isSuccess ? (
|
|
42
|
-
<Icon
|
|
43
|
-
as={FontAwesome}
|
|
44
|
-
name={'check-circle'}
|
|
45
|
-
size={20}
|
|
46
|
-
color={'#52c41a'}
|
|
47
|
-
/>
|
|
48
|
-
) : (
|
|
49
|
-
<Icon as={FontAwesome} name={'warning'} size={20} color={'#f5222d'} />
|
|
50
|
-
)}
|
|
51
|
-
<Text fontSize={25} fontWeight={'bold'} mb={20}>{`결제에 ${
|
|
52
|
-
isSuccess ? '성공' : '실패'
|
|
53
|
-
}하였습니다`}</Text>
|
|
54
|
-
<List width={'90%'} mb={50} borderRadius={3}>
|
|
55
|
-
<List.Item>
|
|
56
|
-
<Text w={'40%'}>아임포트 번호</Text>
|
|
57
|
-
<Text w={'60%'}>{imp_uid ?? tx_id}</Text>
|
|
58
|
-
</List.Item>
|
|
59
|
-
{isSuccess ? (
|
|
60
|
-
<List.Item>
|
|
61
|
-
<Text w={'40%'}>주문번호</Text>
|
|
62
|
-
<Text w={'60%'}>{merchant_uid ?? payment_id}</Text>
|
|
63
|
-
</List.Item>
|
|
64
|
-
) : (
|
|
65
|
-
<List.Item>
|
|
66
|
-
<Text w={'40%'}>에러코드</Text>
|
|
67
|
-
<Text w={'60%'}>{error_code ?? code}</Text>
|
|
68
|
-
<Text w={'40%'}>에러메시지</Text>
|
|
69
|
-
<Text w={'60%'}>{error_msg ?? message}</Text>
|
|
70
|
-
</List.Item>
|
|
71
|
-
)}
|
|
72
|
-
</List>
|
|
73
|
-
<IconButton
|
|
74
|
-
icon={<Icon as={FontAwesome} name={'arrow-left'} size={20} />}
|
|
75
|
-
/* @ts-ignore */
|
|
76
|
-
onPress={() => navigation.navigate('Home')}
|
|
77
|
-
>
|
|
78
|
-
<Text>돌아가기</Text>
|
|
79
|
-
</IconButton>
|
|
80
|
-
</SafeAreaView>
|
|
81
|
-
);
|
|
82
|
-
}
|
|
@@ -1,313 +0,0 @@
|
|
|
1
|
-
import React, { useState } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
Button,
|
|
4
|
-
FormControl,
|
|
5
|
-
Input,
|
|
6
|
-
ScrollView,
|
|
7
|
-
Stack,
|
|
8
|
-
Switch,
|
|
9
|
-
Text,
|
|
10
|
-
} from 'native-base';
|
|
11
|
-
import { SafeAreaView } from 'react-native-safe-area-context';
|
|
12
|
-
import Picker from '../Picker';
|
|
13
|
-
import { PGS, TIER_CODES } from '../constants';
|
|
14
|
-
import { getMethods, getQuotas } from '../utils';
|
|
15
|
-
import { IMPConst } from 'iamport-react-native';
|
|
16
|
-
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
17
|
-
|
|
18
|
-
export default function PaymentTest({ navigation }) {
|
|
19
|
-
const [pg, setPg] = useState('html5_inicis');
|
|
20
|
-
const [tierCode, setTierCode] = useState(undefined);
|
|
21
|
-
const [method, setMethod] = useState('card');
|
|
22
|
-
const [cardQuota, setCardQuota] = useState(0);
|
|
23
|
-
const [merchantUid, setMerchantUid] = useState(`mid_${new Date().getTime()}`);
|
|
24
|
-
const [name, setName] = useState('아임포트 결제데이터분석');
|
|
25
|
-
const [amount, setAmount] = useState('39000');
|
|
26
|
-
const [buyerName, setBuyerName] = useState('홍길동');
|
|
27
|
-
const [buyerTel, setBuyerTel] = useState('01012341234');
|
|
28
|
-
const [buyerEmail, setBuyerEmail] = useState('example@example.com');
|
|
29
|
-
const [vbankDue, setVbankDue] = useState('');
|
|
30
|
-
const [bizNum, setBizNum] = useState('');
|
|
31
|
-
const [escrow, setEscrow] = useState(false);
|
|
32
|
-
const [digital, setDigital] = useState(false);
|
|
33
|
-
const insets = useSafeAreaInsets();
|
|
34
|
-
|
|
35
|
-
return (
|
|
36
|
-
<SafeAreaView
|
|
37
|
-
style={{
|
|
38
|
-
flex: 1,
|
|
39
|
-
justifyContent: 'center',
|
|
40
|
-
backgroundColor: '#f5f5f5',
|
|
41
|
-
paddingTop: -insets.top,
|
|
42
|
-
}}
|
|
43
|
-
>
|
|
44
|
-
<ScrollView m={2} backgroundColor={'#fff'}>
|
|
45
|
-
<FormControl p={'5%'} borderRadius={3}>
|
|
46
|
-
<Stack direction={'row'}>
|
|
47
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
48
|
-
PG사
|
|
49
|
-
</FormControl.Label>
|
|
50
|
-
<Picker
|
|
51
|
-
data={PGS}
|
|
52
|
-
selectedValue={pg}
|
|
53
|
-
onValueChange={(value) => {
|
|
54
|
-
setPg(value);
|
|
55
|
-
const methods = getMethods(value);
|
|
56
|
-
setMethod(methods[0].value);
|
|
57
|
-
}}
|
|
58
|
-
/>
|
|
59
|
-
</Stack>
|
|
60
|
-
<Stack direction={'row'}>
|
|
61
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
62
|
-
티어 코드
|
|
63
|
-
</FormControl.Label>
|
|
64
|
-
<Picker
|
|
65
|
-
data={TIER_CODES}
|
|
66
|
-
selectedValue={tierCode}
|
|
67
|
-
onValueChange={(value) => setTierCode(value)}
|
|
68
|
-
/>
|
|
69
|
-
</Stack>
|
|
70
|
-
<Stack direction={'row'}>
|
|
71
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
72
|
-
결제수단
|
|
73
|
-
</FormControl.Label>
|
|
74
|
-
<Picker
|
|
75
|
-
data={getMethods(pg)}
|
|
76
|
-
selectedValue={method}
|
|
77
|
-
onValueChange={(value) => setMethod(value)}
|
|
78
|
-
/>
|
|
79
|
-
</Stack>
|
|
80
|
-
{method === 'card' && (
|
|
81
|
-
<Stack direction={'row'}>
|
|
82
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
83
|
-
할부개월수
|
|
84
|
-
</FormControl.Label>
|
|
85
|
-
<Picker
|
|
86
|
-
data={getQuotas(pg)}
|
|
87
|
-
selectedValue={cardQuota}
|
|
88
|
-
onValueChange={(value) => setCardQuota(parseInt(value, 10))}
|
|
89
|
-
/>
|
|
90
|
-
</Stack>
|
|
91
|
-
)}
|
|
92
|
-
{method === 'vbank' && (
|
|
93
|
-
<Stack direction={'row'}>
|
|
94
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
95
|
-
입금기한
|
|
96
|
-
</FormControl.Label>
|
|
97
|
-
<Input
|
|
98
|
-
mb={2}
|
|
99
|
-
flex={1}
|
|
100
|
-
value={vbankDue}
|
|
101
|
-
onChangeText={(value) => setVbankDue(value)}
|
|
102
|
-
/>
|
|
103
|
-
</Stack>
|
|
104
|
-
)}
|
|
105
|
-
{method === 'vbank' && pg === 'danal_tpay' && (
|
|
106
|
-
<Stack direction={'row'}>
|
|
107
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
108
|
-
사업자번호
|
|
109
|
-
</FormControl.Label>
|
|
110
|
-
<Input
|
|
111
|
-
mb={2}
|
|
112
|
-
flex={1}
|
|
113
|
-
value={bizNum}
|
|
114
|
-
keyboardType="number-pad"
|
|
115
|
-
returnKeyType={'done'}
|
|
116
|
-
onChangeText={(value) => setBizNum(value)}
|
|
117
|
-
/>
|
|
118
|
-
</Stack>
|
|
119
|
-
)}
|
|
120
|
-
{method === 'phone' && (
|
|
121
|
-
<Stack direction={'row'}>
|
|
122
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
123
|
-
실물컨텐츠
|
|
124
|
-
</FormControl.Label>
|
|
125
|
-
<Switch
|
|
126
|
-
mb={2}
|
|
127
|
-
value={digital}
|
|
128
|
-
onValueChange={(value) => setDigital(value)}
|
|
129
|
-
/>
|
|
130
|
-
</Stack>
|
|
131
|
-
)}
|
|
132
|
-
<Stack direction={'row'}>
|
|
133
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
134
|
-
에스크로
|
|
135
|
-
</FormControl.Label>
|
|
136
|
-
<Switch
|
|
137
|
-
mb={2}
|
|
138
|
-
value={escrow}
|
|
139
|
-
onValueChange={(value) => setEscrow(value)}
|
|
140
|
-
/>
|
|
141
|
-
</Stack>
|
|
142
|
-
<Stack direction={'row'}>
|
|
143
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
144
|
-
주문명
|
|
145
|
-
</FormControl.Label>
|
|
146
|
-
<Input
|
|
147
|
-
mb={2}
|
|
148
|
-
flex={1}
|
|
149
|
-
value={name}
|
|
150
|
-
onChangeText={(value) => setName(value)}
|
|
151
|
-
/>
|
|
152
|
-
</Stack>
|
|
153
|
-
<Stack direction={'row'}>
|
|
154
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
155
|
-
결제금액
|
|
156
|
-
</FormControl.Label>
|
|
157
|
-
<Input
|
|
158
|
-
mb={2}
|
|
159
|
-
flex={1}
|
|
160
|
-
value={amount}
|
|
161
|
-
keyboardType="number-pad"
|
|
162
|
-
returnKeyType={'done'}
|
|
163
|
-
onChangeText={(value) => setAmount(value)}
|
|
164
|
-
/>
|
|
165
|
-
</Stack>
|
|
166
|
-
<Stack direction={'row'}>
|
|
167
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
168
|
-
주문번호
|
|
169
|
-
</FormControl.Label>
|
|
170
|
-
<Input
|
|
171
|
-
mb={2}
|
|
172
|
-
flex={1}
|
|
173
|
-
value={merchantUid}
|
|
174
|
-
onChangeText={(value) => setMerchantUid(value)}
|
|
175
|
-
/>
|
|
176
|
-
</Stack>
|
|
177
|
-
<Stack direction={'row'}>
|
|
178
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
179
|
-
이름
|
|
180
|
-
</FormControl.Label>
|
|
181
|
-
<Input
|
|
182
|
-
mb={2}
|
|
183
|
-
flex={1}
|
|
184
|
-
value={buyerName}
|
|
185
|
-
onChangeText={(value) => setBuyerName(value)}
|
|
186
|
-
/>
|
|
187
|
-
</Stack>
|
|
188
|
-
<Stack direction={'row'}>
|
|
189
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
190
|
-
전화번호
|
|
191
|
-
</FormControl.Label>
|
|
192
|
-
<Input
|
|
193
|
-
mb={2}
|
|
194
|
-
flex={1}
|
|
195
|
-
value={buyerTel}
|
|
196
|
-
keyboardType="number-pad"
|
|
197
|
-
returnKeyType={'done'}
|
|
198
|
-
onChangeText={(value) => setBuyerTel(value)}
|
|
199
|
-
/>
|
|
200
|
-
</Stack>
|
|
201
|
-
<Stack direction={'row'}>
|
|
202
|
-
<FormControl.Label alignItems={'center'} mb={2} w={'18%'}>
|
|
203
|
-
이메일
|
|
204
|
-
</FormControl.Label>
|
|
205
|
-
<Input
|
|
206
|
-
mb={2}
|
|
207
|
-
flex={1}
|
|
208
|
-
value={buyerEmail}
|
|
209
|
-
onChangeText={(value) => setBuyerEmail(value)}
|
|
210
|
-
/>
|
|
211
|
-
</Stack>
|
|
212
|
-
<Button
|
|
213
|
-
bgColor={'#344e81'}
|
|
214
|
-
/* @ts-ignore */
|
|
215
|
-
onPress={() => {
|
|
216
|
-
const data = {
|
|
217
|
-
params: {
|
|
218
|
-
pg,
|
|
219
|
-
pay_method: method,
|
|
220
|
-
currency: undefined,
|
|
221
|
-
notice_url: undefined,
|
|
222
|
-
display: undefined,
|
|
223
|
-
merchant_uid: merchantUid,
|
|
224
|
-
name,
|
|
225
|
-
amount,
|
|
226
|
-
app_scheme: 'exampleformanagedexpo',
|
|
227
|
-
tax_free: undefined,
|
|
228
|
-
buyer_name: buyerName,
|
|
229
|
-
buyer_tel: buyerTel,
|
|
230
|
-
buyer_email: buyerEmail,
|
|
231
|
-
buyer_addr: undefined,
|
|
232
|
-
buyer_postcode: undefined,
|
|
233
|
-
custom_data: undefined,
|
|
234
|
-
vbank_due: undefined,
|
|
235
|
-
popup: undefined,
|
|
236
|
-
digital: undefined,
|
|
237
|
-
language: undefined,
|
|
238
|
-
biz_num: undefined,
|
|
239
|
-
customer_uid: undefined,
|
|
240
|
-
naverPopupMode: undefined,
|
|
241
|
-
naverUseCfm: undefined,
|
|
242
|
-
naverProducts: undefined,
|
|
243
|
-
m_redirect_url: IMPConst.M_REDIRECT_URL,
|
|
244
|
-
escrow,
|
|
245
|
-
},
|
|
246
|
-
tierCode,
|
|
247
|
-
};
|
|
248
|
-
|
|
249
|
-
// 신용카드의 경우, 할부기한 추가
|
|
250
|
-
if (method === 'card' && cardQuota !== 0) {
|
|
251
|
-
data.params.display = {
|
|
252
|
-
card_quota: cardQuota === 1 ? [] : [cardQuota],
|
|
253
|
-
};
|
|
254
|
-
}
|
|
255
|
-
|
|
256
|
-
// 가상계좌의 경우, 입금기한 추가
|
|
257
|
-
if (method === 'vbank' && vbankDue) {
|
|
258
|
-
data.params.vbank_due = vbankDue;
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
// 다날 && 가상계좌의 경우, 사업자 등록번호 10자리 추가
|
|
262
|
-
if (method === 'vbank' && pg === 'danal_tpay') {
|
|
263
|
-
data.params.biz_num = bizNum;
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
// 휴대폰 소액결제의 경우, 실물 컨텐츠 여부 추가
|
|
267
|
-
if (method === 'phone') {
|
|
268
|
-
data.params.digital = digital;
|
|
269
|
-
}
|
|
270
|
-
|
|
271
|
-
// 정기결제의 경우, customer_uid 추가
|
|
272
|
-
if (pg === 'kcp_billing') {
|
|
273
|
-
data.params.customer_uid = `cuid_${new Date().getTime()}`;
|
|
274
|
-
}
|
|
275
|
-
|
|
276
|
-
if (pg === 'naverpay') {
|
|
277
|
-
const today = new Date();
|
|
278
|
-
const oneMonthLater = new Date(
|
|
279
|
-
today.setMonth(today.getMonth() + 1)
|
|
280
|
-
);
|
|
281
|
-
const dd = String(oneMonthLater.getDate()).padStart(2, '0');
|
|
282
|
-
const mm = String(oneMonthLater.getMonth() + 1).padStart(
|
|
283
|
-
2,
|
|
284
|
-
'0'
|
|
285
|
-
); // January is 0!
|
|
286
|
-
const yyyy = oneMonthLater.getFullYear();
|
|
287
|
-
|
|
288
|
-
data.params.naverPopupMode = false;
|
|
289
|
-
data.params.naverUseCfm = `${yyyy}${mm}${dd}`;
|
|
290
|
-
data.params.naverProducts = [
|
|
291
|
-
{
|
|
292
|
-
categoryType: 'BOOK',
|
|
293
|
-
categoryId: 'GENERAL',
|
|
294
|
-
uid: '107922211',
|
|
295
|
-
name: '한국사',
|
|
296
|
-
payReferrer: 'NAVER_BOOK',
|
|
297
|
-
count: 10,
|
|
298
|
-
},
|
|
299
|
-
];
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
navigation.navigate('Payment', data);
|
|
303
|
-
}}
|
|
304
|
-
>
|
|
305
|
-
<Text fontWeight={'bold'} color={'#fff'}>
|
|
306
|
-
결제하기
|
|
307
|
-
</Text>
|
|
308
|
-
</Button>
|
|
309
|
-
</FormControl>
|
|
310
|
-
</ScrollView>
|
|
311
|
-
</SafeAreaView>
|
|
312
|
-
);
|
|
313
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Select } from 'native-base';
|
|
3
|
-
|
|
4
|
-
export default function Picker(props) {
|
|
5
|
-
return (
|
|
6
|
-
<Select
|
|
7
|
-
mb={2}
|
|
8
|
-
flex={1}
|
|
9
|
-
borderColor={'transparent'}
|
|
10
|
-
selectedValue={props.selectedValue}
|
|
11
|
-
onValueChange={props.onValueChange}
|
|
12
|
-
>
|
|
13
|
-
{props.data.map((e, index) => {
|
|
14
|
-
const { label, value } = e;
|
|
15
|
-
return <Select.Item label={label} value={value} key={index} />;
|
|
16
|
-
})}
|
|
17
|
-
</Select>
|
|
18
|
-
);
|
|
19
|
-
}
|