简体   繁体   English

Strapi 嵌套组件 UI,数据不可见,问题

[英]Strapi Nested Components UI, data not visible, issue

Is there any way to get to see the data in the UI of strapi if the components made are nested till third level so that I can make changes there only and does not have to go to database all the time for data changes.如果制作的组件嵌套到第三层,是否有任何方法可以在 strapi 的 UI 中查看数据,这样我只能在那里进行更改,而不必一直为 go 访问数据库以进行数据更改。 The image shows a link components wihich has three three files inside it and the component itself is wrapped under a component which is again wrapped into another one and so on...it has the data in it but is not visible in the UI该图像显示了一个链接组件,其中包含三个三个文件,组件本身包裹在一个组件下,该组件再次包裹到另一个组件中,依此类推......它包含数据但在 UI 中不可见

I tried contacting the community but if someone figured out a solution by itslef do help as we are at production level now and this cms is to be used by non-technical people now who has no idea of what Database is...我尝试联系社区,但如果有人通过 itslef 找到解决方案,请提供帮助,因为我们现在处于生产级别,这个 cms 将由现在不知道数据库是什么的非技术人员使用...

If you are able to add data that is more than 2 levels deep and the only problem you are facing is that you can't see the nested JSON in the API response, I would suggest taking a look at如果您能够添加深度超过 2 层的数据,并且您面临的唯一问题是您在 API 响应中看不到嵌套的 JSON,我建议您看一下

https://www.npmjs.com/package/strapi-plugin-populate-deep . https://www.npmjs.com/package/strapi-plugin-populate-deep

After installing it properly, you will just have to use you can use it as follows:正确安装后,您只需使用即可,如下所示:

Populate a request with the default max depth.使用默认的最大深度填充请求。

/api/articles?populate=deep

Populate a request with the custom depth使用自定义深度填充请求

/api/articles?populate=deep,10

Populate a request with the custom depth and filter使用自定义深度和过滤器填充请求

/api/articles/1?populate=deep,10

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM