Skip to content
This repository has been archived by the owner on Mar 20, 2024. It is now read-only.

how to set related models #71

Open
Moodyqiqi opened this issue Oct 26, 2021 · 1 comment
Open

how to set related models #71

Moodyqiqi opened this issue Oct 26, 2021 · 1 comment

Comments

@Moodyqiqi
Copy link

Moodyqiqi commented Oct 26, 2021

strapi: 3.6.6
strapi-middleware-cache: 2.1.0

i have city and building models, i want to clear building cache when i update or delete city model.
in building/models/building/settings.json, i have set {attributes: {city: {model: "city"}}}
in middleware.js, i have set {clearRelatedCache: true}, it's not clear building cache when i edit or delete city model.

document said (this clears the whole cache for the related models), is there any way to set related models?

@laurenskling
Copy link

Same for me. I cannot get clearRelatedCache working. I want to clear my vehicle cache when an vehicleImage has updated, but it doesn't :(

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants