@felloh-org/lambda-wrapper 1.0.6 → 1.0.10
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/cli/seed/create-schema.js +6 -6
- package/dist/entity/agent-data/booking/index.js +3 -1
- package/dist/entity/agent-data/booking-component/index.js +6 -2
- package/dist/entity/agent-data/booking-component-type/index.js +6 -2
- package/dist/entity/agent-data/supplier/index.js +37 -5
- package/dist/entity/agent-data/supplier-type/index.js +6 -2
- package/dist/entity/payment/payment-link/index.js +38 -16
- package/dist/entity/payment/transaction/index.js +16 -7
- package/dist/entity/payment/transaction-metadata/index.js +1 -3
- package/dist/migration/agent-data/1642771380681-add-supplier-detail.js +17 -0
- package/dist/migration/agent-data/1642771909248-swap-uuid.js +41 -0
- package/dist/migration/payment/1642805897210-payment-link-customer.js +13 -0
- package/dist/service/warehouse.js +1 -1
- package/package.json +1 -1
|
@@ -10,13 +10,13 @@ const run = async () => {
|
|
|
10
10
|
const connection = await warehouse.connect();
|
|
11
11
|
|
|
12
12
|
const queryRunner = await connection.createQueryRunner();
|
|
13
|
-
await queryRunner.createDatabase(
|
|
13
|
+
await queryRunner.createDatabase('felloh', true);
|
|
14
14
|
|
|
15
|
-
await queryRunner.createSchema(
|
|
16
|
-
await queryRunner.createSchema(
|
|
17
|
-
await queryRunner.createSchema(
|
|
18
|
-
await queryRunner.createSchema(
|
|
19
|
-
await queryRunner.createSchema(
|
|
15
|
+
await queryRunner.createSchema('nuapay', true);
|
|
16
|
+
await queryRunner.createSchema('agent_data', true);
|
|
17
|
+
await queryRunner.createSchema('payment', true);
|
|
18
|
+
await queryRunner.createSchema('bank', true);
|
|
19
|
+
await queryRunner.createSchema('user', true);
|
|
20
20
|
};
|
|
21
21
|
|
|
22
22
|
run();
|
|
@@ -13,6 +13,8 @@ var _organisation = _interopRequireDefault(require("../../user/organisation"));
|
|
|
13
13
|
|
|
14
14
|
var _transaction = _interopRequireDefault(require("../../payment/transaction"));
|
|
15
15
|
|
|
16
|
+
var _uuid = require("uuid");
|
|
17
|
+
|
|
16
18
|
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _dec13, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10;
|
|
17
19
|
|
|
18
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
@@ -75,7 +77,7 @@ let Booking = (_dec = (0, _typeorm.Entity)({
|
|
|
75
77
|
enumerable: true,
|
|
76
78
|
writable: true,
|
|
77
79
|
initializer: function () {
|
|
78
|
-
return
|
|
80
|
+
return (0, _uuid.v4)();
|
|
79
81
|
}
|
|
80
82
|
}), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "email", [_dec3], {
|
|
81
83
|
configurable: true,
|
|
@@ -7,6 +7,8 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _typeorm = require("typeorm");
|
|
9
9
|
|
|
10
|
+
var _uuid = require("uuid");
|
|
11
|
+
|
|
10
12
|
var _dec, _dec2, _dec3, _class, _class2, _descriptor, _descriptor2;
|
|
11
13
|
|
|
12
14
|
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 }); }
|
|
@@ -18,7 +20,7 @@ function _initializerWarningHelper(descriptor, context) { throw new Error('Decor
|
|
|
18
20
|
let BookingComponent = (_dec = (0, _typeorm.Entity)({
|
|
19
21
|
name: 'booking_component',
|
|
20
22
|
schema: 'agent_data'
|
|
21
|
-
}), _dec2 = (0, _typeorm.
|
|
23
|
+
}), _dec2 = (0, _typeorm.PrimaryColumn)("varchar"), _dec3 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class BookingComponent {
|
|
22
24
|
constructor() {
|
|
23
25
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
24
26
|
|
|
@@ -29,7 +31,9 @@ let BookingComponent = (_dec = (0, _typeorm.Entity)({
|
|
|
29
31
|
configurable: true,
|
|
30
32
|
enumerable: true,
|
|
31
33
|
writable: true,
|
|
32
|
-
initializer:
|
|
34
|
+
initializer: function () {
|
|
35
|
+
return (0, _uuid.v4)();
|
|
36
|
+
}
|
|
33
37
|
}), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec3], {
|
|
34
38
|
configurable: true,
|
|
35
39
|
enumerable: true,
|
|
@@ -7,6 +7,8 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _typeorm = require("typeorm");
|
|
9
9
|
|
|
10
|
+
var _uuid = require("uuid");
|
|
11
|
+
|
|
10
12
|
var _dec, _dec2, _dec3, _class, _class2, _descriptor, _descriptor2;
|
|
11
13
|
|
|
12
14
|
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 }); }
|
|
@@ -18,7 +20,7 @@ function _initializerWarningHelper(descriptor, context) { throw new Error('Decor
|
|
|
18
20
|
let BookingComponentType = (_dec = (0, _typeorm.Entity)({
|
|
19
21
|
name: 'booking_component_type',
|
|
20
22
|
schema: 'agent_data'
|
|
21
|
-
}), _dec2 = (0, _typeorm.
|
|
23
|
+
}), _dec2 = (0, _typeorm.PrimaryColumn)("varchar"), _dec3 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class BookingComponentType {
|
|
22
24
|
constructor() {
|
|
23
25
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
24
26
|
|
|
@@ -29,7 +31,9 @@ let BookingComponentType = (_dec = (0, _typeorm.Entity)({
|
|
|
29
31
|
configurable: true,
|
|
30
32
|
enumerable: true,
|
|
31
33
|
writable: true,
|
|
32
|
-
initializer:
|
|
34
|
+
initializer: function () {
|
|
35
|
+
return (0, _uuid.v4)();
|
|
36
|
+
}
|
|
33
37
|
}), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec3], {
|
|
34
38
|
configurable: true,
|
|
35
39
|
enumerable: true,
|
|
@@ -7,7 +7,13 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _typeorm = require("typeorm");
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _organisation = _interopRequireDefault(require("../../user/organisation"));
|
|
11
|
+
|
|
12
|
+
var _uuid = require("uuid");
|
|
13
|
+
|
|
14
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4;
|
|
15
|
+
|
|
16
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
17
|
|
|
12
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 }); }
|
|
13
19
|
|
|
@@ -18,19 +24,45 @@ function _initializerWarningHelper(descriptor, context) { throw new Error('Decor
|
|
|
18
24
|
let Supplier = (_dec = (0, _typeorm.Entity)({
|
|
19
25
|
name: 'supplier',
|
|
20
26
|
schema: 'agent_data'
|
|
21
|
-
}), _dec2 = (0, _typeorm.
|
|
27
|
+
}), _dec2 = (0, _typeorm.PrimaryColumn)("varchar"), _dec3 = (0, _typeorm.ManyToOne)(() => _organisation.default), _dec4 = (0, _typeorm.JoinColumn)({
|
|
28
|
+
name: 'organisation_id',
|
|
29
|
+
referencedColumnName: 'id'
|
|
30
|
+
}), _dec5 = (0, _typeorm.Column)({
|
|
31
|
+
type: "varchar",
|
|
32
|
+
length: "150"
|
|
33
|
+
}), _dec6 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class Supplier {
|
|
22
34
|
constructor() {
|
|
23
35
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
24
36
|
|
|
25
|
-
_initializerDefineProperty(this, "
|
|
37
|
+
_initializerDefineProperty(this, "organisation", _descriptor2, this);
|
|
38
|
+
|
|
39
|
+
_initializerDefineProperty(this, "name", _descriptor3, this);
|
|
40
|
+
|
|
41
|
+
_initializerDefineProperty(this, "created_at", _descriptor4, this);
|
|
26
42
|
}
|
|
27
43
|
|
|
28
44
|
}, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "id", [_dec2], {
|
|
29
45
|
configurable: true,
|
|
30
46
|
enumerable: true,
|
|
31
47
|
writable: true,
|
|
32
|
-
initializer:
|
|
33
|
-
|
|
48
|
+
initializer: function () {
|
|
49
|
+
return (0, _uuid.v4)();
|
|
50
|
+
}
|
|
51
|
+
}), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "organisation", [_dec3, _dec4], {
|
|
52
|
+
configurable: true,
|
|
53
|
+
enumerable: true,
|
|
54
|
+
writable: true,
|
|
55
|
+
initializer: function () {
|
|
56
|
+
return _organisation.default;
|
|
57
|
+
}
|
|
58
|
+
}), _descriptor3 = _applyDecoratedDescriptor(_class2.prototype, "name", [_dec5], {
|
|
59
|
+
configurable: true,
|
|
60
|
+
enumerable: true,
|
|
61
|
+
writable: true,
|
|
62
|
+
initializer: function () {
|
|
63
|
+
return "";
|
|
64
|
+
}
|
|
65
|
+
}), _descriptor4 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec6], {
|
|
34
66
|
configurable: true,
|
|
35
67
|
enumerable: true,
|
|
36
68
|
writable: true,
|
|
@@ -7,6 +7,8 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _typeorm = require("typeorm");
|
|
9
9
|
|
|
10
|
+
var _uuid = require("uuid");
|
|
11
|
+
|
|
10
12
|
var _dec, _dec2, _dec3, _class, _class2, _descriptor, _descriptor2;
|
|
11
13
|
|
|
12
14
|
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 }); }
|
|
@@ -18,7 +20,7 @@ function _initializerWarningHelper(descriptor, context) { throw new Error('Decor
|
|
|
18
20
|
let SupplierType = (_dec = (0, _typeorm.Entity)({
|
|
19
21
|
name: 'supplier_type',
|
|
20
22
|
schema: 'agent_data'
|
|
21
|
-
}), _dec2 = (0, _typeorm.
|
|
23
|
+
}), _dec2 = (0, _typeorm.PrimaryColumn)("varchar"), _dec3 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class SupplierType {
|
|
22
24
|
constructor() {
|
|
23
25
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
24
26
|
|
|
@@ -29,7 +31,9 @@ let SupplierType = (_dec = (0, _typeorm.Entity)({
|
|
|
29
31
|
configurable: true,
|
|
30
32
|
enumerable: true,
|
|
31
33
|
writable: true,
|
|
32
|
-
initializer:
|
|
34
|
+
initializer: function () {
|
|
35
|
+
return (0, _uuid.v4)();
|
|
36
|
+
}
|
|
33
37
|
}), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec3], {
|
|
34
38
|
configurable: true,
|
|
35
39
|
enumerable: true,
|
|
@@ -13,7 +13,9 @@ var _user = _interopRequireDefault(require("../../user/user"));
|
|
|
13
13
|
|
|
14
14
|
var _booking = _interopRequireDefault(require("../../agent-data/booking"));
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _transaction = _interopRequireDefault(require("../transaction"));
|
|
17
|
+
|
|
18
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _dec13, _dec14, _dec15, _dec16, _dec17, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10, _descriptor11, _descriptor12, _descriptor13;
|
|
17
19
|
|
|
18
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
21
|
|
|
@@ -41,10 +43,11 @@ let PaymentLink = (_dec = (0, _typeorm.Entity)({
|
|
|
41
43
|
type: "int"
|
|
42
44
|
}), _dec10 = (0, _typeorm.Column)({
|
|
43
45
|
type: "varchar",
|
|
44
|
-
length: "
|
|
46
|
+
length: "150",
|
|
47
|
+
nullable: true
|
|
45
48
|
}), _dec11 = (0, _typeorm.Column)({
|
|
46
49
|
type: "varchar",
|
|
47
|
-
length: "
|
|
50
|
+
length: "250"
|
|
48
51
|
}), _dec12 = (0, _typeorm.Column)({
|
|
49
52
|
type: "varchar",
|
|
50
53
|
length: "200"
|
|
@@ -52,8 +55,11 @@ let PaymentLink = (_dec = (0, _typeorm.Entity)({
|
|
|
52
55
|
type: "varchar",
|
|
53
56
|
length: "200"
|
|
54
57
|
}), _dec14 = (0, _typeorm.Column)({
|
|
58
|
+
type: "varchar",
|
|
59
|
+
length: "200"
|
|
60
|
+
}), _dec15 = (0, _typeorm.OneToMany)(() => _transaction.default, transaction => transaction.payment_link), _dec16 = (0, _typeorm.Column)({
|
|
55
61
|
type: "timestamp with time zone"
|
|
56
|
-
}),
|
|
62
|
+
}), _dec17 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class PaymentLink {
|
|
57
63
|
constructor() {
|
|
58
64
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
59
65
|
|
|
@@ -65,17 +71,21 @@ let PaymentLink = (_dec = (0, _typeorm.Entity)({
|
|
|
65
71
|
|
|
66
72
|
_initializerDefineProperty(this, "amount", _descriptor5, this);
|
|
67
73
|
|
|
68
|
-
_initializerDefineProperty(this, "
|
|
74
|
+
_initializerDefineProperty(this, "customer_name", _descriptor6, this);
|
|
75
|
+
|
|
76
|
+
_initializerDefineProperty(this, "description", _descriptor7, this);
|
|
69
77
|
|
|
70
|
-
_initializerDefineProperty(this, "success_url",
|
|
78
|
+
_initializerDefineProperty(this, "success_url", _descriptor8, this);
|
|
71
79
|
|
|
72
|
-
_initializerDefineProperty(this, "failure_url",
|
|
80
|
+
_initializerDefineProperty(this, "failure_url", _descriptor9, this);
|
|
73
81
|
|
|
74
|
-
_initializerDefineProperty(this, "cancel_url",
|
|
82
|
+
_initializerDefineProperty(this, "cancel_url", _descriptor10, this);
|
|
75
83
|
|
|
76
|
-
_initializerDefineProperty(this, "
|
|
84
|
+
_initializerDefineProperty(this, "transactions", _descriptor11, this);
|
|
77
85
|
|
|
78
|
-
_initializerDefineProperty(this, "
|
|
86
|
+
_initializerDefineProperty(this, "expires_at", _descriptor12, this);
|
|
87
|
+
|
|
88
|
+
_initializerDefineProperty(this, "created_at", _descriptor13, this);
|
|
79
89
|
}
|
|
80
90
|
|
|
81
91
|
generateExpiryDate() {
|
|
@@ -117,42 +127,54 @@ let PaymentLink = (_dec = (0, _typeorm.Entity)({
|
|
|
117
127
|
enumerable: true,
|
|
118
128
|
writable: true,
|
|
119
129
|
initializer: null
|
|
120
|
-
}), _descriptor6 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
130
|
+
}), _descriptor6 = _applyDecoratedDescriptor(_class2.prototype, "customer_name", [_dec10], {
|
|
121
131
|
configurable: true,
|
|
122
132
|
enumerable: true,
|
|
123
133
|
writable: true,
|
|
124
134
|
initializer: function () {
|
|
125
135
|
return "";
|
|
126
136
|
}
|
|
127
|
-
}), _descriptor7 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
137
|
+
}), _descriptor7 = _applyDecoratedDescriptor(_class2.prototype, "description", [_dec11], {
|
|
128
138
|
configurable: true,
|
|
129
139
|
enumerable: true,
|
|
130
140
|
writable: true,
|
|
131
141
|
initializer: function () {
|
|
132
142
|
return "";
|
|
133
143
|
}
|
|
134
|
-
}), _descriptor8 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
144
|
+
}), _descriptor8 = _applyDecoratedDescriptor(_class2.prototype, "success_url", [_dec12], {
|
|
135
145
|
configurable: true,
|
|
136
146
|
enumerable: true,
|
|
137
147
|
writable: true,
|
|
138
148
|
initializer: function () {
|
|
139
149
|
return "";
|
|
140
150
|
}
|
|
141
|
-
}), _descriptor9 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
151
|
+
}), _descriptor9 = _applyDecoratedDescriptor(_class2.prototype, "failure_url", [_dec13], {
|
|
142
152
|
configurable: true,
|
|
143
153
|
enumerable: true,
|
|
144
154
|
writable: true,
|
|
145
155
|
initializer: function () {
|
|
146
156
|
return "";
|
|
147
157
|
}
|
|
148
|
-
}), _descriptor10 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
158
|
+
}), _descriptor10 = _applyDecoratedDescriptor(_class2.prototype, "cancel_url", [_dec14], {
|
|
159
|
+
configurable: true,
|
|
160
|
+
enumerable: true,
|
|
161
|
+
writable: true,
|
|
162
|
+
initializer: function () {
|
|
163
|
+
return "";
|
|
164
|
+
}
|
|
165
|
+
}), _descriptor11 = _applyDecoratedDescriptor(_class2.prototype, "transactions", [_dec15], {
|
|
166
|
+
configurable: true,
|
|
167
|
+
enumerable: true,
|
|
168
|
+
writable: true,
|
|
169
|
+
initializer: null
|
|
170
|
+
}), _descriptor12 = _applyDecoratedDescriptor(_class2.prototype, "expires_at", [_dec16], {
|
|
149
171
|
configurable: true,
|
|
150
172
|
enumerable: true,
|
|
151
173
|
writable: true,
|
|
152
174
|
initializer: function () {
|
|
153
175
|
return this.generateExpiryDate();
|
|
154
176
|
}
|
|
155
|
-
}),
|
|
177
|
+
}), _descriptor13 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec17], {
|
|
156
178
|
configurable: true,
|
|
157
179
|
enumerable: true,
|
|
158
180
|
writable: true,
|
|
@@ -19,7 +19,9 @@ var _transactionStatus = _interopRequireDefault(require("../transaction-status")
|
|
|
19
19
|
|
|
20
20
|
var _paymentLink = _interopRequireDefault(require("../payment-link"));
|
|
21
21
|
|
|
22
|
-
var
|
|
22
|
+
var _transactionMetadata = _interopRequireDefault(require("../transaction-metadata"));
|
|
23
|
+
|
|
24
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _dec13, _dec14, _dec15, _dec16, _dec17, _dec18, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10, _descriptor11;
|
|
23
25
|
|
|
24
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
25
27
|
|
|
@@ -56,10 +58,10 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
56
58
|
}), _dec15 = (0, _typeorm.JoinColumn)({
|
|
57
59
|
name: 'payment_link_id',
|
|
58
60
|
referencedColumnName: 'id'
|
|
59
|
-
}), _dec16 = (0, _typeorm.Column)({
|
|
61
|
+
}), _dec16 = (0, _typeorm.OneToOne)(() => _transactionMetadata.default, transactionMetadata => transactionMetadata.transaction), _dec17 = (0, _typeorm.Column)({
|
|
60
62
|
type: "timestamp with time zone",
|
|
61
63
|
nullable: true
|
|
62
|
-
}),
|
|
64
|
+
}), _dec18 = (0, _typeorm.CreateDateColumn)(), _dec(_class = (_class2 = class Transaction {
|
|
63
65
|
constructor() {
|
|
64
66
|
_initializerDefineProperty(this, "id", _descriptor, this);
|
|
65
67
|
|
|
@@ -77,9 +79,11 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
77
79
|
|
|
78
80
|
_initializerDefineProperty(this, "payment_link", _descriptor8, this);
|
|
79
81
|
|
|
80
|
-
_initializerDefineProperty(this, "
|
|
82
|
+
_initializerDefineProperty(this, "metadata", _descriptor9, this);
|
|
83
|
+
|
|
84
|
+
_initializerDefineProperty(this, "completed_at", _descriptor10, this);
|
|
81
85
|
|
|
82
|
-
_initializerDefineProperty(this, "created_at",
|
|
86
|
+
_initializerDefineProperty(this, "created_at", _descriptor11, this);
|
|
83
87
|
}
|
|
84
88
|
|
|
85
89
|
}, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "id", [_dec2], {
|
|
@@ -136,12 +140,17 @@ let Transaction = (_dec = (0, _typeorm.Entity)({
|
|
|
136
140
|
initializer: function () {
|
|
137
141
|
return _paymentLink.default;
|
|
138
142
|
}
|
|
139
|
-
}), _descriptor9 = _applyDecoratedDescriptor(_class2.prototype, "
|
|
143
|
+
}), _descriptor9 = _applyDecoratedDescriptor(_class2.prototype, "metadata", [_dec16], {
|
|
144
|
+
configurable: true,
|
|
145
|
+
enumerable: true,
|
|
146
|
+
writable: true,
|
|
147
|
+
initializer: null
|
|
148
|
+
}), _descriptor10 = _applyDecoratedDescriptor(_class2.prototype, "completed_at", [_dec17], {
|
|
140
149
|
configurable: true,
|
|
141
150
|
enumerable: true,
|
|
142
151
|
writable: true,
|
|
143
152
|
initializer: null
|
|
144
|
-
}),
|
|
153
|
+
}), _descriptor11 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec18], {
|
|
145
154
|
configurable: true,
|
|
146
155
|
enumerable: true,
|
|
147
156
|
writable: true,
|
|
@@ -7,8 +7,6 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _typeorm = require("typeorm");
|
|
9
9
|
|
|
10
|
-
var _booking = _interopRequireDefault(require("../../agent-data/booking"));
|
|
11
|
-
|
|
12
10
|
var _transaction = _interopRequireDefault(require("../transaction"));
|
|
13
11
|
|
|
14
12
|
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10;
|
|
@@ -89,7 +87,7 @@ let TransactionMetadata = (_dec = (0, _typeorm.Entity)({
|
|
|
89
87
|
enumerable: true,
|
|
90
88
|
writable: true,
|
|
91
89
|
initializer: function () {
|
|
92
|
-
return
|
|
90
|
+
return _transaction.default;
|
|
93
91
|
}
|
|
94
92
|
}), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "card_type", [_dec4], {
|
|
95
93
|
configurable: true,
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
const { MigrationInterface, QueryRunner } = require("typeorm");
|
|
2
|
+
|
|
3
|
+
module.exports = class addSupplierDetail1642771380681 {
|
|
4
|
+
name = 'addSupplierDetail1642771380681'
|
|
5
|
+
|
|
6
|
+
async up(queryRunner) {
|
|
7
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" ADD "name" character varying(150) NOT NULL`);
|
|
8
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" ADD "organisation_id" character varying(150)`);
|
|
9
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" ADD CONSTRAINT "FK_4b0eb422429dfbe15daa42def90" FOREIGN KEY ("organisation_id") REFERENCES "user"."organisation"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
async down(queryRunner) {
|
|
13
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" DROP CONSTRAINT "FK_4b0eb422429dfbe15daa42def90"`);
|
|
14
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" DROP COLUMN "organisation_id"`);
|
|
15
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" DROP COLUMN "name"`);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
const { MigrationInterface, QueryRunner } = require("typeorm");
|
|
2
|
+
|
|
3
|
+
module.exports = class swapUuid1642771909248 {
|
|
4
|
+
name = 'swapUuid1642771909248'
|
|
5
|
+
|
|
6
|
+
async up(queryRunner) {
|
|
7
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" DROP CONSTRAINT "PK_31c60e2f5eb5eb274efbf1551cb"`);
|
|
8
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" DROP COLUMN "id"`);
|
|
9
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" ADD "id" character varying NOT NULL`);
|
|
10
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" ADD CONSTRAINT "PK_31c60e2f5eb5eb274efbf1551cb" PRIMARY KEY ("id")`);
|
|
11
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" DROP CONSTRAINT "PK_fde413f2d9d1e1377876431efaa"`);
|
|
12
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" DROP COLUMN "id"`);
|
|
13
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" ADD "id" character varying NOT NULL`);
|
|
14
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" ADD CONSTRAINT "PK_fde413f2d9d1e1377876431efaa" PRIMARY KEY ("id")`);
|
|
15
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" DROP COLUMN "id"`);
|
|
16
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" ADD "id" character varying NOT NULL`);
|
|
17
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" ADD CONSTRAINT "PK_2bc0d2cab6276144d2ff98a2828" PRIMARY KEY ("id")`);
|
|
18
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier_type" DROP COLUMN "id"`);
|
|
19
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier_type" ADD "id" character varying NOT NULL`);
|
|
20
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier_type" ADD CONSTRAINT "PK_682cd6e0ba8042baeb545fc12c7" PRIMARY KEY ("id")`);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
async down(queryRunner) {
|
|
24
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier_type" DROP CONSTRAINT "PK_682cd6e0ba8042baeb545fc12c7"`);
|
|
25
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier_type" DROP COLUMN "id"`);
|
|
26
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier_type" ADD "id" uuid NOT NULL DEFAULT uuid_generate_v4()`);
|
|
27
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier_type" ADD CONSTRAINT "PK_682cd6e0ba8042baeb545fc12c7" PRIMARY KEY ("id")`);
|
|
28
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" DROP CONSTRAINT "PK_2bc0d2cab6276144d2ff98a2828"`);
|
|
29
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" DROP COLUMN "id"`);
|
|
30
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" ADD "id" uuid NOT NULL DEFAULT uuid_generate_v4()`);
|
|
31
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."supplier" ADD CONSTRAINT "PK_2bc0d2cab6276144d2ff98a2828" PRIMARY KEY ("id")`);
|
|
32
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" DROP CONSTRAINT "PK_fde413f2d9d1e1377876431efaa"`);
|
|
33
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" DROP COLUMN "id"`);
|
|
34
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" ADD "id" uuid NOT NULL DEFAULT uuid_generate_v4()`);
|
|
35
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component" ADD CONSTRAINT "PK_fde413f2d9d1e1377876431efaa" PRIMARY KEY ("id")`);
|
|
36
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" DROP CONSTRAINT "PK_31c60e2f5eb5eb274efbf1551cb"`);
|
|
37
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" DROP COLUMN "id"`);
|
|
38
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" ADD "id" uuid NOT NULL DEFAULT uuid_generate_v4()`);
|
|
39
|
+
await queryRunner.query(`ALTER TABLE "agent_data"."booking_component_type" ADD CONSTRAINT "PK_31c60e2f5eb5eb274efbf1551cb" PRIMARY KEY ("id")`);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
const { MigrationInterface, QueryRunner } = require("typeorm");
|
|
2
|
+
|
|
3
|
+
module.exports = class paymentLinkCustomer1642805897210 {
|
|
4
|
+
name = 'paymentLinkCustomer1642805897210'
|
|
5
|
+
|
|
6
|
+
async up(queryRunner) {
|
|
7
|
+
await queryRunner.query(`ALTER TABLE "payment"."payment_Link" ADD "customer_name" character varying(150)`);
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
async down(queryRunner) {
|
|
11
|
+
await queryRunner.query(`ALTER TABLE "payment"."payment_Link" DROP COLUMN "customer_name"`);
|
|
12
|
+
}
|
|
13
|
+
}
|