react-native-cashfree-pg-sdk 2.1.0 → 2.1.1
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/android/.gradle/7.2/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.2/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/8.1/checksums/checksums.lock +0 -0
- package/android/.gradle/8.1/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/8.1/checksums/sha1-checksums.bin +0 -0
- package/android/.gradle/8.1/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/8.1/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -2
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/checksums/sha1-checksums.bin +0 -0
- package/android/.idea/misc.xml +1 -2
- package/android/.idea/sonarlint/issuestore/index.pb +1 -3
- package/android/.idea/sonarlint/securityhotspotstore/index.pb +1 -3
- package/android/build.gradle +1 -1
- package/lib/module/index.js.map +1 -1
- package/package.json +1 -1
- package/android/.gradle/7.4.2/checksums/checksums.lock +0 -0
- package/android/.gradle/7.4.2/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/7.4.2/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.4.2/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/.idea/sonarlint/issuestore/f/0/f07866736216be0ee2aba49e392191aeae700a35 +0 -0
- package/android/.idea/sonarlint/securityhotspotstore/f/0/f07866736216be0ee2aba49e392191aeae700a35 +0 -0
- /package/android/.gradle/{7.4.2 → 8.1}/dependencies-accessors/gc.properties +0 -0
- /package/android/.gradle/{7.4.2 → 8.1}/fileChanges/last-build.bin +0 -0
- /package/android/.gradle/{7.4.2 → 8.1}/gc.properties +0 -0
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
#
|
|
2
|
-
gradle.version=
|
|
1
|
+
#Mon Aug 14 19:43:19 IST 2023
|
|
2
|
+
gradle.version=8.1
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/android/.idea/misc.xml
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
1
|
<project version="4">
|
|
3
2
|
<component name="ExternalStorageConfigurationManager" enabled="true" />
|
|
4
|
-
<component name="ProjectRootManager" version="2" languageLevel="JDK_17"
|
|
3
|
+
<component name="ProjectRootManager" version="2" languageLevel="JDK_17" project-jdk-name="jbr-17" project-jdk-type="JavaSDK">
|
|
5
4
|
<output url="file://$PROJECT_DIR$/build/classes" />
|
|
6
5
|
</component>
|
|
7
6
|
<component name="ProjectType">
|
|
@@ -6,6 +6,4 @@ L
|
|
|
6
6
|
s
|
|
7
7
|
Csrc/main/java/com/reactnativecashfreepgsdk/CashfreePgApiModule.java,4/4/44aaf172f11159c609e569cf1b49bcd49376a770
|
|
8
8
|
t
|
|
9
|
-
Dsrc/main/java/com/reactnativecashfreepgsdk/CashfreePgApiPackage.java,3/e/3e1984987c20cd21984de8c97894175bd94b0037
|
|
10
|
-
<
|
|
11
|
-
build.gradle,f/0/f07866736216be0ee2aba49e392191aeae700a35
|
|
9
|
+
Dsrc/main/java/com/reactnativecashfreepgsdk/CashfreePgApiPackage.java,3/e/3e1984987c20cd21984de8c97894175bd94b0037
|
|
@@ -6,6 +6,4 @@ L
|
|
|
6
6
|
s
|
|
7
7
|
Csrc/main/java/com/reactnativecashfreepgsdk/CashfreePgApiModule.java,4/4/44aaf172f11159c609e569cf1b49bcd49376a770
|
|
8
8
|
t
|
|
9
|
-
Dsrc/main/java/com/reactnativecashfreepgsdk/CashfreePgApiPackage.java,3/e/3e1984987c20cd21984de8c97894175bd94b0037
|
|
10
|
-
<
|
|
11
|
-
build.gradle,f/0/f07866736216be0ee2aba49e392191aeae700a35
|
|
9
|
+
Dsrc/main/java/com/reactnativecashfreepgsdk/CashfreePgApiPackage.java,3/e/3e1984987c20cd21984de8c97894175bd94b0037
|
package/android/build.gradle
CHANGED
|
@@ -66,7 +66,7 @@ dependencies {
|
|
|
66
66
|
implementation 'androidx.constraintlayout:constraintlayout:2.1.3'
|
|
67
67
|
implementation 'androidx.gridlayout:gridlayout:1.0.0'
|
|
68
68
|
|
|
69
|
-
implementation 'com.cashfree.pg:api:2.1.
|
|
69
|
+
implementation 'com.cashfree.pg:api:2.1.3'
|
|
70
70
|
|
|
71
71
|
implementation "com.facebook.react:react-native:+" // From node_modules
|
|
72
72
|
}
|
package/lib/module/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NativeAppEventEmitter","NativeEventEmitter","NativeModules","Platform","version","LINKING_ERROR","select","ios","default","CashfreePgApi","Proxy","get","Error","CFPaymentGateway","constructor","emitter","OS","CashfreeEventEmitter","doPayment","checkoutPayment","JSON","stringify","doWebPayment","cfSession","setEventSubscriber","cfEventCallback","eventFunction","event","console","log","data","parse","onReceivedEvent","eventName","meta","eventSubscription","addListener","removeEventSubscriber","undefined","remove","setCallback","cfCallback","successFunction","orderID","onVerify","failureFunction","error","response","CFErrorResponse","message","fromJSON","onError","successSubscription","failureSubscription","removeCallback","errorString","object","status","code","type","getStatus","getMessage","getCode","getType","CFPaymentGatewayService"],"sources":["index.
|
|
1
|
+
{"version":3,"names":["NativeAppEventEmitter","NativeEventEmitter","NativeModules","Platform","version","LINKING_ERROR","select","ios","default","CashfreePgApi","Proxy","get","Error","CFPaymentGateway","constructor","emitter","OS","CashfreeEventEmitter","doPayment","checkoutPayment","JSON","stringify","doWebPayment","cfSession","setEventSubscriber","cfEventCallback","eventFunction","event","console","log","data","parse","onReceivedEvent","eventName","meta","eventSubscription","addListener","removeEventSubscriber","undefined","remove","setCallback","cfCallback","successFunction","orderID","onVerify","failureFunction","error","response","CFErrorResponse","message","fromJSON","onError","successSubscription","failureSubscription","removeCallback","errorString","object","status","code","type","getStatus","getMessage","getCode","getType","CFPaymentGatewayService"],"sources":["index.ts"],"sourcesContent":["import {\n EmitterSubscription,\n EventEmitter,\n NativeAppEventEmitter,\n NativeEventEmitter,\n NativeModules,\n Platform,\n} from 'react-native';\nimport { version } from '../package.json';\nimport type { CheckoutPayment, CFSession } from 'cashfree-pg-api-contract';\n\nconst LINKING_ERROR =\n `The package 'react-native-cashfree-pg-api' doesn't seem to be linked. Make sure: \\n\\n` +\n Platform.select({ ios: \"- You have run 'pod install'\\n\", default: '' }) +\n '- You rebuilt the app after installing the package\\n' +\n '- You are not using Expo managed workflow\\n';\n\nconst CashfreePgApi = NativeModules.CashfreePgApi\n ? NativeModules.CashfreePgApi\n : new Proxy(\n {},\n {\n get() {\n throw new Error(LINKING_ERROR);\n },\n }\n );\n\nclass CFPaymentGateway {\n private emitter: EventEmitter;\n private successSubscription: EmitterSubscription | null = null;\n private failureSubscription: EmitterSubscription | null = null;\n private eventSubscription: EmitterSubscription | null = null;\n\n constructor() {\n this.emitter =\n Platform.OS === 'ios'\n ? new NativeEventEmitter(NativeModules.CashfreeEventEmitter)\n : NativeAppEventEmitter;\n }\n\n doPayment(checkoutPayment: CheckoutPayment) {\n checkoutPayment.version = version;\n CashfreePgApi.doPayment(JSON.stringify(checkoutPayment));\n }\n\n doWebPayment(cfSession: CFSession) {\n CashfreePgApi.doWebPayment(cfSession);\n }\n\n setEventSubscriber(cfEventCallback: CFEventCallback) {\n let eventFunction = (event: string) => {\n console.log(JSON.stringify(event));\n let data = JSON.parse(event);\n cfEventCallback.onReceivedEvent(data.eventName, data.meta);\n };\n this.eventSubscription = this.emitter.addListener('cfEvent', eventFunction);\n CashfreePgApi.setEventSubscriber();\n }\n\n removeEventSubscriber() {\n if (\n this.eventSubscription !== undefined &&\n this.eventSubscription !== null\n ) {\n this.eventSubscription.remove();\n this.eventSubscription = null;\n }\n CashfreePgApi.removeEventSubscriber();\n }\n\n setCallback(cfCallback: CFCallback) {\n // this.cfCallback = cfCallback;\n let successFunction = (orderID: string) => {\n console.log('response is : ' + JSON.stringify(orderID));\n cfCallback.onVerify(orderID);\n };\n let failureFunction = (error: string) => {\n console.log('reason: ' + JSON.stringify(error));\n const response = new CFErrorResponse();\n // @ts-ignore\n const message = JSON.parse(error);\n response.fromJSON(message.error);\n // @ts-ignore\n cfCallback.onError(response, message.orderID);\n };\n this.successSubscription = this.emitter.addListener(\n 'cfSuccess',\n successFunction\n );\n this.failureSubscription = this.emitter.addListener(\n 'cfFailure',\n failureFunction\n );\n CashfreePgApi.setCallback();\n }\n\n removeCallback() {\n if (\n this.successSubscription !== undefined &&\n this.successSubscription !== null\n ) {\n this.successSubscription.remove();\n this.successSubscription = null;\n }\n if (\n this.failureSubscription !== undefined &&\n this.failureSubscription !== null\n ) {\n this.failureSubscription.remove();\n this.failureSubscription = null;\n }\n }\n}\n\nexport interface CFCallback {\n onVerify(orderID: string): void;\n\n onError(error: CFErrorResponse, orderID: string): void;\n}\n\nexport interface CFEventCallback {\n onReceivedEvent(eventName: string, map: Map<string, string>): void;\n}\n\nexport class CFErrorResponse {\n private status: string = 'FAILED';\n private message: string = 'payment has failed';\n private code: string = 'payment_failed';\n private type: string = 'request_failed';\n\n fromJSON(errorString: string) {\n console.log('errorString :' + errorString);\n const object = JSON.parse(errorString);\n console.log('errorStringObject :' + object);\n this.status = object.status;\n this.message = object.message;\n this.code = object.code;\n this.type = object.type;\n }\n\n getStatus(): string {\n return this.status;\n }\n\n getMessage(): string {\n return this.message;\n }\n\n getCode(): string {\n return this.code;\n }\n\n getType(): string {\n return this.type;\n }\n}\n\nexport const CFPaymentGatewayService = new CFPaymentGateway();\n"],"mappings":";;;AAAA,SAGEA,qBAAqB,EACrBC,kBAAkB,EAClBC,aAAa,EACbC,QAAQ,QACH,cAAc;AACrB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ary file
|
|
File without changes
|
package/android/.idea/sonarlint/securityhotspotstore/f/0/f07866736216be0ee2aba49e392191aeae700a35
DELETED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|