keystonejs / keystone-classic

Node.js CMS and web app framework
http://v4.keystonejs.com
MIT License
14.64k stars 2.2k forks source link

Keystone Nav Feature Request #4920

Closed igorasilveira closed 5 years ago

igorasilveira commented 5 years ago

Expected behavior

I believe it would be helpful to be able to disable the fact that any Lists not set in the keystone.nav will automatically be placed in an Other field in the Admin UI.

Actual/Current behavior

The idea is that if you have 3 Lists, ie. Posts, Categories, Comments you could be able to set the nav with Posts, Categories and the Comments list would not show in the Admin UI home page.

Environment

Software Version
Keystone v4.0.0
Node.js v10.1.0
Browser Chrome 74
autoboxer commented 5 years ago

@igorasilveira, this can be achieved in a different way when defining your model:

const HiddenModel = new keystone.List( 'Hidden Model', {
    hidden: true
});
igorasilveira commented 5 years ago

@autoboxer I’m aware of that, but what I want to achieve is to hide some Lists to some users, not from the entire Admin UI. Is that possible?

autoboxer commented 5 years ago

As far as I know, @igorasilveira, it's not.

laurenskling commented 5 years ago

It will automatically collect all lists (that are not hidden) to the nav. I don't think we will be adding an option to exclude everything unmentioned in the nav, but I guess you can always try to make a PR :)