Update document template schema to reference object types
All checks were successful
farmcontrol/farmcontrol-ws/pipeline/head This commit looks good
All checks were successful
farmcontrol/farmcontrol-ws/pipeline/head This commit looks good
- Changed the type of `testObject` from Mixed to ObjectId and added a refPath to `objectType`, enhancing the schema's ability to manage relationships with other documents. - This update improves data integrity and allows for more structured querying of related objects.
This commit is contained in:
parent
4fca989b04
commit
f5e74ac471
@ -45,7 +45,8 @@ const documentTemplateSchema = new Schema(
|
||||
default: '<Container></Container>',
|
||||
},
|
||||
testObject: {
|
||||
type: Schema.Types.Mixed,
|
||||
type: Schema.Types.ObjectId,
|
||||
refPath: 'objectType',
|
||||
required: false,
|
||||
},
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user