@medusajs/store 2.12.2-preview-20251208180143 → 2.12.2-preview-20251209000303
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/migrations/Migration20251202184737.d.ts +6 -0
- package/dist/migrations/Migration20251202184737.d.ts.map +1 -0
- package/dist/migrations/Migration20251202184737.js +17 -0
- package/dist/migrations/Migration20251202184737.js.map +1 -0
- package/dist/models/currency.d.ts +12 -0
- package/dist/models/currency.d.ts.map +1 -1
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.d.ts.map +1 -1
- package/dist/models/index.js +3 -1
- package/dist/models/index.js.map +1 -1
- package/dist/models/locale.d.ts +36 -0
- package/dist/models/locale.d.ts.map +1 -0
- package/dist/models/locale.js +19 -0
- package/dist/models/locale.js.map +1 -0
- package/dist/models/store.d.ts +6 -0
- package/dist/models/store.d.ts.map +1 -1
- package/dist/models/store.js +5 -1
- package/dist/models/store.js.map +1 -1
- package/dist/services/store-module-service.d.ts +4 -0
- package/dist/services/store-module-service.d.ts.map +1 -1
- package/dist/services/store-module-service.js +25 -18
- package/dist/services/store-module-service.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +4 -4
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Migration20251202184737.d.ts","sourceRoot":"","sources":["../../src/migrations/Migration20251202184737.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD,qBAAa,uBAAwB,SAAQ,SAAS;IAErC,EAAE,IAAI,OAAO,CAAC,IAAI,CAAC;IAQnB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAIrC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Migration20251202184737 = void 0;
|
|
4
|
+
const migrations_1 = require("@mikro-orm/migrations");
|
|
5
|
+
class Migration20251202184737 extends migrations_1.Migration {
|
|
6
|
+
async up() {
|
|
7
|
+
this.addSql(`create table if not exists "store_locale" ("id" text not null, "locale_code" text not null, "is_default" boolean not null default false, "store_id" text null, "created_at" timestamptz not null default now(), "updated_at" timestamptz not null default now(), "deleted_at" timestamptz null, constraint "store_locale_pkey" primary key ("id"));`);
|
|
8
|
+
this.addSql(`CREATE INDEX IF NOT EXISTS "IDX_store_locale_store_id" ON "store_locale" ("store_id") WHERE deleted_at IS NULL;`);
|
|
9
|
+
this.addSql(`CREATE INDEX IF NOT EXISTS "IDX_store_locale_deleted_at" ON "store_locale" ("deleted_at") WHERE deleted_at IS NULL;`);
|
|
10
|
+
this.addSql(`alter table if exists "store_locale" add constraint "store_locale_store_id_foreign" foreign key ("store_id") references "store" ("id") on update cascade on delete cascade;`);
|
|
11
|
+
}
|
|
12
|
+
async down() {
|
|
13
|
+
this.addSql(`drop table if exists "store_locale" cascade;`);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
exports.Migration20251202184737 = Migration20251202184737;
|
|
17
|
+
//# sourceMappingURL=Migration20251202184737.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Migration20251202184737.js","sourceRoot":"","sources":["../../src/migrations/Migration20251202184737.ts"],"names":[],"mappings":";;;AAAA,sDAAkD;AAElD,MAAa,uBAAwB,SAAQ,sBAAS;IAE3C,KAAK,CAAC,EAAE;QACf,IAAI,CAAC,MAAM,CAAC,qVAAqV,CAAC,CAAC;QACnW,IAAI,CAAC,MAAM,CAAC,iHAAiH,CAAC,CAAC;QAC/H,IAAI,CAAC,MAAM,CAAC,qHAAqH,CAAC,CAAC;QAEnI,IAAI,CAAC,MAAM,CAAC,6KAA6K,CAAC,CAAC;IAC7L,CAAC;IAEQ,KAAK,CAAC,IAAI;QACjB,IAAI,CAAC,MAAM,CAAC,8CAA8C,CAAC,CAAC;IAC9D,CAAC;CAEF;AAdD,0DAcC"}
|
|
@@ -10,6 +10,12 @@ declare const StoreCurrency: import("@medusajs/framework/utils").DmlEntity<impor
|
|
|
10
10
|
default_location_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
11
11
|
metadata: import("@medusajs/framework/utils").NullableModifier<Record<string, unknown>, import("@medusajs/framework/utils").JSONProperty>;
|
|
12
12
|
supported_currencies: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "StoreCurrency">>;
|
|
13
|
+
supported_locales: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
14
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
15
|
+
locale_code: import("@medusajs/framework/utils").TextProperty;
|
|
16
|
+
is_default: import("@medusajs/framework/utils").BooleanProperty;
|
|
17
|
+
store: import("@medusajs/framework/utils").RelationNullableModifier<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, undefined>, true>;
|
|
18
|
+
}>, "StoreLocale">>;
|
|
13
19
|
}>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
14
20
|
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
15
21
|
name: import("@medusajs/framework/utils").TextProperty;
|
|
@@ -18,6 +24,12 @@ declare const StoreCurrency: import("@medusajs/framework/utils").DmlEntity<impor
|
|
|
18
24
|
default_location_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
19
25
|
metadata: import("@medusajs/framework/utils").NullableModifier<Record<string, unknown>, import("@medusajs/framework/utils").JSONProperty>;
|
|
20
26
|
supported_currencies: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "StoreCurrency">>;
|
|
27
|
+
supported_locales: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
28
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
29
|
+
locale_code: import("@medusajs/framework/utils").TextProperty;
|
|
30
|
+
is_default: import("@medusajs/framework/utils").BooleanProperty;
|
|
31
|
+
store: import("@medusajs/framework/utils").RelationNullableModifier<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, undefined>, true>;
|
|
32
|
+
}>, "StoreLocale">>;
|
|
21
33
|
}>, "Store">, undefined>, true>;
|
|
22
34
|
}>, "StoreCurrency">;
|
|
23
35
|
export default StoreCurrency;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"currency.d.ts","sourceRoot":"","sources":["../../src/models/currency.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,aAAa
|
|
1
|
+
{"version":3,"file":"currency.d.ts","sourceRoot":"","sources":["../../src/models/currency.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBASjB,CAAA;AAEF,eAAe,aAAa,CAAA"}
|
package/dist/models/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,SAAS,CAAA;AAC1C,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,SAAS,CAAA;AAC1C,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,YAAY,CAAA;AACrD,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,UAAU,CAAA"}
|
package/dist/models/index.js
CHANGED
|
@@ -3,9 +3,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.StoreCurrency = exports.Store = void 0;
|
|
6
|
+
exports.StoreLocale = exports.StoreCurrency = exports.Store = void 0;
|
|
7
7
|
var store_1 = require("./store");
|
|
8
8
|
Object.defineProperty(exports, "Store", { enumerable: true, get: function () { return __importDefault(store_1).default; } });
|
|
9
9
|
var currency_1 = require("./currency");
|
|
10
10
|
Object.defineProperty(exports, "StoreCurrency", { enumerable: true, get: function () { return __importDefault(currency_1).default; } });
|
|
11
|
+
var locale_1 = require("./locale");
|
|
12
|
+
Object.defineProperty(exports, "StoreLocale", { enumerable: true, get: function () { return __importDefault(locale_1).default; } });
|
|
11
13
|
//# sourceMappingURL=index.js.map
|
package/dist/models/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":";;;;;;AAAA,iCAA0C;AAAjC,+GAAA,OAAO,OAAS;AACzB,uCAAqD;AAA5C,0HAAA,OAAO,OAAiB"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":";;;;;;AAAA,iCAA0C;AAAjC,+GAAA,OAAO,OAAS;AACzB,uCAAqD;AAA5C,0HAAA,OAAO,OAAiB;AACjC,mCAAiD;AAAxC,sHAAA,OAAO,OAAe"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
declare const StoreLocale: import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
2
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
3
|
+
locale_code: import("@medusajs/framework/utils").TextProperty;
|
|
4
|
+
is_default: import("@medusajs/framework/utils").BooleanProperty;
|
|
5
|
+
store: import("@medusajs/framework/utils").RelationNullableModifier<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
6
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
7
|
+
name: import("@medusajs/framework/utils").TextProperty;
|
|
8
|
+
default_sales_channel_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
9
|
+
default_region_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
10
|
+
default_location_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
11
|
+
metadata: import("@medusajs/framework/utils").NullableModifier<Record<string, unknown>, import("@medusajs/framework/utils").JSONProperty>;
|
|
12
|
+
supported_currencies: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
13
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
14
|
+
currency_code: import("@medusajs/framework/utils").TextProperty;
|
|
15
|
+
is_default: import("@medusajs/framework/utils").BooleanProperty;
|
|
16
|
+
store: import("@medusajs/framework/utils").RelationNullableModifier<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, undefined>, true>;
|
|
17
|
+
}>, "StoreCurrency">>;
|
|
18
|
+
supported_locales: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "StoreLocale">>;
|
|
19
|
+
}>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
20
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
21
|
+
name: import("@medusajs/framework/utils").TextProperty;
|
|
22
|
+
default_sales_channel_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
23
|
+
default_region_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
24
|
+
default_location_id: import("@medusajs/framework/utils").NullableModifier<string, import("@medusajs/framework/utils").TextProperty>;
|
|
25
|
+
metadata: import("@medusajs/framework/utils").NullableModifier<Record<string, unknown>, import("@medusajs/framework/utils").JSONProperty>;
|
|
26
|
+
supported_currencies: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
27
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
28
|
+
currency_code: import("@medusajs/framework/utils").TextProperty;
|
|
29
|
+
is_default: import("@medusajs/framework/utils").BooleanProperty;
|
|
30
|
+
store: import("@medusajs/framework/utils").RelationNullableModifier<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, undefined>, true>;
|
|
31
|
+
}>, "StoreCurrency">>;
|
|
32
|
+
supported_locales: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "StoreLocale">>;
|
|
33
|
+
}>, "Store">, undefined>, true>;
|
|
34
|
+
}>, "StoreLocale">;
|
|
35
|
+
export default StoreLocale;
|
|
36
|
+
//# sourceMappingURL=locale.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"locale.d.ts","sourceRoot":"","sources":["../../src/models/locale.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBASf,CAAA;AAEF,eAAe,WAAW,CAAA"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const utils_1 = require("@medusajs/framework/utils");
|
|
7
|
+
const store_1 = __importDefault(require("./store"));
|
|
8
|
+
const StoreLocale = utils_1.model.define("StoreLocale", {
|
|
9
|
+
id: utils_1.model.id({ prefix: "stloc" }).primaryKey(),
|
|
10
|
+
locale_code: utils_1.model.text().searchable(),
|
|
11
|
+
is_default: utils_1.model.boolean().default(false),
|
|
12
|
+
store: utils_1.model
|
|
13
|
+
.belongsTo(() => store_1.default, {
|
|
14
|
+
mappedBy: "supported_locales",
|
|
15
|
+
})
|
|
16
|
+
.nullable(),
|
|
17
|
+
});
|
|
18
|
+
exports.default = StoreLocale;
|
|
19
|
+
//# sourceMappingURL=locale.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"locale.js","sourceRoot":"","sources":["../../src/models/locale.ts"],"names":[],"mappings":";;;;;AAAA,qDAAiD;AACjD,oDAA2B;AAE3B,MAAM,WAAW,GAAG,aAAK,CAAC,MAAM,CAAC,aAAa,EAAE;IAC9C,EAAE,EAAE,aAAK,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,CAAC,UAAU,EAAE;IAC9C,WAAW,EAAE,aAAK,CAAC,IAAI,EAAE,CAAC,UAAU,EAAE;IACtC,UAAU,EAAE,aAAK,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC;IAC1C,KAAK,EAAE,aAAK;SACT,SAAS,CAAC,GAAG,EAAE,CAAC,eAAK,EAAE;QACtB,QAAQ,EAAE,mBAAmB;KAC9B,CAAC;SACD,QAAQ,EAAE;CACd,CAAC,CAAA;AAEF,kBAAe,WAAW,CAAA"}
|
package/dist/models/store.d.ts
CHANGED
|
@@ -11,6 +11,12 @@ declare const Store: import("@medusajs/framework/utils").DmlEntity<import("@medu
|
|
|
11
11
|
is_default: import("@medusajs/framework/utils").BooleanProperty;
|
|
12
12
|
store: import("@medusajs/framework/utils").RelationNullableModifier<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, undefined>, true>;
|
|
13
13
|
}>, "StoreCurrency">>;
|
|
14
|
+
supported_locales: import("@medusajs/framework/utils").HasMany<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder<{
|
|
15
|
+
id: import("@medusajs/framework/utils").PrimaryKeyModifier<string, import("@medusajs/framework/utils").IdProperty>;
|
|
16
|
+
locale_code: import("@medusajs/framework/utils").TextProperty;
|
|
17
|
+
is_default: import("@medusajs/framework/utils").BooleanProperty;
|
|
18
|
+
store: import("@medusajs/framework/utils").RelationNullableModifier<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, import("@medusajs/framework/utils").BelongsTo<() => import("@medusajs/framework/utils").DmlEntity<import("@medusajs/framework/utils").DMLEntitySchemaBuilder</*elided*/ any>, "Store">, undefined>, true>;
|
|
19
|
+
}>, "StoreLocale">>;
|
|
14
20
|
}>, "Store">;
|
|
15
21
|
export default Store;
|
|
16
22
|
//# sourceMappingURL=store.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"store.d.ts","sourceRoot":"","sources":["../../src/models/store.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"store.d.ts","sourceRoot":"","sources":["../../src/models/store.ts"],"names":[],"mappings":"AAIA,QAAA,MAAM,KAAK;;;;;;;;;;;;;;;;;;;YAiBP,CAAA;AAEJ,eAAe,KAAK,CAAA"}
|
package/dist/models/store.js
CHANGED
|
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const utils_1 = require("@medusajs/framework/utils");
|
|
7
7
|
const currency_1 = __importDefault(require("./currency"));
|
|
8
|
+
const locale_1 = __importDefault(require("./locale"));
|
|
8
9
|
const Store = utils_1.model
|
|
9
10
|
.define("Store", {
|
|
10
11
|
id: utils_1.model.id({ prefix: "store" }).primaryKey(),
|
|
@@ -16,9 +17,12 @@ const Store = utils_1.model
|
|
|
16
17
|
supported_currencies: utils_1.model.hasMany(() => currency_1.default, {
|
|
17
18
|
mappedBy: "store",
|
|
18
19
|
}),
|
|
20
|
+
supported_locales: utils_1.model.hasMany(() => locale_1.default, {
|
|
21
|
+
mappedBy: "store",
|
|
22
|
+
}),
|
|
19
23
|
})
|
|
20
24
|
.cascades({
|
|
21
|
-
delete: ["supported_currencies"],
|
|
25
|
+
delete: ["supported_currencies", "supported_locales"],
|
|
22
26
|
});
|
|
23
27
|
exports.default = Store;
|
|
24
28
|
//# sourceMappingURL=store.js.map
|
package/dist/models/store.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"store.js","sourceRoot":"","sources":["../../src/models/store.ts"],"names":[],"mappings":";;;;;AAAA,qDAAiD;AACjD,0DAAsC;
|
|
1
|
+
{"version":3,"file":"store.js","sourceRoot":"","sources":["../../src/models/store.ts"],"names":[],"mappings":";;;;;AAAA,qDAAiD;AACjD,0DAAsC;AACtC,sDAAkC;AAElC,MAAM,KAAK,GAAG,aAAK;KAChB,MAAM,CAAC,OAAO,EAAE;IACf,EAAE,EAAE,aAAK,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,CAAC,UAAU,EAAE;IAC9C,IAAI,EAAE,aAAK,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC,UAAU,EAAE;IACvD,wBAAwB,EAAE,aAAK,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IACjD,iBAAiB,EAAE,aAAK,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IAC1C,mBAAmB,EAAE,aAAK,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IAC5C,QAAQ,EAAE,aAAK,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IACjC,oBAAoB,EAAE,aAAK,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,kBAAa,EAAE;QACvD,QAAQ,EAAE,OAAO;KAClB,CAAC;IACF,iBAAiB,EAAE,aAAK,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,gBAAW,EAAE;QAClD,QAAQ,EAAE,OAAO;KAClB,CAAC;CACH,CAAC;KACD,QAAQ,CAAC;IACR,MAAM,EAAE,CAAC,sBAAsB,EAAE,mBAAmB,CAAC;CACtD,CAAC,CAAA;AAEJ,kBAAe,KAAK,CAAA"}
|
|
@@ -12,6 +12,9 @@ declare const StoreModuleService_base: import("@medusajs/framework/utils").Medus
|
|
|
12
12
|
StoreCurrency: {
|
|
13
13
|
dto: StoreTypes.StoreCurrencyDTO;
|
|
14
14
|
};
|
|
15
|
+
StoreLocale: {
|
|
16
|
+
dto: StoreTypes.StoreLocaleDTO;
|
|
17
|
+
};
|
|
15
18
|
}>;
|
|
16
19
|
export default class StoreModuleService extends StoreModuleService_base implements IStoreModuleService {
|
|
17
20
|
protected readonly moduleDeclaration: InternalModuleDeclaration;
|
|
@@ -29,6 +32,7 @@ export default class StoreModuleService extends StoreModuleService_base implemen
|
|
|
29
32
|
protected update_(data: UpdateStoreInput[], sharedContext?: Context): Promise<InferEntityType<typeof Store>[]>;
|
|
30
33
|
private static normalizeInput;
|
|
31
34
|
private static validateCreateRequest;
|
|
35
|
+
private static validateSupportedItems;
|
|
32
36
|
private static validateUpdateRequest;
|
|
33
37
|
}
|
|
34
38
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"store-module-service.d.ts","sourceRoot":"","sources":["../../src/services/store-module-service.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,OAAO,EACP,GAAG,EACH,eAAe,EACf,yBAAyB,EACzB,mBAAmB,EACnB,eAAe,EACf,UAAU,EACX,MAAM,2BAA2B,CAAA;AAclC,OAAO,EAAE,KAAK,
|
|
1
|
+
{"version":3,"file":"store-module-service.d.ts","sourceRoot":"","sources":["../../src/services/store-module-service.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,OAAO,EACP,GAAG,EACH,eAAe,EACf,yBAAyB,EACzB,mBAAmB,EACnB,eAAe,EACf,UAAU,EACX,MAAM,2BAA2B,CAAA;AAclC,OAAO,EAAE,KAAK,EAA8B,M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AC,EAAE,OAAO,GACtB,OAAO,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;IAC3B,YAAY,CAChB,IAAI,EAAE,UAAU,CAAC,cAAc,EAC/B,aAAa,CAAC,EAAE,OAAO,GACtB,OAAO,CAAC,UAAU,CAAC,QAAQ,CAAC;cAgBf,aAAa,CAC3B,IAAI,EAAE,UAAU,CAAC,cAAc,GAAG,UAAU,CAAC,cAAc,EAAE,EAC5C,aAAa,GAAE,OAAY,GAC3C,OAAO,CAAC,eAAe,CAAC,OAAO,KAAK,CAAC,EAAE,CAAC;IAwBrC,YAAY,CAChB,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,UAAU,CAAC,cAAc,EAC/B,aAAa,CAAC,EAAE,OAAO,GACtB,OAAO,CAAC,UAAU,CAAC,QAAQ,CAAC;IAEzB,YAAY,CAChB,QAAQ,EAAE,UAAU,CAAC,oBAAoB,EACzC,IAAI,EAAE,UAAU,CAAC,cAAc,EAC/B,aAAa,CAAC,EAAE,OAAO,GACtB,OAAO,CAAC,UAAU,CAAC,QAAQ,EAAE,CAAC;cAoCjB,OAAO,CACrB,IAAI,EAAE,gBAAgB,EAAE,EACP,aAAa,GAAE,OAAY,GAC3C,OAAO,CAAC,eAAe,CAAC,OAAO,KAAK,CAAC,EAAE,CAAC;IAa3C,OAAO,CAAC,MAAM,CAAC,cAAc;IAe7B,OAAO,CAAC,MAAM,CAAC,qBAAqB;IAuBpC,OAAO,CAAC,MAAM,CAAC,sBAAsB;IAmCrC,OAAO,CAAC,MAAM,CAAC,qBAAqB;CAGrC"}
|
|
@@ -15,7 +15,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
15
15
|
const types_1 = require("@medusajs/framework/types");
|
|
16
16
|
const utils_1 = require("@medusajs/framework/utils");
|
|
17
17
|
const _models_1 = require("../models");
|
|
18
|
-
class StoreModuleService extends (0, utils_1.MedusaService)({ Store: _models_1.Store, StoreCurrency: _models_1.StoreCurrency }) {
|
|
18
|
+
class StoreModuleService extends (0, utils_1.MedusaService)({ Store: _models_1.Store, StoreCurrency: _models_1.StoreCurrency, StoreLocale: _models_1.StoreLocale }) {
|
|
19
19
|
constructor({ baseRepository, storeService }, moduleDeclaration) {
|
|
20
20
|
// @ts-ignore
|
|
21
21
|
super(...arguments);
|
|
@@ -32,7 +32,7 @@ class StoreModuleService extends (0, utils_1.MedusaService)({ Store: _models_1.S
|
|
|
32
32
|
async create_(data, sharedContext = {}) {
|
|
33
33
|
let normalizedInput = StoreModuleService.normalizeInput(data);
|
|
34
34
|
StoreModuleService.validateCreateRequest(normalizedInput);
|
|
35
|
-
return (await this.storeService_.upsertWithReplace(normalizedInput, { relations: ["supported_currencies"] }, sharedContext)).entities;
|
|
35
|
+
return (await this.storeService_.upsertWithReplace(normalizedInput, { relations: ["supported_currencies", "supported_locales"] }, sharedContext)).entities;
|
|
36
36
|
}
|
|
37
37
|
async upsertStores(data, sharedContext = {}) {
|
|
38
38
|
const result = await this.upsertStores_(data, sharedContext);
|
|
@@ -72,7 +72,7 @@ class StoreModuleService extends (0, utils_1.MedusaService)({ Store: _models_1.S
|
|
|
72
72
|
async update_(data, sharedContext = {}) {
|
|
73
73
|
const normalizedInput = StoreModuleService.normalizeInput(data);
|
|
74
74
|
StoreModuleService.validateUpdateRequest(normalizedInput);
|
|
75
|
-
return (await this.storeService_.upsertWithReplace(normalizedInput, { relations: ["supported_currencies"] }, sharedContext)).entities;
|
|
75
|
+
return (await this.storeService_.upsertWithReplace(normalizedInput, { relations: ["supported_currencies", "supported_locales"] }, sharedContext)).entities;
|
|
76
76
|
}
|
|
77
77
|
static normalizeInput(stores) {
|
|
78
78
|
return stores.map((store) => (0, utils_1.removeUndefined)({
|
|
@@ -87,23 +87,30 @@ class StoreModuleService extends (0, utils_1.MedusaService)({ Store: _models_1.S
|
|
|
87
87
|
static validateCreateRequest(stores) {
|
|
88
88
|
for (const store of stores) {
|
|
89
89
|
if (store.supported_currencies?.length) {
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
90
|
+
StoreModuleService.validateSupportedItems(store.supported_currencies, (c) => c.currency_code, "currency");
|
|
91
|
+
}
|
|
92
|
+
// TODO: If we are protecting this module behind a feature flag, we should check if the feature flag is enabled before validating the locales.
|
|
93
|
+
if (store.supported_locales?.length) {
|
|
94
|
+
StoreModuleService.validateSupportedItems(store.supported_locales, (l) => l.locale_code, "locale");
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
static validateSupportedItems(items, getCode, typeName) {
|
|
99
|
+
const duplicates = (0, utils_1.getDuplicates)(items.map(getCode));
|
|
100
|
+
if (duplicates.length) {
|
|
101
|
+
throw new utils_1.MedusaError(utils_1.MedusaError.Types.INVALID_DATA, `Duplicate ${typeName} codes: ${duplicates.join(", ")}`);
|
|
102
|
+
}
|
|
103
|
+
let seenDefault = false;
|
|
104
|
+
items.forEach((item) => {
|
|
105
|
+
if (item.is_default) {
|
|
106
|
+
if (seenDefault) {
|
|
107
|
+
throw new utils_1.MedusaError(utils_1.MedusaError.Types.INVALID_DATA, `Only one default ${typeName} is allowed`);
|
|
105
108
|
}
|
|
109
|
+
seenDefault = true;
|
|
106
110
|
}
|
|
111
|
+
});
|
|
112
|
+
if (!seenDefault) {
|
|
113
|
+
throw new utils_1.MedusaError(utils_1.MedusaError.Types.INVALID_DATA, `There should be a default ${typeName} set for the store`);
|
|
107
114
|
}
|
|
108
115
|
}
|
|
109
116
|
static validateUpdateRequest(stores) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"store-module-service.js","sourceRoot":"","sources":["../../src/services/store-module-service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,qDAQkC;AAClC,qDAWkC;AAElC,
|
|
1
|
+
{"version":3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AA,qBAAa,GAAE;IACf,IAAA,kBAAU,GAAE;IACb,mBAAmB;;IAIhB,WAAA,IAAA,qBAAa,GAAE,CAAA;;;;sDAyBjB;AAGe;IADf,IAAA,gCAAwB,GAAE;IAGxB,WAAA,IAAA,qBAAa,GAAE,CAAA;;;;iDAYjB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"root":["../src/index.ts","../src/migrations/InitialSetup20240227075933.ts","../src/migrations/Migration20240621145944.ts","../src/migrations/Migration20241206083313.ts","../src/models/currency.ts","../src/models/index.ts","../src/models/store.ts","../src/services/index.ts","../src/services/store-module-service.ts","../src/services/__tests__/noop.ts","../src/types/index.ts"],"version":"5.9.3"}
|
|
1
|
+
{"root":["../src/index.ts","../src/migrations/InitialSetup20240227075933.ts","../src/migrations/Migration20240621145944.ts","../src/migrations/Migration20241206083313.ts","../src/migrations/Migration20251202184737.ts","../src/models/currency.ts","../src/models/index.ts","../src/models/locale.ts","../src/models/store.ts","../src/services/index.ts","../src/services/store-module-service.ts","../src/services/__tests__/noop.ts","../src/types/index.ts"],"version":"5.9.3"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@medusajs/store",
|
|
3
|
-
"version": "2.12.2-preview-
|
|
3
|
+
"version": "2.12.2-preview-20251209000303",
|
|
4
4
|
"description": "Medusa Store module",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -36,10 +36,10 @@
|
|
|
36
36
|
"orm:cache:clear": "MIKRO_ORM_CLI_CONFIG=./mikro-orm.config.dev.ts MIKRO_ORM_ALLOW_GLOBAL_CLI=true medusa-mikro-orm cache:clear"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@medusajs/framework": "2.12.2-preview-
|
|
40
|
-
"@medusajs/test-utils": "2.12.2-preview-
|
|
39
|
+
"@medusajs/framework": "2.12.2-preview-20251209000303",
|
|
40
|
+
"@medusajs/test-utils": "2.12.2-preview-20251209000303"
|
|
41
41
|
},
|
|
42
42
|
"peerDependencies": {
|
|
43
|
-
"@medusajs/framework": "2.12.2-preview-
|
|
43
|
+
"@medusajs/framework": "2.12.2-preview-20251209000303"
|
|
44
44
|
}
|
|
45
45
|
}
|