@spytecgps/nova-orm 1.4.171-rc.2 → 1.4.172

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"),o=require("../types/enums.js"),n=require("../utils/boolToNumberTransformer.js");const i=[o.ChurnNotificationPriority.low,o.ChurnNotificationPriority.moderate,o.ChurnNotificationPriority.high,o.ChurnNotificationPriority.critical],a=[o.ChurnNotificationPhase.payment_failed,o.ChurnNotificationPhase.past_due,o.ChurnNotificationPhase.account_locked,o.ChurnNotificationPhase.prepaid_add_card,o.ChurnNotificationPhase.prepaid_ending_soon,o.ChurnNotificationPhase.add_backup_card];exports.ChurnNotification=class ChurnNotification{id;subscriptionId;customerId;clientId;billingInterval;priority;phase;paymentAttempt;isPaymentFailedPushSent;isPastDuePushSent;isAccountLockedPushSent;isPrepaidAddCardPushSent;isPrepaidEndingSoonPushSent;isAddBackupCardPushSent;resolved;daysInChurn;createdAt;updatedAt},e.__decorate([t.PrimaryGeneratedColumn({type:"int",name:"id",unsigned:!0}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"id",void 0),e.__decorate([t.Column("varchar",{name:"subscriptionId",nullable:!0,length:256}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"subscriptionId",void 0),e.__decorate([t.Column("varchar",{name:"customerId",nullable:!0,length:255}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"customerId",void 0),e.__decorate([t.Column("int",{name:"clientId",nullable:!0}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"clientId",void 0),e.__decorate([t.Column("int",{name:"billingInterval",nullable:!0}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"billingInterval",void 0),e.__decorate([t.Column("enum",{name:"priority",enum:i,nullable:!0}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"priority",void 0),e.__decorate([t.Column("enum",{name:"phase",enum:a,nullable:!0}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"phase",void 0),e.__decorate([t.Column("int",{name:"paymentAttempt",nullable:!0,default:()=>"'0'"}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"paymentAttempt",void 0),e.__decorate([t.Column("tinyint",{name:"isPaymentFailedPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPaymentFailedPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isPastDuePushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPastDuePushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isAccountLockedPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isAccountLockedPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isPrepaidAddCardPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPrepaidAddCardPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isPrepaidEndingSoonPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPrepaidEndingSoonPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isAddBackupCardPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isAddBackupCardPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"resolved",width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"resolved",void 0),e.__decorate([t.Column("int",{name:"daysInChurn",nullable:!0,default:()=>"'0'"}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"daysInChurn",void 0),e.__decorate([t.Column("datetime",{name:"createdAt",nullable:!0}),e.__metadata("design:type",Date)],exports.ChurnNotification.prototype,"createdAt",void 0),e.__decorate([t.Column("datetime",{name:"updatedAt",nullable:!0}),e.__metadata("design:type",Date)],exports.ChurnNotification.prototype,"updatedAt",void 0),exports.ChurnNotification=e.__decorate([t.Index("ixChurnNotificationSubscriptionId",["subscriptionId"]),t.Index("ixChurnNotificationCustomerId",["customerId"]),t.Index("ixChurnNotificationResolved",["resolved"]),t.Index("ixChurnNotificationClientIdResolved",["clientId","resolved"]),t.Index("ixChurnNotificationPhaseResolved",["phase","resolved"]),t.Entity("churnNotification",{schema:"nova"})],exports.ChurnNotification);
1
+ "use strict";var e=require("../node_modules/tslib/tslib.es6.js"),t=require("typeorm"),o=require("../types/enums.js"),n=require("../utils/boolToNumberTransformer.js");const i=[o.ChurnNotificationPriority.low,o.ChurnNotificationPriority.moderate,o.ChurnNotificationPriority.high,o.ChurnNotificationPriority.critical],a=[o.ChurnNotificationPhase.payment_failed,o.ChurnNotificationPhase.past_due,o.ChurnNotificationPhase.account_locked,o.ChurnNotificationPhase.prepaid_add_card,o.ChurnNotificationPhase.prepaid_ending_soon,o.ChurnNotificationPhase.add_backup_card];exports.ChurnNotification=class ChurnNotification{id;subscriptionId;customerId;clientId;billingInterval;priority;phase;paymentAttempt;isPaymentFailedPushSent;isPastDuePushSent;isAccountLockedPushSent;isPrepaidAddCardPushSent;isPrepaidEndingSoonPushSent;isAddBackupCardPushSent;resolved;daysInChurn;createdAt;updatedAt},e.__decorate([t.PrimaryGeneratedColumn({type:"int",name:"id",unsigned:!0}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"id",void 0),e.__decorate([t.Column("varchar",{name:"subscriptionId",nullable:!0,length:256}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"subscriptionId",void 0),e.__decorate([t.Column("varchar",{name:"customerId",nullable:!0,length:255}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"customerId",void 0),e.__decorate([t.Column("int",{name:"clientId",nullable:!0}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"clientId",void 0),e.__decorate([t.Column("int",{name:"billingInterval",nullable:!0}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"billingInterval",void 0),e.__decorate([t.Column("enum",{name:"priority",enum:i,nullable:!0}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"priority",void 0),e.__decorate([t.Column("enum",{name:"phase",enum:a,nullable:!0}),e.__metadata("design:type",String)],exports.ChurnNotification.prototype,"phase",void 0),e.__decorate([t.Column("int",{name:"paymentAttempt",nullable:!0,default:()=>"'0'"}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"paymentAttempt",void 0),e.__decorate([t.Column("tinyint",{name:"isPaymentFailedPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPaymentFailedPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isPastDuePushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPastDuePushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isAccountLockedPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isAccountLockedPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isPrepaidAddCardPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPrepaidAddCardPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isPrepaidEndingSoonPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isPrepaidEndingSoonPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"isAddBackupCardPushSent",nullable:!0,width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"isAddBackupCardPushSent",void 0),e.__decorate([t.Column("tinyint",{name:"resolved",width:1,default:()=>"'0'",transformer:new n.BoolToNumberTransformer}),e.__metadata("design:type",Boolean)],exports.ChurnNotification.prototype,"resolved",void 0),e.__decorate([t.Column("int",{name:"daysInChurn",nullable:!0,default:()=>"'0'"}),e.__metadata("design:type",Number)],exports.ChurnNotification.prototype,"daysInChurn",void 0),e.__decorate([t.Column("datetime",{name:"createdAt",nullable:!0}),e.__metadata("design:type",Date)],exports.ChurnNotification.prototype,"createdAt",void 0),e.__decorate([t.Column("datetime",{name:"updatedAt",nullable:!0}),e.__metadata("design:type",Date)],exports.ChurnNotification.prototype,"updatedAt",void 0),exports.ChurnNotification=e.__decorate([t.Index("ixChurnNotificationSubscriptionId",["subscriptionId"]),t.Index("ixChurnNotificationCustomerId",["customerId"]),t.Index("ixChurnNotificationResolved",["resolved"]),t.Index("ixChurnNotificationClientIdResolved",["clientId","resolved"]),t.Index("ixChurnNotificationPhaseResolved",["phase","resolved"]),t.Index("ixuChurnNotificationSubscriptionIdPhase",["subscriptionId","phase"],{unique:!0}),t.Entity("churnNotification",{schema:"nova"})],exports.ChurnNotification);
@@ -1,11 +1,11 @@
1
1
  'use strict';
2
2
 
3
- var _1684483705002UpdateSecurityUserViewsV2 = require('../1684483705002-updateSecurityUserViewsV2.js');
4
3
  var _1684483704434AddLowerCaseIndex = require('../1684483704434-addLowerCaseIndex.js');
5
4
  var _1684483705001UpdateSecurityUserViewsV1 = require('../1684483705001-updateSecurityUserViewsV1.js');
5
+ var _1684483705002UpdateSecurityUserViewsV2 = require('../1684483705002-updateSecurityUserViewsV2.js');
6
6
 
7
7
 
8
8
 
9
- exports.updateSecurityUserViewsV21684483705002 = _1684483705002UpdateSecurityUserViewsV2.updateSecurityUserViewsV21684483705002;
10
9
  exports.addLowerCaseIndex1684483704434 = _1684483704434AddLowerCaseIndex.addLowerCaseIndex1684483704434;
11
10
  exports.updateSecurityUserViewsV11684483705001 = _1684483705001UpdateSecurityUserViewsV1.updateSecurityUserViewsV11684483705001;
11
+ exports.updateSecurityUserViewsV21684483705002 = _1684483705002UpdateSecurityUserViewsV2.updateSecurityUserViewsV21684483705002;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spytecgps/nova-orm",
3
- "version": "1.4.171-rc.2",
3
+ "version": "1.4.172",
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: ae0689372d74db46ba7553d50dad2b02
1
+ -- nova-orm-schema-checksum: d502a1e2627b10060087f8ca9549281d
2
2
  -- Nova ORM Schema Dump
3
- -- Generated at: 2026-02-09T13:45:21.597Z
3
+ -- Generated at: 2026-02-11T16:46:41.612Z
4
4
 
5
5
  SET FOREIGN_KEY_CHECKS = 0;
6
6
 
@@ -936,6 +936,7 @@ CREATE TABLE `churnNotification` (
936
936
  `createdAt` datetime DEFAULT NULL,
937
937
  `updatedAt` datetime DEFAULT NULL,
938
938
  PRIMARY KEY (`id`),
939
+ UNIQUE KEY `ixuChurnNotificationSubscriptionIdPhase` (`subscriptionId`,`phase`),
939
940
  KEY `ixChurnNotificationPhaseResolved` (`phase`,`resolved`),
940
941
  KEY `ixChurnNotificationClientIdResolved` (`clientId`,`resolved`),
941
942
  KEY `ixChurnNotificationResolved` (`resolved`),
@@ -9,4 +9,4 @@
9
9
  // 'cli-highlight': require.resolve('@spytecgps/nova-orm/stubs/cli-highlight'),
10
10
  // 'highlight.js': require.resolve('@spytecgps/nova-orm/stubs/cli-highlight'),
11
11
  // }
12
- module.exports.highlight = (code) => code
12
+ module.exports.highlight = code => code