@felloh-org/lambda-wrapper 1.11.79 → 1.11.81
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/entity/aisp/gocardless-account/index.js +84 -0
- package/dist/entity/aisp/gocardless-requisition/index.js +41 -7
- package/dist/entity/aisp/index.js +3 -1
- package/dist/index.js +8 -0
- package/dist/migration/aisp/1710340812651-aisp_requisition.js +19 -0
- package/dist/migration/aisp/1710342798216-aisp_commenced_completed.js +15 -0
- package/dist/migration/aisp/1710349579447-aisp_account.js +17 -0
- package/package.json +1 -1
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _typeorm = require("typeorm");
|
|
9
|
+
|
|
10
|
+
var _account = _interopRequireDefault(require("../../bank/account"));
|
|
11
|
+
|
|
12
|
+
var _gocardlessRequisition = _interopRequireDefault(require("../gocardless-requisition"));
|
|
13
|
+
|
|
14
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5;
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
|
+
|
|
18
|
+
function _initializerDefineProperty(target, property, descriptor, context) { if (!descriptor) return; Object.defineProperty(target, property, { enumerable: descriptor.enumerable, configurable: descriptor.configurable, writable: descriptor.writable, value: descriptor.initializer ? descriptor.initializer.call(context) : void 0 }); }
|
|
19
|
+
|
|
20
|
+
function _applyDecoratedDescriptor(target, property, decorators, descriptor, context) { var desc = {}; Object.keys(descriptor).forEach(function (key) { desc[key] = descriptor[key]; }); desc.enumerable = !!desc.enumerable; desc.configurable = !!desc.configurable; if ('value' in desc || desc.initializer) { desc.writable = true; } desc = decorators.slice().reverse().reduce(function (desc, decorator) { return decorator(target, property, desc) || desc; }, desc); if (context && desc.initializer !== void 0) { desc.value = desc.initializer ? desc.initializer.call(context) : void 0; desc.initializer = undefined; } if (desc.initializer === void 0) { Object.defineProperty(target, property, desc); desc = null; } return desc; }
|
|
21
|
+
|
|
22
|
+
function _initializerWarningHelper(descriptor, context) { throw new Error('Decorating class property failed. Please ensure that ' + 'proposal-class-properties is enabled and runs after the decorators transform.'); }
|
|
23
|
+
|
|
24
|
+
let GoCardlessAccount = exports.default = (_dec = (0, _typeorm.Entity)({
|
|
25
|
+
name: 'gocardless_account',
|
|
26
|
+
schema: 'aisp'
|
|
27
|
+
}), _dec2 = (0, _typeorm.PrimaryColumn)({
|
|
28
|
+
type: "varchar",
|
|
29
|
+
length: "50"
|
|
30
|
+
}), _dec3 = (0, _typeorm.ManyToOne)(() => _account.default), _dec4 = (0, _typeorm.JoinColumn)({
|
|
31
|
+
name: 'iban',
|
|
32
|
+
referencedColumnName: 'iban'
|
|
33
|
+
}), _dec5 = (0, _typeorm.ManyToOne)(() => _gocardlessRequisition.default), _dec6 = (0, _typeorm.JoinColumn)({
|
|
34
|
+
name: 'requistion_id',
|
|
35
|
+
referencedColumnName: 'id'
|
|
36
|
+
}), _dec7 = (0, _typeorm.Column)({
|
|
37
|
+
type: "varchar",
|
|
38
|
+
nullable: true,
|
|
39
|
+
length: 50
|
|
40
|
+
}), _dec8 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class GoCardlessAccount {
|
|
41
|
+
constructor() {
|
|
42
|
+
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
43
|
+
|
|
44
|
+
_initializerDefineProperty(this, "account", _descriptor2, this);
|
|
45
|
+
|
|
46
|
+
_initializerDefineProperty(this, "requistion", _descriptor3, this);
|
|
47
|
+
|
|
48
|
+
_initializerDefineProperty(this, "status", _descriptor4, this);
|
|
49
|
+
|
|
50
|
+
_initializerDefineProperty(this, "created_at", _descriptor5, this);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
}, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "id", [_dec2], {
|
|
54
|
+
configurable: true,
|
|
55
|
+
enumerable: true,
|
|
56
|
+
writable: true,
|
|
57
|
+
initializer: function () {
|
|
58
|
+
return undefined;
|
|
59
|
+
}
|
|
60
|
+
}), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "account", [_dec3, _dec4], {
|
|
61
|
+
configurable: true,
|
|
62
|
+
enumerable: true,
|
|
63
|
+
writable: true,
|
|
64
|
+
initializer: function () {
|
|
65
|
+
return _account.default;
|
|
66
|
+
}
|
|
67
|
+
}), _descriptor3 = _applyDecoratedDescriptor(_class2.prototype, "requistion", [_dec5, _dec6], {
|
|
68
|
+
configurable: true,
|
|
69
|
+
enumerable: true,
|
|
70
|
+
writable: true,
|
|
71
|
+
initializer: function () {
|
|
72
|
+
return _gocardlessRequisition.default;
|
|
73
|
+
}
|
|
74
|
+
}), _descriptor4 = _applyDecoratedDescriptor(_class2.prototype, "status", [_dec7], {
|
|
75
|
+
configurable: true,
|
|
76
|
+
enumerable: true,
|
|
77
|
+
writable: true,
|
|
78
|
+
initializer: null
|
|
79
|
+
}), _descriptor5 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec8], {
|
|
80
|
+
configurable: true,
|
|
81
|
+
enumerable: true,
|
|
82
|
+
writable: true,
|
|
83
|
+
initializer: null
|
|
84
|
+
})), _class2)) || _class);
|
|
@@ -11,7 +11,9 @@ var _organisation = _interopRequireDefault(require("../../user/organisation"));
|
|
|
11
11
|
|
|
12
12
|
var _user = _interopRequireDefault(require("../../user/user"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _gocardlessAgreement = _interopRequireDefault(require("../gocardless-agreement"));
|
|
15
|
+
|
|
16
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8;
|
|
15
17
|
|
|
16
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
19
|
|
|
@@ -33,10 +35,19 @@ let Requisition = exports.default = (_dec = (0, _typeorm.Entity)({
|
|
|
33
35
|
}), _dec5 = (0, _typeorm.ManyToOne)(() => _user.default), _dec6 = (0, _typeorm.JoinColumn)({
|
|
34
36
|
name: 'user_id',
|
|
35
37
|
referencedColumnName: 'id'
|
|
36
|
-
}), _dec7 =
|
|
38
|
+
}), _dec7 = (0, _typeorm.ManyToOne)(() => _gocardlessAgreement.default), _dec8 = (0, _typeorm.JoinColumn)({
|
|
39
|
+
name: 'agreement_id',
|
|
40
|
+
referencedColumnName: 'id'
|
|
41
|
+
}), _dec9 = (0, _typeorm.Column)({
|
|
37
42
|
type: "boolean",
|
|
38
43
|
default: false
|
|
39
|
-
}),
|
|
44
|
+
}), _dec10 = (0, _typeorm.Column)({
|
|
45
|
+
type: "timestamp with time zone",
|
|
46
|
+
nullable: true
|
|
47
|
+
}), _dec11 = (0, _typeorm.Column)({
|
|
48
|
+
type: "timestamp with time zone",
|
|
49
|
+
nullable: true
|
|
50
|
+
}), _dec12 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class Requisition {
|
|
40
51
|
constructor() {
|
|
41
52
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
42
53
|
|
|
@@ -44,9 +55,15 @@ let Requisition = exports.default = (_dec = (0, _typeorm.Entity)({
|
|
|
44
55
|
|
|
45
56
|
_initializerDefineProperty(this, "user", _descriptor3, this);
|
|
46
57
|
|
|
47
|
-
_initializerDefineProperty(this, "
|
|
58
|
+
_initializerDefineProperty(this, "Agreement", _descriptor4, this);
|
|
59
|
+
|
|
60
|
+
_initializerDefineProperty(this, "is_complete", _descriptor5, this);
|
|
61
|
+
|
|
62
|
+
_initializerDefineProperty(this, "initial_scrape_commenced_at", _descriptor6, this);
|
|
63
|
+
|
|
64
|
+
_initializerDefineProperty(this, "initial_scrape_completed_at", _descriptor7, this);
|
|
48
65
|
|
|
49
|
-
_initializerDefineProperty(this, "created_at",
|
|
66
|
+
_initializerDefineProperty(this, "created_at", _descriptor8, this);
|
|
50
67
|
}
|
|
51
68
|
|
|
52
69
|
}, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "id", [_dec2], {
|
|
@@ -70,14 +87,31 @@ let Requisition = exports.default = (_dec = (0, _typeorm.Entity)({
|
|
|
70
87
|
initializer: function () {
|
|
71
88
|
return _user.default;
|
|
72
89
|
}
|
|
73
|
-
}), _descriptor4 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
90
|
+
}), _descriptor4 = _applyDecoratedDescriptor(_class2.prototype, "Agreement", [_dec7, _dec8], {
|
|
91
|
+
configurable: true,
|
|
92
|
+
enumerable: true,
|
|
93
|
+
writable: true,
|
|
94
|
+
initializer: function () {
|
|
95
|
+
return _gocardlessAgreement.default;
|
|
96
|
+
}
|
|
97
|
+
}), _descriptor5 = _applyDecoratedDescriptor(_class2.prototype, "is_complete", [_dec9], {
|
|
74
98
|
configurable: true,
|
|
75
99
|
enumerable: true,
|
|
76
100
|
writable: true,
|
|
77
101
|
initializer: function () {
|
|
78
102
|
return false;
|
|
79
103
|
}
|
|
80
|
-
}),
|
|
104
|
+
}), _descriptor6 = _applyDecoratedDescriptor(_class2.prototype, "initial_scrape_commenced_at", [_dec10], {
|
|
105
|
+
configurable: true,
|
|
106
|
+
enumerable: true,
|
|
107
|
+
writable: true,
|
|
108
|
+
initializer: null
|
|
109
|
+
}), _descriptor7 = _applyDecoratedDescriptor(_class2.prototype, "initial_scrape_completed_at", [_dec11], {
|
|
110
|
+
configurable: true,
|
|
111
|
+
enumerable: true,
|
|
112
|
+
writable: true,
|
|
113
|
+
initializer: null
|
|
114
|
+
}), _descriptor8 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec12], {
|
|
81
115
|
configurable: true,
|
|
82
116
|
enumerable: true,
|
|
83
117
|
writable: true,
|
|
@@ -5,12 +5,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
|
|
8
|
+
var _gocardlessAccount = _interopRequireDefault(require("./gocardless-account"));
|
|
9
|
+
|
|
8
10
|
var _gocardlessAgreement = _interopRequireDefault(require("./gocardless-agreement"));
|
|
9
11
|
|
|
10
12
|
var _gocardlessRequisition = _interopRequireDefault(require("./gocardless-requisition"));
|
|
11
13
|
|
|
12
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
15
|
|
|
14
|
-
const ENTITIES = [_gocardlessAgreement.default, _gocardlessRequisition.default];
|
|
16
|
+
const ENTITIES = [_gocardlessAccount.default, _gocardlessAgreement.default, _gocardlessRequisition.default];
|
|
15
17
|
|
|
16
18
|
var _default = exports.default = ENTITIES;
|
package/dist/index.js
CHANGED
|
@@ -189,6 +189,12 @@ Object.defineProperty(exports, "FeatureEntity", {
|
|
|
189
189
|
return _feature.default;
|
|
190
190
|
}
|
|
191
191
|
});
|
|
192
|
+
Object.defineProperty(exports, "GoCardlessAccountEntity", {
|
|
193
|
+
enumerable: true,
|
|
194
|
+
get: function () {
|
|
195
|
+
return _gocardlessAccount.default;
|
|
196
|
+
}
|
|
197
|
+
});
|
|
192
198
|
Object.defineProperty(exports, "GoCardlessAgreementEntity", {
|
|
193
199
|
enumerable: true,
|
|
194
200
|
get: function () {
|
|
@@ -746,6 +752,8 @@ var _bin = _interopRequireDefault(require("./entity/acquirer/bin"));
|
|
|
746
752
|
|
|
747
753
|
var _binRules = _interopRequireDefault(require("./entity/acquirer/bin-rules"));
|
|
748
754
|
|
|
755
|
+
var _gocardlessAccount = _interopRequireDefault(require("./entity/aisp/gocardless-account"));
|
|
756
|
+
|
|
749
757
|
var _gocardlessAgreement = _interopRequireDefault(require("./entity/aisp/gocardless-agreement"));
|
|
750
758
|
|
|
751
759
|
var _gocardlessRequisition = _interopRequireDefault(require("./entity/aisp/gocardless-requisition"));
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
const { MigrationInterface, QueryRunner } = require("typeorm");
|
|
2
|
+
|
|
3
|
+
module.exports = class aispRequisition1710340812651 {
|
|
4
|
+
name = 'aispRequisition1710340812651'
|
|
5
|
+
|
|
6
|
+
async up(queryRunner) {
|
|
7
|
+
await queryRunner.query(`CREATE TABLE "aisp"."gocardless_requisition" ("id" character varying(50) NOT NULL, "is_complete" boolean NOT NULL DEFAULT false, "created_at" TIMESTAMP NOT NULL DEFAULT now(), "organisation_id" character varying(150), "user_id" character varying, "agreement_id" character varying(50), CONSTRAINT "PK_909a47c291ce5606347240a2591" PRIMARY KEY ("id"))`);
|
|
8
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" ADD CONSTRAINT "FK_45399de88453e7eadd731d9a95a" FOREIGN KEY ("organisation_id") REFERENCES "user"."organisation"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`);
|
|
9
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" ADD CONSTRAINT "FK_b4b949c66fa8d309115864647cb" FOREIGN KEY ("user_id") REFERENCES "user"."user"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`);
|
|
10
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" ADD CONSTRAINT "FK_79fa1c1c7eab84dea60b18599ab" FOREIGN KEY ("agreement_id") REFERENCES "aisp"."gocardless_agreement"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
async down(queryRunner) {
|
|
14
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" DROP CONSTRAINT "FK_79fa1c1c7eab84dea60b18599ab"`);
|
|
15
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" DROP CONSTRAINT "FK_b4b949c66fa8d309115864647cb"`);
|
|
16
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" DROP CONSTRAINT "FK_45399de88453e7eadd731d9a95a"`);
|
|
17
|
+
await queryRunner.query(`DROP TABLE "aisp"."gocardless_requisition"`);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const { MigrationInterface, QueryRunner } = require("typeorm");
|
|
2
|
+
|
|
3
|
+
module.exports = class aispCommencedCompleted1710342798216 {
|
|
4
|
+
name = 'aispCommencedCompleted1710342798216'
|
|
5
|
+
|
|
6
|
+
async up(queryRunner) {
|
|
7
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" ADD "initial_scrape_commenced_at" TIMESTAMP WITH TIME ZONE`);
|
|
8
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" ADD "initial_scrape_completed_at" TIMESTAMP WITH TIME ZONE`);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
async down(queryRunner) {
|
|
12
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" DROP COLUMN "initial_scrape_completed_at"`);
|
|
13
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_requisition" DROP COLUMN "initial_scrape_commenced_at"`);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
const { MigrationInterface, QueryRunner } = require("typeorm");
|
|
2
|
+
|
|
3
|
+
module.exports = class aispAccount1710349579447 {
|
|
4
|
+
name = 'aispAccount1710349579447'
|
|
5
|
+
|
|
6
|
+
async up(queryRunner) {
|
|
7
|
+
await queryRunner.query(`CREATE TABLE "aisp"."gocardless_account" ("id" character varying(50) NOT NULL, "status" character varying(50), "created_at" TIMESTAMP NOT NULL DEFAULT now(), "iban" character varying(30), "requistion_id" character varying(50), CONSTRAINT "PK_67d441c1e3f7ecaa53c11d110b4" PRIMARY KEY ("id"))`);
|
|
8
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_account" ADD CONSTRAINT "FK_1e68d1a82d9be2f45f5d7633de7" FOREIGN KEY ("iban") REFERENCES "bank"."account"("iban") ON DELETE NO ACTION ON UPDATE NO ACTION`);
|
|
9
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_account" ADD CONSTRAINT "FK_71ef52a9c3f110052ebd880be73" FOREIGN KEY ("requistion_id") REFERENCES "aisp"."gocardless_requisition"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
async down(queryRunner) {
|
|
13
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_account" DROP CONSTRAINT "FK_71ef52a9c3f110052ebd880be73"`);
|
|
14
|
+
await queryRunner.query(`ALTER TABLE "aisp"."gocardless_account" DROP CONSTRAINT "FK_1e68d1a82d9be2f45f5d7633de7"`);
|
|
15
|
+
await queryRunner.query(`DROP TABLE "aisp"."gocardless_account"`);
|
|
16
|
+
}
|
|
17
|
+
}
|