Hide config model in content type builder and content manager

This commit is contained in:
Jim Laurie 2018-02-02 14:50:10 +01:00
parent 29af75cc51
commit 0e739d8e32
2 changed files with 8 additions and 1 deletions

View File

@ -22,8 +22,11 @@ module.exports = {
'associations'
]);
const models = _.mapValues(strapi.models, pickData);
delete models['strapi-configs'];
ctx.body = {
models: _.mapValues(strapi.models, pickData),
models,
plugins: Object.keys(strapi.plugins).reduce((acc, current) => {
acc[current] = {
models: _.mapValues(strapi.plugins[current].models, pickData)

View File

@ -10,6 +10,10 @@ module.exports = {
const models = [];
_.forEach(strapi.models, (model, name) => {
if (name === 'strapi-configs') {
return true;
}
models.push({
icon: 'fa-cube',
name: _.get(model, 'info.name', 'model.name.missing'),