@felloh-org/lambda-wrapper 1.11.67 → 1.11.69

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.
@@ -7,7 +7,11 @@ exports.default = void 0;
7
7
 
8
8
  var _typeorm = require("typeorm");
9
9
 
10
- var _dec, _dec2, _dec3, _dec4, _dec5, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4;
10
+ var _customer = _interopRequireDefault(require("../../payment/customer"));
11
+
12
+ var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7;
13
+
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
11
15
 
12
16
  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
17
 
@@ -21,22 +25,40 @@ let Token = exports.default = (_dec = (0, _typeorm.Entity)({
21
25
  }), _dec2 = (0, _typeorm.PrimaryColumn)({
22
26
  type: "varchar",
23
27
  length: "36"
24
- }), _dec3 = (0, _typeorm.CreateDateColumn)({
28
+ }), _dec3 = (0, _typeorm.Column)({
29
+ type: "varchar",
30
+ length: "250",
31
+ nullable: true
32
+ }), _dec4 = (0, _typeorm.ManyToOne)(() => _customer.default, {
33
+ nullable: true
34
+ }), _dec5 = (0, _typeorm.JoinColumn)({
35
+ name: 'customer_id',
36
+ referencedColumnName: 'id'
37
+ }), _dec6 = (0, _typeorm.Column)({
38
+ type: "boolean",
39
+ default: false
40
+ }), _dec7 = (0, _typeorm.CreateDateColumn)({
25
41
  type: 'timestamp with time zone'
26
- }), _dec4 = (0, _typeorm.UpdateDateColumn)({
42
+ }), _dec8 = (0, _typeorm.UpdateDateColumn)({
27
43
  type: 'timestamp with time zone'
28
- }), _dec5 = (0, _typeorm.DeleteDateColumn)({
44
+ }), _dec9 = (0, _typeorm.DeleteDateColumn)({
29
45
  type: 'timestamp with time zone',
30
46
  nullable: true
31
47
  }), _dec(_class = (_class2 = class Token {
32
48
  constructor() {
33
49
  _initializerDefineProperty(this, "id", _descriptor, this);
34
50
 
35
- _initializerDefineProperty(this, "created_at", _descriptor2, this);
51
+ _initializerDefineProperty(this, "cardholder_name", _descriptor2, this);
52
+
53
+ _initializerDefineProperty(this, "customer", _descriptor3, this);
36
54
 
37
- _initializerDefineProperty(this, "updated_at", _descriptor3, this);
55
+ _initializerDefineProperty(this, "store_token", _descriptor4, this);
38
56
 
39
- _initializerDefineProperty(this, "deleted_at", _descriptor4, this);
57
+ _initializerDefineProperty(this, "created_at", _descriptor5, this);
58
+
59
+ _initializerDefineProperty(this, "updated_at", _descriptor6, this);
60
+
61
+ _initializerDefineProperty(this, "deleted_at", _descriptor7, this);
40
62
  }
41
63
 
42
64
  }, (_descriptor = _applyDecoratedDescriptor(_class2.prototype, "id", [_dec2], {
@@ -46,17 +68,38 @@ let Token = exports.default = (_dec = (0, _typeorm.Entity)({
46
68
  initializer: function () {
47
69
  return undefined;
48
70
  }
49
- }), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec3], {
71
+ }), _descriptor2 = _applyDecoratedDescriptor(_class2.prototype, "cardholder_name", [_dec3], {
72
+ configurable: true,
73
+ enumerable: true,
74
+ writable: true,
75
+ initializer: function () {
76
+ return "";
77
+ }
78
+ }), _descriptor3 = _applyDecoratedDescriptor(_class2.prototype, "customer", [_dec4, _dec5], {
79
+ configurable: true,
80
+ enumerable: true,
81
+ writable: true,
82
+ initializer: function () {
83
+ return _customer.default;
84
+ }
85
+ }), _descriptor4 = _applyDecoratedDescriptor(_class2.prototype, "store_token", [_dec6], {
86
+ configurable: true,
87
+ enumerable: true,
88
+ writable: true,
89
+ initializer: function () {
90
+ return false;
91
+ }
92
+ }), _descriptor5 = _applyDecoratedDescriptor(_class2.prototype, "created_at", [_dec7], {
50
93
  configurable: true,
51
94
  enumerable: true,
52
95
  writable: true,
53
96
  initializer: null
54
- }), _descriptor3 = _applyDecoratedDescriptor(_class2.prototype, "updated_at", [_dec4], {
97
+ }), _descriptor6 = _applyDecoratedDescriptor(_class2.prototype, "updated_at", [_dec8], {
55
98
  configurable: true,
56
99
  enumerable: true,
57
100
  writable: true,
58
101
  initializer: null
59
- }), _descriptor4 = _applyDecoratedDescriptor(_class2.prototype, "deleted_at", [_dec5], {
102
+ }), _descriptor7 = _applyDecoratedDescriptor(_class2.prototype, "deleted_at", [_dec9], {
60
103
  configurable: true,
61
104
  enumerable: true,
62
105
  writable: true,
@@ -0,0 +1,15 @@
1
+ const { MigrationInterface, QueryRunner } = require("typeorm");
2
+
3
+ module.exports = class basisTheoryTokenStore1705322282519 {
4
+ name = 'basisTheoryTokenStore1705322282519'
5
+
6
+ async up(queryRunner) {
7
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" ADD "customer_name" character varying(250)`);
8
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" ADD "store_token" boolean NOT NULL DEFAULT false`);
9
+ }
10
+
11
+ async down(queryRunner) {
12
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" DROP COLUMN "store_token"`);
13
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" DROP COLUMN "customer_name"`);
14
+ }
15
+ }
@@ -0,0 +1,19 @@
1
+ const { MigrationInterface, QueryRunner } = require("typeorm");
2
+
3
+ module.exports = class basisTheoryTokenCustomer1705327854669 {
4
+ name = 'basisTheoryTokenCustomer1705327854669'
5
+
6
+ async up(queryRunner) {
7
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" DROP COLUMN "customer_name"`);
8
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" ADD "cardholder_name" character varying(250)`);
9
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" ADD "customer_id" character varying`);
10
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" ADD CONSTRAINT "FK_c19a5f00c0589a7eccbf83de5ae" FOREIGN KEY ("customer_id") REFERENCES "payment"."customer"("id") ON DELETE NO ACTION ON UPDATE NO ACTION`);
11
+ }
12
+
13
+ async down(queryRunner) {
14
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" DROP CONSTRAINT "FK_c19a5f00c0589a7eccbf83de5ae"`);
15
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" DROP COLUMN "customer_id"`);
16
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" DROP COLUMN "cardholder_name"`);
17
+ await queryRunner.query(`ALTER TABLE "basis_theory"."token" ADD "customer_name" character varying(250)`);
18
+ }
19
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@felloh-org/lambda-wrapper",
3
- "version": "1.11.67",
3
+ "version": "1.11.69",
4
4
  "description": "Lambda wrapper for all Felloh Serverless Projects",
5
5
  "main": "dist/index.js",
6
6
  "engines": {