@spytecgps/nova-orm 0.0.4 → 0.0.5
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/README.md +2 -0
- package/dist/entities/alert.d.ts +25 -0
- package/dist/entities/alert.js +118 -0
- package/dist/entities/alertType.d.ts +14 -0
- package/dist/entities/alertType.js +65 -0
- package/dist/entities/assetCategory.d.ts +5 -0
- package/dist/entities/assetCategory.js +29 -0
- package/dist/entities/billing.d.ts +15 -0
- package/dist/entities/billing.js +81 -0
- package/dist/entities/billingCustomerBraintree.d.ts +11 -0
- package/dist/entities/billingCustomerBraintree.js +53 -0
- package/dist/entities/billingDeviceHistory.d.ts +11 -0
- package/dist/entities/billingDeviceHistory.js +52 -0
- package/dist/entities/billingStatusHistoryBraintree.d.ts +10 -0
- package/dist/entities/billingStatusHistoryBraintree.js +55 -0
- package/dist/entities/billingSubscriptionBraintree.d.ts +34 -0
- package/dist/entities/billingSubscriptionBraintree.js +169 -0
- package/dist/entities/blacklist.d.ts +9 -0
- package/dist/entities/blacklist.js +44 -0
- package/dist/entities/blacklistType.d.ts +5 -0
- package/dist/entities/blacklistType.js +28 -0
- package/dist/entities/cellTower.d.ts +12 -0
- package/dist/entities/cellTower.js +56 -0
- package/dist/entities/client.d.ts +22 -0
- package/dist/entities/client.js +96 -0
- package/dist/entities/clientConfiguration.d.ts +7 -0
- package/dist/entities/clientConfiguration.js +42 -0
- package/dist/entities/clientDeviceSetting.d.ts +14 -0
- package/dist/entities/clientDeviceSetting.js +76 -0
- package/dist/entities/clientType.d.ts +6 -0
- package/dist/entities/clientType.js +32 -0
- package/dist/entities/country.d.ts +16 -0
- package/dist/entities/country.js +76 -0
- package/dist/entities/dataSourceType.d.ts +5 -0
- package/dist/entities/dataSourceType.js +28 -0
- package/dist/entities/deactivation.d.ts +12 -0
- package/dist/entities/deactivation.js +63 -0
- package/dist/entities/deactivationReason.d.ts +6 -0
- package/dist/entities/deactivationReason.js +36 -0
- package/dist/entities/device.d.ts +31 -0
- package/dist/entities/device.js +123 -0
- package/dist/entities/deviceBehavior.d.ts +22 -0
- package/dist/entities/deviceBehavior.js +105 -0
- package/dist/entities/deviceHistory.d.ts +9 -0
- package/dist/entities/deviceHistory.js +44 -0
- package/dist/entities/deviceModelListener.d.ts +8 -0
- package/dist/entities/deviceModelListener.js +40 -0
- package/dist/entities/deviceReplacement.d.ts +11 -0
- package/dist/entities/deviceReplacement.js +49 -0
- package/dist/entities/deviceType.d.ts +23 -0
- package/dist/entities/deviceType.js +100 -0
- package/dist/entities/deviceTypeEvent.d.ts +5 -0
- package/dist/entities/deviceTypeEvent.js +29 -0
- package/dist/entities/deviceTypeFeature.d.ts +5 -0
- package/dist/entities/deviceTypeFeature.js +29 -0
- package/dist/entities/deviceTypeFirmware.d.ts +11 -0
- package/dist/entities/deviceTypeFirmware.js +57 -0
- package/dist/entities/entityTag.d.ts +8 -0
- package/dist/entities/entityTag.js +42 -0
- package/dist/entities/entityType.d.ts +5 -0
- package/dist/entities/entityType.js +28 -0
- package/dist/entities/event.d.ts +6 -0
- package/dist/entities/event.js +32 -0
- package/dist/entities/feature.d.ts +6 -0
- package/dist/entities/feature.js +32 -0
- package/dist/entities/firmwareUpgradeTask.d.ts +12 -0
- package/dist/entities/firmwareUpgradeTask.js +53 -0
- package/dist/entities/geofence.d.ts +20 -0
- package/dist/entities/geofence.js +86 -0
- package/dist/entities/geofenceEvent.d.ts +19 -0
- package/dist/entities/geofenceEvent.js +87 -0
- package/dist/entities/imeiIccidCarrier.d.ts +16 -0
- package/dist/entities/imeiIccidCarrier.js +78 -0
- package/dist/entities/imeiIccidHistory.d.ts +7 -0
- package/dist/entities/imeiIccidHistory.js +38 -0
- package/dist/entities/index.d.ts +68 -0
- package/dist/entities/index.js +68 -0
- package/dist/entities/industry.d.ts +8 -0
- package/dist/entities/industry.js +40 -0
- package/dist/entities/mobileNetwork.d.ts +9 -0
- package/dist/entities/mobileNetwork.js +44 -0
- package/dist/entities/notificationRecipient.d.ts +14 -0
- package/dist/entities/notificationRecipient.js +70 -0
- package/dist/entities/organization.d.ts +9 -0
- package/dist/entities/organization.js +40 -0
- package/dist/entities/plan.d.ts +16 -0
- package/dist/entities/plan.js +72 -0
- package/dist/entities/position.d.ts +18 -0
- package/dist/entities/position.js +84 -0
- package/dist/entities/securityRole.d.ts +7 -0
- package/dist/entities/securityRole.js +36 -0
- package/dist/entities/serviceProvider.d.ts +7 -0
- package/dist/entities/serviceProvider.js +36 -0
- package/dist/entities/serviceProviderProduct.d.ts +9 -0
- package/dist/entities/serviceProviderProduct.js +54 -0
- package/dist/entities/serviceProviderProductNetwork.d.ts +5 -0
- package/dist/entities/serviceProviderProductNetwork.js +28 -0
- package/dist/entities/serviceProviderProductType.d.ts +5 -0
- package/dist/entities/serviceProviderProductType.js +28 -0
- package/dist/entities/sim.d.ts +16 -0
- package/dist/entities/sim.js +78 -0
- package/dist/entities/trip.d.ts +24 -0
- package/dist/entities/trip.js +103 -0
- package/dist/entities/tripCompletionStatus.d.ts +6 -0
- package/dist/entities/tripCompletionStatus.js +32 -0
- package/dist/entities/tripPosition.d.ts +4 -0
- package/dist/entities/tripPosition.js +24 -0
- package/dist/entities/user.d.ts +25 -0
- package/dist/entities/user.js +116 -0
- package/dist/entities/userActivation.d.ts +9 -0
- package/dist/entities/userActivation.js +45 -0
- package/dist/entities/userActivationDevice.d.ts +22 -0
- package/dist/entities/userActivationDevice.js +105 -0
- package/dist/entities/userActivationEvent.d.ts +12 -0
- package/dist/entities/userActivationEvent.js +52 -0
- package/dist/entities/userActivationMetric.d.ts +38 -0
- package/dist/entities/userActivationMetric.js +167 -0
- package/dist/entities/userAlertConfiguration.d.ts +13 -0
- package/dist/entities/userAlertConfiguration.js +68 -0
- package/dist/entities/userAppFeedback.d.ts +10 -0
- package/dist/entities/userAppFeedback.js +45 -0
- package/dist/entities/userAppIncident.d.ts +29 -0
- package/dist/entities/userAppIncident.js +131 -0
- package/dist/entities/userConfiguration.d.ts +18 -0
- package/dist/entities/userConfiguration.js +87 -0
- package/dist/entities/userDataDeletionRequest.d.ts +11 -0
- package/dist/entities/userDataDeletionRequest.js +48 -0
- package/dist/entities/userDeviceBehaviorTask.d.ts +14 -0
- package/dist/entities/userDeviceBehaviorTask.js +61 -0
- package/dist/entities/userInvitation.d.ts +17 -0
- package/dist/entities/userInvitation.js +75 -0
- package/dist/entities/userRatingRequest.d.ts +13 -0
- package/dist/entities/userRatingRequest.js +63 -0
- package/dist/entities/userRegistrationAttempt.d.ts +35 -0
- package/dist/entities/userRegistrationAttempt.js +145 -0
- package/dist/entities/userSecurityRole.d.ts +6 -0
- package/dist/entities/userSecurityRole.js +30 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +5 -0
- package/dist/novaDataSource.d.ts +56 -0
- package/dist/novaDataSource.js +59 -0
- package/dist/repositories/baseRepository.d.ts +5 -0
- package/dist/repositories/baseRepository.js +5 -0
- package/dist/repositories/devicesRepository.d.ts +24 -0
- package/dist/repositories/devicesRepository.js +122 -0
- package/dist/repositories/index.d.ts +3 -0
- package/dist/repositories/index.js +3 -0
- package/dist/repositories/securityRepository.d.ts +21 -0
- package/dist/repositories/securityRepository.js +99 -0
- package/dist/types/enums.d.ts +9 -0
- package/dist/types/enums.js +11 -0
- package/dist/utils/uuidHelpers.d.ts +2 -0
- package/dist/utils/uuidHelpers.js +6 -0
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
# Hapn ORM for Planet Scale
|
|
2
2
|
|
|
3
|
+
This package contains repositories and entities to connect to Planet Scale database using typeorm
|
|
4
|
+
|
|
3
5
|
# SYNC the entities definition with Planet Scale schema:
|
|
4
6
|
|
|
5
7
|
1- Modify the url value for the data source in the file data-source.ts to use the dev branch connection string
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
export declare class Alert {
|
|
3
|
+
id: string;
|
|
4
|
+
alertTypeId: number;
|
|
5
|
+
value: string | null;
|
|
6
|
+
createdAt: Date | null;
|
|
7
|
+
userId: Buffer | null;
|
|
8
|
+
messageId: Buffer;
|
|
9
|
+
geofenceId: number | null;
|
|
10
|
+
deviceId: number | null;
|
|
11
|
+
imei: string;
|
|
12
|
+
sendTime: Date;
|
|
13
|
+
lat: number | null;
|
|
14
|
+
lon: number | null;
|
|
15
|
+
address: string | null;
|
|
16
|
+
clientId: number | null;
|
|
17
|
+
fromMigration: boolean | null;
|
|
18
|
+
isBuffer: boolean | null;
|
|
19
|
+
isNotification: boolean | null;
|
|
20
|
+
eventUtcTime: Date | null;
|
|
21
|
+
gpsUtcTime: Date | null;
|
|
22
|
+
relevantAddress: string | null;
|
|
23
|
+
gpsMessageId: Buffer | null;
|
|
24
|
+
cellTowerRelevantAddress: string | null;
|
|
25
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Column, Entity, Index, PrimaryGeneratedColumn } from 'typeorm';
|
|
11
|
+
let Alert = class Alert {
|
|
12
|
+
};
|
|
13
|
+
__decorate([
|
|
14
|
+
PrimaryGeneratedColumn({ type: 'bigint', name: 'id' }),
|
|
15
|
+
__metadata("design:type", String)
|
|
16
|
+
], Alert.prototype, "id", void 0);
|
|
17
|
+
__decorate([
|
|
18
|
+
Column('tinyint', { name: 'alertTypeId' }),
|
|
19
|
+
__metadata("design:type", Number)
|
|
20
|
+
], Alert.prototype, "alertTypeId", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
Column('varchar', { name: 'value', nullable: true, length: 50 }),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], Alert.prototype, "value", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
Column('datetime', { name: 'createdAt', nullable: true }),
|
|
27
|
+
__metadata("design:type", Date)
|
|
28
|
+
], Alert.prototype, "createdAt", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
Column('binary', { name: 'userId', nullable: true, length: 16 }),
|
|
31
|
+
__metadata("design:type", Buffer)
|
|
32
|
+
], Alert.prototype, "userId", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
Column('binary', { name: 'messageId', length: 16 }),
|
|
35
|
+
__metadata("design:type", Buffer)
|
|
36
|
+
], Alert.prototype, "messageId", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
Column('mediumint', { name: 'geofenceId', nullable: true }),
|
|
39
|
+
__metadata("design:type", Number)
|
|
40
|
+
], Alert.prototype, "geofenceId", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
Column('int', { name: 'deviceId', nullable: true }),
|
|
43
|
+
__metadata("design:type", Number)
|
|
44
|
+
], Alert.prototype, "deviceId", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
Column('varchar', { name: 'imei', length: 15 }),
|
|
47
|
+
__metadata("design:type", String)
|
|
48
|
+
], Alert.prototype, "imei", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
Column('datetime', { name: 'sendTime' }),
|
|
51
|
+
__metadata("design:type", Date)
|
|
52
|
+
], Alert.prototype, "sendTime", void 0);
|
|
53
|
+
__decorate([
|
|
54
|
+
Column('double', { name: 'lat', nullable: true }),
|
|
55
|
+
__metadata("design:type", Number)
|
|
56
|
+
], Alert.prototype, "lat", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
Column('double', { name: 'lon', nullable: true }),
|
|
59
|
+
__metadata("design:type", Number)
|
|
60
|
+
], Alert.prototype, "lon", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
Column('varchar', { name: 'address', nullable: true, length: 255 }),
|
|
63
|
+
__metadata("design:type", String)
|
|
64
|
+
], Alert.prototype, "address", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
Column('int', { name: 'clientId', nullable: true }),
|
|
67
|
+
__metadata("design:type", Number)
|
|
68
|
+
], Alert.prototype, "clientId", void 0);
|
|
69
|
+
__decorate([
|
|
70
|
+
Column('tinyint', {
|
|
71
|
+
name: 'fromMigration',
|
|
72
|
+
nullable: true,
|
|
73
|
+
width: 1,
|
|
74
|
+
default: () => "'0'",
|
|
75
|
+
}),
|
|
76
|
+
__metadata("design:type", Boolean)
|
|
77
|
+
], Alert.prototype, "fromMigration", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
Column('tinyint', { name: 'isBuffer', nullable: true, width: 1 }),
|
|
80
|
+
__metadata("design:type", Boolean)
|
|
81
|
+
], Alert.prototype, "isBuffer", void 0);
|
|
82
|
+
__decorate([
|
|
83
|
+
Column('tinyint', { name: 'isNotification', nullable: true, width: 1 }),
|
|
84
|
+
__metadata("design:type", Boolean)
|
|
85
|
+
], Alert.prototype, "isNotification", void 0);
|
|
86
|
+
__decorate([
|
|
87
|
+
Column('datetime', { name: 'eventUtcTime', nullable: true }),
|
|
88
|
+
__metadata("design:type", Date)
|
|
89
|
+
], Alert.prototype, "eventUtcTime", void 0);
|
|
90
|
+
__decorate([
|
|
91
|
+
Column('datetime', { name: 'gpsUtcTime', nullable: true }),
|
|
92
|
+
__metadata("design:type", Date)
|
|
93
|
+
], Alert.prototype, "gpsUtcTime", void 0);
|
|
94
|
+
__decorate([
|
|
95
|
+
Column('varchar', { name: 'relevantAddress', nullable: true, length: 255 }),
|
|
96
|
+
__metadata("design:type", String)
|
|
97
|
+
], Alert.prototype, "relevantAddress", void 0);
|
|
98
|
+
__decorate([
|
|
99
|
+
Column('binary', { name: 'gpsMessageId', nullable: true, length: 16 }),
|
|
100
|
+
__metadata("design:type", Buffer)
|
|
101
|
+
], Alert.prototype, "gpsMessageId", void 0);
|
|
102
|
+
__decorate([
|
|
103
|
+
Column('varchar', {
|
|
104
|
+
name: 'cellTowerRelevantAddress',
|
|
105
|
+
nullable: true,
|
|
106
|
+
length: 255,
|
|
107
|
+
}),
|
|
108
|
+
__metadata("design:type", String)
|
|
109
|
+
], Alert.prototype, "cellTowerRelevantAddress", void 0);
|
|
110
|
+
Alert = __decorate([
|
|
111
|
+
Index('ixAlertAlertTypeId', ['alertTypeId'], {}),
|
|
112
|
+
Index('ixAlertClientId', ['clientId'], {}),
|
|
113
|
+
Index('ixAlertImei', ['imei'], {}),
|
|
114
|
+
Index('ixAlertSendTime', ['sendTime'], {}),
|
|
115
|
+
Index('ixAlertUserId', ['userId'], {}),
|
|
116
|
+
Entity('alert', { schema: 'nova' })
|
|
117
|
+
], Alert);
|
|
118
|
+
export { Alert };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export declare class AlertType {
|
|
2
|
+
id: number;
|
|
3
|
+
name: string;
|
|
4
|
+
title: string | null;
|
|
5
|
+
description: string | null;
|
|
6
|
+
isSystem: boolean;
|
|
7
|
+
icon: string | null;
|
|
8
|
+
context: string | null;
|
|
9
|
+
identifier: string | null;
|
|
10
|
+
stage: string | null;
|
|
11
|
+
category: string | null;
|
|
12
|
+
key: string | null;
|
|
13
|
+
createdAt: Date | null;
|
|
14
|
+
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Column, Entity, Index, PrimaryGeneratedColumn } from 'typeorm';
|
|
11
|
+
let AlertType = class AlertType {
|
|
12
|
+
};
|
|
13
|
+
__decorate([
|
|
14
|
+
PrimaryGeneratedColumn({ type: 'tinyint', name: 'id' }),
|
|
15
|
+
__metadata("design:type", Number)
|
|
16
|
+
], AlertType.prototype, "id", void 0);
|
|
17
|
+
__decorate([
|
|
18
|
+
Column('varchar', { name: 'name', length: 50 }),
|
|
19
|
+
__metadata("design:type", String)
|
|
20
|
+
], AlertType.prototype, "name", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
Column('varchar', { name: 'title', nullable: true, length: 255 }),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], AlertType.prototype, "title", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
Column('varchar', { name: 'description', nullable: true, length: 2000 }),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], AlertType.prototype, "description", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
Column('tinyint', { name: 'isSystem', width: 1, default: () => "'0'" }),
|
|
31
|
+
__metadata("design:type", Boolean)
|
|
32
|
+
], AlertType.prototype, "isSystem", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
Column('varchar', { name: 'icon', nullable: true, length: 50 }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], AlertType.prototype, "icon", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
Column('varchar', { name: 'context', nullable: true, length: 25 }),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], AlertType.prototype, "context", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
Column('varchar', { name: 'identifier', nullable: true, length: 50 }),
|
|
43
|
+
__metadata("design:type", String)
|
|
44
|
+
], AlertType.prototype, "identifier", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
Column('varchar', { name: 'stage', nullable: true, length: 10 }),
|
|
47
|
+
__metadata("design:type", String)
|
|
48
|
+
], AlertType.prototype, "stage", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
Column('varchar', { name: 'category', nullable: true, length: 25 }),
|
|
51
|
+
__metadata("design:type", String)
|
|
52
|
+
], AlertType.prototype, "category", void 0);
|
|
53
|
+
__decorate([
|
|
54
|
+
Column('varchar', { name: 'key', nullable: true, length: 25 }),
|
|
55
|
+
__metadata("design:type", String)
|
|
56
|
+
], AlertType.prototype, "key", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
Column('datetime', { name: 'createdAt', nullable: true }),
|
|
59
|
+
__metadata("design:type", Date)
|
|
60
|
+
], AlertType.prototype, "createdAt", void 0);
|
|
61
|
+
AlertType = __decorate([
|
|
62
|
+
Index('ixAlertTypeStage', ['stage'], {}),
|
|
63
|
+
Entity('alertType', { schema: 'nova' })
|
|
64
|
+
], AlertType);
|
|
65
|
+
export { AlertType };
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Column, Entity, Index, PrimaryGeneratedColumn } from 'typeorm';
|
|
11
|
+
let AssetCategory = class AssetCategory {
|
|
12
|
+
};
|
|
13
|
+
__decorate([
|
|
14
|
+
PrimaryGeneratedColumn({ type: 'tinyint', name: 'id' }),
|
|
15
|
+
__metadata("design:type", Number)
|
|
16
|
+
], AssetCategory.prototype, "id", void 0);
|
|
17
|
+
__decorate([
|
|
18
|
+
Column('varchar', { name: 'name', length: 50 }),
|
|
19
|
+
__metadata("design:type", String)
|
|
20
|
+
], AssetCategory.prototype, "name", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
Column('varchar', { name: 'description', nullable: true, length: 255 }),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], AssetCategory.prototype, "description", void 0);
|
|
25
|
+
AssetCategory = __decorate([
|
|
26
|
+
Index('ixuAssetCategoryName', ['name'], { unique: true }),
|
|
27
|
+
Entity('assetCategory', { schema: 'nova' })
|
|
28
|
+
], AssetCategory);
|
|
29
|
+
export { AssetCategory };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare class Billing {
|
|
2
|
+
id: number;
|
|
3
|
+
deviceId: number | null;
|
|
4
|
+
imei: string | null;
|
|
5
|
+
planId: string | null;
|
|
6
|
+
subscriptionId: string | null;
|
|
7
|
+
platform: string | null;
|
|
8
|
+
status: string | null;
|
|
9
|
+
createdAt: Date | null;
|
|
10
|
+
updatedAt: Date | null;
|
|
11
|
+
subscriptionValue: string | null;
|
|
12
|
+
subscriptionPeriodMonths: number | null;
|
|
13
|
+
subscriptionValueMonthly: string | null;
|
|
14
|
+
clientId: number | null;
|
|
15
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Column, Entity, Index, PrimaryGeneratedColumn } from 'typeorm';
|
|
11
|
+
let Billing = class Billing {
|
|
12
|
+
};
|
|
13
|
+
__decorate([
|
|
14
|
+
PrimaryGeneratedColumn({ type: 'int', name: 'id' }),
|
|
15
|
+
__metadata("design:type", Number)
|
|
16
|
+
], Billing.prototype, "id", void 0);
|
|
17
|
+
__decorate([
|
|
18
|
+
Column('int', { name: 'deviceId', nullable: true }),
|
|
19
|
+
__metadata("design:type", Number)
|
|
20
|
+
], Billing.prototype, "deviceId", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
Column('varchar', { name: 'imei', nullable: true, length: 15 }),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], Billing.prototype, "imei", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
Column('varchar', { name: 'planId', nullable: true, length: 50 }),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], Billing.prototype, "planId", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
Column('varchar', { name: 'subscriptionId', nullable: true, length: 50 }),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], Billing.prototype, "subscriptionId", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
Column('varchar', { name: 'platform', nullable: true, length: 25 }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], Billing.prototype, "platform", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
Column('varchar', { name: 'status', nullable: true, length: 10 }),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], Billing.prototype, "status", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
Column('datetime', { name: 'createdAt', nullable: true }),
|
|
43
|
+
__metadata("design:type", Date)
|
|
44
|
+
], Billing.prototype, "createdAt", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
Column('datetime', { name: 'updatedAt', nullable: true }),
|
|
47
|
+
__metadata("design:type", Date)
|
|
48
|
+
], Billing.prototype, "updatedAt", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
Column('decimal', {
|
|
51
|
+
name: 'subscriptionValue',
|
|
52
|
+
nullable: true,
|
|
53
|
+
precision: 19,
|
|
54
|
+
scale: 4,
|
|
55
|
+
}),
|
|
56
|
+
__metadata("design:type", String)
|
|
57
|
+
], Billing.prototype, "subscriptionValue", void 0);
|
|
58
|
+
__decorate([
|
|
59
|
+
Column('tinyint', { name: 'subscriptionPeriodMonths', nullable: true }),
|
|
60
|
+
__metadata("design:type", Number)
|
|
61
|
+
], Billing.prototype, "subscriptionPeriodMonths", void 0);
|
|
62
|
+
__decorate([
|
|
63
|
+
Column('decimal', {
|
|
64
|
+
name: 'subscriptionValueMonthly',
|
|
65
|
+
nullable: true,
|
|
66
|
+
precision: 19,
|
|
67
|
+
scale: 4,
|
|
68
|
+
}),
|
|
69
|
+
__metadata("design:type", String)
|
|
70
|
+
], Billing.prototype, "subscriptionValueMonthly", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
Column('int', { name: 'clientId', nullable: true }),
|
|
73
|
+
__metadata("design:type", Number)
|
|
74
|
+
], Billing.prototype, "clientId", void 0);
|
|
75
|
+
Billing = __decorate([
|
|
76
|
+
Index('ixuBillingImei', ['imei'], { unique: true }),
|
|
77
|
+
Index('ixBillingClientId', ['clientId'], {}),
|
|
78
|
+
Index('ixBillingPlanId', ['planId'], {}),
|
|
79
|
+
Entity('billing', { schema: 'nova' })
|
|
80
|
+
], Billing);
|
|
81
|
+
export { Billing };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare class BillingCustomerBraintree {
|
|
2
|
+
id: string;
|
|
3
|
+
firstName: string | null;
|
|
4
|
+
lastName: string | null;
|
|
5
|
+
company: string | null;
|
|
6
|
+
email: string | null;
|
|
7
|
+
phone: string | null;
|
|
8
|
+
createdAt: Date | null;
|
|
9
|
+
updatedAt: Date | null;
|
|
10
|
+
churnStatus: string | null;
|
|
11
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Column, Entity, Index } from 'typeorm';
|
|
11
|
+
let BillingCustomerBraintree = class BillingCustomerBraintree {
|
|
12
|
+
};
|
|
13
|
+
__decorate([
|
|
14
|
+
Column('varchar', { primary: true, name: 'id', length: 50 }),
|
|
15
|
+
__metadata("design:type", String)
|
|
16
|
+
], BillingCustomerBraintree.prototype, "id", void 0);
|
|
17
|
+
__decorate([
|
|
18
|
+
Column('varchar', { name: 'firstName', nullable: true, length: 50 }),
|
|
19
|
+
__metadata("design:type", String)
|
|
20
|
+
], BillingCustomerBraintree.prototype, "firstName", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
Column('varchar', { name: 'lastName', nullable: true, length: 50 }),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], BillingCustomerBraintree.prototype, "lastName", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
Column('varchar', { name: 'company', nullable: true, length: 100 }),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], BillingCustomerBraintree.prototype, "company", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
Column('varchar', { name: 'email', nullable: true, length: 255 }),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], BillingCustomerBraintree.prototype, "email", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
Column('varchar', { name: 'phone', nullable: true, length: 50 }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], BillingCustomerBraintree.prototype, "phone", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
Column('datetime', { name: 'createdAt', nullable: true }),
|
|
39
|
+
__metadata("design:type", Date)
|
|
40
|
+
], BillingCustomerBraintree.prototype, "createdAt", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
Column('datetime', { name: 'updatedAt', nullable: true }),
|
|
43
|
+
__metadata("design:type", Date)
|
|
44
|
+
], BillingCustomerBraintree.prototype, "updatedAt", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
Column('varchar', { name: 'churnStatus', nullable: true, length: 50 }),
|
|
47
|
+
__metadata("design:type", String)
|
|
48
|
+
], BillingCustomerBraintree.prototype, "churnStatus", void 0);
|
|
49
|
+
BillingCustomerBraintree = __decorate([
|
|
50
|
+
Index('ixBillingCustomerBraintreeEmail', ['email'], {}),
|
|
51
|
+
Entity('billingCustomerBraintree', { schema: 'nova' })
|
|
52
|
+
], BillingCustomerBraintree);
|
|
53
|
+
export { BillingCustomerBraintree };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare class BillingDeviceHistory {
|
|
2
|
+
id: number;
|
|
3
|
+
clientId: number | null;
|
|
4
|
+
deviceId: number | null;
|
|
5
|
+
imei: string | null;
|
|
6
|
+
planId: string | null;
|
|
7
|
+
subscriptionId: string | null;
|
|
8
|
+
platform: string | null;
|
|
9
|
+
status: string | null;
|
|
10
|
+
createdAt: Date | null;
|
|
11
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm';
|
|
11
|
+
let BillingDeviceHistory = class BillingDeviceHistory {
|
|
12
|
+
};
|
|
13
|
+
__decorate([
|
|
14
|
+
PrimaryGeneratedColumn({ type: 'int', name: 'id' }),
|
|
15
|
+
__metadata("design:type", Number)
|
|
16
|
+
], BillingDeviceHistory.prototype, "id", void 0);
|
|
17
|
+
__decorate([
|
|
18
|
+
Column('int', { name: 'clientId', nullable: true }),
|
|
19
|
+
__metadata("design:type", Number)
|
|
20
|
+
], BillingDeviceHistory.prototype, "clientId", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
Column('int', { name: 'deviceId', nullable: true }),
|
|
23
|
+
__metadata("design:type", Number)
|
|
24
|
+
], BillingDeviceHistory.prototype, "deviceId", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
Column('varchar', { name: 'imei', nullable: true, length: 15 }),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], BillingDeviceHistory.prototype, "imei", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
Column('varchar', { name: 'planId', nullable: true, length: 50 }),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], BillingDeviceHistory.prototype, "planId", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
Column('varchar', { name: 'subscriptionId', nullable: true, length: 50 }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], BillingDeviceHistory.prototype, "subscriptionId", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
Column('varchar', { name: 'platform', nullable: true, length: 25 }),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], BillingDeviceHistory.prototype, "platform", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
Column('varchar', { name: 'status', nullable: true, length: 10 }),
|
|
43
|
+
__metadata("design:type", String)
|
|
44
|
+
], BillingDeviceHistory.prototype, "status", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
Column('datetime', { name: 'createdAt', nullable: true }),
|
|
47
|
+
__metadata("design:type", Date)
|
|
48
|
+
], BillingDeviceHistory.prototype, "createdAt", void 0);
|
|
49
|
+
BillingDeviceHistory = __decorate([
|
|
50
|
+
Entity('billingDeviceHistory', { schema: 'nova' })
|
|
51
|
+
], BillingDeviceHistory);
|
|
52
|
+
export { BillingDeviceHistory };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare class BillingStatusHistoryBraintree {
|
|
2
|
+
id: number;
|
|
3
|
+
timestamp: string | null;
|
|
4
|
+
status: string | null;
|
|
5
|
+
balance: string | null;
|
|
6
|
+
price: string | null;
|
|
7
|
+
currencyIsoCode: string | null;
|
|
8
|
+
planId: string | null;
|
|
9
|
+
subscriptionId: string | null;
|
|
10
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { Column, Entity, Index, PrimaryGeneratedColumn } from 'typeorm';
|
|
11
|
+
let BillingStatusHistoryBraintree = class BillingStatusHistoryBraintree {
|
|
12
|
+
};
|
|
13
|
+
__decorate([
|
|
14
|
+
PrimaryGeneratedColumn({ type: 'int', name: 'id' }),
|
|
15
|
+
__metadata("design:type", Number)
|
|
16
|
+
], BillingStatusHistoryBraintree.prototype, "id", void 0);
|
|
17
|
+
__decorate([
|
|
18
|
+
Column('varchar', { name: 'timestamp', nullable: true, length: 255 }),
|
|
19
|
+
__metadata("design:type", String)
|
|
20
|
+
], BillingStatusHistoryBraintree.prototype, "timestamp", void 0);
|
|
21
|
+
__decorate([
|
|
22
|
+
Column('varchar', { name: 'status', nullable: true, length: 10 }),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], BillingStatusHistoryBraintree.prototype, "status", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
Column('decimal', {
|
|
27
|
+
name: 'balance',
|
|
28
|
+
nullable: true,
|
|
29
|
+
precision: 19,
|
|
30
|
+
scale: 4,
|
|
31
|
+
}),
|
|
32
|
+
__metadata("design:type", String)
|
|
33
|
+
], BillingStatusHistoryBraintree.prototype, "balance", void 0);
|
|
34
|
+
__decorate([
|
|
35
|
+
Column('decimal', { name: 'price', nullable: true, precision: 19, scale: 4 }),
|
|
36
|
+
__metadata("design:type", String)
|
|
37
|
+
], BillingStatusHistoryBraintree.prototype, "price", void 0);
|
|
38
|
+
__decorate([
|
|
39
|
+
Column('varchar', { name: 'currencyIsoCode', nullable: true, length: 3 }),
|
|
40
|
+
__metadata("design:type", String)
|
|
41
|
+
], BillingStatusHistoryBraintree.prototype, "currencyIsoCode", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
Column('varchar', { name: 'planId', nullable: true, length: 50 }),
|
|
44
|
+
__metadata("design:type", String)
|
|
45
|
+
], BillingStatusHistoryBraintree.prototype, "planId", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
Column('varchar', { name: 'subscriptionId', nullable: true, length: 25 }),
|
|
48
|
+
__metadata("design:type", String)
|
|
49
|
+
], BillingStatusHistoryBraintree.prototype, "subscriptionId", void 0);
|
|
50
|
+
BillingStatusHistoryBraintree = __decorate([
|
|
51
|
+
Index('ixBillingStatusHistoryBraintreeSubscriptionIdTimestamp', ['subscriptionId', 'timestamp'], {}),
|
|
52
|
+
Index('ixBillingStatusHistoryBraintreeTimestamp', ['timestamp'], {}),
|
|
53
|
+
Entity('billingStatusHistoryBraintree', { schema: 'nova' })
|
|
54
|
+
], BillingStatusHistoryBraintree);
|
|
55
|
+
export { BillingStatusHistoryBraintree };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
export declare class BillingSubscriptionBraintree {
|
|
2
|
+
subscriptionId: string;
|
|
3
|
+
customerId: string | null;
|
|
4
|
+
planId: string | null;
|
|
5
|
+
createdAt: Date | null;
|
|
6
|
+
updatedAt: Date | null;
|
|
7
|
+
subscriptionStart: string | null;
|
|
8
|
+
subscriptionEnd: string | null;
|
|
9
|
+
nextBillingDate: string | null;
|
|
10
|
+
subscriptionValue: string | null;
|
|
11
|
+
status: string | null;
|
|
12
|
+
subscriptionPeriodMonths: number | null;
|
|
13
|
+
paymentInstrumentType: string | null;
|
|
14
|
+
paymentInstrumentDetails: object | null;
|
|
15
|
+
isPaused: boolean | null;
|
|
16
|
+
discountDetails: object | null;
|
|
17
|
+
addons: object | null;
|
|
18
|
+
balance: string | null;
|
|
19
|
+
currentBillingCycle: number | null;
|
|
20
|
+
daysPastDue: number | null;
|
|
21
|
+
description: string | null;
|
|
22
|
+
descriptor: object | null;
|
|
23
|
+
failureCount: number | null;
|
|
24
|
+
firstBillingDate: string | null;
|
|
25
|
+
merchantAccountId: string | null;
|
|
26
|
+
nextBillingPeriodAmount: string | null;
|
|
27
|
+
numberOfBillingCycles: number | null;
|
|
28
|
+
paidThroughDate: string | null;
|
|
29
|
+
paymentMethodToken: string | null;
|
|
30
|
+
statusHistory: object | null;
|
|
31
|
+
trialDuration: number | null;
|
|
32
|
+
trialDurationUnit: string | null;
|
|
33
|
+
trialPeriod: boolean | null;
|
|
34
|
+
}
|