@uniorganization/uni-lib 1.1.43 → 1.1.44

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.
@@ -1,3 +1,4 @@
1
+ import { Transactions } from './transactions.entity';
1
2
  export declare class ActiveLoad {
2
3
  id: number;
3
4
  orderNumber: string;
@@ -13,4 +14,5 @@ export declare class ActiveLoad {
13
14
  destinationZip: string;
14
15
  createDate: Date;
15
16
  updateDate: Date;
17
+ transaction: Transactions;
16
18
  }
@@ -11,14 +11,15 @@ var __metadata = (this && this.__metadata) || function (k, v) {
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.ActiveLoad = void 0;
13
13
  const typeorm_1 = require("typeorm");
14
+ const transactions_entity_1 = require("./transactions.entity");
14
15
  let ActiveLoad = class ActiveLoad {
15
16
  };
16
17
  __decorate([
17
- (0, typeorm_1.Column)({ name: 'id', generated: 'increment' }),
18
+ (0, typeorm_1.PrimaryGeneratedColumn)({ name: 'id' }),
18
19
  __metadata("design:type", Number)
19
20
  ], ActiveLoad.prototype, "id", void 0);
20
21
  __decorate([
21
- (0, typeorm_1.PrimaryColumn)({ name: 'order_number' }),
22
+ (0, typeorm_1.Column)({ name: 'order_number' }),
22
23
  __metadata("design:type", String)
23
24
  ], ActiveLoad.prototype, "orderNumber", void 0);
24
25
  __decorate([
@@ -69,6 +70,14 @@ __decorate([
69
70
  (0, typeorm_1.Column)({ name: 'update_date' }),
70
71
  __metadata("design:type", Date)
71
72
  ], ActiveLoad.prototype, "updateDate", void 0);
73
+ __decorate([
74
+ (0, typeorm_1.ManyToOne)(() => transactions_entity_1.Transactions),
75
+ (0, typeorm_1.JoinColumn)({
76
+ name: 'order_number',
77
+ referencedColumnName: 'transactionId',
78
+ }),
79
+ __metadata("design:type", transactions_entity_1.Transactions)
80
+ ], ActiveLoad.prototype, "transaction", void 0);
72
81
  ActiveLoad = __decorate([
73
82
  (0, typeorm_1.Entity)('active_loads', { schema: 'enr' })
74
83
  ], ActiveLoad);
@@ -15,11 +15,11 @@ const transactions_entity_1 = require("./transactions.entity");
15
15
  let DailyPaymentStatus = class DailyPaymentStatus {
16
16
  };
17
17
  __decorate([
18
- (0, typeorm_1.Column)({ name: 'id', generated: 'increment' }),
18
+ (0, typeorm_1.PrimaryGeneratedColumn)({ name: 'id' }),
19
19
  __metadata("design:type", Number)
20
20
  ], DailyPaymentStatus.prototype, "id", void 0);
21
21
  __decorate([
22
- (0, typeorm_1.PrimaryColumn)({ name: 'payment_reference' }),
22
+ (0, typeorm_1.Column)({ name: 'payment_reference' }),
23
23
  __metadata("design:type", String)
24
24
  ], DailyPaymentStatus.prototype, "paymentReference", void 0);
25
25
  __decorate([
@@ -107,7 +107,7 @@ __decorate([
107
107
  __metadata("design:type", String)
108
108
  ], DailyPaymentStatus.prototype, "rejectionCorrectionReasonDescription", void 0);
109
109
  __decorate([
110
- (0, typeorm_1.ManyToOne)((type) => transactions_entity_1.Transactions),
110
+ (0, typeorm_1.ManyToOne)(() => transactions_entity_1.Transactions),
111
111
  (0, typeorm_1.JoinColumn)({
112
112
  name: 'payment_reference',
113
113
  referencedColumnName: 'transactionId',
@@ -28,5 +28,5 @@ export declare class Transactions {
28
28
  callbackstatus: string;
29
29
  callDrivers: CallDriverData[];
30
30
  dailyPaymentStatus: DailyPaymentStatus[];
31
- activeLoad: ActiveLoad;
31
+ activeLoads: ActiveLoad[];
32
32
  }
@@ -121,12 +121,11 @@ __decorate([
121
121
  __metadata("design:type", Array)
122
122
  ], Transactions.prototype, "dailyPaymentStatus", void 0);
123
123
  __decorate([
124
- (0, typeorm_1.OneToOne)(() => active_loads_entity_1.ActiveLoad, {
124
+ (0, typeorm_1.OneToMany)(() => active_loads_entity_1.ActiveLoad, (cdd) => cdd.transaction, {
125
125
  cascade: ['insert', 'update', 'remove'],
126
126
  }),
127
- (0, typeorm_1.JoinColumn)({ name: 'transaction_id' }),
128
- __metadata("design:type", active_loads_entity_1.ActiveLoad)
129
- ], Transactions.prototype, "activeLoad", void 0);
127
+ __metadata("design:type", Array)
128
+ ], Transactions.prototype, "activeLoads", void 0);
130
129
  Transactions = __decorate([
131
130
  (0, typeorm_1.Entity)('transactions', { schema: 'tracking' })
132
131
  ], Transactions);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uniorganization/uni-lib",
3
- "version": "1.1.43",
3
+ "version": "1.1.44",
4
4
  "description": "UNI Library",
5
5
  "author": "Jhomiguel",
6
6
  "main": "dist/index.js",