@reachu/database 1.0.65 → 1.0.67
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/dist/entity/Connection.d.ts +11 -0
- package/dist/entity/Connection.js +65 -0
- package/dist/entity/Connection.js.map +1 -0
- package/dist/entity/index.d.ts +2 -1
- package/dist/entity/index.js +3 -1
- package/dist/entity/index.js.map +1 -1
- package/dist/migrations/1683904619468-connections.d.ts +6 -0
- package/dist/migrations/1683904619468-connections.js +37 -0
- package/dist/migrations/1683904619468-connections.js.map +1 -0
- package/dist/repositories/index.d.ts +3 -0
- package/dist/repositories/index.js +8 -1
- package/dist/repositories/index.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +36 -4
- package/package.json +3 -3
- package/src/entity/Connection.ts +47 -0
- package/src/entity/index.ts +2 -0
- package/src/migrations/1683904619468-connections.ts +22 -0
- package/src/repositories/index.ts +4 -0
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
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;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
const typeorm_1 = require("typeorm");
|
|
16
|
+
const AuditedModel_1 = __importDefault(require("./AuditedModel"));
|
|
17
|
+
const User_1 = __importDefault(require("./User"));
|
|
18
|
+
const Request_1 = __importDefault(require("./Request"));
|
|
19
|
+
let Connection = class Connection extends AuditedModel_1.default {
|
|
20
|
+
};
|
|
21
|
+
__decorate([
|
|
22
|
+
typeorm_1.PrimaryGeneratedColumn(),
|
|
23
|
+
__metadata("design:type", Number)
|
|
24
|
+
], Connection.prototype, "id", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
typeorm_1.DeleteDateColumn(),
|
|
27
|
+
__metadata("design:type", Date)
|
|
28
|
+
], Connection.prototype, "deletedAt", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
typeorm_1.ManyToOne(() => User_1.default, (user) => user.id, {
|
|
31
|
+
onDelete: 'CASCADE',
|
|
32
|
+
}),
|
|
33
|
+
typeorm_1.JoinColumn(),
|
|
34
|
+
__metadata("design:type", User_1.default)
|
|
35
|
+
], Connection.prototype, "user1", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
typeorm_1.ManyToOne(() => User_1.default, (user) => user.id, {
|
|
38
|
+
onDelete: 'CASCADE',
|
|
39
|
+
}),
|
|
40
|
+
typeorm_1.JoinColumn(),
|
|
41
|
+
__metadata("design:type", User_1.default)
|
|
42
|
+
], Connection.prototype, "user2", void 0);
|
|
43
|
+
__decorate([
|
|
44
|
+
typeorm_1.ManyToOne(() => Request_1.default, (request) => request.id, {
|
|
45
|
+
onDelete: 'CASCADE',
|
|
46
|
+
}),
|
|
47
|
+
typeorm_1.JoinColumn(),
|
|
48
|
+
__metadata("design:type", User_1.default)
|
|
49
|
+
], Connection.prototype, "request1", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
typeorm_1.ManyToOne(() => Request_1.default, (request) => request.id, {
|
|
52
|
+
onDelete: 'CASCADE',
|
|
53
|
+
}),
|
|
54
|
+
typeorm_1.JoinColumn(),
|
|
55
|
+
__metadata("design:type", User_1.default)
|
|
56
|
+
], Connection.prototype, "request2", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
typeorm_1.Column('varchar', { nullable: false }),
|
|
59
|
+
__metadata("design:type", String)
|
|
60
|
+
], Connection.prototype, "state", void 0);
|
|
61
|
+
Connection = __decorate([
|
|
62
|
+
typeorm_1.Entity()
|
|
63
|
+
], Connection);
|
|
64
|
+
exports.default = Connection;
|
|
65
|
+
//# sourceMappingURL=Connection.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Connection.js","sourceRoot":"","sources":["../../src/entity/Connection.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,qCAOiB;AACjB,kEAA0C;AAC1C,kDAA0B;AAC1B,wDAAgC;AAGhC,IAAqB,UAAU,GAA/B,MAAqB,UAAW,SAAQ,sBAAY;CAiCnD,CAAA;AA/BC;IADC,gCAAsB,EAAE;;sCACd;AAGX;IADC,0BAAgB,EAAE;8BACR,IAAI;6CAAC;AAMhB;IAJC,mBAAS,CAAC,GAAG,EAAE,CAAC,cAAI,EAAE,CAAC,IAAU,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE;QAC9C,QAAQ,EAAE,SAAS;KACpB,CAAC;IACD,oBAAU,EAAE;8BACN,cAAI;yCAAC;AAMZ;IAJC,mBAAS,CAAC,GAAG,EAAE,CAAC,cAAI,EAAE,CAAC,IAAU,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE;QAC9C,QAAQ,EAAE,SAAS;KACpB,CAAC;IACD,oBAAU,EAAE;8BACN,cAAI;yCAAC;AAMZ;IAJC,mBAAS,CAAC,GAAG,EAAE,CAAC,iBAAO,EAAE,CAAC,OAAgB,EAAE,EAAE,CAAC,OAAO,CAAC,EAAE,EAAE;QAC1D,QAAQ,EAAE,SAAS;KACpB,CAAC;IACD,oBAAU,EAAE;8BACH,cAAI;4CAAC;AAMf;IAJC,mBAAS,CAAC,GAAG,EAAE,CAAC,iBAAO,EAAE,CAAC,OAAgB,EAAE,EAAE,CAAC,OAAO,CAAC,EAAE,EAAE;QAC1D,QAAQ,EAAE,SAAS;KACpB,CAAC;IACD,oBAAU,EAAE;8BACH,cAAI;4CAAC;AAGf;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;yCACzB;AAhCK,UAAU;IAD9B,gBAAM,EAAE;GACY,UAAU,CAiC9B;kBAjCoB,UAAU"}
|
package/dist/entity/index.d.ts
CHANGED
|
@@ -90,4 +90,5 @@ import Plan from './modules/subscriptions/Plan';
|
|
|
90
90
|
import Subscription from './modules/subscriptions/Subscription';
|
|
91
91
|
import UserCountPlan from './modules/subscriptions/UserCountPlan';
|
|
92
92
|
import Translate from './Translate';
|
|
93
|
-
|
|
93
|
+
import Connection from './Connection';
|
|
94
|
+
export { CustomVariant, CustomProduct, CustomProductImage, Cart, CartItem, Checkout, CheckoutBillingAddress, CheckoutShippingAddress, PriceData, ProductShipping, Shipping, ShippingCountry, Address, ApiCredential, AuditedModel, BankAccount, Business, BusinessProducts, CardRegistration, Category, Channel, Check, CheckoutMetadata, Contact, Country, Courier, FlatRate, FlatRateCountry, Fulfillment, Image, ImportedProduct, MagentoConnection, MetricActiveUser, Notification, Option, Order, OrderCustomer, OrderItem, OrderShipping, OrderTracking, Payment, PaymentShopify, Permission, Price, Product, Request, Return, ReturnAddress, Role, RolePermission, ShippingPackage, ShopifyConnection, Subcategory, User, UserRole, Variant, Wallet, WooConnection, UserTokenWolt, UserSettings, PaymentMethod, Collection, CollectionItem, CollectionShared, ChannelGroup, ChannelUser, ChannelUserProductSync, UserChannelApiKey, Currency, ExchangeRate, Attribute, ProductAttribute, CategoryImages, AuthInfo, AuthMethod, EndpointTemplateEcommerce, TemplateEcommerce, UserTemplateEcommerce, TemplateEcommerceSchemeConfigOrder, TemplateEcommerceSchemeConfigOrderMapped, ReachuSchemeConfigOrder, TemplateEcommerceSchemeConfigProduct, TemplateEcommerceSchemeConfigProductMapped, ReachuSchemeConfigProduct, TemplateEcommerceSchemeConfigVariant, TemplateEcommerceSchemeConfigVariantMapped, ReachuSchemeConfigVariant, Plan, Subscription, UserCountPlan, EnvironmentConfiguration, Translate, Connection, };
|
package/dist/entity/index.js
CHANGED
|
@@ -4,7 +4,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.RolePermission = exports.Role = exports.ReturnAddress = exports.Return = exports.Request = exports.Product = exports.Price = exports.Permission = exports.PaymentShopify = exports.Payment = exports.OrderTracking = exports.OrderShipping = exports.OrderItem = exports.OrderCustomer = exports.Order = exports.Option = exports.Notification = exports.MetricActiveUser = exports.MagentoConnection = exports.ImportedProduct = exports.Image = exports.Fulfillment = exports.FlatRateCountry = exports.FlatRate = exports.Courier = exports.Country = exports.Contact = exports.CheckoutMetadata = exports.Check = exports.Channel = exports.Category = exports.CardRegistration = exports.BusinessProducts = exports.Business = exports.BankAccount = exports.AuditedModel = exports.ApiCredential = exports.Address = exports.ShippingCountry = exports.Shipping = exports.ProductShipping = exports.PriceData = exports.CheckoutShippingAddress = exports.CheckoutBillingAddress = exports.Checkout = exports.CartItem = exports.Cart = exports.CustomProductImage = exports.CustomProduct = exports.CustomVariant = void 0;
|
|
7
|
-
exports.Translate = exports.EnvironmentConfiguration = exports.UserCountPlan = exports.Subscription = exports.Plan = exports.ReachuSchemeConfigVariant = exports.TemplateEcommerceSchemeConfigVariantMapped = exports.TemplateEcommerceSchemeConfigVariant = exports.ReachuSchemeConfigProduct = exports.TemplateEcommerceSchemeConfigProductMapped = exports.TemplateEcommerceSchemeConfigProduct = exports.ReachuSchemeConfigOrder = exports.TemplateEcommerceSchemeConfigOrderMapped = exports.TemplateEcommerceSchemeConfigOrder = exports.UserTemplateEcommerce = exports.TemplateEcommerce = exports.EndpointTemplateEcommerce = exports.AuthMethod = exports.AuthInfo = exports.CategoryImages = exports.ProductAttribute = exports.Attribute = exports.ExchangeRate = exports.Currency = exports.UserChannelApiKey = exports.ChannelUserProductSync = exports.ChannelUser = exports.ChannelGroup = exports.CollectionShared = exports.CollectionItem = exports.Collection = exports.PaymentMethod = exports.UserSettings = exports.UserTokenWolt = exports.WooConnection = exports.Wallet = exports.Variant = exports.UserRole = exports.User = exports.Subcategory = exports.ShopifyConnection = exports.ShippingPackage = void 0;
|
|
7
|
+
exports.Connection = exports.Translate = exports.EnvironmentConfiguration = exports.UserCountPlan = exports.Subscription = exports.Plan = exports.ReachuSchemeConfigVariant = exports.TemplateEcommerceSchemeConfigVariantMapped = exports.TemplateEcommerceSchemeConfigVariant = exports.ReachuSchemeConfigProduct = exports.TemplateEcommerceSchemeConfigProductMapped = exports.TemplateEcommerceSchemeConfigProduct = exports.ReachuSchemeConfigOrder = exports.TemplateEcommerceSchemeConfigOrderMapped = exports.TemplateEcommerceSchemeConfigOrder = exports.UserTemplateEcommerce = exports.TemplateEcommerce = exports.EndpointTemplateEcommerce = exports.AuthMethod = exports.AuthInfo = exports.CategoryImages = exports.ProductAttribute = exports.Attribute = exports.ExchangeRate = exports.Currency = exports.UserChannelApiKey = exports.ChannelUserProductSync = exports.ChannelUser = exports.ChannelGroup = exports.CollectionShared = exports.CollectionItem = exports.Collection = exports.PaymentMethod = exports.UserSettings = exports.UserTokenWolt = exports.WooConnection = exports.Wallet = exports.Variant = exports.UserRole = exports.User = exports.Subcategory = exports.ShopifyConnection = exports.ShippingPackage = void 0;
|
|
8
8
|
const Address_1 = __importDefault(require("./Address"));
|
|
9
9
|
exports.Address = Address_1.default;
|
|
10
10
|
const ApiCredential_1 = __importDefault(require("./ApiCredential"));
|
|
@@ -189,4 +189,6 @@ const UserCountPlan_1 = __importDefault(require("./modules/subscriptions/UserCou
|
|
|
189
189
|
exports.UserCountPlan = UserCountPlan_1.default;
|
|
190
190
|
const Translate_1 = __importDefault(require("./Translate"));
|
|
191
191
|
exports.Translate = Translate_1.default;
|
|
192
|
+
const Connection_1 = __importDefault(require("./Connection"));
|
|
193
|
+
exports.Connection = Connection_1.default;
|
|
192
194
|
//# sourceMappingURL=index.js.map
|
package/dist/entity/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/entity/index.ts"],"names":[],"mappings":";;;;;;;AAAA,wDAAgC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/entity/index.ts"],"names":[],"mappings":";;;;;;;AAAA,wDAAgC;AAyH9B,kBAzHK,iBAAO,CAyHL;AAxHT,oEAA4C;AAyH1C,wBAzHK,uBAAa,CAyHL;AAxHf,kEAA0C;AAyHxC,uBAzHK,sBAAY,CAyHL;AAxHd,gEAAwC;AAyHtC,sBAzHK,qBAAW,CAyHL;AAxHb,0DAAkC;AAyHhC,mBAzHK,kBAAQ,CAyHL;AAxHV,0EAAkD;AAyHhD,2BAzHK,0BAAgB,CAyHL;AAxHlB,0EAAkD;AAyHhD,2BAzHK,0BAAgB,CAyHL;AAxHlB,0DAAkC;AAyHhC,mBAzHK,kBAAQ,CAyHL;AAxHV,wDAAgC;AAyH9B,kBAzHK,iBAAO,CAyHL;AAxHT,oDAA4B;AAyH1B,gBAzHK,eAAK,CAyHL;AAxHP,0EAAkD;AAyHhD,2BAzHK,0BAAgB,CAyHL;AAxHlB,wDAAgC;AAyH9B,kBAzHK,iBAAO,CAyHL;AAxHT,wDAAgC;AAyH9B,kBAzHK,iBAAO,CAyHL;AAxHT,wDAAgC;AAyH9B,kBAzHK,iBAAO,CAyHL;AAxHT,0DAAkC;AAyHhC,mBAzHK,kBAAQ,CAyHL;AAxHV,wEAAgD;AAyH9C,0BAzHK,yBAAe,CAyHL;AAxHjB,gEAAwC;AAyHtC,sBAzHK,qBAAW,CAyHL;AAxHb,oDAA4B;AAyH1B,gBAzHK,eAAK,CAyHL;AAxHP,wEAAgD;AAyH9C,0BAzHK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CK,4BAAkB,CAoCL;AAlCpB,4DAAoC;AAsGlC,oBAtGK,mBAAS,CAsGL;AArGX,0EAAkD;AAsGhD,2BAtGK,0BAAgB,CAsGL;AArGlB,sEAA8C;AAsG5C,yBAtGK,wBAAc,CAsGL;AAnGhB,4EAAoD;AAoGlD,mBApGK,kBAAQ,CAoGL;AAnGV,gFAAwD;AAoGtD,qBApGK,oBAAU,CAoGL;AAnGZ,8GAAsF;AAoGpF,oCApGK,mCAAyB,CAoGL;AAnG3B,8FAAsE;AAoGpE,4BApGK,2BAAiB,CAoGL;AAnGnB,sGAA8E;AAoG5E,gCApGK,+BAAqB,CAoGL;AAlGvB,sHAA8F;AAqG5F,kCArGK,iCAAuB,CAqGL;AApGzB,4IAAoH;AAkGlH,6CAlGK,4CAAkC,CAkGL;AAjGpC,wJAAgI;AAkG9H,mDAlGK,kDAAwC,CAkGL;AAhG1C,4HAAoG;AAoGlG,oCApGK,mCAAyB,CAoGL;AAnG3B,kJAA0H;AAiGxH,+CAjGK,8CAAoC,CAiGL;AAhGtC,8JAAsI;AAiGpI,qDAjGK,oDAA0C,CAiGL;AA/F5C,4HAAoG;AAmGlG,oCAnGK,mCAAyB,CAmGL;AAlG3B,kJAA0H;AAgGxH,+CAhGK,8CAAoC,CAgGL;AA/FtC,8JAAsI;AAgGpI,qDAhGK,oDAA0C,CAgGL;AA7F5C,wEAAgD;AA+F9C,eA/FK,cAAI,CA+FL;AA9FN,wFAAgE;AA+F9D,uBA/FK,sBAAY,CA+FL;AA9Fd,0FAAkE;AA+FhE,wBA/FK,uBAAa,CA+FL;AA7Ff,4DAAoC;AA+FlC,oBA/FK,mBAAS,CA+FL;AA9FX,8DAAsC;AA+FpC,qBA/FK,oBAAU,CA+FL"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.connections1683904619468 = void 0;
|
|
13
|
+
class connections1683904619468 {
|
|
14
|
+
constructor() {
|
|
15
|
+
this.name = 'connections1683904619468';
|
|
16
|
+
}
|
|
17
|
+
up(queryRunner) {
|
|
18
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
19
|
+
yield queryRunner.query(`CREATE TABLE \`connection\` (\`created_at\` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6), \`updated_at\` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6) ON UPDATE CURRENT_TIMESTAMP(6), \`id\` int NOT NULL AUTO_INCREMENT, \`deleted_at\` datetime(6) NULL, \`state\` varchar(255) NOT NULL, \`user1_id\` int NULL, \`user2_id\` int NULL, \`request1_id\` int NULL, \`request2_id\` int NULL, PRIMARY KEY (\`id\`)) ENGINE=InnoDB`);
|
|
20
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_d79e23ba726ae5259fa00d8b676\` FOREIGN KEY (\`user1_id\`) REFERENCES \`user\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
21
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_14c0e5628aafbae9b256580fc30\` FOREIGN KEY (\`user2_id\`) REFERENCES \`user\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
22
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_c5e7b716e32c369affd3b5d53ab\` FOREIGN KEY (\`request1_id\`) REFERENCES \`request\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
23
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_4dbcf398cf5113a67cde4d47254\` FOREIGN KEY (\`request2_id\`) REFERENCES \`request\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
down(queryRunner) {
|
|
27
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
28
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_4dbcf398cf5113a67cde4d47254\``);
|
|
29
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_c5e7b716e32c369affd3b5d53ab\``);
|
|
30
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_14c0e5628aafbae9b256580fc30\``);
|
|
31
|
+
yield queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_d79e23ba726ae5259fa00d8b676\``);
|
|
32
|
+
yield queryRunner.query(`DROP TABLE \`connection\``);
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
exports.connections1683904619468 = connections1683904619468;
|
|
37
|
+
//# sourceMappingURL=1683904619468-connections.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"1683904619468-connections.js","sourceRoot":"","sources":["../../src/migrations/1683904619468-connections.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAa,wBAAwB;IAArC;QACI,SAAI,GAAG,0BAA0B,CAAA;IAkBrC,CAAC;IAhBgB,EAAE,CAAC,WAAwB;;YACpC,MAAM,WAAW,CAAC,KAAK,CAAC,6aAA6a,CAAC,CAAC;YACvc,MAAM,WAAW,CAAC,KAAK,CAAC,2KAA2K,CAAC,CAAC;YACrM,MAAM,WAAW,CAAC,KAAK,CAAC,2KAA2K,CAAC,CAAC;YACrM,MAAM,WAAW,CAAC,KAAK,CAAC,iLAAiL,CAAC,CAAC;YAC3M,MAAM,WAAW,CAAC,KAAK,CAAC,iLAAiL,CAAC,CAAC;QAC/M,CAAC;KAAA;IAEY,IAAI,CAAC,WAAwB;;YACtC,MAAM,WAAW,CAAC,KAAK,CAAC,gFAAgF,CAAC,CAAC;YAC1G,MAAM,WAAW,CAAC,KAAK,CAAC,gFAAgF,CAAC,CAAC;YAC1G,MAAM,WAAW,CAAC,KAAK,CAAC,gFAAgF,CAAC,CAAC;YAC1G,MAAM,WAAW,CAAC,KAAK,CAAC,gFAAgF,CAAC,CAAC;YAC1G,MAAM,WAAW,CAAC,KAAK,CAAC,2BAA2B,CAAC,CAAC;QACzD,CAAC;KAAA;CAEJ;AAnBD,4DAmBC"}
|
|
@@ -54,6 +54,7 @@ import ProductAttribute from '../entity/ProductAttribute';
|
|
|
54
54
|
import CategoryImages from '../entity/CategoryImages';
|
|
55
55
|
import EnvironmentConfiguration from '../entity/EnvironmentConfiguration';
|
|
56
56
|
import Translate from '../entity/Translate';
|
|
57
|
+
import Connection from '../entity/Connection';
|
|
57
58
|
import { CartItemRepository, CartRepository, CheckoutBillingAddressRepository, CheckoutRepository, CheckoutShippingAddressRepository, PriceDataRepository } from './shopcart';
|
|
58
59
|
import { ProductShippingRepository, ShippingCountryRepository, ShippingRepository } from './shipping';
|
|
59
60
|
import { AuthInfoRepository, AuthMethodRepository, EndpointTemplateEcommerceRepository, ReachuSchemeConfigOrderRepository, ReachuSchemeConfigProductRepository, ReachuSchemeConfigVariantRepository, TemplateEcommerceRepository, TemplateEcommerceSchemeConfigOrderMappedRepository, TemplateEcommerceSchemeConfigOrderRepository, TemplateEcommerceSchemeConfigProductMappedRepository, TemplateEcommerceSchemeConfigProductRepository, TemplateEcommerceSchemeConfigVariantMappedRepository, TemplateEcommerceSchemeConfigVariantRepository, UserTemplateEcommerceRepository } from './templates';
|
|
@@ -171,6 +172,8 @@ export declare class EnvironmentConfigurationRepository extends Repository<Envir
|
|
|
171
172
|
}
|
|
172
173
|
export declare class TranslateRepository extends Repository<Translate> {
|
|
173
174
|
}
|
|
175
|
+
export declare class ConnectionRepository extends Repository<Connection> {
|
|
176
|
+
}
|
|
174
177
|
export { CartItemRepository, CartRepository, CheckoutBillingAddressRepository, CheckoutRepository, CheckoutShippingAddressRepository, PriceDataRepository, };
|
|
175
178
|
export { AuthInfoRepository, AuthMethodRepository, EndpointTemplateEcommerceRepository, ReachuSchemeConfigOrderRepository, ReachuSchemeConfigProductRepository, ReachuSchemeConfigVariantRepository, TemplateEcommerceRepository, TemplateEcommerceSchemeConfigOrderMappedRepository, TemplateEcommerceSchemeConfigOrderRepository, TemplateEcommerceSchemeConfigProductMappedRepository, TemplateEcommerceSchemeConfigProductRepository, TemplateEcommerceSchemeConfigVariantMappedRepository, TemplateEcommerceSchemeConfigVariantRepository, UserTemplateEcommerceRepository, };
|
|
176
179
|
export { ProductShippingRepository, ShippingCountryRepository, ShippingRepository };
|
|
@@ -10,7 +10,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.ChannelUserRepository = exports.ChannelGroupRepository = exports.CollectionSharedRepository = exports.CollectionItemRepository = exports.CollectionRepository = exports.PaymentMethodRepository = exports.UserSettingsRepository = exports.UserTokenWoltRepository = exports.WooConnectionRepository = exports.WalletRepository = exports.VariantRepository = exports.UserRoleRepository = exports.UserRepository = exports.SubcategoryRepository = exports.ShopifyConnectionRepository = exports.ShippingPackageRepository = exports.RolePermissionRepository = exports.RoleRepository = exports.RequestRepository = exports.ProductRepository = exports.PermissionRepository = exports.PaymentShopifyRepository = exports.PaymentRepository = exports.OrderTrackingRepository = exports.OrderShippingRepository = exports.OrderItemRepository = exports.OrderRepository = exports.OptionRepository = exports.NotificationRepository = exports.MetricActiveUserRepository = exports.MagentoConnectionRepository = exports.ImportedProductRepository = exports.ImageRepository = exports.FlatRateCountryRepository = exports.FlatRateRepository = exports.CourierRepository = exports.CountryRepository = exports.CheckoutMetadataRepository = exports.ChannelRepository = exports.CategoryRepository = exports.CardRegistrationRepository = exports.BusinessRepository = exports.BankAccountRepository = exports.ApiCredentialRepository = exports.CustomProductImageRepository = exports.CustomProductRepository = exports.CustomVariantRepository = exports.AttributeRepository = exports.ProductAttributeRepository = exports.CategoryImagesRepository = void 0;
|
|
13
|
-
exports.UserCountPlanRepository = exports.SubscriptionRepository = exports.PlanRepository = exports.ShippingRepository = exports.ShippingCountryRepository = exports.ProductShippingRepository = exports.UserTemplateEcommerceRepository = exports.TemplateEcommerceSchemeConfigVariantRepository = exports.TemplateEcommerceSchemeConfigVariantMappedRepository = exports.TemplateEcommerceSchemeConfigProductRepository = exports.TemplateEcommerceSchemeConfigProductMappedRepository = exports.TemplateEcommerceSchemeConfigOrderRepository = exports.TemplateEcommerceSchemeConfigOrderMappedRepository = exports.TemplateEcommerceRepository = exports.ReachuSchemeConfigVariantRepository = exports.ReachuSchemeConfigProductRepository = exports.ReachuSchemeConfigOrderRepository = exports.EndpointTemplateEcommerceRepository = exports.AuthMethodRepository = exports.AuthInfoRepository = exports.PriceDataRepository = exports.CheckoutShippingAddressRepository = exports.CheckoutRepository = exports.CheckoutBillingAddressRepository = exports.CartRepository = exports.CartItemRepository = exports.TranslateRepository = exports.EnvironmentConfigurationRepository = exports.ExchangeRateRepository = exports.CurrencyRepository = exports.UserChannelApiKeyRepository = exports.ChannelUserProductSyncRepository = void 0;
|
|
13
|
+
exports.UserCountPlanRepository = exports.SubscriptionRepository = exports.PlanRepository = exports.ShippingRepository = exports.ShippingCountryRepository = exports.ProductShippingRepository = exports.UserTemplateEcommerceRepository = exports.TemplateEcommerceSchemeConfigVariantRepository = exports.TemplateEcommerceSchemeConfigVariantMappedRepository = exports.TemplateEcommerceSchemeConfigProductRepository = exports.TemplateEcommerceSchemeConfigProductMappedRepository = exports.TemplateEcommerceSchemeConfigOrderRepository = exports.TemplateEcommerceSchemeConfigOrderMappedRepository = exports.TemplateEcommerceRepository = exports.ReachuSchemeConfigVariantRepository = exports.ReachuSchemeConfigProductRepository = exports.ReachuSchemeConfigOrderRepository = exports.EndpointTemplateEcommerceRepository = exports.AuthMethodRepository = exports.AuthInfoRepository = exports.PriceDataRepository = exports.CheckoutShippingAddressRepository = exports.CheckoutRepository = exports.CheckoutBillingAddressRepository = exports.CartRepository = exports.CartItemRepository = exports.ConnectionRepository = exports.TranslateRepository = exports.EnvironmentConfigurationRepository = exports.ExchangeRateRepository = exports.CurrencyRepository = exports.UserChannelApiKeyRepository = exports.ChannelUserProductSyncRepository = void 0;
|
|
14
14
|
const ApiCredential_1 = __importDefault(require("../entity/ApiCredential"));
|
|
15
15
|
const BankAccount_1 = __importDefault(require("../entity/BankAccount"));
|
|
16
16
|
const Business_1 = __importDefault(require("../entity/Business"));
|
|
@@ -67,6 +67,7 @@ const ProductAttribute_1 = __importDefault(require("../entity/ProductAttribute")
|
|
|
67
67
|
const CategoryImages_1 = __importDefault(require("../entity/CategoryImages"));
|
|
68
68
|
const EnvironmentConfiguration_1 = __importDefault(require("../entity/EnvironmentConfiguration"));
|
|
69
69
|
const Translate_1 = __importDefault(require("../entity/Translate"));
|
|
70
|
+
const Connection_1 = __importDefault(require("../entity/Connection"));
|
|
70
71
|
const shopcart_1 = require("./shopcart");
|
|
71
72
|
Object.defineProperty(exports, "CartItemRepository", { enumerable: true, get: function () { return shopcart_1.CartItemRepository; } });
|
|
72
73
|
Object.defineProperty(exports, "CartRepository", { enumerable: true, get: function () { return shopcart_1.CartRepository; } });
|
|
@@ -434,4 +435,10 @@ TranslateRepository = __decorate([
|
|
|
434
435
|
typeorm_1.EntityRepository(Translate_1.default)
|
|
435
436
|
], TranslateRepository);
|
|
436
437
|
exports.TranslateRepository = TranslateRepository;
|
|
438
|
+
let ConnectionRepository = class ConnectionRepository extends typeorm_1.Repository {
|
|
439
|
+
};
|
|
440
|
+
ConnectionRepository = __decorate([
|
|
441
|
+
typeorm_1.EntityRepository(Connection_1.default)
|
|
442
|
+
], ConnectionRepository);
|
|
443
|
+
exports.ConnectionRepository = ConnectionRepository;
|
|
437
444
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/repositories/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,4EAAoD;AACpD,wEAAgD;AAChD,kEAA0C;AAC1C,kFAA0D;AAC1D,kEAA0C;AAC1C,gEAAwC;AACxC,kFAA0D;AAC1D,gEAAwC;AACxC,gEAAwC;AACxC,kEAA0C;AAC1C,gFAAwD;AACxD,4DAAoC;AACpC,gFAAwD;AACxD,iFAAuE;AACvE,kFAA0D;AAC1D,0EAAkD;AAClD,8DAAsC;AACtC,4DAAoC;AACpC,oEAA4C;AAC5C,4EAAoD;AACpD,4EAAoD;AACpD,gEAAwC;AACxC,8EAAsD;AACtD,sEAA8C;AAC9C,6DAAmD;AACnD,gEAAwC;AACxC,0DAAkC;AAClC,8EAAsD;AACtD,gFAAwD;AACxD,oFAA4D;AAC5D,wEAAgD;AAChD,0DAAkC;AAClC,kEAA0C;AAC1C,gEAAwC;AACxC,8DAAsC;AACtC,4EAAoD;AACpD,4EAAoD;AACpD,0EAAkD;AAClD,4EAAoD;AACpD,sEAA8C;AAC9C,8EAAsD;AACtD,kFAA0D;AAC1D,0EAAkD;AAClD,wEAAgD;AAChD,8FAAsE;AACtE,oFAA4D;AAC5D,kEAA0C;AAC1C,0EAAkD;AAElD,4EAAoD;AACpD,2DAAwD;AACxD,sFAA8D;AAE9D,oEAA4C;AAC5C,kFAA0D;AAC1D,8EAAsD;AAEtD,kGAA0E;AAE1E,oEAA4C;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/repositories/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;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;AAApE,kEAA2B;AAGxC,IAAa,kBAAkB,GAA/B,MAAa,kBAAmB,SAAQ,oBAAoB;CAAG,CAAA;AAAlD,kBAAkB;IAD9B,0BAAgB,CAAC,kBAAQ,CAAC;GACd,kBAAkB,CAAgC;AAAlD,gDAAkB;AAG/B,IAAa,sBAAsB,GAAnC,MAAa,sBAAuB,SAAQ,oBAAwB;CAAG,CAAA;AAA1D,sBAAsB;IADlC,0BAAgB,CAAC,sBAAY,CAAC;GAClB,sBAAsB,CAAoC;AAA1D,wDAAsB;AAGnC,IAAa,kCAAkC,GAA/C,MAAa,kCAAmC,SAAQ,oBAAoC;CAAG,CAAA;AAAlF,kCAAkC;IAD9C,0BAAgB,CAAC,kCAAwB,CAAC;GAC9B,kCAAkC,CAAgD;AAAlF,gFAAkC;AAG/C,IAAa,mBAAmB,GAAhC,MAAa,mBAAoB,SAAQ,oBAAqB;CAAG,CAAA;AAApD,mBAAmB;IAD/B,0BAAgB,CAAC,mBAAS,CAAC;GACf,mBAAmB,CAAiC;AAApD,kDAAmB;AAGhC,IAAa,oBAAoB,GAAjC,MAAa,oBAAqB,SAAQ,oBAAsB;CAAG,CAAA;AAAtD,oBAAoB;IADhC,0BAAgB,CAAC,oBAAU,CAAC;GAChB,oBAAoB,CAAkC;AAAtD,oDAAoB"}
|
|
@@ -2716,9 +2716,14 @@
|
|
|
2716
2716
|
"signature": "60106f067920f6679c818a7c7d80face5aa58e305d16d1dd99499ab558b97853",
|
|
2717
2717
|
"affectsGlobalScope": false
|
|
2718
2718
|
},
|
|
2719
|
+
"../src/entity/connection.ts": {
|
|
2720
|
+
"version": "596c229836f3705e5863100507dd72c9c161cf09803cdf691f5bdb0deaaea29d",
|
|
2721
|
+
"signature": "a442173c7242a17a8ced50e6bba05b440355edf563bbd1628ddf399820b9fe45",
|
|
2722
|
+
"affectsGlobalScope": false
|
|
2723
|
+
},
|
|
2719
2724
|
"../src/entity/index.ts": {
|
|
2720
|
-
"version": "
|
|
2721
|
-
"signature": "
|
|
2725
|
+
"version": "eba16c4ce27920e505a0f3aa22030fc74c0d3a6cd8cceb3b8c80d9cb7344938f",
|
|
2726
|
+
"signature": "e2983d82c3b79b54961a14e0b659fce32b91eb36252e55a8796ecf2f568871b5",
|
|
2722
2727
|
"affectsGlobalScope": false
|
|
2723
2728
|
},
|
|
2724
2729
|
"../src/staticdata/productorigin.ts": {
|
|
@@ -2797,8 +2802,8 @@
|
|
|
2797
2802
|
"affectsGlobalScope": false
|
|
2798
2803
|
},
|
|
2799
2804
|
"../src/repositories/index.ts": {
|
|
2800
|
-
"version": "
|
|
2801
|
-
"signature": "
|
|
2805
|
+
"version": "4e3b008432a735c84f1ac8c1493b42c1529f2d89b1d45ae8fa282a4d8fddbe95",
|
|
2806
|
+
"signature": "2bd70cb3e5a87ed3fa74ef90eb86a758be52603bdb711248088699c964094abe",
|
|
2802
2807
|
"affectsGlobalScope": false
|
|
2803
2808
|
},
|
|
2804
2809
|
"../src/subscribers/productsubscriber.ts": {
|
|
@@ -3216,6 +3221,11 @@
|
|
|
3216
3221
|
"signature": "8641289d7b36adc4ad9c0ac0e96393a95b271dfd0967cea4c439b03638953d8a",
|
|
3217
3222
|
"affectsGlobalScope": false
|
|
3218
3223
|
},
|
|
3224
|
+
"../src/migrations/1683904619468-connections.ts": {
|
|
3225
|
+
"version": "4f0291f71debcd25416e366a6a242e5a1b054f2551b804ec3f9c8ec01136b995",
|
|
3226
|
+
"signature": "99f6bae5f921c2b2c4355c1f465af8db7cc21929a20db7be7b52acfe2d8088a2",
|
|
3227
|
+
"affectsGlobalScope": false
|
|
3228
|
+
},
|
|
3219
3229
|
"../src/migrations/execute/index.ts": {
|
|
3220
3230
|
"version": "8b5bf13d095aeb57afd593adf3d799681176a13c327e2f77e0028e178c4ee3b9",
|
|
3221
3231
|
"signature": "8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881",
|
|
@@ -5248,6 +5258,12 @@
|
|
|
5248
5258
|
"../src/entity/collection.ts",
|
|
5249
5259
|
"../src/entity/user.ts"
|
|
5250
5260
|
],
|
|
5261
|
+
"../src/entity/connection.ts": [
|
|
5262
|
+
"../node_modules/typeorm/index.d.ts",
|
|
5263
|
+
"../src/entity/auditedmodel.ts",
|
|
5264
|
+
"../src/entity/request.ts",
|
|
5265
|
+
"../src/entity/user.ts"
|
|
5266
|
+
],
|
|
5251
5267
|
"../src/entity/contact.ts": [
|
|
5252
5268
|
"../node_modules/typeorm/index.d.ts"
|
|
5253
5269
|
],
|
|
@@ -5340,6 +5356,7 @@
|
|
|
5340
5356
|
"../src/entity/collection.ts",
|
|
5341
5357
|
"../src/entity/collectionitem.ts",
|
|
5342
5358
|
"../src/entity/collectionshared.ts",
|
|
5359
|
+
"../src/entity/connection.ts",
|
|
5343
5360
|
"../src/entity/contact.ts",
|
|
5344
5361
|
"../src/entity/country.ts",
|
|
5345
5362
|
"../src/entity/courier.ts",
|
|
@@ -6001,6 +6018,9 @@
|
|
|
6001
6018
|
"../src/migrations/1683656076895-promote_to_production_09_05_2023.ts": [
|
|
6002
6019
|
"../node_modules/typeorm/index.d.ts"
|
|
6003
6020
|
],
|
|
6021
|
+
"../src/migrations/1683904619468-connections.ts": [
|
|
6022
|
+
"../node_modules/typeorm/index.d.ts"
|
|
6023
|
+
],
|
|
6004
6024
|
"../src/migrations/execute/index.ts": [
|
|
6005
6025
|
"../src/config/connect.ts"
|
|
6006
6026
|
],
|
|
@@ -6033,6 +6053,7 @@
|
|
|
6033
6053
|
"../src/entity/collection.ts",
|
|
6034
6054
|
"../src/entity/collectionitem.ts",
|
|
6035
6055
|
"../src/entity/collectionshared.ts",
|
|
6056
|
+
"../src/entity/connection.ts",
|
|
6036
6057
|
"../src/entity/country.ts",
|
|
6037
6058
|
"../src/entity/courier.ts",
|
|
6038
6059
|
"../src/entity/currency.ts",
|
|
@@ -8010,6 +8031,10 @@
|
|
|
8010
8031
|
"../src/entity/collection.ts",
|
|
8011
8032
|
"../src/entity/user.ts"
|
|
8012
8033
|
],
|
|
8034
|
+
"../src/entity/connection.ts": [
|
|
8035
|
+
"../src/entity/auditedmodel.ts",
|
|
8036
|
+
"../src/entity/user.ts"
|
|
8037
|
+
],
|
|
8013
8038
|
"../src/entity/courier.ts": [
|
|
8014
8039
|
"../src/entity/auditedmodel.ts"
|
|
8015
8040
|
],
|
|
@@ -8072,6 +8097,7 @@
|
|
|
8072
8097
|
"../src/entity/collection.ts",
|
|
8073
8098
|
"../src/entity/collectionitem.ts",
|
|
8074
8099
|
"../src/entity/collectionshared.ts",
|
|
8100
|
+
"../src/entity/connection.ts",
|
|
8075
8101
|
"../src/entity/contact.ts",
|
|
8076
8102
|
"../src/entity/country.ts",
|
|
8077
8103
|
"../src/entity/courier.ts",
|
|
@@ -8641,6 +8667,9 @@
|
|
|
8641
8667
|
"../src/migrations/1683656076895-promote_to_production_09_05_2023.ts": [
|
|
8642
8668
|
"../node_modules/typeorm/index.d.ts"
|
|
8643
8669
|
],
|
|
8670
|
+
"../src/migrations/1683904619468-connections.ts": [
|
|
8671
|
+
"../node_modules/typeorm/index.d.ts"
|
|
8672
|
+
],
|
|
8644
8673
|
"../src/migrations/index.ts": [
|
|
8645
8674
|
"../src/migrations/1628474597284-initialschema.ts",
|
|
8646
8675
|
"../src/migrations/1630077596132-removemangopay.ts",
|
|
@@ -8670,6 +8699,7 @@
|
|
|
8670
8699
|
"../src/entity/collection.ts",
|
|
8671
8700
|
"../src/entity/collectionitem.ts",
|
|
8672
8701
|
"../src/entity/collectionshared.ts",
|
|
8702
|
+
"../src/entity/connection.ts",
|
|
8673
8703
|
"../src/entity/country.ts",
|
|
8674
8704
|
"../src/entity/courier.ts",
|
|
8675
8705
|
"../src/entity/currency.ts",
|
|
@@ -9284,6 +9314,7 @@
|
|
|
9284
9314
|
"../src/entity/collection.ts",
|
|
9285
9315
|
"../src/entity/collectionitem.ts",
|
|
9286
9316
|
"../src/entity/collectionshared.ts",
|
|
9317
|
+
"../src/entity/connection.ts",
|
|
9287
9318
|
"../src/entity/contact.ts",
|
|
9288
9319
|
"../src/entity/country.ts",
|
|
9289
9320
|
"../src/entity/courier.ts",
|
|
@@ -9430,6 +9461,7 @@
|
|
|
9430
9461
|
"../src/migrations/1683077989567-update_plan.ts",
|
|
9431
9462
|
"../src/migrations/1683322405116-translate.ts",
|
|
9432
9463
|
"../src/migrations/1683656076895-promote_to_production_09_05_2023.ts",
|
|
9464
|
+
"../src/migrations/1683904619468-connections.ts",
|
|
9433
9465
|
"../src/migrations/execute/index.ts",
|
|
9434
9466
|
"../src/migrations/index.ts",
|
|
9435
9467
|
"../src/repositories/index.ts",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@reachu/database",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.67",
|
|
4
4
|
"description": "reachu-database",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"author": "reachu",
|
|
22
22
|
"license": "ISC",
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@reachu/logger": "1.0.
|
|
25
|
-
"@reachu/utils": "1.0.
|
|
24
|
+
"@reachu/logger": "1.0.67",
|
|
25
|
+
"@reachu/utils": "1.0.67",
|
|
26
26
|
"dotenv": "8.0.0",
|
|
27
27
|
"express": "4.17.1",
|
|
28
28
|
"mysql2": "1.5.2",
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Entity,
|
|
3
|
+
PrimaryGeneratedColumn,
|
|
4
|
+
DeleteDateColumn,
|
|
5
|
+
ManyToOne,
|
|
6
|
+
JoinColumn,
|
|
7
|
+
Column,
|
|
8
|
+
} from 'typeorm';
|
|
9
|
+
import AuditedModel from './AuditedModel';
|
|
10
|
+
import User from './User';
|
|
11
|
+
import Request from './Request';
|
|
12
|
+
|
|
13
|
+
@Entity()
|
|
14
|
+
export default class Connection extends AuditedModel {
|
|
15
|
+
@PrimaryGeneratedColumn()
|
|
16
|
+
id: number;
|
|
17
|
+
|
|
18
|
+
@DeleteDateColumn()
|
|
19
|
+
deletedAt: Date;
|
|
20
|
+
|
|
21
|
+
@ManyToOne(() => User, (user: User) => user.id, {
|
|
22
|
+
onDelete: 'CASCADE',
|
|
23
|
+
})
|
|
24
|
+
@JoinColumn()
|
|
25
|
+
user1: User;
|
|
26
|
+
|
|
27
|
+
@ManyToOne(() => User, (user: User) => user.id, {
|
|
28
|
+
onDelete: 'CASCADE',
|
|
29
|
+
})
|
|
30
|
+
@JoinColumn()
|
|
31
|
+
user2: User;
|
|
32
|
+
|
|
33
|
+
@ManyToOne(() => Request, (request: Request) => request.id, {
|
|
34
|
+
onDelete: 'CASCADE',
|
|
35
|
+
})
|
|
36
|
+
@JoinColumn()
|
|
37
|
+
request1: User;
|
|
38
|
+
|
|
39
|
+
@ManyToOne(() => Request, (request: Request) => request.id, {
|
|
40
|
+
onDelete: 'CASCADE',
|
|
41
|
+
})
|
|
42
|
+
@JoinColumn()
|
|
43
|
+
request2: User;
|
|
44
|
+
|
|
45
|
+
@Column('varchar', { nullable: false })
|
|
46
|
+
state: string;
|
|
47
|
+
}
|
package/src/entity/index.ts
CHANGED
|
@@ -104,6 +104,7 @@ import Subscription from './modules/subscriptions/Subscription';
|
|
|
104
104
|
import UserCountPlan from './modules/subscriptions/UserCountPlan';
|
|
105
105
|
|
|
106
106
|
import Translate from './Translate';
|
|
107
|
+
import Connection from './Connection';
|
|
107
108
|
|
|
108
109
|
export {
|
|
109
110
|
CustomVariant,
|
|
@@ -198,4 +199,5 @@ export {
|
|
|
198
199
|
UserCountPlan,
|
|
199
200
|
EnvironmentConfiguration,
|
|
200
201
|
Translate,
|
|
202
|
+
Connection,
|
|
201
203
|
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import {MigrationInterface, QueryRunner} from "typeorm";
|
|
2
|
+
|
|
3
|
+
export class connections1683904619468 implements MigrationInterface {
|
|
4
|
+
name = 'connections1683904619468'
|
|
5
|
+
|
|
6
|
+
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
7
|
+
await queryRunner.query(`CREATE TABLE \`connection\` (\`created_at\` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6), \`updated_at\` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6) ON UPDATE CURRENT_TIMESTAMP(6), \`id\` int NOT NULL AUTO_INCREMENT, \`deleted_at\` datetime(6) NULL, \`state\` varchar(255) NOT NULL, \`user1_id\` int NULL, \`user2_id\` int NULL, \`request1_id\` int NULL, \`request2_id\` int NULL, PRIMARY KEY (\`id\`)) ENGINE=InnoDB`);
|
|
8
|
+
await queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_d79e23ba726ae5259fa00d8b676\` FOREIGN KEY (\`user1_id\`) REFERENCES \`user\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
9
|
+
await queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_14c0e5628aafbae9b256580fc30\` FOREIGN KEY (\`user2_id\`) REFERENCES \`user\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
10
|
+
await queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_c5e7b716e32c369affd3b5d53ab\` FOREIGN KEY (\`request1_id\`) REFERENCES \`request\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
11
|
+
await queryRunner.query(`ALTER TABLE \`connection\` ADD CONSTRAINT \`FK_4dbcf398cf5113a67cde4d47254\` FOREIGN KEY (\`request2_id\`) REFERENCES \`request\`(\`id\`) ON DELETE CASCADE ON UPDATE NO ACTION`);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
15
|
+
await queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_4dbcf398cf5113a67cde4d47254\``);
|
|
16
|
+
await queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_c5e7b716e32c369affd3b5d53ab\``);
|
|
17
|
+
await queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_14c0e5628aafbae9b256580fc30\``);
|
|
18
|
+
await queryRunner.query(`ALTER TABLE \`connection\` DROP FOREIGN KEY \`FK_d79e23ba726ae5259fa00d8b676\``);
|
|
19
|
+
await queryRunner.query(`DROP TABLE \`connection\``);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
}
|
|
@@ -58,6 +58,7 @@ import CategoryImages from '../entity/CategoryImages';
|
|
|
58
58
|
import EnvironmentConfiguration from '../entity/EnvironmentConfiguration';
|
|
59
59
|
|
|
60
60
|
import Translate from '../entity/Translate';
|
|
61
|
+
import Connection from '../entity/Connection';
|
|
61
62
|
|
|
62
63
|
import {
|
|
63
64
|
CartItemRepository,
|
|
@@ -263,6 +264,9 @@ export class EnvironmentConfigurationRepository extends Repository<EnvironmentCo
|
|
|
263
264
|
@EntityRepository(Translate)
|
|
264
265
|
export class TranslateRepository extends Repository<Translate> {}
|
|
265
266
|
|
|
267
|
+
@EntityRepository(Connection)
|
|
268
|
+
export class ConnectionRepository extends Repository<Connection> {}
|
|
269
|
+
|
|
266
270
|
export {
|
|
267
271
|
CartItemRepository,
|
|
268
272
|
CartRepository,
|