@spytecgps/nova-orm 1.4.176 → 1.4.178

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 +1 @@
1
- "use strict";var e=require("../node_modules/tslib/tslib.es6.js"),t=require("typeorm"),r=require("../utils/boolToNumberTransformer.js"),a=require("../utils/uuidTransformer.js"),o=require("./retailAlertType.js");exports.RetailAlert=class RetailAlert{id;alertTypeId;clientId;alertType;value;createdAt;storeId;zoneId;isNotification;retailClientAlertConfigurationId;deleted;status},e.__decorate([t.PrimaryGeneratedColumn({type:"bigint",name:"id"}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"id",void 0),e.__decorate([t.Column("tinyint",{name:"alertTypeId"}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"alertTypeId",void 0),e.__decorate([t.Column("int",{name:"clientId"}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"clientId",void 0),e.__decorate([t.OneToOne((()=>o.RetailAlertType),{createForeignKeyConstraints:!1}),t.JoinColumn({name:"alertTypeId",referencedColumnName:"id"}),e.__metadata("design:type",Object)],exports.RetailAlert.prototype,"alertType",void 0),e.__decorate([t.Column("varchar",{name:"value",nullable:!0,length:5e3}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"value",void 0),e.__decorate([t.CreateDateColumn({name:"createdAt"}),e.__metadata("design:type",Date)],exports.RetailAlert.prototype,"createdAt",void 0),e.__decorate([t.Column("binary",{name:"storeId",length:16,transformer:a.UUIDTransformer}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"storeId",void 0),e.__decorate([t.Column("binary",{name:"zoneId",length:16,transformer:a.UUIDTransformer,nullable:!0}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"zoneId",void 0),e.__decorate([t.Column("tinyint",{name:"isNotification",nullable:!0,width:1}),e.__metadata("design:type",Boolean)],exports.RetailAlert.prototype,"isNotification",void 0),e.__decorate([t.Column("int",{name:"retailClientAlertConfigurationId",nullable:!0}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"retailClientAlertConfigurationId",void 0),e.__decorate([t.Column("tinyint",{name:"deleted",nullable:!0,width:1,transformer:new r.BoolToNumberTransformer,default:()=>"'0'"}),e.__metadata("design:type",Boolean)],exports.RetailAlert.prototype,"deleted",void 0),e.__decorate([t.Column("varchar",{name:"status",nullable:!0,length:50,default:()=>"'new'"}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"status",void 0),exports.RetailAlert=e.__decorate([t.Index("ix_clientId_createdAt",["clientId","createdAt"],{}),t.Index("ix_clientId_storeId_createdAt",["clientId","storeId","createdAt"],{}),t.Index("ix_clientId_zoneId_createdAt",["clientId","zoneId","createdAt"],{}),t.Index("ix_clientId_alertTypeId_createdAt",["clientId","alertTypeId","createdAt"],{}),t.Entity("retailAlert",{schema:"nova"})],exports.RetailAlert);
1
+ "use strict";var e=require("../node_modules/tslib/tslib.es6.js"),t=require("typeorm"),a=require("../utils/boolToNumberTransformer.js"),r=require("../utils/uuidTransformer.js"),o=require("./retailAlertType.js");exports.RetailAlert=class RetailAlert{id;alertTypeId;clientId;alertType;value;message;createdAt;storeId;zoneId;isNotification;retailClientAlertConfigurationId;severity;deleted;status;acknowledgedAt;resolvedAt},e.__decorate([t.PrimaryGeneratedColumn({type:"bigint",name:"id"}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"id",void 0),e.__decorate([t.Column("tinyint",{name:"alertTypeId"}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"alertTypeId",void 0),e.__decorate([t.Column("int",{name:"clientId"}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"clientId",void 0),e.__decorate([t.OneToOne((()=>o.RetailAlertType),{createForeignKeyConstraints:!1}),t.JoinColumn({name:"alertTypeId",referencedColumnName:"id"}),e.__metadata("design:type",Object)],exports.RetailAlert.prototype,"alertType",void 0),e.__decorate([t.Column("varchar",{name:"value",nullable:!0,length:5e3}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"value",void 0),e.__decorate([t.Column("varchar",{name:"message",length:1e3}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"message",void 0),e.__decorate([t.CreateDateColumn({name:"createdAt"}),e.__metadata("design:type",Date)],exports.RetailAlert.prototype,"createdAt",void 0),e.__decorate([t.Column("binary",{name:"storeId",length:16,transformer:r.UUIDTransformer}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"storeId",void 0),e.__decorate([t.Column("binary",{name:"zoneId",length:16,transformer:r.UUIDTransformer,nullable:!0}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"zoneId",void 0),e.__decorate([t.Column("tinyint",{name:"isNotification",nullable:!0,width:1}),e.__metadata("design:type",Boolean)],exports.RetailAlert.prototype,"isNotification",void 0),e.__decorate([t.Column("int",{name:"retailClientAlertConfigurationId",nullable:!0}),e.__metadata("design:type",Number)],exports.RetailAlert.prototype,"retailClientAlertConfigurationId",void 0),e.__decorate([t.Column("varchar",{name:"severity",length:50}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"severity",void 0),e.__decorate([t.Column("tinyint",{name:"deleted",nullable:!0,width:1,transformer:new a.BoolToNumberTransformer,default:()=>"'0'"}),e.__metadata("design:type",Boolean)],exports.RetailAlert.prototype,"deleted",void 0),e.__decorate([t.Column("varchar",{name:"status",nullable:!0,length:50,default:()=>"'new'"}),e.__metadata("design:type",String)],exports.RetailAlert.prototype,"status",void 0),e.__decorate([t.Column("datetime",{name:"acknowledgedAt",nullable:!0}),e.__metadata("design:type",Date)],exports.RetailAlert.prototype,"acknowledgedAt",void 0),e.__decorate([t.Column("datetime",{name:"resolvedAt",nullable:!0}),e.__metadata("design:type",Date)],exports.RetailAlert.prototype,"resolvedAt",void 0),exports.RetailAlert=e.__decorate([t.Index("ix_clientId_createdAt",["clientId","createdAt"],{}),t.Index("ix_clientId_storeId_createdAt",["clientId","storeId","createdAt"],{}),t.Index("ix_clientId_zoneId_createdAt",["clientId","zoneId","createdAt"],{}),t.Index("ix_clientId_alertTypeId_createdAt",["clientId","alertTypeId","createdAt"],{}),t.Entity("retailAlert",{schema:"nova"})],exports.RetailAlert);
@@ -1,5 +1,6 @@
1
1
  import { Relation } from 'typeorm';
2
2
  import { RetailAlertType } from './retailAlertType';
3
+ import { RetailAlertSeverity } from './retailClientAlertConfiguration';
3
4
  export type RetailAlertStatus = 'new' | 'acknowledged' | 'resolved' | 'dismissed';
4
5
  export declare class RetailAlert {
5
6
  id: number;
@@ -7,11 +8,15 @@ export declare class RetailAlert {
7
8
  clientId: number;
8
9
  alertType?: Relation<RetailAlertType>;
9
10
  value?: string | null;
11
+ message?: string;
10
12
  createdAt: Date;
11
13
  storeId: string;
12
14
  zoneId?: string | null;
13
15
  isNotification?: boolean | null;
14
16
  retailClientAlertConfigurationId?: number | null;
17
+ severity: RetailAlertSeverity;
15
18
  deleted: boolean | null;
16
19
  status: RetailAlertStatus;
20
+ acknowledgedAt?: Date | null;
21
+ resolvedAt?: Date | null;
17
22
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spytecgps/nova-orm",
3
- "version": "1.4.176",
3
+ "version": "1.4.178",
4
4
  "description": "ORM with PlanetScale",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
package/schema.sql CHANGED
@@ -1,6 +1,6 @@
1
- -- nova-orm-schema-checksum: 7d82dc58e39b3abe03513f092f22a195
1
+ -- nova-orm-schema-checksum: 2e67a34b008fc25d3b5f6b4f1eea5262
2
2
  -- Nova ORM Schema Dump
3
- -- Generated at: 2026-02-16T10:44:32.021Z
3
+ -- Generated at: 2026-02-16T11:23:28.835Z
4
4
 
5
5
  SET FOREIGN_KEY_CHECKS = 0;
6
6
 
@@ -2431,13 +2431,17 @@ CREATE TABLE `retailAlert` (
2431
2431
  `alertTypeId` tinyint NOT NULL,
2432
2432
  `clientId` int NOT NULL,
2433
2433
  `value` varchar(5000) DEFAULT NULL,
2434
+ `message` varchar(1000) NOT NULL,
2434
2435
  `createdAt` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
2435
2436
  `storeId` binary(16) NOT NULL,
2436
2437
  `zoneId` binary(16) DEFAULT NULL,
2437
2438
  `isNotification` tinyint(1) DEFAULT NULL,
2438
2439
  `retailClientAlertConfigurationId` int DEFAULT NULL,
2440
+ `severity` varchar(50) NOT NULL,
2439
2441
  `deleted` tinyint(1) DEFAULT '0',
2440
2442
  `status` varchar(50) DEFAULT 'new',
2443
+ `acknowledgedAt` datetime DEFAULT NULL,
2444
+ `resolvedAt` datetime DEFAULT NULL,
2441
2445
  PRIMARY KEY (`id`),
2442
2446
  KEY `ix_clientId_alertTypeId_createdAt` (`clientId`,`alertTypeId`,`createdAt`),
2443
2447
  KEY `ix_clientId_zoneId_createdAt` (`clientId`,`zoneId`,`createdAt`),