@jimrising/easymerchantsdk-react-native 1.0.0 → 1.0.2

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/README.md CHANGED
@@ -8,7 +8,7 @@ To add the path of sdk in your project. Open your `package.json` file and inside
8
8
  ```json
9
9
  "dependencies": {
10
10
  ...
11
- "easymerchantsdk-react-native": "^1.0.0"
11
+ "easymerchantsdk-react-native": "^1.0.2"
12
12
  },
13
13
  ```
14
14
  or using command
@@ -37,9 +37,13 @@ allprojects {
37
37
  ```
38
38
 
39
39
  ## Changes in IOS side.
40
+
41
+ ### If project is based on Objective-C :-
42
+ No need to create any AppDelegate.swift File.
43
+
44
+ ### If project is based on Swift :-
40
45
  Add below content inside the AppDelegate.swift File :-
41
46
 
42
- Create a new file named AppDelegate.swift
43
47
  ```swift
44
48
  import UIKit
45
49
  import easymerchantsdk
@@ -93,7 +97,8 @@ var window: UIWindow?
93
97
  }
94
98
  ```
95
99
 
96
- inside the PodFile add below
100
+
101
+ ### inside the PodFile add below
97
102
  ```pod
98
103
 
99
104
  require_relative '../node_modules/react-native/scripts/react_native_pods'
@@ -140,7 +145,7 @@ const App = () => {
140
145
  const additionalInfoRequest = {
141
146
  name: "Test User",
142
147
  email: "test@gmail.com",
143
- phone_number: "9465351125",
148
+ phone_number: "9815404694",
144
149
  country_code: "91",
145
150
  description: "Test"
146
151
  };
@@ -149,7 +154,7 @@ const App = () => {
149
154
  address: "Mohali, Punjab",
150
155
  country: "India",
151
156
  state: "Punjab",
152
- city: "Anandpur Sahib",
157
+ city: "Mohali",
153
158
  postal_code: "140118",
154
159
  additional_info: additionalInfoRequest
155
160
  };
@@ -158,12 +163,14 @@ const App = () => {
158
163
 
159
164
  try {
160
165
  if (Platform.OS === 'android') {
161
- // const response = await RNEasymerchantsdk.billing(amount, null,'staging','mobilesdk1980IUuCzwWl','mobilesdk1980LVHnN0Oh');
162
- const response = await RNEasymerchantsdk.billing(amount, null,'sandbox','f149cf5afc3a67c79e0aa87e7','22b9dd1e588146077ca77da82');
166
+ // const response = await RNEasymerchantsdk.billing(amount, null,'staging','apiKey','secretKey');
167
+ const response = await RNEasymerchantsdk.billing(amount, null,'sandbox','apiKey','secretKey');
168
+ // const response = await RNEasymerchantsdk.billing(amount, null,'production','apiKey','secretKey');
163
169
  setPaymentResponse(`Payment Success: ${response}`);
164
170
  } else if (Platform.OS === 'ios') {
165
- const result = await EasyMerchantSdk.billing(amount, jsonString,'staging','mobilesdk1980IUuCzwWl','mobilesdk1980LVHnN0Oh');
166
- // const result = await EasyMerchantSdk.billing(amount, jsonString,'sandbox','f149cf5afc3a67c79e0aa87e7','22b9dd1e588146077ca77da82');
171
+ const result = await EasyMerchantSdk.billing(amount, jsonString,'staging','apiKey','secretKey');
172
+ // const result = await EasyMerchantSdk.billing(amount, jsonString,'sandbox','apiKey','secretKey');
173
+ // const result = await EasyMerchantSdk.billing(amount, jsonString,'production','apiKey','secretKey');
167
174
  setBillingResult(`Billing Success: ${result}`);
168
175
  }
169
176
  } catch (error) {
@@ -89,7 +89,6 @@ extension EasyMerchantSdkPlugin: RCTBridgeModule {
89
89
  public static func moduleName() -> String {
90
90
  return "EasyMerchantSdk"
91
91
  }
92
-
93
92
  public static func requiresMainQueueSetup() -> Bool {
94
93
  return true
95
94
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jimrising/easymerchantsdk-react-native",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "description": "A React Native SDK for EasyMerchant",
5
5
  "main": "index.js",
6
6
  "scripts": {