@felloh-org/lambda-wrapper 1.10.13 → 1.10.15
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.
|
@@ -11,7 +11,7 @@ var _transaction = _interopRequireDefault(require("../../payment/transaction"));
|
|
|
11
11
|
|
|
12
12
|
var _account = _interopRequireDefault(require("../account"));
|
|
13
13
|
|
|
14
|
-
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6;
|
|
14
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8;
|
|
15
15
|
|
|
16
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
17
|
|
|
@@ -40,7 +40,14 @@ let SettledTransaction = (_dec = (0, _typeorm.Entity)({
|
|
|
40
40
|
}), _dec8 = (0, _typeorm.ManyToOne)(() => _account.default), _dec9 = (0, _typeorm.JoinColumn)({
|
|
41
41
|
name: 'counterparty_iban',
|
|
42
42
|
referencedColumnName: 'iban'
|
|
43
|
-
}), _dec10 = (0, _typeorm.
|
|
43
|
+
}), _dec10 = (0, _typeorm.Column)({
|
|
44
|
+
type: "int",
|
|
45
|
+
nullable: true
|
|
46
|
+
}), _dec11 = (0, _typeorm.Column)({
|
|
47
|
+
type: "varchar",
|
|
48
|
+
length: "5",
|
|
49
|
+
nullable: true
|
|
50
|
+
}), _dec12 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class SettledTransaction {
|
|
44
51
|
constructor() {
|
|
45
52
|
_initializerDefineProperty(this, "transaction", _descriptor, this);
|
|
46
53
|
|
|
@@ -52,7 +59,11 @@ let SettledTransaction = (_dec = (0, _typeorm.Entity)({
|
|
|
52
59
|
|
|
53
60
|
_initializerDefineProperty(this, "counterparty_iban", _descriptor5, this);
|
|
54
61
|
|
|
55
|
-
_initializerDefineProperty(this, "
|
|
62
|
+
_initializerDefineProperty(this, "settlement_amount", _descriptor6, this);
|
|
63
|
+
|
|
64
|
+
_initializerDefineProperty(this, "settlement_currency", _descriptor7, this);
|
|
65
|
+
|
|
66
|
+
_initializerDefineProperty(this, "created_at", _descriptor8, this);
|
|
56
67
|
}
|
|
57
68
|
|
|
58
69
|
}, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "transaction", [_dec2, _dec3], {
|
|
@@ -88,7 +99,17 @@ let SettledTransaction = (_dec = (0, _typeorm.Entity)({
|
|
|
88
99
|
initializer: function () {
|
|
89
100
|
return _account.default;
|
|
90
101
|
}
|
|
91
|
-
}), _descriptor6 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
102
|
+
}), _descriptor6 = _applyDecoratedDescriptor(_class2.prototype, "settlement_amount", [_dec10], {
|
|
103
|
+
configurable: true,
|
|
104
|
+
enumerable: true,
|
|
105
|
+
writable: true,
|
|
106
|
+
initializer: null
|
|
107
|
+
}), _descriptor7 = _applyDecoratedDescriptor(_class2.prototype, "settlement_currency", [_dec11], {
|
|
108
|
+
configurable: true,
|
|
109
|
+
enumerable: true,
|
|
110
|
+
writable: true,
|
|
111
|
+
initializer: null
|
|
112
|
+
}), _descriptor8 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec12], {
|
|
92
113
|
configurable: true,
|
|
93
114
|
enumerable: true,
|
|
94
115
|
writable: true,
|
|
@@ -33,7 +33,9 @@ var _ecommerce = _interopRequireDefault(require("../ecommerce"));
|
|
|
33
33
|
|
|
34
34
|
var _currency = require("../../bank/currency");
|
|
35
35
|
|
|
36
|
-
var
|
|
36
|
+
var _settledTransaction = _interopRequireDefault(require("../../bank/settled-transaction"));
|
|
37
|
+
|
|
38
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _dec13, _dec14, _dec15, _dec16, _dec17, _dec18, _dec19, _dec20, _dec21, _dec22, _dec23, _dec24, _dec25, _dec26, _dec27, _dec28, _dec29, _dec30, _dec31, _dec32, _dec33, _dec34, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10, _descriptor11, _descriptor12, _descriptor13, _descriptor14, _descriptor15, _descriptor16, _descriptor17, _descriptor18, _descriptor19, _descriptor20, _descriptor21, _descriptor22, _descriptor23;
|
|
37
39
|
|
|
38
40
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
39
41
|
|
|
@@ -112,7 +114,7 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
112
114
|
}), _dec32 = (0, _typeorm.OneToMany)(() => _transactionBatch.default, transactionBatch => transactionBatch.transaction), _dec33 = (0, _typeorm.Column)({
|
|
113
115
|
type: "timestamp with time zone",
|
|
114
116
|
nullable: true
|
|
115
|
-
}), _dec(_class = (_class2 = class Transaction {
|
|
117
|
+
}), _dec34 = (0, _typeorm.OneToOne)(() => _settledTransaction.default, settledTransaction => settledTransaction.transaction), _dec(_class = (_class2 = class Transaction {
|
|
116
118
|
constructor() {
|
|
117
119
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
118
120
|
|
|
@@ -157,6 +159,8 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
157
159
|
_initializerDefineProperty(this, "batch", _descriptor21, this);
|
|
158
160
|
|
|
159
161
|
_initializerDefineProperty(this, "assigned_at", _descriptor22, this);
|
|
162
|
+
|
|
163
|
+
_initializerDefineProperty(this, "settlement", _descriptor23, this);
|
|
160
164
|
}
|
|
161
165
|
|
|
162
166
|
getPublicData() {
|
|
@@ -179,6 +183,10 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
179
183
|
assigned_at: this.assigned_at
|
|
180
184
|
};
|
|
181
185
|
|
|
186
|
+
if (this.settlement !== null && typeof this.settlement !== 'undefined') {
|
|
187
|
+
response.settlement = this.settlement;
|
|
188
|
+
}
|
|
189
|
+
|
|
182
190
|
if (this.booking !== null && typeof this.booking.id !== 'undefined' && typeof this.booking.getPublicData === 'function') {
|
|
183
191
|
response.booking = this.booking.getPublicData();
|
|
184
192
|
}
|
|
@@ -226,6 +234,10 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
226
234
|
assigned_at: this.assigned_at
|
|
227
235
|
};
|
|
228
236
|
|
|
237
|
+
if (this.settlement !== null && typeof this.settlement !== 'undefined') {
|
|
238
|
+
response.settlement = this.settlement;
|
|
239
|
+
}
|
|
240
|
+
|
|
229
241
|
if (this.booking !== null && typeof this.booking.id !== 'undefined' && typeof this.booking.getPublicCompactData === 'function') {
|
|
230
242
|
response.booking = this.booking.getPublicCompactData();
|
|
231
243
|
}
|
|
@@ -395,5 +407,10 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
395
407
|
enumerable: true,
|
|
396
408
|
writable: true,
|
|
397
409
|
initializer: null
|
|
410
|
+
}), _descriptor23 = _applyDecoratedDescriptor(_class2.prototype, "settlement", [_dec34], {
|
|
411
|
+
configurable: true,
|
|
412
|
+
enumerable: true,
|
|
413
|
+
writable: true,
|
|
414
|
+
initializer: null
|
|
398
415
|
})), _class2)) || _class);
|
|
399
416
|
exports.default = Transaction;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
const { MigrationInterface, QueryRunner } = require("typeorm");
|
|
2
|
+
|
|
3
|
+
module.exports = class bankSetlementAmountAndCurrency1686303842122 {
|
|
4
|
+
name = 'bankSetlementAmountAndCurrency1686303842122'
|
|
5
|
+
|
|
6
|
+
async up(queryRunner) {
|
|
7
|
+
await queryRunner.query(`ALTER TABLE "bank"."settled_transaction"
|
|
8
|
+
ADD "settlement_amount" integer`);
|
|
9
|
+
await queryRunner.query(`ALTER TABLE "bank"."settled_transaction"
|
|
10
|
+
ADD "settlement_currency" character varying(5)`);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
async down(queryRunner) {
|
|
14
|
+
await queryRunner.query(`ALTER TABLE "bank"."settled_transaction" DROP COLUMN "settlement_currency"`);
|
|
15
|
+
await queryRunner.query(`ALTER TABLE "bank"."settled_transaction" DROP COLUMN "settlement_amount"`);
|
|
16
|
+
}
|
|
17
|
+
}
|