rerobe-js-orm 2.5.4 → 2.5.5
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.
|
@@ -6,19 +6,19 @@ const options_1 = require("../form-states/Product/options");
|
|
|
6
6
|
const ProductStateManager_1 = require("../models/ProductStateManager");
|
|
7
7
|
class ReRobeProductHelpers {
|
|
8
8
|
static calculateProductionFee(commission) {
|
|
9
|
-
if (commission >= 0.5 || commission === 0.2 || commission === 0.15 || commission === 0) {
|
|
10
|
-
return 0;
|
|
11
|
-
}
|
|
12
9
|
if (commission === 0.16) {
|
|
13
10
|
return 19;
|
|
14
11
|
}
|
|
15
|
-
|
|
12
|
+
if (commission === 0.35) {
|
|
13
|
+
return 40;
|
|
14
|
+
}
|
|
15
|
+
return 0;
|
|
16
16
|
}
|
|
17
17
|
static calculateFulfillmentFee(commission) {
|
|
18
|
-
if (commission
|
|
19
|
-
return
|
|
18
|
+
if (commission === 0.35) {
|
|
19
|
+
return 24;
|
|
20
20
|
}
|
|
21
|
-
return
|
|
21
|
+
return 0;
|
|
22
22
|
}
|
|
23
23
|
static buildReRobeEarnings(arrayLike) {
|
|
24
24
|
const products = Array.isArray(arrayLike) ? arrayLike : [arrayLike];
|