@chevre/domain 21.2.0-alpha.62 → 21.2.0-alpha.63
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 +2338 -0
- package/example/.gitignore +1 -0
- package/example/src/chevre/.gitignore +1 -0
- package/lib/chevre/repo/mongoose/schemas/offerItemCondition.d.ts +1 -1
- package/lib/chevre/repo/mongoose/schemas/offerItemCondition.js +1 -1
- package/lib/chevre/service/transaction/returnOrder.js +6 -3
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
dst
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
*.csv
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
/// <reference types="mongoose/types/virtuals" />
|
|
24
24
|
/// <reference types="mongoose/types/inferschematype" />
|
|
25
25
|
import { Schema } from 'mongoose';
|
|
26
|
-
declare const modelName = "
|
|
26
|
+
declare const modelName = "OfferItemCondition";
|
|
27
27
|
/**
|
|
28
28
|
* アイテムコンディションスキーマ
|
|
29
29
|
*/
|
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.schema = exports.modelName = void 0;
|
|
4
4
|
const mongoose_1 = require("mongoose");
|
|
5
5
|
const writeConcern_1 = require("../writeConcern");
|
|
6
|
-
const modelName = '
|
|
6
|
+
const modelName = 'OfferItemCondition';
|
|
7
7
|
exports.modelName = modelName;
|
|
8
8
|
/**
|
|
9
9
|
* アイテムコンディションスキーマ
|
|
@@ -313,10 +313,13 @@ function findApplicableReturnPolicy(params) {
|
|
|
313
313
|
// restockingFeeが最低のポリシーを自動選択
|
|
314
314
|
let appliedReturnPolicy = applicalbleReturnPolicies[0];
|
|
315
315
|
applicalbleReturnPolicies.forEach((returnPolicy) => {
|
|
316
|
-
|
|
317
|
-
|
|
316
|
+
var _a, _b;
|
|
317
|
+
const appliedReturnPolicyRestockingFeeValue = (_a = appliedReturnPolicy.restockingFee) === null || _a === void 0 ? void 0 : _a.value;
|
|
318
|
+
const restockingFeeValue = (_b = returnPolicy.restockingFee) === null || _b === void 0 ? void 0 : _b.value;
|
|
319
|
+
const appliedReturnPolicyRestockingFee = (typeof appliedReturnPolicyRestockingFeeValue === 'number')
|
|
320
|
+
? appliedReturnPolicyRestockingFeeValue
|
|
318
321
|
: 0;
|
|
319
|
-
const restockingFee = (typeof
|
|
322
|
+
const restockingFee = (typeof restockingFeeValue === 'number') ? restockingFeeValue : 0;
|
|
320
323
|
if (restockingFee < appliedReturnPolicyRestockingFee) {
|
|
321
324
|
appliedReturnPolicy = returnPolicy;
|
|
322
325
|
}
|
package/package.json
CHANGED