Horje
second level relationships data not found in strapi Code Example
second level relationships data not found in strapi
module.exports = {
  find: ctx => {
    return strapi.query('person').find(ctx.query, ['address', 'contact']);
  },
};
second level relationships data not found in strapi
async find(ctx) {
    const entities = await strapi.services.booking.find(ctx.query, [
        'class',
        'class.capacity',
        'class.date',
        'class.category',
        'class.category.name',
        'class.type',
        'class.type.name',
        'class.startTime',
        'class.endTime',
      ]);
    }

    return entities.map((entity) =>
      sanitizeEntity(entity, { model: strapi.models.booking }),
    );
  },
second level relationships data not found in strapi
module.exports = {
  find: ctx => {
    return strapi.query('person').find(ctx.query, [
       { path: 'address' },
       { path: 'contact' },
    ]);
  },
};
second level relationships data not found in strapi
module.exports = {
  find: ctx => {
    return strapi.query('person').find(ctx.query, [
      {
        path: 'address',
        populate: {
          path: 'contacts',
        },
      },
    ]);
  },
};




Javascript

Related
exemple de modal reactjs Code Example exemple de modal reactjs Code Example
set time slots with date in javascript Code Example set time slots with date in javascript Code Example
check date clash js Code Example check date clash js Code Example
handleauthenticateasync unit test Code Example handleauthenticateasync unit test Code Example
add button to add item javascript Code Example add button to add item javascript Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
7