fix(link-modules): table name (#9151)

FIXES: FRMW-2706
This commit is contained in:
Carlos R. L. Rodrigues
2024-09-16 16:08:42 -03:00
committed by GitHub
parent cb79a5dbff
commit d6ff526820
9 changed files with 150 additions and 37 deletions

View File

@@ -7,6 +7,7 @@ import {
} from "@medusajs/utils"
import { EntitySchema } from "@mikro-orm/core"
import { compressName } from "./compress-name"
function getClass(...properties) {
return class LinkModel {
@@ -62,7 +63,7 @@ export function generateEntity(
class: getClass(
...fieldNames.concat("created_at", "updated_at", "deleted_at")
) as any,
tableName,
tableName: compressName(tableName),
properties: {
id: {
type: "string",