@collctiv/l2s-models 1.0.107 → 1.0.109
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/dist/entities/refund.d.ts +29 -0
- package/dist/entities/refund.d.ts.map +1 -0
- package/dist/entities/refund.js +67 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { IDataEntity, ICreatable, IModifiable } from "../global/interfaces.js";
|
|
2
|
+
export declare class Refund implements IDataEntity, ICreatable, IModifiable {
|
|
3
|
+
id: string;
|
|
4
|
+
create_date: Date;
|
|
5
|
+
modified_date: Date | null;
|
|
6
|
+
amount: number;
|
|
7
|
+
user_id: string;
|
|
8
|
+
payment_id: string;
|
|
9
|
+
pot_id: string;
|
|
10
|
+
status: RefundStatus;
|
|
11
|
+
amount_remaining_to_refund: number;
|
|
12
|
+
reason: RefundReason;
|
|
13
|
+
comments: string;
|
|
14
|
+
constructor(args?: Partial<Refund>);
|
|
15
|
+
}
|
|
16
|
+
export declare enum RefundStatus {
|
|
17
|
+
New = "new",
|
|
18
|
+
InProgress = "in_progress",
|
|
19
|
+
Failed = "failed",
|
|
20
|
+
Completed = "completed",
|
|
21
|
+
Cancelled = "cancelled"
|
|
22
|
+
}
|
|
23
|
+
export declare enum RefundReason {
|
|
24
|
+
CustomerRequested = "customer_requested",
|
|
25
|
+
AccountClosure = "account_closure",
|
|
26
|
+
Other = "other",
|
|
27
|
+
Dispute = "dispute"
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=refund.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refund.d.ts","sourceRoot":"","sources":["../../entities/refund.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGpF,qBAEa,MAAO,YAAW,WAAW,EAAE,UAAU,EAAE,WAAW;IAExD,EAAE,EAAE,MAAM,CAAC;IACX,WAAW,EAAE,IAAI,CAAc;IAC/B,aAAa,EAAE,IAAI,GAAG,IAAI,CAAC;IAC3B,MAAM,EAAE,MAAM,CAAK;IAGnB,OAAO,EAAE,MAAM,CAAC;IAGhB,UAAU,EAAE,MAAM,CAAC;IAGnB,MAAM,EAAE,MAAM,CAAC;IAGf,MAAM,EAAE,YAAY,CAAoB;IAGxC,0BAA0B,EAAE,MAAM,CAAK;IAEvC,MAAM,EAAE,YAAY,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;gBAEL,IAAI,GAAE,OAAO,CAAC,MAAM,CAAM;CAGhD;AAED,oBAAY,YAAY;IACpB,GAAG,QAAQ;IACX,UAAU,gBAAgB;IAC1B,MAAM,WAAW;IACjB,SAAS,cAAc;IACvB,SAAS,cAAc;CAC1B;AAED,oBAAY,YAAY;IACpB,iBAAiB,uBAAuB;IACxC,cAAc,oBAAoB;IAClC,KAAK,UAAU;IACf,OAAO,YAAY;CACtB"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
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;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Collection, Updatable, ObjectId, Topic } from "../global/decorators.js";
|
|
11
|
+
let Refund = class Refund {
|
|
12
|
+
id;
|
|
13
|
+
create_date = new Date();
|
|
14
|
+
modified_date;
|
|
15
|
+
amount = 0;
|
|
16
|
+
user_id;
|
|
17
|
+
payment_id;
|
|
18
|
+
pot_id;
|
|
19
|
+
status = RefundStatus.New;
|
|
20
|
+
amount_remaining_to_refund = 0;
|
|
21
|
+
reason;
|
|
22
|
+
comments;
|
|
23
|
+
constructor(args = {}) {
|
|
24
|
+
Object.assign(this, args);
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
__decorate([
|
|
28
|
+
ObjectId(),
|
|
29
|
+
__metadata("design:type", String)
|
|
30
|
+
], Refund.prototype, "user_id", void 0);
|
|
31
|
+
__decorate([
|
|
32
|
+
ObjectId(),
|
|
33
|
+
__metadata("design:type", String)
|
|
34
|
+
], Refund.prototype, "payment_id", void 0);
|
|
35
|
+
__decorate([
|
|
36
|
+
ObjectId(),
|
|
37
|
+
__metadata("design:type", String)
|
|
38
|
+
], Refund.prototype, "pot_id", void 0);
|
|
39
|
+
__decorate([
|
|
40
|
+
Updatable(),
|
|
41
|
+
__metadata("design:type", String)
|
|
42
|
+
], Refund.prototype, "status", void 0);
|
|
43
|
+
__decorate([
|
|
44
|
+
Updatable(),
|
|
45
|
+
__metadata("design:type", Number)
|
|
46
|
+
], Refund.prototype, "amount_remaining_to_refund", void 0);
|
|
47
|
+
Refund = __decorate([
|
|
48
|
+
Collection("refunds"),
|
|
49
|
+
Topic("refunds"),
|
|
50
|
+
__metadata("design:paramtypes", [Object])
|
|
51
|
+
], Refund);
|
|
52
|
+
export { Refund };
|
|
53
|
+
export var RefundStatus;
|
|
54
|
+
(function (RefundStatus) {
|
|
55
|
+
RefundStatus["New"] = "new";
|
|
56
|
+
RefundStatus["InProgress"] = "in_progress";
|
|
57
|
+
RefundStatus["Failed"] = "failed";
|
|
58
|
+
RefundStatus["Completed"] = "completed";
|
|
59
|
+
RefundStatus["Cancelled"] = "cancelled";
|
|
60
|
+
})(RefundStatus || (RefundStatus = {}));
|
|
61
|
+
export var RefundReason;
|
|
62
|
+
(function (RefundReason) {
|
|
63
|
+
RefundReason["CustomerRequested"] = "customer_requested";
|
|
64
|
+
RefundReason["AccountClosure"] = "account_closure";
|
|
65
|
+
RefundReason["Other"] = "other";
|
|
66
|
+
RefundReason["Dispute"] = "dispute";
|
|
67
|
+
})(RefundReason || (RefundReason = {}));
|
package/dist/index.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ export * from "./entities/order.js";
|
|
|
11
11
|
export * from "./entities/payment.js";
|
|
12
12
|
export * from "./entities/paymentRequest.js";
|
|
13
13
|
export * from "./entities/pot.js";
|
|
14
|
+
export * from "./entities/refund.js";
|
|
14
15
|
export * from "./entities/settings.js";
|
|
15
16
|
export * from "./entities/token.js";
|
|
16
17
|
export * from "./entities/user.js";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AACA,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,uBAAuB,CAAC;AACtC,cAAc,wBAAwB,CAAC;AACvC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AAEnC,cAAc,2BAA2B,CAAC;AAE1C,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC;AAClC,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AACA,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,uBAAuB,CAAC;AACtC,cAAc,wBAAwB,CAAC;AACvC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AAEnC,cAAc,2BAA2B,CAAC;AAE1C,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC;AAClC,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -11,6 +11,7 @@ export * from "./entities/order.js";
|
|
|
11
11
|
export * from "./entities/payment.js";
|
|
12
12
|
export * from "./entities/paymentRequest.js";
|
|
13
13
|
export * from "./entities/pot.js";
|
|
14
|
+
export * from "./entities/refund.js";
|
|
14
15
|
export * from "./entities/settings.js";
|
|
15
16
|
export * from "./entities/token.js";
|
|
16
17
|
export * from "./entities/user.js";
|