@etohq/index 1.0.0 → 1.1.0
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
|
-
{"root":["../src/index.ts","../src/loaders/index.ts","../src/migrations/
|
|
1
|
+
{"root":["../src/index.ts","../src/loaders/index.ts","../src/migrations/migration20231019174230.ts","../src/migrations/migration20241209173313.ts","../src/models/index-data.ts","../src/models/index-relation.ts","../src/models/index.ts","../src/services/index-module-service.ts","../src/services/index.ts","../src/services/postgres-provider.ts","../src/types/index.ts","../src/utils/build-config.ts","../src/utils/create-partitions.ts","../src/utils/default-schema.ts","../src/utils/flatten-object-keys.ts","../src/utils/gql-to-types.ts","../src/utils/index.ts","../src/utils/normalize-fields-selection.ts","../src/utils/query-builder.ts","../src/utils/__tests__/flatten-object-keys.spec.ts","../src/utils/__tests__/normalize-fields-selcetion.spec.ts"],"version":"5.6.2"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"default-schema.d.ts","sourceRoot":"","sources":["../../src/utils/default-schema.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"default-schema.d.ts","sourceRoot":"","sources":["../../src/utils/default-schema.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,aAAa,QAkBzB,CAAA"}
|
|
@@ -1,22 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.defaultSchema = void 0;
|
|
4
|
-
const
|
|
4
|
+
const Modules = {
|
|
5
|
+
PRODUCT: "product",
|
|
6
|
+
PRICING: "pricing",
|
|
7
|
+
};
|
|
5
8
|
exports.defaultSchema = `
|
|
6
|
-
type Product @Listeners(values: ["${
|
|
9
|
+
type Product @Listeners(values: ["${Modules.PRODUCT}.product.created", "${Modules.PRODUCT}.product.updated", "${Modules.PRODUCT}.product.deleted"]) {
|
|
7
10
|
id: String
|
|
8
11
|
title: String
|
|
9
12
|
variants: [ProductVariant]
|
|
10
13
|
}
|
|
11
14
|
|
|
12
|
-
type ProductVariant @Listeners(values: ["${
|
|
15
|
+
type ProductVariant @Listeners(values: ["${Modules.PRODUCT}.product-variant.created", "${Modules.PRODUCT}.product-variant.updated", "${Modules.PRODUCT}.product-variant.deleted"]) {
|
|
13
16
|
id: String
|
|
14
17
|
product_id: String
|
|
15
18
|
sku: String
|
|
16
19
|
prices: [Price]
|
|
17
20
|
}
|
|
18
21
|
|
|
19
|
-
type Price @Listeners(values: ["${
|
|
22
|
+
type Price @Listeners(values: ["${Modules.PRICING}.price.created", "${Modules.PRICING}.price.updated", "${Modules.PRICING}.price.deleted"]) {
|
|
20
23
|
amount: Int
|
|
21
24
|
currency_code: String
|
|
22
25
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"default-schema.js","sourceRoot":"","sources":["../../src/utils/default-schema.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"default-schema.js","sourceRoot":"","sources":["../../src/utils/default-schema.ts"],"names":[],"mappings":";;;AACA,MAAM,OAAO,GAAG;IACd,OAAO,EAAE,SAAS;IAClB,OAAO,EAAE,SAAS;CACnB,CAAA;AAEY,QAAA,aAAa,GAAG;sCACS,OAAO,CAAC,OAAO,uBAAuB,OAAO,CAAC,OAAO,uBAAuB,OAAO,CAAC,OAAO;;;;;;6CAMpF,OAAO,CAAC,OAAO,+BAA+B,OAAO,CAAC,OAAO,+BAA+B,OAAO,CAAC,OAAO;;;;;;;oCAOpH,OAAO,CAAC,OAAO,qBAAqB,OAAO,CAAC,OAAO,qBAAqB,OAAO,CAAC,OAAO;;;;CAI1H,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@etohq/index",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"description": "Eto Index module",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"repository": {
|
|
17
17
|
"type": "git",
|
|
18
18
|
"url": "https://github.com/etohq/eto",
|
|
19
|
-
"directory": "packages/index"
|
|
19
|
+
"directory": "packages/core/modules/index"
|
|
20
20
|
},
|
|
21
21
|
"publishConfig": {
|
|
22
22
|
"access": "public"
|
|
@@ -26,7 +26,8 @@
|
|
|
26
26
|
"scripts": {
|
|
27
27
|
"watch": "tsc --build --watch",
|
|
28
28
|
"watch:test": "tsc --build tsconfig.spec.json --watch",
|
|
29
|
-
"resolve:aliases": "tsc --showConfig -p tsconfig.json > tsconfig.resolved.json && tsc-alias -p tsconfig.resolved.json && rimraf tsconfig.resolved.json",
|
|
29
|
+
"resolve:aliases": "tsc --showConfig -p tsconfig.json > tsconfig.resolved.json && tsc-alias -p tsconfig.resolved.json && rimraf tsconfig.resolved.json",
|
|
30
|
+
"build": "rimraf dist && tsc --build && npm run resolve:aliases",
|
|
30
31
|
"test": "jest --passWithNoTests ./src",
|
|
31
32
|
"test:integration": "jest --runInBand --forceExit -- integration-tests/**/__tests__/**/*.ts",
|
|
32
33
|
"migration:initial": " MIKRO_ORM_CLI=./mikro-orm.config.dev.ts eto-mikro-orm migration:create --initial",
|
|
@@ -35,8 +36,8 @@
|
|
|
35
36
|
"orm:cache:clear": " MIKRO_ORM_CLI=./mikro-orm.config.dev.ts eto-mikro-orm cache:clear"
|
|
36
37
|
},
|
|
37
38
|
"devDependencies": {
|
|
38
|
-
"@etohq/framework": "^1.
|
|
39
|
-
"@etohq/test-utils": "^1.
|
|
39
|
+
"@etohq/framework": "^1.1.0",
|
|
40
|
+
"@etohq/test-utils": "^1.1.0",
|
|
40
41
|
"@mikro-orm/cli": "5.9.7",
|
|
41
42
|
"@mikro-orm/core": "5.9.7",
|
|
42
43
|
"@mikro-orm/knex": "5.9.7",
|
|
@@ -51,7 +52,7 @@
|
|
|
51
52
|
"typescript": "^5.6.2"
|
|
52
53
|
},
|
|
53
54
|
"dependencies": {
|
|
54
|
-
"@etohq/utils": "^1.
|
|
55
|
+
"@etohq/utils": "^1.1.0",
|
|
55
56
|
"awilix": "^8.0.1"
|
|
56
57
|
},
|
|
57
58
|
"peerDependencies": {
|