You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let marketingprograms: any = await this.marketingProgramRepository.find({
include: {
relation: 'Brand', // include the brand model
scope: { // further filter the owner object
fields: ['brandName'], // only show one field
include: {
relation: 'Country',
scope: {
fields: ['countryId'],
scope: {
where: { MktngPgmId: marketingProgramId }
}
}
}
}
}
});
it is showing the error on the first include line as
Argument of type '{ include: { relation: string; scope: { fields: string[]; include: { relation: string; scope: { fields: string[]; scope: { where: { MktngPgmId: any; }; }; }; }; }; }; }' is not assignable to parameter of type 'Filter'.
Types of property 'include' are incompatible.
Type '{ relation: string; scope: { fields: string[]; include: { relation: string; scope: { fields: string[]; scope: { where: { MktngPgmId: any; }; }; }; }; }; }' is not assignable to type 'Inclusion[]'.
Object literal may only specify known properties, and 'relation' does not exist in type 'Inclusion[]'.
The text was updated successfully, but these errors were encountered:
let marketingprograms: any = await this.marketingProgramRepository.find({
include: {
relation: 'Brand', // include the brand model
scope: { // further filter the owner object
fields: ['brandName'], // only show one field
include: {
relation: 'Country',
scope: {
fields: ['countryId'],
scope: {
where: { MktngPgmId: marketingProgramId }
}
}
}
}
}
});
it is showing the error on the first include line as
Argument of type '{ include: { relation: string; scope: { fields: string[]; include: { relation: string; scope: { fields: string[]; scope: { where: { MktngPgmId: any; }; }; }; }; }; }; }' is not assignable to parameter of type 'Filter'.
Types of property 'include' are incompatible.
Type '{ relation: string; scope: { fields: string[]; include: { relation: string; scope: { fields: string[]; scope: { where: { MktngPgmId: any; }; }; }; }; }; }' is not assignable to type 'Inclusion[]'.
Object literal may only specify known properties, and 'relation' does not exist in type 'Inclusion[]'.
The text was updated successfully, but these errors were encountered: