feat: auto populate machine structures and seed sample data
This commit is contained in:
@@ -9,46 +9,22 @@ const CUSTOM_FIELD_SELECT = {
|
||||
} as const;
|
||||
|
||||
export const COMPONENT_WITH_RELATIONS_INCLUDE = {
|
||||
machine: true,
|
||||
parentComposant: true,
|
||||
typeComposant: {
|
||||
include: {
|
||||
customFields: true,
|
||||
},
|
||||
},
|
||||
typeMachineComponentRequirement: {
|
||||
include: {
|
||||
typeComposant: {
|
||||
include: {
|
||||
customFields: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
constructeur: true,
|
||||
customFieldValues: {
|
||||
include: {
|
||||
customField: { select: CUSTOM_FIELD_SELECT },
|
||||
},
|
||||
},
|
||||
pieces: {
|
||||
machineLinks: {
|
||||
include: {
|
||||
customFieldValues: {
|
||||
include: {
|
||||
customField: { select: CUSTOM_FIELD_SELECT },
|
||||
},
|
||||
},
|
||||
constructeur: true,
|
||||
typeMachinePieceRequirement: {
|
||||
include: {
|
||||
typePiece: {
|
||||
include: {
|
||||
customFields: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
documents: true,
|
||||
machine: true,
|
||||
typeMachineComponentRequirement: true,
|
||||
childLinks: true,
|
||||
},
|
||||
},
|
||||
documents: true,
|
||||
|
||||
Reference in New Issue
Block a user