tradly 1.1.72 → 1.1.74
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/NetworkManager/NetworkManager.js +6 -0
- package/Roots/App.js +22 -0
- package/package.json +1 -1
|
@@ -52,6 +52,12 @@ class NetworkManager {
|
|
|
52
52
|
if (config.language != undefined || config.language == "") {
|
|
53
53
|
header["X-Language"] = config.language;
|
|
54
54
|
}
|
|
55
|
+
if (
|
|
56
|
+
config?.barrow_access_key != undefined ||
|
|
57
|
+
config?.barrow_access_key !== ""
|
|
58
|
+
) {
|
|
59
|
+
header["barrow_access_key"] = config?.barrow_access_key;
|
|
60
|
+
}
|
|
55
61
|
if (Object.keys(APPCONSTANT.CUSTOM_HEADER).length > 0) {
|
|
56
62
|
Object.keys(APPCONSTANT.CUSTOM_HEADER).forEach((key) => {
|
|
57
63
|
header[key] = APPCONSTANT.CUSTOM_HEADER[key];
|
package/Roots/App.js
CHANGED
|
@@ -2657,6 +2657,28 @@ class App {
|
|
|
2657
2657
|
return error;
|
|
2658
2658
|
}
|
|
2659
2659
|
}
|
|
2660
|
+
async confirmOrderByUser(
|
|
2661
|
+
param = { authKey, data, bodyParam, order_ref, access_key }
|
|
2662
|
+
) {
|
|
2663
|
+
try {
|
|
2664
|
+
const [error, responseJson] = await network.networkCall({
|
|
2665
|
+
path: ORDERS + `/${param.order_ref}/confirm`,
|
|
2666
|
+
method: Method.PATCH,
|
|
2667
|
+
authKey: param.authKey,
|
|
2668
|
+
currency: param.currency,
|
|
2669
|
+
language: param.language,
|
|
2670
|
+
barrow_access_key: param.access_key,
|
|
2671
|
+
param: param.data,
|
|
2672
|
+
});
|
|
2673
|
+
if (error) {
|
|
2674
|
+
return error;
|
|
2675
|
+
} else {
|
|
2676
|
+
return responseJson;
|
|
2677
|
+
}
|
|
2678
|
+
} catch (error) {
|
|
2679
|
+
return error;
|
|
2680
|
+
}
|
|
2681
|
+
}
|
|
2660
2682
|
|
|
2661
2683
|
//
|
|
2662
2684
|
async getSendCloudShipmentsMethods(param = { authKey, bodyParam }) {
|