@medusajs/medusa 1.3.9-alpha.0 → 1.4.0
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/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +10 -8
- package/dist/api/routes/admin/currencies/index.d.ts +0 -0
- package/dist/api/routes/admin/currencies/index.js +0 -0
- package/dist/api/routes/admin/currencies/index.js.map +0 -0
- package/dist/api/routes/admin/currencies/list-currencies.d.ts +0 -0
- package/dist/api/routes/admin/currencies/list-currencies.js +0 -0
- package/dist/api/routes/admin/currencies/list-currencies.js.map +0 -0
- package/dist/api/routes/admin/currencies/update-currency.d.ts +0 -0
- package/dist/api/routes/admin/currencies/update-currency.js +0 -0
- package/dist/api/routes/admin/currencies/update-currency.js.map +0 -0
- package/dist/api/routes/admin/currency/index.d.ts +0 -0
- package/dist/api/routes/admin/currency/index.js +0 -0
- package/dist/api/routes/admin/currency/index.js.map +0 -0
- package/dist/api/routes/admin/currency/list-currencies.d.ts +0 -0
- package/dist/api/routes/admin/currency/list-currencies.js +0 -0
- package/dist/api/routes/admin/currency/list-currencies.js.map +0 -0
- package/dist/api/routes/admin/currency/update-currency.d.ts +0 -0
- package/dist/api/routes/admin/currency/update-currency.js +0 -0
- package/dist/api/routes/admin/currency/update-currency.js.map +0 -0
- package/dist/api/routes/store/carts/create-cart.js +60 -40
- package/dist/api/routes/store/carts/create-cart.js.map +1 -1
- package/dist/loaders/feature-flags/order-editing.d.ts +3 -0
- package/dist/loaders/feature-flags/order-editing.js +10 -0
- package/dist/loaders/feature-flags/order-editing.js.map +1 -0
- package/dist/loaders/feature-flags/tax-inclusive-pricing.d.ts +0 -0
- package/dist/loaders/feature-flags/tax-inclusive-pricing.js +0 -0
- package/dist/loaders/feature-flags/tax-inclusive-pricing.js.map +0 -0
- package/dist/migrations/1659501357661-tax_inclusive_pricing.d.ts +0 -0
- package/dist/migrations/1659501357661-tax_inclusive_pricing.js +0 -0
- package/dist/migrations/1659501357661-tax_inclusive_pricing.js.map +0 -0
- package/dist/migrations/1663059812399-order_editing.d.ts +7 -0
- package/dist/migrations/1663059812399-order_editing.js +112 -0
- package/dist/migrations/1663059812399-order_editing.js.map +1 -0
- package/dist/models/order-edit.d.ts +111 -0
- package/dist/models/order-edit.js +204 -0
- package/dist/models/order-edit.js.map +1 -0
- package/dist/models/order-item-change.d.ts +60 -0
- package/dist/models/order-item-change.js +143 -0
- package/dist/models/order-item-change.js.map +1 -0
- package/dist/models/order.d.ts +7 -0
- package/dist/models/order.js +16 -0
- package/dist/models/order.js.map +1 -1
- package/dist/repositories/order-edit.d.ts +4 -0
- package/dist/repositories/order-edit.js +38 -0
- package/dist/repositories/order-edit.js.map +1 -0
- package/dist/repositories/order-item-change.d.ts +4 -0
- package/dist/repositories/order-item-change.js +38 -0
- package/dist/repositories/order-item-change.js.map +1 -0
- package/dist/services/currency.d.ts +0 -0
- package/dist/services/currency.js +0 -0
- package/dist/services/currency.js.map +0 -0
- package/dist/strategies/batch-jobs/product/import.js +67 -59
- package/dist/strategies/batch-jobs/product/import.js.map +1 -1
- package/dist/types/currency.d.ts +0 -0
- package/dist/types/currency.js +0 -0
- package/dist/types/currency.js.map +0 -0
- package/dist/utils/calculate-price-tax-amount.d.ts +0 -0
- package/dist/utils/calculate-price-tax-amount.js +0 -0
- package/dist/utils/calculate-price-tax-amount.js.map +0 -0
- package/dist/utils/csv-cell-content-formatter.d.ts +0 -0
- package/dist/utils/csv-cell-content-formatter.js +0 -0
- package/dist/utils/csv-cell-content-formatter.js.map +0 -0
- package/package.json +1 -3
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
|
3
|
+
var extendStatics = function (d, b) {
|
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
+
return extendStatics(d, b);
|
|
8
|
+
};
|
|
9
|
+
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
+
extendStatics(d, b);
|
|
13
|
+
function __() { this.constructor = d; }
|
|
14
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
+
};
|
|
16
|
+
})();
|
|
17
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
18
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
19
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
20
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
21
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
22
|
+
};
|
|
23
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
24
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
25
|
+
};
|
|
26
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
27
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
28
|
+
};
|
|
29
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
exports.OrderEdit = void 0;
|
|
31
|
+
var typeorm_1 = require("typeorm");
|
|
32
|
+
var order_editing_1 = __importDefault(require("../loaders/feature-flags/order-editing"));
|
|
33
|
+
var feature_flag_decorators_1 = require("../utils/feature-flag-decorators");
|
|
34
|
+
var db_aware_column_1 = require("../utils/db-aware-column");
|
|
35
|
+
var order_item_change_1 = require("./order-item-change");
|
|
36
|
+
var interfaces_1 = require("../interfaces");
|
|
37
|
+
var utils_1 = require("../utils");
|
|
38
|
+
var order_1 = require("./order");
|
|
39
|
+
var OrderEdit = /** @class */ (function (_super) {
|
|
40
|
+
__extends(OrderEdit, _super);
|
|
41
|
+
function OrderEdit() {
|
|
42
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
43
|
+
}
|
|
44
|
+
OrderEdit.prototype.beforeInsert = function () {
|
|
45
|
+
this.id = (0, utils_1.generateEntityId)(this.id, "oe");
|
|
46
|
+
};
|
|
47
|
+
__decorate([
|
|
48
|
+
(0, typeorm_1.Column)(),
|
|
49
|
+
__metadata("design:type", String)
|
|
50
|
+
], OrderEdit.prototype, "order_id", void 0);
|
|
51
|
+
__decorate([
|
|
52
|
+
(0, typeorm_1.ManyToOne)(function () { return order_1.Order; }, function (o) { return o.edits; }),
|
|
53
|
+
(0, typeorm_1.JoinColumn)({ name: "order_id" }),
|
|
54
|
+
__metadata("design:type", order_1.Order)
|
|
55
|
+
], OrderEdit.prototype, "order", void 0);
|
|
56
|
+
__decorate([
|
|
57
|
+
(0, typeorm_1.OneToMany)(function () { return order_item_change_1.OrderItemChange; }, function (oic) { return oic.order_edit; }, {
|
|
58
|
+
cascade: true,
|
|
59
|
+
}),
|
|
60
|
+
__metadata("design:type", Array)
|
|
61
|
+
], OrderEdit.prototype, "changes", void 0);
|
|
62
|
+
__decorate([
|
|
63
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
64
|
+
__metadata("design:type", String)
|
|
65
|
+
], OrderEdit.prototype, "internal_note", void 0);
|
|
66
|
+
__decorate([
|
|
67
|
+
(0, typeorm_1.Column)(),
|
|
68
|
+
__metadata("design:type", String)
|
|
69
|
+
], OrderEdit.prototype, "created_by", void 0);
|
|
70
|
+
__decorate([
|
|
71
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
72
|
+
__metadata("design:type", String)
|
|
73
|
+
], OrderEdit.prototype, "requested_by", void 0);
|
|
74
|
+
__decorate([
|
|
75
|
+
(0, typeorm_1.Column)({ type: (0, db_aware_column_1.resolveDbType)("timestamptz"), nullable: true }),
|
|
76
|
+
__metadata("design:type", Date)
|
|
77
|
+
], OrderEdit.prototype, "requested_at", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
80
|
+
__metadata("design:type", String)
|
|
81
|
+
], OrderEdit.prototype, "confirmed_by", void 0);
|
|
82
|
+
__decorate([
|
|
83
|
+
(0, typeorm_1.Column)({ type: (0, db_aware_column_1.resolveDbType)("timestamptz"), nullable: true }),
|
|
84
|
+
__metadata("design:type", Date)
|
|
85
|
+
], OrderEdit.prototype, "confirmed_at", void 0);
|
|
86
|
+
__decorate([
|
|
87
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
88
|
+
__metadata("design:type", String)
|
|
89
|
+
], OrderEdit.prototype, "declined_by", void 0);
|
|
90
|
+
__decorate([
|
|
91
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
92
|
+
__metadata("design:type", String)
|
|
93
|
+
], OrderEdit.prototype, "declined_reason", void 0);
|
|
94
|
+
__decorate([
|
|
95
|
+
(0, typeorm_1.Column)({ type: (0, db_aware_column_1.resolveDbType)("timestamptz"), nullable: true }),
|
|
96
|
+
__metadata("design:type", Date)
|
|
97
|
+
], OrderEdit.prototype, "declined_at", void 0);
|
|
98
|
+
__decorate([
|
|
99
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
100
|
+
__metadata("design:type", String)
|
|
101
|
+
], OrderEdit.prototype, "canceled_by", void 0);
|
|
102
|
+
__decorate([
|
|
103
|
+
(0, typeorm_1.Column)({ type: (0, db_aware_column_1.resolveDbType)("timestamptz"), nullable: true }),
|
|
104
|
+
__metadata("design:type", Date
|
|
105
|
+
// Computed
|
|
106
|
+
)
|
|
107
|
+
], OrderEdit.prototype, "canceled_at", void 0);
|
|
108
|
+
__decorate([
|
|
109
|
+
(0, typeorm_1.BeforeInsert)(),
|
|
110
|
+
__metadata("design:type", Function),
|
|
111
|
+
__metadata("design:paramtypes", []),
|
|
112
|
+
__metadata("design:returntype", void 0)
|
|
113
|
+
], OrderEdit.prototype, "beforeInsert", null);
|
|
114
|
+
OrderEdit = __decorate([
|
|
115
|
+
(0, feature_flag_decorators_1.FeatureFlagEntity)(order_editing_1.default.key)
|
|
116
|
+
], OrderEdit);
|
|
117
|
+
return OrderEdit;
|
|
118
|
+
}(interfaces_1.SoftDeletableEntity));
|
|
119
|
+
exports.OrderEdit = OrderEdit;
|
|
120
|
+
/**
|
|
121
|
+
* @schema order_edit
|
|
122
|
+
* title: "Order Edit"
|
|
123
|
+
* description: "Order edit keeps track of order items changes."
|
|
124
|
+
* x-resourceId: order_edit
|
|
125
|
+
* required:
|
|
126
|
+
* - order_id
|
|
127
|
+
* - order
|
|
128
|
+
* - changes
|
|
129
|
+
* - created_by
|
|
130
|
+
* properties:
|
|
131
|
+
* id:
|
|
132
|
+
* type: string
|
|
133
|
+
* description: The order edit's ID
|
|
134
|
+
* example: oe_01G8TJSYT9M6AVS5N4EMNFS1EK
|
|
135
|
+
* order_id:
|
|
136
|
+
* type: string
|
|
137
|
+
* description: The ID of the order that is edited
|
|
138
|
+
* example: order_01G2SG30J8C85S4A5CHM2S1NS2
|
|
139
|
+
* order:
|
|
140
|
+
* description: Order object
|
|
141
|
+
* $ref: "#/components/schemas/order"
|
|
142
|
+
* changes:
|
|
143
|
+
* type: array
|
|
144
|
+
* description: Line item changes array.
|
|
145
|
+
* items:
|
|
146
|
+
* $ref: "#/components/schemas/order_item_changes"
|
|
147
|
+
* internal_note:
|
|
148
|
+
* description: "An optional note with additional details about the order edit."
|
|
149
|
+
* type: string
|
|
150
|
+
* example: Included two more items B to the order.
|
|
151
|
+
* created_by:
|
|
152
|
+
* type: string
|
|
153
|
+
* description: "The unique identifier of the user or customer who created the order edit."
|
|
154
|
+
* requested_by:
|
|
155
|
+
* type: string
|
|
156
|
+
* description: "The unique identifier of the user or customer who requested the order edit."
|
|
157
|
+
* requested_at:
|
|
158
|
+
* type: string
|
|
159
|
+
* description: "The date with timezone at which the edit was requested."
|
|
160
|
+
* format: date-time
|
|
161
|
+
* confirmed_by:
|
|
162
|
+
* type: string
|
|
163
|
+
* description: "The unique identifier of the user or customer who confirmed the order edit."
|
|
164
|
+
* confirmed_at:
|
|
165
|
+
* type: string
|
|
166
|
+
* description: "The date with timezone at which the edit was confirmed."
|
|
167
|
+
* format: date-time
|
|
168
|
+
* declined_by:
|
|
169
|
+
* type: string
|
|
170
|
+
* description: "The unique identifier of the user or customer who declined the order edit."
|
|
171
|
+
* declined_at:
|
|
172
|
+
* type: string
|
|
173
|
+
* description: "The date with timezone at which the edit was declined."
|
|
174
|
+
* format: date-time
|
|
175
|
+
* declined_reason:
|
|
176
|
+
* description: "An optional note why the order edit is declined."
|
|
177
|
+
* type: string
|
|
178
|
+
* subtotal:
|
|
179
|
+
* type: integer
|
|
180
|
+
* description: The subtotal for line items computed from changes.
|
|
181
|
+
* example: 8000
|
|
182
|
+
* discount_total:
|
|
183
|
+
* type: integer
|
|
184
|
+
* description: The total of discount
|
|
185
|
+
* example: 800
|
|
186
|
+
* tax_total:
|
|
187
|
+
* type: integer
|
|
188
|
+
* description: The total of tax
|
|
189
|
+
* example: 0
|
|
190
|
+
* total:
|
|
191
|
+
* type: integer
|
|
192
|
+
* description: The total amount of the edited order.
|
|
193
|
+
* example: 8200
|
|
194
|
+
* difference_due:
|
|
195
|
+
* type: integer
|
|
196
|
+
* description: The difference between the total amount of the order and total amount of edited order.
|
|
197
|
+
* example: 8200
|
|
198
|
+
* items:
|
|
199
|
+
* type: array
|
|
200
|
+
* description: Computed line items from the changes.
|
|
201
|
+
* items:
|
|
202
|
+
* $ref: "#/components/schemas/line_item"
|
|
203
|
+
*/
|
|
204
|
+
//# sourceMappingURL=order-edit.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"order-edit.js","sourceRoot":"","sources":["../../src/models/order-edit.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;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AI,EAAE,CAAC;kCAChD,IAAI;mDAAA;IAGnB;QADC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;kDACP;IAGpB;QADC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sDACH;IAGxB;QADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,IAAA,+BAAa,EAAC,aAAa,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;kCACjD,IAAI;kDAAA;IAGlB;QADC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;kDACP;IAGpB;QADC,IAAA,gBAAM,EAAC,EAAE,IAAI,EAAE,IAAA,+BAAa,EAAC,aAAa,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;kCACjD,IAAI;QAElB,WAAW;;kDAFO;IAYlB;QADC,IAAA,sBAAY,GAAE;;;;iDAGd;IA1DU,SAAS;QADrB,IAAA,2CAAiB,EAAC,uBAAuB,CAAC,GAAG,CAAC;OAClC,SAAS,CA2DrB;IAAD,gBAAC;CAAA,AA3DD,CAA+B,gCAAmB,GA2DjD;AA3DY,8BAAS;AA6DtB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmFG"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { SoftDeletableEntity } from "../interfaces";
|
|
2
|
+
import { OrderEdit } from "./order-edit";
|
|
3
|
+
import { LineItem } from "./line-item";
|
|
4
|
+
export declare enum OrderEditItemChangeType {
|
|
5
|
+
ITEM_ADD = "item_add",
|
|
6
|
+
ITEM_REMOVE = "item_remove",
|
|
7
|
+
ITEM_UPDATE = "item_update"
|
|
8
|
+
}
|
|
9
|
+
export declare class OrderItemChange extends SoftDeletableEntity {
|
|
10
|
+
type: OrderEditItemChangeType;
|
|
11
|
+
order_edit_id: string;
|
|
12
|
+
order_edit: OrderEdit;
|
|
13
|
+
original_line_item_id?: string;
|
|
14
|
+
original_line_item?: LineItem;
|
|
15
|
+
line_item_id?: string;
|
|
16
|
+
line_item?: LineItem;
|
|
17
|
+
private beforeInsert;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* @schema order_item_change
|
|
21
|
+
* title: "Order Item Change"
|
|
22
|
+
* description: "Represents an order edit item change"
|
|
23
|
+
* x-resourceId: order_item_change
|
|
24
|
+
* required:
|
|
25
|
+
* - type
|
|
26
|
+
* - order_edit_id
|
|
27
|
+
* properties:
|
|
28
|
+
* id:
|
|
29
|
+
* type: string
|
|
30
|
+
* description: The order item change's ID
|
|
31
|
+
* example: oic_01G8TJSYT9M6AVS5N4EMNFS1EK
|
|
32
|
+
* type:
|
|
33
|
+
* type: string
|
|
34
|
+
* description: The order's status
|
|
35
|
+
* enum:
|
|
36
|
+
* - item_add
|
|
37
|
+
* - item_remove
|
|
38
|
+
* - item_update
|
|
39
|
+
* order_edit_id:
|
|
40
|
+
* type: string
|
|
41
|
+
* description: The ID of the order edit
|
|
42
|
+
* example: oe_01G2SG30J8C85S4A5CHM2S1NS2
|
|
43
|
+
* order_edit:
|
|
44
|
+
* description: Order edit object
|
|
45
|
+
* $ref: "#/components/schemas/order_edit"
|
|
46
|
+
* original_line_item_id:
|
|
47
|
+
* type: string
|
|
48
|
+
* description: The ID of the original line item in the order
|
|
49
|
+
* example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN
|
|
50
|
+
* original_line_item:
|
|
51
|
+
* description: Original line item object.
|
|
52
|
+
* $ref: "#/components/schemas/line_item"
|
|
53
|
+
* line_item_id:
|
|
54
|
+
* type: string
|
|
55
|
+
* description: The ID of the cloned line item.
|
|
56
|
+
* example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN
|
|
57
|
+
* line_item:
|
|
58
|
+
* description: Line item object.
|
|
59
|
+
* $ref: "#/components/schemas/line_item"
|
|
60
|
+
*/
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
|
3
|
+
var extendStatics = function (d, b) {
|
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
+
return extendStatics(d, b);
|
|
8
|
+
};
|
|
9
|
+
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
+
extendStatics(d, b);
|
|
13
|
+
function __() { this.constructor = d; }
|
|
14
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
+
};
|
|
16
|
+
})();
|
|
17
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
18
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
19
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
20
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
21
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
22
|
+
};
|
|
23
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
24
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
25
|
+
};
|
|
26
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
27
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
28
|
+
};
|
|
29
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
30
|
+
exports.OrderItemChange = exports.OrderEditItemChangeType = void 0;
|
|
31
|
+
var typeorm_1 = require("typeorm");
|
|
32
|
+
var interfaces_1 = require("../interfaces");
|
|
33
|
+
var order_editing_1 = __importDefault(require("../loaders/feature-flags/order-editing"));
|
|
34
|
+
var feature_flag_decorators_1 = require("../utils/feature-flag-decorators");
|
|
35
|
+
var utils_1 = require("../utils");
|
|
36
|
+
var db_aware_column_1 = require("../utils/db-aware-column");
|
|
37
|
+
var order_edit_1 = require("./order-edit");
|
|
38
|
+
var line_item_1 = require("./line-item");
|
|
39
|
+
var OrderEditItemChangeType;
|
|
40
|
+
(function (OrderEditItemChangeType) {
|
|
41
|
+
OrderEditItemChangeType["ITEM_ADD"] = "item_add";
|
|
42
|
+
OrderEditItemChangeType["ITEM_REMOVE"] = "item_remove";
|
|
43
|
+
OrderEditItemChangeType["ITEM_UPDATE"] = "item_update";
|
|
44
|
+
})(OrderEditItemChangeType = exports.OrderEditItemChangeType || (exports.OrderEditItemChangeType = {}));
|
|
45
|
+
var OrderItemChange = /** @class */ (function (_super) {
|
|
46
|
+
__extends(OrderItemChange, _super);
|
|
47
|
+
function OrderItemChange() {
|
|
48
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
49
|
+
}
|
|
50
|
+
OrderItemChange.prototype.beforeInsert = function () {
|
|
51
|
+
this.id = (0, utils_1.generateEntityId)(this.id, "oic");
|
|
52
|
+
};
|
|
53
|
+
__decorate([
|
|
54
|
+
(0, db_aware_column_1.DbAwareColumn)({
|
|
55
|
+
type: "enum",
|
|
56
|
+
enum: OrderEditItemChangeType,
|
|
57
|
+
}),
|
|
58
|
+
__metadata("design:type", String)
|
|
59
|
+
], OrderItemChange.prototype, "type", void 0);
|
|
60
|
+
__decorate([
|
|
61
|
+
(0, typeorm_1.Column)(),
|
|
62
|
+
__metadata("design:type", String)
|
|
63
|
+
], OrderItemChange.prototype, "order_edit_id", void 0);
|
|
64
|
+
__decorate([
|
|
65
|
+
(0, typeorm_1.ManyToOne)(function () { return order_edit_1.OrderEdit; }, function (oe) { return oe.changes; }),
|
|
66
|
+
(0, typeorm_1.JoinColumn)({ name: "order_edit_id" }),
|
|
67
|
+
__metadata("design:type", order_edit_1.OrderEdit)
|
|
68
|
+
], OrderItemChange.prototype, "order_edit", void 0);
|
|
69
|
+
__decorate([
|
|
70
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
71
|
+
__metadata("design:type", String)
|
|
72
|
+
], OrderItemChange.prototype, "original_line_item_id", void 0);
|
|
73
|
+
__decorate([
|
|
74
|
+
(0, typeorm_1.ManyToOne)(function () { return line_item_1.LineItem; }, { nullable: true }),
|
|
75
|
+
(0, typeorm_1.JoinColumn)({ name: "original_line_item_id" }),
|
|
76
|
+
__metadata("design:type", line_item_1.LineItem)
|
|
77
|
+
], OrderItemChange.prototype, "original_line_item", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
80
|
+
__metadata("design:type", String)
|
|
81
|
+
], OrderItemChange.prototype, "line_item_id", void 0);
|
|
82
|
+
__decorate([
|
|
83
|
+
(0, typeorm_1.OneToOne)(function () { return line_item_1.LineItem; }, { nullable: true }),
|
|
84
|
+
(0, typeorm_1.JoinColumn)({ name: "line_item_id" }),
|
|
85
|
+
__metadata("design:type", line_item_1.LineItem)
|
|
86
|
+
], OrderItemChange.prototype, "line_item", void 0);
|
|
87
|
+
__decorate([
|
|
88
|
+
(0, typeorm_1.BeforeInsert)(),
|
|
89
|
+
__metadata("design:type", Function),
|
|
90
|
+
__metadata("design:paramtypes", []),
|
|
91
|
+
__metadata("design:returntype", void 0)
|
|
92
|
+
], OrderItemChange.prototype, "beforeInsert", null);
|
|
93
|
+
OrderItemChange = __decorate([
|
|
94
|
+
(0, feature_flag_decorators_1.FeatureFlagEntity)(order_editing_1.default.key),
|
|
95
|
+
(0, typeorm_1.Unique)(["order_edit_id", "original_line_item_id"]),
|
|
96
|
+
(0, typeorm_1.Unique)(["order_edit_id", "line_item_id"])
|
|
97
|
+
], OrderItemChange);
|
|
98
|
+
return OrderItemChange;
|
|
99
|
+
}(interfaces_1.SoftDeletableEntity));
|
|
100
|
+
exports.OrderItemChange = OrderItemChange;
|
|
101
|
+
/**
|
|
102
|
+
* @schema order_item_change
|
|
103
|
+
* title: "Order Item Change"
|
|
104
|
+
* description: "Represents an order edit item change"
|
|
105
|
+
* x-resourceId: order_item_change
|
|
106
|
+
* required:
|
|
107
|
+
* - type
|
|
108
|
+
* - order_edit_id
|
|
109
|
+
* properties:
|
|
110
|
+
* id:
|
|
111
|
+
* type: string
|
|
112
|
+
* description: The order item change's ID
|
|
113
|
+
* example: oic_01G8TJSYT9M6AVS5N4EMNFS1EK
|
|
114
|
+
* type:
|
|
115
|
+
* type: string
|
|
116
|
+
* description: The order's status
|
|
117
|
+
* enum:
|
|
118
|
+
* - item_add
|
|
119
|
+
* - item_remove
|
|
120
|
+
* - item_update
|
|
121
|
+
* order_edit_id:
|
|
122
|
+
* type: string
|
|
123
|
+
* description: The ID of the order edit
|
|
124
|
+
* example: oe_01G2SG30J8C85S4A5CHM2S1NS2
|
|
125
|
+
* order_edit:
|
|
126
|
+
* description: Order edit object
|
|
127
|
+
* $ref: "#/components/schemas/order_edit"
|
|
128
|
+
* original_line_item_id:
|
|
129
|
+
* type: string
|
|
130
|
+
* description: The ID of the original line item in the order
|
|
131
|
+
* example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN
|
|
132
|
+
* original_line_item:
|
|
133
|
+
* description: Original line item object.
|
|
134
|
+
* $ref: "#/components/schemas/line_item"
|
|
135
|
+
* line_item_id:
|
|
136
|
+
* type: string
|
|
137
|
+
* description: The ID of the cloned line item.
|
|
138
|
+
* example: item_01G8ZC9GWT6B2GP5FSXRXNFNGN
|
|
139
|
+
* line_item:
|
|
140
|
+
* description: Line item object.
|
|
141
|
+
* $ref: "#/components/schemas/line_item"
|
|
142
|
+
*/
|
|
143
|
+
//# sourceMappingURL=order-item-change.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+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AAQ,EAAE,IAAI,EAAE,CAAC;;yDACN;IAIrB;QAFC,IAAA,kBAAQ,EAAC,cAAM,OAAA,oBAAQ,EAAR,CAAQ,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;QAC5C,IAAA,oBAAU,EAAC,EAAE,IAAI,EAAE,cAAc,EAAE,CAAC;kCACzB,oBAAQ;sDAAA;IAGpB;QADC,IAAA,sBAAY,GAAE;;;;uDAGd;IA/BU,eAAe;QAH3B,IAAA,2CAAiB,EAAC,uBAAuB,CAAC,GAAG,CAAC;QAC9C,IAAA,gBAAM,EAAC,CAAC,eAAe,EAAE,uBAAuB,CAAC,CAAC;QAClD,IAAA,gBAAM,EAAC,CAAC,eAAe,EAAE,cAAc,CAAC,CAAC;OAC7B,eAAe,CAgC3B;IAAD,sBAAC;CAAA,AAhCD,CAAqC,gCAAmB,GAgCvD;AAhCY,0CAAe;AAkC5B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG"}
|
package/dist/models/order.d.ts
CHANGED
|
@@ -17,6 +17,7 @@ import { Return } from "./return";
|
|
|
17
17
|
import { SalesChannel } from "./sales-channel";
|
|
18
18
|
import { ShippingMethod } from "./shipping-method";
|
|
19
19
|
import { Swap } from "./swap";
|
|
20
|
+
import { OrderEdit } from "./order-edit";
|
|
20
21
|
export declare enum OrderStatus {
|
|
21
22
|
PENDING = "pending",
|
|
22
23
|
COMPLETED = "completed",
|
|
@@ -75,6 +76,7 @@ export declare class Order extends BaseEntity {
|
|
|
75
76
|
swaps: Swap[];
|
|
76
77
|
draft_order_id: string;
|
|
77
78
|
draft_order: DraftOrder;
|
|
79
|
+
edits: OrderEdit[];
|
|
78
80
|
items: LineItem[];
|
|
79
81
|
gift_card_transactions: GiftCardTransaction[];
|
|
80
82
|
canceled_at: Date;
|
|
@@ -267,6 +269,11 @@ export declare class Order extends BaseEntity {
|
|
|
267
269
|
* description: The line items that belong to the order. Available if the relation `items` is expanded.
|
|
268
270
|
* items:
|
|
269
271
|
* $ref: "#/components/schemas/line_item"
|
|
272
|
+
* edits:
|
|
273
|
+
* type: array
|
|
274
|
+
* description: [EXPERIMENTAL] Order edits done on the order. Available if the relation `edits` is expanded.
|
|
275
|
+
* items:
|
|
276
|
+
* $ref: "#/components/schemas/order_edit"
|
|
270
277
|
* gift_card_transactions:
|
|
271
278
|
* type: array
|
|
272
279
|
* description: The gift card transactions used in the order. Available if the relation `gift_card_transactions` is expanded.
|
package/dist/models/order.js
CHANGED
|
@@ -59,6 +59,9 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
59
59
|
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
60
60
|
}
|
|
61
61
|
};
|
|
62
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
63
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
64
|
+
};
|
|
62
65
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
63
66
|
exports.Order = exports.PaymentStatus = exports.FulfillmentStatus = exports.OrderStatus = void 0;
|
|
64
67
|
var typeorm_1 = require("typeorm");
|
|
@@ -85,6 +88,8 @@ var shipping_method_1 = require("./shipping-method");
|
|
|
85
88
|
var swap_1 = require("./swap");
|
|
86
89
|
var generate_entity_id_1 = require("../utils/generate-entity-id");
|
|
87
90
|
var manual_auto_increment_1 = require("../utils/manual-auto-increment");
|
|
91
|
+
var order_edit_1 = require("./order-edit");
|
|
92
|
+
var order_editing_1 = __importDefault(require("../loaders/feature-flags/order-editing"));
|
|
88
93
|
var OrderStatus;
|
|
89
94
|
(function (OrderStatus) {
|
|
90
95
|
OrderStatus["PENDING"] = "pending";
|
|
@@ -302,6 +307,12 @@ var Order = /** @class */ (function (_super) {
|
|
|
302
307
|
(0, typeorm_1.JoinColumn)({ name: "draft_order_id" }),
|
|
303
308
|
__metadata("design:type", draft_order_1.DraftOrder)
|
|
304
309
|
], Order.prototype, "draft_order", void 0);
|
|
310
|
+
__decorate([
|
|
311
|
+
(0, feature_flag_decorators_1.FeatureFlagDecorators)(order_editing_1.default.key, [
|
|
312
|
+
(0, typeorm_1.OneToMany)(function () { return order_edit_1.OrderEdit; }, function (oe) { return oe.order; }),
|
|
313
|
+
]),
|
|
314
|
+
__metadata("design:type", Array)
|
|
315
|
+
], Order.prototype, "edits", void 0);
|
|
305
316
|
__decorate([
|
|
306
317
|
(0, typeorm_1.OneToMany)(function () { return line_item_1.LineItem; }, function (lineItem) { return lineItem.order; }, {
|
|
307
318
|
cascade: ["insert"],
|
|
@@ -528,6 +539,11 @@ exports.Order = Order;
|
|
|
528
539
|
* description: The line items that belong to the order. Available if the relation `items` is expanded.
|
|
529
540
|
* items:
|
|
530
541
|
* $ref: "#/components/schemas/line_item"
|
|
542
|
+
* edits:
|
|
543
|
+
* type: array
|
|
544
|
+
* description: [EXPERIMENTAL] Order edits done on the order. Available if the relation `edits` is expanded.
|
|
545
|
+
* items:
|
|
546
|
+
* $ref: "#/components/schemas/order_edit"
|
|
531
547
|
* gift_card_transactions:
|
|
532
548
|
* type: array
|
|
533
549
|
* description: The gift card transactions used in the order. Available if the relation `gift_card_transactions` is expanded.
|
package/dist/models/order.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"order.js","sourceRoot":"","sources":["../../src/models/order.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"order.js","sourceRoot":"","sources":["../../src/models/order.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,mCAYgB;AAChB,4DAIiC;AACjC,4EAGyC;AAEzC,qCAAmC;AACnC,gEAA6D;AAC7D,+BAA6B;AAC7B,6CAA0C;AAC1C,uCAAqC;AACrC,uCAAqC;AACrC,uCAAqC;AACrC,6CAA0C;AAC1C,6CAA2C;AAC3C,yCAAsC;AACtC,iEAA6D;AAC7D,yCAAsC;AACtC,qCAAmC;AACn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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsPG"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
|
3
|
+
var extendStatics = function (d, b) {
|
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
+
return extendStatics(d, b);
|
|
8
|
+
};
|
|
9
|
+
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
+
extendStatics(d, b);
|
|
13
|
+
function __() { this.constructor = d; }
|
|
14
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
+
};
|
|
16
|
+
})();
|
|
17
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
18
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
19
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
20
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
21
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
22
|
+
};
|
|
23
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
24
|
+
exports.OrderEditRepository = void 0;
|
|
25
|
+
var typeorm_1 = require("typeorm");
|
|
26
|
+
var order_edit_1 = require("../models/order-edit");
|
|
27
|
+
var OrderEditRepository = /** @class */ (function (_super) {
|
|
28
|
+
__extends(OrderEditRepository, _super);
|
|
29
|
+
function OrderEditRepository() {
|
|
30
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
31
|
+
}
|
|
32
|
+
OrderEditRepository = __decorate([
|
|
33
|
+
(0, typeorm_1.EntityRepository)(order_edit_1.OrderEdit)
|
|
34
|
+
], OrderEditRepository);
|
|
35
|
+
return OrderEditRepository;
|
|
36
|
+
}(typeorm_1.Repository));
|
|
37
|
+
exports.OrderEditRepository = OrderEditRepository;
|
|
38
|
+
//# sourceMappingURL=order-edit.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"order-edit.js","sourceRoot":"","sources":["../../src/repositories/order-edit.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,mCAAsD;AAEtD,mDAAgD;AAGhD;IAAyC,uCAAqB;IAA9D;;IAAgE,CAAC;IAApD,mBAAmB;QAD/B,IAAA,0BAAgB,EAAC,sBAAS,CAAC;OACf,mBAAmB,CAAiC;IAAD,0BAAC;CAAA,AAAjE,CAAyC,oBAAU,GAAc;AAApD,kDAAmB"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __extends = (this && this.__extends) || (function () {
|
|
3
|
+
var extendStatics = function (d, b) {
|
|
4
|
+
extendStatics = Object.setPrototypeOf ||
|
|
5
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
+
return extendStatics(d, b);
|
|
8
|
+
};
|
|
9
|
+
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
12
|
+
extendStatics(d, b);
|
|
13
|
+
function __() { this.constructor = d; }
|
|
14
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
15
|
+
};
|
|
16
|
+
})();
|
|
17
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
18
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
19
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
20
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
21
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
22
|
+
};
|
|
23
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
24
|
+
exports.OrderItemChangeRepository = void 0;
|
|
25
|
+
var typeorm_1 = require("typeorm");
|
|
26
|
+
var order_item_change_1 = require("../models/order-item-change");
|
|
27
|
+
var OrderItemChangeRepository = /** @class */ (function (_super) {
|
|
28
|
+
__extends(OrderItemChangeRepository, _super);
|
|
29
|
+
function OrderItemChangeRepository() {
|
|
30
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
31
|
+
}
|
|
32
|
+
OrderItemChangeRepository = __decorate([
|
|
33
|
+
(0, typeorm_1.EntityRepository)(order_item_change_1.OrderItemChange)
|
|
34
|
+
], OrderItemChangeRepository);
|
|
35
|
+
return OrderItemChangeRepository;
|
|
36
|
+
}(typeorm_1.Repository));
|
|
37
|
+
exports.OrderItemChangeRepository = OrderItemChangeRepository;
|
|
38
|
+
//# sourceMappingURL=order-item-change.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"order-item-change.js","sourceRoot":"","sources":["../../src/repositories/order-item-change.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAAA,mCAAsD;AAEtD,iEAA6D;AAG7D;IAA+C,6CAA2B;IAA1E;;IAA4E,CAAC;IAAhE,yBAAyB;QADrC,IAAA,0BAAgB,EAAC,mCAAe,CAAC;OACrB,yBAAyB,CAAuC;IAAD,gCAAC;CAAA,AAA7E,CAA+C,oBAAU,GAAoB;AAAhE,8DAAyB"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|